intl-tel-input 25.0.0 → 25.0.2

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.
@@ -1,4 +1,4 @@
1
- import { mergeModels as i2, useModel as A2, ref as I1, onMounted as E2, watch as D2, onUnmounted as M2, withDirectives as P2, openBlock as x2, createElementBlock as R2, mergeProps as B2, vModelText as k2 } from "vue";
1
+ import { mergeModels as i2, useModel as T2, ref as I1, onMounted as E2, watch as D2, onUnmounted as M2, withDirectives as P2, openBlock as x2, createElementBlock as R2, mergeProps as B2, vModelText as k2 } from "vue";
2
2
  const r2 = [
3
3
  [
4
4
  "af",
@@ -9,8 +9,7 @@ const r2 = [
9
9
  "ax",
10
10
  // Åland Islands
11
11
  "358",
12
- 1,
13
- ["18"]
12
+ 1
14
13
  ],
15
14
  [
16
15
  "al",
@@ -1305,16 +1304,17 @@ const r2 = [
1305
1304
  // Zimbabwe
1306
1305
  "263"
1307
1306
  ]
1308
- ], H = [];
1307
+ ], W = [];
1309
1308
  for (let y = 0; y < r2.length; y++) {
1310
1309
  const $ = r2[y];
1311
- H[y] = {
1310
+ W[y] = {
1312
1311
  name: "",
1313
1312
  // this is now populated in the plugin
1314
1313
  iso2: $[0],
1315
1314
  dialCode: $[1],
1316
1315
  priority: $[2] || 0,
1317
1316
  areaCodes: $[3] || null,
1317
+ partialAreaCodes: null,
1318
1318
  nodeById: {}
1319
1319
  };
1320
1320
  }
@@ -1573,10 +1573,10 @@ const O2 = {
1573
1573
  ac: "Ascension Island",
1574
1574
  xk: "Kosovo"
1575
1575
  }, u2 = { ...O2, ...G2 };
1576
- for (let y = 0; y < H.length; y++)
1577
- H[y].name = u2[H[y].iso2];
1576
+ for (let y = 0; y < W.length; y++)
1577
+ W[y].name = u2[W[y].iso2];
1578
1578
  let F2 = 0;
1579
- const l2 = {
1579
+ const a2 = {
1580
1580
  //* Whether or not to allow the dropdown.
1581
1581
  allowDropdown: !0,
1582
1582
  //* Add a placeholder in the input with an example number for the selected country.
@@ -1660,33 +1660,33 @@ const l2 = {
1660
1660
  if (n === 0 && !i)
1661
1661
  return 0;
1662
1662
  let o = 0;
1663
- for (let a = 0; a < $.length; a++) {
1664
- if (/[+0-9]/.test($[a]) && o++, o === y && !i)
1665
- return a + 1;
1663
+ for (let l = 0; l < $.length; l++) {
1664
+ if (/[+0-9]/.test($[l]) && o++, o === y && !i)
1665
+ return l + 1;
1666
1666
  if (i && o === y + 1)
1667
- return a;
1667
+ return l;
1668
1668
  }
1669
1669
  return $.length;
1670
- }, A = (y, $, n) => {
1670
+ }, N = (y, $, n) => {
1671
1671
  const i = document.createElement(y);
1672
- return $ && Object.entries($).forEach(([o, a]) => i.setAttribute(o, a)), n && n.appendChild(i), i;
1673
- }, e1 = (y, ...$) => {
1672
+ return $ && Object.entries($).forEach(([o, l]) => i.setAttribute(o, l)), n && n.appendChild(i), i;
1673
+ }, $1 = (y, ...$) => {
1674
1674
  const { instances: n } = C;
1675
1675
  Object.values(n).forEach((i) => i[y](...$));
1676
1676
  };
1677
1677
  class K2 {
1678
1678
  constructor($, n = {}) {
1679
- this.id = F2++, this.telInput = $, this.highlightedItem = null, this.options = Object.assign({}, l2, n), this.hadInitialPlaceholder = !!$.getAttribute("placeholder");
1679
+ this.id = F2++, this.telInput = $, this.highlightedItem = null, this.options = Object.assign({}, a2, n), this.hadInitialPlaceholder = !!$.getAttribute("placeholder");
1680
1680
  }
1681
1681
  //* Can't be private as it's called from intlTelInput convenience wrapper.
1682
1682
  _init() {
1683
1683
  this.options.useFullscreenPopup && (this.options.fixDropdownWidth = !1), this.options.onlyCountries.length === 1 && (this.options.initialCountry = this.options.onlyCountries[0]), this.options.separateDialCode && (this.options.nationalMode = !1), this.options.allowDropdown && !this.options.showFlags && !this.options.separateDialCode && (this.options.nationalMode = !1), this.options.useFullscreenPopup && !this.options.dropdownContainer && (this.options.dropdownContainer = document.body), this.isAndroid = typeof navigator < "u" ? /Android/i.test(navigator.userAgent) : !1, this.isRTL = !!this.telInput.closest("[dir=rtl]");
1684
1684
  const $ = this.options.allowDropdown || this.options.separateDialCode;
1685
1685
  this.showSelectedCountryOnLeft = this.isRTL ? !$ : $, this.options.separateDialCode && (this.isRTL ? this.originalPaddingRight = this.telInput.style.paddingRight : this.originalPaddingLeft = this.telInput.style.paddingLeft), this.options.i18n = { ...u2, ...this.options.i18n };
1686
- const n = new Promise((o, a) => {
1687
- this.resolveAutoCountryPromise = o, this.rejectAutoCountryPromise = a;
1688
- }), i = new Promise((o, a) => {
1689
- this.resolveUtilsScriptPromise = o, this.rejectUtilsScriptPromise = a;
1686
+ const n = new Promise((o, l) => {
1687
+ this.resolveAutoCountryPromise = o, this.rejectAutoCountryPromise = l;
1688
+ }), i = new Promise((o, l) => {
1689
+ this.resolveUtilsScriptPromise = o, this.rejectUtilsScriptPromise = l;
1690
1690
  });
1691
1691
  this.promise = Promise.all([n, i]), this.selectedCountryData = {}, this._processCountryData(), this._generateMarkup(), this._setInitialState(), this._initListeners(), this._initRequests();
1692
1692
  }
@@ -1702,9 +1702,9 @@ class K2 {
1702
1702
  this.options.countryOrder && (this.options.countryOrder = this.options.countryOrder.map(($) => $.toLowerCase())), this.countries.sort(($, n) => {
1703
1703
  const { countryOrder: i } = this.options;
1704
1704
  if (i) {
1705
- const o = i.indexOf($.iso2), a = i.indexOf(n.iso2), c = o > -1, g = a > -1;
1706
- if (c || g)
1707
- return c && g ? o - a : c ? -1 : 1;
1705
+ const o = i.indexOf($.iso2), l = i.indexOf(n.iso2), c = o > -1, f = l > -1;
1706
+ if (c || f)
1707
+ return c && f ? o - l : c ? -1 : 1;
1708
1708
  }
1709
1709
  return $.name.localeCompare(n.name);
1710
1710
  });
@@ -1712,8 +1712,8 @@ class K2 {
1712
1712
  //* Add a dial code to this.dialCodeToIso2Map.
1713
1713
  _addToDialCodeMap($, n, i) {
1714
1714
  n.length > this.dialCodeMaxLen && (this.dialCodeMaxLen = n.length), this.dialCodeToIso2Map.hasOwnProperty(n) || (this.dialCodeToIso2Map[n] = []);
1715
- for (let a = 0; a < this.dialCodeToIso2Map[n].length; a++)
1716
- if (this.dialCodeToIso2Map[n][a] === $)
1715
+ for (let l = 0; l < this.dialCodeToIso2Map[n].length; l++)
1716
+ if (this.dialCodeToIso2Map[n][l] === $)
1717
1717
  return;
1718
1718
  const o = i !== void 0 ? i : this.dialCodeToIso2Map[n].length;
1719
1719
  this.dialCodeToIso2Map[n][o] = $;
@@ -1725,18 +1725,18 @@ class K2 {
1725
1725
  const i = $.map(
1726
1726
  (o) => o.toLowerCase()
1727
1727
  );
1728
- this.countries = H.filter(
1728
+ this.countries = W.filter(
1729
1729
  (o) => i.indexOf(o.iso2) > -1
1730
1730
  );
1731
1731
  } else if (n.length) {
1732
1732
  const i = n.map(
1733
1733
  (o) => o.toLowerCase()
1734
1734
  );
1735
- this.countries = H.filter(
1735
+ this.countries = W.filter(
1736
1736
  (o) => i.indexOf(o.iso2) === -1
1737
1737
  );
1738
1738
  } else
1739
- this.countries = H;
1739
+ this.countries = W;
1740
1740
  }
1741
1741
  //* Translate Countries by object literal provided on config.
1742
1742
  _translateCountryNames() {
@@ -1745,7 +1745,7 @@ class K2 {
1745
1745
  this.options.i18n.hasOwnProperty(n) && (this.countries[$].name = this.options.i18n[n]);
1746
1746
  }
1747
1747
  }
1748
- //* Generate this.dialCodes and this.dialCodeToIso2Map.
1748
+ //* Generate this.dialCodes and this.dialCodeToIso2Map and country.partialAreaCodes.
1749
1749
  _processDialCodes() {
1750
1750
  this.dialCodes = {}, this.dialCodeMaxLen = 0, this.dialCodeToIso2Map = {};
1751
1751
  for (let $ = 0; $ < this.countries.length; $++) {
@@ -1757,41 +1757,41 @@ class K2 {
1757
1757
  if (n.areaCodes) {
1758
1758
  const i = this.dialCodeToIso2Map[n.dialCode][0];
1759
1759
  for (let o = 0; o < n.areaCodes.length; o++) {
1760
- const a = n.areaCodes[o];
1761
- for (let c = 1; c < a.length; c++) {
1762
- const g = n.dialCode + a.substr(0, c);
1763
- this._addToDialCodeMap(i, g), this._addToDialCodeMap(n.iso2, g);
1760
+ const l = n.areaCodes[o];
1761
+ for (let c = 1; c < l.length; c++) {
1762
+ const f = l.substr(0, c), p = n.dialCode + f;
1763
+ this._addToDialCodeMap(i, p), this._addToDialCodeMap(n.iso2, p), n.partialAreaCodes || (n.partialAreaCodes = []), n.partialAreaCodes.includes(f) || n.partialAreaCodes.push(f);
1764
1764
  }
1765
- this._addToDialCodeMap(n.iso2, n.dialCode + a);
1765
+ this._addToDialCodeMap(n.iso2, n.dialCode + l);
1766
1766
  }
1767
1767
  }
1768
1768
  }
1769
1769
  }
1770
1770
  //* Generate all of the markup for the plugin: the selected country overlay, and the dropdown.
1771
1771
  _generateMarkup() {
1772
- var v;
1772
+ var _, T, G;
1773
1773
  this.telInput.classList.add("iti__tel-input"), !this.telInput.hasAttribute("autocomplete") && !(this.telInput.form && this.telInput.form.hasAttribute("autocomplete")) && this.telInput.setAttribute("autocomplete", "off");
1774
1774
  const {
1775
1775
  allowDropdown: $,
1776
1776
  separateDialCode: n,
1777
1777
  showFlags: i,
1778
1778
  containerClass: o,
1779
- hiddenInput: a,
1779
+ hiddenInput: l,
1780
1780
  dropdownContainer: c,
1781
- fixDropdownWidth: g,
1782
- useFullscreenPopup: f,
1783
- countrySearch: b,
1784
- i18n: _
1781
+ fixDropdownWidth: f,
1782
+ useFullscreenPopup: p,
1783
+ countrySearch: w,
1784
+ i18n: I
1785
1785
  } = this.options;
1786
- let I = "iti";
1787
- $ && (I += " iti--allow-dropdown"), i && (I += " iti--show-flags"), o && (I += ` ${o}`), f || (I += " iti--inline-dropdown");
1788
- const L = A("div", { class: I });
1789
- if ((v = this.telInput.parentNode) == null || v.insertBefore(L, this.telInput), $ || i || n) {
1790
- this.countryContainer = A(
1786
+ let S = "iti";
1787
+ $ && (S += " iti--allow-dropdown"), i && (S += " iti--show-flags"), o && (S += ` ${o}`), p || (S += " iti--inline-dropdown");
1788
+ const A = N("div", { class: S });
1789
+ if ((_ = this.telInput.parentNode) == null || _.insertBefore(A, this.telInput), $ || i || n) {
1790
+ this.countryContainer = N(
1791
1791
  "div",
1792
1792
  { class: "iti__country-container" },
1793
- L
1794
- ), this.showSelectedCountryOnLeft ? this.countryContainer.style.left = "0px" : this.countryContainer.style.right = "0px", $ ? (this.selectedCountry = A(
1793
+ A
1794
+ ), this.showSelectedCountryOnLeft ? this.countryContainer.style.left = "0px" : this.countryContainer.style.right = "0px", $ ? (this.selectedCountry = N(
1795
1795
  "button",
1796
1796
  {
1797
1797
  type: "button",
@@ -1803,78 +1803,85 @@ class K2 {
1803
1803
  role: "combobox"
1804
1804
  },
1805
1805
  this.countryContainer
1806
- ), this.telInput.disabled && this.selectedCountry.setAttribute("disabled", "true")) : this.selectedCountry = A(
1806
+ ), this.telInput.disabled && this.selectedCountry.setAttribute("disabled", "true")) : this.selectedCountry = N(
1807
1807
  "div",
1808
1808
  { class: "iti__selected-country" },
1809
1809
  this.countryContainer
1810
1810
  );
1811
- const N = A("div", { class: "iti__selected-country-primary" }, this.selectedCountry);
1812
- if (this.selectedCountryInner = A("div", { class: "iti__flag" }, N), this.selectedCountryA11yText = A(
1811
+ const F = N("div", { class: "iti__selected-country-primary" }, this.selectedCountry);
1812
+ if (this.selectedCountryInner = N("div", { class: "iti__flag" }, F), this.selectedCountryA11yText = N(
1813
1813
  "span",
1814
1814
  { class: "iti__a11y-text" },
1815
1815
  this.selectedCountryInner
1816
- ), $ && (this.dropdownArrow = A(
1816
+ ), $ && (this.dropdownArrow = N(
1817
1817
  "div",
1818
1818
  { class: "iti__arrow", "aria-hidden": "true" },
1819
- N
1820
- )), n && (this.selectedDialCode = A(
1819
+ F
1820
+ )), n && (this.selectedDialCode = N(
1821
1821
  "div",
1822
1822
  { class: "iti__selected-dial-code" },
1823
1823
  this.selectedCountry
1824
1824
  )), $) {
1825
- const M = g ? "" : "iti--flexible-dropdown-width";
1826
- if (this.dropdownContent = A("div", {
1825
+ const M = f ? "" : "iti--flexible-dropdown-width";
1826
+ if (this.dropdownContent = N("div", {
1827
1827
  id: `iti-${this.id}__dropdown-content`,
1828
1828
  class: `iti__dropdown-content iti__hide ${M}`
1829
- }), b && (this.searchInput = A(
1829
+ }), w && (this.searchInput = N(
1830
1830
  "input",
1831
1831
  {
1832
1832
  type: "text",
1833
1833
  class: "iti__search-input",
1834
- placeholder: _.searchPlaceholder,
1834
+ placeholder: I.searchPlaceholder,
1835
1835
  role: "combobox",
1836
1836
  "aria-expanded": "true",
1837
- "aria-label": _.searchPlaceholder,
1837
+ "aria-label": I.searchPlaceholder,
1838
1838
  "aria-controls": `iti-${this.id}__country-listbox`,
1839
1839
  "aria-autocomplete": "list",
1840
1840
  autocomplete: "off"
1841
1841
  },
1842
1842
  this.dropdownContent
1843
- ), this.searchResultsA11yText = A(
1843
+ ), this.searchResultsA11yText = N(
1844
1844
  "span",
1845
1845
  { class: "iti__a11y-text" },
1846
1846
  this.dropdownContent
1847
- )), this.countryList = A(
1847
+ )), this.countryList = N(
1848
1848
  "ul",
1849
1849
  {
1850
1850
  class: "iti__country-list",
1851
1851
  id: `iti-${this.id}__country-listbox`,
1852
1852
  role: "listbox",
1853
- "aria-label": _.countryListAriaLabel
1853
+ "aria-label": I.countryListAriaLabel
1854
1854
  },
1855
1855
  this.dropdownContent
1856
- ), this._appendListItems(), b && this._updateSearchResultsText(), c) {
1857
- let O = "iti iti--container";
1858
- f ? O += " iti--fullscreen-popup" : O += " iti--inline-dropdown", this.dropdown = A("div", { class: O }), this.dropdown.appendChild(this.dropdownContent);
1856
+ ), this._appendListItems(), w && this._updateSearchResultsText(), c) {
1857
+ let x = "iti iti--container";
1858
+ p ? x += " iti--fullscreen-popup" : x += " iti--inline-dropdown", this.dropdown = N("div", { class: x }), this.dropdown.appendChild(this.dropdownContent);
1859
1859
  } else
1860
1860
  this.countryContainer.appendChild(this.dropdownContent);
1861
1861
  }
1862
1862
  }
1863
- if (L.appendChild(this.telInput), this._updateInputPadding(), a) {
1864
- const N = this.telInput.getAttribute("name") || "", M = a(N);
1865
- M.phone && (this.hiddenInput = A("input", {
1866
- type: "hidden",
1867
- name: M.phone
1868
- }), L.appendChild(this.hiddenInput)), M.country && (this.hiddenInputCountry = A("input", {
1869
- type: "hidden",
1870
- name: M.country
1871
- }), L.appendChild(this.hiddenInputCountry));
1863
+ if (A.appendChild(this.telInput), this._updateInputPadding(), l) {
1864
+ const F = this.telInput.getAttribute("name") || "", M = l(F);
1865
+ if (M.phone) {
1866
+ const x = (T = this.telInput.form) == null ? void 0 : T.querySelector(`input[name="${M.phone}"]`);
1867
+ x ? this.hiddenInput = x : (this.hiddenInput = N("input", {
1868
+ type: "hidden",
1869
+ name: M.phone
1870
+ }), A.appendChild(this.hiddenInput));
1871
+ }
1872
+ if (M.country) {
1873
+ const x = (G = this.telInput.form) == null ? void 0 : G.querySelector(`input[name="${M.country}"]`);
1874
+ x ? this.hiddenInputCountry = x : (this.hiddenInputCountry = N("input", {
1875
+ type: "hidden",
1876
+ name: M.country
1877
+ }), A.appendChild(this.hiddenInputCountry));
1878
+ }
1872
1879
  }
1873
1880
  }
1874
1881
  //* For each country: add a country list item <li> to the countryList <ul> container.
1875
1882
  _appendListItems() {
1876
1883
  for (let $ = 0; $ < this.countries.length; $++) {
1877
- const n = this.countries[$], i = $ === 0 ? "iti__highlight" : "", o = A(
1884
+ const n = this.countries[$], i = $ === 0 ? "iti__highlight" : "", o = N(
1878
1885
  "li",
1879
1886
  {
1880
1887
  id: `iti-${this.id}__item-${n.iso2}`,
@@ -1888,22 +1895,22 @@ class K2 {
1888
1895
  this.countryList
1889
1896
  );
1890
1897
  n.nodeById[this.id] = o;
1891
- let a = "";
1892
- this.options.showFlags && (a += `<div class='iti__flag iti__${n.iso2}'></div>`), a += `<span class='iti__country-name'>${n.name}</span>`, a += `<span class='iti__dial-code'>+${n.dialCode}</span>`, o.insertAdjacentHTML("beforeend", a);
1898
+ let l = "";
1899
+ this.options.showFlags && (l += `<div class='iti__flag iti__${n.iso2}'></div>`), l += `<span class='iti__country-name'>${n.name}</span>`, l += `<span class='iti__dial-code'>+${n.dialCode}</span>`, o.insertAdjacentHTML("beforeend", l);
1893
1900
  }
1894
1901
  }
1895
1902
  //* Set the initial state of the input value and the selected country by:
1896
1903
  //* 1. Extracting a dial code from the given number
1897
1904
  //* 2. Using explicit initialCountry
1898
1905
  _setInitialState($ = !1) {
1899
- const n = this.telInput.getAttribute("value"), i = this.telInput.value, a = n && n.charAt(0) === "+" && (!i || i.charAt(0) !== "+") ? n : i, c = this._getDialCode(a), g = o2(a), { initialCountry: f, geoIpLookup: b } = this.options, _ = f === "auto" && b;
1900
- if (c && !g)
1901
- this._updateCountryFromNumber(a);
1902
- else if (!_ || $) {
1903
- const I = f ? f.toLowerCase() : "";
1904
- I && this._getCountryData(I, !0) ? this._setCountry(I) : c && g ? this._setCountry("us") : this._setCountry();
1906
+ const n = this.telInput.getAttribute("value"), i = this.telInput.value, l = n && n.charAt(0) === "+" && (!i || i.charAt(0) !== "+") ? n : i, c = this._getDialCode(l), f = o2(l), { initialCountry: p, geoIpLookup: w } = this.options, I = p === "auto" && w;
1907
+ if (c && !f)
1908
+ this._updateCountryFromNumber(l);
1909
+ else if (!I || $) {
1910
+ const S = p ? p.toLowerCase() : "";
1911
+ S && this._getCountryData(S, !0) ? this._setCountry(S) : c && f ? this._setCountry("us") : this._setCountry();
1905
1912
  }
1906
- a && this._updateValFromNumber(a);
1913
+ l && this._updateValFromNumber(l);
1907
1914
  }
1908
1915
  //* Initialise the main event listeners: input keyup, and click selected country.
1909
1916
  _initListeners() {
@@ -1938,8 +1945,8 @@ class K2 {
1938
1945
  _initRequests() {
1939
1946
  let { loadUtils: $, initialCountry: n, geoIpLookup: i } = this.options;
1940
1947
  $ && !C.utils ? (this._handlePageLoad = () => {
1941
- var a;
1942
- window.removeEventListener("load", this._handlePageLoad), (a = C.attachUtils($)) == null || a.catch(() => {
1948
+ var l;
1949
+ window.removeEventListener("load", this._handlePageLoad), (l = C.attachUtils($)) == null || l.catch(() => {
1943
1950
  });
1944
1951
  }, C.documentReady() ? this._handlePageLoad() : window.addEventListener("load", this._handlePageLoad)) : this.resolveUtilsScriptPromise(), n === "auto" && i && !this.selectedCountryData.iso2 ? this._loadAutoCountry() : this.resolveAutoCountryPromise();
1945
1952
  }
@@ -1948,10 +1955,10 @@ class K2 {
1948
1955
  C.autoCountry ? this.handleAutoCountry() : C.startedLoadingAutoCountry || (C.startedLoadingAutoCountry = !0, typeof this.options.geoIpLookup == "function" && this.options.geoIpLookup(
1949
1956
  ($ = "") => {
1950
1957
  const n = $.toLowerCase();
1951
- n && this._getCountryData(n, !0) ? (C.autoCountry = n, setTimeout(() => e1("handleAutoCountry"))) : (this._setInitialState(!0), e1("rejectAutoCountryPromise"));
1958
+ n && this._getCountryData(n, !0) ? (C.autoCountry = n, setTimeout(() => $1("handleAutoCountry"))) : (this._setInitialState(!0), $1("rejectAutoCountryPromise"));
1952
1959
  },
1953
1960
  () => {
1954
- this._setInitialState(!0), e1("rejectAutoCountryPromise");
1961
+ this._setInitialState(!0), $1("rejectAutoCountryPromise");
1955
1962
  }
1956
1963
  ));
1957
1964
  }
@@ -1960,36 +1967,36 @@ class K2 {
1960
1967
  }
1961
1968
  //* Initialize the tel input listeners.
1962
1969
  _initTelInputListeners() {
1963
- const { strictMode: $, formatAsYouType: n, separateDialCode: i, formatOnDisplay: o, allowDropdown: a, countrySearch: c } = this.options;
1964
- let g = !1;
1965
- new RegExp("\\p{L}", "u").test(this.telInput.value) && (g = !0), this._handleInputEvent = (f) => {
1966
- if (this.isAndroid && (f == null ? void 0 : f.data) === "+" && i && a && c) {
1967
- const L = this.telInput.selectionStart || 0, v = this.telInput.value.substring(0, L - 1), N = this.telInput.value.substring(L);
1968
- this.telInput.value = v + N, this._openDropdownWithPlus();
1970
+ const { strictMode: $, formatAsYouType: n, separateDialCode: i, formatOnDisplay: o, allowDropdown: l, countrySearch: c } = this.options;
1971
+ let f = !1;
1972
+ new RegExp("\\p{L}", "u").test(this.telInput.value) && (f = !0), this._handleInputEvent = (p) => {
1973
+ if (this.isAndroid && (p == null ? void 0 : p.data) === "+" && i && l && c) {
1974
+ const A = this.telInput.selectionStart || 0, _ = this.telInput.value.substring(0, A - 1), T = this.telInput.value.substring(A);
1975
+ this.telInput.value = _ + T, this._openDropdownWithPlus();
1969
1976
  return;
1970
1977
  }
1971
1978
  this._updateCountryFromNumber(this.telInput.value) && this._triggerCountryChange();
1972
- const b = (f == null ? void 0 : f.data) && /[^+0-9]/.test(f.data), _ = (f == null ? void 0 : f.inputType) === "insertFromPaste" && this.telInput.value;
1973
- b || _ && !$ ? g = !0 : /[^+0-9]/.test(this.telInput.value) || (g = !1);
1974
- const I = (f == null ? void 0 : f.detail) && f.detail.isSetNumber && !o;
1975
- if (n && !g && !I) {
1976
- const L = this.telInput.selectionStart || 0, N = this.telInput.value.substring(0, L).replace(/[^+0-9]/g, "").length, M = (f == null ? void 0 : f.inputType) === "deleteContentForward", O = this._formatNumberAsYouType(), Z = V2(N, O, L, M);
1977
- this.telInput.value = O, this.telInput.setSelectionRange(Z, Z);
1979
+ const w = (p == null ? void 0 : p.data) && /[^+0-9]/.test(p.data), I = (p == null ? void 0 : p.inputType) === "insertFromPaste" && this.telInput.value;
1980
+ w || I && !$ ? f = !0 : /[^+0-9]/.test(this.telInput.value) || (f = !1);
1981
+ const S = (p == null ? void 0 : p.detail) && p.detail.isSetNumber && !o;
1982
+ if (n && !f && !S) {
1983
+ const A = this.telInput.selectionStart || 0, T = this.telInput.value.substring(0, A).replace(/[^+0-9]/g, "").length, G = (p == null ? void 0 : p.inputType) === "deleteContentForward", F = this._formatNumberAsYouType(), M = V2(T, F, A, G);
1984
+ this.telInput.value = F, this.telInput.setSelectionRange(M, M);
1978
1985
  }
1979
- }, this.telInput.addEventListener("input", this._handleInputEvent), ($ || i) && (this._handleKeydownEvent = (f) => {
1980
- if (f.key && f.key.length === 1 && !f.altKey && !f.ctrlKey && !f.metaKey) {
1981
- if (i && a && c && f.key === "+") {
1982
- f.preventDefault(), this._openDropdownWithPlus();
1986
+ }, this.telInput.addEventListener("input", this._handleInputEvent), ($ || i) && (this._handleKeydownEvent = (p) => {
1987
+ if (p.key && p.key.length === 1 && !p.altKey && !p.ctrlKey && !p.metaKey) {
1988
+ if (i && l && c && p.key === "+") {
1989
+ p.preventDefault(), this._openDropdownWithPlus();
1983
1990
  return;
1984
1991
  }
1985
1992
  if ($) {
1986
- const b = this.telInput.value, _ = b.charAt(0) === "+", I = !_ && this.telInput.selectionStart === 0 && f.key === "+", L = /^[0-9]$/.test(f.key), v = i ? L : I || L, N = b.slice(0, this.telInput.selectionStart) + f.key + b.slice(this.telInput.selectionEnd), M = this._getFullNumber(N), O = C.utils.getCoreNumber(M, this.selectedCountryData.iso2), Z = this.maxCoreNumberLength && O.length > this.maxCoreNumberLength;
1987
- let $1 = !1;
1988
- if (_) {
1993
+ const w = this.telInput.value, I = w.charAt(0) === "+", S = !I && this.telInput.selectionStart === 0 && p.key === "+", A = /^[0-9]$/.test(p.key), _ = i ? A : S || A, T = w.slice(0, this.telInput.selectionStart) + p.key + w.slice(this.telInput.selectionEnd), G = this._getFullNumber(T), F = C.utils.getCoreNumber(G, this.selectedCountryData.iso2), M = this.maxCoreNumberLength && F.length > this.maxCoreNumberLength;
1994
+ let x = !1;
1995
+ if (I) {
1989
1996
  const f1 = this.selectedCountryData.iso2;
1990
- $1 = this._getCountryFromNumber(M) !== f1;
1997
+ x = this._getCountryFromNumber(G) !== f1;
1991
1998
  }
1992
- (!v || Z && !$1 && !I) && f.preventDefault();
1999
+ (!_ || M && !x && !S) && p.preventDefault();
1993
2000
  }
1994
2001
  }
1995
2002
  }, this.telInput.addEventListener("keydown", this._handleKeydownEvent));
@@ -2028,15 +2035,15 @@ class K2 {
2028
2035
  _bindDropdownListeners() {
2029
2036
  this._handleMouseoverCountryList = (o) => {
2030
2037
  var c;
2031
- const a = (c = o.target) == null ? void 0 : c.closest(".iti__country");
2032
- a && this._highlightListItem(a, !1);
2038
+ const l = (c = o.target) == null ? void 0 : c.closest(".iti__country");
2039
+ l && this._highlightListItem(l, !1);
2033
2040
  }, this.countryList.addEventListener(
2034
2041
  "mouseover",
2035
2042
  this._handleMouseoverCountryList
2036
2043
  ), this._handleClickCountryList = (o) => {
2037
2044
  var c;
2038
- const a = (c = o.target) == null ? void 0 : c.closest(".iti__country");
2039
- a && this._selectListItem(a);
2045
+ const l = (c = o.target) == null ? void 0 : c.closest(".iti__country");
2046
+ l && this._selectListItem(l);
2040
2047
  }, this.countryList.addEventListener("click", this._handleClickCountryList);
2041
2048
  let $ = !0;
2042
2049
  this._handleClickOffToClose = () => {
@@ -2055,10 +2062,10 @@ class K2 {
2055
2062
  const c = this.searchInput.value.trim();
2056
2063
  c ? this._filterCountries(c) : this._filterCountries("", !0);
2057
2064
  };
2058
- let a = null;
2065
+ let l = null;
2059
2066
  this._handleSearchChange = () => {
2060
- a && clearTimeout(a), a = setTimeout(() => {
2061
- o(), a = null;
2067
+ l && clearTimeout(l), l = setTimeout(() => {
2068
+ o(), l = null;
2062
2069
  }, 100);
2063
2070
  }, this.searchInput.addEventListener("input", this._handleSearchChange), this.searchInput.addEventListener("click", (c) => c.stopPropagation());
2064
2071
  }
@@ -2068,8 +2075,8 @@ class K2 {
2068
2075
  for (let n = 0; n < this.countries.length; n++) {
2069
2076
  const i = this.countries[n];
2070
2077
  if (i.name.substr(0, $.length).toLowerCase() === $) {
2071
- const a = i.nodeById[this.id];
2072
- this._highlightListItem(a, !1), this._scrollTo(a);
2078
+ const l = i.nodeById[this.id];
2079
+ this._highlightListItem(l, !1), this._scrollTo(l);
2073
2080
  break;
2074
2081
  }
2075
2082
  }
@@ -2079,11 +2086,11 @@ class K2 {
2079
2086
  let i = !0;
2080
2087
  this.countryList.innerHTML = "";
2081
2088
  const o = s2($);
2082
- for (let a = 0; a < this.countries.length; a++) {
2083
- const c = this.countries[a], g = s2(c.name), f = c.name.split(/[^a-zA-ZÀ-ÿа-яА-Я]/).map((_) => _[0]).join("").toLowerCase(), b = `+${c.dialCode}`;
2084
- if (n || g.includes(o) || b.includes(o) || c.iso2.includes(o) || f.includes(o)) {
2085
- const _ = c.nodeById[this.id];
2086
- _ && this.countryList.appendChild(_), i && (this._highlightListItem(_, !1), i = !1);
2089
+ for (let l = 0; l < this.countries.length; l++) {
2090
+ const c = this.countries[l], f = s2(c.name), p = c.name.split(/[^a-zA-ZÀ-ÿа-яА-Я]/).map((I) => I[0]).join("").toLowerCase(), w = `+${c.dialCode}`;
2091
+ if (n || f.includes(o) || w.includes(o) || c.iso2.includes(o) || p.includes(o)) {
2092
+ const I = c.nodeById[this.id];
2093
+ I && this.countryList.appendChild(I), i && (this._highlightListItem(I, !1), i = !1);
2087
2094
  }
2088
2095
  }
2089
2096
  i && this._highlightListItem(null, !1), this.countryList.scrollTop = 0, this._updateSearchResultsText();
@@ -2109,7 +2116,7 @@ class K2 {
2109
2116
  _updateValFromNumber($) {
2110
2117
  let n = $;
2111
2118
  if (this.options.formatOnDisplay && C.utils && this.selectedCountryData) {
2112
- const i = this.options.nationalMode || n.charAt(0) !== "+" && !this.options.separateDialCode, { NATIONAL: o, INTERNATIONAL: a } = C.utils.numberFormat, c = i ? o : a;
2119
+ const i = this.options.nationalMode || n.charAt(0) !== "+" && !this.options.separateDialCode, { NATIONAL: o, INTERNATIONAL: l } = C.utils.numberFormat, c = i ? o : l;
2113
2120
  n = C.utils.formatNumber(
2114
2121
  n,
2115
2122
  this.selectedCountryData.iso2,
@@ -2124,21 +2131,27 @@ class K2 {
2124
2131
  const n = this._getCountryFromNumber($);
2125
2132
  return n !== null ? this._setCountry(n) : !1;
2126
2133
  }
2134
+ //* Check if the given number matches an area code from the selected country.
2135
+ _isAreaCodeMatch($, n) {
2136
+ const { areaCodes: i, partialAreaCodes: o, dialCode: l } = this.selectedCountryData, c = $.substring(l.length), f = n.substring(l.length);
2137
+ return !!(i.includes(f) || o.includes(c));
2138
+ }
2127
2139
  _getCountryFromNumber($) {
2128
2140
  const n = $.indexOf("+");
2129
2141
  let i = n ? $.substring(n) : $;
2130
2142
  const o = this.selectedCountryData.dialCode;
2131
2143
  i && o === "1" && i.charAt(0) !== "+" && (i.charAt(0) !== "1" && (i = `1${i}`), i = `+${i}`), this.options.separateDialCode && o && i.charAt(0) !== "+" && (i = `+${o}${i}`);
2132
- const c = this._getDialCode(i, !0), g = c1(i);
2144
+ const c = this._getDialCode(i, !0), f = c1(i);
2133
2145
  if (c) {
2134
- const f = this.dialCodeToIso2Map[c1(c)], b = f.indexOf(this.selectedCountryData.iso2) !== -1 && g.length <= c.length - 1;
2135
- if (!(o === "1" && o2(g)) && !b) {
2136
- for (let I = 0; I < f.length; I++)
2137
- if (f[I])
2138
- return f[I];
2146
+ const p = c1(c), w = this.dialCodeToIso2Map[p], I = this.selectedCountryData.iso2 && w.includes(this.selectedCountryData.iso2);
2147
+ let S = !1;
2148
+ if (I && (this.selectedCountryData.areaCodes && f.length > o.length ? S = this._isAreaCodeMatch(f, p) : S = !0), !(o === "1" && o2(f)) && (!I || !S)) {
2149
+ for (let _ = 0; _ < w.length; _++)
2150
+ if (w[_])
2151
+ return w[_];
2139
2152
  }
2140
2153
  } else {
2141
- if (i.charAt(0) === "+" && g.length)
2154
+ if (i.charAt(0) === "+" && f.length)
2142
2155
  return "";
2143
2156
  if ((!i || i === "+") && !this.selectedCountryData.iso2)
2144
2157
  return this.defaultCountry;
@@ -2168,16 +2181,16 @@ class K2 {
2168
2181
  //* Update the selected country, dial code (if separateDialCode), placeholder, title, and active list item.
2169
2182
  //* Note: called from _setInitialState, _updateCountryFromNumber, _selectListItem, setCountry.
2170
2183
  _setCountry($) {
2171
- const { separateDialCode: n, showFlags: i, i18n: o } = this.options, a = this.selectedCountryData.iso2 ? this.selectedCountryData : {};
2184
+ const { separateDialCode: n, showFlags: i, i18n: o } = this.options, l = this.selectedCountryData.iso2 ? this.selectedCountryData : {};
2172
2185
  if (this.selectedCountryData = $ ? this._getCountryData($, !1) || {} : {}, this.selectedCountryData.iso2 && (this.defaultCountry = this.selectedCountryData.iso2), this.selectedCountryInner) {
2173
- let c = "", g = "";
2174
- $ && i ? (c = `iti__flag iti__${$}`, g = `${this.selectedCountryData.name} +${this.selectedCountryData.dialCode}`) : (c = "iti__flag iti__globe", g = o.noCountrySelected), this.selectedCountryInner.className = c, this.selectedCountryA11yText.textContent = g;
2186
+ let c = "", f = "";
2187
+ $ && i ? (c = `iti__flag iti__${$}`, f = `${this.selectedCountryData.name} +${this.selectedCountryData.dialCode}`) : (c = "iti__flag iti__globe", f = o.noCountrySelected), this.selectedCountryInner.className = c, this.selectedCountryA11yText.textContent = f;
2175
2188
  }
2176
2189
  if (this._setSelectedCountryTitleAttribute($, n), n) {
2177
2190
  const c = this.selectedCountryData.dialCode ? `+${this.selectedCountryData.dialCode}` : "";
2178
2191
  this.selectedDialCode.innerHTML = c, this._updateInputPadding();
2179
2192
  }
2180
- return this._updatePlaceholder(), this._updateMaxLength(), a.iso2 !== $;
2193
+ return this._updatePlaceholder(), this._updateMaxLength(), l.iso2 !== $;
2181
2194
  }
2182
2195
  //* Update the input padding to make space for the selected country/dial code.
2183
2196
  _updateInputPadding() {
@@ -2191,17 +2204,17 @@ class K2 {
2191
2204
  const { strictMode: $, placeholderNumberType: n, validationNumberTypes: i } = this.options, { iso2: o } = this.selectedCountryData;
2192
2205
  if ($ && C.utils)
2193
2206
  if (o) {
2194
- const a = C.utils.numberType[n];
2207
+ const l = C.utils.numberType[n];
2195
2208
  let c = C.utils.getExampleNumber(
2196
2209
  o,
2197
2210
  !1,
2198
- a,
2211
+ l,
2199
2212
  !0
2200
- ), g = c;
2213
+ ), f = c;
2201
2214
  for (; C.utils.isPossibleNumber(c, o, i); )
2202
- g = c, c += "0";
2203
- const f = C.utils.getCoreNumber(g, o);
2204
- this.maxCoreNumberLength = f.length, o === "by" && (this.maxCoreNumberLength = f.length + 1);
2215
+ f = c, c += "0";
2216
+ const p = C.utils.getCoreNumber(f, o);
2217
+ this.maxCoreNumberLength = p.length, o === "by" && (this.maxCoreNumberLength = p.length + 1);
2205
2218
  } else
2206
2219
  this.maxCoreNumberLength = null;
2207
2220
  }
@@ -2235,15 +2248,15 @@ class K2 {
2235
2248
  placeholderNumberType: n,
2236
2249
  nationalMode: i,
2237
2250
  customPlaceholder: o
2238
- } = this.options, a = $ === "aggressive" || !this.hadInitialPlaceholder && $ === "polite";
2239
- if (C.utils && a) {
2251
+ } = this.options, l = $ === "aggressive" || !this.hadInitialPlaceholder && $ === "polite";
2252
+ if (C.utils && l) {
2240
2253
  const c = C.utils.numberType[n];
2241
- let g = this.selectedCountryData.iso2 ? C.utils.getExampleNumber(
2254
+ let f = this.selectedCountryData.iso2 ? C.utils.getExampleNumber(
2242
2255
  this.selectedCountryData.iso2,
2243
2256
  i,
2244
2257
  c
2245
2258
  ) : "";
2246
- g = this._beforeSetNumber(g), typeof o == "function" && (g = o(g, this.selectedCountryData)), this.telInput.setAttribute("placeholder", g);
2259
+ f = this._beforeSetNumber(f), typeof o == "function" && (f = o(f, this.selectedCountryData)), this.telInput.setAttribute("placeholder", f);
2247
2260
  }
2248
2261
  }
2249
2262
  //* Called when the user selects a list item from the dropdown.
@@ -2265,12 +2278,12 @@ class K2 {
2265
2278
  }
2266
2279
  //* Check if an element is visible within it's container, else scroll until it is.
2267
2280
  _scrollTo($) {
2268
- const n = this.countryList, i = document.documentElement.scrollTop, o = n.offsetHeight, a = n.getBoundingClientRect().top + i, c = a + o, g = $.offsetHeight, f = $.getBoundingClientRect().top + i, b = f + g, _ = f - a + n.scrollTop;
2269
- if (f < a)
2270
- n.scrollTop = _;
2271
- else if (b > c) {
2272
- const I = o - g;
2273
- n.scrollTop = _ - I;
2281
+ const n = this.countryList, i = document.documentElement.scrollTop, o = n.offsetHeight, l = n.getBoundingClientRect().top + i, c = l + o, f = $.offsetHeight, p = $.getBoundingClientRect().top + i, w = p + f, I = p - l + n.scrollTop;
2282
+ if (p < l)
2283
+ n.scrollTop = I;
2284
+ else if (w > c) {
2285
+ const S = o - f;
2286
+ n.scrollTop = I - S;
2274
2287
  }
2275
2288
  }
2276
2289
  //* Replace any existing dial code with the new one
@@ -2279,8 +2292,8 @@ class K2 {
2279
2292
  const n = this.telInput.value, i = `+${$}`;
2280
2293
  let o;
2281
2294
  if (n.charAt(0) === "+") {
2282
- const a = this._getDialCode(n);
2283
- a ? o = n.replace(a, i) : o = i, this.telInput.value = o;
2295
+ const l = this._getDialCode(n);
2296
+ l ? o = n.replace(l, i) : o = i, this.telInput.value = o;
2284
2297
  }
2285
2298
  }
2286
2299
  //* Try and extract a valid international dial code from a full telephone number.
@@ -2289,13 +2302,13 @@ class K2 {
2289
2302
  let i = "";
2290
2303
  if ($.charAt(0) === "+") {
2291
2304
  let o = "";
2292
- for (let a = 0; a < $.length; a++) {
2293
- const c = $.charAt(a);
2305
+ for (let l = 0; l < $.length; l++) {
2306
+ const c = $.charAt(l);
2294
2307
  if (!isNaN(parseInt(c, 10))) {
2295
2308
  if (o += c, n)
2296
- this.dialCodeToIso2Map[o] && (i = $.substr(0, a + 1));
2309
+ this.dialCodeToIso2Map[o] && (i = $.substr(0, l + 1));
2297
2310
  else if (this.dialCodes[o]) {
2298
- i = $.substr(0, a + 1);
2311
+ i = $.substr(0, l + 1);
2299
2312
  break;
2300
2313
  }
2301
2314
  if (o.length === this.dialCodeMaxLen)
@@ -2309,8 +2322,8 @@ class K2 {
2309
2322
  _getFullNumber($) {
2310
2323
  const n = $ || this.telInput.value.trim(), { dialCode: i } = this.selectedCountryData;
2311
2324
  let o;
2312
- const a = c1(n);
2313
- return this.options.separateDialCode && n.charAt(0) !== "+" && i && a ? o = `+${i}` : o = "", o + n;
2325
+ const l = c1(n);
2326
+ return this.options.separateDialCode && n.charAt(0) !== "+" && i && l ? o = `+${i}` : o = "", o + n;
2314
2327
  }
2315
2328
  //* Remove the dial code if separateDialCode is enabled also cap the length if the input has a maxlength attribute
2316
2329
  _beforeSetNumber($) {
@@ -2350,7 +2363,7 @@ class K2 {
2350
2363
  //********************
2351
2364
  //* Remove plugin.
2352
2365
  destroy() {
2353
- var a, c;
2366
+ var l, c;
2354
2367
  const { allowDropdown: $, separateDialCode: n } = this.options;
2355
2368
  if ($) {
2356
2369
  this._closeDropdown(), this.selectedCountry.removeEventListener(
@@ -2360,13 +2373,13 @@ class K2 {
2360
2373
  "keydown",
2361
2374
  this._handleCountryContainerKeydown
2362
2375
  );
2363
- const g = this.telInput.closest("label");
2364
- g && g.removeEventListener("click", this._handleLabelClick);
2376
+ const f = this.telInput.closest("label");
2377
+ f && f.removeEventListener("click", this._handleLabelClick);
2365
2378
  }
2366
2379
  const { form: i } = this.telInput;
2367
2380
  this._handleHiddenInputSubmit && i && i.removeEventListener("submit", this._handleHiddenInputSubmit), this.telInput.removeEventListener("input", this._handleInputEvent), this._handleKeydownEvent && this.telInput.removeEventListener("keydown", this._handleKeydownEvent), this.telInput.removeAttribute("data-intl-tel-input-id"), n && (this.isRTL ? this.telInput.style.paddingRight = this.originalPaddingRight : this.telInput.style.paddingLeft = this.originalPaddingLeft);
2368
2381
  const o = this.telInput.parentNode;
2369
- (a = o == null ? void 0 : o.parentNode) == null || a.insertBefore(this.telInput, o), (c = o == null ? void 0 : o.parentNode) == null || c.removeChild(o), delete C.instances[this.id];
2382
+ (l = o == null ? void 0 : o.parentNode) == null || l.insertBefore(this.telInput, o), (c = o == null ? void 0 : o.parentNode) == null || c.removeChild(o), delete C.instances[this.id];
2370
2383
  }
2371
2384
  //* Get the extension from the current number.
2372
2385
  getExtension() {
@@ -2412,8 +2425,8 @@ class K2 {
2412
2425
  return !1;
2413
2426
  const $ = this._getFullNumber(), n = $.search(new RegExp("\\p{L}", "u"));
2414
2427
  if (n > -1) {
2415
- const i = $.substring(0, n), o = this._utilsIsPossibleNumber(i), a = this._utilsIsPossibleNumber($);
2416
- return o && a;
2428
+ const i = $.substring(0, n), o = this._utilsIsPossibleNumber(i), l = this._utilsIsPossibleNumber($);
2429
+ return o && l;
2417
2430
  }
2418
2431
  return this._utilsIsPossibleNumber($);
2419
2432
  }
@@ -2426,8 +2439,8 @@ class K2 {
2426
2439
  return !1;
2427
2440
  const $ = this._getFullNumber(), n = $.search(new RegExp("\\p{L}", "u"));
2428
2441
  if (n > -1) {
2429
- const i = $.substring(0, n), o = this._utilsIsValidNumber(i), a = this._utilsIsValidNumber($);
2430
- return o && a;
2442
+ const i = $.substring(0, n), o = this._utilsIsValidNumber(i), l = this._utilsIsValidNumber($);
2443
+ return o && l;
2431
2444
  }
2432
2445
  return this._utilsIsValidNumber($);
2433
2446
  }
@@ -2467,9 +2480,9 @@ const H2 = (y) => {
2467
2480
  const i = n == null ? void 0 : n.default;
2468
2481
  if (!i || typeof i != "object")
2469
2482
  throw new TypeError("The loader function passed to attachUtils did not resolve to a module object with utils as its default export.");
2470
- return C.utils = i, e1("handleUtils"), !0;
2483
+ return C.utils = i, $1("handleUtils"), !0;
2471
2484
  }).catch((n) => {
2472
- throw e1("rejectUtilsScriptPromise", n), n;
2485
+ throw $1("rejectUtilsScriptPromise", n), n;
2473
2486
  });
2474
2487
  }
2475
2488
  return null;
@@ -2479,11 +2492,11 @@ const H2 = (y) => {
2479
2492
  return n._init(), y.setAttribute("data-intl-tel-input-id", n.id.toString()), C.instances[n.id] = n, n;
2480
2493
  },
2481
2494
  {
2482
- defaults: l2,
2495
+ defaults: a2,
2483
2496
  //* Using a static var like this allows us to mock it in the tests.
2484
2497
  documentReady: () => document.readyState === "complete",
2485
2498
  //* Get the country data object.
2486
- getCountryData: () => H,
2499
+ getCountryData: () => W,
2487
2500
  //* A getter for the plugin instance.
2488
2501
  getInstance: (y) => {
2489
2502
  const $ = y.getAttribute("data-intl-tel-input-id");
@@ -2494,7 +2507,7 @@ const H2 = (y) => {
2494
2507
  attachUtils: H2,
2495
2508
  startedLoadingUtilsScript: !1,
2496
2509
  startedLoadingAutoCountry: !1,
2497
- version: "25.0.0"
2510
+ version: "25.0.2"
2498
2511
  }
2499
2512
  );
2500
2513
  (function() {
@@ -2509,8 +2522,8 @@ const H2 = (y) => {
2509
2522
  function e() {
2510
2523
  }
2511
2524
  e.prototype = t.prototype, d.ma = t.prototype, d.prototype = new e(), d.prototype.constructor = d, d.sa = function(r, s, u) {
2512
- for (var l = Array(arguments.length - 2), h = 2; h < arguments.length; h++) l[h - 2] = arguments[h];
2513
- return t.prototype[s].apply(r, l);
2525
+ for (var a = Array(arguments.length - 2), h = 2; h < arguments.length; h++) a[h - 2] = arguments[h];
2526
+ return t.prototype[s].apply(r, a);
2514
2527
  };
2515
2528
  }
2516
2529
  function i(d) {
@@ -2521,16 +2534,16 @@ const H2 = (y) => {
2521
2534
  }
2522
2535
  var o = class {
2523
2536
  constructor(d) {
2524
- if (a !== a) throw Error("SafeUrl is not meant to be built directly");
2537
+ if (l !== l) throw Error("SafeUrl is not meant to be built directly");
2525
2538
  this.g = d;
2526
2539
  }
2527
2540
  toString() {
2528
2541
  return this.g.toString();
2529
2542
  }
2530
- }, a = {};
2543
+ }, l = {};
2531
2544
  new o("about:invalid#zClosurez"), new o("about:blank");
2532
2545
  const c = {};
2533
- class g {
2546
+ class f {
2534
2547
  constructor() {
2535
2548
  if (c !== c) throw Error("SafeStyle is not meant to be built directly");
2536
2549
  }
@@ -2538,84 +2551,84 @@ const H2 = (y) => {
2538
2551
  return "";
2539
2552
  }
2540
2553
  }
2541
- new g();
2542
- const f = {};
2543
- class b {
2554
+ new f();
2555
+ const p = {};
2556
+ class w {
2544
2557
  constructor() {
2545
- if (f !== f) throw Error("SafeStyleSheet is not meant to be built directly");
2558
+ if (p !== p) throw Error("SafeStyleSheet is not meant to be built directly");
2546
2559
  }
2547
2560
  toString() {
2548
2561
  return "";
2549
2562
  }
2550
2563
  }
2551
- new b();
2552
- const _ = {};
2553
- class I {
2564
+ new w();
2565
+ const I = {};
2566
+ class S {
2554
2567
  constructor() {
2555
2568
  var t = y.trustedTypes && y.trustedTypes.emptyHTML || "";
2556
- if (_ !== _) throw Error("SafeHtml is not meant to be built directly");
2569
+ if (I !== I) throw Error("SafeHtml is not meant to be built directly");
2557
2570
  this.g = t;
2558
2571
  }
2559
2572
  toString() {
2560
2573
  return this.g.toString();
2561
2574
  }
2562
2575
  }
2563
- new I();
2564
- function L(d, t) {
2576
+ new S();
2577
+ function A(d, t) {
2565
2578
  switch (this.g = d, this.l = !!t.aa, this.h = t.i, this.s = t.type, this.o = !1, this.h) {
2579
+ case G:
2580
+ case F:
2566
2581
  case M:
2567
- case O:
2568
- case Z:
2569
- case $1:
2582
+ case x:
2570
2583
  case f1:
2571
- case N:
2572
- case v:
2584
+ case T:
2585
+ case _:
2573
2586
  this.o = !0;
2574
2587
  }
2575
2588
  this.j = t.defaultValue;
2576
2589
  }
2577
- var v = 1, N = 2, M = 3, O = 4, Z = 6, $1 = 16, f1 = 18;
2590
+ var _ = 1, T = 2, G = 3, F = 4, M = 6, x = 16, f1 = 18;
2578
2591
  function v1(d, t) {
2579
2592
  for (this.h = d, this.g = {}, d = 0; d < t.length; d++) {
2580
2593
  var e = t[d];
2581
2594
  this.g[e.g] = e;
2582
2595
  }
2583
2596
  }
2584
- function a2(d) {
2597
+ function l2(d) {
2585
2598
  return d = i(d.g), d.sort(function(t, e) {
2586
2599
  return t.g - e.g;
2587
2600
  }), d;
2588
2601
  }
2589
- function x() {
2602
+ function R() {
2590
2603
  this.h = {}, this.j = this.m().g, this.g = this.l = null;
2591
2604
  }
2592
- x.prototype.has = function(d) {
2593
- return R(this, d.g);
2594
- }, x.prototype.get = function(d, t) {
2595
- return p(this, d.g, t);
2596
- }, x.prototype.set = function(d, t) {
2605
+ R.prototype.has = function(d) {
2606
+ return B(this, d.g);
2607
+ }, R.prototype.get = function(d, t) {
2608
+ return g(this, d.g, t);
2609
+ }, R.prototype.set = function(d, t) {
2597
2610
  E(this, d.g, t);
2598
- }, x.prototype.add = function(d, t) {
2611
+ }, R.prototype.add = function(d, t) {
2599
2612
  w1(this, d.g, t);
2600
2613
  };
2601
2614
  function S1(d, t) {
2602
- for (var e = a2(d.m()), r = 0; r < e.length; r++) {
2615
+ for (var e = l2(d.m()), r = 0; r < e.length; r++) {
2603
2616
  var s = e[r], u = s.g;
2604
- if (R(t, u)) {
2617
+ if (B(t, u)) {
2605
2618
  d.g && delete d.g[s.g];
2606
- var l = s.h == 11 || s.h == 10;
2619
+ var a = s.h == 11 || s.h == 10;
2607
2620
  if (s.l) {
2608
2621
  s = P(t, u);
2609
- for (var h = 0; h < s.length; h++) w1(d, u, l ? s[h].clone() : s[h]);
2610
- } else s = n1(t, u), l ? (l = n1(d, u)) ? S1(l, s) : E(d, u, s.clone()) : E(d, u, s);
2622
+ for (var h = 0; h < s.length; h++) w1(d, u, a ? s[h].clone() : s[h]);
2623
+ } else s = n1(t, u), a ? (a = n1(d, u)) ? S1(a, s) : E(d, u, s.clone()) : E(d, u, s);
2611
2624
  }
2612
2625
  }
2613
2626
  }
2614
- x.prototype.clone = function() {
2627
+ R.prototype.clone = function() {
2615
2628
  var d = new this.constructor();
2616
2629
  return d != this && (d.h = {}, d.g && (d.g = {}), S1(d, this)), d;
2617
2630
  };
2618
- function R(d, t) {
2631
+ function B(d, t) {
2619
2632
  return d.h[t] != null;
2620
2633
  }
2621
2634
  function n1(d, t) {
@@ -2625,7 +2638,7 @@ const H2 = (y) => {
2625
2638
  if (!(t in d.g)) {
2626
2639
  var r = d.l, s = d.j[t];
2627
2640
  if (e != null) if (s.l) {
2628
- for (var u = [], l = 0; l < e.length; l++) u[l] = r.h(s, e[l]);
2641
+ for (var u = [], a = 0; a < e.length; a++) u[a] = r.h(s, e[a]);
2629
2642
  e = u;
2630
2643
  } else e = r.h(s, e);
2631
2644
  return d.g[t] = e;
@@ -2634,12 +2647,12 @@ const H2 = (y) => {
2634
2647
  }
2635
2648
  return e;
2636
2649
  }
2637
- function p(d, t, e) {
2650
+ function g(d, t, e) {
2638
2651
  var r = n1(d, t);
2639
2652
  return d.j[t].l ? r[e || 0] : r;
2640
2653
  }
2641
- function S(d, t) {
2642
- if (R(d, t)) d = p(d, t);
2654
+ function v(d, t) {
2655
+ if (B(d, t)) d = g(d, t);
2643
2656
  else d: {
2644
2657
  if (d = d.j[t], d.j === void 0) if (t = d.s, t === Boolean) d.j = !1;
2645
2658
  else if (t === Number) d.j = 0;
@@ -2655,8 +2668,8 @@ const H2 = (y) => {
2655
2668
  function P(d, t) {
2656
2669
  return n1(d, t) || [];
2657
2670
  }
2658
- function U(d, t) {
2659
- return d.j[t].l ? R(d, t) ? d.h[t].length : 0 : R(d, t) ? 1 : 0;
2671
+ function K(d, t) {
2672
+ return d.j[t].l ? B(d, t) ? d.h[t].length : 0 : B(d, t) ? 1 : 0;
2660
2673
  }
2661
2674
  function E(d, t, e) {
2662
2675
  d.h[t] = e, d.g && (d.g[t] = e);
@@ -2666,7 +2679,7 @@ const H2 = (y) => {
2666
2679
  }
2667
2680
  function i1(d, t) {
2668
2681
  var e = [], r;
2669
- for (r in t) r != 0 && e.push(new L(r, t[r]));
2682
+ for (r in t) r != 0 && e.push(new A(r, t[r]));
2670
2683
  return new v1(d, e);
2671
2684
  }
2672
2685
  function r1() {
@@ -2674,7 +2687,7 @@ const H2 = (y) => {
2674
2687
  r1.prototype.g = function(d) {
2675
2688
  throw new d.h(), Error("Unimplemented");
2676
2689
  }, r1.prototype.h = function(d, t) {
2677
- if (d.h == 11 || d.h == 10) return t instanceof x ? t : this.g(d.s.prototype.m(), t);
2690
+ if (d.h == 11 || d.h == 10) return t instanceof R ? t : this.g(d.s.prototype.m(), t);
2678
2691
  if (d.h == 14) return typeof t == "string" && b1.test(t) && (d = Number(t), 0 < d) ? d : t;
2679
2692
  if (!d.o) return t;
2680
2693
  if (d = d.s, d === String) {
@@ -2688,70 +2701,70 @@ const H2 = (y) => {
2688
2701
  n(p1, r1), p1.prototype.g = function(d, t) {
2689
2702
  return d = new d.h(), d.l = this, d.h = t, d.g = {}, d;
2690
2703
  };
2691
- function J() {
2704
+ function q() {
2692
2705
  }
2693
- n(J, p1), J.prototype.h = function(d, t) {
2706
+ n(q, p1), q.prototype.h = function(d, t) {
2694
2707
  return d.h == 8 ? !!t : r1.prototype.h.apply(this, arguments);
2695
- }, J.prototype.g = function(d, t) {
2696
- return J.ma.g.call(this, d, t);
2708
+ }, q.prototype.g = function(d, t) {
2709
+ return q.ma.g.call(this, d, t);
2697
2710
  };
2698
- function T(d, t) {
2711
+ function L(d, t) {
2699
2712
  d != null && this.g.apply(this, arguments);
2700
2713
  }
2701
- T.prototype.h = "", T.prototype.set = function(d) {
2714
+ L.prototype.h = "", L.prototype.set = function(d) {
2702
2715
  this.h = "" + d;
2703
- }, T.prototype.g = function(d, t, e) {
2716
+ }, L.prototype.g = function(d, t, e) {
2704
2717
  if (this.h += String(d), t != null) for (let r = 1; r < arguments.length; r++) this.h += arguments[r];
2705
2718
  return this;
2706
2719
  };
2707
- function B(d) {
2720
+ function k(d) {
2708
2721
  d.h = "";
2709
2722
  }
2710
- T.prototype.toString = function() {
2723
+ L.prototype.toString = function() {
2711
2724
  return this.h;
2712
2725
  };
2713
- function j() {
2714
- x.call(this);
2726
+ function z() {
2727
+ R.call(this);
2728
+ }
2729
+ n(z, R);
2730
+ var A1 = null;
2731
+ function b() {
2732
+ R.call(this);
2715
2733
  }
2716
- n(j, x);
2734
+ n(b, R);
2717
2735
  var L1 = null;
2718
- function w() {
2719
- x.call(this);
2736
+ function Z() {
2737
+ R.call(this);
2720
2738
  }
2721
- n(w, x);
2739
+ n(Z, R);
2722
2740
  var N1 = null;
2723
- function W() {
2724
- x.call(this);
2725
- }
2726
- n(W, x);
2727
- var T1 = null;
2728
- j.prototype.m = function() {
2741
+ z.prototype.m = function() {
2742
+ var d = A1;
2743
+ return d || (A1 = d = i1(z, { 0: { name: "NumberFormat", ia: "i18n.phonenumbers.NumberFormat" }, 1: { name: "pattern", required: !0, i: 9, type: String }, 2: { name: "format", required: !0, i: 9, type: String }, 3: { name: "leading_digits_pattern", aa: !0, i: 9, type: String }, 4: { name: "national_prefix_formatting_rule", i: 9, type: String }, 6: { name: "national_prefix_optional_when_formatting", i: 8, defaultValue: !1, type: Boolean }, 5: { name: "domestic_carrier_code_formatting_rule", i: 9, type: String } })), d;
2744
+ }, z.m = z.prototype.m, b.prototype.m = function() {
2729
2745
  var d = L1;
2730
- return d || (L1 = d = i1(j, { 0: { name: "NumberFormat", ia: "i18n.phonenumbers.NumberFormat" }, 1: { name: "pattern", required: !0, i: 9, type: String }, 2: { name: "format", required: !0, i: 9, type: String }, 3: { name: "leading_digits_pattern", aa: !0, i: 9, type: String }, 4: { name: "national_prefix_formatting_rule", i: 9, type: String }, 6: { name: "national_prefix_optional_when_formatting", i: 8, defaultValue: !1, type: Boolean }, 5: { name: "domestic_carrier_code_formatting_rule", i: 9, type: String } })), d;
2731
- }, j.m = j.prototype.m, w.prototype.m = function() {
2746
+ return d || (L1 = d = i1(b, { 0: { name: "PhoneNumberDesc", ia: "i18n.phonenumbers.PhoneNumberDesc" }, 2: { name: "national_number_pattern", i: 9, type: String }, 9: { name: "possible_length", aa: !0, i: 5, type: Number }, 10: { name: "possible_length_local_only", aa: !0, i: 5, type: Number }, 6: { name: "example_number", i: 9, type: String } })), d;
2747
+ }, b.m = b.prototype.m, Z.prototype.m = function() {
2732
2748
  var d = N1;
2733
- return d || (N1 = d = i1(w, { 0: { name: "PhoneNumberDesc", ia: "i18n.phonenumbers.PhoneNumberDesc" }, 2: { name: "national_number_pattern", i: 9, type: String }, 9: { name: "possible_length", aa: !0, i: 5, type: Number }, 10: { name: "possible_length_local_only", aa: !0, i: 5, type: Number }, 6: { name: "example_number", i: 9, type: String } })), d;
2734
- }, w.m = w.prototype.m, W.prototype.m = function() {
2735
- var d = T1;
2736
- return d || (T1 = d = i1(W, {
2749
+ return d || (N1 = d = i1(Z, {
2737
2750
  0: { name: "PhoneMetadata", ia: "i18n.phonenumbers.PhoneMetadata" },
2738
- 1: { name: "general_desc", i: 11, type: w },
2739
- 2: { name: "fixed_line", i: 11, type: w },
2740
- 3: { name: "mobile", i: 11, type: w },
2741
- 4: { name: "toll_free", i: 11, type: w },
2742
- 5: { name: "premium_rate", i: 11, type: w },
2743
- 6: { name: "shared_cost", i: 11, type: w },
2744
- 7: { name: "personal_number", i: 11, type: w },
2745
- 8: { name: "voip", i: 11, type: w },
2746
- 21: { name: "pager", i: 11, type: w },
2747
- 25: { name: "uan", i: 11, type: w },
2748
- 27: { name: "emergency", i: 11, type: w },
2749
- 28: { name: "voicemail", i: 11, type: w },
2750
- 29: { name: "short_code", i: 11, type: w },
2751
- 30: { name: "standard_rate", i: 11, type: w },
2752
- 31: { name: "carrier_specific", i: 11, type: w },
2753
- 33: { name: "sms_services", i: 11, type: w },
2754
- 24: { name: "no_international_dialling", i: 11, type: w },
2751
+ 1: { name: "general_desc", i: 11, type: b },
2752
+ 2: { name: "fixed_line", i: 11, type: b },
2753
+ 3: { name: "mobile", i: 11, type: b },
2754
+ 4: { name: "toll_free", i: 11, type: b },
2755
+ 5: { name: "premium_rate", i: 11, type: b },
2756
+ 6: { name: "shared_cost", i: 11, type: b },
2757
+ 7: { name: "personal_number", i: 11, type: b },
2758
+ 8: { name: "voip", i: 11, type: b },
2759
+ 21: { name: "pager", i: 11, type: b },
2760
+ 25: { name: "uan", i: 11, type: b },
2761
+ 27: { name: "emergency", i: 11, type: b },
2762
+ 28: { name: "voicemail", i: 11, type: b },
2763
+ 29: { name: "short_code", i: 11, type: b },
2764
+ 30: { name: "standard_rate", i: 11, type: b },
2765
+ 31: { name: "carrier_specific", i: 11, type: b },
2766
+ 33: { name: "sms_services", i: 11, type: b },
2767
+ 24: { name: "no_international_dialling", i: 11, type: b },
2755
2768
  9: { name: "id", required: !0, i: 9, type: String },
2756
2769
  10: { name: "country_code", i: 5, type: Number },
2757
2770
  11: { name: "international_prefix", i: 9, type: String },
@@ -2765,26 +2778,26 @@ const H2 = (y) => {
2765
2778
  },
2766
2779
  16: { name: "national_prefix_transform_rule", i: 9, type: String },
2767
2780
  18: { name: "same_mobile_and_fixed_line_pattern", i: 8, defaultValue: !1, type: Boolean },
2768
- 19: { name: "number_format", aa: !0, i: 11, type: j },
2769
- 20: { name: "intl_number_format", aa: !0, i: 11, type: j },
2781
+ 19: { name: "number_format", aa: !0, i: 11, type: z },
2782
+ 20: { name: "intl_number_format", aa: !0, i: 11, type: z },
2770
2783
  22: { name: "main_country_for_code", i: 8, defaultValue: !1, type: Boolean },
2771
2784
  23: { name: "leading_digits", i: 9, type: String }
2772
2785
  })), d;
2773
- }, W.m = W.prototype.m;
2774
- function V() {
2775
- x.call(this);
2786
+ }, Z.m = Z.prototype.m;
2787
+ function H() {
2788
+ R.call(this);
2776
2789
  }
2777
- n(V, x);
2778
- var A1 = null, h2 = { ra: 0, qa: 1, pa: 5, oa: 10, na: 20 };
2779
- V.prototype.m = function() {
2780
- var d = A1;
2781
- return d || (A1 = d = i1(V, { 0: { name: "PhoneNumber", ia: "i18n.phonenumbers.PhoneNumber" }, 1: { name: "country_code", required: !0, i: 5, type: Number }, 2: { name: "national_number", required: !0, 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: h2 }, 7: {
2790
+ n(H, R);
2791
+ var T1 = null, h2 = { ra: 0, qa: 1, pa: 5, oa: 10, na: 20 };
2792
+ H.prototype.m = function() {
2793
+ var d = T1;
2794
+ return d || (T1 = d = i1(H, { 0: { name: "PhoneNumber", ia: "i18n.phonenumbers.PhoneNumber" }, 1: { name: "country_code", required: !0, i: 5, type: Number }, 2: { name: "national_number", required: !0, 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: h2 }, 7: {
2782
2795
  name: "preferred_domestic_carrier_code",
2783
2796
  i: 9,
2784
2797
  type: String
2785
2798
  } })), d;
2786
- }, V.ctor = V, V.ctor.m = V.prototype.m;
2787
- var q = {
2799
+ }, H.ctor = H, H.ctor.m = H.prototype.m;
2800
+ var X = {
2788
2801
  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(" "),
2789
2802
  7: ["RU", "KZ"],
2790
2803
  20: ["EG"],
@@ -7952,29 +7965,29 @@ const H2 = (y) => {
7952
7965
  X: "9",
7953
7966
  Y: "9",
7954
7967
  Z: "9"
7955
- }, p2 = RegExp("[++]+"), X = RegExp("^[++]+"), D1 = RegExp("([0-90-9٠-٩۰-۹])"), g2 = RegExp("[++0-90-9٠-٩۰-۹]"), C2 = /[\\\/] *x/, m2 = RegExp("[^0-90-9٠-٩۰-۹A-Za-z#]+$"), y2 = /(?:.*?[A-Za-z]){3}.*/, _2 = RegExp("^\\+([0-90-9٠-٩۰-۹]|[\\-\\.\\(\\)]?)*[0-90-9٠-٩۰-۹]([0-90-9٠-٩۰-۹]|[\\-\\.\\(\\)]?)*$"), I2 = RegExp("^([A-Za-z0-90-9٠-٩۰-۹]+((\\-)*[A-Za-z0-90-9٠-٩۰-۹])*\\.)*[A-Za-z]+((\\-)*[A-Za-z0-90-9٠-٩۰-۹])*\\.?$");
7956
- function Y(d) {
7968
+ }, p2 = RegExp("[++]+"), Q = RegExp("^[++]+"), D1 = RegExp("([0-90-9٠-٩۰-۹])"), g2 = RegExp("[++0-90-9٠-٩۰-۹]"), C2 = /[\\\/] *x/, m2 = RegExp("[^0-90-9٠-٩۰-۹A-Za-z#]+$"), y2 = /(?:.*?[A-Za-z]){3}.*/, _2 = RegExp("^\\+([0-90-9٠-٩۰-۹]|[\\-\\.\\(\\)]?)*[0-90-9٠-٩۰-۹]([0-90-9٠-٩۰-۹]|[\\-\\.\\(\\)]?)*$"), I2 = RegExp("^([A-Za-z0-90-9٠-٩۰-۹]+((\\-)*[A-Za-z0-90-9٠-٩۰-۹])*\\.)*[A-Za-z]+((\\-)*[A-Za-z0-90-9٠-٩۰-۹])*\\.?$");
7969
+ function J(d) {
7957
7970
  return "([0-90-9٠-٩۰-۹]{1," + d + "})";
7958
7971
  }
7959
7972
  function M1() {
7960
- return ";ext=" + Y("20") + "|[  \\t,]*(?:e?xt(?:ensi(?:ó?|ó))?n?|e?xtn?|доб|anexo)[:\\..]?[  \\t,-]*" + (Y("20") + "#?|[  \\t,]*(?:[xx##~~]|int|int)[:\\..]?[  \\t,-]*") + (Y("9") + "#?|[- ]+") + (Y("6") + "#|[  \\t]*(?:,{2}|;)[:\\..]?[  \\t,-]*") + (Y("15") + "#?|[  \\t]*(?:,)+[:\\..]?[  \\t,-]*") + (Y("9") + "#?");
7973
+ return ";ext=" + J("20") + "|[  \\t,]*(?:e?xt(?:ensi(?:ó?|ó))?n?|e?xtn?|доб|anexo)[:\\..]?[  \\t,-]*" + (J("20") + "#?|[  \\t,]*(?:[xx##~~]|int|int)[:\\..]?[  \\t,-]*") + (J("9") + "#?|[- ]+") + (J("6") + "#|[  \\t]*(?:,{2}|;)[:\\..]?[  \\t,-]*") + (J("15") + "#?|[  \\t]*(?:,)+[:\\..]?[  \\t,-]*") + (J("9") + "#?");
7961
7974
  }
7962
7975
  var P1 = new RegExp("(?:" + M1() + ")$", "i"), v2 = new RegExp("^[0-90-9٠-٩۰-۹]{2}$|^[++]*(?:[-x‐-―−ー--/  ­​⁠ ()()[].\\[\\]/~⁓∼~*]*[0-90-9٠-٩۰-۹]){3,}[-x‐-―−ー--/  ­​⁠ ()()[].\\[\\]/~⁓∼~*A-Za-z0-90-9٠-٩۰-۹]*(?:" + M1() + ")?$", "i"), S2 = /(\$\d)/, w2 = /^\(?\$1\)?$/;
7963
7976
  function x1(d) {
7964
- return 2 > d.length ? !1 : G(v2, d);
7977
+ return 2 > d.length ? !1 : U(v2, d);
7965
7978
  }
7966
7979
  function R1(d) {
7967
- return G(y2, d) ? s1(d, f2) : s1(d, g1);
7980
+ return U(y2, d) ? s1(d, f2) : s1(d, g1);
7968
7981
  }
7969
7982
  function B1(d) {
7970
7983
  var t = R1(d.toString());
7971
- B(d), d.g(t);
7984
+ k(d), d.g(t);
7972
7985
  }
7973
7986
  function k1(d) {
7974
- return d != null && (U(d, 9) != 1 || P(d, 9)[0] != -1);
7987
+ return d != null && (K(d, 9) != 1 || P(d, 9)[0] != -1);
7975
7988
  }
7976
7989
  function s1(d, t) {
7977
- for (var e = new T(), r, s = d.length, u = 0; u < s; ++u) r = d.charAt(u), r = t[r.toUpperCase()], r != null && e.g(r);
7990
+ for (var e = new L(), r, s = d.length, u = 0; u < s; ++u) r = d.charAt(u), r = t[r.toUpperCase()], r != null && e.g(r);
7978
7991
  return e.toString();
7979
7992
  }
7980
7993
  function O1(d) {
@@ -7984,40 +7997,40 @@ const H2 = (y) => {
7984
7997
  return d != null && isNaN(d) && d.toUpperCase() in E1;
7985
7998
  }
7986
7999
  D.prototype.format = function(d, t) {
7987
- if (p(d, 2) == 0 && R(d, 5)) {
7988
- var e = S(d, 5);
8000
+ if (g(d, 2) == 0 && B(d, 5)) {
8001
+ var e = v(d, 5);
7989
8002
  if (0 < e.length) return e;
7990
8003
  }
7991
- e = S(d, 1);
7992
- var r = d1(d);
8004
+ e = v(d, 1);
8005
+ var r = t1(d);
7993
8006
  if (t == 0) return G1(e, 0, r, "");
7994
- if (!(e in q)) return r;
7995
- var s = Q(this, e, t1(e));
7996
- d = R(d, 3) && p(d, 3).length != 0 ? t == 3 ? ";ext=" + p(d, 3) : R(s, 13) ? p(s, 13) + S(d, 3) : " ext. " + S(d, 3) : "";
8007
+ if (!(e in X)) return r;
8008
+ var s = d1(this, e, e1(e));
8009
+ d = B(d, 3) && g(d, 3).length != 0 ? t == 3 ? ";ext=" + g(d, 3) : B(s, 13) ? g(s, 13) + v(d, 3) : " ext. " + v(d, 3) : "";
7997
8010
  d: {
7998
8011
  s = P(s, 20).length == 0 || t == 2 ? P(s, 19) : P(s, 20);
7999
- for (var u, l = s.length, h = 0; h < l; ++h) {
8012
+ for (var u, a = s.length, h = 0; h < a; ++h) {
8000
8013
  u = s[h];
8001
- var m = U(u, 3);
8002
- if ((m == 0 || r.search(p(u, 3, m - 1)) == 0) && (m = new RegExp(p(u, 1)), G(m, r))) {
8014
+ var m = K(u, 3);
8015
+ if ((m == 0 || r.search(g(u, 3, m - 1)) == 0) && (m = new RegExp(g(u, 1)), U(m, r))) {
8003
8016
  s = u;
8004
8017
  break d;
8005
8018
  }
8006
8019
  }
8007
8020
  s = null;
8008
8021
  }
8009
- return s != null && (l = s, s = S(l, 2), u = new RegExp(p(l, 1)), S(
8010
- l,
8022
+ return s != null && (a = s, s = v(a, 2), u = new RegExp(g(a, 1)), v(
8023
+ a,
8011
8024
  5
8012
- ), l = S(l, 4), r = t == 2 && l != null && 0 < l.length ? r.replace(u, s.replace(S2, l)) : r.replace(u, s), t == 3 && (r = r.replace(RegExp("^[-x‐-―−ー--/  ­​⁠ ()()[].\\[\\]/~⁓∼~]+"), ""), r = r.replace(RegExp("[-x‐-―−ー--/  ­​⁠ ()()[].\\[\\]/~⁓∼~]+", "g"), "-"))), G1(e, t, r, d);
8025
+ ), a = v(a, 4), r = t == 2 && a != null && 0 < a.length ? r.replace(u, s.replace(S2, a)) : r.replace(u, s), t == 3 && (r = r.replace(RegExp("^[-x‐-―−ー--/  ­​⁠ ()()[].\\[\\]/~⁓∼~]+"), ""), r = r.replace(RegExp("[-x‐-―−ー--/  ­​⁠ ()()[].\\[\\]/~⁓∼~]+", "g"), "-"))), G1(e, t, r, d);
8013
8026
  };
8014
- function Q(d, t, e) {
8015
- return e == "001" ? K(d, "" + t) : K(d, e);
8027
+ function d1(d, t, e) {
8028
+ return e == "001" ? j(d, "" + t) : j(d, e);
8016
8029
  }
8017
- function d1(d) {
8018
- if (!R(d, 2)) return "";
8019
- var t = "" + p(d, 2);
8020
- return R(d, 4) && p(d, 4) && 0 < S(d, 8) ? Array(S(d, 8) + 1).join("0") + t : t;
8030
+ function t1(d) {
8031
+ if (!B(d, 2)) return "";
8032
+ var t = "" + g(d, 2);
8033
+ return B(d, 4) && g(d, 4) && 0 < v(d, 8) ? Array(v(d, 8) + 1).join("0") + t : t;
8021
8034
  }
8022
8035
  function G1(d, t, e, r) {
8023
8036
  switch (t) {
@@ -8034,71 +8047,71 @@ const H2 = (y) => {
8034
8047
  function u1(d, t) {
8035
8048
  switch (t) {
8036
8049
  case 4:
8037
- return p(d, 5);
8050
+ return g(d, 5);
8038
8051
  case 3:
8039
- return p(d, 4);
8052
+ return g(d, 4);
8040
8053
  case 1:
8041
- return p(d, 3);
8054
+ return g(d, 3);
8042
8055
  case 0:
8043
8056
  case 2:
8044
- return p(d, 2);
8057
+ return g(d, 2);
8045
8058
  case 5:
8046
- return p(d, 6);
8059
+ return g(d, 6);
8047
8060
  case 6:
8048
- return p(d, 8);
8061
+ return g(d, 8);
8049
8062
  case 7:
8050
- return p(d, 7);
8063
+ return g(d, 7);
8051
8064
  case 8:
8052
- return p(d, 21);
8065
+ return g(d, 21);
8053
8066
  case 9:
8054
- return p(d, 25);
8067
+ return g(d, 25);
8055
8068
  case 10:
8056
- return p(d, 28);
8069
+ return g(d, 28);
8057
8070
  default:
8058
- return p(d, 1);
8071
+ return g(d, 1);
8059
8072
  }
8060
8073
  }
8061
8074
  function F1(d, t) {
8062
8075
  var e = U1(d, t);
8063
- return d = Q(d, S(t, 1), e), d == null ? -1 : (t = d1(t), C1(t, d));
8076
+ return d = d1(d, v(t, 1), e), d == null ? -1 : (t = t1(t), C1(t, d));
8064
8077
  }
8065
8078
  function C1(d, t) {
8066
- return k(d, p(t, 1)) ? k(d, p(t, 5)) ? 4 : k(d, p(t, 4)) ? 3 : k(d, p(t, 6)) ? 5 : k(d, p(t, 8)) ? 6 : k(d, p(t, 7)) ? 7 : k(d, p(t, 21)) ? 8 : k(d, p(t, 25)) ? 9 : k(d, p(t, 28)) ? 10 : k(d, p(t, 2)) ? p(t, 18) || k(d, p(t, 3)) ? 2 : 0 : !p(t, 18) && k(d, p(t, 3)) ? 1 : -1 : -1;
8079
+ return O(d, g(t, 1)) ? O(d, g(t, 5)) ? 4 : O(d, g(t, 4)) ? 3 : O(d, g(t, 6)) ? 5 : O(d, g(t, 8)) ? 6 : O(d, g(t, 7)) ? 7 : O(d, g(t, 21)) ? 8 : O(d, g(t, 25)) ? 9 : O(d, g(t, 28)) ? 10 : O(d, g(t, 2)) ? g(t, 18) || O(d, g(t, 3)) ? 2 : 0 : !g(t, 18) && O(d, g(t, 3)) ? 1 : -1 : -1;
8067
8080
  }
8068
- function K(d, t) {
8081
+ function j(d, t) {
8069
8082
  if (t == null) return null;
8070
8083
  t = t.toUpperCase();
8071
8084
  var e = d.g[t];
8072
8085
  if (e == null) {
8073
8086
  if (e = E1[t], e == null) return null;
8074
- e = new J().g(W.m(), e), d.g[t] = e;
8087
+ e = new q().g(Z.m(), e), d.g[t] = e;
8075
8088
  }
8076
8089
  return e;
8077
8090
  }
8078
- function k(d, t) {
8091
+ function O(d, t) {
8079
8092
  var e = d.length;
8080
- return 0 < U(t, 9) && P(t, 9).indexOf(e) == -1 ? !1 : G(S(t, 2), d);
8093
+ return 0 < K(t, 9) && P(t, 9).indexOf(e) == -1 ? !1 : U(v(t, 2), d);
8081
8094
  }
8082
8095
  function b2(d, t) {
8083
- var e = U1(d, t), r = S(t, 1), s = Q(d, r, e);
8084
- return s == null || e != "001" && r != V1(d, e) ? s = !1 : (d = d1(t), s = C1(d, s) != -1), s;
8096
+ var e = U1(d, t), r = v(t, 1), s = d1(d, r, e);
8097
+ return s == null || e != "001" && r != V1(d, e) ? s = !1 : (d = t1(t), s = C1(d, s) != -1), s;
8085
8098
  }
8086
8099
  function U1(d, t) {
8087
8100
  if (t == null) return null;
8088
- var e = S(t, 1);
8089
- if (e = q[e], e == null) d = null;
8101
+ var e = v(t, 1);
8102
+ if (e = X[e], e == null) d = null;
8090
8103
  else if (e.length == 1) d = e[0];
8091
8104
  else d: {
8092
- t = d1(t);
8105
+ t = t1(t);
8093
8106
  for (var r, s = e.length, u = 0; u < s; u++) {
8094
8107
  r = e[u];
8095
- var l = K(d, r);
8096
- if (R(l, 23)) {
8097
- if (t.search(p(l, 23)) == 0) {
8108
+ var a = j(d, r);
8109
+ if (B(a, 23)) {
8110
+ if (t.search(g(a, 23)) == 0) {
8098
8111
  d = r;
8099
8112
  break d;
8100
8113
  }
8101
- } else if (C1(t, l) != -1) {
8114
+ } else if (C1(t, a) != -1) {
8102
8115
  d = r;
8103
8116
  break d;
8104
8117
  }
@@ -8107,103 +8120,103 @@ const H2 = (y) => {
8107
8120
  }
8108
8121
  return d;
8109
8122
  }
8110
- function t1(d) {
8111
- return d = q[d], d == null ? "ZZ" : d[0];
8123
+ function e1(d) {
8124
+ return d = X[d], d == null ? "ZZ" : d[0];
8112
8125
  }
8113
8126
  function V1(d, t) {
8114
- if (d = K(d, t), d == null) throw Error("Invalid region code: " + t);
8115
- return S(d, 10);
8127
+ if (d = j(d, t), d == null) throw Error("Invalid region code: " + t);
8128
+ return v(d, 10);
8116
8129
  }
8117
- function l1(d, t, e, r) {
8118
- var s = u1(e, r), u = U(s, 9) == 0 ? P(p(e, 1), 9) : P(s, 9);
8119
- if (s = P(s, 10), r == 2) if (k1(u1(e, 0))) d = u1(e, 1), k1(d) && (u = u.concat(U(d, 9) == 0 ? P(p(e, 1), 9) : P(d, 9)), u.sort(), s.length == 0 ? s = P(d, 10) : (s = s.concat(P(d, 10)), s.sort()));
8120
- else return l1(d, t, e, 1);
8130
+ function a1(d, t, e, r) {
8131
+ var s = u1(e, r), u = K(s, 9) == 0 ? P(g(e, 1), 9) : P(s, 9);
8132
+ if (s = P(s, 10), r == 2) if (k1(u1(e, 0))) d = u1(e, 1), k1(d) && (u = u.concat(K(d, 9) == 0 ? P(g(e, 1), 9) : P(d, 9)), u.sort(), s.length == 0 ? s = P(d, 10) : (s = s.concat(P(d, 10)), s.sort()));
8133
+ else return a1(d, t, e, 1);
8121
8134
  return u[0] == -1 ? 5 : (t = t.length, -1 < s.indexOf(t) ? 4 : (e = u[0], e == t ? 0 : e > t ? 2 : u[u.length - 1] < t ? 3 : -1 < u.indexOf(t, 1) ? 0 : 5));
8122
8135
  }
8123
- function a1(d, t, e) {
8124
- var r = d1(t);
8125
- return t = S(t, 1), t in q ? (t = Q(d, t, t1(t)), l1(d, r, t, e)) : 1;
8136
+ function l1(d, t, e) {
8137
+ var r = t1(t);
8138
+ return t = v(t, 1), t in X ? (t = d1(d, t, e1(t)), a1(d, r, t, e)) : 1;
8126
8139
  }
8127
8140
  function K1(d, t) {
8128
8141
  if (d = d.toString(), d.length == 0 || d.charAt(0) == "0") return 0;
8129
- for (var e, r = d.length, s = 1; 3 >= s && s <= r; ++s) if (e = parseInt(d.substring(0, s), 10), e in q) return t.g(d.substring(s)), e;
8142
+ for (var e, r = d.length, s = 1; 3 >= s && s <= r; ++s) if (e = parseInt(d.substring(0, s), 10), e in X) return t.g(d.substring(s)), e;
8130
8143
  return 0;
8131
8144
  }
8132
8145
  function H1(d, t, e, r, s, u) {
8133
8146
  if (t.length == 0) return 0;
8134
- t = new T(t);
8135
- var l;
8136
- e != null && (l = p(e, 11)), l == null && (l = "NonMatch");
8147
+ t = new L(t);
8148
+ var a;
8149
+ e != null && (a = g(e, 11)), a == null && (a = "NonMatch");
8137
8150
  var h = t.toString();
8138
- if (h.length == 0) l = 20;
8139
- else if (X.test(h)) h = h.replace(X, ""), B(t), t.g(R1(h)), l = 1;
8151
+ if (h.length == 0) a = 20;
8152
+ else if (Q.test(h)) h = h.replace(Q, ""), k(t), t.g(R1(h)), a = 1;
8140
8153
  else {
8141
- if (h = new RegExp(l), B1(t), l = t.toString(), l.search(h) == 0) {
8142
- h = l.match(h)[0].length;
8143
- var m = l.substring(h).match(D1);
8144
- m && m[1] != null && 0 < m[1].length && s1(m[1], g1) == "0" ? l = !1 : (B(t), t.g(l.substring(h)), l = !0);
8145
- } else l = !1;
8146
- l = l ? 5 : 20;
8154
+ if (h = new RegExp(a), B1(t), a = t.toString(), a.search(h) == 0) {
8155
+ h = a.match(h)[0].length;
8156
+ var m = a.substring(h).match(D1);
8157
+ m && m[1] != null && 0 < m[1].length && s1(m[1], g1) == "0" ? a = !1 : (k(t), t.g(a.substring(h)), a = !0);
8158
+ } else a = !1;
8159
+ a = a ? 5 : 20;
8147
8160
  }
8148
- if (s && E(u, 6, l), l != 20) {
8161
+ if (s && E(u, 6, a), a != 20) {
8149
8162
  if (2 >= t.h.length) throw Error("Phone number too short after IDD");
8150
8163
  if (d = K1(t, r), d != 0) return E(u, 1, d), d;
8151
8164
  throw Error("Invalid country calling code");
8152
8165
  }
8153
- return e != null && (l = S(e, 10), h = "" + l, m = t.toString(), m.lastIndexOf(h, 0) == 0 && (h = new T(m.substring(h.length)), m = p(e, 1), m = new RegExp(S(m, 2)), j1(h, e, null), h = h.toString(), !G(m, t.toString()) && G(m, h) || l1(d, t.toString(), e, -1) == 3)) ? (r.g(h), s && E(u, 6, 10), E(u, 1, l), l) : (E(u, 1, 0), 0);
8166
+ return e != null && (a = v(e, 10), h = "" + a, m = t.toString(), m.lastIndexOf(h, 0) == 0 && (h = new L(m.substring(h.length)), m = g(e, 1), m = new RegExp(v(m, 2)), j1(h, e, null), h = h.toString(), !U(m, t.toString()) && U(m, h) || a1(d, t.toString(), e, -1) == 3)) ? (r.g(h), s && E(u, 6, 10), E(u, 1, a), a) : (E(u, 1, 0), 0);
8154
8167
  }
8155
8168
  function j1(d, t, e) {
8156
- var r = d.toString(), s = r.length, u = p(t, 15);
8169
+ var r = d.toString(), s = r.length, u = g(t, 15);
8157
8170
  if (s != 0 && u != null && u.length != 0) {
8158
- var l = new RegExp("^(?:" + u + ")");
8159
- if (s = l.exec(r)) {
8160
- u = new RegExp(S(p(t, 1), 2));
8161
- var h = G(u, r), m = s.length - 1;
8162
- t = p(t, 16), t == null || t.length == 0 || s[m] == null || s[m].length == 0 ? (!h || G(u, r.substring(s[0].length))) && (e != null && 0 < m && s[m] != null && e.g(s[1]), d.set(r.substring(s[0].length))) : (r = r.replace(l, t), (!h || G(u, r)) && (e != null && 0 < m && e.g(s[1]), d.set(r)));
8171
+ var a = new RegExp("^(?:" + u + ")");
8172
+ if (s = a.exec(r)) {
8173
+ u = new RegExp(v(g(t, 1), 2));
8174
+ var h = U(u, r), m = s.length - 1;
8175
+ t = g(t, 16), t == null || t.length == 0 || s[m] == null || s[m].length == 0 ? (!h || U(u, r.substring(s[0].length))) && (e != null && 0 < m && s[m] != null && e.g(s[1]), d.set(r.substring(s[0].length))) : (r = r.replace(a, t), (!h || U(u, r)) && (e != null && 0 < m && e.g(s[1]), d.set(r)));
8163
8176
  }
8164
8177
  }
8165
8178
  }
8166
- function z(d, t, e) {
8179
+ function Y(d, t, e) {
8167
8180
  if (!o1(e) && 0 < t.length && t.charAt(0) != "+") throw Error("Invalid country calling code");
8168
8181
  return W1(d, t, e, !0);
8169
8182
  }
8170
8183
  function W1(d, t, e, r) {
8171
8184
  if (t == null) throw Error("The string supplied did not seem to be a phone number");
8172
8185
  if (250 < t.length) throw Error("The string supplied is too long to be a phone number");
8173
- var s = new T(), u = t.indexOf(";phone-context=");
8186
+ var s = new L(), u = t.indexOf(";phone-context=");
8174
8187
  if (u === -1) u = null;
8175
8188
  else if (u += 15, u >= t.length) u = "";
8176
8189
  else {
8177
- var l = t.indexOf(";", u);
8178
- u = l !== -1 ? t.substring(u, l) : t.substring(u);
8190
+ var a = t.indexOf(";", u);
8191
+ u = a !== -1 ? t.substring(u, a) : t.substring(u);
8179
8192
  }
8180
8193
  var h = u;
8181
- if (h == null ? l = !0 : h.length === 0 ? l = !1 : (l = _2.exec(h), h = I2.exec(h), l = l !== null || h !== null), !l || (u != null ? (u.charAt(0) === "+" && s.g(u), u = t.indexOf("tel:"), s.g(t.substring(0 <= u ? u + 4 : 0, t.indexOf(";phone-context=")))) : (u = s.g, l = t ?? "", h = l.search(g2), 0 <= h ? (l = l.substring(h), l = l.replace(m2, ""), h = l.search(C2), 0 <= h && (l = l.substring(0, h))) : l = "", u.call(s, l)), u = s.toString(), l = u.indexOf(";isub="), 0 < l && (B(s), s.g(u.substring(0, l))), !x1(s.toString()))) throw Error("The string supplied did not seem to be a phone number");
8182
- if (u = s.toString(), !(o1(e) || u != null && 0 < u.length && X.test(u))) throw Error("Invalid country calling code");
8183
- u = new V(), r && E(u, 5, t);
8194
+ if (h == null ? a = !0 : h.length === 0 ? a = !1 : (a = _2.exec(h), h = I2.exec(h), a = a !== null || h !== null), !a || (u != null ? (u.charAt(0) === "+" && s.g(u), u = t.indexOf("tel:"), s.g(t.substring(0 <= u ? u + 4 : 0, t.indexOf(";phone-context=")))) : (u = s.g, a = t ?? "", h = a.search(g2), 0 <= h ? (a = a.substring(h), a = a.replace(m2, ""), h = a.search(C2), 0 <= h && (a = a.substring(0, h))) : a = "", u.call(s, a)), u = s.toString(), a = u.indexOf(";isub="), 0 < a && (k(s), s.g(u.substring(0, a))), !x1(s.toString()))) throw Error("The string supplied did not seem to be a phone number");
8195
+ if (u = s.toString(), !(o1(e) || u != null && 0 < u.length && Q.test(u))) throw Error("Invalid country calling code");
8196
+ u = new H(), r && E(u, 5, t);
8184
8197
  d: {
8185
- if (t = s.toString(), l = t.search(P1), 0 <= l && x1(t.substring(0, l))) {
8198
+ if (t = s.toString(), a = t.search(P1), 0 <= a && x1(t.substring(0, a))) {
8186
8199
  h = t.match(P1);
8187
- for (var m = h.length, F = 1; F < m; ++F) if (h[F] != null && 0 < h[F].length) {
8188
- B(s), s.g(t.substring(0, l)), t = h[F];
8200
+ for (var m = h.length, V = 1; V < m; ++V) if (h[V] != null && 0 < h[V].length) {
8201
+ k(s), s.g(t.substring(0, a)), t = h[V];
8189
8202
  break d;
8190
8203
  }
8191
8204
  }
8192
8205
  t = "";
8193
8206
  }
8194
- 0 < t.length && E(u, 3, t), l = K(d, e), t = new T(), h = 0, m = s.toString();
8207
+ 0 < t.length && E(u, 3, t), a = j(d, e), t = new L(), h = 0, m = s.toString();
8195
8208
  try {
8196
- h = H1(d, m, l, t, r, u);
8209
+ h = H1(d, m, a, t, r, u);
8197
8210
  } catch (_1) {
8198
- if (_1.message == "Invalid country calling code" && X.test(m)) {
8199
- if (m = m.replace(X, ""), h = H1(d, m, l, t, r, u), h == 0) throw _1;
8211
+ if (_1.message == "Invalid country calling code" && Q.test(m)) {
8212
+ if (m = m.replace(Q, ""), h = H1(d, m, a, t, r, u), h == 0) throw _1;
8200
8213
  } else throw _1;
8201
8214
  }
8202
- if (h != 0 ? (s = t1(h), s != e && (l = Q(d, h, s))) : (B1(s), t.g(s.toString()), e != null ? (h = S(l, 10), E(
8215
+ if (h != 0 ? (s = e1(h), s != e && (a = d1(d, h, s))) : (B1(s), t.g(s.toString()), e != null ? (h = v(a, 10), E(
8203
8216
  u,
8204
8217
  1,
8205
8218
  h
8206
- )) : r && (delete u.h[6], u.g && delete u.g[6])), 2 > t.h.length || (l != null && (e = new T(), s = new T(t.toString()), j1(s, l, e), d = l1(d, s.toString(), l, -1), d != 2 && d != 4 && d != 5 && (t = s, r && 0 < e.toString().length && E(u, 7, e.toString()))), r = t.toString(), d = r.length, 2 > d)) throw Error("The string supplied is too short to be a phone number");
8219
+ )) : r && (delete u.h[6], u.g && delete u.g[6])), 2 > t.h.length || (a != null && (e = new L(), s = new L(t.toString()), j1(s, a, e), d = a1(d, s.toString(), a, -1), d != 2 && d != 4 && d != 5 && (t = s, r && 0 < e.toString().length && E(u, 7, e.toString()))), r = t.toString(), d = r.length, 2 > d)) throw Error("The string supplied is too short to be a phone number");
8207
8220
  if (17 < d) throw Error("The string supplied is too long to be a phone number");
8208
8221
  if (1 < r.length && r.charAt(0) == "0") {
8209
8222
  for (E(u, 4, !0), d = 1; d < r.length - 1 && r.charAt(d) == "0"; ) d++;
@@ -8211,47 +8224,47 @@ const H2 = (y) => {
8211
8224
  }
8212
8225
  return E(u, 2, parseInt(r, 10)), u;
8213
8226
  }
8214
- function G(d, t) {
8227
+ function U(d, t) {
8215
8228
  return !!((d = typeof d == "string" ? t.match("^(?:" + d + ")$") : t.match(d)) && d[0].length == t.length);
8216
8229
  }
8217
- function L2(d) {
8218
- this.fa = RegExp(" "), this.ja = "", this.v = new T(), this.da = "", this.s = new T(), this.ba = new T(), this.u = !0, this.ea = this.ca = this.la = !1, this.ga = D.g(), this.$ = 0, this.h = new T(), this.ha = !1, this.o = "", this.g = new T(), this.j = [], this.ka = d, this.l = Y1(this, this.ka);
8230
+ function A2(d) {
8231
+ this.fa = RegExp(" "), this.ja = "", this.v = new L(), this.da = "", this.s = new L(), this.ba = new L(), this.u = !0, this.ea = this.ca = this.la = !1, this.ga = D.g(), this.$ = 0, this.h = new L(), this.ha = !1, this.o = "", this.g = new L(), this.j = [], this.ka = d, this.l = Y1(this, this.ka);
8219
8232
  }
8220
- var z1 = new W();
8233
+ var z1 = new Z();
8221
8234
  E(z1, 11, "NA");
8222
- var N2 = RegExp("^[-x‐-―−ー--/  ­​⁠ ()()[].\\[\\]/~⁓∼~]*\\$1[-x‐-―−ー--/  ­​⁠ ()()[].\\[\\]/~⁓∼~]*(\\$\\d[-x‐-―−ー--/  ­​⁠ ()()[].\\[\\]/~⁓∼~]*)*$"), Z1 = /[- ]/;
8235
+ var L2 = RegExp("^[-x‐-―−ー--/  ­​⁠ ()()[].\\[\\]/~⁓∼~]*\\$1[-x‐-―−ー--/  ­​⁠ ()()[].\\[\\]/~⁓∼~]*(\\$\\d[-x‐-―−ー--/  ­​⁠ ()()[].\\[\\]/~⁓∼~]*)*$"), Z1 = /[- ]/;
8223
8236
  function Y1(d, t) {
8224
8237
  var e = d.ga;
8225
- return t = o1(t) ? V1(e, t) : 0, d = K(d.ga, t1(t)), d ?? z1;
8238
+ return t = o1(t) ? V1(e, t) : 0, d = j(d.ga, e1(t)), d ?? z1;
8226
8239
  }
8227
8240
  function J1(d) {
8228
8241
  for (var t = d.j.length, e = 0; e < t; ++e) {
8229
- var r = d.j[e], s = S(r, 1);
8242
+ var r = d.j[e], s = v(r, 1);
8230
8243
  if (d.da == s) return !1;
8231
- var u = d, l = r, h = S(l, 1);
8232
- B(u.v);
8244
+ var u = d, a = r, h = v(a, 1);
8245
+ k(u.v);
8233
8246
  var m = u;
8234
- l = S(l, 2);
8235
- var F = "999999999999999".match(h)[0];
8236
- if (F.length < m.g.h.length ? m = "" : (m = F.replace(new RegExp(h, "g"), l), m = m.replace(RegExp("9", "g"), " ")), 0 < m.length ? (u.v.g(m), u = !0) : u = !1, u) return d.da = s, d.ha = Z1.test(p(r, 4)), d.$ = 0, !0;
8247
+ a = v(a, 2);
8248
+ var V = "999999999999999".match(h)[0];
8249
+ if (V.length < m.g.h.length ? m = "" : (m = V.replace(new RegExp(h, "g"), a), m = m.replace(RegExp("9", "g"), " ")), 0 < m.length ? (u.v.g(m), u = !0) : u = !1, u) return d.da = s, d.ha = Z1.test(g(r, 4)), d.$ = 0, !0;
8237
8250
  }
8238
8251
  return d.u = !1;
8239
8252
  }
8240
8253
  function q1(d, t) {
8241
8254
  for (var e = [], r = t.length - 3, s = d.j.length, u = 0; u < s; ++u) {
8242
- var l = d.j[u];
8243
- U(l, 3) == 0 ? e.push(d.j[u]) : (l = p(l, 3, Math.min(r, U(l, 3) - 1)), t.search(l) == 0 && e.push(d.j[u]));
8255
+ var a = d.j[u];
8256
+ K(a, 3) == 0 ? e.push(d.j[u]) : (a = g(a, 3, Math.min(r, K(a, 3) - 1)), t.search(a) == 0 && e.push(d.j[u]));
8244
8257
  }
8245
8258
  d.j = e;
8246
8259
  }
8247
- function T2(d, t) {
8260
+ function N2(d, t) {
8248
8261
  d.s.g(t);
8249
8262
  var e = t;
8250
8263
  if (D1.test(e) || d.s.h.length == 1 && p2.test(e) ? (t == "+" ? (e = t, d.ba.g(t)) : (e = g1[t], d.ba.g(e), d.g.g(e)), t = e) : (d.u = !1, d.la = !0), !d.u) {
8251
8264
  if (!d.la) {
8252
8265
  if (e2(d)) {
8253
8266
  if ($2(d)) return X1(d);
8254
- } else if (0 < d.o.length && (t = d.g.toString(), B(d.g), d.g.g(d.o), d.g.g(t), t = d.h.toString(), e = t.lastIndexOf(d.o), B(d.h), d.h.g(t.substring(0, e))), d.o != t2(d)) return d.h.g(" "), X1(d);
8267
+ } else if (0 < d.o.length && (t = d.g.toString(), k(d.g), d.g.g(d.o), d.g.g(t), t = d.h.toString(), e = t.lastIndexOf(d.o), k(d.h), d.h.g(t.substring(0, e))), d.o != t2(d)) return d.h.g(" "), X1(d);
8255
8268
  }
8256
8269
  return d.s.toString();
8257
8270
  }
@@ -8268,12 +8281,12 @@ const H2 = (y) => {
8268
8281
  }
8269
8282
  }
8270
8283
  function X1(d) {
8271
- return d.u = !0, d.ea = !1, d.j = [], d.$ = 0, B(d.v), d.da = "", m1(d);
8284
+ return d.u = !0, d.ea = !1, d.j = [], d.$ = 0, k(d.v), d.da = "", m1(d);
8272
8285
  }
8273
8286
  function Q1(d) {
8274
8287
  for (var t = d.g.toString(), e = d.j.length, r = 0; r < e; ++r) {
8275
- var s = d.j[r], u = S(s, 1);
8276
- if (new RegExp("^(?:" + u + ")$").test(t) && (d.ha = Z1.test(p(s, 4)), s = t.replace(new RegExp(u, "g"), p(s, 2)), s = h1(d, s), s1(s, c2) == d.ba)) return s;
8288
+ var s = d.j[r], u = v(s, 1);
8289
+ if (new RegExp("^(?:" + u + ")$").test(t) && (d.ha = Z1.test(g(s, 4)), s = t.replace(new RegExp(u, "g"), g(s, 2)), s = h1(d, s), s1(s, c2) == d.ba)) return s;
8277
8290
  }
8278
8291
  return "";
8279
8292
  }
@@ -8284,9 +8297,9 @@ const H2 = (y) => {
8284
8297
  function m1(d) {
8285
8298
  var t = d.g.toString();
8286
8299
  if (3 <= t.length) {
8287
- for (var e = d.ca && d.o.length == 0 && 0 < U(d.l, 20) ? P(d.l, 20) : P(d.l, 19), r = e.length, s = 0; s < r; ++s) {
8300
+ for (var e = d.ca && d.o.length == 0 && 0 < K(d.l, 20) ? P(d.l, 20) : P(d.l, 19), r = e.length, s = 0; s < r; ++s) {
8288
8301
  var u = e[s];
8289
- 0 < d.o.length && O1(S(u, 4)) && !p(u, 6) && !R(u, 5) || (d.o.length != 0 || d.ca || O1(S(u, 4)) || p(u, 6)) && N2.test(S(u, 2)) && d.j.push(u);
8302
+ 0 < d.o.length && O1(v(u, 4)) && !g(u, 6) && !B(u, 5) || (d.o.length != 0 || d.ca || O1(v(u, 4)) || g(u, 6)) && L2.test(v(u, 2)) && d.j.push(u);
8290
8303
  }
8291
8304
  return q1(d, t), t = Q1(d), 0 < t.length ? t : J1(d) ? d2(d) : d.s.toString();
8292
8305
  }
@@ -8302,41 +8315,41 @@ const H2 = (y) => {
8302
8315
  }
8303
8316
  function t2(d) {
8304
8317
  var t = d.g.toString(), e = 0;
8305
- if (p(d.l, 10) != 1) var r = !1;
8318
+ if (g(d.l, 10) != 1) var r = !1;
8306
8319
  else r = d.g.toString(), r = r.charAt(0) == "1" && r.charAt(1) != "0" && r.charAt(1) != "1";
8307
- return r ? (e = 1, d.h.g("1").g(" "), d.ca = !0) : R(d.l, 15) && (r = new RegExp("^(?:" + p(d.l, 15) + ")"), r = t.match(r), r != null && r[0] != null && 0 < r[0].length && (d.ca = !0, e = r[0].length, d.h.g(t.substring(0, e)))), B(d.g), d.g.g(t.substring(e)), t.substring(0, e);
8320
+ return r ? (e = 1, d.h.g("1").g(" "), d.ca = !0) : B(d.l, 15) && (r = new RegExp("^(?:" + g(d.l, 15) + ")"), r = t.match(r), r != null && r[0] != null && 0 < r[0].length && (d.ca = !0, e = r[0].length, d.h.g(t.substring(0, e)))), k(d.g), d.g.g(t.substring(e)), t.substring(0, e);
8308
8321
  }
8309
8322
  function e2(d) {
8310
- var t = d.ba.toString(), e = new RegExp("^(?:\\+|" + p(d.l, 11) + ")");
8311
- return e = t.match(e), e != null && e[0] != null && 0 < e[0].length ? (d.ca = !0, e = e[0].length, B(d.g), d.g.g(t.substring(e)), B(d.h), d.h.g(t.substring(0, e)), t.charAt(0) != "+" && d.h.g(" "), !0) : !1;
8323
+ var t = d.ba.toString(), e = new RegExp("^(?:\\+|" + g(d.l, 11) + ")");
8324
+ return e = t.match(e), e != null && e[0] != null && 0 < e[0].length ? (d.ca = !0, e = e[0].length, k(d.g), d.g.g(t.substring(e)), k(d.h), d.h.g(t.substring(0, e)), t.charAt(0) != "+" && d.h.g(" "), !0) : !1;
8312
8325
  }
8313
8326
  function $2(d) {
8314
8327
  if (d.g.h.length == 0) return !1;
8315
- var t = new T(), e = K1(d.g, t);
8316
- return e == 0 ? !1 : (B(d.g), d.g.g(t.toString()), t = t1(e), t == "001" ? d.l = K(d.ga, "" + e) : t != d.ka && (d.l = Y1(d, t)), d.h.g("" + e).g(" "), d.o = "", !0);
8328
+ var t = new L(), e = K1(d.g, t);
8329
+ return e == 0 ? !1 : (k(d.g), d.g.g(t.toString()), t = e1(e), t == "001" ? d.l = j(d.ga, "" + e) : t != d.ka && (d.l = Y1(d, t)), d.h.g("" + e).g(" "), d.o = "", !0);
8317
8330
  }
8318
8331
  function n2(d, t) {
8319
8332
  var e = d.v.toString();
8320
8333
  if (0 <= e.substring(d.$).search(d.fa)) {
8321
8334
  var r = e.search(d.fa);
8322
- return t = e.replace(d.fa, t), B(d.v), d.v.g(t), d.$ = r, t.substring(0, d.$ + 1);
8335
+ return t = e.replace(d.fa, t), k(d.v), d.v.g(t), d.$ = r, t.substring(0, d.$ + 1);
8323
8336
  }
8324
8337
  return d.j.length == 1 && (d.u = !1), d.da = "", d.s.toString();
8325
8338
  }
8326
8339
  const y1 = { 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 };
8327
8340
  $("intlTelInputUtilsTemp", {}), $("intlTelInputUtilsTemp.formatNumberAsYouType", (d, t) => {
8328
8341
  try {
8329
- const e = d.replace(/[^+0-9]/g, ""), r = new L2(t);
8342
+ const e = d.replace(/[^+0-9]/g, ""), r = new A2(t);
8330
8343
  t = "";
8331
- for (let s = 0; s < e.length; s++) r.ja = T2(r, e.charAt(s)), t = r.ja;
8344
+ for (let s = 0; s < e.length; s++) r.ja = N2(r, e.charAt(s)), t = r.ja;
8332
8345
  return t;
8333
8346
  } catch {
8334
8347
  return d;
8335
8348
  }
8336
8349
  }), $("intlTelInputUtilsTemp.formatNumber", (d, t, e) => {
8337
8350
  try {
8338
- const s = D.g(), u = z(s, d, t);
8339
- var r = a1(s, u, -1);
8351
+ const s = D.g(), u = Y(s, d, t);
8352
+ var r = l1(s, u, -1);
8340
8353
  return r == 0 || r == 4 ? s.format(u, typeof e > "u" ? 0 : e) : d;
8341
8354
  } catch {
8342
8355
  return d;
@@ -8347,10 +8360,10 @@ const H2 = (y) => {
8347
8360
  d: {
8348
8361
  var s = m;
8349
8362
  if (o1(d)) {
8350
- var u = u1(K(s, d), e);
8363
+ var u = u1(j(s, d), e);
8351
8364
  try {
8352
- if (R(u, 6)) {
8353
- var l = p(u, 6), h = W1(s, l, d, !1);
8365
+ if (B(u, 6)) {
8366
+ var a = g(u, 6), h = W1(s, a, d, !1);
8354
8367
  break d;
8355
8368
  }
8356
8369
  } catch {
@@ -8364,13 +8377,13 @@ const H2 = (y) => {
8364
8377
  }
8365
8378
  }), $("intlTelInputUtilsTemp.getExtension", (d, t) => {
8366
8379
  try {
8367
- return p(z(D.g(), d, t), 3);
8380
+ return g(Y(D.g(), d, t), 3);
8368
8381
  } catch {
8369
8382
  return "";
8370
8383
  }
8371
8384
  }), $("intlTelInputUtilsTemp.getNumberType", (d, t) => {
8372
8385
  try {
8373
- const e = D.g(), r = z(e, d, t);
8386
+ const e = D.g(), r = Y(e, d, t);
8374
8387
  return F1(e, r);
8375
8388
  } catch {
8376
8389
  return -99;
@@ -8378,17 +8391,17 @@ const H2 = (y) => {
8378
8391
  }), $("intlTelInputUtilsTemp.getValidationError", (d, t) => {
8379
8392
  if (!t) return 1;
8380
8393
  try {
8381
- const e = D.g(), r = z(e, d, t);
8382
- return a1(e, r, -1);
8394
+ const e = D.g(), r = Y(e, d, t);
8395
+ return l1(e, r, -1);
8383
8396
  } catch (e) {
8384
8397
  return e.message === "Invalid country calling code" ? 1 : 3 >= d.length || e.message === "Phone number too short after IDD" || e.message === "The string supplied is too short to be a phone number" ? 2 : e.message === "The string supplied is too long to be a phone number" ? 3 : -99;
8385
8398
  }
8386
8399
  }), $("intlTelInputUtilsTemp.isValidNumber", (d, t, e) => {
8387
8400
  try {
8388
- const r = D.g(), s = z(r, d, t), u = b2(r, s);
8401
+ const r = D.g(), s = Y(r, d, t), u = b2(r, s);
8389
8402
  if (e) {
8390
- const l = e.map((h) => y1[h]);
8391
- return u && l.includes(F1(r, s));
8403
+ const a = e.map((h) => y1[h]);
8404
+ return u && a.includes(F1(r, s));
8392
8405
  }
8393
8406
  return u;
8394
8407
  } catch {
@@ -8396,19 +8409,19 @@ const H2 = (y) => {
8396
8409
  }
8397
8410
  }), $("intlTelInputUtilsTemp.isPossibleNumber", (d, t, e) => {
8398
8411
  try {
8399
- const r = D.g(), s = z(r, d, t);
8412
+ const r = D.g(), s = Y(r, d, t);
8400
8413
  if (e) {
8401
8414
  e.includes("FIXED_LINE_OR_MOBILE") && (e.includes("MOBILE") || e.push("MOBILE"), e.includes("FIXED_LINE") || e.push("FIXED_LINE"));
8402
- for (let u of e) if (a1(r, s, y1[u]) === 0) return !0;
8415
+ for (let u of e) if (l1(r, s, y1[u]) === 0) return !0;
8403
8416
  return !1;
8404
8417
  }
8405
- return a1(r, s, -1) === 0;
8418
+ return l1(r, s, -1) === 0;
8406
8419
  } catch {
8407
8420
  return !1;
8408
8421
  }
8409
8422
  }), $("intlTelInputUtilsTemp.getCoreNumber", (d, t) => {
8410
8423
  try {
8411
- return p(z(D.g(), d, t), 2).toString();
8424
+ return g(Y(D.g(), d, t), 2).toString();
8412
8425
  } catch {
8413
8426
  return "";
8414
8427
  }
@@ -8450,37 +8463,37 @@ const z2 = {
8450
8463
  "changeErrorCode"
8451
8464
  ], ["update:modelValue"]),
8452
8465
  setup(y, { expose: $, emit: n }) {
8453
- const i = A2(y, "modelValue"), o = y, a = n, c = I1(), g = I1(), f = I1(!1), b = () => g.value ? o.options.strictMode ? g.value.isValidNumberPrecise() : g.value.isValidNumber() : null, _ = () => {
8454
- let v = b();
8455
- f.value !== v && (f.value = v, a("changeValidity", !!v), a(
8466
+ const i = T2(y, "modelValue"), o = y, l = n, c = I1(), f = I1(), p = I1(!1), w = () => f.value ? o.options.strictMode ? f.value.isValidNumberPrecise() : f.value.isValidNumber() : null, I = () => {
8467
+ let _ = w();
8468
+ p.value !== _ && (p.value = _, l("changeValidity", !!_), l(
8456
8469
  "changeErrorCode",
8457
- v ? null : g.value.getValidationError()
8470
+ _ ? null : f.value.getValidationError()
8458
8471
  ));
8459
- }, I = () => {
8460
- var v;
8461
- a("changeNumber", ((v = g.value) == null ? void 0 : v.getNumber()) ?? ""), _();
8462
- }, L = () => {
8463
- var v;
8464
- a("changeCountry", ((v = g.value) == null ? void 0 : v.getSelectedCountryData().iso2) ?? ""), I(), _();
8472
+ }, S = () => {
8473
+ var _;
8474
+ l("changeNumber", ((_ = f.value) == null ? void 0 : _.getNumber()) ?? ""), I();
8475
+ }, A = () => {
8476
+ var _;
8477
+ l("changeCountry", ((_ = f.value) == null ? void 0 : _.getSelectedCountryData().iso2) ?? ""), S(), I();
8465
8478
  };
8466
8479
  return E2(() => {
8467
- c.value && (g.value = C(c.value, o.options), o.value && g.value.setNumber(o.value), o.disabled && g.value.setDisabled(o.disabled));
8480
+ c.value && (f.value = C(c.value, o.options), o.value && f.value.setNumber(o.value), o.disabled && f.value.setDisabled(o.disabled));
8468
8481
  }), D2(
8469
8482
  () => o.disabled,
8470
- (v) => {
8471
- var N;
8472
- return (N = g.value) == null ? void 0 : N.setDisabled(v);
8483
+ (_) => {
8484
+ var T;
8485
+ return (T = f.value) == null ? void 0 : T.setDisabled(_);
8473
8486
  }
8474
8487
  ), M2(() => {
8475
- var v;
8476
- return (v = g.value) == null ? void 0 : v.destroy();
8477
- }), $({ instance: g, input: c }), (v, N) => P2((x2(), R2("input", B2({
8488
+ var _;
8489
+ return (_ = f.value) == null ? void 0 : _.destroy();
8490
+ }), $({ instance: f, input: c }), (_, T) => P2((x2(), R2("input", B2({
8478
8491
  ref_key: "input",
8479
8492
  ref: c,
8480
- "onUpdate:modelValue": N[0] || (N[0] = (M) => i.value = M),
8493
+ "onUpdate:modelValue": T[0] || (T[0] = (G) => i.value = G),
8481
8494
  type: "tel",
8482
- onCountrychange: L,
8483
- onInput: I
8495
+ onCountrychange: A,
8496
+ onInput: S
8484
8497
  }, y.inputProps), null, 16)), [
8485
8498
  [k2, i.value]
8486
8499
  ]);