@feedmepos/mf-inventory-portal 0.0.22-dev.41 → 0.0.22-dev.43

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.
Files changed (53) hide show
  1. package/dist/{ApprovalView-DKqwRFlF.js → ApprovalView-1ZKaZJ2Z.js} +3 -3
  2. package/dist/{BindingsDialog-CtMSqEuE.js → BindingsDialog-CKjAs5mJ.js} +1 -1
  3. package/dist/{BindingsPicker-DCLNF1PL.js → BindingsPicker-BAVZ-3dF.js} +1 -1
  4. package/dist/{BindingsTable-6ndQuHeA.js → BindingsTable-qq8M9fzG.js} +1 -1
  5. package/dist/ClosingTemplateView-DOLuHmy8.js +1775 -0
  6. package/dist/FmDroppableField-BBpVEZs4.js +154 -0
  7. package/dist/{FmFilterableMenuOptions.vue_vue_type_script_setup_true_lang-BUGB0uk3.js → FmFilterableMenuOptions.vue_vue_type_script_setup_true_lang-ChRPq-Ok.js} +3 -3
  8. package/dist/{FmInventoryTableToolbar.vue_vue_type_script_setup_true_lang-CM93v-jp.js → FmInventoryTableToolbar.vue_vue_type_script_setup_true_lang-BSxhRfE4.js} +1 -1
  9. package/dist/{IngredientBindedItem.vue_vue_type_script_setup_true_lang-SNp8etCc.js → IngredientBindedItem.vue_vue_type_script_setup_true_lang-DrL5a2Pn.js} +1 -1
  10. package/dist/{IngredientsView-B1jGkWYN.js → IngredientsView-m5K8MlM2.js} +5 -5
  11. package/dist/IntegrationView-BE5P68EJ.js +1141 -0
  12. package/dist/{NumberPrecisionInput.vue_vue_type_script_setup_true_lang-mZQlrYaY.js → NumberPrecisionInput.vue_vue_type_script_setup_true_lang-B8cCv--C.js} +1 -1
  13. package/dist/{PremiumBadge.vue_vue_type_script_setup_true_lang-BEFmqnHk.js → PremiumBadge.vue_vue_type_script_setup_true_lang-CcM04Veu.js} +2 -2
  14. package/dist/{PurchaseOrderPrintPreview-DTQViYuX.js → PurchaseOrderPrintPreview-D40E9qZt.js} +1 -1
  15. package/dist/{ReceiveRequestView-CNRixgQu.js → ReceiveRequestView-Ci7FgSjU.js} +10 -10
  16. package/dist/{RecipeView-HStPC5pE.js → RecipeView-Bp7iBiy7.js} +4 -4
  17. package/dist/{StockView-JO3NtkX9.js → StockView-BzowFcFA.js} +5 -5
  18. package/dist/SupplierView-CbRnAb8G.js +3037 -0
  19. package/dist/{TransferDetails.vue_vue_type_script_setup_true_lang-dPt3qbcX.js → TransferDetails.vue_vue_type_script_setup_true_lang-BMikyrhA.js} +5 -5
  20. package/dist/TransferTemplateView-BwamiSyk.js +1302 -0
  21. package/dist/{UnitView-dbInWUk4.js → UnitView-B-058oRk.js} +4 -4
  22. package/dist/{WarehouseView-BlTBvLF0.js → WarehouseView-RtU3sWKx.js} +2 -2
  23. package/dist/api/supplier.d.ts +1 -0
  24. package/dist/{app-TB3IWuaU.js → app-By3PLx0q.js} +3918 -3854
  25. package/dist/app.d.ts +70 -3
  26. package/dist/app.js +1 -1
  27. package/dist/components/FmMultiselectDialog.vue.d.ts +3 -9
  28. package/dist/{decimal-BRAYgPnN.js → decimal-CtriZ1S6.js} +1 -1
  29. package/dist/{defineDeepModel-DrEk5Fhq.js → defineDeepModel-ClK3S9xx.js} +1 -1
  30. package/dist/{format-time-from-id-kpVYfVQb.js → format-time-from-id-CGLKzJJO.js} +1 -1
  31. package/dist/format-unit-display-COeZSqdS.js +1195 -0
  32. package/dist/stores/netsuite.d.ts +1 -1
  33. package/dist/stores/supplier.d.ts +4 -1
  34. package/dist/style.css +1 -1
  35. package/dist/supplier-BxBMThPQ.js +77 -0
  36. package/dist/tsconfig.app.tsbuildinfo +1 -1
  37. package/dist/{use-template-enabled-locations-2-DyD24laW.js → use-template-enabled-locations-2-BIgPnzRW.js} +1 -1
  38. package/dist/views/supplier/components/supplier-import/SupplierImport.vue.d.ts +2 -0
  39. package/dist/views/supplier/components/supplier-import/SupplierImportItem.vue.d.ts +12 -0
  40. package/dist/views/supplier/components/supplier-import/SupplierImportItemProps.d.ts +6 -0
  41. package/dist/views/supplier/composables/use-supplier-actions.d.ts +10 -0
  42. package/dist/views/supplier/helpers/import-export.helper.d.ts +50 -0
  43. package/dist/views/transfer-template/composables/use-transfer-template-actions.d.ts +7 -5
  44. package/dist/{xlsx-Dd5ckm6-.js → xlsx-X_0qJPDg.js} +1 -1
  45. package/dist/{xlsx.util-qlqvEcJz.js → xlsx.util-BOPzVbUa.js} +1 -1
  46. package/package.json +2 -1
  47. package/dist/ClosingTemplateView-BPrDQ_8-.js +0 -1688
  48. package/dist/FmDroppableField-DQFPEiJn.js +0 -152
  49. package/dist/IntegrationView-Bu0waSjB.js +0 -1141
  50. package/dist/SupplierView-gtaS4K3U.js +0 -827
  51. package/dist/TransferTemplateView-C0pjLfbz.js +0 -2054
  52. package/dist/purchase-order-transaction-type-ZMNa__2l.js +0 -348
  53. package/dist/supplier-CJcqHpaM.js +0 -70
@@ -0,0 +1,3037 @@
1
+ import { defineComponent as Q, mergeModels as Kd, computed as x, useModel as Wd, resolveComponent as M, openBlock as S, createElementBlock as F, createElementVNode as g, createVNode as C, withCtx as V, toDisplayString as R, unref as v, Fragment as z, renderList as de, ref as k, createBlock as K, createCommentVNode as X, isRef as ed, normalizeClass as J, createTextVNode as Yd, watch as Fd, createSlots as Xd, onMounted as Zd, normalizeStyle as qd, Teleport as zd } from "vue";
2
+ import { u as ne } from "./supplier-BxBMThPQ.js";
3
+ import { D as dd, R as le, F as B } from "./row-action.enum-PMKMRrZR.js";
4
+ import { c as Jd, _ as Qd, F as se } from "./TableActionableRow.vue_vue_type_script_setup_true_lang-DlNJ6kRg.js";
5
+ import { c as Ne, u as Od, a3 as et, d as td, g as dt, y as tt, C as _e, h as wd, i as me, R as H, b as Ad, f as rt } from "./app-By3PLx0q.js";
6
+ import { useI18n as Z, useCoreStore as we } from "@feedmepos/mf-common";
7
+ import { useDialog as Ae, useSnackbar as ye, useProxiedModel as rd, useDialogChild as nt, useBreakpoints as ot } from "@feedmepos/ui-library";
8
+ import { u as at, _ as $t, a as it } from "./FmInventoryTableToolbar.vue_vue_type_script_setup_true_lang-BSxhRfE4.js";
9
+ import { _ as lt } from "./PreviewBadge.vue_vue_type_script_setup_true_lang-CRZiQHjx.js";
10
+ import { defineStore as st } from "pinia";
11
+ import { t as Rd, d as Td, s as ut, r as ct } from "./xlsx.util-BOPzVbUa.js";
12
+ import { F as ft } from "./FmDroppableField-BBpVEZs4.js";
13
+ function pt(e, d) {
14
+ const { t } = Z();
15
+ function r(o, a) {
16
+ if (o === le.Edit) {
17
+ e(Ne(a));
18
+ return;
19
+ }
20
+ if (o === le.Delete) {
21
+ d(Ne(a));
22
+ return;
23
+ }
24
+ }
25
+ return { columnDefs: [
26
+ {
27
+ accessorKey: "name",
28
+ header: () => t("inventory.supplier.table.supplier"),
29
+ enableSorting: !0,
30
+ size: 200
31
+ },
32
+ {
33
+ accessorKey: "contactName",
34
+ header: () => t("inventory.supplier.table.pic"),
35
+ enableSorting: !1,
36
+ size: 250
37
+ },
38
+ {
39
+ accessorKey: "phoneNumber",
40
+ header: () => t("inventory.supplier.table.contact"),
41
+ enableSorting: !1,
42
+ size: 200
43
+ },
44
+ {
45
+ accessorKey: "email",
46
+ header: () => t("inventory.supplier.table.email"),
47
+ enableSorting: !1,
48
+ size: "auto"
49
+ },
50
+ {
51
+ id: "action",
52
+ header: "",
53
+ cell(o) {
54
+ return Jd(
55
+ [dd[le.Edit], dd[le.Delete]],
56
+ (a) => {
57
+ r(a, o.row.original);
58
+ }
59
+ );
60
+ },
61
+ size: 40,
62
+ meta: {
63
+ cellClass: "",
64
+ headerClass: ""
65
+ }
66
+ }
67
+ ] };
68
+ }
69
+ const mt = { class: "flex flex-col gap-12" }, yt = { class: "flex flex-col" }, vt = { class: "flex items-center gap-8 py-8" }, gt = { class: "flex-1" }, ht = { class: "fm-typo-en-title-sm-800" }, bt = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, _t = { class: "flex flex-col gap-4" }, Pt = { class: "flex-1" }, Ct = { class: "flex flex-col" }, Nt = { class: "fm-typo-en-body-lg-400" }, St = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, Et = { class: "flex-1" }, xt = { class: "flex" }, It = { class: "text-fm-color-typo-secondary" }, Ft = /* @__PURE__ */ Q({
70
+ __name: "SupplierSupplyItemField",
71
+ props: /* @__PURE__ */ Kd({
72
+ modelValue: {}
73
+ }, {
74
+ modelValue: {},
75
+ modelModifiers: {}
76
+ }),
77
+ emits: ["update:modelValue"],
78
+ setup(e) {
79
+ const d = we(), t = Od(), r = x(() => t.skus), n = Ae(), { t: o } = Z(), a = Wd(e, "modelValue");
80
+ function i() {
81
+ var P;
82
+ const f = t.skus.map((_) => ({
83
+ label: _.name,
84
+ sublabel: _.code,
85
+ value: _._id
86
+ })), b = ((P = a.value) == null ? void 0 : P.map((_) => _.skuId)) ?? [], E = x(
87
+ () => {
88
+ var _;
89
+ return ((_ = dt(d.currentCountry.value)) == null ? void 0 : _.currency) ?? "MYR";
90
+ }
91
+ );
92
+ n.open({
93
+ title: o("inventory.supplier.supplyItems.selectItem"),
94
+ closeButton: !0,
95
+ contentComponent: tt,
96
+ contentComponentProps: {
97
+ modelValue: b,
98
+ items: f
99
+ },
100
+ primaryActions: {
101
+ text: "Confirm",
102
+ close: !0
103
+ },
104
+ secondaryActions: {
105
+ text: "Close",
106
+ close: !0,
107
+ variant: "tertiary"
108
+ }
109
+ }).onPrimary((_) => {
110
+ const p = _.map((I) => t.skuById[I]).filter((I) => I);
111
+ p.sort((I, O) => I.code.localeCompare(O.code));
112
+ const N = p.map((I) => {
113
+ var U;
114
+ const O = (U = a.value) == null ? void 0 : U.find((l) => l.skuId === I._id);
115
+ return O || {
116
+ skuId: I._id,
117
+ defaultCost: I.defaultCost ?? {
118
+ costPerUnit: {
119
+ currency: E.value,
120
+ amount: 0,
121
+ precision: 2
122
+ }
123
+ }
124
+ };
125
+ });
126
+ a.value = N;
127
+ });
128
+ }
129
+ function s(f) {
130
+ switch (f) {
131
+ case _e.MY:
132
+ return "MYR";
133
+ case _e.SG:
134
+ return "SGD";
135
+ case _e.ID:
136
+ return "IDR";
137
+ default:
138
+ return "MYR";
139
+ }
140
+ }
141
+ function u(f) {
142
+ const b = [...(a == null ? void 0 : a.value) ?? []];
143
+ b.splice(f, 1), a.value = b;
144
+ }
145
+ function m(f) {
146
+ var P;
147
+ const b = f.skuId, E = (P = r.value.find((_) => _._id === b)) == null ? void 0 : P.unit;
148
+ if (!E)
149
+ throw new Error(`Cannot find ingredient: ${b}`);
150
+ return E;
151
+ }
152
+ function c(f) {
153
+ return {
154
+ amount: f.defaultCost.costPerUnit,
155
+ measurement: f.defaultCost.measurement
156
+ };
157
+ }
158
+ function h(f, b) {
159
+ const P = (a.value ?? []).map((_) => _.skuId !== f.skuId ? _ : {
160
+ ..._,
161
+ defaultCost: {
162
+ ..._.defaultCost,
163
+ measurement: b.measurement,
164
+ costPerUnit: {
165
+ ..._.defaultCost.costPerUnit,
166
+ ...b.amount
167
+ }
168
+ }
169
+ });
170
+ a.value = P;
171
+ }
172
+ return (f, b) => {
173
+ const E = M("FmButton");
174
+ return S(), F("div", mt, [
175
+ g("div", yt, [
176
+ g("div", vt, [
177
+ g("div", gt, [
178
+ C(lt, { "z-index": 50 }, {
179
+ default: V(() => [
180
+ g("div", ht, R(v(o)("inventory.supplier.supplyItems.title")), 1)
181
+ ]),
182
+ _: 1
183
+ })
184
+ ]),
185
+ g("div", null, [
186
+ C(E, {
187
+ "prepend-icon": "link",
188
+ label: v(o)("inventory.supplier.supplyItems.addItems"),
189
+ variant: "plain",
190
+ onClick: i
191
+ }, null, 8, ["label"])
192
+ ])
193
+ ]),
194
+ g("div", bt, R(v(o)("inventory.supplier.supplyItems.overridePriceHint")), 1)
195
+ ]),
196
+ g("div", _t, [
197
+ (S(!0), F(z, null, de(a.value, (P, _) => {
198
+ var p, N, I;
199
+ return S(), F("div", {
200
+ key: P.skuId,
201
+ class: "flex"
202
+ }, [
203
+ g("div", Pt, [
204
+ g("div", Ct, [
205
+ g("div", Nt, R((p = v(t).skuById[P.skuId]) == null ? void 0 : p.name), 1),
206
+ g("div", St, R((N = v(t).skuById[P.skuId]) == null ? void 0 : N.code), 1)
207
+ ])
208
+ ]),
209
+ g("div", Et, [
210
+ g("div", xt, [
211
+ C(et, {
212
+ "model-value": c(P),
213
+ unit: m(P),
214
+ "onUpdate:modelValue": (O) => h(P, O),
215
+ placement: a.value && _ === ((I = a.value) == null ? void 0 : I.length) - 1 ? "top" : "bottom",
216
+ separator: "/",
217
+ "apply-default-rules": "",
218
+ precision: 4,
219
+ "format-minimum-precision": 2
220
+ }, {
221
+ prepend: V(() => {
222
+ var O, w;
223
+ return [
224
+ g("div", It, R(s(((O = v(d).currentCountry) == null ? void 0 : O.value) ?? v(td)) === "MYR" ? "RM" : s(((w = v(d).currentCountry) == null ? void 0 : w.value) ?? v(td))), 1)
225
+ ];
226
+ }),
227
+ _: 2
228
+ }, 1032, ["model-value", "unit", "onUpdate:modelValue", "placement"]),
229
+ g("div", null, [
230
+ C(E, {
231
+ "prepend-icon": "close",
232
+ variant: "tertiary",
233
+ onClick: (O) => u(_)
234
+ }, null, 8, ["onClick"])
235
+ ])
236
+ ])
237
+ ])
238
+ ]);
239
+ }), 128))
240
+ ])
241
+ ]);
242
+ };
243
+ }
244
+ }), Ot = { class: "flex flex-col gap-40" }, wt = { class: "flex flex-col gap-16" }, At = { key: 0 }, Rt = { class: "flex flex-col gap-8" }, Tt = { class: "fm-typo-en-title-sm-800" }, Mt = { class: "grid grid-cols-2 gap-24" }, Dt = { class: "flex flex-col gap-8" }, Lt = { class: "fm-typo-en-title-sm-800" }, kt = { class: "flex flex-col gap-16" }, Vt = {
245
+ key: 0,
246
+ class: "flex flex-col gap-8"
247
+ }, Ut = /* @__PURE__ */ Q({
248
+ __name: "SupplierForm",
249
+ props: {
250
+ modelValue: {},
251
+ disabled: { type: Boolean }
252
+ },
253
+ emits: ["update:modelValue", "validation-success"],
254
+ setup(e, { expose: d, emit: t }) {
255
+ const r = e, n = t, o = Ad(), a = Od(), i = x(() => wd(a.skus, "_id")), { t: s } = Z(), u = me(), m = x(() => u.businessLevel), c = x({
256
+ get() {
257
+ var l;
258
+ return ((l = r.modelValue) == null ? void 0 : l.name) ?? "";
259
+ },
260
+ set(l) {
261
+ const $ = r.modelValue ?? {};
262
+ $.name = l, n("update:modelValue", $);
263
+ }
264
+ }), h = x({
265
+ get() {
266
+ var l;
267
+ return ((l = r.modelValue) == null ? void 0 : l.registrationNumber) ?? "";
268
+ },
269
+ set(l) {
270
+ const $ = r.modelValue ?? {};
271
+ $.registrationNumber = l, n("update:modelValue", $);
272
+ }
273
+ }), f = x({
274
+ get() {
275
+ var l, $;
276
+ return (($ = (l = r.modelValue) == null ? void 0 : l.address) == null ? void 0 : $.line1) ?? "";
277
+ },
278
+ set(l) {
279
+ const $ = r.modelValue ?? {};
280
+ $.address ?? ($.address = {}), $.address.line1 = l, n("update:modelValue", $);
281
+ }
282
+ }), b = x({
283
+ get() {
284
+ var l, $;
285
+ return (($ = (l = r.modelValue) == null ? void 0 : l.address) == null ? void 0 : $.line2) ?? "";
286
+ },
287
+ set(l) {
288
+ const $ = r.modelValue ?? {};
289
+ $.address ?? ($.address = {}), $.address.line2 = l, n("update:modelValue", $);
290
+ }
291
+ }), E = x({
292
+ get() {
293
+ var l, $;
294
+ return (($ = (l = r.modelValue) == null ? void 0 : l.address) == null ? void 0 : $.city) ?? "";
295
+ },
296
+ set(l) {
297
+ const $ = r.modelValue ?? {};
298
+ $.address ?? ($.address = {}), $.address.city = l, n("update:modelValue", $);
299
+ }
300
+ }), P = x({
301
+ get() {
302
+ var l, $;
303
+ return (($ = (l = r.modelValue) == null ? void 0 : l.address) == null ? void 0 : $.postcode) ?? "";
304
+ },
305
+ set(l) {
306
+ const $ = r.modelValue ?? {};
307
+ $.address ?? ($.address = {}), $.address.postcode = l, n("update:modelValue", $);
308
+ }
309
+ }), _ = x({
310
+ get() {
311
+ var l, $;
312
+ return (($ = (l = r.modelValue) == null ? void 0 : l.address) == null ? void 0 : $.state) ?? "";
313
+ },
314
+ set(l) {
315
+ const $ = r.modelValue ?? {};
316
+ $.address ?? ($.address = {}), $.address.state = l, n("update:modelValue", $);
317
+ }
318
+ }), p = x({
319
+ get() {
320
+ var l, $;
321
+ return (($ = (l = r.modelValue) == null ? void 0 : l.address) == null ? void 0 : $.country) ?? "";
322
+ },
323
+ set(l) {
324
+ const $ = r.modelValue ?? {};
325
+ $.address ?? ($.address = {}), $.address.country = l, n("update:modelValue", $);
326
+ }
327
+ }), N = x({
328
+ get() {
329
+ var l;
330
+ return ((l = r.modelValue) == null ? void 0 : l.contactName) ?? "";
331
+ },
332
+ set(l) {
333
+ const $ = r.modelValue ?? {};
334
+ $.contactName = l, n("update:modelValue", $);
335
+ }
336
+ }), I = x({
337
+ get() {
338
+ var l;
339
+ return ((l = r.modelValue) == null ? void 0 : l.phoneNumber) ?? "";
340
+ },
341
+ set(l) {
342
+ const $ = r.modelValue ?? {};
343
+ $.phoneNumber = l, n("update:modelValue", $);
344
+ }
345
+ }), O = x({
346
+ get() {
347
+ var l;
348
+ return ((l = r.modelValue) == null ? void 0 : l.email) ?? "";
349
+ },
350
+ set(l) {
351
+ const $ = r.modelValue ?? {};
352
+ $.email = l, n("update:modelValue", $);
353
+ }
354
+ }), w = x({
355
+ get() {
356
+ var $;
357
+ return ((($ = r.modelValue) == null ? void 0 : $.supplyItems) ?? []).filter((ee) => i.value[ee.skuId]);
358
+ },
359
+ set(l) {
360
+ const $ = r.modelValue ?? {};
361
+ $.supplyItems = l, n("update:modelValue", $);
362
+ }
363
+ }), U = k();
364
+ return d({
365
+ validateInputs: () => {
366
+ var l, $;
367
+ ($ = (l = U.value) == null ? void 0 : l.validateInputs) == null || $.call(l);
368
+ },
369
+ resetInputsValidation: () => {
370
+ var l, $;
371
+ ($ = (l = U.value) == null ? void 0 : l.resetInputsValidation) == null || $.call(l);
372
+ },
373
+ resetInputs: () => {
374
+ var l, $;
375
+ ($ = (l = U.value) == null ? void 0 : l.resetInputs) == null || $.call(l);
376
+ }
377
+ }), (l, $) => {
378
+ const ee = M("FmChip"), T = M("FmTextField"), he = M("FmPhoneNumber"), be = M("FmForm");
379
+ return S(), K(be, {
380
+ ref_key: "formRef",
381
+ ref: U,
382
+ onValidationSuccess: $[12] || ($[12] = (y) => n("validation-success"))
383
+ }, {
384
+ default: V(() => [
385
+ g("div", Ot, [
386
+ g("div", wt, [
387
+ m.value ? (S(), F("div", At, [
388
+ C(ee, {
389
+ label: "Business supplier",
390
+ compact: ""
391
+ })
392
+ ])) : X("", !0),
393
+ C(T, {
394
+ disabled: l.disabled,
395
+ rules: [v(H)()],
396
+ "label-mark": "required",
397
+ label: v(s)("inventory.supplier.companyName"),
398
+ modelValue: c.value,
399
+ "onUpdate:modelValue": $[0] || ($[0] = (y) => c.value = y)
400
+ }, null, 8, ["disabled", "rules", "label", "modelValue"]),
401
+ C(T, {
402
+ disabled: l.disabled,
403
+ rules: [v(H)()],
404
+ "label-mark": "required",
405
+ label: v(s)("inventory.supplier.registrationNo"),
406
+ modelValue: h.value,
407
+ "onUpdate:modelValue": $[1] || ($[1] = (y) => h.value = y)
408
+ }, null, 8, ["disabled", "rules", "label", "modelValue"])
409
+ ]),
410
+ g("div", Rt, [
411
+ g("div", Tt, R(v(s)("inventory.supplier.address.title")), 1),
412
+ g("div", Mt, [
413
+ C(T, {
414
+ disabled: l.disabled,
415
+ rules: [v(H)()],
416
+ "label-mark": "required",
417
+ label: v(s)("inventory.supplier.address.line1"),
418
+ modelValue: f.value,
419
+ "onUpdate:modelValue": $[2] || ($[2] = (y) => f.value = y)
420
+ }, null, 8, ["disabled", "rules", "label", "modelValue"]),
421
+ C(T, {
422
+ disabled: l.disabled,
423
+ "label-mark": "optional",
424
+ label: v(s)("inventory.supplier.address.line2"),
425
+ modelValue: b.value,
426
+ "onUpdate:modelValue": $[3] || ($[3] = (y) => b.value = y)
427
+ }, null, 8, ["disabled", "label", "modelValue"]),
428
+ C(T, {
429
+ disabled: l.disabled,
430
+ rules: [v(H)()],
431
+ "label-mark": "required",
432
+ label: v(s)("inventory.supplier.address.city"),
433
+ modelValue: E.value,
434
+ "onUpdate:modelValue": $[4] || ($[4] = (y) => E.value = y)
435
+ }, null, 8, ["disabled", "rules", "label", "modelValue"]),
436
+ C(T, {
437
+ disabled: l.disabled,
438
+ rules: [v(H)()],
439
+ "label-mark": "required",
440
+ label: v(s)("inventory.supplier.address.postcode"),
441
+ modelValue: P.value,
442
+ "onUpdate:modelValue": $[5] || ($[5] = (y) => P.value = y)
443
+ }, null, 8, ["disabled", "rules", "label", "modelValue"]),
444
+ C(T, {
445
+ disabled: l.disabled,
446
+ rules: [v(H)()],
447
+ "label-mark": "required",
448
+ label: v(s)("inventory.supplier.address.state"),
449
+ modelValue: _.value,
450
+ "onUpdate:modelValue": $[6] || ($[6] = (y) => _.value = y)
451
+ }, null, 8, ["disabled", "rules", "label", "modelValue"]),
452
+ C(T, {
453
+ disabled: l.disabled,
454
+ rules: [v(H)()],
455
+ "label-mark": "required",
456
+ label: v(s)("inventory.supplier.address.country"),
457
+ modelValue: p.value,
458
+ "onUpdate:modelValue": $[7] || ($[7] = (y) => p.value = y)
459
+ }, null, 8, ["disabled", "rules", "label", "modelValue"])
460
+ ])
461
+ ]),
462
+ g("div", Dt, [
463
+ g("div", Lt, R(v(s)("inventory.supplier.contact.title")), 1),
464
+ g("div", kt, [
465
+ C(T, {
466
+ disabled: l.disabled,
467
+ rules: [v(H)()],
468
+ "label-mark": "required",
469
+ label: v(s)("inventory.supplier.contact.pic"),
470
+ modelValue: N.value,
471
+ "onUpdate:modelValue": $[8] || ($[8] = (y) => N.value = y)
472
+ }, null, 8, ["disabled", "rules", "label", "modelValue"]),
473
+ C(he, {
474
+ disabled: l.disabled,
475
+ rules: [v(H)()],
476
+ "label-mark": "required",
477
+ label: v(s)("inventory.supplier.contact.phoneNumber"),
478
+ modelValue: I.value,
479
+ "onUpdate:modelValue": $[9] || ($[9] = (y) => I.value = y)
480
+ }, null, 8, ["disabled", "rules", "label", "modelValue"]),
481
+ C(T, {
482
+ disabled: l.disabled,
483
+ "label-mark": "optional",
484
+ label: v(s)("inventory.supplier.contact.email"),
485
+ modelValue: O.value,
486
+ "onUpdate:modelValue": $[10] || ($[10] = (y) => O.value = y)
487
+ }, null, 8, ["disabled", "label", "modelValue"])
488
+ ])
489
+ ]),
490
+ v(o).enableTotalCost ? (S(), F("div", Vt, [
491
+ C(Ft, {
492
+ modelValue: w.value,
493
+ "onUpdate:modelValue": $[11] || ($[11] = (y) => w.value = y)
494
+ }, null, 8, ["modelValue"])
495
+ ])) : X("", !0)
496
+ ])
497
+ ]),
498
+ _: 1
499
+ }, 512);
500
+ };
501
+ }
502
+ }), Bt = { class: "flex gap-4" }, Gt = /* @__PURE__ */ Q({
503
+ __name: "SupplierDialog",
504
+ props: {
505
+ mode: {},
506
+ supplier: {},
507
+ show: { type: Boolean }
508
+ },
509
+ emits: ["update:show", "submitted"],
510
+ setup(e, { expose: d, emit: t }) {
511
+ const r = e, n = t, o = k(!1), a = ye(), { t: i } = Z(), s = ne(), u = x(() => {
512
+ switch (r.mode) {
513
+ case B.READ:
514
+ return "";
515
+ case B.UPDATE:
516
+ return i("inventory.supplier.update.title");
517
+ case B.CREATE:
518
+ return i("inventory.supplier.create.title");
519
+ }
520
+ return "";
521
+ }), m = x(() => {
522
+ switch (r.mode) {
523
+ case B.READ:
524
+ return "";
525
+ case B.UPDATE:
526
+ return i("common.save");
527
+ case B.CREATE:
528
+ return i("common.add");
529
+ }
530
+ return "";
531
+ }), c = k();
532
+ d({
533
+ validateInputs: () => {
534
+ var p, N;
535
+ (N = (p = c.value) == null ? void 0 : p.validateInputs) == null || N.call(p);
536
+ },
537
+ resetInputsValidation: () => {
538
+ var p, N;
539
+ (N = (p = c.value) == null ? void 0 : p.resetInputsValidation) == null || N.call(p);
540
+ },
541
+ resetInputs: () => {
542
+ var p, N;
543
+ (N = (p = c.value) == null ? void 0 : p.resetInputs) == null || N.call(p);
544
+ }
545
+ });
546
+ const h = rd(r, "show"), f = rd(r, "supplier");
547
+ function b() {
548
+ var p, N;
549
+ (N = (p = c.value) == null ? void 0 : p.validateInputs) == null || N.call(p);
550
+ }
551
+ function E() {
552
+ switch (r.mode) {
553
+ case B.READ:
554
+ return;
555
+ case B.UPDATE:
556
+ return _();
557
+ case B.CREATE:
558
+ return P();
559
+ }
560
+ }
561
+ async function P() {
562
+ o.value = !0;
563
+ try {
564
+ await Promise.all([
565
+ s.createSupplier(f.value),
566
+ new Promise((p) => setTimeout(p, 1e3))
567
+ ]), a.open({
568
+ title: i("inventory.common.success"),
569
+ message: i("inventory.supplier.create.success", { name: f.value.name }),
570
+ type: "success"
571
+ }), n("update:show", !1), n("submitted");
572
+ } catch (p) {
573
+ a.open({
574
+ title: "Something went wrong",
575
+ message: `Cannot create ${f.value.name} supplier. Please try again`,
576
+ type: "error"
577
+ }), console.error("cannot create supplier", p);
578
+ } finally {
579
+ o.value = !1;
580
+ }
581
+ }
582
+ async function _() {
583
+ if (f.value === null) {
584
+ a.open({
585
+ title: i("inventory.supplier.update.error.title"),
586
+ message: i("inventory.supplier.update.error.emptySupplier"),
587
+ type: "error"
588
+ });
589
+ return;
590
+ }
591
+ o.value = !0;
592
+ try {
593
+ await Promise.all([
594
+ s.updateSupplier(f.value),
595
+ new Promise((p) => setTimeout(p, 1e3))
596
+ ]), a.open({
597
+ title: i("inventory.common.success"),
598
+ message: i("inventory.supplier.update.success", { name: f.value.name }),
599
+ type: "success"
600
+ }), n("update:show", !1), n("submitted");
601
+ } catch (p) {
602
+ a.open({
603
+ title: i("inventory.supplier.update.error.title"),
604
+ message: i("inventory.supplier.update.error.message"),
605
+ type: "error"
606
+ }), console.error("cannot update supplier", p);
607
+ } finally {
608
+ o.value = !1;
609
+ }
610
+ }
611
+ return (p, N) => {
612
+ const I = M("FmButton"), O = M("FmSideSheet");
613
+ return S(), K(O, {
614
+ header: u.value,
615
+ modelValue: v(h),
616
+ "onUpdate:modelValue": N[1] || (N[1] = (w) => ed(h) ? h.value = w : null),
617
+ "dismiss-away": !o.value,
618
+ "close-button": "",
619
+ "max-width": 500
620
+ }, {
621
+ default: V(() => {
622
+ var w;
623
+ return [
624
+ (S(), K(Ut, {
625
+ class: "w-full",
626
+ ref_key: "formRef",
627
+ ref: c,
628
+ modelValue: v(f),
629
+ "onUpdate:modelValue": N[0] || (N[0] = (U) => ed(f) ? f.value = U : null),
630
+ onValidationSuccess: E,
631
+ key: ((w = p.supplier) == null ? void 0 : w._id) ?? "",
632
+ disabled: o.value
633
+ }, null, 8, ["modelValue", "disabled"]))
634
+ ];
635
+ }),
636
+ "side-sheet-footer": V(() => [
637
+ g("div", Bt, [
638
+ C(I, {
639
+ loading: o.value,
640
+ label: m.value,
641
+ onClick: b
642
+ }, null, 8, ["loading", "label"])
643
+ ])
644
+ ]),
645
+ _: 1
646
+ }, 8, ["header", "modelValue", "dismiss-away"]);
647
+ };
648
+ }
649
+ }), Ht = { version: 4, country_calling_codes: { 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"], 7: ["RU", "KZ"], 20: ["EG"], 27: ["ZA"], 30: ["GR"], 31: ["NL"], 32: ["BE"], 33: ["FR"], 34: ["ES"], 36: ["HU"], 39: ["IT", "VA"], 40: ["RO"], 41: ["CH"], 43: ["AT"], 44: ["GB", "GG", "IM", "JE"], 45: ["DK"], 46: ["SE"], 47: ["NO", "SJ"], 48: ["PL"], 49: ["DE"], 51: ["PE"], 52: ["MX"], 53: ["CU"], 54: ["AR"], 55: ["BR"], 56: ["CL"], 57: ["CO"], 58: ["VE"], 60: ["MY"], 61: ["AU", "CC", "CX"], 62: ["ID"], 63: ["PH"], 64: ["NZ"], 65: ["SG"], 66: ["TH"], 81: ["JP"], 82: ["KR"], 84: ["VN"], 86: ["CN"], 90: ["TR"], 91: ["IN"], 92: ["PK"], 93: ["AF"], 94: ["LK"], 95: ["MM"], 98: ["IR"], 211: ["SS"], 212: ["MA", "EH"], 213: ["DZ"], 216: ["TN"], 218: ["LY"], 220: ["GM"], 221: ["SN"], 222: ["MR"], 223: ["ML"], 224: ["GN"], 225: ["CI"], 226: ["BF"], 227: ["NE"], 228: ["TG"], 229: ["BJ"], 230: ["MU"], 231: ["LR"], 232: ["SL"], 233: ["GH"], 234: ["NG"], 235: ["TD"], 236: ["CF"], 237: ["CM"], 238: ["CV"], 239: ["ST"], 240: ["GQ"], 241: ["GA"], 242: ["CG"], 243: ["CD"], 244: ["AO"], 245: ["GW"], 246: ["IO"], 247: ["AC"], 248: ["SC"], 249: ["SD"], 250: ["RW"], 251: ["ET"], 252: ["SO"], 253: ["DJ"], 254: ["KE"], 255: ["TZ"], 256: ["UG"], 257: ["BI"], 258: ["MZ"], 260: ["ZM"], 261: ["MG"], 262: ["RE", "YT"], 263: ["ZW"], 264: ["NA"], 265: ["MW"], 266: ["LS"], 267: ["BW"], 268: ["SZ"], 269: ["KM"], 290: ["SH", "TA"], 291: ["ER"], 297: ["AW"], 298: ["FO"], 299: ["GL"], 350: ["GI"], 351: ["PT"], 352: ["LU"], 353: ["IE"], 354: ["IS"], 355: ["AL"], 356: ["MT"], 357: ["CY"], 358: ["FI", "AX"], 359: ["BG"], 370: ["LT"], 371: ["LV"], 372: ["EE"], 373: ["MD"], 374: ["AM"], 375: ["BY"], 376: ["AD"], 377: ["MC"], 378: ["SM"], 380: ["UA"], 381: ["RS"], 382: ["ME"], 383: ["XK"], 385: ["HR"], 386: ["SI"], 387: ["BA"], 389: ["MK"], 420: ["CZ"], 421: ["SK"], 423: ["LI"], 500: ["FK"], 501: ["BZ"], 502: ["GT"], 503: ["SV"], 504: ["HN"], 505: ["NI"], 506: ["CR"], 507: ["PA"], 508: ["PM"], 509: ["HT"], 590: ["GP", "BL", "MF"], 591: ["BO"], 592: ["GY"], 593: ["EC"], 594: ["GF"], 595: ["PY"], 596: ["MQ"], 597: ["SR"], 598: ["UY"], 599: ["CW", "BQ"], 670: ["TL"], 672: ["NF"], 673: ["BN"], 674: ["NR"], 675: ["PG"], 676: ["TO"], 677: ["SB"], 678: ["VU"], 679: ["FJ"], 680: ["PW"], 681: ["WF"], 682: ["CK"], 683: ["NU"], 685: ["WS"], 686: ["KI"], 687: ["NC"], 688: ["TV"], 689: ["PF"], 690: ["TK"], 691: ["FM"], 692: ["MH"], 850: ["KP"], 852: ["HK"], 853: ["MO"], 855: ["KH"], 856: ["LA"], 880: ["BD"], 886: ["TW"], 960: ["MV"], 961: ["LB"], 962: ["JO"], 963: ["SY"], 964: ["IQ"], 965: ["KW"], 966: ["SA"], 967: ["YE"], 968: ["OM"], 970: ["PS"], 971: ["AE"], 972: ["IL"], 973: ["BH"], 974: ["QA"], 975: ["BT"], 976: ["MN"], 977: ["NP"], 992: ["TJ"], 993: ["TM"], 994: ["AZ"], 995: ["GE"], 996: ["KG"], 998: ["UZ"] }, countries: { AC: ["247", "00", "(?:[01589]\\d|[46])\\d{4}", [5, 6]], AD: ["376", "00", "(?:1|6\\d)\\d{7}|[135-9]\\d{5}", [6, 8, 9], [["(\\d{3})(\\d{3})", "$1 $2", ["[135-9]"]], ["(\\d{4})(\\d{4})", "$1 $2", ["1"]], ["(\\d{3})(\\d{3})(\\d{3})", "$1 $2 $3", ["6"]]]], AE: ["971", "00", "(?:[4-7]\\d|9[0-689])\\d{7}|800\\d{2,9}|[2-4679]\\d{7}", [5, 6, 7, 8, 9, 10, 11, 12], [["(\\d{3})(\\d{2,9})", "$1 $2", ["60|8"]], ["(\\d)(\\d{3})(\\d{4})", "$1 $2 $3", ["[236]|[479][2-8]"], "0$1"], ["(\\d{3})(\\d)(\\d{5})", "$1 $2 $3", ["[479]"]], ["(\\d{2})(\\d{3})(\\d{4})", "$1 $2 $3", ["5"], "0$1"]], "0"], AF: ["93", "00", "[2-7]\\d{8}", [9], [["(\\d{2})(\\d{3})(\\d{4})", "$1 $2 $3", ["[2-7]"], "0$1"]], "0"], AG: ["1", "011", "(?:268|[58]\\d\\d|900)\\d{7}", [10], 0, "1", 0, "([457]\\d{6})$|1", "268$1", 0, "268"], AI: ["1", "011", "(?:264|[58]\\d\\d|900)\\d{7}", [10], 0, "1", 0, "([2457]\\d{6})$|1", "264$1", 0, "264"], AL: ["355", "00", "(?:700\\d\\d|900)\\d{3}|8\\d{5,7}|(?:[2-5]|6\\d)\\d{7}", [6, 7, 8, 9], [["(\\d{3})(\\d{3,4})", "$1 $2", ["80|9"], "0$1"], ["(\\d)(\\d{3})(\\d{4})", "$1 $2 $3", ["4[2-6]"], "0$1"], ["(\\d{2})(\\d{3})(\\d{3})", "$1 $2 $3", ["[2358][2-5]|4"], "0$1"], ["(\\d{3})(\\d{5})", "$1 $2", ["[23578]"], "0$1"], ["(\\d{2})(\\d{3})(\\d{4})", "$1 $2 $3", ["6"], "0$1"]], "0"], AM: ["374", "00", "(?:[1-489]\\d|55|60|77)\\d{6}", [8], [["(\\d{3})(\\d{2})(\\d{3})", "$1 $2 $3", ["[89]0"], "0 $1"], ["(\\d{3})(\\d{5})", "$1 $2", ["2|3[12]"], "(0$1)"], ["(\\d{2})(\\d{6})", "$1 $2", ["1|47"], "(0$1)"], ["(\\d{2})(\\d{6})", "$1 $2", ["[3-9]"], "0$1"]], "0"], AO: ["244", "00", "[29]\\d{8}", [9], [["(\\d{3})(\\d{3})(\\d{3})", "$1 $2 $3", ["[29]"]]]], AR: ["54", "00", "(?:11|[89]\\d\\d)\\d{8}|[2368]\\d{9}", [10, 11], [["(\\d{4})(\\d{2})(\\d{4})", "$1 $2-$3", ["2(?:2[024-9]|3[0-59]|47|6[245]|9[02-8])|3(?:3[28]|4[03-9]|5[2-46-8]|7[1-578]|8[2-9])", "2(?:[23]02|6(?:[25]|4[6-8])|9(?:[02356]|4[02568]|72|8[23]))|3(?:3[28]|4(?:[04679]|3[5-8]|5[4-68]|8[2379])|5(?:[2467]|3[237]|8[2-5])|7[1-578]|8(?:[2469]|3[2578]|5[4-8]|7[36-8]|8[5-8]))|2(?:2[24-9]|3[1-59]|47)", "2(?:[23]02|6(?:[25]|4(?:64|[78]))|9(?:[02356]|4(?:[0268]|5[2-6])|72|8[23]))|3(?:3[28]|4(?:[04679]|3[78]|5(?:4[46]|8)|8[2379])|5(?:[2467]|3[237]|8[23])|7[1-578]|8(?:[2469]|3[278]|5[56][46]|86[3-6]))|2(?:2[24-9]|3[1-59]|47)|38(?:[58][78]|7[378])|3(?:4[35][56]|58[45]|8(?:[38]5|54|76))[4-6]", "2(?:[23]02|6(?:[25]|4(?:64|[78]))|9(?:[02356]|4(?:[0268]|5[2-6])|72|8[23]))|3(?:3[28]|4(?:[04679]|3(?:5(?:4[0-25689]|[56])|[78])|58|8[2379])|5(?:[2467]|3[237]|8(?:[23]|4(?:[45]|60)|5(?:4[0-39]|5|64)))|7[1-578]|8(?:[2469]|3[278]|54(?:4|5[13-7]|6[89])|86[3-6]))|2(?:2[24-9]|3[1-59]|47)|38(?:[58][78]|7[378])|3(?:454|85[56])[46]|3(?:4(?:36|5[56])|8(?:[38]5|76))[4-6]"], "0$1", 1], ["(\\d{2})(\\d{4})(\\d{4})", "$1 $2-$3", ["1"], "0$1", 1], ["(\\d{3})(\\d{3})(\\d{4})", "$1-$2-$3", ["[68]"], "0$1"], ["(\\d{3})(\\d{3})(\\d{4})", "$1 $2-$3", ["[23]"], "0$1", 1], ["(\\d)(\\d{4})(\\d{2})(\\d{4})", "$2 15-$3-$4", ["9(?:2[2-469]|3[3-578])", "9(?:2(?:2[024-9]|3[0-59]|47|6[245]|9[02-8])|3(?:3[28]|4[03-9]|5[2-46-8]|7[1-578]|8[2-9]))", "9(?:2(?:[23]02|6(?:[25]|4[6-8])|9(?:[02356]|4[02568]|72|8[23]))|3(?:3[28]|4(?:[04679]|3[5-8]|5[4-68]|8[2379])|5(?:[2467]|3[237]|8[2-5])|7[1-578]|8(?:[2469]|3[2578]|5[4-8]|7[36-8]|8[5-8])))|92(?:2[24-9]|3[1-59]|47)", "9(?:2(?:[23]02|6(?:[25]|4(?:64|[78]))|9(?:[02356]|4(?:[0268]|5[2-6])|72|8[23]))|3(?:3[28]|4(?:[04679]|3[78]|5(?:4[46]|8)|8[2379])|5(?:[2467]|3[237]|8[23])|7[1-578]|8(?:[2469]|3[278]|5(?:[56][46]|[78])|7[378]|8(?:6[3-6]|[78]))))|92(?:2[24-9]|3[1-59]|47)|93(?:4[35][56]|58[45]|8(?:[38]5|54|76))[4-6]", "9(?:2(?:[23]02|6(?:[25]|4(?:64|[78]))|9(?:[02356]|4(?:[0268]|5[2-6])|72|8[23]))|3(?:3[28]|4(?:[04679]|3(?:5(?:4[0-25689]|[56])|[78])|5(?:4[46]|8)|8[2379])|5(?:[2467]|3[237]|8(?:[23]|4(?:[45]|60)|5(?:4[0-39]|5|64)))|7[1-578]|8(?:[2469]|3[278]|5(?:4(?:4|5[13-7]|6[89])|[56][46]|[78])|7[378]|8(?:6[3-6]|[78]))))|92(?:2[24-9]|3[1-59]|47)|93(?:4(?:36|5[56])|8(?:[38]5|76))[4-6]"], "0$1", 0, "$1 $2 $3-$4"], ["(\\d)(\\d{2})(\\d{4})(\\d{4})", "$2 15-$3-$4", ["91"], "0$1", 0, "$1 $2 $3-$4"], ["(\\d{3})(\\d{3})(\\d{5})", "$1-$2-$3", ["8"], "0$1"], ["(\\d)(\\d{3})(\\d{3})(\\d{4})", "$2 15-$3-$4", ["9"], "0$1", 0, "$1 $2 $3-$4"]], "0", 0, "0?(?:(11|2(?:2(?:02?|[13]|2[13-79]|4[1-6]|5[2457]|6[124-8]|7[1-4]|8[13-6]|9[1267])|3(?:02?|1[467]|2[03-6]|3[13-8]|[49][2-6]|5[2-8]|[67])|4(?:7[3-578]|9)|6(?:[0136]|2[24-6]|4[6-8]?|5[15-8])|80|9(?:0[1-3]|[19]|2\\d|3[1-6]|4[02568]?|5[2-4]|6[2-46]|72?|8[23]?))|3(?:3(?:2[79]|6|8[2578])|4(?:0[0-24-9]|[12]|3[5-8]?|4[24-7]|5[4-68]?|6[02-9]|7[126]|8[2379]?|9[1-36-8])|5(?:1|2[1245]|3[237]?|4[1-46-9]|6[2-4]|7[1-6]|8[2-5]?)|6[24]|7(?:[069]|1[1568]|2[15]|3[145]|4[13]|5[14-8]|7[2-57]|8[126])|8(?:[01]|2[15-7]|3[2578]?|4[13-6]|5[4-8]?|6[1-357-9]|7[36-8]?|8[5-8]?|9[124])))15)?", "9$1"], AS: ["1", "011", "(?:[58]\\d\\d|684|900)\\d{7}", [10], 0, "1", 0, "([267]\\d{6})$|1", "684$1", 0, "684"], AT: ["43", "00", "1\\d{3,12}|2\\d{6,12}|43(?:(?:0\\d|5[02-9])\\d{3,9}|2\\d{4,5}|[3467]\\d{4}|8\\d{4,6}|9\\d{4,7})|5\\d{4,12}|8\\d{7,12}|9\\d{8,12}|(?:[367]\\d|4[0-24-9])\\d{4,11}", [4, 5, 6, 7, 8, 9, 10, 11, 12, 13], [["(\\d)(\\d{3,12})", "$1 $2", ["1(?:11|[2-9])"], "0$1"], ["(\\d{3})(\\d{2})", "$1 $2", ["517"], "0$1"], ["(\\d{2})(\\d{3,5})", "$1 $2", ["5[079]"], "0$1"], ["(\\d{3})(\\d{3,10})", "$1 $2", ["(?:31|4)6|51|6(?:5[0-3579]|[6-9])|7(?:20|32|8)|[89]"], "0$1"], ["(\\d{4})(\\d{3,9})", "$1 $2", ["[2-467]|5[2-6]"], "0$1"], ["(\\d{2})(\\d{3})(\\d{3,4})", "$1 $2 $3", ["5"], "0$1"], ["(\\d{2})(\\d{4})(\\d{4,7})", "$1 $2 $3", ["5"], "0$1"]], "0"], AU: ["61", "001[14-689]|14(?:1[14]|34|4[17]|[56]6|7[47]|88)0011", "1(?:[0-79]\\d{7}(?:\\d(?:\\d{2})?)?|8[0-24-9]\\d{7})|[2-478]\\d{8}|1\\d{4,7}", [5, 6, 7, 8, 9, 10, 12], [["(\\d{2})(\\d{3,4})", "$1 $2", ["16"], "0$1"], ["(\\d{2})(\\d{3})(\\d{2,4})", "$1 $2 $3", ["16"], "0$1"], ["(\\d{3})(\\d{3})(\\d{3})", "$1 $2 $3", ["14|4"], "0$1"], ["(\\d)(\\d{4})(\\d{4})", "$1 $2 $3", ["[2378]"], "(0$1)"], ["(\\d{4})(\\d{3})(\\d{3})", "$1 $2 $3", ["1(?:30|[89])"]]], "0", 0, "(183[12])|0", 0, 0, 0, [["(?:(?:(?:2(?:[0-26-9]\\d|3[0-8]|4[02-9]|5[0135-9])|7(?:[013-57-9]\\d|2[0-8]))\\d|3(?:(?:[0-3589]\\d|6[1-9]|7[0-35-9])\\d|4(?:[0-578]\\d|90)))\\d\\d|8(?:51(?:0(?:0[03-9]|[12479]\\d|3[2-9]|5[0-8]|6[1-9]|8[0-7])|1(?:[0235689]\\d|1[0-69]|4[0-589]|7[0-47-9])|2(?:0[0-79]|[18][13579]|2[14-9]|3[0-46-9]|[4-6]\\d|7[89]|9[0-4])|3\\d\\d)|(?:6[0-8]|[78]\\d)\\d{3}|9(?:[02-9]\\d{3}|1(?:(?:[0-58]\\d|6[0135-9])\\d|7(?:0[0-24-9]|[1-9]\\d)|9(?:[0-46-9]\\d|5[0-79])))))\\d{3}", [9]], ["4(?:79[01]|83[0-389]|94[0-4])\\d{5}|4(?:[0-36]\\d|4[047-9]|5[0-25-9]|7[02-8]|8[0-24-9]|9[0-37-9])\\d{6}", [9]], ["180(?:0\\d{3}|2)\\d{3}", [7, 10]], ["190[0-26]\\d{6}", [10]], 0, 0, 0, ["163\\d{2,6}", [5, 6, 7, 8, 9]], ["14(?:5(?:1[0458]|[23][458])|71\\d)\\d{4}", [9]], ["13(?:00\\d{6}(?:\\d{2})?|45[0-4]\\d{3})|13\\d{4}", [6, 8, 10, 12]]], "0011"], AW: ["297", "00", "(?:[25-79]\\d\\d|800)\\d{4}", [7], [["(\\d{3})(\\d{4})", "$1 $2", ["[25-9]"]]]], AX: ["358", "00|99(?:[01469]|5(?:[14]1|3[23]|5[59]|77|88|9[09]))", "2\\d{4,9}|35\\d{4,5}|(?:60\\d\\d|800)\\d{4,6}|7\\d{5,11}|(?:[14]\\d|3[0-46-9]|50)\\d{4,8}", [5, 6, 7, 8, 9, 10, 11, 12], 0, "0", 0, 0, 0, 0, "18", 0, "00"], AZ: ["994", "00", "365\\d{6}|(?:[124579]\\d|60|88)\\d{7}", [9], [["(\\d{3})(\\d{2})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["90"], "0$1"], ["(\\d{2})(\\d{3})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["1[28]|2|365|46", "1[28]|2|365[45]|46", "1[28]|2|365(?:4|5[02])|46"], "(0$1)"], ["(\\d{2})(\\d{3})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["[13-9]"], "0$1"]], "0"], BA: ["387", "00", "6\\d{8}|(?:[35689]\\d|49|70)\\d{6}", [8, 9], [["(\\d{2})(\\d{3})(\\d{3})", "$1 $2 $3", ["6[1-3]|[7-9]"], "0$1"], ["(\\d{2})(\\d{3})(\\d{3})", "$1 $2-$3", ["[3-5]|6[56]"], "0$1"], ["(\\d{2})(\\d{2})(\\d{2})(\\d{3})", "$1 $2 $3 $4", ["6"], "0$1"]], "0"], BB: ["1", "011", "(?:246|[58]\\d\\d|900)\\d{7}", [10], 0, "1", 0, "([2-9]\\d{6})$|1", "246$1", 0, "246"], BD: ["880", "00", "[1-469]\\d{9}|8[0-79]\\d{7,8}|[2-79]\\d{8}|[2-9]\\d{7}|[3-9]\\d{6}|[57-9]\\d{5}", [6, 7, 8, 9, 10], [["(\\d{2})(\\d{4,6})", "$1-$2", ["31[5-8]|[459]1"], "0$1"], ["(\\d{3})(\\d{3,7})", "$1-$2", ["3(?:[67]|8[013-9])|4(?:6[168]|7|[89][18])|5(?:6[128]|9)|6(?:[15]|28|4[14])|7[2-589]|8(?:0[014-9]|[12])|9[358]|(?:3[2-5]|4[235]|5[2-578]|6[0389]|76|8[3-7]|9[24])1|(?:44|66)[01346-9]"], "0$1"], ["(\\d{4})(\\d{3,6})", "$1-$2", ["[13-9]|2[23]"], "0$1"], ["(\\d)(\\d{7,8})", "$1-$2", ["2"], "0$1"]], "0"], BE: ["32", "00", "4\\d{8}|[1-9]\\d{7}", [8, 9], [["(\\d{3})(\\d{2})(\\d{3})", "$1 $2 $3", ["(?:80|9)0"], "0$1"], ["(\\d)(\\d{3})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["[239]|4[23]"], "0$1"], ["(\\d{2})(\\d{2})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["[15-8]"], "0$1"], ["(\\d{3})(\\d{2})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["4"], "0$1"]], "0"], BF: ["226", "00", "[025-7]\\d{7}", [8], [["(\\d{2})(\\d{2})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["[025-7]"]]]], BG: ["359", "00", "00800\\d{7}|[2-7]\\d{6,7}|[89]\\d{6,8}|2\\d{5}", [6, 7, 8, 9, 12], [["(\\d)(\\d)(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["2"], "0$1"], ["(\\d{3})(\\d{4})", "$1 $2", ["43[1-6]|70[1-9]"], "0$1"], ["(\\d)(\\d{3})(\\d{3,4})", "$1 $2 $3", ["2"], "0$1"], ["(\\d{2})(\\d{3})(\\d{2,3})", "$1 $2 $3", ["[356]|4[124-7]|7[1-9]|8[1-6]|9[1-7]"], "0$1"], ["(\\d{3})(\\d{2})(\\d{3})", "$1 $2 $3", ["(?:70|8)0"], "0$1"], ["(\\d{3})(\\d{3})(\\d{2})", "$1 $2 $3", ["43[1-7]|7"], "0$1"], ["(\\d{2})(\\d{3})(\\d{3,4})", "$1 $2 $3", ["[48]|9[08]"], "0$1"], ["(\\d{3})(\\d{3})(\\d{3})", "$1 $2 $3", ["9"], "0$1"]], "0"], BH: ["973", "00", "[136-9]\\d{7}", [8], [["(\\d{4})(\\d{4})", "$1 $2", ["[13679]|8[02-4679]"]]]], BI: ["257", "00", "(?:[267]\\d|31)\\d{6}", [8], [["(\\d{2})(\\d{2})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["[2367]"]]]], BJ: ["229", "00", "(?:01\\d|[24-689])\\d{7}", [8, 10], [["(\\d{2})(\\d{2})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["[24-689]"]], ["(\\d{2})(\\d{2})(\\d{2})(\\d{2})(\\d{2})", "$1 $2 $3 $4 $5", ["0"]]]], BL: ["590", "00", "(?:590\\d|7090)\\d{5}|(?:69|80|9\\d)\\d{7}", [9], 0, "0", 0, 0, 0, 0, 0, [["590(?:2[7-9]|3[3-7]|5[12]|87)\\d{4}"], ["(?:69(?:0\\d\\d|1(?:2[2-9]|3[0-5])|4(?:0[89]|1[2-6]|9\\d)|6(?:1[016-9]|5[0-4]|[67]\\d))|7090[0-4])\\d{4}"], ["80[0-5]\\d{6}"], 0, 0, 0, 0, 0, ["9(?:(?:39[5-7]|76[018])\\d|475[0-5])\\d{4}"]]], BM: ["1", "011", "(?:441|[58]\\d\\d|900)\\d{7}", [10], 0, "1", 0, "([2-9]\\d{6})$|1", "441$1", 0, "441"], BN: ["673", "00", "[2-578]\\d{6}", [7], [["(\\d{3})(\\d{4})", "$1 $2", ["[2-578]"]]]], BO: ["591", "00(?:1\\d)?", "8001\\d{5}|(?:[2-467]\\d|50)\\d{6}", [8, 9], [["(\\d)(\\d{7})", "$1 $2", ["[235]|4[46]"]], ["(\\d{8})", "$1", ["[67]"]], ["(\\d{3})(\\d{2})(\\d{4})", "$1 $2 $3", ["8"]]], "0", 0, "0(1\\d)?"], BQ: ["599", "00", "(?:[34]1|7\\d)\\d{5}", [7], 0, 0, 0, 0, 0, 0, "[347]"], BR: ["55", "00(?:1[245]|2[1-35]|31|4[13]|[56]5|99)", "(?:[1-46-9]\\d\\d|5(?:[0-46-9]\\d|5[0-46-9]))\\d{8}|[1-9]\\d{9}|[3589]\\d{8}|[34]\\d{7}", [8, 9, 10, 11], [["(\\d{4})(\\d{4})", "$1-$2", ["300|4(?:0[02]|37)", "4(?:02|37)0|[34]00"]], ["(\\d{3})(\\d{2,3})(\\d{4})", "$1 $2 $3", ["(?:[358]|90)0"], "0$1"], ["(\\d{2})(\\d{4})(\\d{4})", "$1 $2-$3", ["(?:[14689][1-9]|2[12478]|3[1-578]|5[13-5]|7[13-579])[2-57]"], "($1)"], ["(\\d{2})(\\d{5})(\\d{4})", "$1 $2-$3", ["[16][1-9]|[2-57-9]"], "($1)"]], "0", 0, "(?:0|90)(?:(1[245]|2[1-35]|31|4[13]|[56]5|99)(\\d{10,11}))?", "$2"], BS: ["1", "011", "(?:242|[58]\\d\\d|900)\\d{7}", [10], 0, "1", 0, "([3-8]\\d{6})$|1", "242$1", 0, "242"], BT: ["975", "00", "[17]\\d{7}|[2-8]\\d{6}", [7, 8], [["(\\d)(\\d{3})(\\d{3})", "$1 $2 $3", ["[2-68]|7[246]"]], ["(\\d{2})(\\d{2})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["1[67]|7"]]]], BW: ["267", "00", "(?:0800|(?:[37]|800)\\d)\\d{6}|(?:[2-6]\\d|90)\\d{5}", [7, 8, 10], [["(\\d{2})(\\d{5})", "$1 $2", ["90"]], ["(\\d{3})(\\d{4})", "$1 $2", ["[24-6]|3[15-9]"]], ["(\\d{2})(\\d{3})(\\d{3})", "$1 $2 $3", ["[37]"]], ["(\\d{4})(\\d{3})(\\d{3})", "$1 $2 $3", ["0"]], ["(\\d{3})(\\d{4})(\\d{3})", "$1 $2 $3", ["8"]]]], BY: ["375", "810", "(?:[12]\\d|33|44|902)\\d{7}|8(?:0[0-79]\\d{5,7}|[1-7]\\d{9})|8(?:1[0-489]|[5-79]\\d)\\d{7}|8[1-79]\\d{6,7}|8[0-79]\\d{5}|8\\d{5}", [6, 7, 8, 9, 10, 11], [["(\\d{3})(\\d{3})", "$1 $2", ["800"], "8 $1"], ["(\\d{3})(\\d{2})(\\d{2,4})", "$1 $2 $3", ["800"], "8 $1"], ["(\\d{4})(\\d{2})(\\d{3})", "$1 $2-$3", ["1(?:5[169]|6[3-5]|7[179])|2(?:1[35]|2[34]|3[3-5])", "1(?:5[169]|6(?:3[1-3]|4|5[125])|7(?:1[3-9]|7[0-24-6]|9[2-7]))|2(?:1[35]|2[34]|3[3-5])"], "8 0$1"], ["(\\d{3})(\\d{2})(\\d{2})(\\d{2})", "$1 $2-$3-$4", ["1(?:[56]|7[467])|2[1-3]"], "8 0$1"], ["(\\d{2})(\\d{3})(\\d{2})(\\d{2})", "$1 $2-$3-$4", ["[1-4]"], "8 0$1"], ["(\\d{3})(\\d{3,4})(\\d{4})", "$1 $2 $3", ["[89]"], "8 $1"]], "8", 0, "0|80?", 0, 0, 0, 0, "8~10"], BZ: ["501", "00", "(?:0800\\d|[2-8])\\d{6}", [7, 11], [["(\\d{3})(\\d{4})", "$1-$2", ["[2-8]"]], ["(\\d)(\\d{3})(\\d{4})(\\d{3})", "$1-$2-$3-$4", ["0"]]]], CA: ["1", "011", "[2-9]\\d{9}|3\\d{6}", [7, 10], 0, "1", 0, 0, 0, 0, 0, [["(?:2(?:04|[23]6|[48]9|50|63)|3(?:06|43|54|6[578]|82)|4(?:03|1[68]|[26]8|3[178]|50|74)|5(?:06|1[49]|48|79|8[147])|6(?:04|[18]3|39|47|72)|7(?:0[59]|42|53|78|8[02])|8(?:[06]7|19|25|7[39])|9(?:0[25]|42))[2-9]\\d{6}", [10]], ["", [10]], ["8(?:00|33|44|55|66|77|88)[2-9]\\d{6}", [10]], ["900[2-9]\\d{6}", [10]], ["52(?:3(?:[2-46-9][02-9]\\d|5(?:[02-46-9]\\d|5[0-46-9]))|4(?:[2-478][02-9]\\d|5(?:[034]\\d|2[024-9]|5[0-46-9])|6(?:0[1-9]|[2-9]\\d)|9(?:[05-9]\\d|2[0-5]|49)))\\d{4}|52[34][2-9]1[02-9]\\d{4}|(?:5(?:2[125-9]|33|44|66|77|88)|6(?:22|33))[2-9]\\d{6}", [10]], 0, ["310\\d{4}", [7]], 0, ["600[2-9]\\d{6}", [10]]]], CC: ["61", "001[14-689]|14(?:1[14]|34|4[17]|[56]6|7[47]|88)0011", "1(?:[0-79]\\d{8}(?:\\d{2})?|8[0-24-9]\\d{7})|[148]\\d{8}|1\\d{5,7}", [6, 7, 8, 9, 10, 12], 0, "0", 0, "([59]\\d{7})$|0", "8$1", 0, 0, [["8(?:51(?:0(?:02|31|60|89)|1(?:18|76)|223)|91(?:0(?:1[0-2]|29)|1(?:[28]2|50|79)|2(?:10|64)|3(?:[06]8|22)|4[29]8|62\\d|70[23]|959))\\d{3}", [9]], ["4(?:79[01]|83[0-389]|94[0-4])\\d{5}|4(?:[0-36]\\d|4[047-9]|5[0-25-9]|7[02-8]|8[0-24-9]|9[0-37-9])\\d{6}", [9]], ["180(?:0\\d{3}|2)\\d{3}", [7, 10]], ["190[0-26]\\d{6}", [10]], 0, 0, 0, 0, ["14(?:5(?:1[0458]|[23][458])|71\\d)\\d{4}", [9]], ["13(?:00\\d{6}(?:\\d{2})?|45[0-4]\\d{3})|13\\d{4}", [6, 8, 10, 12]]], "0011"], CD: ["243", "00", "(?:(?:[189]|5\\d)\\d|2)\\d{7}|[1-68]\\d{6}", [7, 8, 9, 10], [["(\\d{2})(\\d{2})(\\d{3})", "$1 $2 $3", ["88"], "0$1"], ["(\\d{2})(\\d{5})", "$1 $2", ["[1-6]"], "0$1"], ["(\\d{2})(\\d{2})(\\d{4})", "$1 $2 $3", ["2"], "0$1"], ["(\\d{2})(\\d{3})(\\d{4})", "$1 $2 $3", ["1"], "0$1"], ["(\\d{3})(\\d{3})(\\d{3})", "$1 $2 $3", ["[89]"], "0$1"], ["(\\d{2})(\\d{2})(\\d{3})(\\d{3})", "$1 $2 $3 $4", ["5"], "0$1"]], "0"], CF: ["236", "00", "(?:[27]\\d{3}|8776)\\d{4}", [8], [["(\\d{2})(\\d{2})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["[278]"]]]], CG: ["242", "00", "222\\d{6}|(?:0\\d|80)\\d{7}", [9], [["(\\d)(\\d{4})(\\d{4})", "$1 $2 $3", ["8"]], ["(\\d{2})(\\d{3})(\\d{4})", "$1 $2 $3", ["[02]"]]]], CH: ["41", "00", "8\\d{11}|[2-9]\\d{8}", [9, 12], [["(\\d{3})(\\d{3})(\\d{3})", "$1 $2 $3", ["8[047]|90"], "0$1"], ["(\\d{2})(\\d{3})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["[2-79]|81"], "0$1"], ["(\\d{3})(\\d{2})(\\d{3})(\\d{2})(\\d{2})", "$1 $2 $3 $4 $5", ["8"], "0$1"]], "0"], CI: ["225", "00", "[02]\\d{9}", [10], [["(\\d{2})(\\d{2})(\\d)(\\d{5})", "$1 $2 $3 $4", ["2"]], ["(\\d{2})(\\d{2})(\\d{2})(\\d{4})", "$1 $2 $3 $4", ["0"]]]], CK: ["682", "00", "[2-578]\\d{4}", [5], [["(\\d{2})(\\d{3})", "$1 $2", ["[2-578]"]]]], CL: ["56", "(?:0|1(?:1[0-69]|2[02-5]|5[13-58]|69|7[0167]|8[018]))0", "12300\\d{6}|6\\d{9,10}|[2-9]\\d{8}", [9, 10, 11], [["(\\d{5})(\\d{4})", "$1 $2", ["219", "2196"], "($1)"], ["(\\d{2})(\\d{3})(\\d{4})", "$1 $2 $3", ["44"]], ["(\\d)(\\d{4})(\\d{4})", "$1 $2 $3", ["2[1-36]"], "($1)"], ["(\\d)(\\d{4})(\\d{4})", "$1 $2 $3", ["9[2-9]"]], ["(\\d{2})(\\d{3})(\\d{4})", "$1 $2 $3", ["3[2-5]|[47]|5[1-3578]|6[13-57]|8(?:0[1-9]|[1-9])"], "($1)"], ["(\\d{3})(\\d{3})(\\d{3,4})", "$1 $2 $3", ["60|8"]], ["(\\d{4})(\\d{3})(\\d{4})", "$1 $2 $3", ["1"]], ["(\\d{3})(\\d{3})(\\d{2})(\\d{3})", "$1 $2 $3 $4", ["60"]]]], CM: ["237", "00", "[26]\\d{8}|88\\d{6,7}", [8, 9], [["(\\d{2})(\\d{2})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["88"]], ["(\\d)(\\d{2})(\\d{2})(\\d{2})(\\d{2})", "$1 $2 $3 $4 $5", ["[26]|88"]]]], CN: ["86", "00|1(?:[12]\\d|79)\\d\\d00", "(?:(?:1[03-689]|2\\d)\\d\\d|6)\\d{8}|1\\d{10}|[126]\\d{6}(?:\\d(?:\\d{2})?)?|86\\d{5,6}|(?:[3-579]\\d|8[0-57-9])\\d{5,9}", [7, 8, 9, 10, 11, 12], [["(\\d{2})(\\d{5,6})", "$1 $2", ["(?:10|2[0-57-9])[19]|3(?:[157]|35|49|9[1-68])|4(?:1[124-9]|2[179]|6[47-9]|7|8[23])|5(?:[1357]|2[37]|4[36]|6[1-46]|80)|6(?:3[1-5]|6[0238]|9[12])|7(?:01|[1579]|2[248]|3[014-9]|4[3-6]|6[023689])|8(?:07|1[236-8]|2[5-7]|[37]|8[36-8]|9[1-8])|9(?:0[1-3689]|1[1-79]|3|4[13]|5[1-5]|7[0-79]|9[0-35-9])|(?:4[35]|59|85)[1-9]", "(?:10|2[0-57-9])(?:1[02]|9[56])|8078|(?:3(?:[157]\\d|35|49|9[1-68])|4(?:1[124-9]|2[179]|[35][1-9]|6[47-9]|7\\d|8[23])|5(?:[1357]\\d|2[37]|4[36]|6[1-46]|80|9[1-9])|6(?:3[1-5]|6[0238]|9[12])|7(?:01|[1579]\\d|2[248]|3[014-9]|4[3-6]|6[023689])|8(?:1[236-8]|2[5-7]|[37]\\d|5[1-9]|8[36-8]|9[1-8])|9(?:0[1-3689]|1[1-79]|3\\d|4[13]|5[1-5]|7[0-79]|9[0-35-9]))1", "10(?:1(?:0|23)|9[56])|2[0-57-9](?:1(?:00|23)|9[56])|80781|(?:3(?:[157]\\d|35|49|9[1-68])|4(?:1[124-9]|2[179]|[35][1-9]|6[47-9]|7\\d|8[23])|5(?:[1357]\\d|2[37]|4[36]|6[1-46]|80|9[1-9])|6(?:3[1-5]|6[0238]|9[12])|7(?:01|[1579]\\d|2[248]|3[014-9]|4[3-6]|6[023689])|8(?:1[236-8]|2[5-7]|[37]\\d|5[1-9]|8[36-8]|9[1-8])|9(?:0[1-3689]|1[1-79]|3\\d|4[13]|5[1-5]|7[0-79]|9[0-35-9]))12", "10(?:1(?:0|23)|9[56])|2[0-57-9](?:1(?:00|23)|9[56])|807812|(?:3(?:[157]\\d|35|49|9[1-68])|4(?:1[124-9]|2[179]|[35][1-9]|6[47-9]|7\\d|8[23])|5(?:[1357]\\d|2[37]|4[36]|6[1-46]|80|9[1-9])|6(?:3[1-5]|6[0238]|9[12])|7(?:01|[1579]\\d|2[248]|3[014-9]|4[3-6]|6[023689])|8(?:1[236-8]|2[5-7]|[37]\\d|5[1-9]|8[36-8]|9[1-8])|9(?:0[1-3689]|1[1-79]|3\\d|4[13]|5[1-5]|7[0-79]|9[0-35-9]))123", "10(?:1(?:0|23)|9[56])|2[0-57-9](?:1(?:00|23)|9[56])|(?:3(?:[157]\\d|35|49|9[1-68])|4(?:1[124-9]|2[179]|[35][1-9]|6[47-9]|7\\d|8[23])|5(?:[1357]\\d|2[37]|4[36]|6[1-46]|80|9[1-9])|6(?:3[1-5]|6[0238]|9[12])|7(?:01|[1579]\\d|2[248]|3[014-9]|4[3-6]|6[023689])|8(?:078|1[236-8]|2[5-7]|[37]\\d|5[1-9]|8[36-8]|9[1-8])|9(?:0[1-3689]|1[1-79]|3\\d|4[13]|5[1-5]|7[0-79]|9[0-35-9]))123"], "0$1"], ["(\\d{3})(\\d{5,6})", "$1 $2", ["3(?:[157]|35|49|9[1-68])|4(?:[17]|2[179]|6[47-9]|8[23])|5(?:[1357]|2[37]|4[36]|6[1-46]|80)|6(?:3[1-5]|6[0238]|9[12])|7(?:01|[1579]|2[248]|3[014-9]|4[3-6]|6[023689])|8(?:1[236-8]|2[5-7]|[37]|8[36-8]|9[1-8])|9(?:0[1-3689]|1[1-79]|[379]|4[13]|5[1-5])|(?:4[35]|59|85)[1-9]", "(?:3(?:[157]\\d|35|49|9[1-68])|4(?:[17]\\d|2[179]|[35][1-9]|6[47-9]|8[23])|5(?:[1357]\\d|2[37]|4[36]|6[1-46]|80|9[1-9])|6(?:3[1-5]|6[0238]|9[12])|7(?:01|[1579]\\d|2[248]|3[014-9]|4[3-6]|6[023689])|8(?:1[236-8]|2[5-7]|[37]\\d|5[1-9]|8[36-8]|9[1-8])|9(?:0[1-3689]|1[1-79]|[379]\\d|4[13]|5[1-5]))[19]", "85[23](?:10|95)|(?:3(?:[157]\\d|35|49|9[1-68])|4(?:[17]\\d|2[179]|[35][1-9]|6[47-9]|8[23])|5(?:[1357]\\d|2[37]|4[36]|6[1-46]|80|9[1-9])|6(?:3[1-5]|6[0238]|9[12])|7(?:01|[1579]\\d|2[248]|3[014-9]|4[3-6]|6[023689])|8(?:1[236-8]|2[5-7]|[37]\\d|5[14-9]|8[36-8]|9[1-8])|9(?:0[1-3689]|1[1-79]|[379]\\d|4[13]|5[1-5]))(?:10|9[56])", "85[23](?:100|95)|(?:3(?:[157]\\d|35|49|9[1-68])|4(?:[17]\\d|2[179]|[35][1-9]|6[47-9]|8[23])|5(?:[1357]\\d|2[37]|4[36]|6[1-46]|80|9[1-9])|6(?:3[1-5]|6[0238]|9[12])|7(?:01|[1579]\\d|2[248]|3[014-9]|4[3-6]|6[023689])|8(?:1[236-8]|2[5-7]|[37]\\d|5[14-9]|8[36-8]|9[1-8])|9(?:0[1-3689]|1[1-79]|[379]\\d|4[13]|5[1-5]))(?:100|9[56])"], "0$1"], ["(\\d{3})(\\d{3})(\\d{4})", "$1 $2 $3", ["(?:4|80)0"]], ["(\\d{2})(\\d{4})(\\d{4})", "$1 $2 $3", ["10|2(?:[02-57-9]|1[1-9])", "10|2(?:[02-57-9]|1[1-9])", "10[0-79]|2(?:[02-57-9]|1[1-79])|(?:10|21)8(?:0[1-9]|[1-9])"], "0$1", 1], ["(\\d{3})(\\d{3})(\\d{4})", "$1 $2 $3", ["3(?:[3-59]|7[02-68])|4(?:[26-8]|3[3-9]|5[2-9])|5(?:3[03-9]|[468]|7[028]|9[2-46-9])|6|7(?:[0-247]|3[04-9]|5[0-4689]|6[2368])|8(?:[1-358]|9[1-7])|9(?:[013479]|5[1-5])|(?:[34]1|55|79|87)[02-9]"], "0$1", 1], ["(\\d{3})(\\d{7,8})", "$1 $2", ["9"]], ["(\\d{4})(\\d{3})(\\d{4})", "$1 $2 $3", ["80"], "0$1", 1], ["(\\d{3})(\\d{4})(\\d{4})", "$1 $2 $3", ["[3-578]"], "0$1", 1], ["(\\d{3})(\\d{4})(\\d{4})", "$1 $2 $3", ["1[3-9]"]], ["(\\d{2})(\\d{3})(\\d{3})(\\d{4})", "$1 $2 $3 $4", ["[12]"], "0$1", 1]], "0", 0, "(1(?:[12]\\d|79)\\d\\d)|0", 0, 0, 0, 0, "00"], CO: ["57", "00(?:4(?:[14]4|56)|[579])", "(?:46|60\\d\\d)\\d{6}|(?:1\\d|[39])\\d{9}", [8, 10, 11], [["(\\d{4})(\\d{4})", "$1 $2", ["46"]], ["(\\d{3})(\\d{7})", "$1 $2", ["6|90"], "($1)"], ["(\\d{3})(\\d{7})", "$1 $2", ["3[0-357]|91"]], ["(\\d)(\\d{3})(\\d{7})", "$1-$2-$3", ["1"], "0$1", 0, "$1 $2 $3"]], "0", 0, "0([3579]|4(?:[14]4|56))?"], CR: ["506", "00", "(?:8\\d|90)\\d{8}|(?:[24-8]\\d{3}|3005)\\d{4}", [8, 10], [["(\\d{4})(\\d{4})", "$1 $2", ["[2-7]|8[3-9]"]], ["(\\d{3})(\\d{3})(\\d{4})", "$1-$2-$3", ["[89]"]]], 0, 0, "(19(?:0[0-2468]|1[09]|20|66|77|99))"], CU: ["53", "119", "(?:[2-7]|8\\d\\d)\\d{7}|[2-47]\\d{6}|[34]\\d{5}", [6, 7, 8, 10], [["(\\d{2})(\\d{4,6})", "$1 $2", ["2[1-4]|[34]"], "(0$1)"], ["(\\d)(\\d{6,7})", "$1 $2", ["7"], "(0$1)"], ["(\\d)(\\d{7})", "$1 $2", ["[56]"], "0$1"], ["(\\d{3})(\\d{7})", "$1 $2", ["8"], "0$1"]], "0"], CV: ["238", "0", "(?:[2-59]\\d\\d|800)\\d{4}", [7], [["(\\d{3})(\\d{2})(\\d{2})", "$1 $2 $3", ["[2-589]"]]]], CW: ["599", "00", "(?:[34]1|60|(?:7|9\\d)\\d)\\d{5}", [7, 8], [["(\\d{3})(\\d{4})", "$1 $2", ["[3467]"]], ["(\\d)(\\d{3})(\\d{4})", "$1 $2 $3", ["9[4-8]"]]], 0, 0, 0, 0, 0, "[69]"], CX: ["61", "001[14-689]|14(?:1[14]|34|4[17]|[56]6|7[47]|88)0011", "1(?:[0-79]\\d{8}(?:\\d{2})?|8[0-24-9]\\d{7})|[148]\\d{8}|1\\d{5,7}", [6, 7, 8, 9, 10, 12], 0, "0", 0, "([59]\\d{7})$|0", "8$1", 0, 0, [["8(?:51(?:0(?:01|30|59|88)|1(?:17|46|75)|2(?:22|35))|91(?:00[6-9]|1(?:[28]1|49|78)|2(?:09|63)|3(?:12|26|75)|4(?:56|97)|64\\d|7(?:0[01]|1[0-2])|958))\\d{3}", [9]], ["4(?:79[01]|83[0-389]|94[0-4])\\d{5}|4(?:[0-36]\\d|4[047-9]|5[0-25-9]|7[02-8]|8[0-24-9]|9[0-37-9])\\d{6}", [9]], ["180(?:0\\d{3}|2)\\d{3}", [7, 10]], ["190[0-26]\\d{6}", [10]], 0, 0, 0, 0, ["14(?:5(?:1[0458]|[23][458])|71\\d)\\d{4}", [9]], ["13(?:00\\d{6}(?:\\d{2})?|45[0-4]\\d{3})|13\\d{4}", [6, 8, 10, 12]]], "0011"], CY: ["357", "00", "(?:[279]\\d|[58]0)\\d{6}", [8], [["(\\d{2})(\\d{6})", "$1 $2", ["[257-9]"]]]], CZ: ["420", "00", "(?:[2-578]\\d|60)\\d{7}|9\\d{8,11}", [9, 10, 11, 12], [["(\\d{3})(\\d{3})(\\d{3})", "$1 $2 $3", ["[2-8]|9[015-7]"]], ["(\\d{2})(\\d{3})(\\d{3})(\\d{2})", "$1 $2 $3 $4", ["96"]], ["(\\d{2})(\\d{3})(\\d{3})(\\d{3})", "$1 $2 $3 $4", ["9"]], ["(\\d{3})(\\d{3})(\\d{3})(\\d{3})", "$1 $2 $3 $4", ["9"]]]], DE: ["49", "00", "[2579]\\d{5,14}|49(?:[34]0|69|8\\d)\\d\\d?|49(?:37|49|60|7[089]|9\\d)\\d{1,3}|49(?:2[024-9]|3[2-689]|7[1-7])\\d{1,8}|(?:1|[368]\\d|4[0-8])\\d{3,13}|49(?:[015]\\d|2[13]|31|[46][1-8])\\d{1,9}", [4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15], [["(\\d{2})(\\d{3,13})", "$1 $2", ["3[02]|40|[68]9"], "0$1"], ["(\\d{3})(\\d{3,12})", "$1 $2", ["2(?:0[1-389]|1[124]|2[18]|3[14])|3(?:[35-9][15]|4[015])|906|(?:2[4-9]|4[2-9]|[579][1-9]|[68][1-8])1", "2(?:0[1-389]|12[0-8])|3(?:[35-9][15]|4[015])|906|2(?:[13][14]|2[18])|(?:2[4-9]|4[2-9]|[579][1-9]|[68][1-8])1"], "0$1"], ["(\\d{4})(\\d{2,11})", "$1 $2", ["[24-6]|3(?:[3569][02-46-9]|4[2-4679]|7[2-467]|8[2-46-8])|70[2-8]|8(?:0[2-9]|[1-8])|90[7-9]|[79][1-9]", "[24-6]|3(?:3(?:0[1-467]|2[127-9]|3[124578]|7[1257-9]|8[1256]|9[145])|4(?:2[135]|4[13578]|9[1346])|5(?:0[14]|2[1-3589]|6[1-4]|7[13468]|8[13568])|6(?:2[1-489]|3[124-6]|6[13]|7[12579]|8[1-356]|9[135])|7(?:2[1-7]|4[145]|6[1-5]|7[1-4])|8(?:21|3[1468]|6|7[1467]|8[136])|9(?:0[12479]|2[1358]|4[134679]|6[1-9]|7[136]|8[147]|9[1468]))|70[2-8]|8(?:0[2-9]|[1-8])|90[7-9]|[79][1-9]|3[68]4[1347]|3(?:47|60)[1356]|3(?:3[46]|46|5[49])[1246]|3[4579]3[1357]"], "0$1"], ["(\\d{3})(\\d{4})", "$1 $2", ["138"], "0$1"], ["(\\d{5})(\\d{2,10})", "$1 $2", ["3"], "0$1"], ["(\\d{3})(\\d{5,11})", "$1 $2", ["181"], "0$1"], ["(\\d{3})(\\d)(\\d{4,10})", "$1 $2 $3", ["1(?:3|80)|9"], "0$1"], ["(\\d{3})(\\d{7,8})", "$1 $2", ["1[67]"], "0$1"], ["(\\d{3})(\\d{7,12})", "$1 $2", ["8"], "0$1"], ["(\\d{5})(\\d{6})", "$1 $2", ["185", "1850", "18500"], "0$1"], ["(\\d{3})(\\d{4})(\\d{4})", "$1 $2 $3", ["7"], "0$1"], ["(\\d{4})(\\d{7})", "$1 $2", ["18[68]"], "0$1"], ["(\\d{4})(\\d{7})", "$1 $2", ["15[1279]"], "0$1"], ["(\\d{5})(\\d{6})", "$1 $2", ["15[03568]", "15(?:[0568]|31)"], "0$1"], ["(\\d{3})(\\d{8})", "$1 $2", ["18"], "0$1"], ["(\\d{3})(\\d{2})(\\d{7,8})", "$1 $2 $3", ["1(?:6[023]|7)"], "0$1"], ["(\\d{4})(\\d{2})(\\d{7})", "$1 $2 $3", ["15[279]"], "0$1"], ["(\\d{3})(\\d{2})(\\d{8})", "$1 $2 $3", ["15"], "0$1"]], "0"], DJ: ["253", "00", "(?:2\\d|77)\\d{6}", [8], [["(\\d{2})(\\d{2})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["[27]"]]]], DK: ["45", "00", "[2-9]\\d{7}", [8], [["(\\d{2})(\\d{2})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["[2-9]"]]]], DM: ["1", "011", "(?:[58]\\d\\d|767|900)\\d{7}", [10], 0, "1", 0, "([2-7]\\d{6})$|1", "767$1", 0, "767"], DO: ["1", "011", "(?:[58]\\d\\d|900)\\d{7}", [10], 0, "1", 0, 0, 0, 0, "8001|8[024]9"], DZ: ["213", "00", "(?:[1-4]|[5-79]\\d|80)\\d{7}", [8, 9], [["(\\d{2})(\\d{2})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["[1-4]"], "0$1"], ["(\\d{2})(\\d{3})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["9"], "0$1"], ["(\\d{3})(\\d{2})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["[5-8]"], "0$1"]], "0"], EC: ["593", "00", "1\\d{9,10}|(?:[2-7]|9\\d)\\d{7}", [8, 9, 10, 11], [["(\\d)(\\d{3})(\\d{4})", "$1 $2-$3", ["[2-7]"], "(0$1)", 0, "$1-$2-$3"], ["(\\d{2})(\\d{3})(\\d{4})", "$1 $2 $3", ["9"], "0$1"], ["(\\d{4})(\\d{3})(\\d{3,4})", "$1 $2 $3", ["1"]]], "0"], EE: ["372", "00", "8\\d{9}|[4578]\\d{7}|(?:[3-8]\\d|90)\\d{5}", [7, 8, 10], [["(\\d{3})(\\d{4})", "$1 $2", ["[369]|4[3-8]|5(?:[0-2]|5[0-478]|6[45])|7[1-9]|88", "[369]|4[3-8]|5(?:[02]|1(?:[0-8]|95)|5[0-478]|6(?:4[0-4]|5[1-589]))|7[1-9]|88"]], ["(\\d{4})(\\d{3,4})", "$1 $2", ["[45]|8(?:00|[1-49])", "[45]|8(?:00[1-9]|[1-49])"]], ["(\\d{2})(\\d{2})(\\d{4})", "$1 $2 $3", ["7"]], ["(\\d{4})(\\d{3})(\\d{3})", "$1 $2 $3", ["8"]]]], EG: ["20", "00", "[189]\\d{8,9}|[24-6]\\d{8}|[135]\\d{7}", [8, 9, 10], [["(\\d)(\\d{7,8})", "$1 $2", ["[23]"], "0$1"], ["(\\d{2})(\\d{6,7})", "$1 $2", ["1[35]|[4-6]|8[2468]|9[235-7]"], "0$1"], ["(\\d{3})(\\d{3})(\\d{4})", "$1 $2 $3", ["[89]"], "0$1"], ["(\\d{2})(\\d{8})", "$1 $2", ["1"], "0$1"]], "0"], EH: ["212", "00", "[5-8]\\d{8}", [9], 0, "0", 0, 0, 0, 0, "528[89]"], ER: ["291", "00", "[178]\\d{6}", [7], [["(\\d)(\\d{3})(\\d{3})", "$1 $2 $3", ["[178]"], "0$1"]], "0"], ES: ["34", "00", "[5-9]\\d{8}", [9], [["(\\d{3})(\\d{3})(\\d{3})", "$1 $2 $3", ["[89]00"]], ["(\\d{3})(\\d{2})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["[5-9]"]]]], ET: ["251", "00", "(?:11|[2-579]\\d)\\d{7}", [9], [["(\\d{2})(\\d{3})(\\d{4})", "$1 $2 $3", ["[1-579]"], "0$1"]], "0"], FI: ["358", "00|99(?:[01469]|5(?:[14]1|3[23]|5[59]|77|88|9[09]))", "[1-35689]\\d{4}|7\\d{10,11}|(?:[124-7]\\d|3[0-46-9])\\d{8}|[1-9]\\d{5,8}", [5, 6, 7, 8, 9, 10, 11, 12], [["(\\d{5})", "$1", ["20[2-59]"], "0$1"], ["(\\d{3})(\\d{3,7})", "$1 $2", ["(?:[1-3]0|[68])0|70[07-9]"], "0$1"], ["(\\d{2})(\\d{4,8})", "$1 $2", ["[14]|2[09]|50|7[135]"], "0$1"], ["(\\d{2})(\\d{6,10})", "$1 $2", ["7"], "0$1"], ["(\\d)(\\d{4,9})", "$1 $2", ["(?:19|[2568])[1-8]|3(?:0[1-9]|[1-9])|9"], "0$1"]], "0", 0, 0, 0, 0, "1[03-79]|[2-9]", 0, "00"], FJ: ["679", "0(?:0|52)", "45\\d{5}|(?:0800\\d|[235-9])\\d{6}", [7, 11], [["(\\d{3})(\\d{4})", "$1 $2", ["[235-9]|45"]], ["(\\d{4})(\\d{3})(\\d{4})", "$1 $2 $3", ["0"]]], 0, 0, 0, 0, 0, 0, 0, "00"], FK: ["500", "00", "[2-7]\\d{4}", [5]], FM: ["691", "00", "(?:[39]\\d\\d|820)\\d{4}", [7], [["(\\d{3})(\\d{4})", "$1 $2", ["[389]"]]]], FO: ["298", "00", "[2-9]\\d{5}", [6], [["(\\d{6})", "$1", ["[2-9]"]]], 0, 0, "(10(?:01|[12]0|88))"], FR: ["33", "00", "[1-9]\\d{8}", [9], [["(\\d{3})(\\d{2})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["8"], "0 $1"], ["(\\d)(\\d{2})(\\d{2})(\\d{2})(\\d{2})", "$1 $2 $3 $4 $5", ["[1-79]"], "0$1"]], "0"], GA: ["241", "00", "(?:[067]\\d|11)\\d{6}|[2-7]\\d{6}", [7, 8], [["(\\d)(\\d{2})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["[2-7]"], "0$1"], ["(\\d{2})(\\d{2})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["0"]], ["(\\d{2})(\\d{2})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["11|[67]"], "0$1"]], 0, 0, "0(11\\d{6}|60\\d{6}|61\\d{6}|6[256]\\d{6}|7[467]\\d{6})", "$1"], GB: ["44", "00", "[1-357-9]\\d{9}|[18]\\d{8}|8\\d{6}", [7, 9, 10], [["(\\d{3})(\\d{4})", "$1 $2", ["800", "8001", "80011", "800111", "8001111"], "0$1"], ["(\\d{3})(\\d{2})(\\d{2})", "$1 $2 $3", ["845", "8454", "84546", "845464"], "0$1"], ["(\\d{3})(\\d{6})", "$1 $2", ["800"], "0$1"], ["(\\d{5})(\\d{4,5})", "$1 $2", ["1(?:38|5[23]|69|76|94)", "1(?:(?:38|69)7|5(?:24|39)|768|946)", "1(?:3873|5(?:242|39[4-6])|(?:697|768)[347]|9467)"], "0$1"], ["(\\d{4})(\\d{5,6})", "$1 $2", ["1(?:[2-69][02-9]|[78])"], "0$1"], ["(\\d{2})(\\d{4})(\\d{4})", "$1 $2 $3", ["[25]|7(?:0|6[02-9])", "[25]|7(?:0|6(?:[03-9]|2[356]))"], "0$1"], ["(\\d{4})(\\d{6})", "$1 $2", ["7"], "0$1"], ["(\\d{3})(\\d{3})(\\d{4})", "$1 $2 $3", ["[1389]"], "0$1"]], "0", 0, 0, 0, 0, 0, [["(?:1(?:1(?:3(?:[0-58]\\d\\d|73[0-35])|4(?:(?:[0-5]\\d|70)\\d|69[7-9])|(?:(?:5[0-26-9]|[78][0-49])\\d|6(?:[0-4]\\d|50))\\d)|(?:2(?:(?:0[024-9]|2[3-9]|3[3-79]|4[1-689]|[58][02-9]|6[0-47-9]|7[013-9]|9\\d)\\d|1(?:[0-7]\\d|8[0-3]))|(?:3(?:0\\d|1[0-8]|[25][02-9]|3[02-579]|[468][0-46-9]|7[1-35-79]|9[2-578])|4(?:0[03-9]|[137]\\d|[28][02-57-9]|4[02-69]|5[0-8]|[69][0-79])|5(?:0[1-35-9]|[16]\\d|2[024-9]|3[015689]|4[02-9]|5[03-9]|7[0-35-9]|8[0-468]|9[0-57-9])|6(?:0[034689]|1\\d|2[0-35689]|[38][013-9]|4[1-467]|5[0-69]|6[13-9]|7[0-8]|9[0-24578])|7(?:0[0246-9]|2\\d|3[0236-8]|4[03-9]|5[0-46-9]|6[013-9]|7[0-35-9]|8[024-9]|9[02-9])|8(?:0[35-9]|2[1-57-9]|3[02-578]|4[0-578]|5[124-9]|6[2-69]|7\\d|8[02-9]|9[02569])|9(?:0[02-589]|[18]\\d|2[02-689]|3[1-57-9]|4[2-9]|5[0-579]|6[2-47-9]|7[0-24578]|9[2-57]))\\d)\\d)|2(?:0[013478]|3[0189]|4[017]|8[0-46-9]|9[0-2])\\d{3})\\d{4}|1(?:2(?:0(?:46[1-4]|87[2-9])|545[1-79]|76(?:2\\d|3[1-8]|6[1-6])|9(?:7(?:2[0-4]|3[2-5])|8(?:2[2-8]|7[0-47-9]|8[3-5])))|3(?:6(?:38[2-5]|47[23])|8(?:47[04-9]|64[0157-9]))|4(?:044[1-7]|20(?:2[23]|8\\d)|6(?:0(?:30|5[2-57]|6[1-8]|7[2-8])|140)|8(?:052|87[1-3]))|5(?:2(?:4(?:3[2-79]|6\\d)|76\\d)|6(?:26[06-9]|686))|6(?:06(?:4\\d|7[4-79])|295[5-7]|35[34]\\d|47(?:24|61)|59(?:5[08]|6[67]|74)|9(?:55[0-4]|77[23]))|7(?:26(?:6[13-9]|7[0-7])|(?:442|688)\\d|50(?:2[0-3]|[3-68]2|76))|8(?:27[56]\\d|37(?:5[2-5]|8[239])|843[2-58])|9(?:0(?:0(?:6[1-8]|85)|52\\d)|3583|4(?:66[1-8]|9(?:2[01]|81))|63(?:23|3[1-4])|9561))\\d{3}", [9, 10]], ["7(?:457[0-57-9]|700[01]|911[028])\\d{5}|7(?:[1-3]\\d\\d|4(?:[0-46-9]\\d|5[0-689])|5(?:0[0-8]|[13-9]\\d|2[0-35-9])|7(?:0[1-9]|[1-7]\\d|8[02-9]|9[0-689])|8(?:[014-9]\\d|[23][0-8])|9(?:[024-9]\\d|1[02-9]|3[0-689]))\\d{6}", [10]], ["80[08]\\d{7}|800\\d{6}|8001111"], ["(?:8(?:4[2-5]|7[0-3])|9(?:[01]\\d|8[2-49]))\\d{7}|845464\\d", [7, 10]], ["70\\d{8}", [10]], 0, ["(?:3[0347]|55)\\d{8}", [10]], ["76(?:464|652)\\d{5}|76(?:0[0-28]|2[356]|34|4[01347]|5[49]|6[0-369]|77|8[14]|9[139])\\d{6}", [10]], ["56\\d{8}", [10]]], 0, " x"], GD: ["1", "011", "(?:473|[58]\\d\\d|900)\\d{7}", [10], 0, "1", 0, "([2-9]\\d{6})$|1", "473$1", 0, "473"], GE: ["995", "00", "(?:[3-57]\\d\\d|800)\\d{6}", [9], [["(\\d{3})(\\d{3})(\\d{3})", "$1 $2 $3", ["70"], "0$1"], ["(\\d{2})(\\d{3})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["32"], "0$1"], ["(\\d{3})(\\d{2})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["[57]"]], ["(\\d{3})(\\d{2})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["[348]"], "0$1"]], "0"], GF: ["594", "00", "(?:[56]94\\d|7093)\\d{5}|(?:80|9\\d)\\d{7}", [9], [["(\\d{3})(\\d{2})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["[5-7]|9[47]"], "0$1"], ["(\\d{3})(\\d{2})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["[89]"], "0$1"]], "0"], GG: ["44", "00", "(?:1481|[357-9]\\d{3})\\d{6}|8\\d{6}(?:\\d{2})?", [7, 9, 10], 0, "0", 0, "([25-9]\\d{5})$|0", "1481$1", 0, 0, [["1481[25-9]\\d{5}", [10]], ["7(?:(?:781|839)\\d|911[17])\\d{5}", [10]], ["80[08]\\d{7}|800\\d{6}|8001111"], ["(?:8(?:4[2-5]|7[0-3])|9(?:[01]\\d|8[0-3]))\\d{7}|845464\\d", [7, 10]], ["70\\d{8}", [10]], 0, ["(?:3[0347]|55)\\d{8}", [10]], ["76(?:464|652)\\d{5}|76(?:0[0-28]|2[356]|34|4[01347]|5[49]|6[0-369]|77|8[14]|9[139])\\d{6}", [10]], ["56\\d{8}", [10]]]], GH: ["233", "00", "(?:[235]\\d{3}|800)\\d{5}", [8, 9], [["(\\d{3})(\\d{5})", "$1 $2", ["8"], "0$1"], ["(\\d{2})(\\d{3})(\\d{4})", "$1 $2 $3", ["[235]"], "0$1"]], "0"], GI: ["350", "00", "(?:[25]\\d|60)\\d{6}", [8], [["(\\d{3})(\\d{5})", "$1 $2", ["2"]]]], GL: ["299", "00", "(?:19|[2-689]\\d|70)\\d{4}", [6], [["(\\d{2})(\\d{2})(\\d{2})", "$1 $2 $3", ["19|[2-9]"]]]], GM: ["220", "00", "[2-9]\\d{6}", [7], [["(\\d{3})(\\d{4})", "$1 $2", ["[2-9]"]]]], GN: ["224", "00", "722\\d{6}|(?:3|6\\d)\\d{7}", [8, 9], [["(\\d{2})(\\d{2})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["3"]], ["(\\d{3})(\\d{2})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["[67]"]]]], GP: ["590", "00", "(?:590\\d|7090)\\d{5}|(?:69|80|9\\d)\\d{7}", [9], [["(\\d{3})(\\d{2})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["[5-79]"], "0$1"], ["(\\d{3})(\\d{2})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["8"], "0$1"]], "0", 0, 0, 0, 0, 0, [["590(?:0[1-68]|[14][0-24-9]|2[0-68]|3[1-9]|5[3-579]|[68][0-689]|7[08]|9\\d)\\d{4}"], ["(?:69(?:0\\d\\d|1(?:2[2-9]|3[0-5])|4(?:0[89]|1[2-6]|9\\d)|6(?:1[016-9]|5[0-4]|[67]\\d))|7090[0-4])\\d{4}"], ["80[0-5]\\d{6}"], 0, 0, 0, 0, 0, ["9(?:(?:39[5-7]|76[018])\\d|475[0-5])\\d{4}"]]], GQ: ["240", "00", "222\\d{6}|(?:3\\d|55|[89]0)\\d{7}", [9], [["(\\d{3})(\\d{3})(\\d{3})", "$1 $2 $3", ["[235]"]], ["(\\d{3})(\\d{6})", "$1 $2", ["[89]"]]]], GR: ["30", "00", "5005000\\d{3}|8\\d{9,11}|(?:[269]\\d|70)\\d{8}", [10, 11, 12], [["(\\d{2})(\\d{4})(\\d{4})", "$1 $2 $3", ["21|7"]], ["(\\d{4})(\\d{6})", "$1 $2", ["2(?:2|3[2-57-9]|4[2-469]|5[2-59]|6[2-9]|7[2-69]|8[2-49])|5"]], ["(\\d{3})(\\d{3})(\\d{4})", "$1 $2 $3", ["[2689]"]], ["(\\d{3})(\\d{3,4})(\\d{5})", "$1 $2 $3", ["8"]]]], GT: ["502", "00", "80\\d{6}|(?:1\\d{3}|[2-7])\\d{7}", [8, 11], [["(\\d{4})(\\d{4})", "$1 $2", ["[2-8]"]], ["(\\d{4})(\\d{3})(\\d{4})", "$1 $2 $3", ["1"]]]], GU: ["1", "011", "(?:[58]\\d\\d|671|900)\\d{7}", [10], 0, "1", 0, "([2-9]\\d{6})$|1", "671$1", 0, "671"], GW: ["245", "00", "[49]\\d{8}|4\\d{6}", [7, 9], [["(\\d{3})(\\d{4})", "$1 $2", ["40"]], ["(\\d{3})(\\d{3})(\\d{3})", "$1 $2 $3", ["[49]"]]]], GY: ["592", "001", "(?:[2-8]\\d{3}|9008)\\d{3}", [7], [["(\\d{3})(\\d{4})", "$1 $2", ["[2-9]"]]]], HK: ["852", "00(?:30|5[09]|[126-9]?)", "8[0-46-9]\\d{6,7}|9\\d{4,7}|(?:[2-7]|9\\d{3})\\d{7}", [5, 6, 7, 8, 9, 11], [["(\\d{3})(\\d{2,5})", "$1 $2", ["900", "9003"]], ["(\\d{4})(\\d{4})", "$1 $2", ["[2-7]|8[1-4]|9(?:0[1-9]|[1-8])"]], ["(\\d{3})(\\d{3})(\\d{3})", "$1 $2 $3", ["8"]], ["(\\d{3})(\\d{2})(\\d{3})(\\d{3})", "$1 $2 $3 $4", ["9"]]], 0, 0, 0, 0, 0, 0, 0, "00"], HN: ["504", "00", "8\\d{10}|[237-9]\\d{7}", [8, 11], [["(\\d{4})(\\d{4})", "$1-$2", ["[237-9]"]]]], HR: ["385", "00", "(?:[24-69]\\d|3[0-79])\\d{7}|80\\d{5,7}|[1-79]\\d{7}|6\\d{5,6}", [6, 7, 8, 9], [["(\\d{2})(\\d{2})(\\d{2,3})", "$1 $2 $3", ["6[01]"], "0$1"], ["(\\d{3})(\\d{2})(\\d{2,3})", "$1 $2 $3", ["8"], "0$1"], ["(\\d)(\\d{4})(\\d{3})", "$1 $2 $3", ["1"], "0$1"], ["(\\d{2})(\\d{3})(\\d{3,4})", "$1 $2 $3", ["6|7[245]"], "0$1"], ["(\\d{2})(\\d{3})(\\d{3,4})", "$1 $2 $3", ["9"], "0$1"], ["(\\d{2})(\\d{3})(\\d{3,4})", "$1 $2 $3", ["[2-57]"], "0$1"], ["(\\d{3})(\\d{3})(\\d{3})", "$1 $2 $3", ["8"], "0$1"]], "0"], HT: ["509", "00", "(?:[2-489]\\d|55)\\d{6}", [8], [["(\\d{2})(\\d{2})(\\d{4})", "$1 $2 $3", ["[2-589]"]]]], HU: ["36", "00", "[235-7]\\d{8}|[1-9]\\d{7}", [8, 9], [["(\\d)(\\d{3})(\\d{4})", "$1 $2 $3", ["1"], "(06 $1)"], ["(\\d{2})(\\d{3})(\\d{3})", "$1 $2 $3", ["[27][2-9]|3[2-7]|4[24-9]|5[2-79]|6|8[2-57-9]|9[2-69]"], "(06 $1)"], ["(\\d{2})(\\d{3})(\\d{3,4})", "$1 $2 $3", ["[2-9]"], "06 $1"]], "06"], ID: ["62", "00[89]", "00[1-9]\\d{9,14}|(?:[1-36]|8\\d{5})\\d{6}|00\\d{9}|[1-9]\\d{8,10}|[2-9]\\d{7}", [7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17], [["(\\d)(\\d{3})(\\d{3})", "$1 $2 $3", ["15"]], ["(\\d{2})(\\d{5,9})", "$1 $2", ["2[124]|[36]1"], "(0$1)"], ["(\\d{3})(\\d{5,7})", "$1 $2", ["800"], "0$1"], ["(\\d{3})(\\d{5,8})", "$1 $2", ["[2-79]"], "(0$1)"], ["(\\d{3})(\\d{3,4})(\\d{3})", "$1-$2-$3", ["8[1-35-9]"], "0$1"], ["(\\d{3})(\\d{6,8})", "$1 $2", ["1"], "0$1"], ["(\\d{3})(\\d{3})(\\d{4})", "$1 $2 $3", ["804"], "0$1"], ["(\\d{3})(\\d)(\\d{3})(\\d{3})", "$1 $2 $3 $4", ["80"], "0$1"], ["(\\d{3})(\\d{4})(\\d{4,5})", "$1-$2-$3", ["8"], "0$1"]], "0"], IE: ["353", "00", "(?:1\\d|[2569])\\d{6,8}|4\\d{6,9}|7\\d{8}|8\\d{8,9}", [7, 8, 9, 10], [["(\\d{2})(\\d{5})", "$1 $2", ["2[24-9]|47|58|6[237-9]|9[35-9]"], "(0$1)"], ["(\\d{3})(\\d{5})", "$1 $2", ["[45]0"], "(0$1)"], ["(\\d)(\\d{3,4})(\\d{4})", "$1 $2 $3", ["1"], "(0$1)"], ["(\\d{2})(\\d{3})(\\d{3,4})", "$1 $2 $3", ["[2569]|4[1-69]|7[14]"], "(0$1)"], ["(\\d{3})(\\d{3})(\\d{3})", "$1 $2 $3", ["70"], "0$1"], ["(\\d{3})(\\d{3})(\\d{3})", "$1 $2 $3", ["81"], "(0$1)"], ["(\\d{2})(\\d{3})(\\d{4})", "$1 $2 $3", ["[78]"], "0$1"], ["(\\d{4})(\\d{3})(\\d{3})", "$1 $2 $3", ["1"]], ["(\\d{2})(\\d{4})(\\d{4})", "$1 $2 $3", ["4"], "(0$1)"], ["(\\d{2})(\\d)(\\d{3})(\\d{4})", "$1 $2 $3 $4", ["8"], "0$1"]], "0"], IL: ["972", "0(?:0|1[2-9])", "1\\d{6}(?:\\d{3,5})?|[57]\\d{8}|[1-489]\\d{7}", [7, 8, 9, 10, 11, 12], [["(\\d{4})(\\d{3})", "$1-$2", ["125"]], ["(\\d{4})(\\d{2})(\\d{2})", "$1-$2-$3", ["121"]], ["(\\d)(\\d{3})(\\d{4})", "$1-$2-$3", ["[2-489]"], "0$1"], ["(\\d{2})(\\d{3})(\\d{4})", "$1-$2-$3", ["[57]"], "0$1"], ["(\\d{4})(\\d{3})(\\d{3})", "$1-$2-$3", ["12"]], ["(\\d{4})(\\d{6})", "$1-$2", ["159"]], ["(\\d)(\\d{3})(\\d{3})(\\d{3})", "$1-$2-$3-$4", ["1[7-9]"]], ["(\\d{3})(\\d{1,2})(\\d{3})(\\d{4})", "$1-$2 $3-$4", ["15"]]], "0"], IM: ["44", "00", "1624\\d{6}|(?:[3578]\\d|90)\\d{8}", [10], 0, "0", 0, "([25-8]\\d{5})$|0", "1624$1", 0, "74576|(?:16|7[56])24"], IN: ["91", "00", "(?:000800|[2-9]\\d\\d)\\d{7}|1\\d{7,12}", [8, 9, 10, 11, 12, 13], [["(\\d{8})", "$1", ["5(?:0|2[23]|3[03]|[67]1|88)", "5(?:0|2(?:21|3)|3(?:0|3[23])|616|717|888)", "5(?:0|2(?:21|3)|3(?:0|3[23])|616|717|8888)"], 0, 1], ["(\\d{4})(\\d{4,5})", "$1 $2", ["180", "1800"], 0, 1], ["(\\d{3})(\\d{3})(\\d{4})", "$1 $2 $3", ["140"], 0, 1], ["(\\d{2})(\\d{4})(\\d{4})", "$1 $2 $3", ["11|2[02]|33|4[04]|79[1-7]|80[2-46]", "11|2[02]|33|4[04]|79(?:[1-6]|7[19])|80(?:[2-4]|6[0-589])", "11|2[02]|33|4[04]|79(?:[124-6]|3(?:[02-9]|1[0-24-9])|7(?:1|9[1-6]))|80(?:[2-4]|6[0-589])"], "0$1", 1], ["(\\d{3})(\\d{3})(\\d{4})", "$1 $2 $3", ["1(?:2[0-249]|3[0-25]|4[145]|[68]|7[1257])|2(?:1[257]|3[013]|4[01]|5[0137]|6[0158]|78|8[1568])|3(?:26|4[1-3]|5[34]|6[01489]|7[02-46]|8[159])|4(?:1[36]|2[1-47]|5[12]|6[0-26-9]|7[0-24-9]|8[013-57]|9[014-7])|5(?:1[025]|22|[36][25]|4[28]|5[12]|[78]1)|6(?:12|[2-4]1|5[17]|6[13]|80)|7(?:12|3[134]|4[47]|61|88)|8(?:16|2[014]|3[126]|6[136]|7[078]|8[34]|91)|(?:43|59|75)[15]|(?:1[59]|29|67|72)[14]", "1(?:2[0-24]|3[0-25]|4[145]|[59][14]|6[1-9]|7[1257]|8[1-57-9])|2(?:1[257]|3[013]|4[01]|5[0137]|6[058]|78|8[1568]|9[14])|3(?:26|4[1-3]|5[34]|6[01489]|7[02-46]|8[159])|4(?:1[36]|2[1-47]|3[15]|5[12]|6[0-26-9]|7[0-24-9]|8[013-57]|9[014-7])|5(?:1[025]|22|[36][25]|4[28]|[578]1|9[15])|674|7(?:(?:2[14]|3[34]|5[15])[2-6]|61[346]|88[0-8])|8(?:70[2-6]|84[235-7]|91[3-7])|(?:1(?:29|60|8[06])|261|552|6(?:12|[2-47]1|5[17]|6[13]|80)|7(?:12|31|4[47])|8(?:16|2[014]|3[126]|6[136]|7[78]|83))[2-7]", "1(?:2[0-24]|3[0-25]|4[145]|[59][14]|6[1-9]|7[1257]|8[1-57-9])|2(?:1[257]|3[013]|4[01]|5[0137]|6[058]|78|8[1568]|9[14])|3(?:26|4[1-3]|5[34]|6[01489]|7[02-46]|8[159])|4(?:1[36]|2[1-47]|3[15]|5[12]|6[0-26-9]|7[0-24-9]|8[013-57]|9[014-7])|5(?:1[025]|22|[36][25]|4[28]|[578]1|9[15])|6(?:12(?:[2-6]|7[0-8])|74[2-7])|7(?:(?:2[14]|5[15])[2-6]|3171|61[346]|88(?:[2-7]|82))|8(?:70[2-6]|84(?:[2356]|7[19])|91(?:[3-6]|7[19]))|73[134][2-6]|(?:74[47]|8(?:16|2[014]|3[126]|6[136]|7[78]|83))(?:[2-6]|7[19])|(?:1(?:29|60|8[06])|261|552|6(?:[2-4]1|5[17]|6[13]|7(?:1|4[0189])|80)|7(?:12|88[01]))[2-7]"], "0$1", 1], ["(\\d{4})(\\d{3})(\\d{3})", "$1 $2 $3", ["1(?:[2-479]|5[0235-9])|[2-5]|6(?:1[1358]|2[2457-9]|3[2-5]|4[235-7]|5[2-689]|6[24578]|7[235689]|8[1-6])|7(?:1[013-9]|28|3[129]|4[1-35689]|5[29]|6[02-5]|70)|807", "1(?:[2-479]|5[0235-9])|[2-5]|6(?:1[1358]|2(?:[2457]|84|95)|3(?:[2-4]|55)|4[235-7]|5[2-689]|6[24578]|7[235689]|8[1-6])|7(?:1(?:[013-8]|9[6-9])|28[6-8]|3(?:17|2[0-49]|9[2-57])|4(?:1[2-4]|[29][0-7]|3[0-8]|[56]|8[0-24-7])|5(?:2[1-3]|9[0-6])|6(?:0[5689]|2[5-9]|3[02-8]|4|5[0-367])|70[13-7])|807[19]", "1(?:[2-479]|5(?:[0236-9]|5[013-9]))|[2-5]|6(?:2(?:84|95)|355|83)|73179|807(?:1|9[1-3])|(?:1552|6(?:1[1358]|2[2457]|3[2-4]|4[235-7]|5[2-689]|6[24578]|7[235689]|8[124-6])\\d|7(?:1(?:[013-8]\\d|9[6-9])|28[6-8]|3(?:2[0-49]|9[2-57])|4(?:1[2-4]|[29][0-7]|3[0-8]|[56]\\d|8[0-24-7])|5(?:2[1-3]|9[0-6])|6(?:0[5689]|2[5-9]|3[02-8]|4\\d|5[0-367])|70[13-7]))[2-7]"], "0$1", 1], ["(\\d{5})(\\d{5})", "$1 $2", ["[6-9]"], "0$1", 1], ["(\\d{4})(\\d{2,4})(\\d{4})", "$1 $2 $3", ["1(?:6|8[06])", "1(?:6|8[06]0)"], 0, 1], ["(\\d{4})(\\d{3})(\\d{3})(\\d{3})", "$1 $2 $3 $4", ["18"], 0, 1]], "0"], IO: ["246", "00", "3\\d{6}", [7], [["(\\d{3})(\\d{4})", "$1 $2", ["3"]]]], IQ: ["964", "00", "(?:1|7\\d\\d)\\d{7}|[2-6]\\d{7,8}", [8, 9, 10], [["(\\d)(\\d{3})(\\d{4})", "$1 $2 $3", ["1"], "0$1"], ["(\\d{2})(\\d{3})(\\d{3,4})", "$1 $2 $3", ["[2-6]"], "0$1"], ["(\\d{3})(\\d{3})(\\d{4})", "$1 $2 $3", ["7"], "0$1"]], "0"], IR: ["98", "00", "[1-9]\\d{9}|(?:[1-8]\\d\\d|9)\\d{3,4}", [4, 5, 6, 7, 10], [["(\\d{4,5})", "$1", ["96"], "0$1"], ["(\\d{2})(\\d{4,5})", "$1 $2", ["(?:1[137]|2[13-68]|3[1458]|4[145]|5[1468]|6[16]|7[1467]|8[13467])[12689]"], "0$1"], ["(\\d{3})(\\d{3})(\\d{3,4})", "$1 $2 $3", ["9"], "0$1"], ["(\\d{2})(\\d{4})(\\d{4})", "$1 $2 $3", ["[1-8]"], "0$1"]], "0"], IS: ["354", "00|1(?:0(?:01|[12]0)|100)", "(?:38\\d|[4-9])\\d{6}", [7, 9], [["(\\d{3})(\\d{4})", "$1 $2", ["[4-9]"]], ["(\\d{3})(\\d{3})(\\d{3})", "$1 $2 $3", ["3"]]], 0, 0, 0, 0, 0, 0, 0, "00"], IT: ["39", "00", "0\\d{5,10}|1\\d{8,10}|3(?:[0-8]\\d{7,10}|9\\d{7,8})|(?:43|55|70)\\d{8}|8\\d{5}(?:\\d{2,4})?", [6, 7, 8, 9, 10, 11, 12], [["(\\d{2})(\\d{4,6})", "$1 $2", ["0[26]"]], ["(\\d{3})(\\d{3,6})", "$1 $2", ["0[13-57-9][0159]|8(?:03|4[17]|9[2-5])", "0[13-57-9][0159]|8(?:03|4[17]|9(?:2|3[04]|[45][0-4]))"]], ["(\\d{4})(\\d{2,6})", "$1 $2", ["0(?:[13-579][2-46-8]|8[236-8])"]], ["(\\d{4})(\\d{4})", "$1 $2", ["894"]], ["(\\d{2})(\\d{3,4})(\\d{4})", "$1 $2 $3", ["0[26]|5"]], ["(\\d{3})(\\d{3})(\\d{3,4})", "$1 $2 $3", ["1(?:44|[679])|[378]|43"]], ["(\\d{3})(\\d{3,4})(\\d{4})", "$1 $2 $3", ["0[13-57-9][0159]|14"]], ["(\\d{2})(\\d{4})(\\d{5})", "$1 $2 $3", ["0[26]"]], ["(\\d{4})(\\d{3})(\\d{4})", "$1 $2 $3", ["0"]], ["(\\d{3})(\\d{4})(\\d{4,5})", "$1 $2 $3", ["3"]]], 0, 0, 0, 0, 0, 0, [["0669[0-79]\\d{1,6}|0(?:1(?:[0159]\\d|[27][1-5]|31|4[1-4]|6[1356]|8[2-57])|2\\d\\d|3(?:[0159]\\d|2[1-4]|3[12]|[48][1-6]|6[2-59]|7[1-7])|4(?:[0159]\\d|[23][1-9]|4[245]|6[1-5]|7[1-4]|81)|5(?:[0159]\\d|2[1-5]|3[2-6]|4[1-79]|6[4-6]|7[1-578]|8[3-8])|6(?:[0-57-9]\\d|6[0-8])|7(?:[0159]\\d|2[12]|3[1-7]|4[2-46]|6[13569]|7[13-6]|8[1-59])|8(?:[0159]\\d|2[3-578]|3[1-356]|[6-8][1-5])|9(?:[0159]\\d|[238][1-5]|4[12]|6[1-8]|7[1-6]))\\d{2,7}", [6, 7, 8, 9, 10, 11]], ["3[2-9]\\d{7,8}|(?:31|43)\\d{8}", [9, 10]], ["80(?:0\\d{3}|3)\\d{3}", [6, 9]], ["(?:0878\\d{3}|89(?:2\\d|3[04]|4(?:[0-4]|[5-9]\\d\\d)|5[0-4]))\\d\\d|(?:1(?:44|6[346])|89(?:38|5[5-9]|9))\\d{6}", [6, 8, 9, 10]], ["1(?:78\\d|99)\\d{6}", [9, 10]], ["3[2-8]\\d{9,10}", [11, 12]], 0, 0, ["55\\d{8}", [10]], ["84(?:[08]\\d{3}|[17])\\d{3}", [6, 9]]]], JE: ["44", "00", "1534\\d{6}|(?:[3578]\\d|90)\\d{8}", [10], 0, "0", 0, "([0-24-8]\\d{5})$|0", "1534$1", 0, 0, [["1534[0-24-8]\\d{5}"], ["7(?:(?:(?:50|82)9|937)\\d|7(?:00[378]|97\\d))\\d{5}"], ["80(?:07(?:35|81)|8901)\\d{4}"], ["(?:8(?:4(?:4(?:4(?:05|42|69)|703)|5(?:041|800))|7(?:0002|1206))|90(?:066[59]|1810|71(?:07|55)))\\d{4}"], ["701511\\d{4}"], 0, ["(?:3(?:0(?:07(?:35|81)|8901)|3\\d{4}|4(?:4(?:4(?:05|42|69)|703)|5(?:041|800))|7(?:0002|1206))|55\\d{4})\\d{4}"], ["76(?:464|652)\\d{5}|76(?:0[0-28]|2[356]|34|4[01347]|5[49]|6[0-369]|77|8[14]|9[139])\\d{6}"], ["56\\d{8}"]]], JM: ["1", "011", "(?:[58]\\d\\d|658|900)\\d{7}", [10], 0, "1", 0, 0, 0, 0, "658|876"], JO: ["962", "00", "(?:(?:[2689]|7\\d)\\d|32|53)\\d{6}", [8, 9], [["(\\d)(\\d{3})(\\d{4})", "$1 $2 $3", ["[2356]|87"], "(0$1)"], ["(\\d{3})(\\d{5,6})", "$1 $2", ["[89]"], "0$1"], ["(\\d{2})(\\d{7})", "$1 $2", ["70"], "0$1"], ["(\\d)(\\d{4})(\\d{4})", "$1 $2 $3", ["7"], "0$1"]], "0"], JP: ["81", "010", "00[1-9]\\d{6,14}|[25-9]\\d{9}|(?:00|[1-9]\\d\\d)\\d{6}", [8, 9, 10, 11, 12, 13, 14, 15, 16, 17], [["(\\d{3})(\\d{3})(\\d{3})", "$1-$2-$3", ["(?:12|57|99)0"], "0$1"], ["(\\d{4})(\\d)(\\d{4})", "$1-$2-$3", ["1(?:26|3[79]|4[56]|5[4-68]|6[3-5])|499|5(?:76|97)|746|8(?:3[89]|47|51)|9(?:80|9[16])", "1(?:267|3(?:7[247]|9[278])|466|5(?:47|58|64)|6(?:3[245]|48|5[4-68]))|499[2468]|5(?:76|97)9|7468|8(?:3(?:8[7-9]|96)|477|51[2-9])|9(?:802|9(?:1[23]|69))|1(?:45|58)[67]", "1(?:267|3(?:7[247]|9[278])|466|5(?:47|58|64)|6(?:3[245]|48|5[4-68]))|499[2468]|5(?:769|979[2-69])|7468|8(?:3(?:8[7-9]|96[2457-9])|477|51[2-9])|9(?:802|9(?:1[23]|69))|1(?:45|58)[67]"], "0$1"], ["(\\d{2})(\\d{3})(\\d{4})", "$1-$2-$3", ["60"], "0$1"], ["(\\d)(\\d{4})(\\d{4})", "$1-$2-$3", ["3|4(?:2[09]|7[01])|6[1-9]", "3|4(?:2(?:0|9[02-69])|7(?:0[019]|1))|6[1-9]"], "0$1"], ["(\\d{2})(\\d{3})(\\d{4})", "$1-$2-$3", ["1(?:1|5[45]|77|88|9[69])|2(?:2[1-37]|3[0-269]|4[59]|5|6[24]|7[1-358]|8[1369]|9[0-38])|4(?:[28][1-9]|3[0-57]|[45]|6[248]|7[2-579]|9[29])|5(?:2|3[0459]|4[0-369]|5[29]|8[02389]|9[0-389])|7(?:2[02-46-9]|34|[58]|6[0249]|7[57]|9[2-6])|8(?:2[124589]|3[26-9]|49|51|6|7[0-468]|8[68]|9[019])|9(?:[23][1-9]|4[15]|5[138]|6[1-3]|7[156]|8[189]|9[1-489])", "1(?:1|5(?:4[018]|5[017])|77|88|9[69])|2(?:2(?:[127]|3[014-9])|3[0-269]|4[59]|5(?:[1-3]|5[0-69]|9[19])|62|7(?:[1-35]|8[0189])|8(?:[16]|3[0134]|9[0-5])|9(?:[028]|17))|4(?:2(?:[13-79]|8[014-6])|3[0-57]|[45]|6[248]|7[2-47]|8[1-9]|9[29])|5(?:2|3(?:[045]|9[0-8])|4[0-369]|5[29]|8[02389]|9[0-3])|7(?:2[02-46-9]|34|[58]|6[0249]|7[57]|9(?:[23]|4[0-59]|5[01569]|6[0167]))|8(?:2(?:[1258]|4[0-39]|9[0-2469])|3(?:[29]|60)|49|51|6(?:[0-24]|36|5[0-3589]|7[23]|9[01459])|7[0-468]|8[68])|9(?:[23][1-9]|4[15]|5[138]|6[1-3]|7[156]|8[189]|9(?:[1289]|3[34]|4[0178]))|(?:264|837)[016-9]|2(?:57|93)[015-9]|(?:25[0468]|422|838)[01]|(?:47[59]|59[89]|8(?:6[68]|9))[019]", "1(?:1|5(?:4[018]|5[017])|77|88|9[69])|2(?:2[127]|3[0-269]|4[59]|5(?:[1-3]|5[0-69]|9(?:17|99))|6(?:2|4[016-9])|7(?:[1-35]|8[0189])|8(?:[16]|3[0134]|9[0-5])|9(?:[028]|17))|4(?:2(?:[13-79]|8[014-6])|3[0-57]|[45]|6[248]|7[2-47]|9[29])|5(?:2|3(?:[045]|9(?:[0-58]|6[4-9]|7[0-35689]))|4[0-369]|5[29]|8[02389]|9[0-3])|7(?:2[02-46-9]|34|[58]|6[0249]|7[57]|9(?:[23]|4[0-59]|5[01569]|6[0167]))|8(?:2(?:[1258]|4[0-39]|9[0169])|3(?:[29]|60|7(?:[017-9]|6[6-8]))|49|51|6(?:[0-24]|36[2-57-9]|5(?:[0-389]|5[23])|6(?:[01]|9[178])|7(?:2[2-468]|3[78])|9[0145])|7[0-468]|8[68])|9(?:4[15]|5[138]|7[156]|8[189]|9(?:[1289]|3(?:31|4[357])|4[0178]))|(?:8294|96)[1-3]|2(?:57|93)[015-9]|(?:223|8699)[014-9]|(?:25[0468]|422|838)[01]|(?:48|8292|9[23])[1-9]|(?:47[59]|59[89]|8(?:68|9))[019]"], "0$1"], ["(\\d{3})(\\d{2})(\\d{4})", "$1-$2-$3", ["[14]|[289][2-9]|5[3-9]|7[2-4679]"], "0$1"], ["(\\d{3})(\\d{3})(\\d{4})", "$1-$2-$3", ["800"], "0$1"], ["(\\d{2})(\\d{4})(\\d{4})", "$1-$2-$3", ["[25-9]"], "0$1"]], "0", 0, "(000[259]\\d{6})$|(?:(?:003768)0?)|0", "$1"], KE: ["254", "000", "(?:[17]\\d\\d|900)\\d{6}|(?:2|80)0\\d{6,7}|[4-6]\\d{6,8}", [7, 8, 9, 10], [["(\\d{2})(\\d{5,7})", "$1 $2", ["[24-6]"], "0$1"], ["(\\d{3})(\\d{6})", "$1 $2", ["[17]"], "0$1"], ["(\\d{3})(\\d{3})(\\d{3,4})", "$1 $2 $3", ["[89]"], "0$1"]], "0"], KG: ["996", "00", "8\\d{9}|[235-9]\\d{8}", [9, 10], [["(\\d{4})(\\d{5})", "$1 $2", ["3(?:1[346]|[24-79])"], "0$1"], ["(\\d{3})(\\d{3})(\\d{3})", "$1 $2 $3", ["[235-79]|88"], "0$1"], ["(\\d{3})(\\d{3})(\\d)(\\d{2,3})", "$1 $2 $3 $4", ["8"], "0$1"]], "0"], KH: ["855", "00[14-9]", "1\\d{9}|[1-9]\\d{7,8}", [8, 9, 10], [["(\\d{2})(\\d{3})(\\d{3,4})", "$1 $2 $3", ["[1-9]"], "0$1"], ["(\\d{4})(\\d{3})(\\d{3})", "$1 $2 $3", ["1"]]], "0"], KI: ["686", "00", "(?:[37]\\d|6[0-79])\\d{6}|(?:[2-48]\\d|50)\\d{3}", [5, 8], 0, "0"], KM: ["269", "00", "[3478]\\d{6}", [7], [["(\\d{3})(\\d{2})(\\d{2})", "$1 $2 $3", ["[3478]"]]]], KN: ["1", "011", "(?:[58]\\d\\d|900)\\d{7}", [10], 0, "1", 0, "([2-7]\\d{6})$|1", "869$1", 0, "869"], KP: ["850", "00|99", "85\\d{6}|(?:19\\d|[2-7])\\d{7}", [8, 10], [["(\\d{2})(\\d{3})(\\d{3})", "$1 $2 $3", ["8"], "0$1"], ["(\\d)(\\d{3})(\\d{4})", "$1 $2 $3", ["[2-7]"], "0$1"], ["(\\d{3})(\\d{3})(\\d{4})", "$1 $2 $3", ["1"], "0$1"]], "0"], KR: ["82", "00(?:[125689]|3(?:[46]5|91)|7(?:00|27|3|55|6[126]))", "00[1-9]\\d{8,11}|(?:[12]|5\\d{3})\\d{7}|[13-6]\\d{9}|(?:[1-6]\\d|80)\\d{7}|[3-6]\\d{4,5}|(?:00|7)0\\d{8}", [5, 6, 8, 9, 10, 11, 12, 13, 14], [["(\\d{2})(\\d{3,4})", "$1-$2", ["(?:3[1-3]|[46][1-4]|5[1-5])1"], "0$1"], ["(\\d{4})(\\d{4})", "$1-$2", ["1"]], ["(\\d)(\\d{3,4})(\\d{4})", "$1-$2-$3", ["2"], "0$1"], ["(\\d{2})(\\d{3})(\\d{4})", "$1-$2-$3", ["[36]0|8"], "0$1"], ["(\\d{2})(\\d{3,4})(\\d{4})", "$1-$2-$3", ["[1346]|5[1-5]"], "0$1"], ["(\\d{2})(\\d{4})(\\d{4})", "$1-$2-$3", ["[57]"], "0$1"], ["(\\d{2})(\\d{5})(\\d{4})", "$1-$2-$3", ["5"], "0$1"]], "0", 0, "0(8(?:[1-46-8]|5\\d\\d))?"], KW: ["965", "00", "18\\d{5}|(?:[2569]\\d|41)\\d{6}", [7, 8], [["(\\d{4})(\\d{3,4})", "$1 $2", ["[169]|2(?:[235]|4[1-35-9])|52"]], ["(\\d{3})(\\d{5})", "$1 $2", ["[245]"]]]], KY: ["1", "011", "(?:345|[58]\\d\\d|900)\\d{7}", [10], 0, "1", 0, "([2-9]\\d{6})$|1", "345$1", 0, "345"], KZ: ["7", "810", "(?:33622|8\\d{8})\\d{5}|[78]\\d{9}", [10, 14], 0, "8", 0, 0, 0, 0, "33|7", 0, "8~10"], LA: ["856", "00", "[23]\\d{9}|3\\d{8}|(?:[235-8]\\d|41)\\d{6}", [8, 9, 10], [["(\\d{2})(\\d{3})(\\d{3})", "$1 $2 $3", ["2[13]|3[14]|[4-8]"], "0$1"], ["(\\d{2})(\\d{2})(\\d{2})(\\d{3})", "$1 $2 $3 $4", ["30[0135-9]"], "0$1"], ["(\\d{2})(\\d{2})(\\d{3})(\\d{3})", "$1 $2 $3 $4", ["[23]"], "0$1"]], "0"], LB: ["961", "00", "[27-9]\\d{7}|[13-9]\\d{6}", [7, 8], [["(\\d)(\\d{3})(\\d{3})", "$1 $2 $3", ["[13-69]|7(?:[2-57]|62|8[0-7]|9[04-9])|8[02-9]"], "0$1"], ["(\\d{2})(\\d{3})(\\d{3})", "$1 $2 $3", ["[27-9]"]]], "0"], LC: ["1", "011", "(?:[58]\\d\\d|758|900)\\d{7}", [10], 0, "1", 0, "([2-8]\\d{6})$|1", "758$1", 0, "758"], LI: ["423", "00", "[68]\\d{8}|(?:[2378]\\d|90)\\d{5}", [7, 9], [["(\\d{3})(\\d{2})(\\d{2})", "$1 $2 $3", ["[2379]|8(?:0[09]|7)", "[2379]|8(?:0(?:02|9)|7)"]], ["(\\d{3})(\\d{3})(\\d{3})", "$1 $2 $3", ["8"]], ["(\\d{2})(\\d{3})(\\d{4})", "$1 $2 $3", ["69"]], ["(\\d{3})(\\d{3})(\\d{3})", "$1 $2 $3", ["6"]]], "0", 0, "(1001)|0"], LK: ["94", "00", "[1-9]\\d{8}", [9], [["(\\d{2})(\\d{3})(\\d{4})", "$1 $2 $3", ["7"], "0$1"], ["(\\d{3})(\\d{3})(\\d{3})", "$1 $2 $3", ["[1-689]"], "0$1"]], "0"], LR: ["231", "00", "(?:[245]\\d|33|77|88)\\d{7}|(?:2\\d|[4-6])\\d{6}", [7, 8, 9], [["(\\d)(\\d{3})(\\d{3})", "$1 $2 $3", ["4[67]|[56]"], "0$1"], ["(\\d{2})(\\d{3})(\\d{3})", "$1 $2 $3", ["2"], "0$1"], ["(\\d{2})(\\d{3})(\\d{4})", "$1 $2 $3", ["[2-578]"], "0$1"]], "0"], LS: ["266", "00", "(?:[256]\\d\\d|800)\\d{5}", [8], [["(\\d{4})(\\d{4})", "$1 $2", ["[2568]"]]]], LT: ["370", "00", "(?:[3469]\\d|52|[78]0)\\d{6}", [8], [["(\\d)(\\d{3})(\\d{4})", "$1 $2 $3", ["52[0-7]"], "(0-$1)", 1], ["(\\d{3})(\\d{2})(\\d{3})", "$1 $2 $3", ["[7-9]"], "0 $1", 1], ["(\\d{2})(\\d{6})", "$1 $2", ["37|4(?:[15]|6[1-8])"], "(0-$1)", 1], ["(\\d{3})(\\d{5})", "$1 $2", ["[3-6]"], "(0-$1)", 1]], "0", 0, "[08]"], LU: ["352", "00", "35[013-9]\\d{4,8}|6\\d{8}|35\\d{2,4}|(?:[2457-9]\\d|3[0-46-9])\\d{2,9}", [4, 5, 6, 7, 8, 9, 10, 11], [["(\\d{2})(\\d{3})", "$1 $2", ["2(?:0[2-689]|[2-9])|[3-57]|8(?:0[2-9]|[13-9])|9(?:0[89]|[2-579])"]], ["(\\d{2})(\\d{2})(\\d{2})", "$1 $2 $3", ["2(?:0[2-689]|[2-9])|[3-57]|8(?:0[2-9]|[13-9])|9(?:0[89]|[2-579])"]], ["(\\d{2})(\\d{2})(\\d{3})", "$1 $2 $3", ["20[2-689]"]], ["(\\d{2})(\\d{2})(\\d{2})(\\d{1,2})", "$1 $2 $3 $4", ["2(?:[0367]|4[3-8])"]], ["(\\d{3})(\\d{2})(\\d{3})", "$1 $2 $3", ["80[01]|90[015]"]], ["(\\d{2})(\\d{2})(\\d{2})(\\d{3})", "$1 $2 $3 $4", ["20"]], ["(\\d{3})(\\d{3})(\\d{3})", "$1 $2 $3", ["6"]], ["(\\d{2})(\\d{2})(\\d{2})(\\d{2})(\\d{1,2})", "$1 $2 $3 $4 $5", ["2(?:[0367]|4[3-8])"]], ["(\\d{2})(\\d{2})(\\d{2})(\\d{1,5})", "$1 $2 $3 $4", ["[3-57]|8[13-9]|9(?:0[89]|[2-579])|(?:2|80)[2-9]"]]], 0, 0, "(15(?:0[06]|1[12]|[35]5|4[04]|6[26]|77|88|99)\\d)"], LV: ["371", "00", "(?:[268]\\d|90)\\d{6}", [8], [["(\\d{2})(\\d{3})(\\d{3})", "$1 $2 $3", ["[269]|8[01]"]]]], LY: ["218", "00", "[2-9]\\d{8}", [9], [["(\\d{2})(\\d{7})", "$1-$2", ["[2-9]"], "0$1"]], "0"], MA: ["212", "00", "[5-8]\\d{8}", [9], [["(\\d{3})(\\d{2})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["5[45]"], "0$1"], ["(\\d{4})(\\d{5})", "$1-$2", ["5(?:2[2-46-9]|3[3-9]|9)|8(?:0[89]|92)"], "0$1"], ["(\\d{2})(\\d{7})", "$1-$2", ["8"], "0$1"], ["(\\d{3})(\\d{6})", "$1-$2", ["[5-7]"], "0$1"]], "0", 0, 0, 0, 0, 0, [["5(?:2(?:[0-25-79]\\d|3[1-578]|4[02-46-8]|8[0235-7])|3(?:[0-47]\\d|5[02-9]|6[02-8]|8[014-9]|9[3-9])|(?:4[067]|5[03])\\d)\\d{5}"], ["(?:6(?:[0-79]\\d|8[0-247-9])|7(?:[0167]\\d|2[0-467]|5[0-3]|8[0-5]))\\d{6}"], ["80[0-7]\\d{6}"], ["89\\d{7}"], 0, 0, 0, 0, ["(?:592(?:4[0-2]|93)|80[89]\\d\\d)\\d{4}"]]], MC: ["377", "00", "(?:[3489]|6\\d)\\d{7}", [8, 9], [["(\\d{2})(\\d{3})(\\d{3})", "$1 $2 $3", ["4"], "0$1"], ["(\\d{2})(\\d{2})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["[389]"]], ["(\\d)(\\d{2})(\\d{2})(\\d{2})(\\d{2})", "$1 $2 $3 $4 $5", ["6"], "0$1"]], "0"], MD: ["373", "00", "(?:[235-7]\\d|[89]0)\\d{6}", [8], [["(\\d{3})(\\d{5})", "$1 $2", ["[89]"], "0$1"], ["(\\d{2})(\\d{3})(\\d{3})", "$1 $2 $3", ["22|3"], "0$1"], ["(\\d{3})(\\d{2})(\\d{3})", "$1 $2 $3", ["[25-7]"], "0$1"]], "0"], ME: ["382", "00", "(?:20|[3-79]\\d)\\d{6}|80\\d{6,7}", [8, 9], [["(\\d{2})(\\d{3})(\\d{3,4})", "$1 $2 $3", ["[2-9]"], "0$1"]], "0"], MF: ["590", "00", "(?:590\\d|7090)\\d{5}|(?:69|80|9\\d)\\d{7}", [9], 0, "0", 0, 0, 0, 0, 0, [["590(?:0[079]|[14]3|[27][79]|3[03-7]|5[0-268]|87)\\d{4}"], ["(?:69(?:0\\d\\d|1(?:2[2-9]|3[0-5])|4(?:0[89]|1[2-6]|9\\d)|6(?:1[016-9]|5[0-4]|[67]\\d))|7090[0-4])\\d{4}"], ["80[0-5]\\d{6}"], 0, 0, 0, 0, 0, ["9(?:(?:39[5-7]|76[018])\\d|475[0-5])\\d{4}"]]], MG: ["261", "00", "[23]\\d{8}", [9], [["(\\d{2})(\\d{2})(\\d{3})(\\d{2})", "$1 $2 $3 $4", ["[23]"], "0$1"]], "0", 0, "([24-9]\\d{6})$|0", "20$1"], MH: ["692", "011", "329\\d{4}|(?:[256]\\d|45)\\d{5}", [7], [["(\\d{3})(\\d{4})", "$1-$2", ["[2-6]"]]], "1"], MK: ["389", "00", "[2-578]\\d{7}", [8], [["(\\d)(\\d{3})(\\d{4})", "$1 $2 $3", ["2|34[47]|4(?:[37]7|5[47]|64)"], "0$1"], ["(\\d{2})(\\d{3})(\\d{3})", "$1 $2 $3", ["[347]"], "0$1"], ["(\\d{3})(\\d)(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["[58]"], "0$1"]], "0"], ML: ["223", "00", "[24-9]\\d{7}", [8], [["(\\d{2})(\\d{2})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["[24-9]"]]]], MM: ["95", "00", "1\\d{5,7}|95\\d{6}|(?:[4-7]|9[0-46-9])\\d{6,8}|(?:2|8\\d)\\d{5,8}", [6, 7, 8, 9, 10], [["(\\d)(\\d{2})(\\d{3})", "$1 $2 $3", ["16|2"], "0$1"], ["(\\d{2})(\\d{2})(\\d{3})", "$1 $2 $3", ["4(?:[2-46]|5[3-5])|5|6(?:[1-689]|7[235-7])|7(?:[0-4]|5[2-7])|8[1-5]|(?:60|86)[23]"], "0$1"], ["(\\d)(\\d{3})(\\d{3,4})", "$1 $2 $3", ["[12]|452|678|86", "[12]|452|6788|86"], "0$1"], ["(\\d{2})(\\d{3})(\\d{3,4})", "$1 $2 $3", ["[4-7]|8[1-35]"], "0$1"], ["(\\d)(\\d{3})(\\d{4,6})", "$1 $2 $3", ["9(?:2[0-4]|[35-9]|4[137-9])"], "0$1"], ["(\\d)(\\d{4})(\\d{4})", "$1 $2 $3", ["2"], "0$1"], ["(\\d{3})(\\d{3})(\\d{4})", "$1 $2 $3", ["8"], "0$1"], ["(\\d)(\\d{3})(\\d{3})(\\d{3})", "$1 $2 $3 $4", ["92"], "0$1"], ["(\\d)(\\d{5})(\\d{4})", "$1 $2 $3", ["9"], "0$1"]], "0"], MN: ["976", "001", "[12]\\d{7,9}|[5-9]\\d{7}", [8, 9, 10], [["(\\d{2})(\\d{2})(\\d{4})", "$1 $2 $3", ["[12]1"], "0$1"], ["(\\d{4})(\\d{4})", "$1 $2", ["[5-9]"]], ["(\\d{3})(\\d{5,6})", "$1 $2", ["[12]2[1-3]"], "0$1"], ["(\\d{4})(\\d{5,6})", "$1 $2", ["[12](?:27|3[2-8]|4[2-68]|5[1-4689])", "[12](?:27|3[2-8]|4[2-68]|5[1-4689])[0-3]"], "0$1"], ["(\\d{5})(\\d{4,5})", "$1 $2", ["[12]"], "0$1"]], "0"], MO: ["853", "00", "0800\\d{3}|(?:28|[68]\\d)\\d{6}", [7, 8], [["(\\d{4})(\\d{3})", "$1 $2", ["0"]], ["(\\d{4})(\\d{4})", "$1 $2", ["[268]"]]]], MP: ["1", "011", "[58]\\d{9}|(?:67|90)0\\d{7}", [10], 0, "1", 0, "([2-9]\\d{6})$|1", "670$1", 0, "670"], MQ: ["596", "00", "(?:596\\d|7091)\\d{5}|(?:69|[89]\\d)\\d{7}", [9], [["(\\d{3})(\\d{2})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["[5-79]|8(?:0[6-9]|[36])"], "0$1"], ["(\\d{3})(\\d{2})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["8"], "0$1"]], "0"], MR: ["222", "00", "(?:[2-4]\\d\\d|800)\\d{5}", [8], [["(\\d{2})(\\d{2})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["[2-48]"]]]], MS: ["1", "011", "(?:[58]\\d\\d|664|900)\\d{7}", [10], 0, "1", 0, "([34]\\d{6})$|1", "664$1", 0, "664"], MT: ["356", "00", "3550\\d{4}|(?:[2579]\\d\\d|800)\\d{5}", [8], [["(\\d{4})(\\d{4})", "$1 $2", ["[2357-9]"]]]], MU: ["230", "0(?:0|[24-7]0|3[03])", "(?:[57]|8\\d\\d)\\d{7}|[2-468]\\d{6}", [7, 8, 10], [["(\\d{3})(\\d{4})", "$1 $2", ["[2-46]|8[013]"]], ["(\\d{4})(\\d{4})", "$1 $2", ["[57]"]], ["(\\d{5})(\\d{5})", "$1 $2", ["8"]]], 0, 0, 0, 0, 0, 0, 0, "020"], MV: ["960", "0(?:0|19)", "(?:800|9[0-57-9]\\d)\\d{7}|[34679]\\d{6}", [7, 10], [["(\\d{3})(\\d{4})", "$1-$2", ["[34679]"]], ["(\\d{3})(\\d{3})(\\d{4})", "$1 $2 $3", ["[89]"]]], 0, 0, 0, 0, 0, 0, 0, "00"], MW: ["265", "00", "(?:[1289]\\d|31|77)\\d{7}|1\\d{6}", [7, 9], [["(\\d)(\\d{3})(\\d{3})", "$1 $2 $3", ["1[2-9]"], "0$1"], ["(\\d{3})(\\d{3})(\\d{3})", "$1 $2 $3", ["2"], "0$1"], ["(\\d{3})(\\d{2})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["[137-9]"], "0$1"]], "0"], MX: ["52", "0[09]", "[2-9]\\d{9}", [10], [["(\\d{2})(\\d{4})(\\d{4})", "$1 $2 $3", ["33|5[56]|81"]], ["(\\d{3})(\\d{3})(\\d{4})", "$1 $2 $3", ["[2-9]"]]], 0, 0, 0, 0, 0, 0, 0, "00"], MY: ["60", "00", "1\\d{8,9}|(?:3\\d|[4-9])\\d{7}", [8, 9, 10], [["(\\d)(\\d{3})(\\d{4})", "$1-$2 $3", ["[4-79]"], "0$1"], ["(\\d{2})(\\d{3})(\\d{3,4})", "$1-$2 $3", ["1(?:[02469]|[378][1-9]|53)|8", "1(?:[02469]|[37][1-9]|53|8(?:[1-46-9]|5[7-9]))|8"], "0$1"], ["(\\d)(\\d{4})(\\d{4})", "$1-$2 $3", ["3"], "0$1"], ["(\\d)(\\d{3})(\\d{2})(\\d{4})", "$1-$2-$3-$4", ["1(?:[367]|80)"]], ["(\\d{3})(\\d{3})(\\d{4})", "$1-$2 $3", ["15"], "0$1"], ["(\\d{2})(\\d{4})(\\d{4})", "$1-$2 $3", ["1"], "0$1"]], "0"], MZ: ["258", "00", "(?:2|8\\d)\\d{7}", [8, 9], [["(\\d{2})(\\d{3})(\\d{3,4})", "$1 $2 $3", ["2|8[2-79]"]], ["(\\d{3})(\\d{3})(\\d{3})", "$1 $2 $3", ["8"]]]], NA: ["264", "00", "[68]\\d{7,8}", [8, 9], [["(\\d{2})(\\d{3})(\\d{3})", "$1 $2 $3", ["88"], "0$1"], ["(\\d{2})(\\d{3})(\\d{3,4})", "$1 $2 $3", ["6"], "0$1"], ["(\\d{3})(\\d{3})(\\d{3})", "$1 $2 $3", ["87"], "0$1"], ["(\\d{2})(\\d{3})(\\d{4})", "$1 $2 $3", ["8"], "0$1"]], "0"], NC: ["687", "00", "(?:050|[2-57-9]\\d\\d)\\d{3}", [6], [["(\\d{2})(\\d{2})(\\d{2})", "$1.$2.$3", ["[02-57-9]"]]]], NE: ["227", "00", "[027-9]\\d{7}", [8], [["(\\d{2})(\\d{3})(\\d{3})", "$1 $2 $3", ["08"]], ["(\\d{2})(\\d{2})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["[089]|2[013]|7[0467]"]]]], NF: ["672", "00", "[13]\\d{5}", [6], [["(\\d{2})(\\d{4})", "$1 $2", ["1[0-3]"]], ["(\\d)(\\d{5})", "$1 $2", ["[13]"]]], 0, 0, "([0-258]\\d{4})$", "3$1"], NG: ["234", "009", "38\\d{6}|[78]\\d{9,13}|(?:20|9\\d)\\d{8}", [8, 10, 11, 12, 13, 14], [["(\\d{2})(\\d{3})(\\d{2,3})", "$1 $2 $3", ["3"], "0$1"], ["(\\d{3})(\\d{3})(\\d{3,4})", "$1 $2 $3", ["[7-9]"], "0$1"], ["(\\d{3})(\\d{3})(\\d{4})", "$1 $2 $3", ["20[129]"], "0$1"], ["(\\d{4})(\\d{2})(\\d{4})", "$1 $2 $3", ["2"], "0$1"], ["(\\d{3})(\\d{4})(\\d{4,5})", "$1 $2 $3", ["[78]"], "0$1"], ["(\\d{3})(\\d{5})(\\d{5,6})", "$1 $2 $3", ["[78]"], "0$1"]], "0"], NI: ["505", "00", "(?:1800|[25-8]\\d{3})\\d{4}", [8], [["(\\d{4})(\\d{4})", "$1 $2", ["[125-8]"]]]], NL: ["31", "00", "(?:[124-7]\\d\\d|3(?:[02-9]\\d|1[0-8]))\\d{6}|8\\d{6,9}|9\\d{6,10}|1\\d{4,5}", [5, 6, 7, 8, 9, 10, 11], [["(\\d{3})(\\d{4,7})", "$1 $2", ["[89]0"], "0$1"], ["(\\d{2})(\\d{7})", "$1 $2", ["66"], "0$1"], ["(\\d)(\\d{8})", "$1 $2", ["6"], "0$1"], ["(\\d{3})(\\d{3})(\\d{3})", "$1 $2 $3", ["1[16-8]|2[259]|3[124]|4[17-9]|5[124679]"], "0$1"], ["(\\d{2})(\\d{3})(\\d{4})", "$1 $2 $3", ["[1-578]|91"], "0$1"], ["(\\d{3})(\\d{3})(\\d{5})", "$1 $2 $3", ["9"], "0$1"]], "0"], NO: ["47", "00", "(?:0|[2-9]\\d{3})\\d{4}", [5, 8], [["(\\d{3})(\\d{2})(\\d{3})", "$1 $2 $3", ["8"]], ["(\\d{2})(\\d{2})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["[2-79]"]]], 0, 0, 0, 0, 0, "[02-689]|7[0-8]"], NP: ["977", "00", "(?:1\\d|9)\\d{9}|[1-9]\\d{7}", [8, 10, 11], [["(\\d)(\\d{7})", "$1-$2", ["1[2-6]"], "0$1"], ["(\\d{2})(\\d{6})", "$1-$2", ["1[01]|[2-8]|9(?:[1-59]|[67][2-6])"], "0$1"], ["(\\d{3})(\\d{7})", "$1-$2", ["9"]]], "0"], NR: ["674", "00", "(?:444|(?:55|8\\d)\\d|666)\\d{4}", [7], [["(\\d{3})(\\d{4})", "$1 $2", ["[4-68]"]]]], NU: ["683", "00", "(?:[4-7]|888\\d)\\d{3}", [4, 7], [["(\\d{3})(\\d{4})", "$1 $2", ["8"]]]], NZ: ["64", "0(?:0|161)", "[1289]\\d{9}|50\\d{5}(?:\\d{2,3})?|[27-9]\\d{7,8}|(?:[34]\\d|6[0-35-9])\\d{6}|8\\d{4,6}", [5, 6, 7, 8, 9, 10], [["(\\d{2})(\\d{3,8})", "$1 $2", ["8[1-79]"], "0$1"], ["(\\d{3})(\\d{2})(\\d{2,3})", "$1 $2 $3", ["50[036-8]|8|90", "50(?:[0367]|88)|8|90"], "0$1"], ["(\\d)(\\d{3})(\\d{4})", "$1 $2 $3", ["24|[346]|7[2-57-9]|9[2-9]"], "0$1"], ["(\\d{3})(\\d{3})(\\d{3,4})", "$1 $2 $3", ["2(?:10|74)|[589]"], "0$1"], ["(\\d{2})(\\d{3,4})(\\d{4})", "$1 $2 $3", ["1|2[028]"], "0$1"], ["(\\d{2})(\\d{3})(\\d{3,5})", "$1 $2 $3", ["2(?:[169]|7[0-35-9])|7"], "0$1"]], "0", 0, 0, 0, 0, 0, 0, "00"], OM: ["968", "00", "(?:1505|[279]\\d{3}|500)\\d{4}|800\\d{5,6}", [7, 8, 9], [["(\\d{3})(\\d{4,6})", "$1 $2", ["[58]"]], ["(\\d{2})(\\d{6})", "$1 $2", ["2"]], ["(\\d{4})(\\d{4})", "$1 $2", ["[179]"]]]], PA: ["507", "00", "(?:00800|8\\d{3})\\d{6}|[68]\\d{7}|[1-57-9]\\d{6}", [7, 8, 10, 11], [["(\\d{3})(\\d{4})", "$1-$2", ["[1-57-9]"]], ["(\\d{4})(\\d{4})", "$1-$2", ["[68]"]], ["(\\d{3})(\\d{3})(\\d{4})", "$1 $2 $3", ["8"]]]], PE: ["51", "00|19(?:1[124]|77|90)00", "(?:[14-8]|9\\d)\\d{7}", [8, 9], [["(\\d{3})(\\d{5})", "$1 $2", ["80"], "(0$1)"], ["(\\d)(\\d{7})", "$1 $2", ["1"], "(0$1)"], ["(\\d{2})(\\d{6})", "$1 $2", ["[4-8]"], "(0$1)"], ["(\\d{3})(\\d{3})(\\d{3})", "$1 $2 $3", ["9"]]], "0", 0, 0, 0, 0, 0, 0, "00", " Anexo "], PF: ["689", "00", "4\\d{5}(?:\\d{2})?|8\\d{7,8}", [6, 8, 9], [["(\\d{2})(\\d{2})(\\d{2})", "$1 $2 $3", ["44"]], ["(\\d{2})(\\d{2})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["4|8[7-9]"]], ["(\\d{3})(\\d{2})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["8"]]]], PG: ["675", "00|140[1-3]", "(?:180|[78]\\d{3})\\d{4}|(?:[2-589]\\d|64)\\d{5}", [7, 8], [["(\\d{3})(\\d{4})", "$1 $2", ["18|[2-69]|85"]], ["(\\d{4})(\\d{4})", "$1 $2", ["[78]"]]], 0, 0, 0, 0, 0, 0, 0, "00"], PH: ["63", "00", "(?:[2-7]|9\\d)\\d{8}|2\\d{5}|(?:1800|8)\\d{7,9}", [6, 8, 9, 10, 11, 12, 13], [["(\\d)(\\d{5})", "$1 $2", ["2"], "(0$1)"], ["(\\d{4})(\\d{4,6})", "$1 $2", ["3(?:23|39|46)|4(?:2[3-6]|[35]9|4[26]|76)|544|88[245]|(?:52|64|86)2", "3(?:230|397|461)|4(?:2(?:35|[46]4|51)|396|4(?:22|63)|59[347]|76[15])|5(?:221|446)|642[23]|8(?:622|8(?:[24]2|5[13]))"], "(0$1)"], ["(\\d{5})(\\d{4})", "$1 $2", ["346|4(?:27|9[35])|883", "3469|4(?:279|9(?:30|56))|8834"], "(0$1)"], ["(\\d)(\\d{4})(\\d{4})", "$1 $2 $3", ["2"], "(0$1)"], ["(\\d{2})(\\d{3})(\\d{4})", "$1 $2 $3", ["[3-7]|8[2-8]"], "(0$1)"], ["(\\d{3})(\\d{3})(\\d{4})", "$1 $2 $3", ["[89]"], "0$1"], ["(\\d{4})(\\d{3})(\\d{4})", "$1 $2 $3", ["1"]], ["(\\d{4})(\\d{1,2})(\\d{3})(\\d{4})", "$1 $2 $3 $4", ["1"]]], "0"], PK: ["92", "00", "122\\d{6}|[24-8]\\d{10,11}|9(?:[013-9]\\d{8,10}|2(?:[01]\\d\\d|2(?:[06-8]\\d|1[01]))\\d{7})|(?:[2-8]\\d{3}|92(?:[0-7]\\d|8[1-9]))\\d{6}|[24-9]\\d{8}|[89]\\d{7}", [8, 9, 10, 11, 12], [["(\\d{3})(\\d{3})(\\d{2,7})", "$1 $2 $3", ["[89]0"], "0$1"], ["(\\d{4})(\\d{5})", "$1 $2", ["1"]], ["(\\d{3})(\\d{6,7})", "$1 $2", ["2(?:3[2358]|4[2-4]|9[2-8])|45[3479]|54[2-467]|60[468]|72[236]|8(?:2[2-689]|3[23578]|4[3478]|5[2356])|9(?:2[2-8]|3[27-9]|4[2-6]|6[3569]|9[25-8])", "9(?:2[3-8]|98)|(?:2(?:3[2358]|4[2-4]|9[2-8])|45[3479]|54[2-467]|60[468]|72[236]|8(?:2[2-689]|3[23578]|4[3478]|5[2356])|9(?:22|3[27-9]|4[2-6]|6[3569]|9[25-7]))[2-9]"], "(0$1)"], ["(\\d{2})(\\d{7,8})", "$1 $2", ["(?:2[125]|4[0-246-9]|5[1-35-7]|6[1-8]|7[14]|8[16]|91)[2-9]"], "(0$1)"], ["(\\d{5})(\\d{5})", "$1 $2", ["58"], "(0$1)"], ["(\\d{3})(\\d{7})", "$1 $2", ["3"], "0$1"], ["(\\d{2})(\\d{3})(\\d{3})(\\d{3})", "$1 $2 $3 $4", ["2[125]|4[0-246-9]|5[1-35-7]|6[1-8]|7[14]|8[16]|91"], "(0$1)"], ["(\\d{3})(\\d{3})(\\d{3})(\\d{3})", "$1 $2 $3 $4", ["[24-9]"], "(0$1)"]], "0"], PL: ["48", "00", "(?:6|8\\d\\d)\\d{7}|[1-9]\\d{6}(?:\\d{2})?|[26]\\d{5}", [6, 7, 8, 9, 10], [["(\\d{5})", "$1", ["19"]], ["(\\d{3})(\\d{3})", "$1 $2", ["11|20|64"]], ["(\\d{2})(\\d{2})(\\d{3})", "$1 $2 $3", ["(?:1[2-8]|2[2-69]|3[2-4]|4[1-468]|5[24-689]|6[1-3578]|7[14-7]|8[1-79]|9[145])1", "(?:1[2-8]|2[2-69]|3[2-4]|4[1-468]|5[24-689]|6[1-3578]|7[14-7]|8[1-79]|9[145])19"]], ["(\\d{3})(\\d{2})(\\d{2,3})", "$1 $2 $3", ["64"]], ["(\\d{3})(\\d{3})(\\d{3})", "$1 $2 $3", ["21|39|45|5[0137]|6[0469]|7[02389]|8(?:0[14]|8)"]], ["(\\d{2})(\\d{3})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["1[2-8]|[2-7]|8[1-79]|9[145]"]], ["(\\d{3})(\\d{3})(\\d{3,4})", "$1 $2 $3", ["8"]]]], PM: ["508", "00", "[45]\\d{5}|(?:708|8\\d\\d)\\d{6}", [6, 9], [["(\\d{2})(\\d{2})(\\d{2})", "$1 $2 $3", ["[45]"], "0$1"], ["(\\d{3})(\\d{3})(\\d{3})", "$1 $2 $3", ["7"]], ["(\\d{3})(\\d{2})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["8"], "0$1"]], "0"], PR: ["1", "011", "(?:[589]\\d\\d|787)\\d{7}", [10], 0, "1", 0, 0, 0, 0, "787|939"], PS: ["970", "00", "[2489]2\\d{6}|(?:1\\d|5)\\d{8}", [8, 9, 10], [["(\\d)(\\d{3})(\\d{4})", "$1 $2 $3", ["[2489]"], "0$1"], ["(\\d{3})(\\d{3})(\\d{3})", "$1 $2 $3", ["5"], "0$1"], ["(\\d{4})(\\d{3})(\\d{3})", "$1 $2 $3", ["1"]]], "0"], PT: ["351", "00", "1693\\d{5}|(?:[26-9]\\d|30)\\d{7}", [9], [["(\\d{2})(\\d{3})(\\d{4})", "$1 $2 $3", ["2[12]"]], ["(\\d{3})(\\d{3})(\\d{3})", "$1 $2 $3", ["16|[236-9]"]]]], PW: ["680", "01[12]", "(?:[24-8]\\d\\d|345|900)\\d{4}", [7], [["(\\d{3})(\\d{4})", "$1 $2", ["[2-9]"]]]], PY: ["595", "00", "59\\d{4,6}|9\\d{5,10}|(?:[2-46-8]\\d|5[0-8])\\d{4,7}", [6, 7, 8, 9, 10, 11], [["(\\d{3})(\\d{3,6})", "$1 $2", ["[2-9]0"], "0$1"], ["(\\d{2})(\\d{5})", "$1 $2", ["[26]1|3[289]|4[1246-8]|7[1-3]|8[1-36]"], "(0$1)"], ["(\\d{3})(\\d{4,5})", "$1 $2", ["2[279]|3[13-5]|4[359]|5|6(?:[34]|7[1-46-8])|7[46-8]|85"], "(0$1)"], ["(\\d{2})(\\d{3})(\\d{3,4})", "$1 $2 $3", ["2[14-68]|3[26-9]|4[1246-8]|6(?:1|75)|7[1-35]|8[1-36]"], "(0$1)"], ["(\\d{2})(\\d{3})(\\d{4})", "$1 $2 $3", ["87"]], ["(\\d{3})(\\d{6})", "$1 $2", ["9(?:[5-79]|8[1-7])"], "0$1"], ["(\\d{3})(\\d{3})(\\d{3})", "$1 $2 $3", ["[2-8]"], "0$1"], ["(\\d{4})(\\d{3})(\\d{4})", "$1 $2 $3", ["9"]]], "0"], QA: ["974", "00", "800\\d{4}|(?:2|800)\\d{6}|(?:0080|[3-7])\\d{7}", [7, 8, 9, 11], [["(\\d{3})(\\d{4})", "$1 $2", ["2[16]|8"]], ["(\\d{4})(\\d{4})", "$1 $2", ["[3-7]"]]]], RE: ["262", "00", "709\\d{6}|(?:26|[689]\\d)\\d{7}", [9], [["(\\d{3})(\\d{2})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["[26-9]"], "0$1"]], "0", 0, 0, 0, 0, 0, [["26(?:2\\d\\d|3(?:0\\d|1[0-6]))\\d{4}"], ["(?:69(?:2\\d\\d|3(?:[06][0-6]|1[013]|2[0-2]|3[0-39]|4\\d|5[0-5]|7[0-37]|8[0-8]|9[0-479]))|7092[0-3])\\d{4}"], ["80\\d{7}"], ["89[1-37-9]\\d{6}"], 0, 0, 0, 0, ["9(?:399[0-3]|479[0-5]|76(?:2[278]|3[0-37]))\\d{4}"], ["8(?:1[019]|2[0156]|84|90)\\d{6}"]]], RO: ["40", "00", "(?:[236-8]\\d|90)\\d{7}|[23]\\d{5}", [6, 9], [["(\\d{3})(\\d{3})", "$1 $2", ["2[3-6]", "2[3-6]\\d9"], "0$1"], ["(\\d{2})(\\d{4})", "$1 $2", ["219|31"], "0$1"], ["(\\d{2})(\\d{3})(\\d{4})", "$1 $2 $3", ["[23]1"], "0$1"], ["(\\d{3})(\\d{3})(\\d{3})", "$1 $2 $3", ["[236-9]"], "0$1"]], "0", 0, 0, 0, 0, 0, 0, 0, " int "], RS: ["381", "00", "38[02-9]\\d{6,9}|6\\d{7,9}|90\\d{4,8}|38\\d{5,6}|(?:7\\d\\d|800)\\d{3,9}|(?:[12]\\d|3[0-79])\\d{5,10}", [6, 7, 8, 9, 10, 11, 12], [["(\\d{3})(\\d{3,9})", "$1 $2", ["(?:2[389]|39)0|[7-9]"], "0$1"], ["(\\d{2})(\\d{5,10})", "$1 $2", ["[1-36]"], "0$1"]], "0"], RU: ["7", "810", "8\\d{13}|[347-9]\\d{9}", [10, 14], [["(\\d{4})(\\d{2})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["7(?:1[0-8]|2[1-9])", "7(?:1(?:[0-356]2|4[29]|7|8[27])|2(?:1[23]|[2-9]2))", "7(?:1(?:[0-356]2|4[29]|7|8[27])|2(?:13[03-69]|62[013-9]))|72[1-57-9]2"], "8 ($1)", 1], ["(\\d{5})(\\d)(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["7(?:1[0-68]|2[1-9])", "7(?:1(?:[06][3-6]|[18]|2[35]|[3-5][3-5])|2(?:[13][3-5]|[24-689]|7[457]))", "7(?:1(?:0(?:[356]|4[023])|[18]|2(?:3[013-9]|5)|3[45]|43[013-79]|5(?:3[1-8]|4[1-7]|5)|6(?:3[0-35-9]|[4-6]))|2(?:1(?:3[178]|[45])|[24-689]|3[35]|7[457]))|7(?:14|23)4[0-8]|71(?:33|45)[1-79]"], "8 ($1)", 1], ["(\\d{3})(\\d{3})(\\d{4})", "$1 $2 $3", ["7"], "8 ($1)", 1], ["(\\d{3})(\\d{3})(\\d{2})(\\d{2})", "$1 $2-$3-$4", ["[349]|8(?:[02-7]|1[1-8])"], "8 ($1)", 1], ["(\\d{4})(\\d{4})(\\d{3})(\\d{3})", "$1 $2 $3 $4", ["8"], "8 ($1)"]], "8", 0, 0, 0, 0, "3[04-689]|[489]", 0, "8~10"], RW: ["250", "00", "(?:06|[27]\\d\\d|[89]00)\\d{6}", [8, 9], [["(\\d{2})(\\d{2})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["0"]], ["(\\d{3})(\\d{3})(\\d{3})", "$1 $2 $3", ["2"]], ["(\\d{3})(\\d{3})(\\d{3})", "$1 $2 $3", ["[7-9]"], "0$1"]], "0"], SA: ["966", "00", "92\\d{7}|(?:[15]|8\\d)\\d{8}", [9, 10], [["(\\d{4})(\\d{5})", "$1 $2", ["9"]], ["(\\d{2})(\\d{3})(\\d{4})", "$1 $2 $3", ["1"], "0$1"], ["(\\d{2})(\\d{3})(\\d{4})", "$1 $2 $3", ["5"], "0$1"], ["(\\d{3})(\\d{3})(\\d{3,4})", "$1 $2 $3", ["81"], "0$1"], ["(\\d{3})(\\d{3})(\\d{4})", "$1 $2 $3", ["8"]]], "0"], SB: ["677", "0[01]", "[6-9]\\d{6}|[1-6]\\d{4}", [5, 7], [["(\\d{2})(\\d{5})", "$1 $2", ["6[89]|7|8[4-9]|9(?:[1-8]|9[0-8])"]]]], SC: ["248", "010|0[0-2]", "(?:[2489]\\d|64)\\d{5}", [7], [["(\\d)(\\d{3})(\\d{3})", "$1 $2 $3", ["[246]|9[57]"]]], 0, 0, 0, 0, 0, 0, 0, "00"], SD: ["249", "00", "[19]\\d{8}", [9], [["(\\d{2})(\\d{3})(\\d{4})", "$1 $2 $3", ["[19]"], "0$1"]], "0"], SE: ["46", "00", "(?:[26]\\d\\d|9)\\d{9}|[1-9]\\d{8}|[1-689]\\d{7}|[1-4689]\\d{6}|2\\d{5}", [6, 7, 8, 9, 10, 12], [["(\\d{2})(\\d{2,3})(\\d{2})", "$1-$2 $3", ["20"], "0$1", 0, "$1 $2 $3"], ["(\\d{3})(\\d{4})", "$1-$2", ["9(?:00|39|44|9)"], "0$1", 0, "$1 $2"], ["(\\d{2})(\\d{3})(\\d{2})", "$1-$2 $3", ["[12][136]|3[356]|4[0246]|6[03]|90[1-9]"], "0$1", 0, "$1 $2 $3"], ["(\\d)(\\d{2,3})(\\d{2})(\\d{2})", "$1-$2 $3 $4", ["8"], "0$1", 0, "$1 $2 $3 $4"], ["(\\d{3})(\\d{2,3})(\\d{2})", "$1-$2 $3", ["1[2457]|2(?:[247-9]|5[0138])|3[0247-9]|4[1357-9]|5[0-35-9]|6(?:[125689]|4[02-57]|7[0-2])|9(?:[125-8]|3[02-5]|4[0-3])"], "0$1", 0, "$1 $2 $3"], ["(\\d{3})(\\d{2,3})(\\d{3})", "$1-$2 $3", ["9(?:00|39|44)"], "0$1", 0, "$1 $2 $3"], ["(\\d{2})(\\d{2,3})(\\d{2})(\\d{2})", "$1-$2 $3 $4", ["1[13689]|2[0136]|3[1356]|4[0246]|54|6[03]|90[1-9]"], "0$1", 0, "$1 $2 $3 $4"], ["(\\d{2})(\\d{3})(\\d{2})(\\d{2})", "$1-$2 $3 $4", ["10|7"], "0$1", 0, "$1 $2 $3 $4"], ["(\\d)(\\d{3})(\\d{3})(\\d{2})", "$1-$2 $3 $4", ["8"], "0$1", 0, "$1 $2 $3 $4"], ["(\\d{3})(\\d{2})(\\d{2})(\\d{2})", "$1-$2 $3 $4", ["[13-5]|2(?:[247-9]|5[0138])|6(?:[124-689]|7[0-2])|9(?:[125-8]|3[02-5]|4[0-3])"], "0$1", 0, "$1 $2 $3 $4"], ["(\\d{3})(\\d{2})(\\d{2})(\\d{3})", "$1-$2 $3 $4", ["9"], "0$1", 0, "$1 $2 $3 $4"], ["(\\d{3})(\\d{2})(\\d{3})(\\d{2})(\\d{2})", "$1-$2 $3 $4 $5", ["[26]"], "0$1", 0, "$1 $2 $3 $4 $5"]], "0"], SG: ["65", "0[0-3]\\d", "(?:(?:1\\d|8)\\d\\d|7000)\\d{7}|[3689]\\d{7}", [8, 10, 11], [["(\\d{4})(\\d{4})", "$1 $2", ["[369]|8(?:0[1-9]|[1-9])"]], ["(\\d{3})(\\d{3})(\\d{4})", "$1 $2 $3", ["8"]], ["(\\d{4})(\\d{4})(\\d{3})", "$1 $2 $3", ["7"]], ["(\\d{4})(\\d{3})(\\d{4})", "$1 $2 $3", ["1"]]]], SH: ["290", "00", "(?:[256]\\d|8)\\d{3}", [4, 5], 0, 0, 0, 0, 0, 0, "[256]"], SI: ["386", "00|10(?:22|66|88|99)", "[1-7]\\d{7}|8\\d{4,7}|90\\d{4,6}", [5, 6, 7, 8], [["(\\d{2})(\\d{3,6})", "$1 $2", ["8[09]|9"], "0$1"], ["(\\d{3})(\\d{5})", "$1 $2", ["59|8"], "0$1"], ["(\\d{2})(\\d{3})(\\d{3})", "$1 $2 $3", ["[37][01]|4[0139]|51|6"], "0$1"], ["(\\d)(\\d{3})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["[1-57]"], "(0$1)"]], "0", 0, 0, 0, 0, 0, 0, "00"], SJ: ["47", "00", "0\\d{4}|(?:[489]\\d|79)\\d{6}", [5, 8], 0, 0, 0, 0, 0, 0, "79"], SK: ["421", "00", "[2-689]\\d{8}|[2-59]\\d{6}|[2-5]\\d{5}", [6, 7, 9], [["(\\d)(\\d{2})(\\d{3,4})", "$1 $2 $3", ["21"], "0$1"], ["(\\d{2})(\\d{2})(\\d{2,3})", "$1 $2 $3", ["[3-5][1-8]1", "[3-5][1-8]1[67]"], "0$1"], ["(\\d)(\\d{3})(\\d{3})(\\d{2})", "$1/$2 $3 $4", ["2"], "0$1"], ["(\\d{3})(\\d{3})(\\d{3})", "$1 $2 $3", ["[689]"], "0$1"], ["(\\d{2})(\\d{3})(\\d{2})(\\d{2})", "$1/$2 $3 $4", ["[3-5]"], "0$1"]], "0"], SL: ["232", "00", "(?:[237-9]\\d|66)\\d{6}", [8], [["(\\d{2})(\\d{6})", "$1 $2", ["[236-9]"], "(0$1)"]], "0"], SM: ["378", "00", "(?:0549|[5-7]\\d)\\d{6}", [8, 10], [["(\\d{2})(\\d{2})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["[5-7]"]], ["(\\d{4})(\\d{6})", "$1 $2", ["0"]]], 0, 0, "([89]\\d{5})$", "0549$1"], SN: ["221", "00", "(?:[378]\\d|93)\\d{7}", [9], [["(\\d{3})(\\d{2})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["8"]], ["(\\d{2})(\\d{3})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["[379]"]]]], SO: ["252", "00", "[346-9]\\d{8}|[12679]\\d{7}|[1-5]\\d{6}|[1348]\\d{5}", [6, 7, 8, 9], [["(\\d{2})(\\d{4})", "$1 $2", ["8[125]"]], ["(\\d{6})", "$1", ["[134]"]], ["(\\d)(\\d{6})", "$1 $2", ["[15]|2[0-79]|3[0-46-8]|4[0-7]"]], ["(\\d)(\\d{7})", "$1 $2", ["(?:2|90)4|[67]"]], ["(\\d{3})(\\d{3})(\\d{3})", "$1 $2 $3", ["[348]|64|79|90"]], ["(\\d{2})(\\d{5,7})", "$1 $2", ["1|28|6[0-35-9]|7[67]|9[2-9]"]]], "0"], SR: ["597", "00", "(?:[2-5]|68|[78]\\d)\\d{5}", [6, 7], [["(\\d{2})(\\d{2})(\\d{2})", "$1-$2-$3", ["56"]], ["(\\d{3})(\\d{3})", "$1-$2", ["[2-5]"]], ["(\\d{3})(\\d{4})", "$1-$2", ["[6-8]"]]]], SS: ["211", "00", "[19]\\d{8}", [9], [["(\\d{3})(\\d{3})(\\d{3})", "$1 $2 $3", ["[19]"], "0$1"]], "0"], ST: ["239", "00", "(?:22|9\\d)\\d{5}", [7], [["(\\d{3})(\\d{4})", "$1 $2", ["[29]"]]]], SV: ["503", "00", "[267]\\d{7}|(?:80\\d|900)\\d{4}(?:\\d{4})?", [7, 8, 11], [["(\\d{3})(\\d{4})", "$1 $2", ["[89]"]], ["(\\d{4})(\\d{4})", "$1 $2", ["[267]"]], ["(\\d{3})(\\d{4})(\\d{4})", "$1 $2 $3", ["[89]"]]]], SX: ["1", "011", "7215\\d{6}|(?:[58]\\d\\d|900)\\d{7}", [10], 0, "1", 0, "(5\\d{6})$|1", "721$1", 0, "721"], SY: ["963", "00", "[1-359]\\d{8}|[1-5]\\d{7}", [8, 9], [["(\\d{2})(\\d{3})(\\d{3,4})", "$1 $2 $3", ["[1-4]|5[1-3]"], "0$1", 1], ["(\\d{3})(\\d{3})(\\d{3})", "$1 $2 $3", ["[59]"], "0$1", 1]], "0"], SZ: ["268", "00", "0800\\d{4}|(?:[237]\\d|900)\\d{6}", [8, 9], [["(\\d{4})(\\d{4})", "$1 $2", ["[0237]"]], ["(\\d{5})(\\d{4})", "$1 $2", ["9"]]]], TA: ["290", "00", "8\\d{3}", [4], 0, 0, 0, 0, 0, 0, "8"], TC: ["1", "011", "(?:[58]\\d\\d|649|900)\\d{7}", [10], 0, "1", 0, "([2-479]\\d{6})$|1", "649$1", 0, "649"], TD: ["235", "00|16", "(?:22|[689]\\d|77)\\d{6}", [8], [["(\\d{2})(\\d{2})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["[26-9]"]]], 0, 0, 0, 0, 0, 0, 0, "00"], TG: ["228", "00", "[279]\\d{7}", [8], [["(\\d{2})(\\d{2})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["[279]"]]]], TH: ["66", "00[1-9]", "(?:001800|[2-57]|[689]\\d)\\d{7}|1\\d{7,9}", [8, 9, 10, 13], [["(\\d)(\\d{3})(\\d{4})", "$1 $2 $3", ["2"], "0$1"], ["(\\d{2})(\\d{3})(\\d{3,4})", "$1 $2 $3", ["[13-9]"], "0$1"], ["(\\d{4})(\\d{3})(\\d{3})", "$1 $2 $3", ["1"]]], "0"], TJ: ["992", "810", "[0-57-9]\\d{8}", [9], [["(\\d{6})(\\d)(\\d{2})", "$1 $2 $3", ["331", "3317"]], ["(\\d{3})(\\d{2})(\\d{4})", "$1 $2 $3", ["44[02-479]|[34]7"]], ["(\\d{4})(\\d)(\\d{4})", "$1 $2 $3", ["3(?:[1245]|3[12])"]], ["(\\d{2})(\\d{3})(\\d{4})", "$1 $2 $3", ["[0-57-9]"]]], 0, 0, 0, 0, 0, 0, 0, "8~10"], TK: ["690", "00", "[2-47]\\d{3,6}", [4, 5, 6, 7]], TL: ["670", "00", "7\\d{7}|(?:[2-47]\\d|[89]0)\\d{5}", [7, 8], [["(\\d{3})(\\d{4})", "$1 $2", ["[2-489]|70"]], ["(\\d{4})(\\d{4})", "$1 $2", ["7"]]]], TM: ["993", "810", "(?:[1-6]\\d|71)\\d{6}", [8], [["(\\d{2})(\\d{2})(\\d{2})(\\d{2})", "$1 $2-$3-$4", ["12"], "(8 $1)"], ["(\\d{3})(\\d)(\\d{2})(\\d{2})", "$1 $2-$3-$4", ["[1-5]"], "(8 $1)"], ["(\\d{2})(\\d{6})", "$1 $2", ["[67]"], "8 $1"]], "8", 0, 0, 0, 0, 0, 0, "8~10"], TN: ["216", "00", "[2-57-9]\\d{7}", [8], [["(\\d{2})(\\d{3})(\\d{3})", "$1 $2 $3", ["[2-57-9]"]]]], TO: ["676", "00", "(?:0800|(?:[5-8]\\d\\d|999)\\d)\\d{3}|[2-8]\\d{4}", [5, 7], [["(\\d{2})(\\d{3})", "$1-$2", ["[2-4]|50|6[09]|7[0-24-69]|8[05]"]], ["(\\d{4})(\\d{3})", "$1 $2", ["0"]], ["(\\d{3})(\\d{4})", "$1 $2", ["[5-9]"]]]], TR: ["90", "00", "4\\d{6}|8\\d{11,12}|(?:[2-58]\\d\\d|900)\\d{7}", [7, 10, 12, 13], [["(\\d{3})(\\d{3})(\\d{4})", "$1 $2 $3", ["512|8[01589]|90"], "0$1", 1], ["(\\d{3})(\\d{3})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["5(?:[0-59]|61)", "5(?:[0-59]|61[06])", "5(?:[0-59]|61[06]1)"], "0$1", 1], ["(\\d{3})(\\d{3})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["[24][1-8]|3[1-9]"], "(0$1)", 1], ["(\\d{3})(\\d{3})(\\d{6,7})", "$1 $2 $3", ["80"], "0$1", 1]], "0"], TT: ["1", "011", "(?:[58]\\d\\d|900)\\d{7}", [10], 0, "1", 0, "([2-46-8]\\d{6})$|1", "868$1", 0, "868"], TV: ["688", "00", "(?:2|7\\d\\d|90)\\d{4}", [5, 6, 7], [["(\\d{2})(\\d{3})", "$1 $2", ["2"]], ["(\\d{2})(\\d{4})", "$1 $2", ["90"]], ["(\\d{2})(\\d{5})", "$1 $2", ["7"]]]], TW: ["886", "0(?:0[25-79]|19)", "[2-689]\\d{8}|7\\d{9,10}|[2-8]\\d{7}|2\\d{6}", [7, 8, 9, 10, 11], [["(\\d{2})(\\d)(\\d{4})", "$1 $2 $3", ["202"], "0$1"], ["(\\d{2})(\\d{3})(\\d{3,4})", "$1 $2 $3", ["[258]0"], "0$1"], ["(\\d)(\\d{3,4})(\\d{4})", "$1 $2 $3", ["[23568]|4(?:0[02-48]|[1-47-9])|7[1-9]", "[23568]|4(?:0[2-48]|[1-47-9])|(?:400|7)[1-9]"], "0$1"], ["(\\d{3})(\\d{3})(\\d{3})", "$1 $2 $3", ["[49]"], "0$1"], ["(\\d{2})(\\d{4})(\\d{4,5})", "$1 $2 $3", ["7"], "0$1"]], "0", 0, 0, 0, 0, 0, 0, 0, "#"], TZ: ["255", "00[056]", "(?:[25-8]\\d|41|90)\\d{7}", [9], [["(\\d{3})(\\d{2})(\\d{4})", "$1 $2 $3", ["[89]"], "0$1"], ["(\\d{2})(\\d{3})(\\d{4})", "$1 $2 $3", ["[24]"], "0$1"], ["(\\d{2})(\\d{7})", "$1 $2", ["5"]], ["(\\d{3})(\\d{3})(\\d{3})", "$1 $2 $3", ["[67]"], "0$1"]], "0"], UA: ["380", "00", "[89]\\d{9}|[3-9]\\d{8}", [9, 10], [["(\\d{3})(\\d{3})(\\d{3})", "$1 $2 $3", ["6[12][29]|(?:3[1-8]|4[136-8]|5[12457]|6[49])2|(?:56|65)[24]", "6[12][29]|(?:35|4[1378]|5[12457]|6[49])2|(?:56|65)[24]|(?:3[1-46-8]|46)2[013-9]"], "0$1"], ["(\\d{4})(\\d{5})", "$1 $2", ["3[1-8]|4(?:[1367]|[45][6-9]|8[4-6])|5(?:[1-5]|6[0135689]|7[4-6])|6(?:[12][3-7]|[459])", "3[1-8]|4(?:[1367]|[45][6-9]|8[4-6])|5(?:[1-5]|6(?:[015689]|3[02389])|7[4-6])|6(?:[12][3-7]|[459])"], "0$1"], ["(\\d{2})(\\d{3})(\\d{4})", "$1 $2 $3", ["[3-7]|89|9[1-9]"], "0$1"], ["(\\d{3})(\\d{3})(\\d{3,4})", "$1 $2 $3", ["[89]"], "0$1"]], "0", 0, 0, 0, 0, 0, 0, "0~0"], UG: ["256", "00[057]", "800\\d{6}|(?:[29]0|[347]\\d)\\d{7}", [9], [["(\\d{4})(\\d{5})", "$1 $2", ["202", "2024"], "0$1"], ["(\\d{3})(\\d{6})", "$1 $2", ["[27-9]|4(?:6[45]|[7-9])"], "0$1"], ["(\\d{2})(\\d{7})", "$1 $2", ["[34]"], "0$1"]], "0"], US: ["1", "011", "[2-9]\\d{9}|3\\d{6}", [10], [["(\\d{3})(\\d{4})", "$1-$2", ["310"], 0, 1], ["(\\d{3})(\\d{3})(\\d{4})", "($1) $2-$3", ["[2-9]"], 0, 1, "$1-$2-$3"]], "1", 0, 0, 0, 0, 0, [["(?:3052(?:0[0-8]|[1-9]\\d)|5056(?:[0-35-9]\\d|4[468]))\\d{4}|(?:305[3-9]|472[24]|505[2-57-9]|983[2-47-9])\\d{6}|(?:2(?:0[1-35-9]|1[02-9]|2[03-57-9]|3[1459]|4[08]|5[1-46]|6[0279]|7[0269]|8[13])|3(?:0[1-47-9]|1[02-9]|2[0135-79]|3[0-24679]|4[167]|5[0-2]|6[01349]|8[056])|4(?:0[124-9]|1[02-579]|2[3-5]|3[0245]|4[023578]|58|6[349]|7[0589]|8[04])|5(?:0[1-47-9]|1[0235-8]|20|3[0149]|4[01]|5[179]|6[1-47]|7[0-5]|8[0256])|6(?:0[1-35-9]|1[024-9]|2[03689]|3[016]|4[0156]|5[01679]|6[0-279]|78|8[0-29])|7(?:0[1-46-8]|1[2-9]|2[04-8]|3[0-247]|4[037]|5[47]|6[02359]|7[0-59]|8[156])|8(?:0[1-68]|1[02-8]|2[068]|3[0-2589]|4[03578]|5[046-9]|6[02-5]|7[028])|9(?:0[1346-9]|1[02-9]|2[0589]|3[0146-8]|4[01357-9]|5[12469]|7[0-389]|8[04-69]))[2-9]\\d{6}"], [""], ["8(?:00|33|44|55|66|77|88)[2-9]\\d{6}"], ["900[2-9]\\d{6}"], ["52(?:3(?:[2-46-9][02-9]\\d|5(?:[02-46-9]\\d|5[0-46-9]))|4(?:[2-478][02-9]\\d|5(?:[034]\\d|2[024-9]|5[0-46-9])|6(?:0[1-9]|[2-9]\\d)|9(?:[05-9]\\d|2[0-5]|49)))\\d{4}|52[34][2-9]1[02-9]\\d{4}|5(?:00|2[125-9]|33|44|66|77|88)[2-9]\\d{6}"], 0, 0, 0, ["305209\\d{4}"]]], UY: ["598", "0(?:0|1[3-9]\\d)", "0004\\d{2,9}|[1249]\\d{7}|(?:[49]\\d|80)\\d{5}", [6, 7, 8, 9, 10, 11, 12, 13], [["(\\d{3})(\\d{3,4})", "$1 $2", ["0"]], ["(\\d{3})(\\d{4})", "$1 $2", ["[49]0|8"], "0$1"], ["(\\d{2})(\\d{3})(\\d{3})", "$1 $2 $3", ["9"], "0$1"], ["(\\d{4})(\\d{4})", "$1 $2", ["[124]"]], ["(\\d{3})(\\d{3})(\\d{2,4})", "$1 $2 $3", ["0"]], ["(\\d{3})(\\d{3})(\\d{3})(\\d{2,4})", "$1 $2 $3 $4", ["0"]]], "0", 0, 0, 0, 0, 0, 0, "00", " int. "], UZ: ["998", "00", "(?:20|33|[5-9]\\d)\\d{7}", [9], [["(\\d{2})(\\d{3})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["[235-9]"]]]], VA: ["39", "00", "0\\d{5,10}|3[0-8]\\d{7,10}|55\\d{8}|8\\d{5}(?:\\d{2,4})?|(?:1\\d|39)\\d{7,8}", [6, 7, 8, 9, 10, 11, 12], 0, 0, 0, 0, 0, 0, "06698"], VC: ["1", "011", "(?:[58]\\d\\d|784|900)\\d{7}", [10], 0, "1", 0, "([2-7]\\d{6})$|1", "784$1", 0, "784"], VE: ["58", "00", "[68]00\\d{7}|(?:[24]\\d|[59]0)\\d{8}", [10], [["(\\d{3})(\\d{7})", "$1-$2", ["[24-689]"], "0$1"]], "0"], VG: ["1", "011", "(?:284|[58]\\d\\d|900)\\d{7}", [10], 0, "1", 0, "([2-578]\\d{6})$|1", "284$1", 0, "284"], VI: ["1", "011", "[58]\\d{9}|(?:34|90)0\\d{7}", [10], 0, "1", 0, "([2-9]\\d{6})$|1", "340$1", 0, "340"], VN: ["84", "00", "[12]\\d{9}|[135-9]\\d{8}|[16]\\d{7}|[16-8]\\d{6}", [7, 8, 9, 10], [["(\\d{2})(\\d{5})", "$1 $2", ["80"], "0$1", 1], ["(\\d{4})(\\d{4,6})", "$1 $2", ["1"], 0, 1], ["(\\d{2})(\\d{3})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["6"], "0$1", 1], ["(\\d{3})(\\d{3})(\\d{3})", "$1 $2 $3", ["[357-9]"], "0$1", 1], ["(\\d{2})(\\d{4})(\\d{4})", "$1 $2 $3", ["2[48]"], "0$1", 1], ["(\\d{3})(\\d{4})(\\d{3})", "$1 $2 $3", ["2"], "0$1", 1]], "0"], VU: ["678", "00", "[57-9]\\d{6}|(?:[238]\\d|48)\\d{3}", [5, 7], [["(\\d{3})(\\d{4})", "$1 $2", ["[57-9]"]]]], WF: ["681", "00", "(?:40|72|8\\d{4})\\d{4}|[89]\\d{5}", [6, 9], [["(\\d{2})(\\d{2})(\\d{2})", "$1 $2 $3", ["[47-9]"]], ["(\\d{3})(\\d{2})(\\d{2})(\\d{2})", "$1 $2 $3 $4", ["8"]]]], WS: ["685", "0", "(?:[2-6]|8\\d{5})\\d{4}|[78]\\d{6}|[68]\\d{5}", [5, 6, 7, 10], [["(\\d{5})", "$1", ["[2-5]|6[1-9]"]], ["(\\d{3})(\\d{3,7})", "$1 $2", ["[68]"]], ["(\\d{2})(\\d{5})", "$1 $2", ["7"]]]], XK: ["383", "00", "2\\d{7,8}|3\\d{7,11}|(?:4\\d\\d|[89]00)\\d{5}", [8, 9, 10, 11, 12], [["(\\d{3})(\\d{5})", "$1 $2", ["[89]"], "0$1"], ["(\\d{2})(\\d{3})(\\d{3})", "$1 $2 $3", ["[2-4]"], "0$1"], ["(\\d{3})(\\d{3})(\\d{3})", "$1 $2 $3", ["2|39"], "0$1"], ["(\\d{2})(\\d{7,10})", "$1 $2", ["3"], "0$1"]], "0"], YE: ["967", "00", "(?:1|7\\d)\\d{7}|[1-7]\\d{6}", [7, 8, 9], [["(\\d)(\\d{3})(\\d{3,4})", "$1 $2 $3", ["[1-6]|7(?:[24-6]|8[0-7])"], "0$1"], ["(\\d{3})(\\d{3})(\\d{3})", "$1 $2 $3", ["7"], "0$1"]], "0"], YT: ["262", "00", "7093\\d{5}|(?:80|9\\d)\\d{7}|(?:26|63)9\\d{6}", [9], 0, "0", 0, 0, 0, 0, 0, [["269(?:0[0-467]|15|5[0-4]|6\\d|[78]0)\\d{4}"], ["(?:639(?:0[0-79]|1[019]|[267]\\d|3[09]|40|5[05-9]|9[04-79])|7093[5-7])\\d{4}"], ["80\\d{7}"], 0, 0, 0, 0, 0, ["9(?:(?:39|47)8[01]|769\\d)\\d{4}"]]], ZA: ["27", "00", "[1-79]\\d{8}|8\\d{4,9}", [5, 6, 7, 8, 9, 10], [["(\\d{2})(\\d{3,4})", "$1 $2", ["8[1-4]"], "0$1"], ["(\\d{2})(\\d{3})(\\d{2,3})", "$1 $2 $3", ["8[1-4]"], "0$1"], ["(\\d{3})(\\d{3})(\\d{3})", "$1 $2 $3", ["860"], "0$1"], ["(\\d{2})(\\d{3})(\\d{4})", "$1 $2 $3", ["[1-9]"], "0$1"], ["(\\d{3})(\\d{3})(\\d{4})", "$1 $2 $3", ["8"], "0$1"]], "0"], ZM: ["260", "00", "800\\d{6}|(?:21|63|[79]\\d)\\d{7}", [9], [["(\\d{3})(\\d{3})(\\d{3})", "$1 $2 $3", ["[28]"], "0$1"], ["(\\d{2})(\\d{7})", "$1 $2", ["[79]"], "0$1"]], "0"], ZW: ["263", "00", "2(?:[0-57-9]\\d{6,8}|6[0-24-9]\\d{6,7})|[38]\\d{9}|[35-8]\\d{8}|[3-6]\\d{7}|[1-689]\\d{6}|[1-3569]\\d{5}|[1356]\\d{4}", [5, 6, 7, 8, 9, 10], [["(\\d{3})(\\d{3,5})", "$1 $2", ["2(?:0[45]|2[278]|[49]8)|3(?:[09]8|17)|6(?:[29]8|37|75)|[23][78]|(?:33|5[15]|6[68])[78]"], "0$1"], ["(\\d)(\\d{3})(\\d{2,4})", "$1 $2 $3", ["[49]"], "0$1"], ["(\\d{3})(\\d{4})", "$1 $2", ["80"], "0$1"], ["(\\d{2})(\\d{7})", "$1 $2", ["24|8[13-59]|(?:2[05-79]|39|5[45]|6[15-8])2", "2(?:02[014]|4|[56]20|[79]2)|392|5(?:42|525)|6(?:[16-8]21|52[013])|8[13-59]"], "(0$1)"], ["(\\d{2})(\\d{3})(\\d{4})", "$1 $2 $3", ["7"], "0$1"], ["(\\d{3})(\\d{3})(\\d{3,4})", "$1 $2 $3", ["2(?:1[39]|2[0157]|[378]|[56][14])|3(?:12|29)", "2(?:1[39]|2[0157]|[378]|[56][14])|3(?:123|29)"], "0$1"], ["(\\d{4})(\\d{6})", "$1 $2", ["8"], "0$1"], ["(\\d{2})(\\d{3,5})", "$1 $2", ["1|2(?:0[0-36-9]|12|29|[56])|3(?:1[0-689]|[24-6])|5(?:[0236-9]|1[2-4])|6(?:[013-59]|7[0-46-9])|(?:33|55|6[68])[0-69]|(?:29|3[09]|62)[0-79]"], "0$1"], ["(\\d{2})(\\d{3})(\\d{3,4})", "$1 $2 $3", ["29[013-9]|39|54"], "0$1"], ["(\\d{4})(\\d{3,5})", "$1 $2", ["(?:25|54)8", "258|5483"], "0$1"]], "0"] }, nonGeographic: { 800: ["800", 0, "(?:00|[1-9]\\d)\\d{6}", [8], [["(\\d{4})(\\d{4})", "$1 $2", ["\\d"]]], 0, 0, 0, 0, 0, 0, [0, 0, ["(?:00|[1-9]\\d)\\d{6}"]]], 808: ["808", 0, "[1-9]\\d{7}", [8], [["(\\d{4})(\\d{4})", "$1 $2", ["[1-9]"]]], 0, 0, 0, 0, 0, 0, [0, 0, 0, 0, 0, 0, 0, 0, 0, ["[1-9]\\d{7}"]]], 870: ["870", 0, "7\\d{11}|[235-7]\\d{8}", [9, 12], [["(\\d{3})(\\d{3})(\\d{3})", "$1 $2 $3", ["[235-7]"]]], 0, 0, 0, 0, 0, 0, [0, ["(?:[356]|774[45])\\d{8}|7[6-8]\\d{7}"], 0, 0, 0, 0, 0, 0, ["2\\d{8}", [9]]]], 878: ["878", 0, "10\\d{10}", [12], [["(\\d{2})(\\d{5})(\\d{5})", "$1 $2 $3", ["1"]]], 0, 0, 0, 0, 0, 0, [0, 0, 0, 0, 0, 0, 0, 0, ["10\\d{10}"]]], 881: ["881", 0, "6\\d{9}|[0-36-9]\\d{8}", [9, 10], [["(\\d)(\\d{3})(\\d{5})", "$1 $2 $3", ["[0-37-9]"]], ["(\\d)(\\d{3})(\\d{5,6})", "$1 $2 $3", ["6"]]], 0, 0, 0, 0, 0, 0, [0, ["6\\d{9}|[0-36-9]\\d{8}"]]], 882: ["882", 0, "[13]\\d{6}(?:\\d{2,5})?|[19]\\d{7}|(?:[25]\\d\\d|4)\\d{7}(?:\\d{2})?", [7, 8, 9, 10, 11, 12], [["(\\d{2})(\\d{5})", "$1 $2", ["16|342"]], ["(\\d{2})(\\d{6})", "$1 $2", ["49"]], ["(\\d{2})(\\d{2})(\\d{4})", "$1 $2 $3", ["1[36]|9"]], ["(\\d{2})(\\d{4})(\\d{3})", "$1 $2 $3", ["3[23]"]], ["(\\d{2})(\\d{3,4})(\\d{4})", "$1 $2 $3", ["16"]], ["(\\d{2})(\\d{4})(\\d{4})", "$1 $2 $3", ["10|23|3(?:[15]|4[57])|4|51"]], ["(\\d{3})(\\d{4})(\\d{4})", "$1 $2 $3", ["34"]], ["(\\d{2})(\\d{4,5})(\\d{5})", "$1 $2 $3", ["[1-35]"]]], 0, 0, 0, 0, 0, 0, [0, ["342\\d{4}|(?:337|49)\\d{6}|(?:3(?:2|47|7\\d{3})|50\\d{3})\\d{7}", [7, 8, 9, 10, 12]], 0, 0, 0, ["348[57]\\d{7}", [11]], 0, 0, ["1(?:3(?:0[0347]|[13][0139]|2[035]|4[013568]|6[0459]|7[06]|8[15-8]|9[0689])\\d{4}|6\\d{5,10})|(?:345\\d|9[89])\\d{6}|(?:10|2(?:3|85\\d)|3(?:[15]|[69]\\d\\d)|4[15-8]|51)\\d{8}"]]], 883: ["883", 0, "(?:[1-4]\\d|51)\\d{6,10}", [8, 9, 10, 11, 12], [["(\\d{3})(\\d{3})(\\d{2,8})", "$1 $2 $3", ["[14]|2[24-689]|3[02-689]|51[24-9]"]], ["(\\d{3})(\\d{3})(\\d{3})", "$1 $2 $3", ["510"]], ["(\\d{3})(\\d{3})(\\d{4})", "$1 $2 $3", ["21"]], ["(\\d{4})(\\d{4})(\\d{4})", "$1 $2 $3", ["51[13]"]], ["(\\d{3})(\\d{3})(\\d{3})(\\d{3})", "$1 $2 $3 $4", ["[235]"]]], 0, 0, 0, 0, 0, 0, [0, 0, 0, 0, 0, 0, 0, 0, ["(?:2(?:00\\d\\d|10)|(?:370[1-9]|51\\d0)\\d)\\d{7}|51(?:00\\d{5}|[24-9]0\\d{4,7})|(?:1[0-79]|2[24-689]|3[02-689]|4[0-4])0\\d{5,9}"]]], 888: ["888", 0, "\\d{11}", [11], [["(\\d{3})(\\d{3})(\\d{5})", "$1 $2 $3"]], 0, 0, 0, 0, 0, 0, [0, 0, 0, 0, 0, 0, ["\\d{11}"]]], 979: ["979", 0, "[1359]\\d{8}", [9], [["(\\d)(\\d{4})(\\d{4})", "$1 $2 $3", ["[1359]"]]], 0, 0, 0, 0, 0, 0, [0, 0, 0, ["[1359]\\d{8}"]]] } };
650
+ function jt(e, d) {
651
+ var t = Array.prototype.slice.call(d);
652
+ return t.push(Ht), e.apply(this, t);
653
+ }
654
+ function Se(e) {
655
+ "@babel/helpers - typeof";
656
+ return Se = typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? function(d) {
657
+ return typeof d;
658
+ } : function(d) {
659
+ return d && typeof Symbol == "function" && d.constructor === Symbol && d !== Symbol.prototype ? "symbol" : typeof d;
660
+ }, Se(e);
661
+ }
662
+ function Kt(e, d, t) {
663
+ return Object.defineProperty(e, "prototype", { writable: !1 }), e;
664
+ }
665
+ function Wt(e, d) {
666
+ if (!(e instanceof d))
667
+ throw new TypeError("Cannot call a class as a function");
668
+ }
669
+ function Yt(e, d) {
670
+ if (typeof d != "function" && d !== null)
671
+ throw new TypeError("Super expression must either be null or a function");
672
+ e.prototype = Object.create(d && d.prototype, { constructor: { value: e, writable: !0, configurable: !0 } }), Object.defineProperty(e, "prototype", { writable: !1 }), d && te(e, d);
673
+ }
674
+ function Xt(e) {
675
+ var d = Dd();
676
+ return function() {
677
+ var r = re(e), n;
678
+ if (d) {
679
+ var o = re(this).constructor;
680
+ n = Reflect.construct(r, arguments, o);
681
+ } else
682
+ n = r.apply(this, arguments);
683
+ return Zt(this, n);
684
+ };
685
+ }
686
+ function Zt(e, d) {
687
+ if (d && (Se(d) === "object" || typeof d == "function"))
688
+ return d;
689
+ if (d !== void 0)
690
+ throw new TypeError("Derived constructors may only return object or undefined");
691
+ return Md(e);
692
+ }
693
+ function Md(e) {
694
+ if (e === void 0)
695
+ throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
696
+ return e;
697
+ }
698
+ function Ee(e) {
699
+ var d = typeof Map == "function" ? /* @__PURE__ */ new Map() : void 0;
700
+ return Ee = function(r) {
701
+ if (r === null || !qt(r)) return r;
702
+ if (typeof r != "function")
703
+ throw new TypeError("Super expression must either be null or a function");
704
+ if (typeof d < "u") {
705
+ if (d.has(r)) return d.get(r);
706
+ d.set(r, n);
707
+ }
708
+ function n() {
709
+ return ue(r, arguments, re(this).constructor);
710
+ }
711
+ return n.prototype = Object.create(r.prototype, { constructor: { value: n, enumerable: !1, writable: !0, configurable: !0 } }), te(n, r);
712
+ }, Ee(e);
713
+ }
714
+ function ue(e, d, t) {
715
+ return Dd() ? ue = Reflect.construct : ue = function(n, o, a) {
716
+ var i = [null];
717
+ i.push.apply(i, o);
718
+ var s = Function.bind.apply(n, i), u = new s();
719
+ return a && te(u, a.prototype), u;
720
+ }, ue.apply(null, arguments);
721
+ }
722
+ function Dd() {
723
+ if (typeof Reflect > "u" || !Reflect.construct || Reflect.construct.sham) return !1;
724
+ if (typeof Proxy == "function") return !0;
725
+ try {
726
+ return Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {
727
+ })), !0;
728
+ } catch {
729
+ return !1;
730
+ }
731
+ }
732
+ function qt(e) {
733
+ return Function.toString.call(e).indexOf("[native code]") !== -1;
734
+ }
735
+ function te(e, d) {
736
+ return te = Object.setPrototypeOf || function(r, n) {
737
+ return r.__proto__ = n, r;
738
+ }, te(e, d);
739
+ }
740
+ function re(e) {
741
+ return re = Object.setPrototypeOf ? Object.getPrototypeOf : function(t) {
742
+ return t.__proto__ || Object.getPrototypeOf(t);
743
+ }, re(e);
744
+ }
745
+ var j = /* @__PURE__ */ function(e) {
746
+ Yt(t, e);
747
+ var d = Xt(t);
748
+ function t(r) {
749
+ var n;
750
+ return Wt(this, t), n = d.call(this, r), Object.setPrototypeOf(Md(n), t.prototype), n.name = n.constructor.name, n;
751
+ }
752
+ return Kt(t);
753
+ }(/* @__PURE__ */ Ee(Error)), Re = 2, zt = 17, Jt = 3, G = "0-90-9٠-٩۰-۹", Qt = "-‐-―−ー-", e0 = "//", d0 = "..", t0 = "  ­​⁠ ", r0 = "()()[]\\[\\]", n0 = "~⁓∼~", fe = "".concat(Qt).concat(e0).concat(d0).concat(t0).concat(r0).concat(n0), Te = "++";
754
+ function nd(e, d) {
755
+ e = e.split("-"), d = d.split("-");
756
+ for (var t = e[0].split("."), r = d[0].split("."), n = 0; n < 3; n++) {
757
+ var o = Number(t[n]), a = Number(r[n]);
758
+ if (o > a) return 1;
759
+ if (a > o) return -1;
760
+ if (!isNaN(o) && isNaN(a)) return 1;
761
+ if (isNaN(o) && !isNaN(a)) return -1;
762
+ }
763
+ return e[1] && d[1] ? e[1] > d[1] ? 1 : e[1] < d[1] ? -1 : 0 : !e[1] && d[1] ? 1 : e[1] && !d[1] ? -1 : 0;
764
+ }
765
+ var o0 = {}.constructor;
766
+ function ce(e) {
767
+ return e != null && e.constructor === o0;
768
+ }
769
+ function xe(e) {
770
+ "@babel/helpers - typeof";
771
+ return xe = typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? function(d) {
772
+ return typeof d;
773
+ } : function(d) {
774
+ return d && typeof Symbol == "function" && d.constructor === Symbol && d !== Symbol.prototype ? "symbol" : typeof d;
775
+ }, xe(e);
776
+ }
777
+ function ve(e, d) {
778
+ if (!(e instanceof d))
779
+ throw new TypeError("Cannot call a class as a function");
780
+ }
781
+ function a0(e, d) {
782
+ for (var t = 0; t < d.length; t++) {
783
+ var r = d[t];
784
+ r.enumerable = r.enumerable || !1, r.configurable = !0, "value" in r && (r.writable = !0), Object.defineProperty(e, r.key, r);
785
+ }
786
+ }
787
+ function ge(e, d, t) {
788
+ return d && a0(e.prototype, d), Object.defineProperty(e, "prototype", { writable: !1 }), e;
789
+ }
790
+ var $0 = "1.2.0", i0 = "1.7.35", od = " ext. ", l0 = /^\d+$/, D = /* @__PURE__ */ function() {
791
+ function e(d) {
792
+ ve(this, e), f0(d), this.metadata = d, Ld.call(this, d);
793
+ }
794
+ return ge(e, [{
795
+ key: "getCountries",
796
+ value: function() {
797
+ return Object.keys(this.metadata.countries).filter(function(t) {
798
+ return t !== "001";
799
+ });
800
+ }
801
+ }, {
802
+ key: "getCountryMetadata",
803
+ value: function(t) {
804
+ return this.metadata.countries[t];
805
+ }
806
+ }, {
807
+ key: "nonGeographic",
808
+ value: function() {
809
+ if (!(this.v1 || this.v2 || this.v3))
810
+ return this.metadata.nonGeographic || this.metadata.nonGeographical;
811
+ }
812
+ }, {
813
+ key: "hasCountry",
814
+ value: function(t) {
815
+ return this.getCountryMetadata(t) !== void 0;
816
+ }
817
+ }, {
818
+ key: "hasCallingCode",
819
+ value: function(t) {
820
+ if (this.getCountryCodesForCallingCode(t))
821
+ return !0;
822
+ if (this.nonGeographic()) {
823
+ if (this.nonGeographic()[t])
824
+ return !0;
825
+ } else {
826
+ var r = this.countryCallingCodes()[t];
827
+ if (r && r.length === 1 && r[0] === "001")
828
+ return !0;
829
+ }
830
+ }
831
+ }, {
832
+ key: "isNonGeographicCallingCode",
833
+ value: function(t) {
834
+ return this.nonGeographic() ? !!this.nonGeographic()[t] : !this.getCountryCodesForCallingCode(t);
835
+ }
836
+ // Deprecated.
837
+ }, {
838
+ key: "country",
839
+ value: function(t) {
840
+ return this.selectNumberingPlan(t);
841
+ }
842
+ }, {
843
+ key: "selectNumberingPlan",
844
+ value: function(t, r) {
845
+ if (t && l0.test(t) && (r = t, t = null), t && t !== "001") {
846
+ if (!this.hasCountry(t))
847
+ throw new Error("Unknown country: ".concat(t));
848
+ this.numberingPlan = new ad(this.getCountryMetadata(t), this);
849
+ } else if (r) {
850
+ if (!this.hasCallingCode(r))
851
+ throw new Error("Unknown calling code: ".concat(r));
852
+ this.numberingPlan = new ad(this.getNumberingPlanMetadata(r), this);
853
+ } else
854
+ this.numberingPlan = void 0;
855
+ return this;
856
+ }
857
+ }, {
858
+ key: "getCountryCodesForCallingCode",
859
+ value: function(t) {
860
+ var r = this.countryCallingCodes()[t];
861
+ if (r)
862
+ return r.length === 1 && r[0].length === 3 ? void 0 : r;
863
+ }
864
+ }, {
865
+ key: "getCountryCodeForCallingCode",
866
+ value: function(t) {
867
+ var r = this.getCountryCodesForCallingCode(t);
868
+ if (r)
869
+ return r[0];
870
+ }
871
+ }, {
872
+ key: "getNumberingPlanMetadata",
873
+ value: function(t) {
874
+ var r = this.getCountryCodeForCallingCode(t);
875
+ if (r)
876
+ return this.getCountryMetadata(r);
877
+ if (this.nonGeographic()) {
878
+ var n = this.nonGeographic()[t];
879
+ if (n)
880
+ return n;
881
+ } else {
882
+ var o = this.countryCallingCodes()[t];
883
+ if (o && o.length === 1 && o[0] === "001")
884
+ return this.metadata.countries["001"];
885
+ }
886
+ }
887
+ // Deprecated.
888
+ }, {
889
+ key: "countryCallingCode",
890
+ value: function() {
891
+ return this.numberingPlan.callingCode();
892
+ }
893
+ // Deprecated.
894
+ }, {
895
+ key: "IDDPrefix",
896
+ value: function() {
897
+ return this.numberingPlan.IDDPrefix();
898
+ }
899
+ // Deprecated.
900
+ }, {
901
+ key: "defaultIDDPrefix",
902
+ value: function() {
903
+ return this.numberingPlan.defaultIDDPrefix();
904
+ }
905
+ // Deprecated.
906
+ }, {
907
+ key: "nationalNumberPattern",
908
+ value: function() {
909
+ return this.numberingPlan.nationalNumberPattern();
910
+ }
911
+ // Deprecated.
912
+ }, {
913
+ key: "possibleLengths",
914
+ value: function() {
915
+ return this.numberingPlan.possibleLengths();
916
+ }
917
+ // Deprecated.
918
+ }, {
919
+ key: "formats",
920
+ value: function() {
921
+ return this.numberingPlan.formats();
922
+ }
923
+ // Deprecated.
924
+ }, {
925
+ key: "nationalPrefixForParsing",
926
+ value: function() {
927
+ return this.numberingPlan.nationalPrefixForParsing();
928
+ }
929
+ // Deprecated.
930
+ }, {
931
+ key: "nationalPrefixTransformRule",
932
+ value: function() {
933
+ return this.numberingPlan.nationalPrefixTransformRule();
934
+ }
935
+ // Deprecated.
936
+ }, {
937
+ key: "leadingDigits",
938
+ value: function() {
939
+ return this.numberingPlan.leadingDigits();
940
+ }
941
+ // Deprecated.
942
+ }, {
943
+ key: "hasTypes",
944
+ value: function() {
945
+ return this.numberingPlan.hasTypes();
946
+ }
947
+ // Deprecated.
948
+ }, {
949
+ key: "type",
950
+ value: function(t) {
951
+ return this.numberingPlan.type(t);
952
+ }
953
+ // Deprecated.
954
+ }, {
955
+ key: "ext",
956
+ value: function() {
957
+ return this.numberingPlan.ext();
958
+ }
959
+ }, {
960
+ key: "countryCallingCodes",
961
+ value: function() {
962
+ return this.v1 ? this.metadata.country_phone_code_to_countries : this.metadata.country_calling_codes;
963
+ }
964
+ // Deprecated.
965
+ }, {
966
+ key: "chooseCountryByCountryCallingCode",
967
+ value: function(t) {
968
+ return this.selectNumberingPlan(t);
969
+ }
970
+ }, {
971
+ key: "hasSelectedNumberingPlan",
972
+ value: function() {
973
+ return this.numberingPlan !== void 0;
974
+ }
975
+ }]), e;
976
+ }(), ad = /* @__PURE__ */ function() {
977
+ function e(d, t) {
978
+ ve(this, e), this.globalMetadataObject = t, this.metadata = d, Ld.call(this, t.metadata);
979
+ }
980
+ return ge(e, [{
981
+ key: "callingCode",
982
+ value: function() {
983
+ return this.metadata[0];
984
+ }
985
+ // Formatting information for regions which share
986
+ // a country calling code is contained by only one region
987
+ // for performance reasons. For example, for NANPA region
988
+ // ("North American Numbering Plan Administration",
989
+ // which includes USA, Canada, Cayman Islands, Bahamas, etc)
990
+ // it will be contained in the metadata for `US`.
991
+ }, {
992
+ key: "getDefaultCountryMetadataForRegion",
993
+ value: function() {
994
+ return this.globalMetadataObject.getNumberingPlanMetadata(this.callingCode());
995
+ }
996
+ // Is always present.
997
+ }, {
998
+ key: "IDDPrefix",
999
+ value: function() {
1000
+ if (!(this.v1 || this.v2))
1001
+ return this.metadata[1];
1002
+ }
1003
+ // Is only present when a country supports multiple IDD prefixes.
1004
+ }, {
1005
+ key: "defaultIDDPrefix",
1006
+ value: function() {
1007
+ if (!(this.v1 || this.v2))
1008
+ return this.metadata[12];
1009
+ }
1010
+ }, {
1011
+ key: "nationalNumberPattern",
1012
+ value: function() {
1013
+ return this.v1 || this.v2 ? this.metadata[1] : this.metadata[2];
1014
+ }
1015
+ // "possible length" data is always present in Google's metadata.
1016
+ }, {
1017
+ key: "possibleLengths",
1018
+ value: function() {
1019
+ if (!this.v1)
1020
+ return this.metadata[this.v2 ? 2 : 3];
1021
+ }
1022
+ }, {
1023
+ key: "_getFormats",
1024
+ value: function(t) {
1025
+ return t[this.v1 ? 2 : this.v2 ? 3 : 4];
1026
+ }
1027
+ // For countries of the same region (e.g. NANPA)
1028
+ // formats are all stored in the "main" country for that region.
1029
+ // E.g. "RU" and "KZ", "US" and "CA".
1030
+ }, {
1031
+ key: "formats",
1032
+ value: function() {
1033
+ var t = this, r = this._getFormats(this.metadata) || this._getFormats(this.getDefaultCountryMetadataForRegion()) || [];
1034
+ return r.map(function(n) {
1035
+ return new s0(n, t);
1036
+ });
1037
+ }
1038
+ }, {
1039
+ key: "nationalPrefix",
1040
+ value: function() {
1041
+ return this.metadata[this.v1 ? 3 : this.v2 ? 4 : 5];
1042
+ }
1043
+ }, {
1044
+ key: "_getNationalPrefixFormattingRule",
1045
+ value: function(t) {
1046
+ return t[this.v1 ? 4 : this.v2 ? 5 : 6];
1047
+ }
1048
+ // For countries of the same region (e.g. NANPA)
1049
+ // national prefix formatting rule is stored in the "main" country for that region.
1050
+ // E.g. "RU" and "KZ", "US" and "CA".
1051
+ }, {
1052
+ key: "nationalPrefixFormattingRule",
1053
+ value: function() {
1054
+ return this._getNationalPrefixFormattingRule(this.metadata) || this._getNationalPrefixFormattingRule(this.getDefaultCountryMetadataForRegion());
1055
+ }
1056
+ }, {
1057
+ key: "_nationalPrefixForParsing",
1058
+ value: function() {
1059
+ return this.metadata[this.v1 ? 5 : this.v2 ? 6 : 7];
1060
+ }
1061
+ }, {
1062
+ key: "nationalPrefixForParsing",
1063
+ value: function() {
1064
+ return this._nationalPrefixForParsing() || this.nationalPrefix();
1065
+ }
1066
+ }, {
1067
+ key: "nationalPrefixTransformRule",
1068
+ value: function() {
1069
+ return this.metadata[this.v1 ? 6 : this.v2 ? 7 : 8];
1070
+ }
1071
+ }, {
1072
+ key: "_getNationalPrefixIsOptionalWhenFormatting",
1073
+ value: function() {
1074
+ return !!this.metadata[this.v1 ? 7 : this.v2 ? 8 : 9];
1075
+ }
1076
+ // For countries of the same region (e.g. NANPA)
1077
+ // "national prefix is optional when formatting" flag is
1078
+ // stored in the "main" country for that region.
1079
+ // E.g. "RU" and "KZ", "US" and "CA".
1080
+ }, {
1081
+ key: "nationalPrefixIsOptionalWhenFormattingInNationalFormat",
1082
+ value: function() {
1083
+ return this._getNationalPrefixIsOptionalWhenFormatting(this.metadata) || this._getNationalPrefixIsOptionalWhenFormatting(this.getDefaultCountryMetadataForRegion());
1084
+ }
1085
+ }, {
1086
+ key: "leadingDigits",
1087
+ value: function() {
1088
+ return this.metadata[this.v1 ? 8 : this.v2 ? 9 : 10];
1089
+ }
1090
+ }, {
1091
+ key: "types",
1092
+ value: function() {
1093
+ return this.metadata[this.v1 ? 9 : this.v2 ? 10 : 11];
1094
+ }
1095
+ }, {
1096
+ key: "hasTypes",
1097
+ value: function() {
1098
+ return this.types() && this.types().length === 0 ? !1 : !!this.types();
1099
+ }
1100
+ }, {
1101
+ key: "type",
1102
+ value: function(t) {
1103
+ if (this.hasTypes() && $d(this.types(), t))
1104
+ return new c0($d(this.types(), t), this);
1105
+ }
1106
+ }, {
1107
+ key: "ext",
1108
+ value: function() {
1109
+ return this.v1 || this.v2 ? od : this.metadata[13] || od;
1110
+ }
1111
+ }]), e;
1112
+ }(), s0 = /* @__PURE__ */ function() {
1113
+ function e(d, t) {
1114
+ ve(this, e), this._format = d, this.metadata = t;
1115
+ }
1116
+ return ge(e, [{
1117
+ key: "pattern",
1118
+ value: function() {
1119
+ return this._format[0];
1120
+ }
1121
+ }, {
1122
+ key: "format",
1123
+ value: function() {
1124
+ return this._format[1];
1125
+ }
1126
+ }, {
1127
+ key: "leadingDigitsPatterns",
1128
+ value: function() {
1129
+ return this._format[2] || [];
1130
+ }
1131
+ }, {
1132
+ key: "nationalPrefixFormattingRule",
1133
+ value: function() {
1134
+ return this._format[3] || this.metadata.nationalPrefixFormattingRule();
1135
+ }
1136
+ }, {
1137
+ key: "nationalPrefixIsOptionalWhenFormattingInNationalFormat",
1138
+ value: function() {
1139
+ return !!this._format[4] || this.metadata.nationalPrefixIsOptionalWhenFormattingInNationalFormat();
1140
+ }
1141
+ }, {
1142
+ key: "nationalPrefixIsMandatoryWhenFormattingInNationalFormat",
1143
+ value: function() {
1144
+ return this.usesNationalPrefix() && !this.nationalPrefixIsOptionalWhenFormattingInNationalFormat();
1145
+ }
1146
+ // Checks whether national prefix formatting rule contains national prefix.
1147
+ }, {
1148
+ key: "usesNationalPrefix",
1149
+ value: function() {
1150
+ return !!(this.nationalPrefixFormattingRule() && // Check that national prefix formatting rule is not a "dummy" one.
1151
+ !u0.test(this.nationalPrefixFormattingRule()));
1152
+ }
1153
+ }, {
1154
+ key: "internationalFormat",
1155
+ value: function() {
1156
+ return this._format[5] || this.format();
1157
+ }
1158
+ }]), e;
1159
+ }(), u0 = /^\(?\$1\)?$/, c0 = /* @__PURE__ */ function() {
1160
+ function e(d, t) {
1161
+ ve(this, e), this.type = d, this.metadata = t;
1162
+ }
1163
+ return ge(e, [{
1164
+ key: "pattern",
1165
+ value: function() {
1166
+ return this.metadata.v1 ? this.type : this.type[0];
1167
+ }
1168
+ }, {
1169
+ key: "possibleLengths",
1170
+ value: function() {
1171
+ if (!this.metadata.v1)
1172
+ return this.type[1] || this.metadata.possibleLengths();
1173
+ }
1174
+ }]), e;
1175
+ }();
1176
+ function $d(e, d) {
1177
+ switch (d) {
1178
+ case "FIXED_LINE":
1179
+ return e[0];
1180
+ case "MOBILE":
1181
+ return e[1];
1182
+ case "TOLL_FREE":
1183
+ return e[2];
1184
+ case "PREMIUM_RATE":
1185
+ return e[3];
1186
+ case "PERSONAL_NUMBER":
1187
+ return e[4];
1188
+ case "VOICEMAIL":
1189
+ return e[5];
1190
+ case "UAN":
1191
+ return e[6];
1192
+ case "PAGER":
1193
+ return e[7];
1194
+ case "VOIP":
1195
+ return e[8];
1196
+ case "SHARED_COST":
1197
+ return e[9];
1198
+ }
1199
+ }
1200
+ function f0(e) {
1201
+ if (!e)
1202
+ throw new Error("[libphonenumber-js] `metadata` argument not passed. Check your arguments.");
1203
+ if (!ce(e) || !ce(e.countries))
1204
+ throw new Error("[libphonenumber-js] `metadata` argument was passed but it's not a valid metadata. Must be an object having `.countries` child object property. Got ".concat(ce(e) ? "an object of shape: { " + Object.keys(e).join(", ") + " }" : "a " + p0(e) + ": " + e, "."));
1205
+ }
1206
+ var p0 = function(d) {
1207
+ return xe(d);
1208
+ };
1209
+ function Me(e, d) {
1210
+ if (d = new D(d), d.hasCountry(e))
1211
+ return d.country(e).countryCallingCode();
1212
+ throw new Error("Unknown country: ".concat(e));
1213
+ }
1214
+ function m0(e, d) {
1215
+ return d.countries.hasOwnProperty(e);
1216
+ }
1217
+ function Ld(e) {
1218
+ var d = e.version;
1219
+ typeof d == "number" ? (this.v1 = d === 1, this.v2 = d === 2, this.v3 = d === 3, this.v4 = d === 4) : d ? nd(d, $0) === -1 ? this.v2 = !0 : nd(d, i0) === -1 ? this.v3 = !0 : this.v4 = !0 : this.v1 = !0;
1220
+ }
1221
+ var y0 = ";ext=", q = function(d) {
1222
+ return "([".concat(G, "]{1,").concat(d, "})");
1223
+ };
1224
+ function kd(e) {
1225
+ var d = "20", t = "15", r = "9", n = "6", o = "[  \\t,]*", a = "[:\\..]?[  \\t,-]*", i = "#?", s = "(?:e?xt(?:ensi(?:ó?|ó))?n?|e?xtn?|доб|anexo)", u = "(?:[xx##~~]|int|int)", m = "[- ]+", c = "[  \\t]*", h = "(?:,{2}|;)", f = y0 + q(d), b = o + s + a + q(d) + i, E = o + u + a + q(r) + i, P = m + q(n) + "#", _ = c + h + a + q(t) + i, p = c + "(?:,)+" + a + q(r) + i;
1226
+ return f + "|" + b + "|" + E + "|" + P + "|" + _ + "|" + p;
1227
+ }
1228
+ var v0 = "[" + G + "]{" + Re + "}", g0 = "[" + Te + "]{0,1}(?:[" + fe + "]*[" + G + "]){3,}[" + fe + G + "]*", h0 = new RegExp("^[" + Te + "]{0,1}(?:[" + fe + "]*[" + G + "]){1,2}$", "i"), b0 = g0 + // Phone number extensions
1229
+ "(?:" + kd() + ")?", _0 = new RegExp(
1230
+ // Either a short two-digit-only phone number
1231
+ "^" + v0 + "$|^" + b0 + "$",
1232
+ "i"
1233
+ );
1234
+ function P0(e) {
1235
+ return e.length >= Re && _0.test(e);
1236
+ }
1237
+ function C0(e) {
1238
+ return h0.test(e);
1239
+ }
1240
+ var id = new RegExp("(?:" + kd() + ")$", "i");
1241
+ function N0(e) {
1242
+ var d = e.search(id);
1243
+ if (d < 0)
1244
+ return {};
1245
+ for (var t = e.slice(0, d), r = e.match(id), n = 1; n < r.length; ) {
1246
+ if (r[n])
1247
+ return {
1248
+ number: t,
1249
+ ext: r[n]
1250
+ };
1251
+ n++;
1252
+ }
1253
+ }
1254
+ var S0 = {
1255
+ 0: "0",
1256
+ 1: "1",
1257
+ 2: "2",
1258
+ 3: "3",
1259
+ 4: "4",
1260
+ 5: "5",
1261
+ 6: "6",
1262
+ 7: "7",
1263
+ 8: "8",
1264
+ 9: "9",
1265
+ "0": "0",
1266
+ // Fullwidth digit 0
1267
+ "1": "1",
1268
+ // Fullwidth digit 1
1269
+ "2": "2",
1270
+ // Fullwidth digit 2
1271
+ "3": "3",
1272
+ // Fullwidth digit 3
1273
+ "4": "4",
1274
+ // Fullwidth digit 4
1275
+ "5": "5",
1276
+ // Fullwidth digit 5
1277
+ "6": "6",
1278
+ // Fullwidth digit 6
1279
+ "7": "7",
1280
+ // Fullwidth digit 7
1281
+ "8": "8",
1282
+ // Fullwidth digit 8
1283
+ "9": "9",
1284
+ // Fullwidth digit 9
1285
+ "٠": "0",
1286
+ // Arabic-indic digit 0
1287
+ "١": "1",
1288
+ // Arabic-indic digit 1
1289
+ "٢": "2",
1290
+ // Arabic-indic digit 2
1291
+ "٣": "3",
1292
+ // Arabic-indic digit 3
1293
+ "٤": "4",
1294
+ // Arabic-indic digit 4
1295
+ "٥": "5",
1296
+ // Arabic-indic digit 5
1297
+ "٦": "6",
1298
+ // Arabic-indic digit 6
1299
+ "٧": "7",
1300
+ // Arabic-indic digit 7
1301
+ "٨": "8",
1302
+ // Arabic-indic digit 8
1303
+ "٩": "9",
1304
+ // Arabic-indic digit 9
1305
+ "۰": "0",
1306
+ // Eastern-Arabic digit 0
1307
+ "۱": "1",
1308
+ // Eastern-Arabic digit 1
1309
+ "۲": "2",
1310
+ // Eastern-Arabic digit 2
1311
+ "۳": "3",
1312
+ // Eastern-Arabic digit 3
1313
+ "۴": "4",
1314
+ // Eastern-Arabic digit 4
1315
+ "۵": "5",
1316
+ // Eastern-Arabic digit 5
1317
+ "۶": "6",
1318
+ // Eastern-Arabic digit 6
1319
+ "۷": "7",
1320
+ // Eastern-Arabic digit 7
1321
+ "۸": "8",
1322
+ // Eastern-Arabic digit 8
1323
+ "۹": "9"
1324
+ // Eastern-Arabic digit 9
1325
+ };
1326
+ function E0(e) {
1327
+ return S0[e];
1328
+ }
1329
+ function x0(e, d) {
1330
+ var t = typeof Symbol < "u" && e[Symbol.iterator] || e["@@iterator"];
1331
+ if (t) return (t = t.call(e)).next.bind(t);
1332
+ if (Array.isArray(e) || (t = I0(e)) || d) {
1333
+ t && (e = t);
1334
+ var r = 0;
1335
+ return function() {
1336
+ return r >= e.length ? { done: !0 } : { done: !1, value: e[r++] };
1337
+ };
1338
+ }
1339
+ throw new TypeError(`Invalid attempt to iterate non-iterable instance.
1340
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`);
1341
+ }
1342
+ function I0(e, d) {
1343
+ if (e) {
1344
+ if (typeof e == "string") return ld(e, d);
1345
+ var t = Object.prototype.toString.call(e).slice(8, -1);
1346
+ if (t === "Object" && e.constructor && (t = e.constructor.name), t === "Map" || t === "Set") return Array.from(e);
1347
+ if (t === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t)) return ld(e, d);
1348
+ }
1349
+ }
1350
+ function ld(e, d) {
1351
+ (d == null || d > e.length) && (d = e.length);
1352
+ for (var t = 0, r = new Array(d); t < d; t++)
1353
+ r[t] = e[t];
1354
+ return r;
1355
+ }
1356
+ function sd(e) {
1357
+ for (var d = "", t = x0(e.split("")), r; !(r = t()).done; ) {
1358
+ var n = r.value;
1359
+ d += F0(n, d) || "";
1360
+ }
1361
+ return d;
1362
+ }
1363
+ function F0(e, d, t) {
1364
+ return e === "+" ? d ? void 0 : "+" : E0(e);
1365
+ }
1366
+ function De(e, d) {
1367
+ return O0(e, void 0, d);
1368
+ }
1369
+ function O0(e, d, t) {
1370
+ var r = t.type(d), n = r && r.possibleLengths() || t.possibleLengths();
1371
+ if (!n)
1372
+ return "IS_POSSIBLE";
1373
+ var o = e.length, a = n[0];
1374
+ return a === o ? "IS_POSSIBLE" : a > o ? "TOO_SHORT" : n[n.length - 1] < o ? "TOO_LONG" : n.indexOf(o, 1) >= 0 ? "IS_POSSIBLE" : "INVALID_LENGTH";
1375
+ }
1376
+ function w0(e, d, t) {
1377
+ if (d === void 0 && (d = {}), t = new D(t), d.v2) {
1378
+ if (!e.countryCallingCode)
1379
+ throw new Error("Invalid phone number object passed");
1380
+ t.selectNumberingPlan(e.countryCallingCode);
1381
+ } else {
1382
+ if (!e.phone)
1383
+ return !1;
1384
+ if (e.country) {
1385
+ if (!t.hasCountry(e.country))
1386
+ throw new Error("Unknown country: ".concat(e.country));
1387
+ t.country(e.country);
1388
+ } else {
1389
+ if (!e.countryCallingCode)
1390
+ throw new Error("Invalid phone number object passed");
1391
+ t.selectNumberingPlan(e.countryCallingCode);
1392
+ }
1393
+ }
1394
+ if (t.possibleLengths())
1395
+ return Vd(e.phone || e.nationalNumber, t);
1396
+ if (e.countryCallingCode && t.isNonGeographicCallingCode(e.countryCallingCode))
1397
+ return !0;
1398
+ throw new Error('Missing "possibleLengths" in metadata. Perhaps the metadata has been generated before v1.0.18.');
1399
+ }
1400
+ function Vd(e, d) {
1401
+ switch (De(e, d)) {
1402
+ case "IS_POSSIBLE":
1403
+ return !0;
1404
+ default:
1405
+ return !1;
1406
+ }
1407
+ }
1408
+ function W(e, d) {
1409
+ return e = e || "", new RegExp("^(?:" + d + ")$").test(e);
1410
+ }
1411
+ function A0(e, d) {
1412
+ var t = typeof Symbol < "u" && e[Symbol.iterator] || e["@@iterator"];
1413
+ if (t) return (t = t.call(e)).next.bind(t);
1414
+ if (Array.isArray(e) || (t = R0(e)) || d) {
1415
+ t && (e = t);
1416
+ var r = 0;
1417
+ return function() {
1418
+ return r >= e.length ? { done: !0 } : { done: !1, value: e[r++] };
1419
+ };
1420
+ }
1421
+ throw new TypeError(`Invalid attempt to iterate non-iterable instance.
1422
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`);
1423
+ }
1424
+ function R0(e, d) {
1425
+ if (e) {
1426
+ if (typeof e == "string") return ud(e, d);
1427
+ var t = Object.prototype.toString.call(e).slice(8, -1);
1428
+ if (t === "Object" && e.constructor && (t = e.constructor.name), t === "Map" || t === "Set") return Array.from(e);
1429
+ if (t === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t)) return ud(e, d);
1430
+ }
1431
+ }
1432
+ function ud(e, d) {
1433
+ (d == null || d > e.length) && (d = e.length);
1434
+ for (var t = 0, r = new Array(d); t < d; t++)
1435
+ r[t] = e[t];
1436
+ return r;
1437
+ }
1438
+ var T0 = ["MOBILE", "PREMIUM_RATE", "TOLL_FREE", "SHARED_COST", "VOIP", "PERSONAL_NUMBER", "PAGER", "UAN", "VOICEMAIL"];
1439
+ function Le(e, d, t) {
1440
+ if (d = d || {}, !(!e.country && !e.countryCallingCode)) {
1441
+ t = new D(t), t.selectNumberingPlan(e.country, e.countryCallingCode);
1442
+ var r = d.v2 ? e.nationalNumber : e.phone;
1443
+ if (W(r, t.nationalNumberPattern())) {
1444
+ if (Pe(r, "FIXED_LINE", t))
1445
+ return t.type("MOBILE") && t.type("MOBILE").pattern() === "" || !t.type("MOBILE") || Pe(r, "MOBILE", t) ? "FIXED_LINE_OR_MOBILE" : "FIXED_LINE";
1446
+ for (var n = A0(T0), o; !(o = n()).done; ) {
1447
+ var a = o.value;
1448
+ if (Pe(r, a, t))
1449
+ return a;
1450
+ }
1451
+ }
1452
+ }
1453
+ }
1454
+ function Pe(e, d, t) {
1455
+ return d = t.type(d), !d || !d.pattern() || d.possibleLengths() && d.possibleLengths().indexOf(e.length) < 0 ? !1 : W(e, d.pattern());
1456
+ }
1457
+ function M0(e, d, t) {
1458
+ if (d = d || {}, t = new D(t), t.selectNumberingPlan(e.country, e.countryCallingCode), t.hasTypes())
1459
+ return Le(e, d, t.metadata) !== void 0;
1460
+ var r = d.v2 ? e.nationalNumber : e.phone;
1461
+ return W(r, t.nationalNumberPattern());
1462
+ }
1463
+ function D0(e, d, t) {
1464
+ var r = new D(t), n = r.getCountryCodesForCallingCode(e);
1465
+ return n ? n.filter(function(o) {
1466
+ return L0(d, o, t);
1467
+ }) : [];
1468
+ }
1469
+ function L0(e, d, t) {
1470
+ var r = new D(t);
1471
+ return r.selectNumberingPlan(d), r.numberingPlan.possibleLengths().indexOf(e.length) >= 0;
1472
+ }
1473
+ function k0(e) {
1474
+ return e.replace(new RegExp("[".concat(fe, "]+"), "g"), " ").trim();
1475
+ }
1476
+ var V0 = /(\$\d)/;
1477
+ function U0(e, d, t) {
1478
+ var r = t.useInternationalFormat, n = t.withNationalPrefix, o = e.replace(new RegExp(d.pattern()), r ? d.internationalFormat() : (
1479
+ // This library doesn't use `domestic_carrier_code_formatting_rule`,
1480
+ // because that one is only used when formatting phone numbers
1481
+ // for dialing from a mobile phone, and this is not a dialing library.
1482
+ // carrierCode && format.domesticCarrierCodeFormattingRule()
1483
+ // // First, replace the $CC in the formatting rule with the desired carrier code.
1484
+ // // Then, replace the $FG in the formatting rule with the first group
1485
+ // // and the carrier code combined in the appropriate way.
1486
+ // ? format.format().replace(FIRST_GROUP_PATTERN, format.domesticCarrierCodeFormattingRule().replace('$CC', carrierCode))
1487
+ // : (
1488
+ // withNationalPrefix && format.nationalPrefixFormattingRule()
1489
+ // ? format.format().replace(FIRST_GROUP_PATTERN, format.nationalPrefixFormattingRule())
1490
+ // : format.format()
1491
+ // )
1492
+ n && d.nationalPrefixFormattingRule() ? d.format().replace(V0, d.nationalPrefixFormattingRule()) : d.format()
1493
+ ));
1494
+ return r ? k0(o) : o;
1495
+ }
1496
+ var B0 = /^[\d]+(?:[~\u2053\u223C\uFF5E][\d]+)?$/;
1497
+ function G0(e, d, t) {
1498
+ var r = new D(t);
1499
+ if (r.selectNumberingPlan(e, d), r.defaultIDDPrefix())
1500
+ return r.defaultIDDPrefix();
1501
+ if (B0.test(r.IDDPrefix()))
1502
+ return r.IDDPrefix();
1503
+ }
1504
+ function H0(e) {
1505
+ var d = e.number, t = e.ext;
1506
+ if (!d)
1507
+ return "";
1508
+ if (d[0] !== "+")
1509
+ throw new Error('"formatRFC3966()" expects "number" to be in E.164 format.');
1510
+ return "tel:".concat(d).concat(t ? ";ext=" + t : "");
1511
+ }
1512
+ function j0(e, d) {
1513
+ var t = typeof Symbol < "u" && e[Symbol.iterator] || e["@@iterator"];
1514
+ if (t) return (t = t.call(e)).next.bind(t);
1515
+ if (Array.isArray(e) || (t = K0(e)) || d) {
1516
+ t && (e = t);
1517
+ var r = 0;
1518
+ return function() {
1519
+ return r >= e.length ? { done: !0 } : { done: !1, value: e[r++] };
1520
+ };
1521
+ }
1522
+ throw new TypeError(`Invalid attempt to iterate non-iterable instance.
1523
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`);
1524
+ }
1525
+ function K0(e, d) {
1526
+ if (e) {
1527
+ if (typeof e == "string") return cd(e, d);
1528
+ var t = Object.prototype.toString.call(e).slice(8, -1);
1529
+ if (t === "Object" && e.constructor && (t = e.constructor.name), t === "Map" || t === "Set") return Array.from(e);
1530
+ if (t === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t)) return cd(e, d);
1531
+ }
1532
+ }
1533
+ function cd(e, d) {
1534
+ (d == null || d > e.length) && (d = e.length);
1535
+ for (var t = 0, r = new Array(d); t < d; t++)
1536
+ r[t] = e[t];
1537
+ return r;
1538
+ }
1539
+ function fd(e, d) {
1540
+ var t = Object.keys(e);
1541
+ if (Object.getOwnPropertySymbols) {
1542
+ var r = Object.getOwnPropertySymbols(e);
1543
+ d && (r = r.filter(function(n) {
1544
+ return Object.getOwnPropertyDescriptor(e, n).enumerable;
1545
+ })), t.push.apply(t, r);
1546
+ }
1547
+ return t;
1548
+ }
1549
+ function pd(e) {
1550
+ for (var d = 1; d < arguments.length; d++) {
1551
+ var t = arguments[d] != null ? arguments[d] : {};
1552
+ d % 2 ? fd(Object(t), !0).forEach(function(r) {
1553
+ W0(e, r, t[r]);
1554
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : fd(Object(t)).forEach(function(r) {
1555
+ Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r));
1556
+ });
1557
+ }
1558
+ return e;
1559
+ }
1560
+ function W0(e, d, t) {
1561
+ return d in e ? Object.defineProperty(e, d, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[d] = t, e;
1562
+ }
1563
+ var md = {
1564
+ formatExtension: function(d, t, r) {
1565
+ return "".concat(d).concat(r.ext()).concat(t);
1566
+ }
1567
+ };
1568
+ function Y0(e, d, t, r) {
1569
+ if (t ? t = pd(pd({}, md), t) : t = md, r = new D(r), e.country && e.country !== "001") {
1570
+ if (!r.hasCountry(e.country))
1571
+ throw new Error("Unknown country: ".concat(e.country));
1572
+ r.country(e.country);
1573
+ } else if (e.countryCallingCode)
1574
+ r.selectNumberingPlan(e.countryCallingCode);
1575
+ else return e.phone || "";
1576
+ var n = r.countryCallingCode(), o = t.v2 ? e.nationalNumber : e.phone, a;
1577
+ switch (d) {
1578
+ case "NATIONAL":
1579
+ return o ? (a = pe(o, e.carrierCode, "NATIONAL", r, t), Ce(a, e.ext, r, t.formatExtension)) : "";
1580
+ case "INTERNATIONAL":
1581
+ return o ? (a = pe(o, null, "INTERNATIONAL", r, t), a = "+".concat(n, " ").concat(a), Ce(a, e.ext, r, t.formatExtension)) : "+".concat(n);
1582
+ case "E.164":
1583
+ return "+".concat(n).concat(o);
1584
+ case "RFC3966":
1585
+ return H0({
1586
+ number: "+".concat(n).concat(o),
1587
+ ext: e.ext
1588
+ });
1589
+ case "IDD":
1590
+ if (!t.fromCountry)
1591
+ return;
1592
+ var i = Z0(o, e.carrierCode, n, t.fromCountry, r);
1593
+ return Ce(i, e.ext, r, t.formatExtension);
1594
+ default:
1595
+ throw new Error('Unknown "format" argument passed to "formatNumber()": "'.concat(d, '"'));
1596
+ }
1597
+ }
1598
+ function pe(e, d, t, r, n) {
1599
+ var o = X0(r.formats(), e);
1600
+ return o ? U0(e, o, {
1601
+ useInternationalFormat: t === "INTERNATIONAL",
1602
+ withNationalPrefix: !(o.nationalPrefixIsOptionalWhenFormattingInNationalFormat() && n && n.nationalPrefix === !1),
1603
+ carrierCode: d,
1604
+ metadata: r
1605
+ }) : e;
1606
+ }
1607
+ function X0(e, d) {
1608
+ for (var t = j0(e), r; !(r = t()).done; ) {
1609
+ var n = r.value;
1610
+ if (n.leadingDigitsPatterns().length > 0) {
1611
+ var o = n.leadingDigitsPatterns()[n.leadingDigitsPatterns().length - 1];
1612
+ if (d.search(o) !== 0)
1613
+ continue;
1614
+ }
1615
+ if (W(d, n.pattern()))
1616
+ return n;
1617
+ }
1618
+ }
1619
+ function Ce(e, d, t, r) {
1620
+ return d ? r(e, d, t) : e;
1621
+ }
1622
+ function Z0(e, d, t, r, n) {
1623
+ var o = Me(r, n.metadata);
1624
+ if (o === t) {
1625
+ var a = pe(e, d, "NATIONAL", n);
1626
+ return t === "1" ? t + " " + a : a;
1627
+ }
1628
+ var i = G0(r, void 0, n.metadata);
1629
+ if (i)
1630
+ return "".concat(i, " ").concat(t, " ").concat(pe(e, null, "INTERNATIONAL", n));
1631
+ }
1632
+ function yd(e, d) {
1633
+ var t = Object.keys(e);
1634
+ if (Object.getOwnPropertySymbols) {
1635
+ var r = Object.getOwnPropertySymbols(e);
1636
+ d && (r = r.filter(function(n) {
1637
+ return Object.getOwnPropertyDescriptor(e, n).enumerable;
1638
+ })), t.push.apply(t, r);
1639
+ }
1640
+ return t;
1641
+ }
1642
+ function vd(e) {
1643
+ for (var d = 1; d < arguments.length; d++) {
1644
+ var t = arguments[d] != null ? arguments[d] : {};
1645
+ d % 2 ? yd(Object(t), !0).forEach(function(r) {
1646
+ q0(e, r, t[r]);
1647
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : yd(Object(t)).forEach(function(r) {
1648
+ Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r));
1649
+ });
1650
+ }
1651
+ return e;
1652
+ }
1653
+ function q0(e, d, t) {
1654
+ return d in e ? Object.defineProperty(e, d, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[d] = t, e;
1655
+ }
1656
+ function z0(e, d) {
1657
+ if (!(e instanceof d))
1658
+ throw new TypeError("Cannot call a class as a function");
1659
+ }
1660
+ function J0(e, d) {
1661
+ for (var t = 0; t < d.length; t++) {
1662
+ var r = d[t];
1663
+ r.enumerable = r.enumerable || !1, r.configurable = !0, "value" in r && (r.writable = !0), Object.defineProperty(e, r.key, r);
1664
+ }
1665
+ }
1666
+ function Q0(e, d, t) {
1667
+ return d && J0(e.prototype, d), Object.defineProperty(e, "prototype", { writable: !1 }), e;
1668
+ }
1669
+ var e1 = /* @__PURE__ */ function() {
1670
+ function e(d, t, r) {
1671
+ if (z0(this, e), !d)
1672
+ throw new TypeError("`country` or `countryCallingCode` not passed");
1673
+ if (!t)
1674
+ throw new TypeError("`nationalNumber` not passed");
1675
+ if (!r)
1676
+ throw new TypeError("`metadata` not passed");
1677
+ var n = t1(d, r), o = n.country, a = n.countryCallingCode;
1678
+ this.country = o, this.countryCallingCode = a, this.nationalNumber = t, this.number = "+" + this.countryCallingCode + this.nationalNumber, this.getMetadata = function() {
1679
+ return r;
1680
+ };
1681
+ }
1682
+ return Q0(e, [{
1683
+ key: "setExt",
1684
+ value: function(t) {
1685
+ this.ext = t;
1686
+ }
1687
+ }, {
1688
+ key: "getPossibleCountries",
1689
+ value: function() {
1690
+ return this.country ? [this.country] : D0(this.countryCallingCode, this.nationalNumber, this.getMetadata());
1691
+ }
1692
+ }, {
1693
+ key: "isPossible",
1694
+ value: function() {
1695
+ return w0(this, {
1696
+ v2: !0
1697
+ }, this.getMetadata());
1698
+ }
1699
+ }, {
1700
+ key: "isValid",
1701
+ value: function() {
1702
+ return M0(this, {
1703
+ v2: !0
1704
+ }, this.getMetadata());
1705
+ }
1706
+ }, {
1707
+ key: "isNonGeographic",
1708
+ value: function() {
1709
+ var t = new D(this.getMetadata());
1710
+ return t.isNonGeographicCallingCode(this.countryCallingCode);
1711
+ }
1712
+ }, {
1713
+ key: "isEqual",
1714
+ value: function(t) {
1715
+ return this.number === t.number && this.ext === t.ext;
1716
+ }
1717
+ // This function was originally meant to be an equivalent for `validatePhoneNumberLength()`,
1718
+ // but later it was found out that it doesn't include the possible `TOO_SHORT` result
1719
+ // returned from `parsePhoneNumberWithError()` in the original `validatePhoneNumberLength()`,
1720
+ // so eventually I simply commented out this method from the `PhoneNumber` class
1721
+ // and just left the `validatePhoneNumberLength()` function, even though that one would require
1722
+ // and additional step to also validate the actual country / calling code of the phone number.
1723
+ // validateLength() {
1724
+ // const metadata = new Metadata(this.getMetadata())
1725
+ // metadata.selectNumberingPlan(this.countryCallingCode)
1726
+ // const result = checkNumberLength(this.nationalNumber, metadata)
1727
+ // if (result !== 'IS_POSSIBLE') {
1728
+ // return result
1729
+ // }
1730
+ // }
1731
+ }, {
1732
+ key: "getType",
1733
+ value: function() {
1734
+ return Le(this, {
1735
+ v2: !0
1736
+ }, this.getMetadata());
1737
+ }
1738
+ }, {
1739
+ key: "format",
1740
+ value: function(t, r) {
1741
+ return Y0(this, t, r ? vd(vd({}, r), {}, {
1742
+ v2: !0
1743
+ }) : {
1744
+ v2: !0
1745
+ }, this.getMetadata());
1746
+ }
1747
+ }, {
1748
+ key: "formatNational",
1749
+ value: function(t) {
1750
+ return this.format("NATIONAL", t);
1751
+ }
1752
+ }, {
1753
+ key: "formatInternational",
1754
+ value: function(t) {
1755
+ return this.format("INTERNATIONAL", t);
1756
+ }
1757
+ }, {
1758
+ key: "getURI",
1759
+ value: function(t) {
1760
+ return this.format("RFC3966", t);
1761
+ }
1762
+ }]), e;
1763
+ }(), d1 = function(d) {
1764
+ return /^[A-Z]{2}$/.test(d);
1765
+ };
1766
+ function t1(e, d) {
1767
+ var t, r, n = new D(d);
1768
+ return d1(e) ? (t = e, n.selectNumberingPlan(t), r = n.countryCallingCode()) : r = e, {
1769
+ country: t,
1770
+ countryCallingCode: r
1771
+ };
1772
+ }
1773
+ var r1 = new RegExp("([" + G + "])");
1774
+ function n1(e, d, t, r) {
1775
+ if (d) {
1776
+ var n = new D(r);
1777
+ n.selectNumberingPlan(d, t);
1778
+ var o = new RegExp(n.IDDPrefix());
1779
+ if (e.search(o) === 0) {
1780
+ e = e.slice(e.match(o)[0].length);
1781
+ var a = e.match(r1);
1782
+ if (!(a && a[1] != null && a[1].length > 0 && a[1] === "0"))
1783
+ return e;
1784
+ }
1785
+ }
1786
+ }
1787
+ function o1(e, d) {
1788
+ if (e && d.numberingPlan.nationalPrefixForParsing()) {
1789
+ var t = new RegExp("^(?:" + d.numberingPlan.nationalPrefixForParsing() + ")"), r = t.exec(e);
1790
+ if (r) {
1791
+ var n, o, a = r.length - 1, i = a > 0 && r[a];
1792
+ if (d.nationalPrefixTransformRule() && i)
1793
+ n = e.replace(t, d.nationalPrefixTransformRule()), a > 1 && (o = r[1]);
1794
+ else {
1795
+ var s = r[0];
1796
+ n = e.slice(s.length), i && (o = r[1]);
1797
+ }
1798
+ var u;
1799
+ if (i) {
1800
+ var m = e.indexOf(r[1]), c = e.slice(0, m);
1801
+ c === d.numberingPlan.nationalPrefix() && (u = d.numberingPlan.nationalPrefix());
1802
+ } else
1803
+ u = r[0];
1804
+ return {
1805
+ nationalNumber: n,
1806
+ nationalPrefix: u,
1807
+ carrierCode: o
1808
+ };
1809
+ }
1810
+ }
1811
+ return {
1812
+ nationalNumber: e
1813
+ };
1814
+ }
1815
+ function Ie(e, d) {
1816
+ var t = o1(e, d), r = t.carrierCode, n = t.nationalNumber;
1817
+ if (n !== e) {
1818
+ if (!a1(e, n, d))
1819
+ return {
1820
+ nationalNumber: e
1821
+ };
1822
+ if (d.possibleLengths() && !$1(n, d))
1823
+ return {
1824
+ nationalNumber: e
1825
+ };
1826
+ }
1827
+ return {
1828
+ nationalNumber: n,
1829
+ carrierCode: r
1830
+ };
1831
+ }
1832
+ function a1(e, d, t) {
1833
+ return !(W(e, t.nationalNumberPattern()) && !W(d, t.nationalNumberPattern()));
1834
+ }
1835
+ function $1(e, d) {
1836
+ switch (De(e, d)) {
1837
+ case "TOO_SHORT":
1838
+ case "INVALID_LENGTH":
1839
+ return !1;
1840
+ default:
1841
+ return !0;
1842
+ }
1843
+ }
1844
+ function i1(e, d, t, r) {
1845
+ var n = d ? Me(d, r) : t;
1846
+ if (e.indexOf(n) === 0) {
1847
+ r = new D(r), r.selectNumberingPlan(d, t);
1848
+ var o = e.slice(n.length), a = Ie(o, r), i = a.nationalNumber, s = Ie(e, r), u = s.nationalNumber;
1849
+ if (!W(u, r.nationalNumberPattern()) && W(i, r.nationalNumberPattern()) || De(u, r) === "TOO_LONG")
1850
+ return {
1851
+ countryCallingCode: n,
1852
+ number: o
1853
+ };
1854
+ }
1855
+ return {
1856
+ number: e
1857
+ };
1858
+ }
1859
+ function l1(e, d, t, r) {
1860
+ if (!e)
1861
+ return {};
1862
+ var n;
1863
+ if (e[0] !== "+") {
1864
+ var o = n1(e, d, t, r);
1865
+ if (o && o !== e)
1866
+ n = !0, e = "+" + o;
1867
+ else {
1868
+ if (d || t) {
1869
+ var a = i1(e, d, t, r), i = a.countryCallingCode, s = a.number;
1870
+ if (i)
1871
+ return {
1872
+ countryCallingCodeSource: "FROM_NUMBER_WITHOUT_PLUS_SIGN",
1873
+ countryCallingCode: i,
1874
+ number: s
1875
+ };
1876
+ }
1877
+ return {
1878
+ // No need to set it to `UNSPECIFIED`. It can be just `undefined`.
1879
+ // countryCallingCodeSource: 'UNSPECIFIED',
1880
+ number: e
1881
+ };
1882
+ }
1883
+ }
1884
+ if (e[1] === "0")
1885
+ return {};
1886
+ r = new D(r);
1887
+ for (var u = 2; u - 1 <= Jt && u <= e.length; ) {
1888
+ var m = e.slice(1, u);
1889
+ if (r.hasCallingCode(m))
1890
+ return r.selectNumberingPlan(m), {
1891
+ countryCallingCodeSource: n ? "FROM_NUMBER_WITH_IDD" : "FROM_NUMBER_WITH_PLUS_SIGN",
1892
+ countryCallingCode: m,
1893
+ number: e.slice(u)
1894
+ };
1895
+ u++;
1896
+ }
1897
+ return {};
1898
+ }
1899
+ function s1(e, d) {
1900
+ var t = typeof Symbol < "u" && e[Symbol.iterator] || e["@@iterator"];
1901
+ if (t) return (t = t.call(e)).next.bind(t);
1902
+ if (Array.isArray(e) || (t = u1(e)) || d) {
1903
+ t && (e = t);
1904
+ var r = 0;
1905
+ return function() {
1906
+ return r >= e.length ? { done: !0 } : { done: !1, value: e[r++] };
1907
+ };
1908
+ }
1909
+ throw new TypeError(`Invalid attempt to iterate non-iterable instance.
1910
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`);
1911
+ }
1912
+ function u1(e, d) {
1913
+ if (e) {
1914
+ if (typeof e == "string") return gd(e, d);
1915
+ var t = Object.prototype.toString.call(e).slice(8, -1);
1916
+ if (t === "Object" && e.constructor && (t = e.constructor.name), t === "Map" || t === "Set") return Array.from(e);
1917
+ if (t === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t)) return gd(e, d);
1918
+ }
1919
+ }
1920
+ function gd(e, d) {
1921
+ (d == null || d > e.length) && (d = e.length);
1922
+ for (var t = 0, r = new Array(d); t < d; t++)
1923
+ r[t] = e[t];
1924
+ return r;
1925
+ }
1926
+ function c1(e, d) {
1927
+ var t = d.countries, r = d.metadata;
1928
+ r = new D(r);
1929
+ for (var n = s1(t), o; !(o = n()).done; ) {
1930
+ var a = o.value;
1931
+ if (r.country(a), r.leadingDigits()) {
1932
+ if (e && e.search(r.leadingDigits()) === 0)
1933
+ return a;
1934
+ } else if (Le({
1935
+ phone: e,
1936
+ country: a
1937
+ }, void 0, r.metadata))
1938
+ return a;
1939
+ }
1940
+ }
1941
+ function f1(e, d) {
1942
+ var t = d.nationalNumber, r = d.defaultCountry, n = d.metadata, o = n.getCountryCodesForCallingCode(e);
1943
+ if (o)
1944
+ return o.length === 1 ? o[0] : c1(t, {
1945
+ countries: o,
1946
+ defaultCountry: r,
1947
+ metadata: n.metadata
1948
+ });
1949
+ }
1950
+ var Ud = "+", p1 = "[\\-\\.\\(\\)]?", hd = "([" + G + "]|" + p1 + ")", m1 = "^\\" + Ud + hd + "*[" + G + "]" + hd + "*$", y1 = new RegExp(m1, "g"), Fe = G, v1 = "[" + Fe + "]+((\\-)*[" + Fe + "])*", g1 = "a-zA-Z", h1 = "[" + g1 + "]+((\\-)*[" + Fe + "])*", b1 = "^(" + v1 + "\\.)*" + h1 + "\\.?$", _1 = new RegExp(b1, "g"), bd = "tel:", Oe = ";phone-context=", P1 = ";isub=";
1951
+ function C1(e) {
1952
+ var d = e.indexOf(Oe);
1953
+ if (d < 0)
1954
+ return null;
1955
+ var t = d + Oe.length;
1956
+ if (t >= e.length)
1957
+ return "";
1958
+ var r = e.indexOf(";", t);
1959
+ return r >= 0 ? e.substring(t, r) : e.substring(t);
1960
+ }
1961
+ function N1(e) {
1962
+ return e === null ? !0 : e.length === 0 ? !1 : y1.test(e) || _1.test(e);
1963
+ }
1964
+ function S1(e, d) {
1965
+ var t = d.extractFormattedPhoneNumber, r = C1(e);
1966
+ if (!N1(r))
1967
+ throw new j("NOT_A_NUMBER");
1968
+ var n;
1969
+ if (r === null)
1970
+ n = t(e) || "";
1971
+ else {
1972
+ n = "", r.charAt(0) === Ud && (n += r);
1973
+ var o = e.indexOf(bd), a;
1974
+ o >= 0 ? a = o + bd.length : a = 0;
1975
+ var i = e.indexOf(Oe);
1976
+ n += e.substring(a, i);
1977
+ }
1978
+ var s = n.indexOf(P1);
1979
+ if (s > 0 && (n = n.substring(0, s)), n !== "")
1980
+ return n;
1981
+ }
1982
+ var E1 = 250, x1 = new RegExp("[" + Te + G + "]"), I1 = new RegExp("[^" + G + "#]+$");
1983
+ function F1(e, d, t) {
1984
+ if (d = d || {}, t = new D(t), d.defaultCountry && !t.hasCountry(d.defaultCountry))
1985
+ throw d.v2 ? new j("INVALID_COUNTRY") : new Error("Unknown country: ".concat(d.defaultCountry));
1986
+ var r = w1(e, d.v2, d.extract), n = r.number, o = r.ext, a = r.error;
1987
+ if (!n) {
1988
+ if (d.v2)
1989
+ throw a === "TOO_SHORT" ? new j("TOO_SHORT") : new j("NOT_A_NUMBER");
1990
+ return {};
1991
+ }
1992
+ var i = R1(n, d.defaultCountry, d.defaultCallingCode, t), s = i.country, u = i.nationalNumber, m = i.countryCallingCode, c = i.countryCallingCodeSource, h = i.carrierCode;
1993
+ if (!t.hasSelectedNumberingPlan()) {
1994
+ if (d.v2)
1995
+ throw new j("INVALID_COUNTRY");
1996
+ return {};
1997
+ }
1998
+ if (!u || u.length < Re) {
1999
+ if (d.v2)
2000
+ throw new j("TOO_SHORT");
2001
+ return {};
2002
+ }
2003
+ if (u.length > zt) {
2004
+ if (d.v2)
2005
+ throw new j("TOO_LONG");
2006
+ return {};
2007
+ }
2008
+ if (d.v2) {
2009
+ var f = new e1(m, u, t.metadata);
2010
+ return s && (f.country = s), h && (f.carrierCode = h), o && (f.ext = o), f.__countryCallingCodeSource = c, f;
2011
+ }
2012
+ var b = (d.extended ? t.hasSelectedNumberingPlan() : s) ? W(u, t.nationalNumberPattern()) : !1;
2013
+ return d.extended ? {
2014
+ country: s,
2015
+ countryCallingCode: m,
2016
+ carrierCode: h,
2017
+ valid: b,
2018
+ possible: b ? !0 : !!(d.extended === !0 && t.possibleLengths() && Vd(u, t)),
2019
+ phone: u,
2020
+ ext: o
2021
+ } : b ? A1(s, u, o) : {};
2022
+ }
2023
+ function O1(e, d, t) {
2024
+ if (e) {
2025
+ if (e.length > E1) {
2026
+ if (t)
2027
+ throw new j("TOO_LONG");
2028
+ return;
2029
+ }
2030
+ if (d === !1)
2031
+ return e;
2032
+ var r = e.search(x1);
2033
+ if (!(r < 0))
2034
+ return e.slice(r).replace(I1, "");
2035
+ }
2036
+ }
2037
+ function w1(e, d, t) {
2038
+ var r = S1(e, {
2039
+ extractFormattedPhoneNumber: function(a) {
2040
+ return O1(a, t, d);
2041
+ }
2042
+ });
2043
+ if (!r)
2044
+ return {};
2045
+ if (!P0(r))
2046
+ return C0(r) ? {
2047
+ error: "TOO_SHORT"
2048
+ } : {};
2049
+ var n = N0(r);
2050
+ return n.ext ? n : {
2051
+ number: r
2052
+ };
2053
+ }
2054
+ function A1(e, d, t) {
2055
+ var r = {
2056
+ country: e,
2057
+ phone: d
2058
+ };
2059
+ return t && (r.ext = t), r;
2060
+ }
2061
+ function R1(e, d, t, r) {
2062
+ var n = l1(sd(e), d, t, r.metadata), o = n.countryCallingCodeSource, a = n.countryCallingCode, i = n.number, s;
2063
+ if (a)
2064
+ r.selectNumberingPlan(a);
2065
+ else if (i && (d || t))
2066
+ r.selectNumberingPlan(d, t), d && (s = d), a = t || Me(d, r.metadata);
2067
+ else return {};
2068
+ if (!i)
2069
+ return {
2070
+ countryCallingCodeSource: o,
2071
+ countryCallingCode: a
2072
+ };
2073
+ var u = Ie(sd(i), r), m = u.nationalNumber, c = u.carrierCode, h = f1(a, {
2074
+ nationalNumber: m,
2075
+ defaultCountry: d,
2076
+ metadata: r
2077
+ });
2078
+ return h && (s = h, h === "001" || r.country(s)), {
2079
+ country: s,
2080
+ countryCallingCode: a,
2081
+ countryCallingCodeSource: o,
2082
+ nationalNumber: m,
2083
+ carrierCode: c
2084
+ };
2085
+ }
2086
+ function _d(e, d) {
2087
+ var t = Object.keys(e);
2088
+ if (Object.getOwnPropertySymbols) {
2089
+ var r = Object.getOwnPropertySymbols(e);
2090
+ d && (r = r.filter(function(n) {
2091
+ return Object.getOwnPropertyDescriptor(e, n).enumerable;
2092
+ })), t.push.apply(t, r);
2093
+ }
2094
+ return t;
2095
+ }
2096
+ function Pd(e) {
2097
+ for (var d = 1; d < arguments.length; d++) {
2098
+ var t = arguments[d] != null ? arguments[d] : {};
2099
+ d % 2 ? _d(Object(t), !0).forEach(function(r) {
2100
+ T1(e, r, t[r]);
2101
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : _d(Object(t)).forEach(function(r) {
2102
+ Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r));
2103
+ });
2104
+ }
2105
+ return e;
2106
+ }
2107
+ function T1(e, d, t) {
2108
+ return d in e ? Object.defineProperty(e, d, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[d] = t, e;
2109
+ }
2110
+ function M1(e, d, t) {
2111
+ return F1(e, Pd(Pd({}, d), {}, {
2112
+ v2: !0
2113
+ }), t);
2114
+ }
2115
+ function Cd(e, d) {
2116
+ var t = Object.keys(e);
2117
+ if (Object.getOwnPropertySymbols) {
2118
+ var r = Object.getOwnPropertySymbols(e);
2119
+ d && (r = r.filter(function(n) {
2120
+ return Object.getOwnPropertyDescriptor(e, n).enumerable;
2121
+ })), t.push.apply(t, r);
2122
+ }
2123
+ return t;
2124
+ }
2125
+ function D1(e) {
2126
+ for (var d = 1; d < arguments.length; d++) {
2127
+ var t = arguments[d] != null ? arguments[d] : {};
2128
+ d % 2 ? Cd(Object(t), !0).forEach(function(r) {
2129
+ L1(e, r, t[r]);
2130
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : Cd(Object(t)).forEach(function(r) {
2131
+ Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r));
2132
+ });
2133
+ }
2134
+ return e;
2135
+ }
2136
+ function L1(e, d, t) {
2137
+ return d in e ? Object.defineProperty(e, d, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[d] = t, e;
2138
+ }
2139
+ function k1(e, d) {
2140
+ return G1(e) || B1(e, d) || U1(e, d) || V1();
2141
+ }
2142
+ function V1() {
2143
+ throw new TypeError(`Invalid attempt to destructure non-iterable instance.
2144
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`);
2145
+ }
2146
+ function U1(e, d) {
2147
+ if (e) {
2148
+ if (typeof e == "string") return Nd(e, d);
2149
+ var t = Object.prototype.toString.call(e).slice(8, -1);
2150
+ if (t === "Object" && e.constructor && (t = e.constructor.name), t === "Map" || t === "Set") return Array.from(e);
2151
+ if (t === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t)) return Nd(e, d);
2152
+ }
2153
+ }
2154
+ function Nd(e, d) {
2155
+ (d == null || d > e.length) && (d = e.length);
2156
+ for (var t = 0, r = new Array(d); t < d; t++)
2157
+ r[t] = e[t];
2158
+ return r;
2159
+ }
2160
+ function B1(e, d) {
2161
+ var t = e == null ? null : typeof Symbol < "u" && e[Symbol.iterator] || e["@@iterator"];
2162
+ if (t != null) {
2163
+ var r = [], n = !0, o = !1, a, i;
2164
+ try {
2165
+ for (t = t.call(e); !(n = (a = t.next()).done) && (r.push(a.value), !(d && r.length === d)); n = !0)
2166
+ ;
2167
+ } catch (s) {
2168
+ o = !0, i = s;
2169
+ } finally {
2170
+ try {
2171
+ !n && t.return != null && t.return();
2172
+ } finally {
2173
+ if (o) throw i;
2174
+ }
2175
+ }
2176
+ return r;
2177
+ }
2178
+ }
2179
+ function G1(e) {
2180
+ if (Array.isArray(e)) return e;
2181
+ }
2182
+ function H1(e) {
2183
+ var d = Array.prototype.slice.call(e), t = k1(d, 4), r = t[0], n = t[1], o = t[2], a = t[3], i, s, u;
2184
+ if (typeof r == "string")
2185
+ i = r;
2186
+ else throw new TypeError("A text for parsing must be a string.");
2187
+ if (!n || typeof n == "string")
2188
+ a ? (s = o, u = a) : (s = void 0, u = o), n && (s = D1({
2189
+ defaultCountry: n
2190
+ }, s));
2191
+ else if (ce(n))
2192
+ o ? (s = n, u = o) : u = n;
2193
+ else throw new Error("Invalid second argument: ".concat(n));
2194
+ return {
2195
+ text: i,
2196
+ options: s,
2197
+ metadata: u
2198
+ };
2199
+ }
2200
+ function Sd(e, d) {
2201
+ var t = Object.keys(e);
2202
+ if (Object.getOwnPropertySymbols) {
2203
+ var r = Object.getOwnPropertySymbols(e);
2204
+ d && (r = r.filter(function(n) {
2205
+ return Object.getOwnPropertyDescriptor(e, n).enumerable;
2206
+ })), t.push.apply(t, r);
2207
+ }
2208
+ return t;
2209
+ }
2210
+ function Ed(e) {
2211
+ for (var d = 1; d < arguments.length; d++) {
2212
+ var t = arguments[d] != null ? arguments[d] : {};
2213
+ d % 2 ? Sd(Object(t), !0).forEach(function(r) {
2214
+ j1(e, r, t[r]);
2215
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : Sd(Object(t)).forEach(function(r) {
2216
+ Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r));
2217
+ });
2218
+ }
2219
+ return e;
2220
+ }
2221
+ function j1(e, d, t) {
2222
+ return d in e ? Object.defineProperty(e, d, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[d] = t, e;
2223
+ }
2224
+ function K1(e, d, t) {
2225
+ d && d.defaultCountry && !m0(d.defaultCountry, t) && (d = Ed(Ed({}, d), {}, {
2226
+ defaultCountry: void 0
2227
+ }));
2228
+ try {
2229
+ return M1(e, d, t);
2230
+ } catch (r) {
2231
+ if (!(r instanceof j)) throw r;
2232
+ }
2233
+ }
2234
+ function W1() {
2235
+ var e = H1(arguments), d = e.text, t = e.options, r = e.metadata;
2236
+ return K1(d, t, r);
2237
+ }
2238
+ function Y1() {
2239
+ return jt(W1, arguments);
2240
+ }
2241
+ function X1(e) {
2242
+ return {
2243
+ id: e._id,
2244
+ name: e.name,
2245
+ regNo: e.registrationNumber,
2246
+ addressLine1: e.address.line1,
2247
+ addressLine2: e.address.line2 ?? "",
2248
+ addressCity: e.address.city,
2249
+ addressPostcode: e.address.postcode,
2250
+ addressState: e.address.state,
2251
+ addressCountry: e.address.country,
2252
+ picName: e.contactName ?? "",
2253
+ picPhoneNumber: e.phoneNumber ?? "",
2254
+ picEmail: e.email ?? ""
2255
+ };
2256
+ }
2257
+ function Bd() {
2258
+ return [
2259
+ {
2260
+ id: "id",
2261
+ name: "System ID (leave empty to create new)"
2262
+ },
2263
+ {
2264
+ id: "name",
2265
+ name: "Name"
2266
+ },
2267
+ {
2268
+ id: "regNo",
2269
+ name: "Registration no."
2270
+ },
2271
+ {
2272
+ id: "addressLine1",
2273
+ name: "Address line 1"
2274
+ },
2275
+ {
2276
+ id: "addressLine2",
2277
+ name: "Address line 2"
2278
+ },
2279
+ {
2280
+ id: "addressCity",
2281
+ name: "City"
2282
+ },
2283
+ {
2284
+ id: "addressPostcode",
2285
+ name: "Postcode"
2286
+ },
2287
+ {
2288
+ id: "addressState",
2289
+ name: "State"
2290
+ },
2291
+ {
2292
+ id: "addressCountry",
2293
+ name: "Country"
2294
+ },
2295
+ {
2296
+ id: "picName",
2297
+ name: "Contact name"
2298
+ },
2299
+ {
2300
+ id: "picPhoneNumber",
2301
+ name: "Phone number"
2302
+ },
2303
+ {
2304
+ id: "picEmail",
2305
+ name: "Email"
2306
+ }
2307
+ ];
2308
+ }
2309
+ function Z1() {
2310
+ return [
2311
+ {
2312
+ id: "name",
2313
+ name: "Name"
2314
+ },
2315
+ {
2316
+ id: "regNo",
2317
+ name: "Registration no."
2318
+ },
2319
+ {
2320
+ id: "addressLine1",
2321
+ name: "Address line 1"
2322
+ },
2323
+ {
2324
+ id: "addressCity",
2325
+ name: "City"
2326
+ },
2327
+ {
2328
+ id: "addressPostcode",
2329
+ name: "Postcode"
2330
+ },
2331
+ {
2332
+ id: "addressState",
2333
+ name: "State"
2334
+ },
2335
+ {
2336
+ id: "addressCountry",
2337
+ name: "Country"
2338
+ },
2339
+ {
2340
+ id: "picName",
2341
+ name: "Contact name"
2342
+ },
2343
+ {
2344
+ id: "picPhoneNumber",
2345
+ name: "Phone number"
2346
+ }
2347
+ ];
2348
+ }
2349
+ function q1() {
2350
+ const e = me(), d = ne(), r = (e.businessLevel ? d.businessSuppliers : d.locationSuppliers).map(X1), o = we().currentBusiness.value, a = Bd(), i = [
2351
+ ["Business name:", o == null ? void 0 : o.name],
2352
+ ["Business ID:", o == null ? void 0 : o._id],
2353
+ ["Menu version", o == null ? void 0 : o.menuVersion],
2354
+ [],
2355
+ a.map((c) => c.name),
2356
+ ...r.map((c) => a.map((h) => c[h.id]))
2357
+ ], s = a.map((c) => `system:${c.id}`), u = Rd(i, s), m = `${o == null ? void 0 : o.name} suppliers (${rt(/* @__PURE__ */ new Date())}).xlsx`;
2358
+ return Td(u, m), m;
2359
+ }
2360
+ function z1() {
2361
+ const d = we().currentBusiness.value, t = Bd(), r = [
2362
+ ["Business name:", d == null ? void 0 : d.name],
2363
+ ["Business ID:", d == null ? void 0 : d._id],
2364
+ ["Menu version", d == null ? void 0 : d.menuVersion],
2365
+ [],
2366
+ t.map((i) => i.name)
2367
+ ], n = t.map((i) => `system:${i.id}`), o = Rd(r, n), a = "FeedMe supplier template.xlsx";
2368
+ return Td(o, a), a;
2369
+ }
2370
+ function J1(e) {
2371
+ const [
2372
+ d,
2373
+ t,
2374
+ r,
2375
+ n,
2376
+ o,
2377
+ a,
2378
+ ...i
2379
+ ] = ut(e);
2380
+ if (!d || !d.length || d.some((h) => h.length && !h.startsWith("system:")))
2381
+ throw new Error("Missing meta header. Excel file does not come from the template.");
2382
+ const s = d.map((h) => h.split(":")[1]), m = [
2383
+ "id",
2384
+ "name",
2385
+ "regNo",
2386
+ "addressLine1",
2387
+ "addressCity",
2388
+ "addressPostcode",
2389
+ "addressState",
2390
+ "addressCountry",
2391
+ "picName",
2392
+ "picPhoneNumber"
2393
+ ].filter((h) => !s.includes(h));
2394
+ if (m.length)
2395
+ throw new Error(
2396
+ `Missing meta headers (${m.join()}). Excel file does not come from the template.`
2397
+ );
2398
+ return i.map((h, f) => {
2399
+ const b = {};
2400
+ for (const E in s) {
2401
+ const P = s[E];
2402
+ Object.assign(b, { [P]: h[E] });
2403
+ }
2404
+ return {
2405
+ index: f,
2406
+ data: b
2407
+ };
2408
+ });
2409
+ }
2410
+ function xd(e, d, t) {
2411
+ var u;
2412
+ const r = new Array(), o = Z1().filter((m) => !`${e[m.id] || ""}`.trim().length);
2413
+ o.length && r.push(`Missing required values: ${o.map((m) => m.name).join(", ")}`);
2414
+ const a = t.filter((m) => m.data.id === e.id);
2415
+ return a.length > 1 && r.push(`ID ${e.id} is already used in row ${a.map((m) => m.index + 6).join()}.`), (((u = Y1(e.picPhoneNumber)) == null ? void 0 : u.isValid()) ?? !1) || r.push(`Invalid phone number: ${e.picPhoneNumber}`), {
2416
+ type: "create",
2417
+ supplier: {
2418
+ _id: "",
2419
+ name: e.name,
2420
+ registrationNumber: e.regNo,
2421
+ address: {
2422
+ line2: e.addressLine2,
2423
+ line1: e.addressLine1,
2424
+ state: e.addressState,
2425
+ city: e.addressCity,
2426
+ postcode: e.addressPostcode,
2427
+ country: e.addressCountry
2428
+ },
2429
+ contactName: e.picName,
2430
+ phoneNumber: e.picPhoneNumber,
2431
+ email: e.picEmail
2432
+ },
2433
+ errors: r,
2434
+ excelRowNumber: d + 6
2435
+ };
2436
+ }
2437
+ function Q1(e) {
2438
+ try {
2439
+ const d = J1(e).filter((m) => m.data.id), t = me(), r = ne(), n = t.businessLevel ? r.businessSuppliers : r.locationSuppliers, o = wd(n, "_id"), a = d.filter((m) => !m.data.id), i = d.filter((m) => m.data.id), s = a.map(
2440
+ (m) => xd(m.data, m.index, d)
2441
+ ), u = i.map((m) => {
2442
+ const c = xd(m.data, m.index, d), h = o[m.data.id];
2443
+ return h ? {
2444
+ ...c,
2445
+ type: "update",
2446
+ original: h,
2447
+ supplier: {
2448
+ ...h,
2449
+ name: c.supplier.name,
2450
+ address: {
2451
+ line2: c.supplier.address.line2,
2452
+ line1: c.supplier.address.line1,
2453
+ state: c.supplier.address.state,
2454
+ city: c.supplier.address.city,
2455
+ postcode: c.supplier.address.postcode,
2456
+ country: c.supplier.address.country
2457
+ },
2458
+ registrationNumber: c.supplier.registrationNumber
2459
+ }
2460
+ } : {
2461
+ ...c,
2462
+ type: "update",
2463
+ original: c.supplier,
2464
+ supplier: c.supplier,
2465
+ errors: [
2466
+ ...c.errors,
2467
+ `Cannot find supplier id ${m.data.id} in the system. Reexport supplier excel to obtain the correct value.`
2468
+ ]
2469
+ };
2470
+ });
2471
+ return {
2472
+ invalidExcel: !1,
2473
+ importCreateResult: s,
2474
+ importUpdateResult: u
2475
+ };
2476
+ } catch (d) {
2477
+ return {
2478
+ invalidExcel: !0,
2479
+ invalidExcelMessage: (d == null ? void 0 : d.message) ?? "Invalid excel",
2480
+ importCreateResult: [],
2481
+ importUpdateResult: []
2482
+ };
2483
+ }
2484
+ }
2485
+ const er = { class: "flex items-center gap-12 pl-8" }, dr = { class: "flex flex-col" }, tr = { class: "fm-typo-en-body-md-400 text-fm-color-typo-primary flex items-center gap-4" }, rr = {
2486
+ key: 0,
2487
+ class: "text-fm-color-typo-secondary fm-typo-en-body-sm-400"
2488
+ }, nr = { key: 0 }, Id = /* @__PURE__ */ Q({
2489
+ __name: "SupplierImportItem",
2490
+ props: {
2491
+ type: {},
2492
+ name: {},
2493
+ pic: {},
2494
+ errors: {}
2495
+ },
2496
+ setup(e) {
2497
+ const { t: d } = Z();
2498
+ return (t, r) => {
2499
+ const n = M("FmIcon"), o = M("FmTooltip");
2500
+ return S(), F("div", er, [
2501
+ r[0] || (r[0] = g("div", null, "•", -1)),
2502
+ g("div", dr, [
2503
+ g("div", tr, [
2504
+ g("div", {
2505
+ class: J({
2506
+ "text-fm-color-system-error-300": t.errors.length
2507
+ })
2508
+ }, [
2509
+ Yd(R(t.name) + " ", 1),
2510
+ t.type === "create" ? (S(), F("span", rr, "(" + R(v(d)("inventory.closing.template.import.new")) + ")", 1)) : X("", !0)
2511
+ ], 2),
2512
+ t.errors.length ? (S(), F("div", nr, [
2513
+ C(o, { "z-index": 50 }, {
2514
+ content: V(() => [
2515
+ g("ol", null, [
2516
+ (S(!0), F(z, null, de(t.errors, (a, i) => (S(), F("li", { key: i }, R(a), 1))), 128))
2517
+ ])
2518
+ ]),
2519
+ default: V(() => [
2520
+ C(n, {
2521
+ name: "error",
2522
+ size: "sm",
2523
+ color: "system-error-300"
2524
+ })
2525
+ ]),
2526
+ _: 1
2527
+ })
2528
+ ])) : X("", !0)
2529
+ ]),
2530
+ g("div", {
2531
+ class: J([
2532
+ "fm-typo-en-body-sm-400",
2533
+ {
2534
+ "text-fm-color-system-error-200": t.errors.length,
2535
+ "text-fm-color-typo-secondary": !t.errors.length
2536
+ }
2537
+ ])
2538
+ }, R(t.pic), 3)
2539
+ ])
2540
+ ]);
2541
+ };
2542
+ }
2543
+ }), or = { class: "flex flex-col gap-24" }, ar = { class: "fm-typo-en-body-md-400" }, $r = {
2544
+ key: 0,
2545
+ class: "flex items-center gap-8"
2546
+ }, ir = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, lr = { class: "flex flex-col gap-8" }, sr = { class: "line-clamp-2 text-ellipsis break-all" }, ur = {
2547
+ key: 2,
2548
+ class: "shrink-0"
2549
+ }, cr = {
2550
+ key: 0,
2551
+ class: "flex flex-col"
2552
+ }, fr = { class: "text-fm-color-system-error-300 fm-typo-en-body-sm-400" }, pr = {
2553
+ key: 0,
2554
+ class: "max-h-[200px] overflow-y-auto flex flex-col gap-8"
2555
+ }, mr = { class: "fm-typo-en-body-lg-600" }, yr = /* @__PURE__ */ Q({
2556
+ __name: "SupplierImport",
2557
+ setup(e) {
2558
+ const d = k(null), t = nt(), r = ye(), n = k(!1), o = k(!1), a = k(new Array()), i = k([]), s = k([]), u = x(
2559
+ () => !!a.value.length || i.value.some((f) => f.errors.length) || s.value.some((f) => f.errors.length)
2560
+ ), m = x(
2561
+ () => !!i.value.length || !!s.value.length
2562
+ ), { t: c } = Z();
2563
+ async function h(f) {
2564
+ a.value = [], i.value = [], s.value = [];
2565
+ try {
2566
+ n.value = !0;
2567
+ const [b] = await Promise.all([
2568
+ ct(f),
2569
+ // fake buffer
2570
+ new Promise((_) => setTimeout(_, 1e3))
2571
+ ]), E = b.SheetNames.find((_) => _);
2572
+ if (!E) {
2573
+ a.value.push(c("inventory.ingredient.import.fileError.noSheet"));
2574
+ return;
2575
+ }
2576
+ const P = Q1(b.Sheets[E]);
2577
+ if (P.invalidExcel) {
2578
+ a.value.push(
2579
+ P.invalidExcelMessage ?? c("inventory.ingredient.import.fileError.invalidExcel")
2580
+ );
2581
+ return;
2582
+ }
2583
+ if (i.value = P.importCreateResult, s.value = P.importUpdateResult, !i.value.length && !s.value.length) {
2584
+ a.value.push(c("inventory.ingredient.import.fileError.noData"));
2585
+ return;
2586
+ }
2587
+ t.emitData(P);
2588
+ } catch (b) {
2589
+ r.open({
2590
+ title: c("inventory.ingredient.import.fileError.unableToRead"),
2591
+ message: b == null ? void 0 : b.message,
2592
+ type: "error"
2593
+ }), console.error("Error in reading file", b);
2594
+ } finally {
2595
+ a.value.length && r.open({
2596
+ title: c("inventory.ingredient.import.fileError.invalidExcel"),
2597
+ type: "error"
2598
+ }), n.value = !1;
2599
+ }
2600
+ }
2601
+ return Fd(d, (f) => {
2602
+ f && h(f);
2603
+ }), (f, b) => {
2604
+ const E = M("FmCircularProgress"), P = M("FmIcon"), _ = M("FmButton");
2605
+ return S(), F("div", or, [
2606
+ g("div", ar, R(v(c)("inventory.supplier.import.message")), 1),
2607
+ o.value ? (S(), F("div", $r, [
2608
+ g("div", null, [
2609
+ C(E, {
2610
+ size: "md",
2611
+ color: "neutral-gray-200"
2612
+ })
2613
+ ]),
2614
+ g("div", ir, R(v(c)("inventory.formField.loading")), 1)
2615
+ ])) : (S(), F(z, { key: 1 }, [
2616
+ C(ft, {
2617
+ class: J({
2618
+ "w-full": !0,
2619
+ "h-[200px]": !d.value
2620
+ }),
2621
+ accept: ".xlsx",
2622
+ onFileUpload: b[0] || (b[0] = (p) => d.value = p),
2623
+ label: v(c)("inventory.ingredient.import.uploadTemplate"),
2624
+ "button-label": v(c)("inventory.ingredient.import.selectFile")
2625
+ }, Xd({ _: 2 }, [
2626
+ d.value ? {
2627
+ name: "default",
2628
+ fn: V(({ openFileDialog: p }) => [
2629
+ g("div", lr, [
2630
+ g("div", {
2631
+ class: J([
2632
+ "fm-corner-radius-md p-16 flex items-center gap-16",
2633
+ {
2634
+ "border border-fm-color-neutral-gray-100": n.value,
2635
+ "border border-fm-color-neutral-gray-200": !n.value && !u.value,
2636
+ "border border-fm-color-system-error-200": u.value
2637
+ }
2638
+ ])
2639
+ }, [
2640
+ n.value ? (S(), K(E, {
2641
+ key: 0,
2642
+ size: "md",
2643
+ color: "neutral-gray-200"
2644
+ })) : (S(), K(P, {
2645
+ key: 1,
2646
+ name: u.value ? "error" : "attach_file",
2647
+ outline: "",
2648
+ color: u.value ? "system-error-300" : void 0
2649
+ }, null, 8, ["name", "color"])),
2650
+ g("div", {
2651
+ class: J([
2652
+ "fm-typo-en-body-md-400 flex-1 h-[36px] flex items-center",
2653
+ {
2654
+ "text-fm-color-typo-disabled": n.value,
2655
+ "text-fm-color-typo-primary": !n.value
2656
+ }
2657
+ ])
2658
+ }, [
2659
+ g("div", sr, R(d.value.name), 1)
2660
+ ], 2),
2661
+ n.value ? X("", !0) : (S(), F("div", ur, [
2662
+ C(_, {
2663
+ label: v(c)("inventory.ingredient.import.replaceFile"),
2664
+ variant: u.value ? "destructive" : "secondary",
2665
+ "prepend-icon": u.value ? void 0 : "autorenew",
2666
+ onClick: p
2667
+ }, null, 8, ["label", "variant", "prepend-icon", "onClick"])
2668
+ ]))
2669
+ ], 2),
2670
+ a.value.length ? (S(), F("div", cr, [
2671
+ (S(!0), F(z, null, de(a.value, (N, I) => (S(), F("div", {
2672
+ key: I,
2673
+ class: "flex gap-8 items-center"
2674
+ }, [
2675
+ C(P, {
2676
+ name: "error",
2677
+ size: "sm",
2678
+ color: "system-error-300"
2679
+ }),
2680
+ g("div", fr, R(N), 1)
2681
+ ]))), 128))
2682
+ ])) : X("", !0)
2683
+ ])
2684
+ ]),
2685
+ key: "0"
2686
+ } : void 0
2687
+ ]), 1032, ["class", "label", "button-label"]),
2688
+ m.value ? (S(), F("div", pr, [
2689
+ g("div", mr, R(v(c)("inventory.ingredient.import.summary")), 1),
2690
+ (S(!0), F(z, null, de(i.value, (p, N) => (S(), K(Id, {
2691
+ key: N,
2692
+ name: p.supplier.name,
2693
+ pic: p.supplier.contactName ?? "",
2694
+ errors: p.errors,
2695
+ type: "create"
2696
+ }, null, 8, ["name", "pic", "errors"]))), 128)),
2697
+ (S(!0), F(z, null, de(s.value, (p) => (S(), K(Id, {
2698
+ key: p.supplier._id,
2699
+ name: p.supplier.name,
2700
+ pic: p.supplier.contactName ?? "",
2701
+ errors: p.errors,
2702
+ type: "update"
2703
+ }, null, 8, ["name", "pic", "errors"]))), 128))
2704
+ ])) : X("", !0)
2705
+ ], 64))
2706
+ ]);
2707
+ };
2708
+ }
2709
+ }), vr = st("supplierActions", function() {
2710
+ const e = ne(), d = Ae(), { t } = Z(), r = ye();
2711
+ function n() {
2712
+ d.open({
2713
+ title: t("inventory.supplier.import.title"),
2714
+ contentComponent: yr,
2715
+ overlay: !0,
2716
+ closeButton: !0,
2717
+ primaryActions: {
2718
+ text: t("common.import"),
2719
+ close: !1
2720
+ },
2721
+ secondaryActions: {
2722
+ text: t("common.close"),
2723
+ close: !0
2724
+ },
2725
+ tertiaryActions: {
2726
+ text: t("inventory.supplier.import.actions.downloadTemplate"),
2727
+ close: !1,
2728
+ variant: "plain"
2729
+ }
2730
+ }).onPrimary((i) => {
2731
+ if (!i) {
2732
+ r.open({
2733
+ title: t("inventory.supplier.import.error.noData"),
2734
+ type: "error"
2735
+ });
2736
+ return;
2737
+ }
2738
+ if (!i.importCreateResult.length && !i.importUpdateResult.length) {
2739
+ r.open({
2740
+ title: t("inventory.supplier.import.error.invalidContent"),
2741
+ message: t("inventory.supplier.import.error.noImportData"),
2742
+ type: "error"
2743
+ });
2744
+ return;
2745
+ }
2746
+ if (i.importCreateResult.some((s) => s.errors.length) || i.importUpdateResult.some((s) => s.errors.length)) {
2747
+ r.open({
2748
+ title: t("inventory.supplier.import.error.invalidContent"),
2749
+ message: t("inventory.supplier.import.error.hasErrors"),
2750
+ type: "error"
2751
+ });
2752
+ return;
2753
+ }
2754
+ d.close(), a(i);
2755
+ }).onTertiary(z1);
2756
+ }
2757
+ function o() {
2758
+ const i = q1();
2759
+ r.open({
2760
+ title: t("inventory.supplier.export.success"),
2761
+ message: t("inventory.supplier.export.filename", [i]),
2762
+ type: "success"
2763
+ });
2764
+ }
2765
+ async function a(i) {
2766
+ try {
2767
+ const s = [
2768
+ ...i.importCreateResult.map((h) => h.supplier),
2769
+ ...i.importUpdateResult.map((h) => h.supplier)
2770
+ ], u = 100;
2771
+ let m = 0;
2772
+ const c = () => {
2773
+ m += u, r.open({
2774
+ title: t("inventory.supplier.import.progress", [
2775
+ Math.min(m, s.length),
2776
+ s.length
2777
+ ])
2778
+ });
2779
+ };
2780
+ for (const h of s.chunk(100))
2781
+ c(), await e.importSuppliers(h);
2782
+ r.open({
2783
+ title: t("inventory.supplier.import.success"),
2784
+ type: "success"
2785
+ });
2786
+ } catch (s) {
2787
+ r.open({
2788
+ title: t("inventory.supplier.import.error.failed"),
2789
+ message: t("inventory.supplier.import.error.systemMessage", [s == null ? void 0 : s.message]),
2790
+ type: "error"
2791
+ }), console.error("Error in importing skus", i, s);
2792
+ } finally {
2793
+ e.readSuppliers();
2794
+ }
2795
+ }
2796
+ return {
2797
+ importSuppliers: n,
2798
+ exportSuppliers: o
2799
+ };
2800
+ }), gr = { class: "flex flex-col py-8" }, hr = { class: "fm-typo-en-body-lg-600 text-fm-color-typo-primary" }, br = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, _r = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, Pr = {
2801
+ key: 0,
2802
+ class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary"
2803
+ }, Cr = "You are managing business-level supplier list. These suppliers will be made visible to all locations.", Dr = /* @__PURE__ */ Q({
2804
+ __name: "SupplierView",
2805
+ setup(e) {
2806
+ const { importSuppliers: d, exportSuppliers: t } = vr(), r = ne(), n = me(), o = Ad(), a = k(!1), i = Ae(), s = ye(), { t: u } = Z();
2807
+ n.watchLocation(c);
2808
+ const m = x(() => n.businessLevel);
2809
+ Fd(m, c), Zd(() => {
2810
+ o.enableSupplierMasterList || (n.businessLevel = !1);
2811
+ });
2812
+ async function c() {
2813
+ if (n._currentLocation) {
2814
+ a.value = !0;
2815
+ try {
2816
+ await Promise.all([
2817
+ r.readSuppliers(),
2818
+ new Promise((A) => setTimeout(A, 1e3))
2819
+ ]);
2820
+ } catch {
2821
+ s.open({
2822
+ title: "Cannot fetch supplier list",
2823
+ type: "error"
2824
+ });
2825
+ } finally {
2826
+ a.value = !1;
2827
+ }
2828
+ }
2829
+ }
2830
+ const h = x(
2831
+ () => m.value ? r.businessSuppliers : r.locationSuppliers
2832
+ ), f = k({});
2833
+ function b() {
2834
+ f.value.mode = B.CREATE, f.value.supplier = {}, f.value.show = !0;
2835
+ }
2836
+ function E(y) {
2837
+ f.value.mode = B.UPDATE, f.value.supplier = Ne(y), f.value.show = !0;
2838
+ }
2839
+ async function P(y) {
2840
+ i.open({
2841
+ title: u("inventory.supplier.delete.confirm"),
2842
+ message: u("inventory.supplier.delete.confirmMessage", { name: y.name }),
2843
+ primaryActions: {
2844
+ text: u("common.delete"),
2845
+ close: !0,
2846
+ variant: "destructive"
2847
+ },
2848
+ secondaryActions: {
2849
+ text: u("common.cancel"),
2850
+ close: !0
2851
+ }
2852
+ }).onPrimary(() => _(y));
2853
+ }
2854
+ async function _(y) {
2855
+ i.open({
2856
+ title: u("inventory.supplier.deletingSupplier"),
2857
+ closeButton: !1
2858
+ });
2859
+ try {
2860
+ await r.deleteSupplier(y), s.open({
2861
+ title: u("inventory.supplier.delete.success"),
2862
+ message: u("inventory.supplier.delete.successMessage", { name: y == null ? void 0 : y.name }),
2863
+ type: "success"
2864
+ }), c();
2865
+ } catch (A) {
2866
+ s.open({
2867
+ title: u("inventory.supplier.delete.error"),
2868
+ message: u("inventory.supplier.delete.errorMessage", { name: y == null ? void 0 : y.name }),
2869
+ type: "error"
2870
+ }), console.error("failed to delete supplier", A);
2871
+ } finally {
2872
+ i.close();
2873
+ }
2874
+ }
2875
+ const { columnDefs: p } = pt(E, P);
2876
+ function N(y) {
2877
+ y === "create" && b(), y === "import" && d();
2878
+ }
2879
+ const I = k(""), { breakpoints: O } = ot(), w = x(() => O.value.xs || O.value.sm), U = x(() => w.value ? 10 : 20), l = at(), $ = x(() => {
2880
+ const y = [
2881
+ {
2882
+ label: u("inventory.supplier.create.title"),
2883
+ value: "create",
2884
+ isPrimary: !0,
2885
+ prependIcon: "add"
2886
+ }
2887
+ ];
2888
+ return w.value ? y : [
2889
+ ...y,
2890
+ {
2891
+ label: "Import",
2892
+ value: "import",
2893
+ isPrimary: !1
2894
+ }
2895
+ ];
2896
+ }), ee = x(() => {
2897
+ const y = [
2898
+ {
2899
+ icon: "refresh",
2900
+ onClick: c
2901
+ }
2902
+ ];
2903
+ return w.value ? [...y, { icon: "more_vert", onClick: () => T.value = !0 }] : [
2904
+ ...y,
2905
+ {
2906
+ icon: "ios_share",
2907
+ onClick: t
2908
+ }
2909
+ ];
2910
+ }), T = k(!1), he = [
2911
+ {
2912
+ value: "import",
2913
+ label: u("common.import")
2914
+ },
2915
+ {
2916
+ value: "export",
2917
+ label: u("common.export")
2918
+ }
2919
+ ];
2920
+ function be(y) {
2921
+ switch (T.value = !1, y) {
2922
+ case "import":
2923
+ return d();
2924
+ case "export":
2925
+ return t();
2926
+ }
2927
+ }
2928
+ return (y, A) => {
2929
+ const Gd = M("FmTable"), Hd = M("FmCollapsibleTabs"), jd = M("FmBottomSheet");
2930
+ return S(), K($t, {
2931
+ title: v(u)("inventory.supplier.title"),
2932
+ actions: $.value,
2933
+ "onClick:action": N,
2934
+ "using-business-helper-text": Cr
2935
+ }, {
2936
+ default: V(() => [
2937
+ g("div", {
2938
+ class: J([
2939
+ "flex flex-col gap-8 max-h-full",
2940
+ {
2941
+ "p-0": w.value,
2942
+ "px-24 ": !w.value
2943
+ }
2944
+ ])
2945
+ }, [
2946
+ C(it, {
2947
+ searchable: "",
2948
+ "change-location": "",
2949
+ search: I.value,
2950
+ "onUpdate:search": A[0] || (A[0] = (L) => I.value = L),
2951
+ "show-business": v(o).enableSupplierMasterList,
2952
+ actions: ee.value
2953
+ }, null, 8, ["search", "show-business", "actions"]),
2954
+ C(Gd, {
2955
+ style: qd(v(l).tableHeight),
2956
+ "column-defs": v(p),
2957
+ "row-data": h.value,
2958
+ "search-value": I.value,
2959
+ loading: !v(n)._currentLocation || a.value,
2960
+ onRowClick: A[1] || (A[1] = (L) => E(L.original)),
2961
+ "page-size": U.value
2962
+ }, {
2963
+ "list-row": V((L) => [
2964
+ C(Qd, {
2965
+ row: L,
2966
+ onRowClick: E
2967
+ }, {
2968
+ default: V((Y) => {
2969
+ var ke, Ve, Ue, oe, Be, Ge, He, je, ae, Ke, We, Ye, Xe, $e, Ze, qe, ze, Je, ie, Qe;
2970
+ return [
2971
+ g("div", gr, [
2972
+ g("div", hr, [
2973
+ C(v(se), {
2974
+ render: (Ue = (Ve = (ke = Y.name) == null ? void 0 : ke.column) == null ? void 0 : Ve.columnDef) == null ? void 0 : Ue.cell,
2975
+ props: (Be = (oe = Y.name) == null ? void 0 : oe.getContext) == null ? void 0 : Be.call(oe)
2976
+ }, null, 8, ["render", "props"])
2977
+ ]),
2978
+ g("div", br, [
2979
+ C(v(se), {
2980
+ render: (je = (He = (Ge = Y.contactName) == null ? void 0 : Ge.column) == null ? void 0 : He.columnDef) == null ? void 0 : je.cell,
2981
+ props: (Ke = (ae = Y.contactName) == null ? void 0 : ae.getContext) == null ? void 0 : Ke.call(ae)
2982
+ }, null, 8, ["render", "props"])
2983
+ ]),
2984
+ g("div", _r, [
2985
+ C(v(se), {
2986
+ render: (Xe = (Ye = (We = Y.phoneNumber) == null ? void 0 : We.column) == null ? void 0 : Ye.columnDef) == null ? void 0 : Xe.cell,
2987
+ props: (Ze = ($e = Y.phoneNumber) == null ? void 0 : $e.getContext) == null ? void 0 : Ze.call($e)
2988
+ }, null, 8, ["render", "props"])
2989
+ ]),
2990
+ L.original.email ? (S(), F("div", Pr, [
2991
+ C(v(se), {
2992
+ render: (Je = (ze = (qe = Y.email) == null ? void 0 : qe.column) == null ? void 0 : ze.columnDef) == null ? void 0 : Je.cell,
2993
+ props: (Qe = (ie = Y.email) == null ? void 0 : ie.getContext) == null ? void 0 : Qe.call(ie)
2994
+ }, null, 8, ["render", "props"])
2995
+ ])) : X("", !0)
2996
+ ])
2997
+ ];
2998
+ }),
2999
+ _: 2
3000
+ }, 1032, ["row"])
3001
+ ]),
3002
+ _: 1
3003
+ }, 8, ["style", "column-defs", "row-data", "search-value", "loading", "page-size"])
3004
+ ], 2),
3005
+ (S(), K(zd, { to: "body" }, [
3006
+ C(Gt, {
3007
+ show: f.value.show,
3008
+ "onUpdate:show": A[2] || (A[2] = (L) => f.value.show = L),
3009
+ supplier: f.value.supplier,
3010
+ mode: f.value.mode,
3011
+ onSubmitted: A[3] || (A[3] = (L) => c())
3012
+ }, null, 8, ["show", "supplier", "mode"]),
3013
+ C(jd, {
3014
+ "dismiss-away": "",
3015
+ "no-header": "",
3016
+ modelValue: T.value,
3017
+ "onUpdate:modelValue": A[5] || (A[5] = (L) => T.value = L)
3018
+ }, {
3019
+ default: V(() => [
3020
+ C(Hd, {
3021
+ class: "pb-8",
3022
+ items: he,
3023
+ "onUpdate:modelValue": A[4] || (A[4] = (L) => be(L))
3024
+ })
3025
+ ]),
3026
+ _: 1
3027
+ }, 8, ["modelValue"])
3028
+ ]))
3029
+ ]),
3030
+ _: 1
3031
+ }, 8, ["title", "actions"]);
3032
+ };
3033
+ }
3034
+ });
3035
+ export {
3036
+ Dr as default
3037
+ };