intl-tel-input 25.10.10 → 25.10.12
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +11 -9
- package/angular/README.md +1 -1
- package/angular/build/IntlTelInput.js +547 -180
- package/angular/build/IntlTelInputWithUtils.js +547 -180
- package/angular/build/types/intl-tel-input/data.d.ts +1 -1
- package/angular/build/types/intl-tel-input.d.ts +3 -5
- package/angular/build/types/modules/format/formatting.d.ts +3 -3
- package/angular/build/types/modules/types/public-api.d.ts +0 -7
- package/build/css/intlTelInput.css +1 -13
- package/build/css/intlTelInput.min.css +1 -1
- package/build/js/data.js +497 -143
- package/build/js/data.min.js +2 -2
- package/build/js/intlTelInput.d.ts +7 -16
- package/build/js/intlTelInput.js +548 -181
- package/build/js/intlTelInput.min.js +4 -4
- package/build/js/intlTelInputWithUtils.js +548 -181
- package/build/js/intlTelInputWithUtils.min.js +3 -3
- package/package.json +5 -4
- package/react/README.md +1 -1
- package/react/build/IntlTelInput.cjs +547 -180
- package/react/build/IntlTelInput.d.ts +7 -16
- package/react/build/IntlTelInput.js +547 -180
- package/react/build/IntlTelInputWithUtils.cjs +547 -180
- package/react/build/IntlTelInputWithUtils.js +547 -180
- package/vue/README.md +1 -1
- package/vue/build/IntlTelInput.mjs +937 -561
- package/vue/build/IntlTelInputWithUtils.mjs +1027 -651
|
@@ -1,32 +1,45 @@
|
|
|
1
|
-
import { mergeModels as
|
|
2
|
-
const
|
|
1
|
+
import { mergeModels as s0, useModel as P0, ref as I1, onMounted as x0, watch as B0, onUnmounted as R0, withDirectives as k0, createElementBlock as O0, openBlock as G0, mergeProps as U0, vModelText as F0 } from "vue";
|
|
2
|
+
const K0 = [
|
|
3
3
|
[
|
|
4
4
|
"af",
|
|
5
5
|
// Afghanistan
|
|
6
|
-
"93"
|
|
6
|
+
"93",
|
|
7
|
+
0,
|
|
8
|
+
null,
|
|
9
|
+
"0"
|
|
7
10
|
],
|
|
8
11
|
[
|
|
9
12
|
"ax",
|
|
10
13
|
// Åland Islands
|
|
11
14
|
"358",
|
|
12
|
-
1
|
|
15
|
+
1,
|
|
16
|
+
["18", "4"],
|
|
17
|
+
// (4 is a mobile range shared with FI)
|
|
18
|
+
"0"
|
|
13
19
|
],
|
|
14
20
|
[
|
|
15
21
|
"al",
|
|
16
22
|
// Albania
|
|
17
|
-
"355"
|
|
23
|
+
"355",
|
|
24
|
+
0,
|
|
25
|
+
null,
|
|
26
|
+
"0"
|
|
18
27
|
],
|
|
19
28
|
[
|
|
20
29
|
"dz",
|
|
21
30
|
// Algeria
|
|
22
|
-
"213"
|
|
31
|
+
"213",
|
|
32
|
+
0,
|
|
33
|
+
null,
|
|
34
|
+
"0"
|
|
23
35
|
],
|
|
24
36
|
[
|
|
25
37
|
"as",
|
|
26
38
|
// American Samoa
|
|
27
39
|
"1",
|
|
28
40
|
5,
|
|
29
|
-
["684"]
|
|
41
|
+
["684"],
|
|
42
|
+
"1"
|
|
30
43
|
],
|
|
31
44
|
[
|
|
32
45
|
"ad",
|
|
@@ -43,24 +56,32 @@ const K2 = [
|
|
|
43
56
|
// Anguilla
|
|
44
57
|
"1",
|
|
45
58
|
6,
|
|
46
|
-
["264"]
|
|
59
|
+
["264"],
|
|
60
|
+
"1"
|
|
47
61
|
],
|
|
48
62
|
[
|
|
49
63
|
"ag",
|
|
50
64
|
// Antigua and Barbuda
|
|
51
65
|
"1",
|
|
52
66
|
7,
|
|
53
|
-
["268"]
|
|
67
|
+
["268"],
|
|
68
|
+
"1"
|
|
54
69
|
],
|
|
55
70
|
[
|
|
56
71
|
"ar",
|
|
57
72
|
// Argentina
|
|
58
|
-
"54"
|
|
73
|
+
"54",
|
|
74
|
+
0,
|
|
75
|
+
null,
|
|
76
|
+
"0"
|
|
59
77
|
],
|
|
60
78
|
[
|
|
61
79
|
"am",
|
|
62
80
|
// Armenia
|
|
63
|
-
"374"
|
|
81
|
+
"374",
|
|
82
|
+
0,
|
|
83
|
+
null,
|
|
84
|
+
"0"
|
|
64
85
|
],
|
|
65
86
|
[
|
|
66
87
|
"aw",
|
|
@@ -77,25 +98,33 @@ const K2 = [
|
|
|
77
98
|
// Australia
|
|
78
99
|
"61",
|
|
79
100
|
0,
|
|
80
|
-
|
|
101
|
+
["4"],
|
|
102
|
+
// (mobile range shared with CX and CC)
|
|
81
103
|
"0"
|
|
82
104
|
],
|
|
83
105
|
[
|
|
84
106
|
"at",
|
|
85
107
|
// Austria
|
|
86
|
-
"43"
|
|
108
|
+
"43",
|
|
109
|
+
0,
|
|
110
|
+
null,
|
|
111
|
+
"0"
|
|
87
112
|
],
|
|
88
113
|
[
|
|
89
114
|
"az",
|
|
90
115
|
// Azerbaijan
|
|
91
|
-
"994"
|
|
116
|
+
"994",
|
|
117
|
+
0,
|
|
118
|
+
null,
|
|
119
|
+
"0"
|
|
92
120
|
],
|
|
93
121
|
[
|
|
94
122
|
"bs",
|
|
95
123
|
// Bahamas
|
|
96
124
|
"1",
|
|
97
125
|
8,
|
|
98
|
-
["242"]
|
|
126
|
+
["242"],
|
|
127
|
+
"1"
|
|
99
128
|
],
|
|
100
129
|
[
|
|
101
130
|
"bh",
|
|
@@ -105,24 +134,34 @@ const K2 = [
|
|
|
105
134
|
[
|
|
106
135
|
"bd",
|
|
107
136
|
// Bangladesh
|
|
108
|
-
"880"
|
|
137
|
+
"880",
|
|
138
|
+
0,
|
|
139
|
+
null,
|
|
140
|
+
"0"
|
|
109
141
|
],
|
|
110
142
|
[
|
|
111
143
|
"bb",
|
|
112
144
|
// Barbados
|
|
113
145
|
"1",
|
|
114
146
|
9,
|
|
115
|
-
["246"]
|
|
147
|
+
["246"],
|
|
148
|
+
"1"
|
|
116
149
|
],
|
|
117
150
|
[
|
|
118
151
|
"by",
|
|
119
152
|
// Belarus
|
|
120
|
-
"375"
|
|
153
|
+
"375",
|
|
154
|
+
0,
|
|
155
|
+
null,
|
|
156
|
+
"8"
|
|
121
157
|
],
|
|
122
158
|
[
|
|
123
159
|
"be",
|
|
124
160
|
// Belgium
|
|
125
|
-
"32"
|
|
161
|
+
"32",
|
|
162
|
+
0,
|
|
163
|
+
null,
|
|
164
|
+
"0"
|
|
126
165
|
],
|
|
127
166
|
[
|
|
128
167
|
"bz",
|
|
@@ -139,7 +178,8 @@ const K2 = [
|
|
|
139
178
|
// Bermuda
|
|
140
179
|
"1",
|
|
141
180
|
10,
|
|
142
|
-
["441"]
|
|
181
|
+
["441"],
|
|
182
|
+
"1"
|
|
143
183
|
],
|
|
144
184
|
[
|
|
145
185
|
"bt",
|
|
@@ -149,12 +189,18 @@ const K2 = [
|
|
|
149
189
|
[
|
|
150
190
|
"bo",
|
|
151
191
|
// Bolivia
|
|
152
|
-
"591"
|
|
192
|
+
"591",
|
|
193
|
+
0,
|
|
194
|
+
null,
|
|
195
|
+
"0"
|
|
153
196
|
],
|
|
154
197
|
[
|
|
155
198
|
"ba",
|
|
156
199
|
// Bosnia and Herzegovina
|
|
157
|
-
"387"
|
|
200
|
+
"387",
|
|
201
|
+
0,
|
|
202
|
+
null,
|
|
203
|
+
"0"
|
|
158
204
|
],
|
|
159
205
|
[
|
|
160
206
|
"bw",
|
|
@@ -164,7 +210,10 @@ const K2 = [
|
|
|
164
210
|
[
|
|
165
211
|
"br",
|
|
166
212
|
// Brazil
|
|
167
|
-
"55"
|
|
213
|
+
"55",
|
|
214
|
+
0,
|
|
215
|
+
null,
|
|
216
|
+
"0"
|
|
168
217
|
],
|
|
169
218
|
[
|
|
170
219
|
"io",
|
|
@@ -176,7 +225,8 @@ const K2 = [
|
|
|
176
225
|
// British Virgin Islands
|
|
177
226
|
"1",
|
|
178
227
|
11,
|
|
179
|
-
["284"]
|
|
228
|
+
["284"],
|
|
229
|
+
"1"
|
|
180
230
|
],
|
|
181
231
|
[
|
|
182
232
|
"bn",
|
|
@@ -186,7 +236,10 @@ const K2 = [
|
|
|
186
236
|
[
|
|
187
237
|
"bg",
|
|
188
238
|
// Bulgaria
|
|
189
|
-
"359"
|
|
239
|
+
"359",
|
|
240
|
+
0,
|
|
241
|
+
null,
|
|
242
|
+
"0"
|
|
190
243
|
],
|
|
191
244
|
[
|
|
192
245
|
"bf",
|
|
@@ -201,7 +254,10 @@ const K2 = [
|
|
|
201
254
|
[
|
|
202
255
|
"kh",
|
|
203
256
|
// Cambodia
|
|
204
|
-
"855"
|
|
257
|
+
"855",
|
|
258
|
+
0,
|
|
259
|
+
null,
|
|
260
|
+
"0"
|
|
205
261
|
],
|
|
206
262
|
[
|
|
207
263
|
"cm",
|
|
@@ -213,7 +269,8 @@ const K2 = [
|
|
|
213
269
|
// Canada
|
|
214
270
|
"1",
|
|
215
271
|
1,
|
|
216
|
-
["204", "226", "236", "249", "250", "263", "289", "306", "343", "354", "365", "367", "368", "382", "
|
|
272
|
+
["204", "226", "236", "249", "250", "257", "263", "289", "306", "343", "354", "365", "367", "368", "382", "403", "416", "418", "428", "431", "437", "438", "450", "468", "474", "506", "514", "519", "548", "579", "581", "584", "587", "604", "613", "639", "647", "672", "683", "705", "709", "742", "753", "778", "780", "782", "807", "819", "825", "867", "873", "879", "902", "905", "942"],
|
|
273
|
+
"1"
|
|
217
274
|
],
|
|
218
275
|
[
|
|
219
276
|
"cv",
|
|
@@ -232,7 +289,8 @@ const K2 = [
|
|
|
232
289
|
// Cayman Islands
|
|
233
290
|
"1",
|
|
234
291
|
12,
|
|
235
|
-
["345"]
|
|
292
|
+
["345"],
|
|
293
|
+
"1"
|
|
236
294
|
],
|
|
237
295
|
[
|
|
238
296
|
"cf",
|
|
@@ -252,14 +310,18 @@ const K2 = [
|
|
|
252
310
|
[
|
|
253
311
|
"cn",
|
|
254
312
|
// China
|
|
255
|
-
"86"
|
|
313
|
+
"86",
|
|
314
|
+
0,
|
|
315
|
+
null,
|
|
316
|
+
"0"
|
|
256
317
|
],
|
|
257
318
|
[
|
|
258
319
|
"cx",
|
|
259
320
|
// Christmas Island
|
|
260
321
|
"61",
|
|
261
322
|
2,
|
|
262
|
-
["89164"],
|
|
323
|
+
["4", "89164"],
|
|
324
|
+
// (4 is a mobile range shared with AU and CC)
|
|
263
325
|
"0"
|
|
264
326
|
],
|
|
265
327
|
[
|
|
@@ -267,13 +329,17 @@ const K2 = [
|
|
|
267
329
|
// Cocos (Keeling) Islands
|
|
268
330
|
"61",
|
|
269
331
|
1,
|
|
270
|
-
["89162"],
|
|
332
|
+
["4", "89162"],
|
|
333
|
+
// (4 is a mobile range shared with AU and CX)
|
|
271
334
|
"0"
|
|
272
335
|
],
|
|
273
336
|
[
|
|
274
337
|
"co",
|
|
275
338
|
// Colombia
|
|
276
|
-
"57"
|
|
339
|
+
"57",
|
|
340
|
+
0,
|
|
341
|
+
null,
|
|
342
|
+
"0"
|
|
277
343
|
],
|
|
278
344
|
[
|
|
279
345
|
"km",
|
|
@@ -288,7 +354,10 @@ const K2 = [
|
|
|
288
354
|
[
|
|
289
355
|
"cd",
|
|
290
356
|
// Congo (Kinshasa)
|
|
291
|
-
"243"
|
|
357
|
+
"243",
|
|
358
|
+
0,
|
|
359
|
+
null,
|
|
360
|
+
"0"
|
|
292
361
|
],
|
|
293
362
|
[
|
|
294
363
|
"ck",
|
|
@@ -308,12 +377,18 @@ const K2 = [
|
|
|
308
377
|
[
|
|
309
378
|
"hr",
|
|
310
379
|
// Croatia
|
|
311
|
-
"385"
|
|
380
|
+
"385",
|
|
381
|
+
0,
|
|
382
|
+
null,
|
|
383
|
+
"0"
|
|
312
384
|
],
|
|
313
385
|
[
|
|
314
386
|
"cu",
|
|
315
387
|
// Cuba
|
|
316
|
-
"53"
|
|
388
|
+
"53",
|
|
389
|
+
0,
|
|
390
|
+
null,
|
|
391
|
+
"0"
|
|
317
392
|
],
|
|
318
393
|
[
|
|
319
394
|
"cw",
|
|
@@ -346,24 +421,32 @@ const K2 = [
|
|
|
346
421
|
// Dominica
|
|
347
422
|
"1",
|
|
348
423
|
13,
|
|
349
|
-
["767"]
|
|
424
|
+
["767"],
|
|
425
|
+
"1"
|
|
350
426
|
],
|
|
351
427
|
[
|
|
352
428
|
"do",
|
|
353
429
|
// Dominican Republic
|
|
354
430
|
"1",
|
|
355
431
|
2,
|
|
356
|
-
["809", "829", "849"]
|
|
432
|
+
["809", "829", "849"],
|
|
433
|
+
"1"
|
|
357
434
|
],
|
|
358
435
|
[
|
|
359
436
|
"ec",
|
|
360
437
|
// Ecuador
|
|
361
|
-
"593"
|
|
438
|
+
"593",
|
|
439
|
+
0,
|
|
440
|
+
null,
|
|
441
|
+
"0"
|
|
362
442
|
],
|
|
363
443
|
[
|
|
364
444
|
"eg",
|
|
365
445
|
// Egypt
|
|
366
|
-
"20"
|
|
446
|
+
"20",
|
|
447
|
+
0,
|
|
448
|
+
null,
|
|
449
|
+
"0"
|
|
367
450
|
],
|
|
368
451
|
[
|
|
369
452
|
"sv",
|
|
@@ -378,7 +461,10 @@ const K2 = [
|
|
|
378
461
|
[
|
|
379
462
|
"er",
|
|
380
463
|
// Eritrea
|
|
381
|
-
"291"
|
|
464
|
+
"291",
|
|
465
|
+
0,
|
|
466
|
+
null,
|
|
467
|
+
"0"
|
|
382
468
|
],
|
|
383
469
|
[
|
|
384
470
|
"ee",
|
|
@@ -393,7 +479,10 @@ const K2 = [
|
|
|
393
479
|
[
|
|
394
480
|
"et",
|
|
395
481
|
// Ethiopia
|
|
396
|
-
"251"
|
|
482
|
+
"251",
|
|
483
|
+
0,
|
|
484
|
+
null,
|
|
485
|
+
"0"
|
|
397
486
|
],
|
|
398
487
|
[
|
|
399
488
|
"fk",
|
|
@@ -414,17 +503,26 @@ const K2 = [
|
|
|
414
503
|
"fi",
|
|
415
504
|
// Finland
|
|
416
505
|
"358",
|
|
417
|
-
0
|
|
506
|
+
0,
|
|
507
|
+
["4"],
|
|
508
|
+
// (mobile range shared with AX)
|
|
509
|
+
"0"
|
|
418
510
|
],
|
|
419
511
|
[
|
|
420
512
|
"fr",
|
|
421
513
|
// France
|
|
422
|
-
"33"
|
|
514
|
+
"33",
|
|
515
|
+
0,
|
|
516
|
+
null,
|
|
517
|
+
"0"
|
|
423
518
|
],
|
|
424
519
|
[
|
|
425
520
|
"gf",
|
|
426
521
|
// French Guiana
|
|
427
|
-
"594"
|
|
522
|
+
"594",
|
|
523
|
+
0,
|
|
524
|
+
null,
|
|
525
|
+
"0"
|
|
428
526
|
],
|
|
429
527
|
[
|
|
430
528
|
"pf",
|
|
@@ -444,17 +542,26 @@ const K2 = [
|
|
|
444
542
|
[
|
|
445
543
|
"ge",
|
|
446
544
|
// Georgia
|
|
447
|
-
"995"
|
|
545
|
+
"995",
|
|
546
|
+
0,
|
|
547
|
+
null,
|
|
548
|
+
"0"
|
|
448
549
|
],
|
|
449
550
|
[
|
|
450
551
|
"de",
|
|
451
552
|
// Germany
|
|
452
|
-
"49"
|
|
553
|
+
"49",
|
|
554
|
+
0,
|
|
555
|
+
null,
|
|
556
|
+
"0"
|
|
453
557
|
],
|
|
454
558
|
[
|
|
455
559
|
"gh",
|
|
456
560
|
// Ghana
|
|
457
|
-
"233"
|
|
561
|
+
"233",
|
|
562
|
+
0,
|
|
563
|
+
null,
|
|
564
|
+
"0"
|
|
458
565
|
],
|
|
459
566
|
[
|
|
460
567
|
"gi",
|
|
@@ -476,20 +583,24 @@ const K2 = [
|
|
|
476
583
|
// Grenada
|
|
477
584
|
"1",
|
|
478
585
|
14,
|
|
479
|
-
["473"]
|
|
586
|
+
["473"],
|
|
587
|
+
"1"
|
|
480
588
|
],
|
|
481
589
|
[
|
|
482
590
|
"gp",
|
|
483
591
|
// Guadeloupe
|
|
484
592
|
"590",
|
|
485
|
-
0
|
|
593
|
+
0,
|
|
594
|
+
null,
|
|
595
|
+
"0"
|
|
486
596
|
],
|
|
487
597
|
[
|
|
488
598
|
"gu",
|
|
489
599
|
// Guam
|
|
490
600
|
"1",
|
|
491
601
|
15,
|
|
492
|
-
["671"]
|
|
602
|
+
["671"],
|
|
603
|
+
"1"
|
|
493
604
|
],
|
|
494
605
|
[
|
|
495
606
|
"gt",
|
|
@@ -537,7 +648,10 @@ const K2 = [
|
|
|
537
648
|
[
|
|
538
649
|
"hu",
|
|
539
650
|
// Hungary
|
|
540
|
-
"36"
|
|
651
|
+
"36",
|
|
652
|
+
0,
|
|
653
|
+
null,
|
|
654
|
+
"06"
|
|
541
655
|
],
|
|
542
656
|
[
|
|
543
657
|
"is",
|
|
@@ -547,58 +661,82 @@ const K2 = [
|
|
|
547
661
|
[
|
|
548
662
|
"in",
|
|
549
663
|
// India
|
|
550
|
-
"91"
|
|
664
|
+
"91",
|
|
665
|
+
0,
|
|
666
|
+
null,
|
|
667
|
+
"0"
|
|
551
668
|
],
|
|
552
669
|
[
|
|
553
670
|
"id",
|
|
554
671
|
// Indonesia
|
|
555
|
-
"62"
|
|
672
|
+
"62",
|
|
673
|
+
0,
|
|
674
|
+
null,
|
|
675
|
+
"0"
|
|
556
676
|
],
|
|
557
677
|
[
|
|
558
678
|
"ir",
|
|
559
679
|
// Iran
|
|
560
|
-
"98"
|
|
680
|
+
"98",
|
|
681
|
+
0,
|
|
682
|
+
null,
|
|
683
|
+
"0"
|
|
561
684
|
],
|
|
562
685
|
[
|
|
563
686
|
"iq",
|
|
564
687
|
// Iraq
|
|
565
|
-
"964"
|
|
688
|
+
"964",
|
|
689
|
+
0,
|
|
690
|
+
null,
|
|
691
|
+
"0"
|
|
566
692
|
],
|
|
567
693
|
[
|
|
568
694
|
"ie",
|
|
569
695
|
// Ireland
|
|
570
|
-
"353"
|
|
696
|
+
"353",
|
|
697
|
+
0,
|
|
698
|
+
null,
|
|
699
|
+
"0"
|
|
571
700
|
],
|
|
572
701
|
[
|
|
573
702
|
"im",
|
|
574
703
|
// Isle of Man
|
|
575
704
|
"44",
|
|
576
705
|
2,
|
|
577
|
-
["1624", "74576", "7524", "
|
|
706
|
+
["1624", "74576", "7524", "7624", "7924"],
|
|
578
707
|
"0"
|
|
579
708
|
],
|
|
580
709
|
[
|
|
581
710
|
"il",
|
|
582
711
|
// Israel
|
|
583
|
-
"972"
|
|
712
|
+
"972",
|
|
713
|
+
0,
|
|
714
|
+
null,
|
|
715
|
+
"0"
|
|
584
716
|
],
|
|
585
717
|
[
|
|
586
718
|
"it",
|
|
587
719
|
// Italy
|
|
588
720
|
"39",
|
|
589
|
-
0
|
|
721
|
+
0,
|
|
722
|
+
["3"]
|
|
723
|
+
// (mobile range shared with VA)
|
|
590
724
|
],
|
|
591
725
|
[
|
|
592
726
|
"jm",
|
|
593
727
|
// Jamaica
|
|
594
728
|
"1",
|
|
595
729
|
4,
|
|
596
|
-
["
|
|
730
|
+
["658", "876"],
|
|
731
|
+
"1"
|
|
597
732
|
],
|
|
598
733
|
[
|
|
599
734
|
"jp",
|
|
600
735
|
// Japan
|
|
601
|
-
"81"
|
|
736
|
+
"81",
|
|
737
|
+
0,
|
|
738
|
+
null,
|
|
739
|
+
"0"
|
|
602
740
|
],
|
|
603
741
|
[
|
|
604
742
|
"je",
|
|
@@ -611,7 +749,10 @@ const K2 = [
|
|
|
611
749
|
[
|
|
612
750
|
"jo",
|
|
613
751
|
// Jordan
|
|
614
|
-
"962"
|
|
752
|
+
"962",
|
|
753
|
+
0,
|
|
754
|
+
null,
|
|
755
|
+
"0"
|
|
615
756
|
],
|
|
616
757
|
[
|
|
617
758
|
"kz",
|
|
@@ -619,22 +760,32 @@ const K2 = [
|
|
|
619
760
|
"7",
|
|
620
761
|
1,
|
|
621
762
|
["33", "7"],
|
|
763
|
+
// (33 is shared with RU)
|
|
622
764
|
"8"
|
|
623
765
|
],
|
|
624
766
|
[
|
|
625
767
|
"ke",
|
|
626
768
|
// Kenya
|
|
627
|
-
"254"
|
|
769
|
+
"254",
|
|
770
|
+
0,
|
|
771
|
+
null,
|
|
772
|
+
"0"
|
|
628
773
|
],
|
|
629
774
|
[
|
|
630
775
|
"ki",
|
|
631
776
|
// Kiribati
|
|
632
|
-
"686"
|
|
777
|
+
"686",
|
|
778
|
+
0,
|
|
779
|
+
null,
|
|
780
|
+
"0"
|
|
633
781
|
],
|
|
634
782
|
[
|
|
635
783
|
"xk",
|
|
636
784
|
// Kosovo
|
|
637
|
-
"383"
|
|
785
|
+
"383",
|
|
786
|
+
0,
|
|
787
|
+
null,
|
|
788
|
+
"0"
|
|
638
789
|
],
|
|
639
790
|
[
|
|
640
791
|
"kw",
|
|
@@ -644,12 +795,18 @@ const K2 = [
|
|
|
644
795
|
[
|
|
645
796
|
"kg",
|
|
646
797
|
// Kyrgyzstan
|
|
647
|
-
"996"
|
|
798
|
+
"996",
|
|
799
|
+
0,
|
|
800
|
+
null,
|
|
801
|
+
"0"
|
|
648
802
|
],
|
|
649
803
|
[
|
|
650
804
|
"la",
|
|
651
805
|
// Laos
|
|
652
|
-
"856"
|
|
806
|
+
"856",
|
|
807
|
+
0,
|
|
808
|
+
null,
|
|
809
|
+
"0"
|
|
653
810
|
],
|
|
654
811
|
[
|
|
655
812
|
"lv",
|
|
@@ -659,7 +816,10 @@ const K2 = [
|
|
|
659
816
|
[
|
|
660
817
|
"lb",
|
|
661
818
|
// Lebanon
|
|
662
|
-
"961"
|
|
819
|
+
"961",
|
|
820
|
+
0,
|
|
821
|
+
null,
|
|
822
|
+
"0"
|
|
663
823
|
],
|
|
664
824
|
[
|
|
665
825
|
"ls",
|
|
@@ -669,22 +829,34 @@ const K2 = [
|
|
|
669
829
|
[
|
|
670
830
|
"lr",
|
|
671
831
|
// Liberia
|
|
672
|
-
"231"
|
|
832
|
+
"231",
|
|
833
|
+
0,
|
|
834
|
+
null,
|
|
835
|
+
"0"
|
|
673
836
|
],
|
|
674
837
|
[
|
|
675
838
|
"ly",
|
|
676
839
|
// Libya
|
|
677
|
-
"218"
|
|
840
|
+
"218",
|
|
841
|
+
0,
|
|
842
|
+
null,
|
|
843
|
+
"0"
|
|
678
844
|
],
|
|
679
845
|
[
|
|
680
846
|
"li",
|
|
681
847
|
// Liechtenstein
|
|
682
|
-
"423"
|
|
848
|
+
"423",
|
|
849
|
+
0,
|
|
850
|
+
null,
|
|
851
|
+
"0"
|
|
683
852
|
],
|
|
684
853
|
[
|
|
685
854
|
"lt",
|
|
686
855
|
// Lithuania
|
|
687
|
-
"370"
|
|
856
|
+
"370",
|
|
857
|
+
0,
|
|
858
|
+
null,
|
|
859
|
+
"0"
|
|
688
860
|
],
|
|
689
861
|
[
|
|
690
862
|
"lu",
|
|
@@ -699,17 +871,26 @@ const K2 = [
|
|
|
699
871
|
[
|
|
700
872
|
"mg",
|
|
701
873
|
// Madagascar
|
|
702
|
-
"261"
|
|
874
|
+
"261",
|
|
875
|
+
0,
|
|
876
|
+
null,
|
|
877
|
+
"0"
|
|
703
878
|
],
|
|
704
879
|
[
|
|
705
880
|
"mw",
|
|
706
881
|
// Malawi
|
|
707
|
-
"265"
|
|
882
|
+
"265",
|
|
883
|
+
0,
|
|
884
|
+
null,
|
|
885
|
+
"0"
|
|
708
886
|
],
|
|
709
887
|
[
|
|
710
888
|
"my",
|
|
711
889
|
// Malaysia
|
|
712
|
-
"60"
|
|
890
|
+
"60",
|
|
891
|
+
0,
|
|
892
|
+
null,
|
|
893
|
+
"0"
|
|
713
894
|
],
|
|
714
895
|
[
|
|
715
896
|
"mv",
|
|
@@ -729,12 +910,18 @@ const K2 = [
|
|
|
729
910
|
[
|
|
730
911
|
"mh",
|
|
731
912
|
// Marshall Islands
|
|
732
|
-
"692"
|
|
913
|
+
"692",
|
|
914
|
+
0,
|
|
915
|
+
null,
|
|
916
|
+
"1"
|
|
733
917
|
],
|
|
734
918
|
[
|
|
735
919
|
"mq",
|
|
736
920
|
// Martinique
|
|
737
|
-
"596"
|
|
921
|
+
"596",
|
|
922
|
+
0,
|
|
923
|
+
null,
|
|
924
|
+
"0"
|
|
738
925
|
],
|
|
739
926
|
[
|
|
740
927
|
"mr",
|
|
@@ -767,36 +954,50 @@ const K2 = [
|
|
|
767
954
|
[
|
|
768
955
|
"md",
|
|
769
956
|
// Moldova
|
|
770
|
-
"373"
|
|
957
|
+
"373",
|
|
958
|
+
0,
|
|
959
|
+
null,
|
|
960
|
+
"0"
|
|
771
961
|
],
|
|
772
962
|
[
|
|
773
963
|
"mc",
|
|
774
964
|
// Monaco
|
|
775
|
-
"377"
|
|
965
|
+
"377",
|
|
966
|
+
0,
|
|
967
|
+
null,
|
|
968
|
+
"0"
|
|
776
969
|
],
|
|
777
970
|
[
|
|
778
971
|
"mn",
|
|
779
972
|
// Mongolia
|
|
780
|
-
"976"
|
|
973
|
+
"976",
|
|
974
|
+
0,
|
|
975
|
+
null,
|
|
976
|
+
"0"
|
|
781
977
|
],
|
|
782
978
|
[
|
|
783
979
|
"me",
|
|
784
980
|
// Montenegro
|
|
785
|
-
"382"
|
|
981
|
+
"382",
|
|
982
|
+
0,
|
|
983
|
+
null,
|
|
984
|
+
"0"
|
|
786
985
|
],
|
|
787
986
|
[
|
|
788
987
|
"ms",
|
|
789
988
|
// Montserrat
|
|
790
989
|
"1",
|
|
791
990
|
16,
|
|
792
|
-
["664"]
|
|
991
|
+
["664"],
|
|
992
|
+
"1"
|
|
793
993
|
],
|
|
794
994
|
[
|
|
795
995
|
"ma",
|
|
796
996
|
// Morocco
|
|
797
997
|
"212",
|
|
798
998
|
0,
|
|
799
|
-
|
|
999
|
+
["6", "7"],
|
|
1000
|
+
// (mobile ranges shared with EH)
|
|
800
1001
|
"0"
|
|
801
1002
|
],
|
|
802
1003
|
[
|
|
@@ -807,12 +1008,18 @@ const K2 = [
|
|
|
807
1008
|
[
|
|
808
1009
|
"mm",
|
|
809
1010
|
// Myanmar (Burma)
|
|
810
|
-
"95"
|
|
1011
|
+
"95",
|
|
1012
|
+
0,
|
|
1013
|
+
null,
|
|
1014
|
+
"0"
|
|
811
1015
|
],
|
|
812
1016
|
[
|
|
813
1017
|
"na",
|
|
814
1018
|
// Namibia
|
|
815
|
-
"264"
|
|
1019
|
+
"264",
|
|
1020
|
+
0,
|
|
1021
|
+
null,
|
|
1022
|
+
"0"
|
|
816
1023
|
],
|
|
817
1024
|
[
|
|
818
1025
|
"nr",
|
|
@@ -822,12 +1029,18 @@ const K2 = [
|
|
|
822
1029
|
[
|
|
823
1030
|
"np",
|
|
824
1031
|
// Nepal
|
|
825
|
-
"977"
|
|
1032
|
+
"977",
|
|
1033
|
+
0,
|
|
1034
|
+
null,
|
|
1035
|
+
"0"
|
|
826
1036
|
],
|
|
827
1037
|
[
|
|
828
1038
|
"nl",
|
|
829
1039
|
// Netherlands
|
|
830
|
-
"31"
|
|
1040
|
+
"31",
|
|
1041
|
+
0,
|
|
1042
|
+
null,
|
|
1043
|
+
"0"
|
|
831
1044
|
],
|
|
832
1045
|
[
|
|
833
1046
|
"nc",
|
|
@@ -837,7 +1050,10 @@ const K2 = [
|
|
|
837
1050
|
[
|
|
838
1051
|
"nz",
|
|
839
1052
|
// New Zealand
|
|
840
|
-
"64"
|
|
1053
|
+
"64",
|
|
1054
|
+
0,
|
|
1055
|
+
null,
|
|
1056
|
+
"0"
|
|
841
1057
|
],
|
|
842
1058
|
[
|
|
843
1059
|
"ni",
|
|
@@ -852,7 +1068,10 @@ const K2 = [
|
|
|
852
1068
|
[
|
|
853
1069
|
"ng",
|
|
854
1070
|
// Nigeria
|
|
855
|
-
"234"
|
|
1071
|
+
"234",
|
|
1072
|
+
0,
|
|
1073
|
+
null,
|
|
1074
|
+
"0"
|
|
856
1075
|
],
|
|
857
1076
|
[
|
|
858
1077
|
"nu",
|
|
@@ -867,25 +1086,34 @@ const K2 = [
|
|
|
867
1086
|
[
|
|
868
1087
|
"kp",
|
|
869
1088
|
// North Korea
|
|
870
|
-
"850"
|
|
1089
|
+
"850",
|
|
1090
|
+
0,
|
|
1091
|
+
null,
|
|
1092
|
+
"0"
|
|
871
1093
|
],
|
|
872
1094
|
[
|
|
873
1095
|
"mk",
|
|
874
1096
|
// North Macedonia
|
|
875
|
-
"389"
|
|
1097
|
+
"389",
|
|
1098
|
+
0,
|
|
1099
|
+
null,
|
|
1100
|
+
"0"
|
|
876
1101
|
],
|
|
877
1102
|
[
|
|
878
1103
|
"mp",
|
|
879
1104
|
// Northern Mariana Islands
|
|
880
1105
|
"1",
|
|
881
1106
|
17,
|
|
882
|
-
["670"]
|
|
1107
|
+
["670"],
|
|
1108
|
+
"1"
|
|
883
1109
|
],
|
|
884
1110
|
[
|
|
885
1111
|
"no",
|
|
886
1112
|
// Norway
|
|
887
1113
|
"47",
|
|
888
|
-
0
|
|
1114
|
+
0,
|
|
1115
|
+
["4", "9"]
|
|
1116
|
+
// (mobile ranges shared with SJ)
|
|
889
1117
|
],
|
|
890
1118
|
[
|
|
891
1119
|
"om",
|
|
@@ -895,7 +1123,10 @@ const K2 = [
|
|
|
895
1123
|
[
|
|
896
1124
|
"pk",
|
|
897
1125
|
// Pakistan
|
|
898
|
-
"92"
|
|
1126
|
+
"92",
|
|
1127
|
+
0,
|
|
1128
|
+
null,
|
|
1129
|
+
"0"
|
|
899
1130
|
],
|
|
900
1131
|
[
|
|
901
1132
|
"pw",
|
|
@@ -905,7 +1136,10 @@ const K2 = [
|
|
|
905
1136
|
[
|
|
906
1137
|
"ps",
|
|
907
1138
|
// Palestinian Territories
|
|
908
|
-
"970"
|
|
1139
|
+
"970",
|
|
1140
|
+
0,
|
|
1141
|
+
null,
|
|
1142
|
+
"0"
|
|
909
1143
|
],
|
|
910
1144
|
[
|
|
911
1145
|
"pa",
|
|
@@ -920,17 +1154,26 @@ const K2 = [
|
|
|
920
1154
|
[
|
|
921
1155
|
"py",
|
|
922
1156
|
// Paraguay
|
|
923
|
-
"595"
|
|
1157
|
+
"595",
|
|
1158
|
+
0,
|
|
1159
|
+
null,
|
|
1160
|
+
"0"
|
|
924
1161
|
],
|
|
925
1162
|
[
|
|
926
1163
|
"pe",
|
|
927
1164
|
// Peru
|
|
928
|
-
"51"
|
|
1165
|
+
"51",
|
|
1166
|
+
0,
|
|
1167
|
+
null,
|
|
1168
|
+
"0"
|
|
929
1169
|
],
|
|
930
1170
|
[
|
|
931
1171
|
"ph",
|
|
932
1172
|
// Philippines
|
|
933
|
-
"63"
|
|
1173
|
+
"63",
|
|
1174
|
+
0,
|
|
1175
|
+
null,
|
|
1176
|
+
"0"
|
|
934
1177
|
],
|
|
935
1178
|
[
|
|
936
1179
|
"pl",
|
|
@@ -947,7 +1190,8 @@ const K2 = [
|
|
|
947
1190
|
// Puerto Rico
|
|
948
1191
|
"1",
|
|
949
1192
|
3,
|
|
950
|
-
["787", "939"]
|
|
1193
|
+
["787", "939"],
|
|
1194
|
+
"1"
|
|
951
1195
|
],
|
|
952
1196
|
[
|
|
953
1197
|
"qa",
|
|
@@ -965,20 +1209,27 @@ const K2 = [
|
|
|
965
1209
|
[
|
|
966
1210
|
"ro",
|
|
967
1211
|
// Romania
|
|
968
|
-
"40"
|
|
1212
|
+
"40",
|
|
1213
|
+
0,
|
|
1214
|
+
null,
|
|
1215
|
+
"0"
|
|
969
1216
|
],
|
|
970
1217
|
[
|
|
971
1218
|
"ru",
|
|
972
1219
|
// Russia
|
|
973
1220
|
"7",
|
|
974
1221
|
0,
|
|
975
|
-
|
|
1222
|
+
["33"],
|
|
1223
|
+
// (shared with KZ)
|
|
976
1224
|
"8"
|
|
977
1225
|
],
|
|
978
1226
|
[
|
|
979
1227
|
"rw",
|
|
980
1228
|
// Rwanda
|
|
981
|
-
"250"
|
|
1229
|
+
"250",
|
|
1230
|
+
0,
|
|
1231
|
+
null,
|
|
1232
|
+
"0"
|
|
982
1233
|
],
|
|
983
1234
|
[
|
|
984
1235
|
"ws",
|
|
@@ -998,7 +1249,10 @@ const K2 = [
|
|
|
998
1249
|
[
|
|
999
1250
|
"sa",
|
|
1000
1251
|
// Saudi Arabia
|
|
1001
|
-
"966"
|
|
1252
|
+
"966",
|
|
1253
|
+
0,
|
|
1254
|
+
null,
|
|
1255
|
+
"0"
|
|
1002
1256
|
],
|
|
1003
1257
|
[
|
|
1004
1258
|
"sn",
|
|
@@ -1008,7 +1262,10 @@ const K2 = [
|
|
|
1008
1262
|
[
|
|
1009
1263
|
"rs",
|
|
1010
1264
|
// Serbia
|
|
1011
|
-
"381"
|
|
1265
|
+
"381",
|
|
1266
|
+
0,
|
|
1267
|
+
null,
|
|
1268
|
+
"0"
|
|
1012
1269
|
],
|
|
1013
1270
|
[
|
|
1014
1271
|
"sc",
|
|
@@ -1018,7 +1275,10 @@ const K2 = [
|
|
|
1018
1275
|
[
|
|
1019
1276
|
"sl",
|
|
1020
1277
|
// Sierra Leone
|
|
1021
|
-
"232"
|
|
1278
|
+
"232",
|
|
1279
|
+
0,
|
|
1280
|
+
null,
|
|
1281
|
+
"0"
|
|
1022
1282
|
],
|
|
1023
1283
|
[
|
|
1024
1284
|
"sg",
|
|
@@ -1030,17 +1290,24 @@ const K2 = [
|
|
|
1030
1290
|
// Sint Maarten
|
|
1031
1291
|
"1",
|
|
1032
1292
|
21,
|
|
1033
|
-
["721"]
|
|
1293
|
+
["721"],
|
|
1294
|
+
"1"
|
|
1034
1295
|
],
|
|
1035
1296
|
[
|
|
1036
1297
|
"sk",
|
|
1037
1298
|
// Slovakia
|
|
1038
|
-
"421"
|
|
1299
|
+
"421",
|
|
1300
|
+
0,
|
|
1301
|
+
null,
|
|
1302
|
+
"0"
|
|
1039
1303
|
],
|
|
1040
1304
|
[
|
|
1041
1305
|
"si",
|
|
1042
1306
|
// Slovenia
|
|
1043
|
-
"386"
|
|
1307
|
+
"386",
|
|
1308
|
+
0,
|
|
1309
|
+
null,
|
|
1310
|
+
"0"
|
|
1044
1311
|
],
|
|
1045
1312
|
[
|
|
1046
1313
|
"sb",
|
|
@@ -1050,22 +1317,34 @@ const K2 = [
|
|
|
1050
1317
|
[
|
|
1051
1318
|
"so",
|
|
1052
1319
|
// Somalia
|
|
1053
|
-
"252"
|
|
1320
|
+
"252",
|
|
1321
|
+
0,
|
|
1322
|
+
null,
|
|
1323
|
+
"0"
|
|
1054
1324
|
],
|
|
1055
1325
|
[
|
|
1056
1326
|
"za",
|
|
1057
1327
|
// South Africa
|
|
1058
|
-
"27"
|
|
1328
|
+
"27",
|
|
1329
|
+
0,
|
|
1330
|
+
null,
|
|
1331
|
+
"0"
|
|
1059
1332
|
],
|
|
1060
1333
|
[
|
|
1061
1334
|
"kr",
|
|
1062
1335
|
// South Korea
|
|
1063
|
-
"82"
|
|
1336
|
+
"82",
|
|
1337
|
+
0,
|
|
1338
|
+
null,
|
|
1339
|
+
"0"
|
|
1064
1340
|
],
|
|
1065
1341
|
[
|
|
1066
1342
|
"ss",
|
|
1067
1343
|
// South Sudan
|
|
1068
|
-
"211"
|
|
1344
|
+
"211",
|
|
1345
|
+
0,
|
|
1346
|
+
null,
|
|
1347
|
+
"0"
|
|
1069
1348
|
],
|
|
1070
1349
|
[
|
|
1071
1350
|
"es",
|
|
@@ -1075,13 +1354,18 @@ const K2 = [
|
|
|
1075
1354
|
[
|
|
1076
1355
|
"lk",
|
|
1077
1356
|
// Sri Lanka
|
|
1078
|
-
"94"
|
|
1357
|
+
"94",
|
|
1358
|
+
0,
|
|
1359
|
+
null,
|
|
1360
|
+
"0"
|
|
1079
1361
|
],
|
|
1080
1362
|
[
|
|
1081
1363
|
"bl",
|
|
1082
1364
|
// St. Barthélemy
|
|
1083
1365
|
"590",
|
|
1084
|
-
1
|
|
1366
|
+
1,
|
|
1367
|
+
null,
|
|
1368
|
+
"0"
|
|
1085
1369
|
],
|
|
1086
1370
|
[
|
|
1087
1371
|
"sh",
|
|
@@ -1093,37 +1377,48 @@ const K2 = [
|
|
|
1093
1377
|
// St. Kitts & Nevis
|
|
1094
1378
|
"1",
|
|
1095
1379
|
18,
|
|
1096
|
-
["869"]
|
|
1380
|
+
["869"],
|
|
1381
|
+
"1"
|
|
1097
1382
|
],
|
|
1098
1383
|
[
|
|
1099
1384
|
"lc",
|
|
1100
1385
|
// St. Lucia
|
|
1101
1386
|
"1",
|
|
1102
1387
|
19,
|
|
1103
|
-
["758"]
|
|
1388
|
+
["758"],
|
|
1389
|
+
"1"
|
|
1104
1390
|
],
|
|
1105
1391
|
[
|
|
1106
1392
|
"mf",
|
|
1107
1393
|
// St. Martin
|
|
1108
1394
|
"590",
|
|
1109
|
-
2
|
|
1395
|
+
2,
|
|
1396
|
+
null,
|
|
1397
|
+
"0"
|
|
1110
1398
|
],
|
|
1111
1399
|
[
|
|
1112
1400
|
"pm",
|
|
1113
1401
|
// St. Pierre & Miquelon
|
|
1114
|
-
"508"
|
|
1402
|
+
"508",
|
|
1403
|
+
0,
|
|
1404
|
+
null,
|
|
1405
|
+
"0"
|
|
1115
1406
|
],
|
|
1116
1407
|
[
|
|
1117
1408
|
"vc",
|
|
1118
1409
|
// St. Vincent & Grenadines
|
|
1119
1410
|
"1",
|
|
1120
1411
|
20,
|
|
1121
|
-
["784"]
|
|
1412
|
+
["784"],
|
|
1413
|
+
"1"
|
|
1122
1414
|
],
|
|
1123
1415
|
[
|
|
1124
1416
|
"sd",
|
|
1125
1417
|
// Sudan
|
|
1126
|
-
"249"
|
|
1418
|
+
"249",
|
|
1419
|
+
0,
|
|
1420
|
+
null,
|
|
1421
|
+
"0"
|
|
1127
1422
|
],
|
|
1128
1423
|
[
|
|
1129
1424
|
"sr",
|
|
@@ -1135,27 +1430,40 @@ const K2 = [
|
|
|
1135
1430
|
// Svalbard & Jan Mayen
|
|
1136
1431
|
"47",
|
|
1137
1432
|
1,
|
|
1138
|
-
["79"]
|
|
1433
|
+
["4", "79", "9"]
|
|
1434
|
+
// (4 and 9 are mobile ranges shared with NO)
|
|
1139
1435
|
],
|
|
1140
1436
|
[
|
|
1141
1437
|
"se",
|
|
1142
1438
|
// Sweden
|
|
1143
|
-
"46"
|
|
1439
|
+
"46",
|
|
1440
|
+
0,
|
|
1441
|
+
null,
|
|
1442
|
+
"0"
|
|
1144
1443
|
],
|
|
1145
1444
|
[
|
|
1146
1445
|
"ch",
|
|
1147
1446
|
// Switzerland
|
|
1148
|
-
"41"
|
|
1447
|
+
"41",
|
|
1448
|
+
0,
|
|
1449
|
+
null,
|
|
1450
|
+
"0"
|
|
1149
1451
|
],
|
|
1150
1452
|
[
|
|
1151
1453
|
"sy",
|
|
1152
1454
|
// Syria
|
|
1153
|
-
"963"
|
|
1455
|
+
"963",
|
|
1456
|
+
0,
|
|
1457
|
+
null,
|
|
1458
|
+
"0"
|
|
1154
1459
|
],
|
|
1155
1460
|
[
|
|
1156
1461
|
"tw",
|
|
1157
1462
|
// Taiwan
|
|
1158
|
-
"886"
|
|
1463
|
+
"886",
|
|
1464
|
+
0,
|
|
1465
|
+
null,
|
|
1466
|
+
"0"
|
|
1159
1467
|
],
|
|
1160
1468
|
[
|
|
1161
1469
|
"tj",
|
|
@@ -1165,12 +1473,18 @@ const K2 = [
|
|
|
1165
1473
|
[
|
|
1166
1474
|
"tz",
|
|
1167
1475
|
// Tanzania
|
|
1168
|
-
"255"
|
|
1476
|
+
"255",
|
|
1477
|
+
0,
|
|
1478
|
+
null,
|
|
1479
|
+
"0"
|
|
1169
1480
|
],
|
|
1170
1481
|
[
|
|
1171
1482
|
"th",
|
|
1172
1483
|
// Thailand
|
|
1173
|
-
"66"
|
|
1484
|
+
"66",
|
|
1485
|
+
0,
|
|
1486
|
+
null,
|
|
1487
|
+
"0"
|
|
1174
1488
|
],
|
|
1175
1489
|
[
|
|
1176
1490
|
"tl",
|
|
@@ -1197,7 +1511,8 @@ const K2 = [
|
|
|
1197
1511
|
// Trinidad & Tobago
|
|
1198
1512
|
"1",
|
|
1199
1513
|
22,
|
|
1200
|
-
["868"]
|
|
1514
|
+
["868"],
|
|
1515
|
+
"1"
|
|
1201
1516
|
],
|
|
1202
1517
|
[
|
|
1203
1518
|
"tn",
|
|
@@ -1207,19 +1522,26 @@ const K2 = [
|
|
|
1207
1522
|
[
|
|
1208
1523
|
"tr",
|
|
1209
1524
|
// Turkey
|
|
1210
|
-
"90"
|
|
1525
|
+
"90",
|
|
1526
|
+
0,
|
|
1527
|
+
null,
|
|
1528
|
+
"0"
|
|
1211
1529
|
],
|
|
1212
1530
|
[
|
|
1213
1531
|
"tm",
|
|
1214
1532
|
// Turkmenistan
|
|
1215
|
-
"993"
|
|
1533
|
+
"993",
|
|
1534
|
+
0,
|
|
1535
|
+
null,
|
|
1536
|
+
"8"
|
|
1216
1537
|
],
|
|
1217
1538
|
[
|
|
1218
1539
|
"tc",
|
|
1219
1540
|
// Turks & Caicos Islands
|
|
1220
1541
|
"1",
|
|
1221
1542
|
23,
|
|
1222
|
-
["649"]
|
|
1543
|
+
["649"],
|
|
1544
|
+
"1"
|
|
1223
1545
|
],
|
|
1224
1546
|
[
|
|
1225
1547
|
"tv",
|
|
@@ -1231,22 +1553,32 @@ const K2 = [
|
|
|
1231
1553
|
// U.S. Virgin Islands
|
|
1232
1554
|
"1",
|
|
1233
1555
|
24,
|
|
1234
|
-
["340"]
|
|
1556
|
+
["340"],
|
|
1557
|
+
"1"
|
|
1235
1558
|
],
|
|
1236
1559
|
[
|
|
1237
1560
|
"ug",
|
|
1238
1561
|
// Uganda
|
|
1239
|
-
"256"
|
|
1562
|
+
"256",
|
|
1563
|
+
0,
|
|
1564
|
+
null,
|
|
1565
|
+
"0"
|
|
1240
1566
|
],
|
|
1241
1567
|
[
|
|
1242
1568
|
"ua",
|
|
1243
1569
|
// Ukraine
|
|
1244
|
-
"380"
|
|
1570
|
+
"380",
|
|
1571
|
+
0,
|
|
1572
|
+
null,
|
|
1573
|
+
"0"
|
|
1245
1574
|
],
|
|
1246
1575
|
[
|
|
1247
1576
|
"ae",
|
|
1248
1577
|
// United Arab Emirates
|
|
1249
|
-
"971"
|
|
1578
|
+
"971",
|
|
1579
|
+
0,
|
|
1580
|
+
null,
|
|
1581
|
+
"0"
|
|
1250
1582
|
],
|
|
1251
1583
|
[
|
|
1252
1584
|
"gb",
|
|
@@ -1260,12 +1592,17 @@ const K2 = [
|
|
|
1260
1592
|
"us",
|
|
1261
1593
|
// United States
|
|
1262
1594
|
"1",
|
|
1263
|
-
0
|
|
1595
|
+
0,
|
|
1596
|
+
null,
|
|
1597
|
+
"1"
|
|
1264
1598
|
],
|
|
1265
1599
|
[
|
|
1266
1600
|
"uy",
|
|
1267
1601
|
// Uruguay
|
|
1268
|
-
"598"
|
|
1602
|
+
"598",
|
|
1603
|
+
0,
|
|
1604
|
+
null,
|
|
1605
|
+
"0"
|
|
1269
1606
|
],
|
|
1270
1607
|
[
|
|
1271
1608
|
"uz",
|
|
@@ -1282,17 +1619,24 @@ const K2 = [
|
|
|
1282
1619
|
// Vatican City
|
|
1283
1620
|
"39",
|
|
1284
1621
|
1,
|
|
1285
|
-
["06698"]
|
|
1622
|
+
["06698", "3"]
|
|
1623
|
+
// (3 is a mobile range shared with IT)
|
|
1286
1624
|
],
|
|
1287
1625
|
[
|
|
1288
1626
|
"ve",
|
|
1289
1627
|
// Venezuela
|
|
1290
|
-
"58"
|
|
1628
|
+
"58",
|
|
1629
|
+
0,
|
|
1630
|
+
null,
|
|
1631
|
+
"0"
|
|
1291
1632
|
],
|
|
1292
1633
|
[
|
|
1293
1634
|
"vn",
|
|
1294
1635
|
// Vietnam
|
|
1295
|
-
"84"
|
|
1636
|
+
"84",
|
|
1637
|
+
0,
|
|
1638
|
+
null,
|
|
1639
|
+
"0"
|
|
1296
1640
|
],
|
|
1297
1641
|
[
|
|
1298
1642
|
"wf",
|
|
@@ -1304,27 +1648,37 @@ const K2 = [
|
|
|
1304
1648
|
// Western Sahara
|
|
1305
1649
|
"212",
|
|
1306
1650
|
1,
|
|
1307
|
-
["5288", "5289"],
|
|
1651
|
+
["5288", "5289", "6", "7"],
|
|
1652
|
+
// (6 and 7 are mobile ranges shared with MA)
|
|
1308
1653
|
"0"
|
|
1309
1654
|
],
|
|
1310
1655
|
[
|
|
1311
1656
|
"ye",
|
|
1312
1657
|
// Yemen
|
|
1313
|
-
"967"
|
|
1658
|
+
"967",
|
|
1659
|
+
0,
|
|
1660
|
+
null,
|
|
1661
|
+
"0"
|
|
1314
1662
|
],
|
|
1315
1663
|
[
|
|
1316
1664
|
"zm",
|
|
1317
1665
|
// Zambia
|
|
1318
|
-
"260"
|
|
1666
|
+
"260",
|
|
1667
|
+
0,
|
|
1668
|
+
null,
|
|
1669
|
+
"0"
|
|
1319
1670
|
],
|
|
1320
1671
|
[
|
|
1321
1672
|
"zw",
|
|
1322
1673
|
// Zimbabwe
|
|
1323
|
-
"263"
|
|
1674
|
+
"263",
|
|
1675
|
+
0,
|
|
1676
|
+
null,
|
|
1677
|
+
"0"
|
|
1324
1678
|
]
|
|
1325
|
-
],
|
|
1326
|
-
for (const f of
|
|
1327
|
-
|
|
1679
|
+
], Y = [];
|
|
1680
|
+
for (const f of K0)
|
|
1681
|
+
Y.push({
|
|
1328
1682
|
name: "",
|
|
1329
1683
|
// populated in the plugin
|
|
1330
1684
|
iso2: f[0],
|
|
@@ -1335,7 +1689,7 @@ for (const f of K2)
|
|
|
1335
1689
|
// populated by the plugin
|
|
1336
1690
|
nationalPrefix: f[4] || null
|
|
1337
1691
|
});
|
|
1338
|
-
const
|
|
1692
|
+
const V0 = {
|
|
1339
1693
|
ad: "Andorra",
|
|
1340
1694
|
ae: "United Arab Emirates",
|
|
1341
1695
|
af: "Afghanistan",
|
|
@@ -1578,7 +1932,7 @@ const V2 = {
|
|
|
1578
1932
|
za: "South Africa",
|
|
1579
1933
|
zm: "Zambia",
|
|
1580
1934
|
zw: "Zimbabwe"
|
|
1581
|
-
},
|
|
1935
|
+
}, H0 = {
|
|
1582
1936
|
selectedCountryAriaLabel: "Change country, selected ${countryName} (${dialCode})",
|
|
1583
1937
|
noCountrySelected: "Select country",
|
|
1584
1938
|
countryListAriaLabel: "List of countries",
|
|
@@ -1590,13 +1944,13 @@ const V2 = {
|
|
|
1590
1944
|
// additional countries (not supported by country-list library)
|
|
1591
1945
|
ac: "Ascension Island",
|
|
1592
1946
|
xk: "Kosovo"
|
|
1593
|
-
},
|
|
1947
|
+
}, l0 = { ...V0, ...H0 }, v1 = (f) => typeof window < "u" && typeof window.matchMedia == "function" && window.matchMedia(f).matches, j0 = () => {
|
|
1594
1948
|
if (typeof navigator < "u" && typeof window < "u") {
|
|
1595
1949
|
const f = /Android.+Mobile|webOS|iPhone|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent), e = v1("(max-width: 500px)"), $ = v1("(max-height: 600px)"), i = v1("(pointer: coarse)");
|
|
1596
1950
|
return f || e || i && $;
|
|
1597
1951
|
}
|
|
1598
1952
|
return !1;
|
|
1599
|
-
},
|
|
1953
|
+
}, u0 = {
|
|
1600
1954
|
// Allow alphanumeric "phonewords" (e.g. +1 800 FLOWERS) as valid numbers
|
|
1601
1955
|
allowPhonewords: !1,
|
|
1602
1956
|
//* Whether or not to allow the dropdown.
|
|
@@ -1644,106 +1998,112 @@ const V2 = {
|
|
|
1644
1998
|
//* Only allow certain chars e.g. a plus followed by numeric digits, and cap at max valid length.
|
|
1645
1999
|
strictMode: !1,
|
|
1646
2000
|
//* Use full screen popup instead of dropdown for country list.
|
|
1647
|
-
useFullscreenPopup:
|
|
2001
|
+
useFullscreenPopup: j0(),
|
|
1648
2002
|
//* The number type to enforce during validation.
|
|
1649
2003
|
validationNumberTypes: ["MOBILE"]
|
|
1650
2004
|
};
|
|
1651
|
-
function
|
|
1652
|
-
f.useFullscreenPopup && (f.fixDropdownWidth = !1), f.onlyCountries.length === 1 && (f.initialCountry = f.onlyCountries[0]), f.separateDialCode && (f.nationalMode = !1), f.allowDropdown && !f.showFlags && !f.separateDialCode && (f.nationalMode = !1), f.useFullscreenPopup && !f.dropdownContainer && (f.dropdownContainer = document.body), f.i18n = { ...
|
|
2005
|
+
function W0(f) {
|
|
2006
|
+
f.useFullscreenPopup && (f.fixDropdownWidth = !1), f.onlyCountries.length === 1 && (f.initialCountry = f.onlyCountries[0]), f.separateDialCode && (f.nationalMode = !1), f.allowDropdown && !f.showFlags && !f.separateDialCode && (f.nationalMode = !1), f.useFullscreenPopup && !f.dropdownContainer && (f.dropdownContainer = document.body), f.i18n = { ...l0, ...f.i18n };
|
|
1653
2007
|
}
|
|
1654
|
-
const
|
|
2008
|
+
const c1 = (f) => f.replace(/\D/g, ""), a0 = (f = "") => f.normalize("NFD").replace(/[\u0300-\u036f]/g, "").toLowerCase(), L = (f, e, $) => {
|
|
1655
2009
|
const i = document.createElement(f);
|
|
1656
|
-
return e && Object.entries(e).forEach(([
|
|
2010
|
+
return e && Object.entries(e).forEach(([r, u]) => i.setAttribute(r, u)), $ && $.appendChild(i), i;
|
|
1657
2011
|
};
|
|
1658
|
-
function
|
|
2012
|
+
function z0(f) {
|
|
1659
2013
|
const { onlyCountries: e, excludeCountries: $ } = f;
|
|
1660
2014
|
if (e.length) {
|
|
1661
|
-
const i = e.map((
|
|
1662
|
-
return
|
|
2015
|
+
const i = e.map((r) => r.toLowerCase());
|
|
2016
|
+
return Y.filter((r) => i.includes(r.iso2));
|
|
1663
2017
|
} else if ($.length) {
|
|
1664
|
-
const i = $.map((
|
|
1665
|
-
return
|
|
2018
|
+
const i = $.map((r) => r.toLowerCase());
|
|
2019
|
+
return Y.filter((r) => !i.includes(r.iso2));
|
|
1666
2020
|
}
|
|
1667
|
-
return
|
|
2021
|
+
return Y;
|
|
1668
2022
|
}
|
|
1669
|
-
function
|
|
2023
|
+
function Z0(f, e) {
|
|
1670
2024
|
for (const $ of f) {
|
|
1671
2025
|
const i = $.iso2.toLowerCase();
|
|
1672
2026
|
e.i18n[i] && ($.name = e.i18n[i]);
|
|
1673
2027
|
}
|
|
1674
2028
|
}
|
|
1675
|
-
function
|
|
2029
|
+
function Y0(f, e) {
|
|
1676
2030
|
const $ = /* @__PURE__ */ new Set();
|
|
1677
2031
|
let i = 0;
|
|
1678
|
-
const
|
|
2032
|
+
const r = {}, u = (h, c, C) => {
|
|
1679
2033
|
if (!h || !c)
|
|
1680
2034
|
return;
|
|
1681
|
-
c.length > i && (i = c.length),
|
|
1682
|
-
const g =
|
|
2035
|
+
c.length > i && (i = c.length), r.hasOwnProperty(c) || (r[c] = []);
|
|
2036
|
+
const g = r[c];
|
|
1683
2037
|
if (g.includes(h))
|
|
1684
2038
|
return;
|
|
1685
2039
|
const I = C !== void 0 ? C : g.length;
|
|
1686
2040
|
g[I] = h;
|
|
1687
2041
|
};
|
|
1688
|
-
for (const h of f)
|
|
1689
|
-
$.has(h.dialCode) || $.add(h.dialCode)
|
|
2042
|
+
for (const h of f) {
|
|
2043
|
+
$.has(h.dialCode) || $.add(h.dialCode);
|
|
2044
|
+
for (let c = 1; c < h.dialCode.length; c++) {
|
|
2045
|
+
const C = h.dialCode.substring(0, c);
|
|
2046
|
+
u(h.iso2, C);
|
|
2047
|
+
}
|
|
2048
|
+
u(h.iso2, h.dialCode, h.priority);
|
|
2049
|
+
}
|
|
1690
2050
|
(e.onlyCountries.length || e.excludeCountries.length) && $.forEach((h) => {
|
|
1691
|
-
|
|
2051
|
+
r[h] = r[h].filter(Boolean);
|
|
1692
2052
|
});
|
|
1693
2053
|
for (const h of f)
|
|
1694
2054
|
if (h.areaCodes) {
|
|
1695
|
-
const c =
|
|
2055
|
+
const c = r[h.dialCode][0];
|
|
1696
2056
|
for (const C of h.areaCodes) {
|
|
1697
2057
|
for (let g = 1; g < C.length; g++) {
|
|
1698
|
-
const I = C.substring(0, g),
|
|
1699
|
-
u(c,
|
|
2058
|
+
const I = C.substring(0, g), w = h.dialCode + I;
|
|
2059
|
+
u(c, w), u(h.iso2, w);
|
|
1700
2060
|
}
|
|
1701
2061
|
u(h.iso2, h.dialCode + C);
|
|
1702
2062
|
}
|
|
1703
2063
|
}
|
|
1704
|
-
return { dialCodes: $, dialCodeMaxLen: i, dialCodeToIso2Map:
|
|
2064
|
+
return { dialCodes: $, dialCodeMaxLen: i, dialCodeToIso2Map: r };
|
|
1705
2065
|
}
|
|
1706
|
-
function
|
|
2066
|
+
function J0(f, e) {
|
|
1707
2067
|
e.countryOrder && (e.countryOrder = e.countryOrder.map(($) => $.toLowerCase())), f.sort(($, i) => {
|
|
1708
|
-
const { countryOrder:
|
|
1709
|
-
if (
|
|
1710
|
-
const u =
|
|
2068
|
+
const { countryOrder: r } = e;
|
|
2069
|
+
if (r) {
|
|
2070
|
+
const u = r.indexOf($.iso2), h = r.indexOf(i.iso2), c = u > -1, C = h > -1;
|
|
1711
2071
|
if (c || C)
|
|
1712
2072
|
return c && C ? u - h : c ? -1 : 1;
|
|
1713
2073
|
}
|
|
1714
2074
|
return $.name.localeCompare(i.name);
|
|
1715
2075
|
});
|
|
1716
2076
|
}
|
|
1717
|
-
function
|
|
2077
|
+
function q0(f) {
|
|
1718
2078
|
for (const e of f)
|
|
1719
|
-
e.normalisedName =
|
|
2079
|
+
e.normalisedName = a0(e.name), e.initials = e.name.split(/[^a-zA-ZÀ-ÿа-яА-Я]/).map(($) => $[0]).join("").toLowerCase(), e.dialCodePlus = `+${e.dialCode}`;
|
|
1720
2080
|
}
|
|
1721
|
-
function
|
|
1722
|
-
let
|
|
2081
|
+
function X0(f, e, $, i) {
|
|
2082
|
+
let r = f;
|
|
1723
2083
|
if ($ && e) {
|
|
1724
2084
|
e = `+${i.dialCode}`;
|
|
1725
|
-
const u =
|
|
1726
|
-
|
|
2085
|
+
const u = r[e.length] === " " || r[e.length] === "-" ? e.length + 1 : e.length;
|
|
2086
|
+
r = r.substring(u);
|
|
1727
2087
|
}
|
|
1728
|
-
return
|
|
2088
|
+
return r;
|
|
1729
2089
|
}
|
|
1730
|
-
function
|
|
2090
|
+
function Q0(f, e, $, i, r) {
|
|
1731
2091
|
const u = $ ? $.formatNumberAsYouType(f, i.iso2) : f, { dialCode: h } = i;
|
|
1732
|
-
return
|
|
2092
|
+
return r && e.charAt(0) !== "+" && u.includes(`+${h}`) ? (u.split(`+${h}`)[1] || "").trim() : u;
|
|
1733
2093
|
}
|
|
1734
|
-
function
|
|
2094
|
+
function d2(f, e, $, i) {
|
|
1735
2095
|
if ($ === 0 && !i)
|
|
1736
2096
|
return 0;
|
|
1737
|
-
let
|
|
2097
|
+
let r = 0;
|
|
1738
2098
|
for (let u = 0; u < e.length; u++) {
|
|
1739
|
-
if (/[+0-9]/.test(e[u]) &&
|
|
2099
|
+
if (/[+0-9]/.test(e[u]) && r++, r === f && !i)
|
|
1740
2100
|
return u + 1;
|
|
1741
|
-
if (i &&
|
|
2101
|
+
if (i && r === f + 1)
|
|
1742
2102
|
return u;
|
|
1743
2103
|
}
|
|
1744
2104
|
return e.length;
|
|
1745
2105
|
}
|
|
1746
|
-
const
|
|
2106
|
+
const t2 = [
|
|
1747
2107
|
"800",
|
|
1748
2108
|
"822",
|
|
1749
2109
|
"833",
|
|
@@ -1761,22 +2121,22 @@ const t0 = [
|
|
|
1761
2121
|
"887",
|
|
1762
2122
|
"888",
|
|
1763
2123
|
"889"
|
|
1764
|
-
],
|
|
1765
|
-
const e =
|
|
2124
|
+
], o0 = (f) => {
|
|
2125
|
+
const e = c1(f);
|
|
1766
2126
|
if (e.charAt(0) === "1") {
|
|
1767
2127
|
const $ = e.substring(1, 4);
|
|
1768
|
-
return
|
|
2128
|
+
return t2.includes($);
|
|
1769
2129
|
}
|
|
1770
2130
|
return !1;
|
|
1771
2131
|
};
|
|
1772
|
-
for (const f of
|
|
1773
|
-
f.name =
|
|
1774
|
-
let
|
|
1775
|
-
const $
|
|
2132
|
+
for (const f of Y)
|
|
2133
|
+
f.name = l0[f.iso2];
|
|
2134
|
+
let e2 = 0;
|
|
2135
|
+
const $2 = new Set(Y.map((f) => f.iso2)), w1 = (f) => $2.has(f), $1 = (f, ...e) => {
|
|
1776
2136
|
const { instances: $ } = y;
|
|
1777
2137
|
Object.values($).forEach((i) => i[f](...e));
|
|
1778
2138
|
};
|
|
1779
|
-
class
|
|
2139
|
+
class f1 {
|
|
1780
2140
|
/**
|
|
1781
2141
|
* Build a space-delimited class string from an object map of className -> truthy/falsey.
|
|
1782
2142
|
* Only keys with truthy values are included.
|
|
@@ -1785,33 +2145,31 @@ class c1 {
|
|
|
1785
2145
|
return Object.keys(e).filter(($) => !!e[$]).join(" ");
|
|
1786
2146
|
}
|
|
1787
2147
|
constructor(e, $ = {}) {
|
|
1788
|
-
this.id =
|
|
2148
|
+
this.id = e2++, this.telInput = e, this.highlightedItem = null, this.options = Object.assign({}, u0, $), this.hadInitialPlaceholder = !!e.getAttribute("placeholder");
|
|
1789
2149
|
}
|
|
1790
2150
|
_detectEnvironmentAndLayout() {
|
|
1791
|
-
this.isAndroid = typeof navigator < "u" ? /Android/i.test(navigator.userAgent) : !1, this.isRTL = !!this.telInput.closest("[dir=rtl]"), this.
|
|
1792
|
-
const e = this.options.allowDropdown || this.options.separateDialCode;
|
|
1793
|
-
this.showSelectedCountryOnLeft = this.isRTL ? !e : e, this.options.separateDialCode && (this.isRTL ? this.originalPaddingRight = this.telInput.style.paddingRight : this.originalPaddingLeft = this.telInput.style.paddingLeft);
|
|
2151
|
+
this.isAndroid = typeof navigator < "u" ? /Android/i.test(navigator.userAgent) : !1, this.isRTL = !!this.telInput.closest("[dir=rtl]"), this.options.separateDialCode && (this.originalPaddingLeft = this.telInput.style.paddingLeft);
|
|
1794
2152
|
}
|
|
1795
2153
|
_createInitPromises() {
|
|
1796
|
-
const e = new Promise((i,
|
|
1797
|
-
this.resolveAutoCountryPromise = i, this.rejectAutoCountryPromise =
|
|
1798
|
-
}), $ = new Promise((i,
|
|
1799
|
-
this.resolveUtilsScriptPromise = i, this.rejectUtilsScriptPromise =
|
|
2154
|
+
const e = new Promise((i, r) => {
|
|
2155
|
+
this.resolveAutoCountryPromise = i, this.rejectAutoCountryPromise = r;
|
|
2156
|
+
}), $ = new Promise((i, r) => {
|
|
2157
|
+
this.resolveUtilsScriptPromise = i, this.rejectUtilsScriptPromise = r;
|
|
1800
2158
|
});
|
|
1801
2159
|
this.promise = Promise.all([e, $]);
|
|
1802
2160
|
}
|
|
1803
2161
|
//* Can't be private as it's called from intlTelInput convenience wrapper.
|
|
1804
2162
|
_init() {
|
|
1805
|
-
|
|
2163
|
+
W0(this.options), this._detectEnvironmentAndLayout(), this._createInitPromises(), this.selectedCountryData = {}, this._processCountryData(), this._generateMarkup(), this._setInitialState(), this._initListeners(), this._initRequests();
|
|
1806
2164
|
}
|
|
1807
2165
|
//********************
|
|
1808
2166
|
//* PRIVATE METHODS
|
|
1809
2167
|
//********************
|
|
1810
2168
|
//* Prepare all of the country data, including onlyCountries, excludeCountries, countryOrder options.
|
|
1811
2169
|
_processCountryData() {
|
|
1812
|
-
this.countries =
|
|
1813
|
-
const e =
|
|
1814
|
-
this.dialCodes = e.dialCodes, this.dialCodeMaxLen = e.dialCodeMaxLen, this.dialCodeToIso2Map = e.dialCodeToIso2Map,
|
|
2170
|
+
this.countries = z0(this.options);
|
|
2171
|
+
const e = Y0(this.countries, this.options);
|
|
2172
|
+
this.dialCodes = e.dialCodes, this.dialCodeMaxLen = e.dialCodeMaxLen, this.dialCodeToIso2Map = e.dialCodeToIso2Map, Z0(this.countries, this.options), J0(this.countries, this.options), this.countryByIso2 = new Map(this.countries.map(($) => [$.iso2, $])), q0(this.countries);
|
|
1815
2173
|
}
|
|
1816
2174
|
//* Generate all of the markup for the plugin: the selected country overlay, and the dropdown.
|
|
1817
2175
|
_generateMarkup() {
|
|
@@ -1828,29 +2186,29 @@ class c1 {
|
|
|
1828
2186
|
allowDropdown: e,
|
|
1829
2187
|
showFlags: $,
|
|
1830
2188
|
containerClass: i,
|
|
1831
|
-
useFullscreenPopup:
|
|
1832
|
-
} = this.options, u =
|
|
2189
|
+
useFullscreenPopup: r
|
|
2190
|
+
} = this.options, u = f1._buildClassNames({
|
|
1833
2191
|
iti: !0,
|
|
1834
2192
|
"iti--allow-dropdown": e,
|
|
1835
2193
|
"iti--show-flags": $,
|
|
1836
|
-
"iti--inline-dropdown": !
|
|
2194
|
+
"iti--inline-dropdown": !r,
|
|
1837
2195
|
[i]: !!i
|
|
1838
2196
|
}), h = L("div", { class: u });
|
|
1839
|
-
return (c = this.telInput.parentNode) == null || c.insertBefore(h, this.telInput), h;
|
|
2197
|
+
return this.isRTL && h.setAttribute("dir", "ltr"), (c = this.telInput.parentNode) == null || c.insertBefore(h, this.telInput), h;
|
|
1840
2198
|
}
|
|
1841
2199
|
_maybeBuildCountryContainer(e) {
|
|
1842
2200
|
const {
|
|
1843
2201
|
allowDropdown: $,
|
|
1844
2202
|
separateDialCode: i,
|
|
1845
|
-
showFlags:
|
|
2203
|
+
showFlags: r
|
|
1846
2204
|
} = this.options;
|
|
1847
|
-
if ($ ||
|
|
2205
|
+
if ($ || r || i) {
|
|
1848
2206
|
this.countryContainer = L(
|
|
1849
2207
|
"div",
|
|
1850
2208
|
// visibly hidden until we measure it's width to set the input padding correctly
|
|
1851
2209
|
{ class: "iti__country-container iti__v-hide" },
|
|
1852
2210
|
e
|
|
1853
|
-
),
|
|
2211
|
+
), $ ? (this.selectedCountry = L(
|
|
1854
2212
|
"button",
|
|
1855
2213
|
{
|
|
1856
2214
|
type: "button",
|
|
@@ -1881,7 +2239,7 @@ class c1 {
|
|
|
1881
2239
|
u
|
|
1882
2240
|
)), i && (this.selectedDialCode = L(
|
|
1883
2241
|
"div",
|
|
1884
|
-
{ class: "iti__selected-dial-code"
|
|
2242
|
+
{ class: "iti__selected-dial-code" },
|
|
1885
2243
|
this.selectedCountry
|
|
1886
2244
|
)), $ && this._buildDropdownContent();
|
|
1887
2245
|
}
|
|
@@ -1891,7 +2249,7 @@ class c1 {
|
|
|
1891
2249
|
fixDropdownWidth: e,
|
|
1892
2250
|
useFullscreenPopup: $,
|
|
1893
2251
|
countrySearch: i,
|
|
1894
|
-
i18n:
|
|
2252
|
+
i18n: r,
|
|
1895
2253
|
dropdownContainer: u,
|
|
1896
2254
|
containerClass: h
|
|
1897
2255
|
} = this.options, c = e ? "" : "iti--flexible-dropdown-width";
|
|
@@ -1900,17 +2258,17 @@ class c1 {
|
|
|
1900
2258
|
class: `iti__dropdown-content iti__hide ${c}`,
|
|
1901
2259
|
role: "dialog",
|
|
1902
2260
|
"aria-modal": "true"
|
|
1903
|
-
}), i && this._buildSearchUI(), this.countryList = L(
|
|
2261
|
+
}), this.isRTL && this.dropdownContent.setAttribute("dir", "rtl"), i && this._buildSearchUI(), this.countryList = L(
|
|
1904
2262
|
"ul",
|
|
1905
2263
|
{
|
|
1906
2264
|
class: "iti__country-list",
|
|
1907
2265
|
id: `iti-${this.id}__country-listbox`,
|
|
1908
2266
|
role: "listbox",
|
|
1909
|
-
"aria-label":
|
|
2267
|
+
"aria-label": r.countryListAriaLabel
|
|
1910
2268
|
},
|
|
1911
2269
|
this.dropdownContent
|
|
1912
2270
|
), this._appendListItems(), i && this._updateSearchResultsA11yText(), u) {
|
|
1913
|
-
const C =
|
|
2271
|
+
const C = f1._buildClassNames({
|
|
1914
2272
|
iti: !0,
|
|
1915
2273
|
"iti--container": !0,
|
|
1916
2274
|
"iti--fullscreen-popup": $,
|
|
@@ -1991,7 +2349,7 @@ class c1 {
|
|
|
1991
2349
|
this.countryContainer && (this._updateInputPadding(), this.countryContainer.classList.remove("iti__v-hide"));
|
|
1992
2350
|
}
|
|
1993
2351
|
_maybeBuildHiddenInputs(e) {
|
|
1994
|
-
var i,
|
|
2352
|
+
var i, r;
|
|
1995
2353
|
const { hiddenInput: $ } = this.options;
|
|
1996
2354
|
if ($) {
|
|
1997
2355
|
const u = this.telInput.getAttribute("name") || "", h = $(u);
|
|
@@ -2003,7 +2361,7 @@ class c1 {
|
|
|
2003
2361
|
}), e.appendChild(this.hiddenInput));
|
|
2004
2362
|
}
|
|
2005
2363
|
if (h.country) {
|
|
2006
|
-
const c = (
|
|
2364
|
+
const c = (r = this.telInput.form) == null ? void 0 : r.querySelector(`input[name="${h.country}"]`);
|
|
2007
2365
|
c ? this.hiddenInputCountry = c : (this.hiddenInputCountry = L("input", {
|
|
2008
2366
|
type: "hidden",
|
|
2009
2367
|
name: h.country
|
|
@@ -2014,7 +2372,7 @@ class c1 {
|
|
|
2014
2372
|
//* For each country: add a country list item <li> to the countryList <ul> container.
|
|
2015
2373
|
_appendListItems() {
|
|
2016
2374
|
for (let e = 0; e < this.countries.length; e++) {
|
|
2017
|
-
const $ = this.countries[e], i = e === 0 ? "iti__highlight" : "",
|
|
2375
|
+
const $ = this.countries[e], i = e === 0 ? "iti__highlight" : "", r = L(
|
|
2018
2376
|
"li",
|
|
2019
2377
|
{
|
|
2020
2378
|
id: `iti-${this.id}__item-${$.iso2}`,
|
|
@@ -2027,21 +2385,21 @@ class c1 {
|
|
|
2027
2385
|
},
|
|
2028
2386
|
this.countryList
|
|
2029
2387
|
);
|
|
2030
|
-
$.nodeById[this.id] =
|
|
2388
|
+
$.nodeById[this.id] = r;
|
|
2031
2389
|
let u = "";
|
|
2032
|
-
this.options.showFlags && (u += `<div class='iti__flag iti__${$.iso2}'></div>`), u += `<span class='iti__country-name'>${$.name}</span>`, u += `<span class='iti__dial-code' dir='ltr'>+${$.dialCode}</span>`,
|
|
2390
|
+
this.options.showFlags && (u += `<div class='iti__flag iti__${$.iso2}'></div>`), u += `<span class='iti__country-name'>${$.name}</span>`, u += `<span class='iti__dial-code' dir='ltr'>+${$.dialCode}</span>`, r.insertAdjacentHTML("beforeend", u);
|
|
2033
2391
|
}
|
|
2034
2392
|
}
|
|
2035
2393
|
//* Set the initial state of the input value and the selected country by:
|
|
2036
2394
|
//* 1. Extracting a dial code from the given number
|
|
2037
2395
|
//* 2. Using explicit initialCountry
|
|
2038
2396
|
_setInitialState(e = !1) {
|
|
2039
|
-
const $ = this.telInput.getAttribute("value"), i = this.telInput.value, u = $ && $.charAt(0) === "+" && (!i || i.charAt(0) !== "+") ? $ : i, h = this._getDialCode(u), c =
|
|
2397
|
+
const $ = this.telInput.getAttribute("value"), i = this.telInput.value, u = $ && $.charAt(0) === "+" && (!i || i.charAt(0) !== "+") ? $ : i, h = this._getDialCode(u), c = o0(u), { initialCountry: C, geoIpLookup: g } = this.options, I = C === "auto" && g;
|
|
2040
2398
|
if (h && !c)
|
|
2041
2399
|
this._updateCountryFromNumber(u);
|
|
2042
2400
|
else if (!I || e) {
|
|
2043
|
-
const
|
|
2044
|
-
w1(
|
|
2401
|
+
const w = C ? C.toLowerCase() : "";
|
|
2402
|
+
w1(w) ? this._setCountry(w) : h && c ? this._setCountry("us") : this._setCountry("");
|
|
2045
2403
|
}
|
|
2046
2404
|
u && this._updateValFromNumber(u);
|
|
2047
2405
|
}
|
|
@@ -2090,10 +2448,10 @@ class c1 {
|
|
|
2090
2448
|
y.autoCountry ? this.handleAutoCountry() : y.startedLoadingAutoCountry || (y.startedLoadingAutoCountry = !0, typeof this.options.geoIpLookup == "function" && this.options.geoIpLookup(
|
|
2091
2449
|
(e = "") => {
|
|
2092
2450
|
const $ = e.toLowerCase();
|
|
2093
|
-
w1($) ? (y.autoCountry = $, setTimeout(() =>
|
|
2451
|
+
w1($) ? (y.autoCountry = $, setTimeout(() => $1("handleAutoCountry"))) : (this._setInitialState(!0), $1("rejectAutoCountryPromise"));
|
|
2094
2452
|
},
|
|
2095
2453
|
() => {
|
|
2096
|
-
this._setInitialState(!0),
|
|
2454
|
+
this._setInitialState(!0), $1("rejectAutoCountryPromise");
|
|
2097
2455
|
}
|
|
2098
2456
|
));
|
|
2099
2457
|
}
|
|
@@ -2105,12 +2463,12 @@ class c1 {
|
|
|
2105
2463
|
this._bindInputListener(), this._maybeBindKeydownListener(), this._maybeBindPasteListener();
|
|
2106
2464
|
}
|
|
2107
2465
|
_bindInputListener() {
|
|
2108
|
-
const { strictMode: e, formatAsYouType: $, separateDialCode: i, allowDropdown:
|
|
2466
|
+
const { strictMode: e, formatAsYouType: $, separateDialCode: i, allowDropdown: r, countrySearch: u } = this.options;
|
|
2109
2467
|
let h = !1;
|
|
2110
2468
|
new RegExp("\\p{L}", "u").test(this.telInput.value) && (h = !0), this._handleInputEvent = (c) => {
|
|
2111
|
-
if (this.isAndroid && (c == null ? void 0 : c.data) === "+" && i &&
|
|
2112
|
-
const
|
|
2113
|
-
this.telInput.value =
|
|
2469
|
+
if (this.isAndroid && (c == null ? void 0 : c.data) === "+" && i && r && u) {
|
|
2470
|
+
const w = this.telInput.selectionStart || 0, k = this.telInput.value.substring(0, w - 1), v = this.telInput.value.substring(w);
|
|
2471
|
+
this.telInput.value = k + v, this._openDropdownWithPlus();
|
|
2114
2472
|
return;
|
|
2115
2473
|
}
|
|
2116
2474
|
this._updateCountryFromNumber(this.telInput.value) && this._triggerCountryChange();
|
|
@@ -2118,28 +2476,28 @@ class c1 {
|
|
|
2118
2476
|
C || g && !e ? h = !0 : /[^+0-9]/.test(this.telInput.value) || (h = !1);
|
|
2119
2477
|
const I = (c == null ? void 0 : c.detail) && c.detail.isSetNumber;
|
|
2120
2478
|
if ($ && !h && !I) {
|
|
2121
|
-
const
|
|
2122
|
-
|
|
2479
|
+
const w = this.telInput.selectionStart || 0, v = this.telInput.value.substring(0, w).replace(/[^+0-9]/g, "").length, E = (c == null ? void 0 : c.inputType) === "deleteContentForward", N = this._getFullNumber(), P = Q0(
|
|
2480
|
+
N,
|
|
2123
2481
|
this.telInput.value,
|
|
2124
2482
|
y.utils,
|
|
2125
2483
|
this.selectedCountryData,
|
|
2126
2484
|
this.options.separateDialCode
|
|
2127
|
-
),
|
|
2128
|
-
this.telInput.value =
|
|
2485
|
+
), G = d2(v, P, w, E);
|
|
2486
|
+
this.telInput.value = P, this.telInput.setSelectionRange(G, G);
|
|
2129
2487
|
}
|
|
2130
2488
|
}, this.telInput.addEventListener("input", this._handleInputEvent);
|
|
2131
2489
|
}
|
|
2132
2490
|
_maybeBindKeydownListener() {
|
|
2133
|
-
const { strictMode: e, separateDialCode: $, allowDropdown: i, countrySearch:
|
|
2491
|
+
const { strictMode: e, separateDialCode: $, allowDropdown: i, countrySearch: r } = this.options;
|
|
2134
2492
|
(e || $) && (this._handleKeydownEvent = (u) => {
|
|
2135
2493
|
if (u.key && u.key.length === 1 && !u.altKey && !u.ctrlKey && !u.metaKey) {
|
|
2136
|
-
if ($ && i &&
|
|
2494
|
+
if ($ && i && r && u.key === "+") {
|
|
2137
2495
|
u.preventDefault(), this._openDropdownWithPlus();
|
|
2138
2496
|
return;
|
|
2139
2497
|
}
|
|
2140
2498
|
if (e) {
|
|
2141
|
-
const h = this.telInput.value, C = !(h.charAt(0) === "+") && this.telInput.selectionStart === 0 && u.key === "+", g = /^[0-9]$/.test(u.key), I = $ ? g : C || g,
|
|
2142
|
-
(!I ||
|
|
2499
|
+
const h = this.telInput.value, C = !(h.charAt(0) === "+") && this.telInput.selectionStart === 0 && u.key === "+", g = /^[0-9]$/.test(u.key), I = $ ? g : C || g, w = h.slice(0, this.telInput.selectionStart) + u.key + h.slice(this.telInput.selectionEnd), k = this._getFullNumber(w), v = y.utils.getCoreNumber(k, this.selectedCountryData.iso2), E = this.maxCoreNumberLength && v.length > this.maxCoreNumberLength, P = this._getNewCountryFromNumber(k) !== null;
|
|
2500
|
+
(!I || E && !P && !C) && u.preventDefault();
|
|
2143
2501
|
}
|
|
2144
2502
|
}
|
|
2145
2503
|
}, this.telInput.addEventListener("keydown", this._handleKeydownEvent));
|
|
@@ -2147,21 +2505,21 @@ class c1 {
|
|
|
2147
2505
|
_maybeBindPasteListener() {
|
|
2148
2506
|
this.options.strictMode && (this._handlePasteEvent = (e) => {
|
|
2149
2507
|
e.preventDefault();
|
|
2150
|
-
const $ = this.telInput, i = $.selectionStart,
|
|
2151
|
-
let
|
|
2152
|
-
for (;
|
|
2153
|
-
|
|
2154
|
-
if (!
|
|
2508
|
+
const $ = this.telInput, i = $.selectionStart, r = $.selectionEnd, u = $.value.slice(0, i), h = $.value.slice(r), c = this.selectedCountryData.iso2, C = e.clipboardData.getData("text"), g = i === 0 && r > 0, I = !$.value.startsWith("+") || g, w = C.replace(/[^0-9+]/g, ""), k = w.startsWith("+"), v = w.replace(/\+/g, ""), E = k && I ? `+${v}` : v;
|
|
2509
|
+
let N = u + E + h, P = y.utils.getCoreNumber(N, c);
|
|
2510
|
+
for (; P.length === 0 && N.length > 0; )
|
|
2511
|
+
N = N.slice(0, -1), P = y.utils.getCoreNumber(N, c);
|
|
2512
|
+
if (!P)
|
|
2155
2513
|
return;
|
|
2156
|
-
if (this.maxCoreNumberLength &&
|
|
2514
|
+
if (this.maxCoreNumberLength && P.length > this.maxCoreNumberLength)
|
|
2157
2515
|
if ($.selectionEnd === $.value.length) {
|
|
2158
|
-
const
|
|
2159
|
-
|
|
2516
|
+
const j = P.length - this.maxCoreNumberLength;
|
|
2517
|
+
N = N.slice(0, N.length - j);
|
|
2160
2518
|
} else
|
|
2161
2519
|
return;
|
|
2162
|
-
$.value =
|
|
2163
|
-
const
|
|
2164
|
-
$.setSelectionRange(
|
|
2520
|
+
$.value = N;
|
|
2521
|
+
const G = i + E.length;
|
|
2522
|
+
$.setSelectionRange(G, G), $.dispatchEvent(new InputEvent("input", { bubbles: !0 }));
|
|
2165
2523
|
}, this.telInput.addEventListener("paste", this._handlePasteEvent));
|
|
2166
2524
|
}
|
|
2167
2525
|
//* Adhere to the input's maxlength attr.
|
|
@@ -2198,15 +2556,15 @@ class c1 {
|
|
|
2198
2556
|
_bindDropdownListeners() {
|
|
2199
2557
|
this._handleMouseoverCountryList = (i) => {
|
|
2200
2558
|
var u;
|
|
2201
|
-
const
|
|
2202
|
-
|
|
2559
|
+
const r = (u = i.target) == null ? void 0 : u.closest(".iti__country");
|
|
2560
|
+
r && this._highlightListItem(r, !1);
|
|
2203
2561
|
}, this.countryList.addEventListener(
|
|
2204
2562
|
"mouseover",
|
|
2205
2563
|
this._handleMouseoverCountryList
|
|
2206
2564
|
), this._handleClickCountryList = (i) => {
|
|
2207
2565
|
var u;
|
|
2208
|
-
const
|
|
2209
|
-
|
|
2566
|
+
const r = (u = i.target) == null ? void 0 : u.closest(".iti__country");
|
|
2567
|
+
r && this._selectListItem(r);
|
|
2210
2568
|
}, this.countryList.addEventListener("click", this._handleClickCountryList), this._handleClickOffToClose = (i) => {
|
|
2211
2569
|
!!i.target.closest(`#iti-${this.id}__dropdown-content`) || this._closeDropdown();
|
|
2212
2570
|
}, setTimeout(() => {
|
|
@@ -2225,10 +2583,10 @@ class c1 {
|
|
|
2225
2583
|
const u = this.searchInput.value.trim();
|
|
2226
2584
|
this._filterCountries(u), this.searchInput.value ? this.searchClearButton.classList.remove("iti__hide") : this.searchClearButton.classList.add("iti__hide");
|
|
2227
2585
|
};
|
|
2228
|
-
let
|
|
2586
|
+
let r = null;
|
|
2229
2587
|
this._handleSearchChange = () => {
|
|
2230
|
-
|
|
2231
|
-
i(),
|
|
2588
|
+
r && clearTimeout(r), r = setTimeout(() => {
|
|
2589
|
+
i(), r = null;
|
|
2232
2590
|
}, 100);
|
|
2233
2591
|
}, this.searchInput.addEventListener("input", this._handleSearchChange), this._handleSearchClear = () => {
|
|
2234
2592
|
this.searchInput.value = "", this.searchInput.focus(), i();
|
|
@@ -2239,8 +2597,8 @@ class c1 {
|
|
|
2239
2597
|
_searchForCountry(e) {
|
|
2240
2598
|
for (const $ of this.countries)
|
|
2241
2599
|
if ($.name.substring(0, e.length).toLowerCase() === e) {
|
|
2242
|
-
const
|
|
2243
|
-
this._highlightListItem(
|
|
2600
|
+
const r = $.nodeById[this.id];
|
|
2601
|
+
this._highlightListItem(r, !1), this._scrollTo(r);
|
|
2244
2602
|
break;
|
|
2245
2603
|
}
|
|
2246
2604
|
}
|
|
@@ -2250,19 +2608,19 @@ class c1 {
|
|
|
2250
2608
|
let $;
|
|
2251
2609
|
e === "" ? $ = this.countries : $ = this._getMatchedCountries(e);
|
|
2252
2610
|
let i = !0;
|
|
2253
|
-
for (const
|
|
2254
|
-
const u =
|
|
2611
|
+
for (const r of $) {
|
|
2612
|
+
const u = r.nodeById[this.id];
|
|
2255
2613
|
u && (this.countryList.appendChild(u), i && (this._highlightListItem(u, !1), i = !1));
|
|
2256
2614
|
}
|
|
2257
2615
|
i ? (this._highlightListItem(null, !1), this.searchNoResults && this.searchNoResults.classList.remove("iti__hide")) : this.searchNoResults && this.searchNoResults.classList.add("iti__hide"), this.countryList.scrollTop = 0, this._updateSearchResultsA11yText();
|
|
2258
2616
|
}
|
|
2259
2617
|
_getMatchedCountries(e) {
|
|
2260
|
-
const $ =
|
|
2618
|
+
const $ = a0(e), i = [], r = [], u = [], h = [], c = [], C = [];
|
|
2261
2619
|
for (const g of this.countries)
|
|
2262
|
-
g.iso2 === $ ? i.push(g) : g.normalisedName.startsWith($) ?
|
|
2620
|
+
g.iso2 === $ ? i.push(g) : g.normalisedName.startsWith($) ? r.push(g) : g.normalisedName.includes($) ? u.push(g) : $ === g.dialCode || $ === g.dialCodePlus ? h.push(g) : g.dialCodePlus.includes($) ? c.push(g) : g.initials.includes($) && C.push(g);
|
|
2263
2621
|
return [
|
|
2264
2622
|
...i.sort((g, I) => g.priority - I.priority),
|
|
2265
|
-
...
|
|
2623
|
+
...r.sort((g, I) => g.priority - I.priority),
|
|
2266
2624
|
...u.sort((g, I) => g.priority - I.priority),
|
|
2267
2625
|
...h.sort((g, I) => g.priority - I.priority),
|
|
2268
2626
|
...c.sort((g, I) => g.priority - I.priority),
|
|
@@ -2277,8 +2635,8 @@ class c1 {
|
|
|
2277
2635
|
}
|
|
2278
2636
|
//* Highlight the next/prev item in the list (and ensure it is visible).
|
|
2279
2637
|
_handleUpDownKey(e) {
|
|
2280
|
-
var i,
|
|
2281
|
-
let $ = e === "ArrowUp" ? (i = this.highlightedItem) == null ? void 0 : i.previousElementSibling : (
|
|
2638
|
+
var i, r;
|
|
2639
|
+
let $ = e === "ArrowUp" ? (i = this.highlightedItem) == null ? void 0 : i.previousElementSibling : (r = this.highlightedItem) == null ? void 0 : r.nextElementSibling;
|
|
2282
2640
|
!$ && this.countryList.childElementCount > 1 && ($ = e === "ArrowUp" ? this.countryList.lastElementChild : this.countryList.firstElementChild), $ && (this._scrollTo($), this._highlightListItem($, !1));
|
|
2283
2641
|
}
|
|
2284
2642
|
//* Select the currently highlighted item.
|
|
@@ -2290,7 +2648,7 @@ class c1 {
|
|
|
2290
2648
|
_updateValFromNumber(e) {
|
|
2291
2649
|
let $ = e;
|
|
2292
2650
|
if (this.options.formatOnDisplay && y.utils && this.selectedCountryData) {
|
|
2293
|
-
const i = this.options.nationalMode || $.charAt(0) !== "+" && !this.options.separateDialCode, { NATIONAL:
|
|
2651
|
+
const i = this.options.nationalMode || $.charAt(0) !== "+" && !this.options.separateDialCode, { NATIONAL: r, INTERNATIONAL: u } = y.utils.numberFormat, h = i ? r : u;
|
|
2294
2652
|
$ = y.utils.formatNumber(
|
|
2295
2653
|
$,
|
|
2296
2654
|
this.selectedCountryData.iso2,
|
|
@@ -2305,6 +2663,7 @@ class c1 {
|
|
|
2305
2663
|
const $ = this._getNewCountryFromNumber(e);
|
|
2306
2664
|
return $ !== null ? this._setCountry($) : !1;
|
|
2307
2665
|
}
|
|
2666
|
+
// if there is a selected country, and the number doesn't start with a dial code, then add it
|
|
2308
2667
|
_ensureHasDialCode(e) {
|
|
2309
2668
|
const { dialCode: $, nationalPrefix: i } = this.selectedCountryData;
|
|
2310
2669
|
if (e.charAt(0) === "+" || !$)
|
|
@@ -2318,24 +2677,31 @@ class c1 {
|
|
|
2318
2677
|
_getNewCountryFromNumber(e) {
|
|
2319
2678
|
const $ = e.indexOf("+");
|
|
2320
2679
|
let i = $ ? e.substring($) : e;
|
|
2321
|
-
const
|
|
2680
|
+
const r = this.selectedCountryData.iso2, u = this.selectedCountryData.dialCode;
|
|
2322
2681
|
i = this._ensureHasDialCode(i);
|
|
2323
|
-
const h = this._getDialCode(i, !0), c =
|
|
2682
|
+
const h = this._getDialCode(i, !0), c = c1(i);
|
|
2324
2683
|
if (h) {
|
|
2325
|
-
const C =
|
|
2684
|
+
const C = c1(h), g = this.dialCodeToIso2Map[C];
|
|
2326
2685
|
if (g.length === 1)
|
|
2327
|
-
return g[0] ===
|
|
2328
|
-
if (!
|
|
2686
|
+
return g[0] === r ? null : g[0];
|
|
2687
|
+
if (!r && this.defaultCountry && g.includes(this.defaultCountry))
|
|
2329
2688
|
return this.defaultCountry;
|
|
2330
|
-
if (u === "1" &&
|
|
2689
|
+
if (u === "1" && o0(c))
|
|
2331
2690
|
return null;
|
|
2332
|
-
const
|
|
2333
|
-
if (
|
|
2691
|
+
const { areaCodes: w, priority: k } = this.selectedCountryData;
|
|
2692
|
+
if (w) {
|
|
2693
|
+
const G = w.map((j) => `${u}${j}`);
|
|
2694
|
+
for (const j of G)
|
|
2695
|
+
if (c.startsWith(j))
|
|
2696
|
+
return null;
|
|
2697
|
+
}
|
|
2698
|
+
const E = w && !(k === 0) && c.length > C.length, N = r && g.includes(r) && !E, P = r === g[0];
|
|
2699
|
+
if (!N && !P)
|
|
2334
2700
|
return g[0];
|
|
2335
2701
|
} else {
|
|
2336
2702
|
if (i.charAt(0) === "+" && c.length)
|
|
2337
2703
|
return "";
|
|
2338
|
-
if ((!i || i === "+") && !
|
|
2704
|
+
if ((!i || i === "+") && !r)
|
|
2339
2705
|
return this.defaultCountry;
|
|
2340
2706
|
}
|
|
2341
2707
|
return null;
|
|
@@ -2344,23 +2710,23 @@ class c1 {
|
|
|
2344
2710
|
_highlightListItem(e, $) {
|
|
2345
2711
|
const i = this.highlightedItem;
|
|
2346
2712
|
if (i && (i.classList.remove("iti__highlight"), i.setAttribute("aria-selected", "false")), this.highlightedItem = e, this.highlightedItem && (this.highlightedItem.classList.add("iti__highlight"), this.highlightedItem.setAttribute("aria-selected", "true"), this.options.countrySearch)) {
|
|
2347
|
-
const
|
|
2348
|
-
this.searchInput.setAttribute("aria-activedescendant",
|
|
2713
|
+
const r = this.highlightedItem.getAttribute("id") || "";
|
|
2714
|
+
this.searchInput.setAttribute("aria-activedescendant", r);
|
|
2349
2715
|
}
|
|
2350
2716
|
$ && this.highlightedItem.focus();
|
|
2351
2717
|
}
|
|
2352
2718
|
//* Update the selected country, dial code (if separateDialCode), placeholder, title, and active list item.
|
|
2353
2719
|
//* Note: called from _setInitialState, _updateCountryFromNumber, _selectListItem, setCountry.
|
|
2354
2720
|
_setCountry(e) {
|
|
2355
|
-
const { separateDialCode: $, showFlags: i, i18n:
|
|
2721
|
+
const { separateDialCode: $, showFlags: i, i18n: r } = this.options, u = this.selectedCountryData.iso2 || "";
|
|
2356
2722
|
if (this.selectedCountryData = e ? this.countryByIso2.get(e) : {}, this.selectedCountryData.iso2 && (this.defaultCountry = this.selectedCountryData.iso2), this.selectedCountry) {
|
|
2357
2723
|
const h = e && i ? `iti__flag iti__${e}` : "iti__flag iti__globe";
|
|
2358
2724
|
let c, C;
|
|
2359
2725
|
if (e) {
|
|
2360
2726
|
const { name: g, dialCode: I } = this.selectedCountryData;
|
|
2361
|
-
C = g, c =
|
|
2727
|
+
C = g, c = r.selectedCountryAriaLabel.replace("${countryName}", g).replace("${dialCode}", `+${I}`);
|
|
2362
2728
|
} else
|
|
2363
|
-
C =
|
|
2729
|
+
C = r.noCountrySelected, c = r.noCountrySelected;
|
|
2364
2730
|
this.selectedCountryInner.className = h, this.selectedCountry.setAttribute("title", C), this.selectedCountry.setAttribute("aria-label", c);
|
|
2365
2731
|
}
|
|
2366
2732
|
if ($) {
|
|
@@ -2373,25 +2739,25 @@ class c1 {
|
|
|
2373
2739
|
_updateInputPadding() {
|
|
2374
2740
|
if (this.selectedCountry) {
|
|
2375
2741
|
const e = this.options.separateDialCode ? 78 : 42, i = (this.selectedCountry.offsetWidth || this._getHiddenSelectedCountryWidth() || e) + 6;
|
|
2376
|
-
this.
|
|
2742
|
+
this.telInput.style.paddingLeft = `${i}px`;
|
|
2377
2743
|
}
|
|
2378
2744
|
}
|
|
2379
2745
|
//* Update the maximum valid number length for the currently selected country.
|
|
2380
2746
|
_updateMaxLength() {
|
|
2381
|
-
const { strictMode: e, placeholderNumberType: $, validationNumberTypes: i } = this.options, { iso2:
|
|
2747
|
+
const { strictMode: e, placeholderNumberType: $, validationNumberTypes: i } = this.options, { iso2: r } = this.selectedCountryData;
|
|
2382
2748
|
if (e && y.utils)
|
|
2383
|
-
if (
|
|
2749
|
+
if (r) {
|
|
2384
2750
|
const u = y.utils.numberType[$];
|
|
2385
2751
|
let h = y.utils.getExampleNumber(
|
|
2386
|
-
|
|
2752
|
+
r,
|
|
2387
2753
|
!1,
|
|
2388
2754
|
u,
|
|
2389
2755
|
!0
|
|
2390
2756
|
), c = h;
|
|
2391
|
-
for (; y.utils.isPossibleNumber(h,
|
|
2757
|
+
for (; y.utils.isPossibleNumber(h, r, i); )
|
|
2392
2758
|
c = h, h += "0";
|
|
2393
|
-
const C = y.utils.getCoreNumber(c,
|
|
2394
|
-
this.maxCoreNumberLength = C.length,
|
|
2759
|
+
const C = y.utils.getCoreNumber(c, r);
|
|
2760
|
+
this.maxCoreNumberLength = C.length, r === "by" && (this.maxCoreNumberLength = C.length + 1);
|
|
2395
2761
|
} else
|
|
2396
2762
|
this.maxCoreNumberLength = null;
|
|
2397
2763
|
}
|
|
@@ -2411,9 +2777,9 @@ class c1 {
|
|
|
2411
2777
|
$.style.visibility = "hidden", e.appendChild($);
|
|
2412
2778
|
const i = this.countryContainer.cloneNode();
|
|
2413
2779
|
$.appendChild(i);
|
|
2414
|
-
const
|
|
2415
|
-
i.appendChild(
|
|
2416
|
-
const u =
|
|
2780
|
+
const r = this.selectedCountry.cloneNode(!0);
|
|
2781
|
+
i.appendChild(r);
|
|
2782
|
+
const u = r.offsetWidth;
|
|
2417
2783
|
return e.removeChild($), u;
|
|
2418
2784
|
}
|
|
2419
2785
|
return 0;
|
|
@@ -2424,7 +2790,7 @@ class c1 {
|
|
|
2424
2790
|
autoPlaceholder: e,
|
|
2425
2791
|
placeholderNumberType: $,
|
|
2426
2792
|
nationalMode: i,
|
|
2427
|
-
customPlaceholder:
|
|
2793
|
+
customPlaceholder: r
|
|
2428
2794
|
} = this.options, u = e === "aggressive" || !this.hadInitialPlaceholder && e === "polite";
|
|
2429
2795
|
if (y.utils && u) {
|
|
2430
2796
|
const h = y.utils.numberType[$];
|
|
@@ -2433,15 +2799,15 @@ class c1 {
|
|
|
2433
2799
|
i,
|
|
2434
2800
|
h
|
|
2435
2801
|
) : "";
|
|
2436
|
-
c = this._beforeSetNumber(c), typeof
|
|
2802
|
+
c = this._beforeSetNumber(c), typeof r == "function" && (c = r(c, this.selectedCountryData)), this.telInput.setAttribute("placeholder", c);
|
|
2437
2803
|
}
|
|
2438
2804
|
}
|
|
2439
2805
|
//* Called when the user selects a list item from the dropdown.
|
|
2440
2806
|
_selectListItem(e) {
|
|
2441
2807
|
const $ = e.getAttribute("data-country-code"), i = this._setCountry($);
|
|
2442
2808
|
this._closeDropdown();
|
|
2443
|
-
const
|
|
2444
|
-
this._updateDialCode(
|
|
2809
|
+
const r = e.getAttribute("data-dial-code");
|
|
2810
|
+
this._updateDialCode(r), this.options.formatOnDisplay && this._updateValFromNumber(this.telInput.value), this.telInput.focus(), i && this._triggerCountryChange();
|
|
2445
2811
|
}
|
|
2446
2812
|
//* Close the dropdown and unbind any listeners.
|
|
2447
2813
|
_closeDropdown() {
|
|
@@ -2455,22 +2821,22 @@ class c1 {
|
|
|
2455
2821
|
}
|
|
2456
2822
|
//* Check if an element is visible within it's container, else scroll until it is.
|
|
2457
2823
|
_scrollTo(e) {
|
|
2458
|
-
const $ = this.countryList, i = document.documentElement.scrollTop,
|
|
2824
|
+
const $ = this.countryList, i = document.documentElement.scrollTop, r = $.offsetHeight, u = $.getBoundingClientRect().top + i, h = u + r, c = e.offsetHeight, C = e.getBoundingClientRect().top + i, g = C + c, I = C - u + $.scrollTop;
|
|
2459
2825
|
if (C < u)
|
|
2460
2826
|
$.scrollTop = I;
|
|
2461
2827
|
else if (g > h) {
|
|
2462
|
-
const
|
|
2463
|
-
$.scrollTop = I -
|
|
2828
|
+
const w = r - c;
|
|
2829
|
+
$.scrollTop = I - w;
|
|
2464
2830
|
}
|
|
2465
2831
|
}
|
|
2466
2832
|
//* Replace any existing dial code with the new one
|
|
2467
2833
|
//* Note: called from _selectListItem and setCountry
|
|
2468
2834
|
_updateDialCode(e) {
|
|
2469
2835
|
const $ = this.telInput.value, i = `+${e}`;
|
|
2470
|
-
let
|
|
2836
|
+
let r;
|
|
2471
2837
|
if ($.charAt(0) === "+") {
|
|
2472
2838
|
const u = this._getDialCode($);
|
|
2473
|
-
u ?
|
|
2839
|
+
u ? r = $.replace(u, i) : r = i, this.telInput.value = r;
|
|
2474
2840
|
}
|
|
2475
2841
|
}
|
|
2476
2842
|
//* Try and extract a valid international dial code from a full telephone number.
|
|
@@ -2478,17 +2844,19 @@ class c1 {
|
|
|
2478
2844
|
_getDialCode(e, $) {
|
|
2479
2845
|
let i = "";
|
|
2480
2846
|
if (e.charAt(0) === "+") {
|
|
2481
|
-
let
|
|
2847
|
+
let r = "";
|
|
2482
2848
|
for (let u = 0; u < e.length; u++) {
|
|
2483
2849
|
const h = e.charAt(u);
|
|
2484
2850
|
if (/[0-9]/.test(h)) {
|
|
2485
|
-
if (
|
|
2486
|
-
|
|
2487
|
-
|
|
2851
|
+
if (r += h, !!!this.dialCodeToIso2Map[r])
|
|
2852
|
+
break;
|
|
2853
|
+
if ($)
|
|
2854
|
+
i = e.substring(0, u + 1);
|
|
2855
|
+
else if (this.dialCodes.has(r)) {
|
|
2488
2856
|
i = e.substring(0, u + 1);
|
|
2489
2857
|
break;
|
|
2490
2858
|
}
|
|
2491
|
-
if (
|
|
2859
|
+
if (r.length === this.dialCodeMaxLen)
|
|
2492
2860
|
break;
|
|
2493
2861
|
}
|
|
2494
2862
|
}
|
|
@@ -2498,13 +2866,13 @@ class c1 {
|
|
|
2498
2866
|
//* Get the input val, adding the dial code if separateDialCode is enabled.
|
|
2499
2867
|
_getFullNumber(e) {
|
|
2500
2868
|
const $ = e || this.telInput.value.trim(), { dialCode: i } = this.selectedCountryData;
|
|
2501
|
-
let
|
|
2502
|
-
const u =
|
|
2503
|
-
return this.options.separateDialCode && $.charAt(0) !== "+" && i && u ?
|
|
2869
|
+
let r;
|
|
2870
|
+
const u = c1($);
|
|
2871
|
+
return this.options.separateDialCode && $.charAt(0) !== "+" && i && u ? r = `+${i}` : r = "", r + $;
|
|
2504
2872
|
}
|
|
2505
2873
|
//* Remove the dial code if separateDialCode is enabled also cap the length if the input has a maxlength attribute
|
|
2506
2874
|
_beforeSetNumber(e) {
|
|
2507
|
-
const $ = this._getDialCode(e), i =
|
|
2875
|
+
const $ = this._getDialCode(e), i = X0(
|
|
2508
2876
|
e,
|
|
2509
2877
|
$,
|
|
2510
2878
|
this.options.separateDialCode,
|
|
@@ -2547,9 +2915,9 @@ class c1 {
|
|
|
2547
2915
|
c && c.removeEventListener("click", this._handleLabelClick);
|
|
2548
2916
|
}
|
|
2549
2917
|
const { form: i } = this.telInput;
|
|
2550
|
-
this._handleHiddenInputSubmit && i && i.removeEventListener("submit", this._handleHiddenInputSubmit), this.telInput.removeEventListener("input", this._handleInputEvent), this._handleKeydownEvent && this.telInput.removeEventListener("keydown", this._handleKeydownEvent), this._handlePasteEvent && this.telInput.removeEventListener("paste", this._handlePasteEvent), this._handlePageLoad && window.removeEventListener("load", this._handlePageLoad), this.telInput.removeAttribute("data-intl-tel-input-id"), $ && (this.
|
|
2551
|
-
const
|
|
2552
|
-
(u =
|
|
2918
|
+
this._handleHiddenInputSubmit && i && i.removeEventListener("submit", this._handleHiddenInputSubmit), this.telInput.removeEventListener("input", this._handleInputEvent), this._handleKeydownEvent && this.telInput.removeEventListener("keydown", this._handleKeydownEvent), this._handlePasteEvent && this.telInput.removeEventListener("paste", this._handlePasteEvent), this._handlePageLoad && window.removeEventListener("load", this._handlePageLoad), this.telInput.removeAttribute("data-intl-tel-input-id"), $ && (this.telInput.style.paddingLeft = this.originalPaddingLeft);
|
|
2919
|
+
const r = this.telInput.parentNode;
|
|
2920
|
+
(u = r == null ? void 0 : r.parentNode) == null || u.insertBefore(this.telInput, r), (h = r == null ? void 0 : r.parentNode) == null || h.removeChild(r), delete y.instances[this.id];
|
|
2553
2921
|
}
|
|
2554
2922
|
//* Get the extension from the current number.
|
|
2555
2923
|
getExtension() {
|
|
@@ -2589,11 +2957,17 @@ class c1 {
|
|
|
2589
2957
|
}
|
|
2590
2958
|
return -99;
|
|
2591
2959
|
}
|
|
2592
|
-
//* Validate the input val
|
|
2960
|
+
//* Validate the input val using number length only
|
|
2593
2961
|
isValidNumber() {
|
|
2962
|
+
const { dialCode: e, iso2: $ } = this.selectedCountryData;
|
|
2963
|
+
if (e === "44" && y.utils) {
|
|
2964
|
+
const i = this._getFullNumber(), r = y.utils.getCoreNumber(i, $);
|
|
2965
|
+
if (r[0] === "7" && r.length !== 10)
|
|
2966
|
+
return !1;
|
|
2967
|
+
}
|
|
2594
2968
|
return this._validateNumber(!1);
|
|
2595
2969
|
}
|
|
2596
|
-
//* Validate the input val
|
|
2970
|
+
//* Validate the input val with precise validation
|
|
2597
2971
|
isValidNumberPrecise() {
|
|
2598
2972
|
return this._validateNumber(!0);
|
|
2599
2973
|
}
|
|
@@ -2602,11 +2976,13 @@ class c1 {
|
|
|
2602
2976
|
}
|
|
2603
2977
|
//* Shared internal validation logic to handle alpha character extension rules.
|
|
2604
2978
|
_validateNumber(e) {
|
|
2979
|
+
if (!y.utils)
|
|
2980
|
+
return null;
|
|
2605
2981
|
if (!this.selectedCountryData.iso2)
|
|
2606
2982
|
return !1;
|
|
2607
|
-
const $ = (h) => e ? this._utilsIsValidNumber(h) : this._utilsIsPossibleNumber(h), i = this._getFullNumber(),
|
|
2608
|
-
if (
|
|
2609
|
-
const h = i.substring(0,
|
|
2983
|
+
const $ = (h) => e ? this._utilsIsValidNumber(h) : this._utilsIsPossibleNumber(h), i = this._getFullNumber(), r = i.search(new RegExp("\\p{L}", "u"));
|
|
2984
|
+
if (r > -1 && !this.options.allowPhonewords) {
|
|
2985
|
+
const h = i.substring(0, r), c = $(h), C = $(i);
|
|
2610
2986
|
return c && C;
|
|
2611
2987
|
}
|
|
2612
2988
|
return $(i);
|
|
@@ -2635,7 +3011,7 @@ class c1 {
|
|
|
2635
3011
|
this.telInput.disabled = e, e ? this.selectedCountry.setAttribute("disabled", "true") : this.selectedCountry.removeAttribute("disabled");
|
|
2636
3012
|
}
|
|
2637
3013
|
}
|
|
2638
|
-
const
|
|
3014
|
+
const n2 = (f) => {
|
|
2639
3015
|
if (!y.utils && !y.startedLoadingUtilsScript) {
|
|
2640
3016
|
let e;
|
|
2641
3017
|
if (typeof f == "function")
|
|
@@ -2650,23 +3026,23 @@ const n0 = (f) => {
|
|
|
2650
3026
|
const i = $ == null ? void 0 : $.default;
|
|
2651
3027
|
if (!i || typeof i != "object")
|
|
2652
3028
|
throw new TypeError("The loader function passed to attachUtils did not resolve to a module object with utils as its default export.");
|
|
2653
|
-
return y.utils = i,
|
|
3029
|
+
return y.utils = i, $1("handleUtils"), !0;
|
|
2654
3030
|
}).catch(($) => {
|
|
2655
|
-
throw
|
|
3031
|
+
throw $1("rejectUtilsScriptPromise", $), $;
|
|
2656
3032
|
});
|
|
2657
3033
|
}
|
|
2658
3034
|
return null;
|
|
2659
3035
|
}, y = Object.assign(
|
|
2660
3036
|
(f, e) => {
|
|
2661
|
-
const $ = new
|
|
3037
|
+
const $ = new f1(f, e);
|
|
2662
3038
|
return $._init(), f.setAttribute("data-intl-tel-input-id", $.id.toString()), y.instances[$.id] = $, f.iti = $, $;
|
|
2663
3039
|
},
|
|
2664
3040
|
{
|
|
2665
|
-
defaults:
|
|
3041
|
+
defaults: u0,
|
|
2666
3042
|
//* Using a static var like this allows us to mock it in the tests.
|
|
2667
3043
|
documentReady: () => document.readyState === "complete",
|
|
2668
3044
|
//* Get the country data object.
|
|
2669
|
-
getCountryData: () =>
|
|
3045
|
+
getCountryData: () => Y,
|
|
2670
3046
|
//* A getter for the plugin instance.
|
|
2671
3047
|
getInstance: (f) => {
|
|
2672
3048
|
const e = f.getAttribute("data-intl-tel-input-id");
|
|
@@ -2674,10 +3050,10 @@ const n0 = (f) => {
|
|
|
2674
3050
|
},
|
|
2675
3051
|
//* A map from instance ID to instance object.
|
|
2676
3052
|
instances: {},
|
|
2677
|
-
attachUtils:
|
|
3053
|
+
attachUtils: n2,
|
|
2678
3054
|
startedLoadingUtilsScript: !1,
|
|
2679
3055
|
startedLoadingAutoCountry: !1,
|
|
2680
|
-
version: "25.10.
|
|
3056
|
+
version: "25.10.12"
|
|
2681
3057
|
}
|
|
2682
3058
|
);
|
|
2683
3059
|
(function() {
|
|
@@ -2686,23 +3062,23 @@ const n0 = (f) => {
|
|
|
2686
3062
|
d = d.split(".");
|
|
2687
3063
|
var n = f;
|
|
2688
3064
|
d[0] in n || typeof n.execScript > "u" || n.execScript("var " + d[0]);
|
|
2689
|
-
for (var
|
|
3065
|
+
for (var s; d.length && (s = d.shift()); ) d.length || t === void 0 ? n[s] && n[s] !== Object.prototype[s] ? n = n[s] : n = n[s] = {} : n[s] = t;
|
|
2690
3066
|
}
|
|
2691
3067
|
function $(d, t) {
|
|
2692
3068
|
function n() {
|
|
2693
3069
|
}
|
|
2694
|
-
n.prototype = t.prototype, d.ma = t.prototype, d.prototype = new n(), d.prototype.constructor = d, d.sa = function(
|
|
2695
|
-
for (var
|
|
2696
|
-
return t.prototype[o].apply(
|
|
3070
|
+
n.prototype = t.prototype, d.ma = t.prototype, d.prototype = new n(), d.prototype.constructor = d, d.sa = function(s, o, l) {
|
|
3071
|
+
for (var a = Array(arguments.length - 2), p = 2; p < arguments.length; p++) a[p - 2] = arguments[p];
|
|
3072
|
+
return t.prototype[o].apply(s, a);
|
|
2697
3073
|
};
|
|
2698
3074
|
}
|
|
2699
3075
|
function i(d) {
|
|
2700
3076
|
const t = [];
|
|
2701
3077
|
let n = 0;
|
|
2702
|
-
for (const
|
|
3078
|
+
for (const s in d) t[n++] = d[s];
|
|
2703
3079
|
return t;
|
|
2704
3080
|
}
|
|
2705
|
-
var
|
|
3081
|
+
var r = class {
|
|
2706
3082
|
constructor(d) {
|
|
2707
3083
|
if (u !== u) throw Error("SafeUrl is not meant to be built directly");
|
|
2708
3084
|
this.g = d;
|
|
@@ -2711,7 +3087,7 @@ const n0 = (f) => {
|
|
|
2711
3087
|
return this.g.toString();
|
|
2712
3088
|
}
|
|
2713
3089
|
}, u = {};
|
|
2714
|
-
new
|
|
3090
|
+
new r("about:invalid#zClosurez"), new r("about:blank");
|
|
2715
3091
|
const h = {};
|
|
2716
3092
|
class c {
|
|
2717
3093
|
constructor() {
|
|
@@ -2733,7 +3109,7 @@ const n0 = (f) => {
|
|
|
2733
3109
|
}
|
|
2734
3110
|
new g();
|
|
2735
3111
|
const I = {};
|
|
2736
|
-
class
|
|
3112
|
+
class w {
|
|
2737
3113
|
constructor() {
|
|
2738
3114
|
var t = f.trustedTypes && f.trustedTypes.emptyHTML || "";
|
|
2739
3115
|
if (I !== I) throw Error("SafeHtml is not meant to be built directly");
|
|
@@ -2743,74 +3119,74 @@ const n0 = (f) => {
|
|
|
2743
3119
|
return this.g.toString();
|
|
2744
3120
|
}
|
|
2745
3121
|
}
|
|
2746
|
-
new
|
|
2747
|
-
function
|
|
3122
|
+
new w();
|
|
3123
|
+
function k(d, t) {
|
|
2748
3124
|
switch (this.g = d, this.l = !!t.aa, this.h = t.i, this.s = t.type, this.o = !1, this.h) {
|
|
2749
|
-
case
|
|
2750
|
-
case
|
|
2751
|
-
case
|
|
2752
|
-
case
|
|
2753
|
-
case
|
|
2754
|
-
case
|
|
3125
|
+
case N:
|
|
3126
|
+
case P:
|
|
3127
|
+
case G:
|
|
3128
|
+
case j:
|
|
3129
|
+
case c0:
|
|
3130
|
+
case E:
|
|
2755
3131
|
case v:
|
|
2756
3132
|
this.o = !0;
|
|
2757
3133
|
}
|
|
2758
3134
|
this.j = t.defaultValue;
|
|
2759
3135
|
}
|
|
2760
|
-
var v = 1,
|
|
2761
|
-
function
|
|
3136
|
+
var v = 1, E = 2, N = 3, P = 4, G = 6, j = 16, c0 = 18;
|
|
3137
|
+
function f0(d, t) {
|
|
2762
3138
|
for (this.h = d, this.g = {}, d = 0; d < t.length; d++) {
|
|
2763
3139
|
var n = t[d];
|
|
2764
3140
|
this.g[n.g] = n;
|
|
2765
3141
|
}
|
|
2766
3142
|
}
|
|
2767
|
-
function
|
|
3143
|
+
function p0(d) {
|
|
2768
3144
|
return d = i(d.g), d.sort(function(t, n) {
|
|
2769
3145
|
return t.g - n.g;
|
|
2770
3146
|
}), d;
|
|
2771
3147
|
}
|
|
2772
|
-
function
|
|
3148
|
+
function x() {
|
|
2773
3149
|
this.h = {}, this.j = this.m().g, this.g = this.l = null;
|
|
2774
3150
|
}
|
|
2775
|
-
|
|
2776
|
-
return
|
|
2777
|
-
},
|
|
3151
|
+
x.prototype.has = function(d) {
|
|
3152
|
+
return B(this, d.g);
|
|
3153
|
+
}, x.prototype.get = function(d, t) {
|
|
2778
3154
|
return m(this, d.g, t);
|
|
2779
|
-
},
|
|
2780
|
-
|
|
2781
|
-
},
|
|
3155
|
+
}, x.prototype.set = function(d, t) {
|
|
3156
|
+
T(this, d.g, t);
|
|
3157
|
+
}, x.prototype.add = function(d, t) {
|
|
2782
3158
|
b1(this, d.g, t);
|
|
2783
3159
|
};
|
|
2784
3160
|
function S1(d, t) {
|
|
2785
|
-
for (var n =
|
|
2786
|
-
var o = n[
|
|
2787
|
-
if (
|
|
3161
|
+
for (var n = p0(d.m()), s = 0; s < n.length; s++) {
|
|
3162
|
+
var o = n[s], l = o.g;
|
|
3163
|
+
if (B(t, l)) {
|
|
2788
3164
|
d.g && delete d.g[o.g];
|
|
2789
|
-
var
|
|
3165
|
+
var a = o.h == 11 || o.h == 10;
|
|
2790
3166
|
if (o.l) {
|
|
2791
|
-
o =
|
|
2792
|
-
for (var p = 0; p < o.length; p++) b1(d,
|
|
2793
|
-
} else o =
|
|
3167
|
+
o = D(t, l);
|
|
3168
|
+
for (var p = 0; p < o.length; p++) b1(d, l, a ? o[p].clone() : o[p]);
|
|
3169
|
+
} else o = n1(t, l), a ? (a = n1(d, l)) ? S1(a, o) : T(d, l, o.clone()) : T(d, l, o);
|
|
2794
3170
|
}
|
|
2795
3171
|
}
|
|
2796
3172
|
}
|
|
2797
|
-
|
|
3173
|
+
x.prototype.clone = function() {
|
|
2798
3174
|
var d = new this.constructor();
|
|
2799
3175
|
return d != this && (d.h = {}, d.g && (d.g = {}), S1(d, this)), d;
|
|
2800
3176
|
};
|
|
2801
|
-
function
|
|
3177
|
+
function B(d, t) {
|
|
2802
3178
|
return d.h[t] != null;
|
|
2803
3179
|
}
|
|
2804
|
-
function
|
|
3180
|
+
function n1(d, t) {
|
|
2805
3181
|
var n = d.h[t];
|
|
2806
3182
|
if (n == null) return null;
|
|
2807
3183
|
if (d.l) {
|
|
2808
3184
|
if (!(t in d.g)) {
|
|
2809
|
-
var
|
|
3185
|
+
var s = d.l, o = d.j[t];
|
|
2810
3186
|
if (n != null) if (o.l) {
|
|
2811
|
-
for (var
|
|
2812
|
-
n =
|
|
2813
|
-
} else n =
|
|
3187
|
+
for (var l = [], a = 0; a < n.length; a++) l[a] = s.h(o, n[a]);
|
|
3188
|
+
n = l;
|
|
3189
|
+
} else n = s.h(o, n);
|
|
2814
3190
|
return d.g[t] = n;
|
|
2815
3191
|
}
|
|
2816
3192
|
return d.g[t];
|
|
@@ -2818,11 +3194,11 @@ const n0 = (f) => {
|
|
|
2818
3194
|
return n;
|
|
2819
3195
|
}
|
|
2820
3196
|
function m(d, t, n) {
|
|
2821
|
-
var
|
|
2822
|
-
return d.j[t].l ?
|
|
3197
|
+
var s = n1(d, t);
|
|
3198
|
+
return d.j[t].l ? s[n || 0] : s;
|
|
2823
3199
|
}
|
|
2824
|
-
function
|
|
2825
|
-
if (
|
|
3200
|
+
function S(d, t) {
|
|
3201
|
+
if (B(d, t)) d = m(d, t);
|
|
2826
3202
|
else d: {
|
|
2827
3203
|
if (d = d.j[t], d.j === void 0) if (t = d.s, t === Boolean) d.j = !1;
|
|
2828
3204
|
else if (t === Number) d.j = 0;
|
|
@@ -2835,29 +3211,29 @@ const n0 = (f) => {
|
|
|
2835
3211
|
}
|
|
2836
3212
|
return d;
|
|
2837
3213
|
}
|
|
2838
|
-
function
|
|
2839
|
-
return
|
|
3214
|
+
function D(d, t) {
|
|
3215
|
+
return n1(d, t) || [];
|
|
2840
3216
|
}
|
|
2841
|
-
function
|
|
2842
|
-
return d.j[t].l ?
|
|
3217
|
+
function K(d, t) {
|
|
3218
|
+
return d.j[t].l ? B(d, t) ? d.h[t].length : 0 : B(d, t) ? 1 : 0;
|
|
2843
3219
|
}
|
|
2844
|
-
function
|
|
3220
|
+
function T(d, t, n) {
|
|
2845
3221
|
d.h[t] = n, d.g && (d.g[t] = n);
|
|
2846
3222
|
}
|
|
2847
3223
|
function b1(d, t, n) {
|
|
2848
3224
|
d.h[t] || (d.h[t] = []), d.h[t].push(n), d.g && delete d.g[t];
|
|
2849
3225
|
}
|
|
2850
|
-
function
|
|
2851
|
-
var n = [],
|
|
2852
|
-
for (
|
|
2853
|
-
return new
|
|
3226
|
+
function i1(d, t) {
|
|
3227
|
+
var n = [], s;
|
|
3228
|
+
for (s in t) s != 0 && n.push(new k(s, t[s]));
|
|
3229
|
+
return new f0(d, n);
|
|
2854
3230
|
}
|
|
2855
|
-
function
|
|
3231
|
+
function r1() {
|
|
2856
3232
|
}
|
|
2857
|
-
|
|
3233
|
+
r1.prototype.g = function(d) {
|
|
2858
3234
|
throw new d.h(), Error("Unimplemented");
|
|
2859
|
-
},
|
|
2860
|
-
if (d.h == 11 || d.h == 10) return t instanceof
|
|
3235
|
+
}, r1.prototype.h = function(d, t) {
|
|
3236
|
+
if (d.h == 11 || d.h == 10) return t instanceof x ? t : this.g(d.s.prototype.m(), t);
|
|
2861
3237
|
if (d.h == 14) return typeof t == "string" && L1.test(t) && (d = Number(t), 0 < d) ? d : t;
|
|
2862
3238
|
if (!d.o) return t;
|
|
2863
3239
|
if (d = d.s, d === String) {
|
|
@@ -2868,55 +3244,55 @@ const n0 = (f) => {
|
|
|
2868
3244
|
var L1 = /^-?[0-9]+$/;
|
|
2869
3245
|
function p1() {
|
|
2870
3246
|
}
|
|
2871
|
-
$(p1,
|
|
3247
|
+
$(p1, r1), p1.prototype.g = function(d, t) {
|
|
2872
3248
|
return d = new d.h(), d.l = this, d.h = t, d.g = {}, d;
|
|
2873
3249
|
};
|
|
2874
|
-
function
|
|
3250
|
+
function q() {
|
|
2875
3251
|
}
|
|
2876
|
-
$(
|
|
2877
|
-
return d.h == 8 ? !!t :
|
|
2878
|
-
},
|
|
2879
|
-
return
|
|
3252
|
+
$(q, p1), q.prototype.h = function(d, t) {
|
|
3253
|
+
return d.h == 8 ? !!t : r1.prototype.h.apply(this, arguments);
|
|
3254
|
+
}, q.prototype.g = function(d, t) {
|
|
3255
|
+
return q.ma.g.call(this, d, t);
|
|
2880
3256
|
};
|
|
2881
|
-
function
|
|
3257
|
+
function A(d, t) {
|
|
2882
3258
|
d != null && this.g.apply(this, arguments);
|
|
2883
3259
|
}
|
|
2884
|
-
|
|
3260
|
+
A.prototype.h = "", A.prototype.set = function(d) {
|
|
2885
3261
|
this.h = "" + d;
|
|
2886
|
-
},
|
|
2887
|
-
if (this.h += String(d), t != null) for (let
|
|
3262
|
+
}, A.prototype.g = function(d, t, n) {
|
|
3263
|
+
if (this.h += String(d), t != null) for (let s = 1; s < arguments.length; s++) this.h += arguments[s];
|
|
2888
3264
|
return this;
|
|
2889
3265
|
};
|
|
2890
|
-
function
|
|
3266
|
+
function R(d) {
|
|
2891
3267
|
d.h = "";
|
|
2892
3268
|
}
|
|
2893
|
-
|
|
3269
|
+
A.prototype.toString = function() {
|
|
2894
3270
|
return this.h;
|
|
2895
3271
|
};
|
|
2896
|
-
function
|
|
2897
|
-
|
|
3272
|
+
function W() {
|
|
3273
|
+
x.call(this);
|
|
2898
3274
|
}
|
|
2899
|
-
$(
|
|
3275
|
+
$(W, x);
|
|
2900
3276
|
var N1 = null;
|
|
2901
3277
|
function b() {
|
|
2902
|
-
|
|
3278
|
+
x.call(this);
|
|
2903
3279
|
}
|
|
2904
|
-
$(b,
|
|
3280
|
+
$(b, x);
|
|
2905
3281
|
var A1 = null;
|
|
2906
|
-
function
|
|
2907
|
-
|
|
3282
|
+
function z() {
|
|
3283
|
+
x.call(this);
|
|
2908
3284
|
}
|
|
2909
|
-
$(
|
|
3285
|
+
$(z, x);
|
|
2910
3286
|
var E1 = null;
|
|
2911
|
-
|
|
3287
|
+
W.prototype.m = function() {
|
|
2912
3288
|
var d = N1;
|
|
2913
|
-
return d || (N1 = d =
|
|
2914
|
-
},
|
|
3289
|
+
return d || (N1 = d = i1(W, { 0: { name: "NumberFormat", ia: "i18n.phonenumbers.NumberFormat" }, 1: { name: "pattern", required: !0, i: 9, type: String }, 2: { name: "format", required: !0, i: 9, type: String }, 3: { name: "leading_digits_pattern", aa: !0, i: 9, type: String }, 4: { name: "national_prefix_formatting_rule", i: 9, type: String }, 6: { name: "national_prefix_optional_when_formatting", i: 8, defaultValue: !1, type: Boolean }, 5: { name: "domestic_carrier_code_formatting_rule", i: 9, type: String } })), d;
|
|
3290
|
+
}, W.m = W.prototype.m, b.prototype.m = function() {
|
|
2915
3291
|
var d = A1;
|
|
2916
|
-
return d || (A1 = d =
|
|
2917
|
-
}, b.m = b.prototype.m,
|
|
3292
|
+
return d || (A1 = d = i1(b, { 0: { name: "PhoneNumberDesc", ia: "i18n.phonenumbers.PhoneNumberDesc" }, 2: { name: "national_number_pattern", i: 9, type: String }, 9: { name: "possible_length", aa: !0, i: 5, type: Number }, 10: { name: "possible_length_local_only", aa: !0, i: 5, type: Number }, 6: { name: "example_number", i: 9, type: String } })), d;
|
|
3293
|
+
}, b.m = b.prototype.m, z.prototype.m = function() {
|
|
2918
3294
|
var d = E1;
|
|
2919
|
-
return d || (E1 = d =
|
|
3295
|
+
return d || (E1 = d = i1(z, {
|
|
2920
3296
|
0: { name: "PhoneMetadata", ia: "i18n.phonenumbers.PhoneMetadata" },
|
|
2921
3297
|
1: { name: "general_desc", i: 11, type: b },
|
|
2922
3298
|
2: { name: "fixed_line", i: 11, type: b },
|
|
@@ -2948,26 +3324,26 @@ const n0 = (f) => {
|
|
|
2948
3324
|
},
|
|
2949
3325
|
16: { name: "national_prefix_transform_rule", i: 9, type: String },
|
|
2950
3326
|
18: { name: "same_mobile_and_fixed_line_pattern", i: 8, defaultValue: !1, type: Boolean },
|
|
2951
|
-
19: { name: "number_format", aa: !0, i: 11, type:
|
|
2952
|
-
20: { name: "intl_number_format", aa: !0, i: 11, type:
|
|
3327
|
+
19: { name: "number_format", aa: !0, i: 11, type: W },
|
|
3328
|
+
20: { name: "intl_number_format", aa: !0, i: 11, type: W },
|
|
2953
3329
|
22: { name: "main_country_for_code", i: 8, defaultValue: !1, type: Boolean },
|
|
2954
3330
|
23: { name: "leading_digits", i: 9, type: String }
|
|
2955
3331
|
})), d;
|
|
2956
|
-
},
|
|
2957
|
-
function
|
|
2958
|
-
|
|
3332
|
+
}, z.m = z.prototype.m;
|
|
3333
|
+
function V() {
|
|
3334
|
+
x.call(this);
|
|
2959
3335
|
}
|
|
2960
|
-
$(
|
|
2961
|
-
var T1 = null,
|
|
2962
|
-
|
|
3336
|
+
$(V, x);
|
|
3337
|
+
var T1 = null, g0 = { ra: 0, qa: 1, pa: 5, oa: 10, na: 20 };
|
|
3338
|
+
V.prototype.m = function() {
|
|
2963
3339
|
var d = T1;
|
|
2964
|
-
return d || (T1 = d =
|
|
3340
|
+
return d || (T1 = d = i1(V, { 0: { name: "PhoneNumber", ia: "i18n.phonenumbers.PhoneNumber" }, 1: { name: "country_code", required: !0, i: 5, type: Number }, 2: { name: "national_number", required: !0, i: 4, type: Number }, 3: { name: "extension", i: 9, type: String }, 4: { name: "italian_leading_zero", i: 8, type: Boolean }, 8: { name: "number_of_leading_zeros", i: 5, defaultValue: 1, type: Number }, 5: { name: "raw_input", i: 9, type: String }, 6: { name: "country_code_source", i: 14, defaultValue: 0, type: g0 }, 7: {
|
|
2965
3341
|
name: "preferred_domestic_carrier_code",
|
|
2966
3342
|
i: 9,
|
|
2967
3343
|
type: String
|
|
2968
3344
|
} })), d;
|
|
2969
|
-
},
|
|
2970
|
-
var
|
|
3345
|
+
}, V.ctor = V, V.ctor.m = V.prototype.m;
|
|
3346
|
+
var X = {
|
|
2971
3347
|
1: "US AG AI AS BB BM BS CA DM DO GD GU JM KN KY LC MP MS PR SX TC TT VC VG VI".split(" "),
|
|
2972
3348
|
7: ["RU", "KZ"],
|
|
2973
3349
|
20: ["EG"],
|
|
@@ -8317,13 +8693,13 @@ const n0 = (f) => {
|
|
|
8317
8693
|
], [, , , , , , , , , [-1]], [, , , , , , , , , [-1]], "001", 888, , , , , , , , 1, [[, "(\\d{3})(\\d{3})(\\d{5})", "$1 $2 $3"]], , [, , , , , , , , , [-1]], , , [, , , , , , , , , [-1]], [, , "\\d{11}", , , , "12345678901"], , , [, , , , , , , , , [-1]]],
|
|
8318
8694
|
979: [, [, , "[1359]\\d{8}", , , , , , , [9], [8]], [, , , , , , , , , [-1]], [, , , , , , , , , [-1]], [, , , , , , , , , [-1]], [, , "[1359]\\d{8}", , , , "123456789", , , , [8]], [, , , , , , , , , [-1]], [, , , , , , , , , [-1]], [, , , , , , , , , [-1]], "001", 979, , , , , , , , 1, [[, "(\\d)(\\d{4})(\\d{4})", "$1 $2 $3", ["[1359]"]]], , [, , , , , , , , , [-1]], , , [, , , , , , , , , [-1]], [, , , , , , , , , [-1]], , , [, , , , , , , , , [-1]]]
|
|
8319
8695
|
};
|
|
8320
|
-
function
|
|
8696
|
+
function M() {
|
|
8321
8697
|
this.g = {};
|
|
8322
8698
|
}
|
|
8323
|
-
|
|
8324
|
-
return
|
|
8699
|
+
M.h = void 0, M.g = function() {
|
|
8700
|
+
return M.h ? M.h : M.h = new M();
|
|
8325
8701
|
};
|
|
8326
|
-
var g1 = { 0: "0", 1: "1", 2: "2", 3: "3", 4: "4", 5: "5", 6: "6", 7: "7", 8: "8", 9: "9", "0": "0", "1": "1", "2": "2", "3": "3", "4": "4", "5": "5", "6": "6", "7": "7", "8": "8", "9": "9", "٠": "0", "١": "1", "٢": "2", "٣": "3", "٤": "4", "٥": "5", "٦": "6", "٧": "7", "٨": "8", "٩": "9", "۰": "0", "۱": "1", "۲": "2", "۳": "3", "۴": "4", "۵": "5", "۶": "6", "۷": "7", "۸": "8", "۹": "9" },
|
|
8702
|
+
var g1 = { 0: "0", 1: "1", 2: "2", 3: "3", 4: "4", 5: "5", 6: "6", 7: "7", 8: "8", 9: "9", "0": "0", "1": "1", "2": "2", "3": "3", "4": "4", "5": "5", "6": "6", "7": "7", "8": "8", "9": "9", "٠": "0", "١": "1", "٢": "2", "٣": "3", "٤": "4", "٥": "5", "٦": "6", "٧": "7", "٨": "8", "٩": "9", "۰": "0", "۱": "1", "۲": "2", "۳": "3", "۴": "4", "۵": "5", "۶": "6", "۷": "7", "۸": "8", "۹": "9" }, m0 = {
|
|
8327
8703
|
0: "0",
|
|
8328
8704
|
1: "1",
|
|
8329
8705
|
2: "2",
|
|
@@ -8337,7 +8713,7 @@ const n0 = (f) => {
|
|
|
8337
8713
|
"+": "+",
|
|
8338
8714
|
"*": "*",
|
|
8339
8715
|
"#": "#"
|
|
8340
|
-
},
|
|
8716
|
+
}, C0 = {
|
|
8341
8717
|
0: "0",
|
|
8342
8718
|
1: "1",
|
|
8343
8719
|
2: "2",
|
|
@@ -8404,86 +8780,86 @@ const n0 = (f) => {
|
|
|
8404
8780
|
X: "9",
|
|
8405
8781
|
Y: "9",
|
|
8406
8782
|
Z: "9"
|
|
8407
|
-
},
|
|
8408
|
-
function
|
|
8783
|
+
}, y0 = RegExp("[++]+"), Q = RegExp("^[++]+"), D1 = RegExp("([0-90-9٠-٩۰-۹])"), _0 = RegExp("[++0-90-9٠-٩۰-۹]"), I0 = /[\\\/] *x/, v0 = RegExp("[^0-90-9٠-٩۰-۹A-Za-z#]+$"), w0 = /(?:.*?[A-Za-z]){3}.*/, S0 = RegExp("^\\+([0-90-9٠-٩۰-۹]|[\\-\\.\\(\\)]?)*[0-90-9٠-٩۰-۹]([0-90-9٠-٩۰-۹]|[\\-\\.\\(\\)]?)*$"), b0 = RegExp("^([A-Za-z0-90-9٠-٩۰-۹]+((\\-)*[A-Za-z0-90-9٠-٩۰-۹])*\\.)*[A-Za-z]+((\\-)*[A-Za-z0-90-9٠-٩۰-۹])*\\.?$");
|
|
8784
|
+
function J(d) {
|
|
8409
8785
|
return "([0-90-9٠-٩۰-۹]{1," + d + "})";
|
|
8410
8786
|
}
|
|
8411
8787
|
function P1() {
|
|
8412
|
-
return ";ext=" +
|
|
8788
|
+
return ";ext=" + J("20") + "|[ \\t,]*(?:e?xt(?:ensi(?:ó?|ó))?n?|e?xtn?|доб|anexo)[:\\..]?[ \\t,-]*" + (J("20") + "#?|[ \\t,]*(?:[xx##~~]|int|int)[:\\..]?[ \\t,-]*") + (J("9") + "#?|[- ]+") + (J("6") + "#|[ \\t]*(?:,{2}|;)[:\\..]?[ \\t,-]*") + (J("15") + "#?|[ \\t]*(?:,)+[:\\..]?[ \\t,-]*") + (J("9") + "#?");
|
|
8413
8789
|
}
|
|
8414
|
-
var x1 = new RegExp("(?:" + P1() + ")$", "i"),
|
|
8790
|
+
var x1 = new RegExp("(?:" + P1() + ")$", "i"), L0 = new RegExp("^[0-90-9٠-٩۰-۹]{2}$|^[++]*(?:[-x‐-―−ー--/ ()()[].\\[\\]/~⁓∼~*]*[0-90-9٠-٩۰-۹]){3,}[-x‐-―−ー--/ ()()[].\\[\\]/~⁓∼~*A-Za-z0-90-9٠-٩۰-۹]*(?:" + P1() + ")?$", "i"), N0 = /(\$\d)/, A0 = /^\(?\$1\)?$/;
|
|
8415
8791
|
function B1(d) {
|
|
8416
|
-
return 2 > d.length ? !1 :
|
|
8792
|
+
return 2 > d.length ? !1 : U(L0, d);
|
|
8417
8793
|
}
|
|
8418
8794
|
function R1(d) {
|
|
8419
|
-
return
|
|
8795
|
+
return U(w0, d) ? s1(d, C0) : s1(d, g1);
|
|
8420
8796
|
}
|
|
8421
8797
|
function k1(d) {
|
|
8422
8798
|
var t = R1(d.toString());
|
|
8423
|
-
|
|
8799
|
+
R(d), d.g(t);
|
|
8424
8800
|
}
|
|
8425
8801
|
function O1(d) {
|
|
8426
|
-
return d != null && (
|
|
8802
|
+
return d != null && (K(d, 9) != 1 || D(d, 9)[0] != -1);
|
|
8427
8803
|
}
|
|
8428
8804
|
function s1(d, t) {
|
|
8429
|
-
for (var n = new
|
|
8805
|
+
for (var n = new A(), s, o = d.length, l = 0; l < o; ++l) s = d.charAt(l), s = t[s.toUpperCase()], s != null && n.g(s);
|
|
8430
8806
|
return n.toString();
|
|
8431
8807
|
}
|
|
8432
8808
|
function G1(d) {
|
|
8433
|
-
return d.length == 0 ||
|
|
8809
|
+
return d.length == 0 || A0.test(d);
|
|
8434
8810
|
}
|
|
8435
|
-
function
|
|
8811
|
+
function o1(d) {
|
|
8436
8812
|
return d != null && isNaN(d) && d.toUpperCase() in M1;
|
|
8437
8813
|
}
|
|
8438
|
-
|
|
8439
|
-
if (m(d, 2) == 0 &&
|
|
8440
|
-
var n =
|
|
8814
|
+
M.prototype.format = function(d, t) {
|
|
8815
|
+
if (m(d, 2) == 0 && B(d, 5)) {
|
|
8816
|
+
var n = S(d, 5);
|
|
8441
8817
|
if (0 < n.length) return n;
|
|
8442
8818
|
}
|
|
8443
|
-
n =
|
|
8444
|
-
var
|
|
8445
|
-
if (t == 0) return U1(n, 0,
|
|
8446
|
-
if (!(n in
|
|
8447
|
-
var o =
|
|
8448
|
-
d =
|
|
8819
|
+
n = S(d, 1);
|
|
8820
|
+
var s = t1(d);
|
|
8821
|
+
if (t == 0) return U1(n, 0, s, "");
|
|
8822
|
+
if (!(n in X)) return s;
|
|
8823
|
+
var o = d1(this, n, e1(n));
|
|
8824
|
+
d = B(d, 3) && m(d, 3).length != 0 ? t == 3 ? ";ext=" + m(d, 3) : B(o, 13) ? m(o, 13) + S(d, 3) : " ext. " + S(d, 3) : "";
|
|
8449
8825
|
d: {
|
|
8450
|
-
o =
|
|
8451
|
-
for (var
|
|
8452
|
-
|
|
8453
|
-
var _ =
|
|
8454
|
-
if ((_ == 0 ||
|
|
8455
|
-
o =
|
|
8826
|
+
o = D(o, 20).length == 0 || t == 2 ? D(o, 19) : D(o, 20);
|
|
8827
|
+
for (var l, a = o.length, p = 0; p < a; ++p) {
|
|
8828
|
+
l = o[p];
|
|
8829
|
+
var _ = K(l, 3);
|
|
8830
|
+
if ((_ == 0 || s.search(m(l, 3, _ - 1)) == 0) && (_ = new RegExp(m(l, 1)), U(_, s))) {
|
|
8831
|
+
o = l;
|
|
8456
8832
|
break d;
|
|
8457
8833
|
}
|
|
8458
8834
|
}
|
|
8459
8835
|
o = null;
|
|
8460
8836
|
}
|
|
8461
|
-
return o != null && (
|
|
8462
|
-
|
|
8837
|
+
return o != null && (a = o, o = S(a, 2), l = new RegExp(m(a, 1)), S(
|
|
8838
|
+
a,
|
|
8463
8839
|
5
|
|
8464
|
-
),
|
|
8840
|
+
), a = S(a, 4), s = t == 2 && a != null && 0 < a.length ? s.replace(l, o.replace(N0, a)) : s.replace(l, o), t == 3 && (s = s.replace(RegExp("^[-x‐-―−ー--/ ()()[].\\[\\]/~⁓∼~]+"), ""), s = s.replace(RegExp("[-x‐-―−ー--/ ()()[].\\[\\]/~⁓∼~]+", "g"), "-"))), U1(n, t, s, d);
|
|
8465
8841
|
};
|
|
8466
|
-
function
|
|
8467
|
-
return n == "001" ?
|
|
8842
|
+
function d1(d, t, n) {
|
|
8843
|
+
return n == "001" ? H(d, "" + t) : H(d, n);
|
|
8468
8844
|
}
|
|
8469
|
-
function
|
|
8470
|
-
if (!
|
|
8845
|
+
function t1(d) {
|
|
8846
|
+
if (!B(d, 2)) return "";
|
|
8471
8847
|
var t = "" + m(d, 2);
|
|
8472
|
-
return
|
|
8848
|
+
return B(d, 4) && m(d, 4) && 0 < S(d, 8) ? Array(S(d, 8) + 1).join("0") + t : t;
|
|
8473
8849
|
}
|
|
8474
|
-
function U1(d, t, n,
|
|
8850
|
+
function U1(d, t, n, s) {
|
|
8475
8851
|
switch (t) {
|
|
8476
8852
|
case 0:
|
|
8477
|
-
return "+" + d + n +
|
|
8853
|
+
return "+" + d + n + s;
|
|
8478
8854
|
case 1:
|
|
8479
|
-
return "+" + d + " " + n +
|
|
8855
|
+
return "+" + d + " " + n + s;
|
|
8480
8856
|
case 3:
|
|
8481
|
-
return "tel:+" + d + "-" + n +
|
|
8857
|
+
return "tel:+" + d + "-" + n + s;
|
|
8482
8858
|
default:
|
|
8483
|
-
return n +
|
|
8859
|
+
return n + s;
|
|
8484
8860
|
}
|
|
8485
8861
|
}
|
|
8486
|
-
function
|
|
8862
|
+
function l1(d, t) {
|
|
8487
8863
|
switch (t) {
|
|
8488
8864
|
case 4:
|
|
8489
8865
|
return m(d, 5);
|
|
@@ -8512,46 +8888,46 @@ const n0 = (f) => {
|
|
|
8512
8888
|
}
|
|
8513
8889
|
function F1(d, t) {
|
|
8514
8890
|
var n = K1(d, t);
|
|
8515
|
-
return d =
|
|
8891
|
+
return d = d1(d, S(t, 1), n), d == null ? -1 : (t = t1(t), m1(t, d));
|
|
8516
8892
|
}
|
|
8517
8893
|
function m1(d, t) {
|
|
8518
8894
|
return O(d, m(t, 1)) ? O(d, m(t, 5)) ? 4 : O(d, m(t, 4)) ? 3 : O(d, m(t, 6)) ? 5 : O(d, m(t, 8)) ? 6 : O(d, m(t, 7)) ? 7 : O(d, m(t, 21)) ? 8 : O(d, m(t, 25)) ? 9 : O(d, m(t, 28)) ? 10 : O(d, m(t, 2)) ? m(t, 18) || O(d, m(t, 3)) ? 2 : 0 : !m(t, 18) && O(d, m(t, 3)) ? 1 : -1 : -1;
|
|
8519
8895
|
}
|
|
8520
|
-
function
|
|
8896
|
+
function H(d, t) {
|
|
8521
8897
|
if (t == null) return null;
|
|
8522
8898
|
t = t.toUpperCase();
|
|
8523
8899
|
var n = d.g[t];
|
|
8524
8900
|
if (n == null) {
|
|
8525
8901
|
if (n = M1[t], n == null) return null;
|
|
8526
|
-
n = new
|
|
8902
|
+
n = new q().g(z.m(), n), d.g[t] = n;
|
|
8527
8903
|
}
|
|
8528
8904
|
return n;
|
|
8529
8905
|
}
|
|
8530
8906
|
function O(d, t) {
|
|
8531
8907
|
var n = d.length;
|
|
8532
|
-
return 0 <
|
|
8908
|
+
return 0 < K(t, 9) && D(t, 9).indexOf(n) == -1 ? !1 : U(S(t, 2), d);
|
|
8533
8909
|
}
|
|
8534
|
-
function
|
|
8535
|
-
var n = K1(d, t),
|
|
8536
|
-
return o == null || n != "001" &&
|
|
8910
|
+
function E0(d, t) {
|
|
8911
|
+
var n = K1(d, t), s = S(t, 1), o = d1(d, s, n);
|
|
8912
|
+
return o == null || n != "001" && s != V1(d, n) ? o = !1 : (d = t1(t), o = m1(d, o) != -1), o;
|
|
8537
8913
|
}
|
|
8538
8914
|
function K1(d, t) {
|
|
8539
8915
|
if (t == null) return null;
|
|
8540
|
-
var n =
|
|
8541
|
-
if (n =
|
|
8916
|
+
var n = S(t, 1);
|
|
8917
|
+
if (n = X[n], n == null) d = null;
|
|
8542
8918
|
else if (n.length == 1) d = n[0];
|
|
8543
8919
|
else d: {
|
|
8544
|
-
t =
|
|
8545
|
-
for (var
|
|
8546
|
-
|
|
8547
|
-
var
|
|
8548
|
-
if (
|
|
8549
|
-
if (t.search(m(
|
|
8550
|
-
d =
|
|
8920
|
+
t = t1(t);
|
|
8921
|
+
for (var s, o = n.length, l = 0; l < o; l++) {
|
|
8922
|
+
s = n[l];
|
|
8923
|
+
var a = H(d, s);
|
|
8924
|
+
if (B(a, 23)) {
|
|
8925
|
+
if (t.search(m(a, 23)) == 0) {
|
|
8926
|
+
d = s;
|
|
8551
8927
|
break d;
|
|
8552
8928
|
}
|
|
8553
|
-
} else if (m1(t,
|
|
8554
|
-
d =
|
|
8929
|
+
} else if (m1(t, a) != -1) {
|
|
8930
|
+
d = s;
|
|
8555
8931
|
break d;
|
|
8556
8932
|
}
|
|
8557
8933
|
}
|
|
@@ -8559,151 +8935,151 @@ const n0 = (f) => {
|
|
|
8559
8935
|
}
|
|
8560
8936
|
return d;
|
|
8561
8937
|
}
|
|
8562
|
-
function
|
|
8563
|
-
return d =
|
|
8938
|
+
function e1(d) {
|
|
8939
|
+
return d = X[d], d == null ? "ZZ" : d[0];
|
|
8564
8940
|
}
|
|
8565
8941
|
function V1(d, t) {
|
|
8566
|
-
if (d =
|
|
8567
|
-
return
|
|
8942
|
+
if (d = H(d, t), d == null) throw Error("Invalid region code: " + t);
|
|
8943
|
+
return S(d, 10);
|
|
8568
8944
|
}
|
|
8569
|
-
function
|
|
8570
|
-
var o =
|
|
8571
|
-
if (o =
|
|
8572
|
-
else return
|
|
8573
|
-
return
|
|
8945
|
+
function u1(d, t, n, s) {
|
|
8946
|
+
var o = l1(n, s), l = K(o, 9) == 0 ? D(m(n, 1), 9) : D(o, 9);
|
|
8947
|
+
if (o = D(o, 10), s == 2) if (O1(l1(n, 0))) d = l1(n, 1), O1(d) && (l = l.concat(K(d, 9) == 0 ? D(m(n, 1), 9) : D(d, 9)), l.sort(), o.length == 0 ? o = D(d, 10) : (o = o.concat(D(d, 10)), o.sort()));
|
|
8948
|
+
else return u1(d, t, n, 1);
|
|
8949
|
+
return l[0] == -1 ? 5 : (t = t.length, -1 < o.indexOf(t) ? 4 : (n = l[0], n == t ? 0 : n > t ? 2 : l[l.length - 1] < t ? 3 : -1 < l.indexOf(t, 1) ? 0 : 5));
|
|
8574
8950
|
}
|
|
8575
|
-
function
|
|
8576
|
-
var
|
|
8577
|
-
return t =
|
|
8951
|
+
function a1(d, t, n) {
|
|
8952
|
+
var s = t1(t);
|
|
8953
|
+
return t = S(t, 1), t in X ? (t = d1(d, t, e1(t)), u1(d, s, t, n)) : 1;
|
|
8578
8954
|
}
|
|
8579
8955
|
function H1(d, t) {
|
|
8580
8956
|
if (d = d.toString(), d.length == 0 || d.charAt(0) == "0") return 0;
|
|
8581
|
-
for (var n,
|
|
8957
|
+
for (var n, s = d.length, o = 1; 3 >= o && o <= s; ++o) if (n = parseInt(d.substring(0, o), 10), n in X) return t.g(d.substring(o)), n;
|
|
8582
8958
|
return 0;
|
|
8583
8959
|
}
|
|
8584
|
-
function j1(d, t, n,
|
|
8960
|
+
function j1(d, t, n, s, o, l) {
|
|
8585
8961
|
if (t.length == 0) return 0;
|
|
8586
|
-
t = new
|
|
8587
|
-
var
|
|
8588
|
-
n != null && (
|
|
8962
|
+
t = new A(t);
|
|
8963
|
+
var a;
|
|
8964
|
+
n != null && (a = m(n, 11)), a == null && (a = "NonMatch");
|
|
8589
8965
|
var p = t.toString();
|
|
8590
|
-
if (p.length == 0)
|
|
8591
|
-
else if (
|
|
8966
|
+
if (p.length == 0) a = 20;
|
|
8967
|
+
else if (Q.test(p)) p = p.replace(Q, ""), R(t), t.g(R1(p)), a = 1;
|
|
8592
8968
|
else {
|
|
8593
|
-
if (p = new RegExp(
|
|
8594
|
-
p =
|
|
8595
|
-
var _ =
|
|
8596
|
-
_ && _[1] != null && 0 < _[1].length && s1(_[1], g1) == "0" ?
|
|
8597
|
-
} else
|
|
8598
|
-
|
|
8969
|
+
if (p = new RegExp(a), k1(t), a = t.toString(), a.search(p) == 0) {
|
|
8970
|
+
p = a.match(p)[0].length;
|
|
8971
|
+
var _ = a.substring(p).match(D1);
|
|
8972
|
+
_ && _[1] != null && 0 < _[1].length && s1(_[1], g1) == "0" ? a = !1 : (R(t), t.g(a.substring(p)), a = !0);
|
|
8973
|
+
} else a = !1;
|
|
8974
|
+
a = a ? 5 : 20;
|
|
8599
8975
|
}
|
|
8600
|
-
if (o &&
|
|
8976
|
+
if (o && T(l, 6, a), a != 20) {
|
|
8601
8977
|
if (2 >= t.h.length) throw Error("Phone number too short after IDD");
|
|
8602
|
-
if (d = H1(t,
|
|
8978
|
+
if (d = H1(t, s), d != 0) return T(l, 1, d), d;
|
|
8603
8979
|
throw Error("Invalid country calling code");
|
|
8604
8980
|
}
|
|
8605
|
-
return n != null && (
|
|
8981
|
+
return n != null && (a = S(n, 10), p = "" + a, _ = t.toString(), _.lastIndexOf(p, 0) == 0 && (p = new A(_.substring(p.length)), _ = m(n, 1), _ = new RegExp(S(_, 2)), W1(p, n, null), p = p.toString(), !U(_, t.toString()) && U(_, p) || u1(d, t.toString(), n, -1) == 3)) ? (s.g(p), o && T(l, 6, 10), T(l, 1, a), a) : (T(l, 1, 0), 0);
|
|
8606
8982
|
}
|
|
8607
8983
|
function W1(d, t, n) {
|
|
8608
|
-
var
|
|
8609
|
-
if (o != 0 &&
|
|
8610
|
-
var
|
|
8611
|
-
if (o =
|
|
8612
|
-
|
|
8613
|
-
var p =
|
|
8614
|
-
t = m(t, 16), t == null || t.length == 0 || o[_] == null || o[_].length == 0 ? (!p ||
|
|
8984
|
+
var s = d.toString(), o = s.length, l = m(t, 15);
|
|
8985
|
+
if (o != 0 && l != null && l.length != 0) {
|
|
8986
|
+
var a = new RegExp("^(?:" + l + ")");
|
|
8987
|
+
if (o = a.exec(s)) {
|
|
8988
|
+
l = new RegExp(S(m(t, 1), 2));
|
|
8989
|
+
var p = U(l, s), _ = o.length - 1;
|
|
8990
|
+
t = m(t, 16), t == null || t.length == 0 || o[_] == null || o[_].length == 0 ? (!p || U(l, s.substring(o[0].length))) && (n != null && 0 < _ && o[_] != null && n.g(o[1]), d.set(s.substring(o[0].length))) : (s = s.replace(a, t), (!p || U(l, s)) && (n != null && 0 < _ && n.g(o[1]), d.set(s)));
|
|
8615
8991
|
}
|
|
8616
8992
|
}
|
|
8617
8993
|
}
|
|
8618
|
-
function
|
|
8619
|
-
if (!
|
|
8994
|
+
function Z(d, t, n) {
|
|
8995
|
+
if (!o1(n) && 0 < t.length && t.charAt(0) != "+") throw Error("Invalid country calling code");
|
|
8620
8996
|
return z1(d, t, n, !0);
|
|
8621
8997
|
}
|
|
8622
|
-
function z1(d, t, n,
|
|
8998
|
+
function z1(d, t, n, s) {
|
|
8623
8999
|
if (t == null) throw Error("The string supplied did not seem to be a phone number");
|
|
8624
9000
|
if (250 < t.length) throw Error("The string supplied is too long to be a phone number");
|
|
8625
|
-
var o = new
|
|
8626
|
-
if (
|
|
8627
|
-
else if (
|
|
9001
|
+
var o = new A(), l = t.indexOf(";phone-context=");
|
|
9002
|
+
if (l === -1) l = null;
|
|
9003
|
+
else if (l += 15, l >= t.length) l = "";
|
|
8628
9004
|
else {
|
|
8629
|
-
var
|
|
8630
|
-
|
|
9005
|
+
var a = t.indexOf(";", l);
|
|
9006
|
+
l = a !== -1 ? t.substring(l, a) : t.substring(l);
|
|
8631
9007
|
}
|
|
8632
|
-
var p =
|
|
8633
|
-
if (p == null ?
|
|
8634
|
-
if (
|
|
8635
|
-
|
|
9008
|
+
var p = l;
|
|
9009
|
+
if (p == null ? a = !0 : p.length === 0 ? a = !1 : (a = S0.exec(p), p = b0.exec(p), a = a !== null || p !== null), !a || (l != null ? (l.charAt(0) === "+" && o.g(l), l = t.indexOf("tel:"), o.g(t.substring(0 <= l ? l + 4 : 0, t.indexOf(";phone-context=")))) : (l = o.g, a = t ?? "", p = a.search(_0), 0 <= p ? (a = a.substring(p), a = a.replace(v0, ""), p = a.search(I0), 0 <= p && (a = a.substring(0, p))) : a = "", l.call(o, a)), l = o.toString(), a = l.indexOf(";isub="), 0 < a && (R(o), o.g(l.substring(0, a))), !B1(o.toString()))) throw Error("The string supplied did not seem to be a phone number");
|
|
9010
|
+
if (l = o.toString(), !(o1(n) || l != null && 0 < l.length && Q.test(l))) throw Error("Invalid country calling code");
|
|
9011
|
+
l = new V(), s && T(l, 5, t);
|
|
8636
9012
|
d: {
|
|
8637
|
-
if (t = o.toString(),
|
|
9013
|
+
if (t = o.toString(), a = t.search(x1), 0 <= a && B1(t.substring(0, a))) {
|
|
8638
9014
|
p = t.match(x1);
|
|
8639
|
-
for (var _ = p.length,
|
|
8640
|
-
|
|
9015
|
+
for (var _ = p.length, F = 1; F < _; ++F) if (p[F] != null && 0 < p[F].length) {
|
|
9016
|
+
R(o), o.g(t.substring(0, a)), t = p[F];
|
|
8641
9017
|
break d;
|
|
8642
9018
|
}
|
|
8643
9019
|
}
|
|
8644
9020
|
t = "";
|
|
8645
9021
|
}
|
|
8646
|
-
0 < t.length &&
|
|
9022
|
+
0 < t.length && T(l, 3, t), a = H(d, n), t = new A(), p = 0, _ = o.toString();
|
|
8647
9023
|
try {
|
|
8648
|
-
p = j1(d, _,
|
|
9024
|
+
p = j1(d, _, a, t, s, l);
|
|
8649
9025
|
} catch (_1) {
|
|
8650
|
-
if (_1.message == "Invalid country calling code" &&
|
|
8651
|
-
if (_ = _.replace(
|
|
9026
|
+
if (_1.message == "Invalid country calling code" && Q.test(_)) {
|
|
9027
|
+
if (_ = _.replace(Q, ""), p = j1(d, _, a, t, s, l), p == 0) throw _1;
|
|
8652
9028
|
} else throw _1;
|
|
8653
9029
|
}
|
|
8654
|
-
if (p != 0 ? (o =
|
|
8655
|
-
|
|
9030
|
+
if (p != 0 ? (o = e1(p), o != n && (a = d1(d, p, o))) : (k1(o), t.g(o.toString()), n != null ? (p = S(a, 10), T(
|
|
9031
|
+
l,
|
|
8656
9032
|
1,
|
|
8657
9033
|
p
|
|
8658
|
-
)) :
|
|
9034
|
+
)) : s && (delete l.h[6], l.g && delete l.g[6])), 2 > t.h.length || (a != null && (n = new A(), o = new A(t.toString()), W1(o, a, n), d = u1(d, o.toString(), a, -1), d != 2 && d != 4 && d != 5 && (t = o, s && 0 < n.toString().length && T(l, 7, n.toString()))), s = t.toString(), d = s.length, 2 > d)) throw Error("The string supplied is too short to be a phone number");
|
|
8659
9035
|
if (17 < d) throw Error("The string supplied is too long to be a phone number");
|
|
8660
|
-
if (1 <
|
|
8661
|
-
for (
|
|
8662
|
-
d != 1 &&
|
|
9036
|
+
if (1 < s.length && s.charAt(0) == "0") {
|
|
9037
|
+
for (T(l, 4, !0), d = 1; d < s.length - 1 && s.charAt(d) == "0"; ) d++;
|
|
9038
|
+
d != 1 && T(l, 8, d);
|
|
8663
9039
|
}
|
|
8664
|
-
return
|
|
9040
|
+
return T(l, 2, parseInt(s, 10)), l;
|
|
8665
9041
|
}
|
|
8666
|
-
function
|
|
9042
|
+
function U(d, t) {
|
|
8667
9043
|
return !!((d = t.match(new RegExp("^(?:" + (typeof d == "string" ? d : d.source) + ")$", "i"))) && d[0].length == t.length);
|
|
8668
9044
|
}
|
|
8669
|
-
function
|
|
8670
|
-
this.fa = RegExp(" "), this.ja = "", this.v = new
|
|
9045
|
+
function T0(d) {
|
|
9046
|
+
this.fa = RegExp(" "), this.ja = "", this.v = new A(), this.da = "", this.s = new A(), this.ba = new A(), this.u = !0, this.ea = this.ca = this.la = !1, this.ga = M.g(), this.$ = 0, this.h = new A(), this.ha = !1, this.o = "", this.g = new A(), this.j = [], this.ka = d, this.l = J1(this, this.ka);
|
|
8671
9047
|
}
|
|
8672
|
-
var Z1 = new
|
|
8673
|
-
|
|
8674
|
-
var
|
|
9048
|
+
var Z1 = new z();
|
|
9049
|
+
T(Z1, 11, "NA");
|
|
9050
|
+
var M0 = RegExp("^[-x‐-―−ー--/ ()()[].\\[\\]/~⁓∼~]*\\$1[-x‐-―−ー--/ ()()[].\\[\\]/~⁓∼~]*(\\$\\d[-x‐-―−ー--/ ()()[].\\[\\]/~⁓∼~]*)*$"), Y1 = /[- ]/;
|
|
8675
9051
|
function J1(d, t) {
|
|
8676
9052
|
var n = d.ga;
|
|
8677
|
-
return t =
|
|
9053
|
+
return t = o1(t) ? V1(n, t) : 0, d = H(d.ga, e1(t)), d ?? Z1;
|
|
8678
9054
|
}
|
|
8679
9055
|
function q1(d) {
|
|
8680
9056
|
for (var t = d.j.length, n = 0; n < t; ++n) {
|
|
8681
|
-
var
|
|
9057
|
+
var s = d.j[n], o = S(s, 1);
|
|
8682
9058
|
if (d.da == o) return !1;
|
|
8683
|
-
var
|
|
8684
|
-
|
|
8685
|
-
var _ =
|
|
8686
|
-
|
|
8687
|
-
var
|
|
8688
|
-
if (
|
|
9059
|
+
var l = d, a = s, p = S(a, 1);
|
|
9060
|
+
R(l.v);
|
|
9061
|
+
var _ = l;
|
|
9062
|
+
a = S(a, 2);
|
|
9063
|
+
var F = "999999999999999".match(p)[0];
|
|
9064
|
+
if (F.length < _.g.h.length ? _ = "" : (_ = F.replace(new RegExp(p, "g"), a), _ = _.replace(RegExp("9", "g"), " ")), 0 < _.length ? (l.v.g(_), l = !0) : l = !1, l) return d.da = o, d.ha = Y1.test(m(s, 4)), d.$ = 0, !0;
|
|
8689
9065
|
}
|
|
8690
9066
|
return d.u = !1;
|
|
8691
9067
|
}
|
|
8692
9068
|
function X1(d, t) {
|
|
8693
|
-
for (var n = [],
|
|
8694
|
-
var
|
|
8695
|
-
|
|
9069
|
+
for (var n = [], s = t.length - 3, o = d.j.length, l = 0; l < o; ++l) {
|
|
9070
|
+
var a = d.j[l];
|
|
9071
|
+
K(a, 3) == 0 ? n.push(d.j[l]) : (a = m(a, 3, Math.min(s, K(a, 3) - 1)), t.search(a) == 0 && n.push(d.j[l]));
|
|
8696
9072
|
}
|
|
8697
9073
|
d.j = n;
|
|
8698
9074
|
}
|
|
8699
|
-
function
|
|
9075
|
+
function D0(d, t) {
|
|
8700
9076
|
d.s.g(t);
|
|
8701
9077
|
var n = t;
|
|
8702
|
-
if (D1.test(n) || d.s.h.length == 1 &&
|
|
9078
|
+
if (D1.test(n) || d.s.h.length == 1 && y0.test(n) ? (t == "+" ? (n = t, d.ba.g(t)) : (n = g1[t], d.ba.g(n), d.g.g(n)), t = n) : (d.u = !1, d.la = !0), !d.u) {
|
|
8703
9079
|
if (!d.la) {
|
|
8704
|
-
if ($
|
|
8705
|
-
if (
|
|
8706
|
-
} else if (0 < d.o.length && (t = d.g.toString(),
|
|
9080
|
+
if ($0(d)) {
|
|
9081
|
+
if (n0(d)) return Q1(d);
|
|
9082
|
+
} else if (0 < d.o.length && (t = d.g.toString(), R(d.g), d.g.g(d.o), d.g.g(t), t = d.h.toString(), n = t.lastIndexOf(d.o), R(d.h), d.h.g(t.substring(0, n))), d.o != e0(d)) return d.h.g(" "), Q1(d);
|
|
8707
9083
|
}
|
|
8708
9084
|
return d.s.toString();
|
|
8709
9085
|
}
|
|
@@ -8713,99 +9089,99 @@ const n0 = (f) => {
|
|
|
8713
9089
|
case 2:
|
|
8714
9090
|
return d.s.toString();
|
|
8715
9091
|
case 3:
|
|
8716
|
-
if ($
|
|
8717
|
-
else return d.o =
|
|
9092
|
+
if ($0(d)) d.ea = !0;
|
|
9093
|
+
else return d.o = e0(d), C1(d);
|
|
8718
9094
|
default:
|
|
8719
|
-
return d.ea ? (
|
|
9095
|
+
return d.ea ? (n0(d) && (d.ea = !1), d.h.toString() + d.g.toString()) : 0 < d.j.length ? (t = i0(d, t), n = d0(d), 0 < n.length ? n : (X1(d, d.g.toString()), q1(d) ? t0(d) : d.u ? h1(d, t) : d.s.toString())) : C1(d);
|
|
8720
9096
|
}
|
|
8721
9097
|
}
|
|
8722
9098
|
function Q1(d) {
|
|
8723
|
-
return d.u = !0, d.ea = !1, d.j = [], d.$ = 0,
|
|
9099
|
+
return d.u = !0, d.ea = !1, d.j = [], d.$ = 0, R(d.v), d.da = "", C1(d);
|
|
8724
9100
|
}
|
|
8725
|
-
function
|
|
8726
|
-
for (var t = d.g.toString(), n = d.j.length,
|
|
8727
|
-
var o = d.j[
|
|
8728
|
-
if (new RegExp("^(?:" +
|
|
9101
|
+
function d0(d) {
|
|
9102
|
+
for (var t = d.g.toString(), n = d.j.length, s = 0; s < n; ++s) {
|
|
9103
|
+
var o = d.j[s], l = S(o, 1);
|
|
9104
|
+
if (new RegExp("^(?:" + l + ")$").test(t) && (d.ha = Y1.test(m(o, 4)), o = t.replace(new RegExp(l, "g"), m(o, 2)), o = h1(d, o), s1(o, m0) == d.ba)) return o;
|
|
8729
9105
|
}
|
|
8730
9106
|
return "";
|
|
8731
9107
|
}
|
|
8732
|
-
function
|
|
9108
|
+
function h1(d, t) {
|
|
8733
9109
|
var n = d.h.h.length;
|
|
8734
9110
|
return d.ha && 0 < n && d.h.toString().charAt(n - 1) != " " ? d.h + " " + t : d.h + t;
|
|
8735
9111
|
}
|
|
8736
9112
|
function C1(d) {
|
|
8737
9113
|
var t = d.g.toString();
|
|
8738
9114
|
if (3 <= t.length) {
|
|
8739
|
-
for (var n = d.ca && d.o.length == 0 && 0 <
|
|
8740
|
-
var
|
|
8741
|
-
0 < d.o.length && G1(
|
|
9115
|
+
for (var n = d.ca && d.o.length == 0 && 0 < K(d.l, 20) ? D(d.l, 20) : D(d.l, 19), s = n.length, o = 0; o < s; ++o) {
|
|
9116
|
+
var l = n[o];
|
|
9117
|
+
0 < d.o.length && G1(S(l, 4)) && !m(l, 6) && !B(l, 5) || (d.o.length != 0 || d.ca || G1(S(l, 4)) || m(l, 6)) && M0.test(S(l, 2)) && d.j.push(l);
|
|
8742
9118
|
}
|
|
8743
|
-
return X1(d, t), t =
|
|
9119
|
+
return X1(d, t), t = d0(d), 0 < t.length ? t : q1(d) ? t0(d) : d.s.toString();
|
|
8744
9120
|
}
|
|
8745
|
-
return
|
|
9121
|
+
return h1(d, t);
|
|
8746
9122
|
}
|
|
8747
|
-
function
|
|
9123
|
+
function t0(d) {
|
|
8748
9124
|
var t = d.g.toString(), n = t.length;
|
|
8749
9125
|
if (0 < n) {
|
|
8750
|
-
for (var
|
|
8751
|
-
return d.u ?
|
|
9126
|
+
for (var s = "", o = 0; o < n; o++) s = i0(d, t.charAt(o));
|
|
9127
|
+
return d.u ? h1(d, s) : d.s.toString();
|
|
8752
9128
|
}
|
|
8753
9129
|
return d.h.toString();
|
|
8754
9130
|
}
|
|
8755
|
-
function
|
|
9131
|
+
function e0(d) {
|
|
8756
9132
|
var t = d.g.toString(), n = 0;
|
|
8757
|
-
if (m(d.l, 10) != 1) var
|
|
8758
|
-
else
|
|
8759
|
-
return
|
|
9133
|
+
if (m(d.l, 10) != 1) var s = !1;
|
|
9134
|
+
else s = d.g.toString(), s = s.charAt(0) == "1" && s.charAt(1) != "0" && s.charAt(1) != "1";
|
|
9135
|
+
return s ? (n = 1, d.h.g("1").g(" "), d.ca = !0) : B(d.l, 15) && (s = new RegExp("^(?:" + m(d.l, 15) + ")"), s = t.match(s), s != null && s[0] != null && 0 < s[0].length && (d.ca = !0, n = s[0].length, d.h.g(t.substring(0, n)))), R(d.g), d.g.g(t.substring(n)), t.substring(0, n);
|
|
8760
9136
|
}
|
|
8761
|
-
function $
|
|
9137
|
+
function $0(d) {
|
|
8762
9138
|
var t = d.ba.toString(), n = new RegExp("^(?:\\+|" + m(d.l, 11) + ")");
|
|
8763
|
-
return n = t.match(n), n != null && n[0] != null && 0 < n[0].length ? (d.ca = !0, n = n[0].length,
|
|
9139
|
+
return n = t.match(n), n != null && n[0] != null && 0 < n[0].length ? (d.ca = !0, n = n[0].length, R(d.g), d.g.g(t.substring(n)), R(d.h), d.h.g(t.substring(0, n)), t.charAt(0) != "+" && d.h.g(" "), !0) : !1;
|
|
8764
9140
|
}
|
|
8765
|
-
function
|
|
9141
|
+
function n0(d) {
|
|
8766
9142
|
if (d.g.h.length == 0) return !1;
|
|
8767
|
-
var t = new
|
|
8768
|
-
return n == 0 ? !1 : (
|
|
9143
|
+
var t = new A(), n = H1(d.g, t);
|
|
9144
|
+
return n == 0 ? !1 : (R(d.g), d.g.g(t.toString()), t = e1(n), t == "001" ? d.l = H(d.ga, "" + n) : t != d.ka && (d.l = J1(d, t)), d.h.g("" + n).g(" "), d.o = "", !0);
|
|
8769
9145
|
}
|
|
8770
|
-
function
|
|
9146
|
+
function i0(d, t) {
|
|
8771
9147
|
var n = d.v.toString();
|
|
8772
9148
|
if (0 <= n.substring(d.$).search(d.fa)) {
|
|
8773
|
-
var
|
|
8774
|
-
return t = n.replace(d.fa, t),
|
|
9149
|
+
var s = n.search(d.fa);
|
|
9150
|
+
return t = n.replace(d.fa, t), R(d.v), d.v.g(t), d.$ = s, t.substring(0, d.$ + 1);
|
|
8775
9151
|
}
|
|
8776
9152
|
return d.j.length == 1 && (d.u = !1), d.da = "", d.s.toString();
|
|
8777
9153
|
}
|
|
8778
|
-
const
|
|
9154
|
+
const r0 = (d) => {
|
|
8779
9155
|
const t = [];
|
|
8780
9156
|
return d.includes("FIXED_LINE_OR_MOBILE") ? (d.includes("MOBILE") || t.push("MOBILE"), d.includes("FIXED_LINE") || t.push("FIXED_LINE")) : (d.includes("MOBILE") || d.includes("FIXED_LINE")) && t.push("FIXED_LINE_OR_MOBILE"), d.concat(t);
|
|
8781
9157
|
}, y1 = { FIXED_LINE: 0, MOBILE: 1, FIXED_LINE_OR_MOBILE: 2, TOLL_FREE: 3, PREMIUM_RATE: 4, SHARED_COST: 5, VOIP: 6, PERSONAL_NUMBER: 7, PAGER: 8, UAN: 9, VOICEMAIL: 10, UNKNOWN: -1 };
|
|
8782
9158
|
e("intlTelInputUtilsTemp", {}), e("intlTelInputUtilsTemp.formatNumberAsYouType", (d, t) => {
|
|
8783
9159
|
try {
|
|
8784
|
-
const n = d.replace(/[^+0-9]/g, ""),
|
|
9160
|
+
const n = d.replace(/[^+0-9]/g, ""), s = new T0(t);
|
|
8785
9161
|
t = "";
|
|
8786
|
-
for (let o = 0; o < n.length; o++)
|
|
9162
|
+
for (let o = 0; o < n.length; o++) s.ja = D0(s, n.charAt(o)), t = s.ja;
|
|
8787
9163
|
return t;
|
|
8788
9164
|
} catch {
|
|
8789
9165
|
return d;
|
|
8790
9166
|
}
|
|
8791
9167
|
}), e("intlTelInputUtilsTemp.formatNumber", (d, t, n) => {
|
|
8792
9168
|
try {
|
|
8793
|
-
const o =
|
|
8794
|
-
var
|
|
8795
|
-
return
|
|
9169
|
+
const o = M.g(), l = Z(o, d, t);
|
|
9170
|
+
var s = a1(o, l, -1);
|
|
9171
|
+
return s == 0 || s == 4 ? o.format(l, typeof n > "u" ? 0 : n) : d;
|
|
8796
9172
|
} catch {
|
|
8797
9173
|
return d;
|
|
8798
9174
|
}
|
|
8799
|
-
}), e("intlTelInputUtilsTemp.getExampleNumber", (d, t, n,
|
|
9175
|
+
}), e("intlTelInputUtilsTemp.getExampleNumber", (d, t, n, s) => {
|
|
8800
9176
|
try {
|
|
8801
|
-
const _ =
|
|
9177
|
+
const _ = M.g();
|
|
8802
9178
|
d: {
|
|
8803
9179
|
var o = _;
|
|
8804
|
-
if (
|
|
8805
|
-
var
|
|
9180
|
+
if (o1(d)) {
|
|
9181
|
+
var l = l1(H(o, d), n);
|
|
8806
9182
|
try {
|
|
8807
|
-
if (
|
|
8808
|
-
var
|
|
9183
|
+
if (B(l, 6)) {
|
|
9184
|
+
var a = m(l, 6), p = z1(o, a, d, !1);
|
|
8809
9185
|
break d;
|
|
8810
9186
|
}
|
|
8811
9187
|
} catch {
|
|
@@ -8813,68 +9189,68 @@ const n0 = (f) => {
|
|
|
8813
9189
|
}
|
|
8814
9190
|
p = null;
|
|
8815
9191
|
}
|
|
8816
|
-
return _.format(p,
|
|
9192
|
+
return _.format(p, s ? 0 : t ? 2 : 1);
|
|
8817
9193
|
} catch {
|
|
8818
9194
|
return "";
|
|
8819
9195
|
}
|
|
8820
9196
|
}), e("intlTelInputUtilsTemp.getExtension", (d, t) => {
|
|
8821
9197
|
try {
|
|
8822
|
-
return m(
|
|
9198
|
+
return m(Z(M.g(), d, t), 3);
|
|
8823
9199
|
} catch {
|
|
8824
9200
|
return "";
|
|
8825
9201
|
}
|
|
8826
9202
|
}), e("intlTelInputUtilsTemp.getNumberType", (d, t) => {
|
|
8827
9203
|
try {
|
|
8828
|
-
const n =
|
|
8829
|
-
return F1(n,
|
|
9204
|
+
const n = M.g(), s = Z(n, d, t);
|
|
9205
|
+
return F1(n, s);
|
|
8830
9206
|
} catch {
|
|
8831
9207
|
return -99;
|
|
8832
9208
|
}
|
|
8833
9209
|
}), e("intlTelInputUtilsTemp.getValidationError", (d, t) => {
|
|
8834
9210
|
if (!t) return 1;
|
|
8835
9211
|
try {
|
|
8836
|
-
const n =
|
|
8837
|
-
return
|
|
9212
|
+
const n = M.g(), s = Z(n, d, t);
|
|
9213
|
+
return a1(n, s, -1);
|
|
8838
9214
|
} catch (n) {
|
|
8839
9215
|
return n.message === "Invalid country calling code" ? 1 : 3 >= d.length || n.message === "Phone number too short after IDD" || n.message === "The string supplied is too short to be a phone number" ? 2 : n.message === "The string supplied is too long to be a phone number" ? 3 : -99;
|
|
8840
9216
|
}
|
|
8841
9217
|
}), e("intlTelInputUtilsTemp.isValidNumber", (d, t, n) => {
|
|
8842
9218
|
try {
|
|
8843
|
-
const
|
|
9219
|
+
const s = M.g(), o = Z(s, d, t), l = E0(s, o);
|
|
8844
9220
|
if (n) {
|
|
8845
|
-
const
|
|
8846
|
-
return
|
|
9221
|
+
const a = r0(n).map((p) => y1[p]);
|
|
9222
|
+
return l && a.includes(F1(s, o));
|
|
8847
9223
|
}
|
|
8848
|
-
return
|
|
9224
|
+
return l;
|
|
8849
9225
|
} catch {
|
|
8850
9226
|
return !1;
|
|
8851
9227
|
}
|
|
8852
9228
|
}), e("intlTelInputUtilsTemp.isPossibleNumber", (d, t, n) => {
|
|
8853
9229
|
try {
|
|
8854
|
-
const
|
|
9230
|
+
const s = M.g(), o = Z(s, d, t);
|
|
8855
9231
|
if (n) {
|
|
8856
|
-
const
|
|
8857
|
-
for (let
|
|
9232
|
+
const l = r0(n);
|
|
9233
|
+
for (let a of l) if (a1(s, o, y1[a]) === 0) return !0;
|
|
8858
9234
|
return !1;
|
|
8859
9235
|
}
|
|
8860
|
-
return
|
|
9236
|
+
return a1(s, o, -1) === 0;
|
|
8861
9237
|
} catch {
|
|
8862
9238
|
return !1;
|
|
8863
9239
|
}
|
|
8864
9240
|
}), e("intlTelInputUtilsTemp.getCoreNumber", (d, t) => {
|
|
8865
9241
|
try {
|
|
8866
|
-
return m(
|
|
9242
|
+
return m(Z(M.g(), d, t), 2).toString();
|
|
8867
9243
|
} catch {
|
|
8868
9244
|
return "";
|
|
8869
9245
|
}
|
|
8870
9246
|
}), e("intlTelInputUtilsTemp.numberFormat", { E164: 0, INTERNATIONAL: 1, NATIONAL: 2, RFC3966: 3 }), e("intlTelInputUtilsTemp.numberType", y1), e("intlTelInputUtilsTemp.validationError", { IS_POSSIBLE: 0, INVALID_COUNTRY_CODE: 1, TOO_SHORT: 2, TOO_LONG: 3, IS_POSSIBLE_LOCAL_ONLY: 4, INVALID_LENGTH: 5 });
|
|
8871
9247
|
})();
|
|
8872
|
-
const
|
|
8873
|
-
delete
|
|
8874
|
-
y.utils =
|
|
8875
|
-
const
|
|
9248
|
+
const h0 = typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : void 0, i2 = h0.intlTelInputUtilsTemp;
|
|
9249
|
+
delete h0.intlTelInputUtilsTemp;
|
|
9250
|
+
y.utils = i2;
|
|
9251
|
+
const s2 = {
|
|
8876
9252
|
__name: "IntlTelInputWithUtils",
|
|
8877
|
-
props: /* @__PURE__ */
|
|
9253
|
+
props: /* @__PURE__ */ s0({
|
|
8878
9254
|
disabled: {
|
|
8879
9255
|
type: Boolean,
|
|
8880
9256
|
default: !1
|
|
@@ -8898,47 +9274,47 @@ const r0 = {
|
|
|
8898
9274
|
},
|
|
8899
9275
|
modelModifiers: {}
|
|
8900
9276
|
}),
|
|
8901
|
-
emits: /* @__PURE__ */
|
|
9277
|
+
emits: /* @__PURE__ */ s0([
|
|
8902
9278
|
"changeNumber",
|
|
8903
9279
|
"changeCountry",
|
|
8904
9280
|
"changeValidity",
|
|
8905
9281
|
"changeErrorCode"
|
|
8906
9282
|
], ["update:modelValue"]),
|
|
8907
9283
|
setup(f, { expose: e, emit: $ }) {
|
|
8908
|
-
const i =
|
|
9284
|
+
const i = P0(f, "modelValue"), r = f, u = $, h = I1(), c = I1(), C = I1(!1), g = () => c.value ? r.options.strictMode ? c.value.isValidNumberPrecise() : c.value.isValidNumber() : null, I = () => {
|
|
8909
9285
|
let v = g();
|
|
8910
9286
|
C.value !== v && (C.value = v, u("changeValidity", !!v), u(
|
|
8911
9287
|
"changeErrorCode",
|
|
8912
9288
|
v ? null : c.value.getValidationError()
|
|
8913
9289
|
));
|
|
8914
|
-
},
|
|
9290
|
+
}, w = () => {
|
|
8915
9291
|
var v;
|
|
8916
9292
|
u("changeNumber", ((v = c.value) == null ? void 0 : v.getNumber()) ?? ""), I();
|
|
8917
|
-
},
|
|
9293
|
+
}, k = () => {
|
|
8918
9294
|
var v;
|
|
8919
|
-
u("changeCountry", ((v = c.value) == null ? void 0 : v.getSelectedCountryData().iso2) ?? ""),
|
|
9295
|
+
u("changeCountry", ((v = c.value) == null ? void 0 : v.getSelectedCountryData().iso2) ?? ""), w(), I();
|
|
8920
9296
|
};
|
|
8921
|
-
return
|
|
8922
|
-
h.value && (c.value = y(h.value,
|
|
8923
|
-
}),
|
|
8924
|
-
() =>
|
|
9297
|
+
return x0(() => {
|
|
9298
|
+
h.value && (c.value = y(h.value, r.options), r.value && c.value.setNumber(r.value), r.disabled && c.value.setDisabled(r.disabled), C.value = g());
|
|
9299
|
+
}), B0(
|
|
9300
|
+
() => r.disabled,
|
|
8925
9301
|
(v) => {
|
|
8926
|
-
var
|
|
8927
|
-
return (
|
|
9302
|
+
var E;
|
|
9303
|
+
return (E = c.value) == null ? void 0 : E.setDisabled(v);
|
|
8928
9304
|
}
|
|
8929
|
-
),
|
|
9305
|
+
), R0(() => {
|
|
8930
9306
|
var v;
|
|
8931
9307
|
return (v = c.value) == null ? void 0 : v.destroy();
|
|
8932
|
-
}), e({ instance: c, input: h }), (v,
|
|
9308
|
+
}), e({ instance: c, input: h }), (v, E) => k0((G0(), O0("input", U0({
|
|
8933
9309
|
ref_key: "input",
|
|
8934
9310
|
ref: h,
|
|
8935
|
-
"onUpdate:modelValue":
|
|
9311
|
+
"onUpdate:modelValue": E[0] || (E[0] = (N) => i.value = N),
|
|
8936
9312
|
type: "tel",
|
|
8937
|
-
onCountrychange:
|
|
8938
|
-
onInput:
|
|
9313
|
+
onCountrychange: k,
|
|
9314
|
+
onInput: w
|
|
8939
9315
|
}, f.inputProps), null, 16)), [
|
|
8940
9316
|
[
|
|
8941
|
-
|
|
9317
|
+
F0,
|
|
8942
9318
|
i.value,
|
|
8943
9319
|
void 0,
|
|
8944
9320
|
{ lazy: !0 }
|
|
@@ -8947,5 +9323,5 @@ const r0 = {
|
|
|
8947
9323
|
}
|
|
8948
9324
|
};
|
|
8949
9325
|
export {
|
|
8950
|
-
|
|
9326
|
+
s2 as default
|
|
8951
9327
|
};
|