Skip to content

Commit 61110b2

Browse files
Update the validation patterns
1 parent f75dcb7 commit 61110b2

File tree

3 files changed

+59
-14
lines changed

3 files changed

+59
-14
lines changed

resources/metadata.xml

Lines changed: 56 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -6327,6 +6327,38 @@
63276327
internationalPrefix="00|1(?:[12]\d|79)\d\d00" nationalPrefix="0"
63286328
nationalPrefixForParsing="(1(?:[12]\d|79)\d\d)|0">
63296329
<availableFormats>
6330+
<!-- 5-6 digit short number -->
6331+
<numberFormat pattern="(\d{5,6})">
6332+
<leadingDigits>
6333+
1(?:
6334+
00|
6335+
2[13]
6336+
)|
6337+
95
6338+
</leadingDigits>
6339+
<leadingDigits>
6340+
1(?:
6341+
00|
6342+
2(?:
6343+
11|
6344+
39
6345+
)
6346+
)|
6347+
95
6348+
</leadingDigits>
6349+
<leadingDigits>
6350+
1(?:
6351+
00|
6352+
2(?:
6353+
110|
6354+
395
6355+
)
6356+
)|
6357+
95
6358+
</leadingDigits>
6359+
<format>$1</format>
6360+
<intlFormat>NA</intlFormat>
6361+
</numberFormat>
63306362
<numberFormat pattern="(\d{5,6})">
63316363
<leadingDigits>
63326364
10|
@@ -10497,9 +10529,11 @@
1049710529
73[0235]
1049810530
)|
1049910531
4(?:
10500-
[0-5]\d\d|
10501-
69[7-9]|
10502-
70[0-79]
10532+
(?:
10533+
[0-5]\d|
10534+
70
10535+
)\d|
10536+
69[7-9]
1050310537
)|
1050410538
(?:
1050510539
(?:
@@ -19340,7 +19374,7 @@
1934019374
<exampleNumber>612345678</exampleNumber>
1934119375
<nationalNumberPattern>
1934219376
4(?:
19343-
[46]\d|
19377+
[469]\d|
1934419378
5[1-9]
1934519379
)\d{5}|
1934619380
(?:
@@ -28961,7 +28995,7 @@
2896128995
472[24]|
2896228996
505[2-57-9]|
2896328997
7306|
28964-
983[237-9]
28998+
983[2-47-9]
2896528999
)\d{6}|
2896629000
(?:
2896729001
2(?:
@@ -29067,7 +29101,7 @@
2906729101
472[24]|
2906829102
505[2-57-9]|
2906929103
7306|
29070-
983[237-9]
29104+
983[2-47-9]
2907129105
)\d{6}|
2907229106
(?:
2907329107
2(?:
@@ -30645,28 +30679,39 @@
3064530679
<format>$1 $2 $3</format>
3064630680
</numberFormat>
3064730681
<numberFormat pattern="(\d{3})(\d{3})(\d{3})" nationalPrefixFormattingRule="$NP$FG">
30648-
<leadingDigits>[23]</leadingDigits>
30682+
<leadingDigits>
30683+
2|
30684+
39
30685+
</leadingDigits>
3064930686
<format>$1 $2 $3</format>
3065030687
</numberFormat>
30688+
<numberFormat pattern="(\d{2})(\d{7,10})" nationalPrefixFormattingRule="$NP$FG">
30689+
<leadingDigits>3</leadingDigits>
30690+
<format>$1 $2</format>
30691+
</numberFormat>
3065130692
</availableFormats>
3065230693
<generalDesc>
3065330694
<nationalNumberPattern>
30654-
[23]\d{7,8}|
30695+
2\d{7,8}|
30696+
3\d{7,11}|
3065530697
(?:
3065630698
4\d\d|
3065730699
[89]00
3065830700
)\d{5}
3065930701
</nationalNumberPattern>
3066030702
</generalDesc>
3066130703
<fixedLine>
30662-
<possibleLengths national="8,9"/>
30704+
<possibleLengths national="[8-12]"/>
3066330705
<exampleNumber>28012345</exampleNumber>
3066430706
<nationalNumberPattern>
30707+
38\d{6,10}|
3066530708
(?:
3066630709
2[89]|
3066730710
39
30668-
)0\d{6}|
30669-
[23][89]\d{6}
30711+
)(?:
30712+
0\d{5,6}|
30713+
[1-9]\d{5}
30714+
)
3067030715
</nationalNumberPattern>
3067130716
</fixedLine>
3067230717
<mobile>

src/metadata/countries.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1173,7 +1173,7 @@
11731173
"xk",
11741174
"Kosovo",
11751175
"383",
1176-
"+383 (...) ... ..."
1176+
"+383 (...) ... ... ..."
11771177
],
11781178
[
11791179
"kw",

src/metadata/validations.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -912,8 +912,8 @@
912912
"^(?:[2-6]|8\\d{5})\\d{4}|[78]\\d{6}|[68]\\d{5}$"
913913
],
914914
"xk": [
915-
"^\\d{8,9}$",
916-
"^[23]\\d{7,8}|(?:4\\d\\d|[89]00)\\d{5}$"
915+
"^\\d{8,12}$",
916+
"^2\\d{7,8}|3\\d{7,11}|(?:4\\d\\d|[89]00)\\d{5}$"
917917
],
918918
"ye": [
919919
"^\\d{7,9}$",

0 commit comments

Comments
 (0)