@rpcbase/ui 0.208.0 → 0.209.0
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/dist/index.js +13 -13
- package/dist/index100.js +3 -3
- package/dist/index100.js.map +1 -1
- package/dist/index101.js +9 -3
- package/dist/index101.js.map +1 -1
- package/dist/index102.js +4 -9
- package/dist/index102.js.map +1 -1
- package/dist/index103.js +9 -4
- package/dist/index103.js.map +1 -1
- package/dist/index104.js +18 -12
- package/dist/index104.js.map +1 -1
- package/dist/index105.js +25 -18
- package/dist/index105.js.map +1 -1
- package/dist/index106.js +5 -24
- package/dist/index106.js.map +1 -1
- package/dist/index107.js +2 -2
- package/dist/index107.js.map +1 -1
- package/dist/index108.js +4 -3
- package/dist/index108.js.map +1 -1
- package/dist/index109.js +3 -3
- package/dist/index109.js.map +1 -1
- package/dist/index110.js +3 -4
- package/dist/index110.js.map +1 -1
- package/dist/index111.js +3 -3
- package/dist/index111.js.map +1 -1
- package/dist/index112.js +8 -5
- package/dist/index112.js.map +1 -1
- package/dist/index113.js +7 -8
- package/dist/index113.js.map +1 -1
- package/dist/index114.js +34 -7
- package/dist/index114.js.map +1 -1
- package/dist/index115.js +7 -34
- package/dist/index115.js.map +1 -1
- package/dist/index116.js +5 -7
- package/dist/index116.js.map +1 -1
- package/dist/index117.js +7 -5
- package/dist/index117.js.map +1 -1
- package/dist/index118.js +9 -7
- package/dist/index118.js.map +1 -1
- package/dist/index119.js +3 -7
- package/dist/index119.js.map +1 -1
- package/dist/index120.js +4 -3
- package/dist/index120.js.map +1 -1
- package/dist/index121.js +3 -4
- package/dist/index121.js.map +1 -1
- package/dist/index122.js +3 -3
- package/dist/index122.js.map +1 -1
- package/dist/index123.js +4 -3
- package/dist/index123.js.map +1 -1
- package/dist/index124.js +3 -4
- package/dist/index124.js.map +1 -1
- package/dist/index125.js +3 -3
- package/dist/index125.js.map +1 -1
- package/dist/index126.js +7 -5
- package/dist/index126.js.map +1 -1
- package/dist/index127.js +57 -8
- package/dist/index127.js.map +1 -1
- package/dist/index128.js +7 -57
- package/dist/index128.js.map +1 -1
- package/dist/index129.js +19 -6
- package/dist/index129.js.map +1 -1
- package/dist/index130.js +19 -19
- package/dist/index130.js.map +1 -1
- package/dist/index131.js +34 -19
- package/dist/index131.js.map +1 -1
- package/dist/index132.js +5 -34
- package/dist/index132.js.map +1 -1
- package/dist/index133.js +8 -5
- package/dist/index133.js.map +1 -1
- package/dist/index134.js +13 -7
- package/dist/index134.js.map +1 -1
- package/dist/index135.js +10 -14
- package/dist/index135.js.map +1 -1
- package/dist/index136.js +6 -10
- package/dist/index136.js.map +1 -1
- package/dist/index137.js +4 -5
- package/dist/index137.js.map +1 -1
- package/dist/index138.js +5 -5
- package/dist/index138.js.map +1 -1
- package/dist/index139.js +5 -5
- package/dist/index139.js.map +1 -1
- package/dist/index140.js +5 -5
- package/dist/index140.js.map +1 -1
- package/dist/index141.js +4 -5
- package/dist/index141.js.map +1 -1
- package/dist/index142.js +6 -4
- package/dist/index142.js.map +1 -1
- package/dist/index143.js +21 -7
- package/dist/index143.js.map +1 -1
- package/dist/index144.js +9 -21
- package/dist/index144.js.map +1 -1
- package/dist/index145.js +7 -8
- package/dist/index145.js.map +1 -1
- package/dist/index146.js +5 -6
- package/dist/index146.js.map +1 -1
- package/dist/index147.js +6 -6
- package/dist/index147.js.map +1 -1
- package/dist/index148.js +4 -6
- package/dist/index148.js.map +1 -1
- package/dist/index149.js +4 -4
- package/dist/index149.js.map +1 -1
- package/dist/index150.js +5 -4
- package/dist/index150.js.map +1 -1
- package/dist/index151.js +4 -5
- package/dist/index151.js.map +1 -1
- package/dist/index152.js +5 -4
- package/dist/index152.js.map +1 -1
- package/dist/index153.js +4 -5
- package/dist/index153.js.map +1 -1
- package/dist/index154.js +4 -4
- package/dist/index154.js.map +1 -1
- package/dist/index155.js +3 -3
- package/dist/index155.js.map +1 -1
- package/dist/index156.js +29 -5
- package/dist/index156.js.map +1 -1
- package/dist/index157.js +33 -29
- package/dist/index157.js.map +1 -1
- package/dist/index158.js +15 -32
- package/dist/index158.js.map +1 -1
- package/dist/index159.js +10 -14
- package/dist/index159.js.map +1 -1
- package/dist/index160.js +9 -11
- package/dist/index160.js.map +1 -1
- package/dist/index161.js +16 -9
- package/dist/index161.js.map +1 -1
- package/dist/index162.js +86 -16
- package/dist/index162.js.map +1 -1
- package/dist/index163.js +47 -86
- package/dist/index163.js.map +1 -1
- package/dist/index164.js +16 -46
- package/dist/index164.js.map +1 -1
- package/dist/index165.js +8 -17
- package/dist/index165.js.map +1 -1
- package/dist/index166.js +10 -8
- package/dist/index166.js.map +1 -1
- package/dist/index167.js +4 -9
- package/dist/index167.js.map +1 -1
- package/dist/index168.js +22 -5
- package/dist/index168.js.map +1 -1
- package/dist/index169.js +7 -22
- package/dist/index169.js.map +1 -1
- package/dist/index170.js +6 -7
- package/dist/index170.js.map +1 -1
- package/dist/index171.js +4 -4
- package/dist/index171.js.map +1 -1
- package/dist/index172.js +4 -6
- package/dist/index172.js.map +1 -1
- package/dist/index173.js +6 -4
- package/dist/index173.js.map +1 -1
- package/dist/index174.js +67 -6
- package/dist/index174.js.map +1 -1
- package/dist/index175.js +17 -67
- package/dist/index175.js.map +1 -1
- package/dist/index176.js +12 -17
- package/dist/index176.js.map +1 -1
- package/dist/index177.js +9 -12
- package/dist/index177.js.map +1 -1
- package/dist/index178.js +20 -9
- package/dist/index178.js.map +1 -1
- package/dist/index179.js +14 -17
- package/dist/index179.js.map +1 -1
- package/dist/index180.js +54 -16
- package/dist/index180.js.map +1 -1
- package/dist/index181.js +9 -54
- package/dist/index181.js.map +1 -1
- package/dist/index182.js +6 -10
- package/dist/index182.js.map +1 -1
- package/dist/index183.js +26 -6
- package/dist/index183.js.map +1 -1
- package/dist/index184.js +26 -26
- package/dist/index184.js.map +1 -1
- package/dist/index185.js +10 -23
- package/dist/index185.js.map +1 -1
- package/dist/index186.js +13 -13
- package/dist/index186.js.map +1 -1
- package/dist/index187.js +6 -13
- package/dist/index187.js.map +1 -1
- package/dist/index188.js +23 -6
- package/dist/index188.js.map +1 -1
- package/dist/index189.js +385 -23
- package/dist/index189.js.map +1 -1
- package/dist/index190.js +487 -377
- package/dist/index190.js.map +1 -1
- package/dist/index191.js +122 -487
- package/dist/index191.js.map +1 -1
- package/dist/index192.js +53 -131
- package/dist/index192.js.map +1 -1
- package/dist/index193.js +76 -51
- package/dist/index193.js.map +1 -1
- package/dist/index194.js +897 -75
- package/dist/index194.js.map +1 -1
- package/dist/index195.js +19 -899
- package/dist/index195.js.map +1 -1
- package/dist/index196.js +446 -17
- package/dist/index196.js.map +1 -1
- package/dist/index197.js +4 -448
- package/dist/index197.js.map +1 -1
- package/dist/index198.js +57 -4
- package/dist/index198.js.map +1 -1
- package/dist/index199.js +56 -52
- package/dist/index199.js.map +1 -1
- package/dist/index200.js +55 -56
- package/dist/index200.js.map +1 -1
- package/dist/index201.js +8 -60
- package/dist/index201.js.map +1 -1
- package/dist/index202.js +15 -7
- package/dist/index202.js.map +1 -1
- package/dist/index203.js +143 -15
- package/dist/index203.js.map +1 -1
- package/dist/index204.js +4 -145
- package/dist/index204.js.map +1 -1
- package/dist/index205.js +11 -4
- package/dist/index205.js.map +1 -1
- package/dist/index206.js +104 -10
- package/dist/index206.js.map +1 -1
- package/dist/index207.js +347 -94
- package/dist/index207.js.map +1 -1
- package/dist/index208.js +87 -349
- package/dist/index208.js.map +1 -1
- package/dist/index209.js +304 -73
- package/dist/index209.js.map +1 -1
- package/dist/index210.js +193 -309
- package/dist/index210.js.map +1 -1
- package/dist/index211.js +19 -211
- package/dist/index211.js.map +1 -1
- package/dist/index212.js +27 -18
- package/dist/index212.js.map +1 -1
- package/dist/index213.js +187 -27
- package/dist/index213.js.map +1 -1
- package/dist/index214.js +16 -186
- package/dist/index214.js.map +1 -1
- package/dist/index215.js +62 -18
- package/dist/index215.js.map +1 -1
- package/dist/index216.js +40 -58
- package/dist/index216.js.map +1 -1
- package/dist/index217.js +9 -43
- package/dist/index217.js.map +1 -1
- package/dist/index218.js +25 -10
- package/dist/index218.js.map +1 -1
- package/dist/index219.js +45 -25
- package/dist/index219.js.map +1 -1
- package/dist/index220.js +17 -44
- package/dist/index220.js.map +1 -1
- package/dist/index221.js +3 -18
- package/dist/index221.js.map +1 -1
- package/dist/index222.js +5 -3
- package/dist/index222.js.map +1 -1
- package/dist/index223.js +20 -4
- package/dist/index223.js.map +1 -1
- package/dist/index224.js +24 -20
- package/dist/index224.js.map +1 -1
- package/dist/index225.js +66 -23
- package/dist/index225.js.map +1 -1
- package/dist/index226.js +14 -67
- package/dist/index226.js.map +1 -1
- package/dist/index227.js +4 -15
- package/dist/index227.js.map +1 -1
- package/dist/index228.js +51 -4
- package/dist/index228.js.map +1 -1
- package/dist/index229.js +5 -50
- package/dist/index229.js.map +1 -1
- package/dist/index230.js +26 -5
- package/dist/index230.js.map +1 -1
- package/dist/index231.js +11 -24
- package/dist/index231.js.map +1 -1
- package/dist/index232.js +8 -12
- package/dist/index232.js.map +1 -1
- package/dist/index233.js +3 -13
- package/dist/index234.js +29 -3
- package/dist/index234.js.map +1 -0
- package/dist/index235.js +68 -25
- package/dist/index235.js.map +1 -1
- package/dist/index236.js +2 -71
- package/dist/index237.js +15 -3
- package/dist/index237.js.map +1 -0
- package/dist/index238.js +51 -12
- package/dist/index238.js.map +1 -1
- package/dist/index239.js +114 -50
- package/dist/index239.js.map +1 -1
- package/dist/index24.js +9 -0
- package/dist/index24.js.map +1 -1
- package/dist/index240.js +6 -115
- package/dist/index240.js.map +1 -1
- package/dist/index241.js +13 -6
- package/dist/index241.js.map +1 -1
- package/dist/index242.js +687 -13
- package/dist/index242.js.map +1 -1
- package/dist/index243.js +234 -668
- package/dist/index243.js.map +1 -1
- package/dist/index244.js +670 -222
- package/dist/index244.js.map +1 -1
- package/dist/index245.js +7430 -700
- package/dist/index245.js.map +1 -1
- package/dist/index246.js +7 -7431
- package/dist/index246.js.map +1 -1
- package/dist/index247.js +12 -6
- package/dist/index247.js.map +1 -1
- package/dist/index248.js +5 -12
- package/dist/index248.js.map +1 -1
- package/dist/index249.js +459 -5
- package/dist/index249.js.map +1 -1
- package/dist/index25.js +20 -8
- package/dist/index25.js.map +1 -1
- package/dist/index250.js +32 -454
- package/dist/index250.js.map +1 -1
- package/dist/index251.js +18 -36
- package/dist/index251.js.map +1 -1
- package/dist/index252.js +25 -17
- package/dist/index252.js.map +1 -1
- package/dist/index253.js +4 -27
- package/dist/index253.js.map +1 -1
- package/dist/index254.js +58 -4
- package/dist/index254.js.map +1 -1
- package/dist/index255.js +7 -58
- package/dist/index255.js.map +1 -1
- package/dist/index256.js +12 -7
- package/dist/index256.js.map +1 -1
- package/dist/index257.js +3 -13
- package/dist/index257.js.map +1 -1
- package/dist/index258.js +17 -3
- package/dist/index258.js.map +1 -1
- package/dist/index259.js +23 -14
- package/dist/index259.js.map +1 -1
- package/dist/index26.js +56 -18
- package/dist/index26.js.map +1 -1
- package/dist/index260.js +41 -23
- package/dist/index260.js.map +1 -1
- package/dist/index261.js +13 -43
- package/dist/index261.js.map +1 -1
- package/dist/index262.js +25 -13
- package/dist/index262.js.map +1 -1
- package/dist/index263.js +16 -24
- package/dist/index263.js.map +1 -1
- package/dist/index264.js +33 -15
- package/dist/index264.js.map +1 -1
- package/dist/index265.js +5 -35
- package/dist/index265.js.map +1 -1
- package/dist/index266.js +9 -5
- package/dist/index266.js.map +1 -1
- package/dist/index267.js +7 -8
- package/dist/index267.js.map +1 -1
- package/dist/index268.js +9 -8
- package/dist/index268.js.map +1 -1
- package/dist/index269.js +10 -9
- package/dist/index269.js.map +1 -1
- package/dist/index27.js +50 -53
- package/dist/index27.js.map +1 -1
- package/dist/index270.js +7 -10
- package/dist/index270.js.map +1 -1
- package/dist/index271.js +73 -7
- package/dist/index271.js.map +1 -1
- package/dist/index272.js +161 -63
- package/dist/index272.js.map +1 -1
- package/dist/index273.js +100 -157
- package/dist/index273.js.map +1 -1
- package/dist/index274.js +13 -113
- package/dist/index274.js.map +1 -1
- package/dist/index275.js +78 -12
- package/dist/index275.js.map +1 -1
- package/dist/index276.js +23 -57
- package/dist/index276.js.map +1 -1
- package/dist/index277.js +12 -45
- package/dist/index277.js.map +1 -1
- package/dist/index278.js +16 -13
- package/dist/index278.js.map +1 -1
- package/dist/index279.js +98 -15
- package/dist/index279.js.map +1 -1
- package/dist/index28.js +1 -59
- package/dist/index280.js +50 -93
- package/dist/index280.js.map +1 -1
- package/dist/index281.js +57 -5
- package/dist/index281.js.map +1 -1
- package/dist/index282.js +41 -78
- package/dist/index282.js.map +1 -1
- package/dist/index283.js +100 -58
- package/dist/index283.js.map +1 -1
- package/dist/index284.js +46 -104
- package/dist/index284.js.map +1 -1
- package/dist/index285.js +39 -51
- package/dist/index285.js.map +1 -1
- package/dist/index286.js +141 -42
- package/dist/index286.js.map +1 -1
- package/dist/index287.js +119 -122
- package/dist/index287.js.map +1 -1
- package/dist/index288.js +222 -107
- package/dist/index288.js.map +1 -1
- package/dist/index289.js +159 -173
- package/dist/index289.js.map +1 -1
- package/dist/index29.js +4 -0
- package/dist/index290.js +177 -119
- package/dist/index290.js.map +1 -1
- package/dist/index291.js +5 -298
- package/dist/index291.js.map +1 -1
- package/dist/index292.js +6 -5
- package/dist/index292.js.map +1 -1
- package/dist/index293.js +7 -6
- package/dist/index293.js.map +1 -1
- package/dist/index294.js +5 -6
- package/dist/index294.js.map +1 -1
- package/dist/index295.js +4 -4
- package/dist/index295.js.map +1 -1
- package/dist/index296.js +21 -6
- package/dist/index296.js.map +1 -1
- package/dist/index297.js +10 -21
- package/dist/index297.js.map +1 -1
- package/dist/index298.js +126 -10
- package/dist/index298.js.map +1 -1
- package/dist/index299.js +146 -108
- package/dist/index299.js.map +1 -1
- package/dist/index30.js +8 -6
- package/dist/index30.js.map +1 -0
- package/dist/index300.js +55 -151
- package/dist/index300.js.map +1 -1
- package/dist/index301.js +107 -66
- package/dist/index301.js.map +1 -1
- package/dist/index302.js +489 -107
- package/dist/index302.js.map +1 -1
- package/dist/index303.js +63 -492
- package/dist/index303.js.map +1 -1
- package/dist/index304.js +4 -63
- package/dist/index304.js.map +1 -1
- package/dist/index305.js +28 -4
- package/dist/index305.js.map +1 -1
- package/dist/index306.js +65 -27
- package/dist/index306.js.map +1 -1
- package/dist/index307.js +147 -60
- package/dist/index307.js.map +1 -1
- package/dist/index308.js +56 -147
- package/dist/index308.js.map +1 -1
- package/dist/index309.js +553 -53
- package/dist/index309.js.map +1 -1
- package/dist/index31.js +6 -5
- package/dist/index31.js.map +1 -1
- package/dist/index310.js +170 -521
- package/dist/index310.js.map +1 -1
- package/dist/index311.js +327 -206
- package/dist/index311.js.map +1 -1
- package/dist/index312.js +251 -314
- package/dist/index312.js.map +1 -1
- package/dist/index32.js +3 -3
- package/dist/index32.js.map +1 -1
- package/dist/index33.js +7 -5
- package/dist/index33.js.map +1 -1
- package/dist/index34.js +7 -4
- package/dist/index34.js.map +1 -1
- package/dist/index35.js +5 -10
- package/dist/index35.js.map +1 -1
- package/dist/index36.js +7 -5
- package/dist/index36.js.map +1 -1
- package/dist/index37.js +8 -7
- package/dist/index37.js.map +1 -1
- package/dist/index38.js +12 -8
- package/dist/index38.js.map +1 -1
- package/dist/index39.js +5 -11
- package/dist/index39.js.map +1 -1
- package/dist/index40.js +6 -6
- package/dist/index40.js.map +1 -1
- package/dist/index41.js +5 -5
- package/dist/index41.js.map +1 -1
- package/dist/index42.js +9 -6
- package/dist/index42.js.map +1 -1
- package/dist/index43.js +8 -9
- package/dist/index43.js.map +1 -1
- package/dist/index44.js +5 -8
- package/dist/index44.js.map +1 -1
- package/dist/index45.js +2 -2
- package/dist/index45.js.map +1 -1
- package/dist/index46.js +11 -5
- package/dist/index46.js.map +1 -1
- package/dist/index47.js +4 -4
- package/dist/index47.js.map +1 -1
- package/dist/index48.js +6 -10
- package/dist/index48.js.map +1 -1
- package/dist/index49.js +4 -7
- package/dist/index49.js.map +1 -1
- package/dist/index50.js +6 -4
- package/dist/index50.js.map +1 -1
- package/dist/index51.js +6 -6
- package/dist/index51.js.map +1 -1
- package/dist/index52.js +5 -5
- package/dist/index52.js.map +1 -1
- package/dist/index53.js +8 -5
- package/dist/index53.js.map +1 -1
- package/dist/index54.js +13 -9
- package/dist/index54.js.map +1 -1
- package/dist/index55.js +5 -12
- package/dist/index55.js.map +1 -1
- package/dist/index56.js +4 -4
- package/dist/index56.js.map +1 -1
- package/dist/index57.js +4 -4
- package/dist/index57.js.map +1 -1
- package/dist/index58.js +13 -6
- package/dist/index58.js.map +1 -1
- package/dist/index59.js +4 -10
- package/dist/index59.js.map +1 -1
- package/dist/index60.js +8 -7
- package/dist/index60.js.map +1 -1
- package/dist/index61.js +68 -9
- package/dist/index61.js.map +1 -1
- package/dist/index62.js +8 -68
- package/dist/index62.js.map +1 -1
- package/dist/index63.js +31 -8
- package/dist/index63.js.map +1 -1
- package/dist/index64.js +10 -31
- package/dist/index64.js.map +1 -1
- package/dist/index65.js +16 -10
- package/dist/index65.js.map +1 -1
- package/dist/index66.js +200 -15
- package/dist/index66.js.map +1 -1
- package/dist/index67.js +21 -201
- package/dist/index67.js.map +1 -1
- package/dist/index68.js +12 -16
- package/dist/index68.js.map +1 -1
- package/dist/index69.js +123 -17
- package/dist/index69.js.map +1 -1
- package/dist/index70.js +18 -122
- package/dist/index70.js.map +1 -1
- package/dist/index71.js +9 -19
- package/dist/index71.js.map +1 -1
- package/dist/index72.js +9 -8
- package/dist/index72.js.map +1 -1
- package/dist/index73.js +11 -7
- package/dist/index73.js.map +1 -1
- package/dist/index74.js +7 -11
- package/dist/index74.js.map +1 -1
- package/dist/index75.js +6 -6
- package/dist/index75.js.map +1 -1
- package/dist/index76.js +4 -9
- package/dist/index76.js.map +1 -1
- package/dist/index77.js +42 -5
- package/dist/index77.js.map +1 -1
- package/dist/index78.js +368 -29
- package/dist/index78.js.map +1 -1
- package/dist/index79.js +37 -379
- package/dist/index79.js.map +1 -1
- package/dist/index80.js +22 -39
- package/dist/index80.js.map +1 -1
- package/dist/index81.js +56 -20
- package/dist/index81.js.map +1 -1
- package/dist/index82.js +7 -57
- package/dist/index82.js.map +1 -1
- package/dist/index83.js +4 -6
- package/dist/index83.js.map +1 -1
- package/dist/index84.js +3 -3
- package/dist/index84.js.map +1 -1
- package/dist/index85.js +3 -3
- package/dist/index85.js.map +1 -1
- package/dist/index86.js +3 -3
- package/dist/index86.js.map +1 -1
- package/dist/index87.js +5 -4
- package/dist/index87.js.map +1 -1
- package/dist/index88.js +3 -3
- package/dist/index88.js.map +1 -1
- package/dist/index89.js +10 -6
- package/dist/index89.js.map +1 -1
- package/dist/index90.js +7 -10
- package/dist/index90.js.map +1 -1
- package/dist/index91.js +6 -7
- package/dist/index91.js.map +1 -1
- package/dist/index92.js +5 -6
- package/dist/index92.js.map +1 -1
- package/dist/index93.js +7 -5
- package/dist/index93.js.map +1 -1
- package/dist/index94.js +48 -8
- package/dist/index94.js.map +1 -1
- package/dist/index95.js +104 -46
- package/dist/index95.js.map +1 -1
- package/dist/index96.js +8 -103
- package/dist/index96.js.map +1 -1
- package/dist/index97.js +5 -9
- package/dist/index97.js.map +1 -1
- package/dist/index98.js +3 -3
- package/dist/index98.js.map +1 -1
- package/dist/index99.js +6 -7
- package/dist/index99.js.map +1 -1
- package/package.json +2 -2
- package/dist/index233.js.map +0 -1
- package/dist/index236.js.map +0 -1
- package/dist/index28.js.map +0 -1
- package/dist/index313.js +0 -272
- package/dist/index313.js.map +0 -1
package/dist/index259.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index259.js","names":[],"sources":["../../../node_modules/libphonenumber-js/es6/helpers/
|
|
1
|
+
{"version":3,"file":"index259.js","names":[],"sources":["../../../node_modules/libphonenumber-js/es6/helpers/extractNationalNumberFromPossiblyIncompleteNumber.js"],"sourcesContent":["/**\r\n * Strips any national prefix (such as 0, 1) present in a\r\n * (possibly incomplete) number provided.\r\n * \"Carrier codes\" are only used in Colombia and Brazil,\r\n * and only when dialing within those countries from a mobile phone to a fixed line number.\r\n * Sometimes it won't actually strip national prefix\r\n * and will instead prepend some digits to the `number`:\r\n * for example, when number `2345678` is passed with `VI` country selected,\r\n * it will return `{ number: \"3402345678\" }`, because `340` area code is prepended.\r\n * @param {string} number — National number digits.\r\n * @param {object} metadata — Metadata with country selected.\r\n * @return {object} `{ nationalNumber: string, nationalPrefix: string? carrierCode: string? }`. Even if a national prefix was extracted, it's not necessarily present in the returned object, so don't rely on its presence in the returned object in order to find out whether a national prefix has been extracted or not.\r\n */\nexport default function extractNationalNumberFromPossiblyIncompleteNumber(number, metadata) {\n if (number && metadata.numberingPlan.nationalPrefixForParsing()) {\n // See METADATA.md for the description of\n // `national_prefix_for_parsing` and `national_prefix_transform_rule`.\n // Attempt to parse the first digits as a national prefix.\n var prefixPattern = new RegExp('^(?:' + metadata.numberingPlan.nationalPrefixForParsing() + ')');\n var prefixMatch = prefixPattern.exec(number);\n if (prefixMatch) {\n var nationalNumber;\n var carrierCode;\n // https://gitlab.com/catamphetamine/libphonenumber-js/-/blob/master/METADATA.md#national_prefix_for_parsing--national_prefix_transform_rule\n // If a `national_prefix_for_parsing` has any \"capturing groups\"\n // then it means that the national (significant) number is equal to\n // those \"capturing groups\" transformed via `national_prefix_transform_rule`,\n // and nothing could be said about the actual national prefix:\n // what is it and was it even there.\n // If a `national_prefix_for_parsing` doesn't have any \"capturing groups\",\n // then everything it matches is a national prefix.\n // To determine whether `national_prefix_for_parsing` matched any\n // \"capturing groups\", the value of the result of calling `.exec()`\n // is looked at, and if it has non-undefined values where there're\n // \"capturing groups\" in the regular expression, then it means\n // that \"capturing groups\" have been matched.\n // It's not possible to tell whether there'll be any \"capturing gropus\"\n // before the matching process, because a `national_prefix_for_parsing`\n // could exhibit both behaviors.\n var capturedGroupsCount = prefixMatch.length - 1;\n var hasCapturedGroups = capturedGroupsCount > 0 && prefixMatch[capturedGroupsCount];\n if (metadata.nationalPrefixTransformRule() && hasCapturedGroups) {\n nationalNumber = number.replace(prefixPattern, metadata.nationalPrefixTransformRule());\n // If there's more than one captured group,\n // then carrier code is the second one.\n if (capturedGroupsCount > 1) {\n carrierCode = prefixMatch[1];\n }\n }\n // If there're no \"capturing groups\",\n // or if there're \"capturing groups\" but no\n // `national_prefix_transform_rule`,\n // then just strip the national prefix from the number,\n // and possibly a carrier code.\n // Seems like there could be more.\n else {\n // `prefixBeforeNationalNumber` is the whole substring matched by\n // the `national_prefix_for_parsing` regular expression.\n // There seem to be no guarantees that it's just a national prefix.\n // For example, if there's a carrier code, it's gonna be a\n // part of `prefixBeforeNationalNumber` too.\n var prefixBeforeNationalNumber = prefixMatch[0];\n nationalNumber = number.slice(prefixBeforeNationalNumber.length);\n // If there's at least one captured group,\n // then carrier code is the first one.\n if (hasCapturedGroups) {\n carrierCode = prefixMatch[1];\n }\n }\n // Tries to guess whether a national prefix was present in the input.\n // This is not something copy-pasted from Google's library:\n // they don't seem to have an equivalent for that.\n // So this isn't an \"officially approved\" way of doing something like that.\n // But since there seems no other existing method, this library uses it.\n var nationalPrefix;\n if (hasCapturedGroups) {\n var possiblePositionOfTheFirstCapturedGroup = number.indexOf(prefixMatch[1]);\n var possibleNationalPrefix = number.slice(0, possiblePositionOfTheFirstCapturedGroup);\n // Example: an Argentinian (AR) phone number `0111523456789`.\n // `prefixMatch[0]` is `01115`, and `$1` is `11`,\n // and the rest of the phone number is `23456789`.\n // The national number is transformed via `9$1` to `91123456789`.\n // National prefix `0` is detected being present at the start.\n // if (possibleNationalPrefix.indexOf(metadata.numberingPlan.nationalPrefix()) === 0) {\n if (possibleNationalPrefix === metadata.numberingPlan.nationalPrefix()) {\n nationalPrefix = metadata.numberingPlan.nationalPrefix();\n }\n } else {\n nationalPrefix = prefixMatch[0];\n }\n return {\n nationalNumber: nationalNumber,\n nationalPrefix: nationalPrefix,\n carrierCode: carrierCode\n };\n }\n }\n return {\n nationalNumber: number\n };\n}\n//# sourceMappingURL=extractNationalNumberFromPossiblyIncompleteNumber.js.map"],"x_google_ignoreList":[0],"mappings":";AAaA,SAAwB,EAAkD,GAAQ,GAAU;AAC1F,KAAI,KAAU,EAAS,cAAc,0BAA0B,EAAE;EAI/D,IAAI,IAAoB,OAAO,SAAS,EAAS,cAAc,0BAA0B,GAAG,IAAI,EAC5F,IAAc,EAAc,KAAK,EAAO;AAC5C,MAAI,GAAa;GACf,IAAI,GACA,GAiBA,IAAsB,EAAY,SAAS,GAC3C,IAAoB,IAAsB,KAAK,EAAY;AAC/D,OAAI,EAAS,6BAA6B,IAAI,EAI5C,CAHA,IAAiB,EAAO,QAAQ,GAAe,EAAS,6BAA6B,CAAC,EAGlF,IAAsB,MACxB,IAAc,EAAY;QASzB;IAMH,IAAI,IAA6B,EAAY;AAI7C,IAHA,IAAiB,EAAO,MAAM,EAA2B,OAAO,EAG5D,MACF,IAAc,EAAY;;GAQ9B,IAAI;AACJ,OAAI,GAAmB;IACrB,IAAI,IAA0C,EAAO,QAAQ,EAAY,GAAG;AAQ5E,IAP6B,EAAO,MAAM,GAAG,EAAwC,KAOtD,EAAS,cAAc,gBAAgB,KACpE,IAAiB,EAAS,cAAc,gBAAgB;SAG1D,KAAiB,EAAY;AAE/B,UAAO;IACW;IACA;IACH;IACd;;;AAGL,QAAO,EACL,gBAAgB,GACjB"}
|
package/dist/index26.js
CHANGED
|
@@ -1,24 +1,62 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
timeZone: n,
|
|
7
|
-
timeZoneName: "longOffset"
|
|
8
|
-
}).format)(a).split("GMT")[1];
|
|
9
|
-
return r in t ? t[r] : i(r, r.split(":"));
|
|
10
|
-
} catch {
|
|
11
|
-
if (n in t) return t[n];
|
|
12
|
-
let e = n?.match(r);
|
|
13
|
-
return e ? i(n, e.slice(1)) : NaN;
|
|
1
|
+
import { tzOffset as e } from "./index25.js";
|
|
2
|
+
//#region ../../node_modules/@date-fns/tz/date/mini.js
|
|
3
|
+
var t = class t extends Date {
|
|
4
|
+
constructor(...t) {
|
|
5
|
+
super(), t.length > 1 && typeof t[t.length - 1] == "string" && (this.timeZone = t.pop()), this.internal = /* @__PURE__ */ new Date(), isNaN(e(this.timeZone, this)) ? this.setTime(NaN) : t.length ? typeof t[0] == "number" && (t.length === 1 || t.length === 2 && typeof t[1] != "number") ? this.setTime(t[0]) : typeof t[0] == "string" ? this.setTime(+new Date(t[0])) : t[0] instanceof Date ? this.setTime(+t[0]) : (this.setTime(+new Date(...t)), a(this, NaN), r(this)) : this.setTime(Date.now());
|
|
14
6
|
}
|
|
7
|
+
static tz(e, ...n) {
|
|
8
|
+
return n.length ? new t(...n, e) : new t(Date.now(), e);
|
|
9
|
+
}
|
|
10
|
+
withTimeZone(e) {
|
|
11
|
+
return new t(+this, e);
|
|
12
|
+
}
|
|
13
|
+
getTimezoneOffset() {
|
|
14
|
+
let t = -e(this.timeZone, this);
|
|
15
|
+
return t > 0 ? Math.floor(t) : Math.ceil(t);
|
|
16
|
+
}
|
|
17
|
+
setTime(e) {
|
|
18
|
+
return Date.prototype.setTime.apply(this, arguments), r(this), +this;
|
|
19
|
+
}
|
|
20
|
+
[Symbol.for("constructDateFrom")](e) {
|
|
21
|
+
return new t(+new Date(e), this.timeZone);
|
|
22
|
+
}
|
|
23
|
+
}, n = /^(get|set)(?!UTC)/;
|
|
24
|
+
Object.getOwnPropertyNames(Date.prototype).forEach((e) => {
|
|
25
|
+
if (!n.test(e)) return;
|
|
26
|
+
let a = e.replace(n, "$1UTC");
|
|
27
|
+
t.prototype[a] && (e.startsWith("get") ? t.prototype[e] = function() {
|
|
28
|
+
return this.internal[a]();
|
|
29
|
+
} : (t.prototype[e] = function() {
|
|
30
|
+
return Date.prototype[a].apply(this.internal, arguments), i(this), +this;
|
|
31
|
+
}, t.prototype[a] = function() {
|
|
32
|
+
return Date.prototype[a].apply(this, arguments), r(this), +this;
|
|
33
|
+
}));
|
|
34
|
+
});
|
|
35
|
+
function r(t) {
|
|
36
|
+
t.internal.setTime(+t), t.internal.setUTCSeconds(t.internal.getUTCSeconds() - Math.round(-e(t.timeZone, t) * 60));
|
|
37
|
+
}
|
|
38
|
+
function i(e) {
|
|
39
|
+
Date.prototype.setFullYear.call(e, e.internal.getUTCFullYear(), e.internal.getUTCMonth(), e.internal.getUTCDate()), Date.prototype.setHours.call(e, e.internal.getUTCHours(), e.internal.getUTCMinutes(), e.internal.getUTCSeconds(), e.internal.getUTCMilliseconds()), a(e);
|
|
15
40
|
}
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
41
|
+
function a(t) {
|
|
42
|
+
let n = e(t.timeZone, t), r = n > 0 ? Math.floor(n) : Math.ceil(n), i = /* @__PURE__ */ new Date(+t);
|
|
43
|
+
i.setUTCHours(i.getUTCHours() - 1);
|
|
44
|
+
let a = -(/* @__PURE__ */ new Date(+t)).getTimezoneOffset(), o = a - -(/* @__PURE__ */ new Date(+i)).getTimezoneOffset(), s = Date.prototype.getHours.apply(t) !== t.internal.getUTCHours();
|
|
45
|
+
o && s && t.internal.setUTCMinutes(t.internal.getUTCMinutes() + o);
|
|
46
|
+
let c = a - r;
|
|
47
|
+
c && Date.prototype.setUTCMinutes.call(t, Date.prototype.getUTCMinutes.call(t) + c);
|
|
48
|
+
let l = /* @__PURE__ */ new Date(+t);
|
|
49
|
+
l.setUTCSeconds(0);
|
|
50
|
+
let u = a > 0 ? l.getSeconds() : (l.getSeconds() - 60) % 60, d = Math.round(-(e(t.timeZone, t) * 60)) % 60;
|
|
51
|
+
(d || u) && (t.internal.setUTCSeconds(t.internal.getUTCSeconds() + d), Date.prototype.setUTCSeconds.call(t, Date.prototype.getUTCSeconds.call(t) + d + u));
|
|
52
|
+
let f = e(t.timeZone, t), p = f > 0 ? Math.floor(f) : Math.ceil(f), m = -(/* @__PURE__ */ new Date(+t)).getTimezoneOffset() - p, h = p !== r, g = m - c;
|
|
53
|
+
if (h && g) {
|
|
54
|
+
Date.prototype.setUTCMinutes.call(t, Date.prototype.getUTCMinutes.call(t) + g);
|
|
55
|
+
let n = e(t.timeZone, t), r = p - (n > 0 ? Math.floor(n) : Math.ceil(n));
|
|
56
|
+
r && (t.internal.setUTCMinutes(t.internal.getUTCMinutes() + r), Date.prototype.setUTCMinutes.call(t, Date.prototype.getUTCMinutes.call(t) + r));
|
|
57
|
+
}
|
|
20
58
|
}
|
|
21
59
|
//#endregion
|
|
22
|
-
export {
|
|
60
|
+
export { t as TZDateMini };
|
|
23
61
|
|
|
24
62
|
//# sourceMappingURL=index26.js.map
|
package/dist/index26.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index26.js","names":[],"sources":["../../../node_modules/@date-fns/tz/tzOffset/index.js"],"sourcesContent":["const offsetFormatCache = {};\nconst offsetCache = {};\n\n/**\n * The function extracts UTC offset in minutes from the given date in specified\n * time zone.\n *\n * Unlike `Date.prototype.getTimezoneOffset`, this function returns the value\n * mirrored to the sign of the offset in the time zone. For Asia/Singapore\n * (UTC+8), `tzOffset` returns 480, while `getTimezoneOffset` returns -480.\n *\n * @param timeZone - Time zone name (IANA or UTC offset)\n * @param date - Date to check the offset for\n *\n * @returns UTC offset in minutes\n */\nexport function tzOffset(timeZone, date) {\n try {\n const format = offsetFormatCache[timeZone] ||= new Intl.DateTimeFormat(\"en-US\", {\n timeZone,\n timeZoneName: \"longOffset\"\n }).format;\n const offsetStr = format(date).split(\"GMT\")[1];\n if (offsetStr in offsetCache) return offsetCache[offsetStr];\n return calcOffset(offsetStr, offsetStr.split(\":\"));\n } catch {\n // Fallback to manual parsing if the runtime doesn't support ±HH:MM/±HHMM/±HH\n // See: https://github.com/nodejs/node/issues/53419\n if (timeZone in offsetCache) return offsetCache[timeZone];\n const captures = timeZone?.match(offsetRe);\n if (captures) return calcOffset(timeZone, captures.slice(1));\n return NaN;\n }\n}\nconst offsetRe = /([+-]\\d\\d):?(\\d\\d)?/;\nfunction calcOffset(cacheStr, values) {\n const hours = +(values[0] || 0);\n const minutes = +(values[1] || 0);\n // Convert seconds to minutes by dividing by 60 to keep the function return in minutes.\n const seconds = +(values[2] || 0) / 60;\n return offsetCache[cacheStr] = hours * 60 + minutes > 0 ? hours * 60 + minutes + seconds : hours * 60 - minutes - seconds;\n}"],"x_google_ignoreList":[0],"mappings":";AAAA,IAAM,IAAoB,EAAE,EACtB,IAAc,EAAE;AAetB,SAAgB,EAAS,GAAU,GAAM;AACvC,KAAI;EAKF,IAAM,KAJS,EAAkB,OAAc,IAAI,KAAK,eAAe,SAAS;GAC9E;GACA,cAAc;GACf,CAAC,CAAC,QACsB,EAAK,CAAC,MAAM,MAAM,CAAC;AAE5C,SADI,KAAa,IAAoB,EAAY,KAC1C,EAAW,GAAW,EAAU,MAAM,IAAI,CAAC;SAC5C;AAGN,MAAI,KAAY,EAAa,QAAO,EAAY;EAChD,IAAM,IAAW,GAAU,MAAM,EAAS;AAE1C,SADI,IAAiB,EAAW,GAAU,EAAS,MAAM,EAAE,CAAC,GACrD;;;AAGX,IAAM,IAAW;AACjB,SAAS,EAAW,GAAU,GAAQ;CACpC,IAAM,IAAQ,EAAE,EAAO,MAAM,IACvB,IAAU,EAAE,EAAO,MAAM,IAEzB,KAAY,EAAO,MAAM,KAAK;AACpC,QAAO,EAAY,KAAY,IAAQ,KAAK,IAAU,IAAI,IAAQ,KAAK,IAAU,IAAU,IAAQ,KAAK,IAAU"}
|
|
1
|
+
{"version":3,"file":"index26.js","names":[],"sources":["../../../node_modules/@date-fns/tz/date/mini.js"],"sourcesContent":["import { tzOffset } from \"../tzOffset/index.js\";\nexport class TZDateMini extends Date {\n //#region static\n\n constructor(...args) {\n super();\n if (args.length > 1 && typeof args[args.length - 1] === \"string\") {\n this.timeZone = args.pop();\n }\n this.internal = new Date();\n if (isNaN(tzOffset(this.timeZone, this))) {\n this.setTime(NaN);\n } else {\n if (!args.length) {\n this.setTime(Date.now());\n } else if (typeof args[0] === \"number\" && (args.length === 1 || args.length === 2 && typeof args[1] !== \"number\")) {\n this.setTime(args[0]);\n } else if (typeof args[0] === \"string\") {\n this.setTime(+new Date(args[0]));\n } else if (args[0] instanceof Date) {\n this.setTime(+args[0]);\n } else {\n this.setTime(+new Date(...args));\n adjustToSystemTZ(this, NaN);\n syncToInternal(this);\n }\n }\n }\n static tz(tz, ...args) {\n return args.length ? new TZDateMini(...args, tz) : new TZDateMini(Date.now(), tz);\n }\n\n //#endregion\n\n //#region time zone\n\n withTimeZone(timeZone) {\n return new TZDateMini(+this, timeZone);\n }\n getTimezoneOffset() {\n const offset = -tzOffset(this.timeZone, this);\n // Remove the seconds offset\n // use Math.floor for negative GMT timezones and Math.ceil for positive GMT timezones.\n return offset > 0 ? Math.floor(offset) : Math.ceil(offset);\n }\n\n //#endregion\n\n //#region time\n\n setTime(time) {\n Date.prototype.setTime.apply(this, arguments);\n syncToInternal(this);\n return +this;\n }\n\n //#endregion\n\n //#region date-fns integration\n\n [Symbol.for(\"constructDateFrom\")](date) {\n return new TZDateMini(+new Date(date), this.timeZone);\n }\n\n //#endregion\n}\n\n// Assign getters and setters\nconst re = /^(get|set)(?!UTC)/;\nObject.getOwnPropertyNames(Date.prototype).forEach(method => {\n if (!re.test(method)) return;\n const utcMethod = method.replace(re, \"$1UTC\");\n // Filter out methods without UTC counterparts\n if (!TZDateMini.prototype[utcMethod]) return;\n if (method.startsWith(\"get\")) {\n // Delegate to internal date's UTC method\n TZDateMini.prototype[method] = function () {\n return this.internal[utcMethod]();\n };\n } else {\n // Assign regular setter\n TZDateMini.prototype[method] = function () {\n Date.prototype[utcMethod].apply(this.internal, arguments);\n syncFromInternal(this);\n return +this;\n };\n\n // Assign UTC setter\n TZDateMini.prototype[utcMethod] = function () {\n Date.prototype[utcMethod].apply(this, arguments);\n syncToInternal(this);\n return +this;\n };\n }\n});\n\n/**\n * Function syncs time to internal date, applying the time zone offset.\n *\n * @param {Date} date - Date to sync\n */\nfunction syncToInternal(date) {\n date.internal.setTime(+date);\n date.internal.setUTCSeconds(date.internal.getUTCSeconds() - Math.round(-tzOffset(date.timeZone, date) * 60));\n}\n\n/**\n * Function syncs the internal date UTC values to the date. It allows to get\n * accurate timestamp value.\n *\n * @param {Date} date - The date to sync\n */\nfunction syncFromInternal(date) {\n // First we transpose the internal values\n Date.prototype.setFullYear.call(date, date.internal.getUTCFullYear(), date.internal.getUTCMonth(), date.internal.getUTCDate());\n Date.prototype.setHours.call(date, date.internal.getUTCHours(), date.internal.getUTCMinutes(), date.internal.getUTCSeconds(), date.internal.getUTCMilliseconds());\n\n // Now we have to adjust the date to the system time zone\n adjustToSystemTZ(date);\n}\n\n/**\n * Function adjusts the date to the system time zone. It uses the time zone\n * differences to calculate the offset and adjust the date.\n *\n * @param {Date} date - Date to adjust\n */\nfunction adjustToSystemTZ(date) {\n // Save the time zone offset before all the adjustments\n const baseOffset = tzOffset(date.timeZone, date);\n // Remove the seconds offset\n // use Math.floor for negative GMT timezones and Math.ceil for positive GMT timezones.\n const offset = baseOffset > 0 ? Math.floor(baseOffset) : Math.ceil(baseOffset);\n //#region System DST adjustment\n\n // The biggest problem with using the system time zone is that when we create\n // a date from internal values stored in UTC, the system time zone might end\n // up on the DST hour:\n //\n // $ TZ=America/New_York node\n // > new Date(2020, 2, 8, 1).toString()\n // 'Sun Mar 08 2020 01:00:00 GMT-0500 (Eastern Standard Time)'\n // > new Date(2020, 2, 8, 2).toString()\n // 'Sun Mar 08 2020 03:00:00 GMT-0400 (Eastern Daylight Time)'\n // > new Date(2020, 2, 8, 3).toString()\n // 'Sun Mar 08 2020 03:00:00 GMT-0400 (Eastern Daylight Time)'\n // > new Date(2020, 2, 8, 4).toString()\n // 'Sun Mar 08 2020 04:00:00 GMT-0400 (Eastern Daylight Time)'\n //\n // Here we get the same hour for both 2 and 3, because the system time zone\n // has DST beginning at 8 March 2020, 2 a.m. and jumps to 3 a.m. So we have\n // to adjust the internal date to reflect that.\n //\n // However we want to adjust only if that's the DST hour the change happenes,\n // not the hour where DST moves to.\n\n // We calculate the previous hour to see if the time zone offset has changed\n // and we have landed on the DST hour.\n const prevHour = new Date(+date);\n // We use UTC methods here as we don't want to land on the same hour again\n // in case of DST.\n prevHour.setUTCHours(prevHour.getUTCHours() - 1);\n\n // Calculate if we are on the system DST hour.\n const systemOffset = -new Date(+date).getTimezoneOffset();\n const prevHourSystemOffset = -new Date(+prevHour).getTimezoneOffset();\n const systemDSTChange = systemOffset - prevHourSystemOffset;\n // Detect the DST shift. System DST change will occur both on\n const dstShift = Date.prototype.getHours.apply(date) !== date.internal.getUTCHours();\n\n // Move the internal date when we are on the system DST hour.\n if (systemDSTChange && dstShift) date.internal.setUTCMinutes(date.internal.getUTCMinutes() + systemDSTChange);\n\n //#endregion\n\n //#region System diff adjustment\n\n // Now we need to adjust the date, since we just applied internal values.\n // We need to calculate the difference between the system and date time zones\n // and apply it to the date.\n\n const offsetDiff = systemOffset - offset;\n if (offsetDiff) Date.prototype.setUTCMinutes.call(date, Date.prototype.getUTCMinutes.call(date) + offsetDiff);\n\n //#endregion\n\n //#region Seconds System diff adjustment\n\n const systemDate = new Date(+date);\n // Set the UTC seconds to 0 to isolate the timezone offset in seconds.\n systemDate.setUTCSeconds(0);\n // For negative systemOffset, invert the seconds.\n const systemSecondsOffset = systemOffset > 0 ? systemDate.getSeconds() : (systemDate.getSeconds() - 60) % 60;\n\n // Calculate the seconds offset based on the timezone offset.\n const secondsOffset = Math.round(-(tzOffset(date.timeZone, date) * 60)) % 60;\n if (secondsOffset || systemSecondsOffset) {\n date.internal.setUTCSeconds(date.internal.getUTCSeconds() + secondsOffset);\n Date.prototype.setUTCSeconds.call(date, Date.prototype.getUTCSeconds.call(date) + secondsOffset + systemSecondsOffset);\n }\n\n //#endregion\n\n //#region Post-adjustment DST fix\n\n const postBaseOffset = tzOffset(date.timeZone, date);\n // Remove the seconds offset\n // use Math.floor for negative GMT timezones and Math.ceil for positive GMT timezones.\n const postOffset = postBaseOffset > 0 ? Math.floor(postBaseOffset) : Math.ceil(postBaseOffset);\n const postSystemOffset = -new Date(+date).getTimezoneOffset();\n const postOffsetDiff = postSystemOffset - postOffset;\n const offsetChanged = postOffset !== offset;\n const postDiff = postOffsetDiff - offsetDiff;\n if (offsetChanged && postDiff) {\n Date.prototype.setUTCMinutes.call(date, Date.prototype.getUTCMinutes.call(date) + postDiff);\n\n // Now we need to check if got offset change during the post-adjustment.\n // If so, we also need both dates to reflect that.\n\n const newBaseOffset = tzOffset(date.timeZone, date);\n // Remove the seconds offset\n // use Math.floor for negative GMT timezones and Math.ceil for positive GMT timezones.\n const newOffset = newBaseOffset > 0 ? Math.floor(newBaseOffset) : Math.ceil(newBaseOffset);\n const offsetChange = postOffset - newOffset;\n if (offsetChange) {\n date.internal.setUTCMinutes(date.internal.getUTCMinutes() + offsetChange);\n Date.prototype.setUTCMinutes.call(date, Date.prototype.getUTCMinutes.call(date) + offsetChange);\n }\n }\n\n //#endregion\n}"],"x_google_ignoreList":[0],"mappings":"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"}
|
package/dist/index260.js
CHANGED
|
@@ -1,29 +1,47 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
}
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
var u = e.indexOf(r[1]);
|
|
15
|
-
e.slice(0, u) === t.numberingPlan.nationalPrefix() && (l = t.numberingPlan.nationalPrefix());
|
|
16
|
-
} else l = r[0];
|
|
17
|
-
return {
|
|
18
|
-
nationalNumber: i,
|
|
19
|
-
nationalPrefix: l,
|
|
20
|
-
carrierCode: a
|
|
1
|
+
import { Metadata as e } from "./index249.js";
|
|
2
|
+
import t from "./index254.js";
|
|
3
|
+
//#region ../../node_modules/libphonenumber-js/es6/helpers/getCountryByNationalNumber.js
|
|
4
|
+
function n(e, t) {
|
|
5
|
+
var n = typeof Symbol < "u" && e[Symbol.iterator] || e["@@iterator"];
|
|
6
|
+
if (n) return (n = n.call(e)).next.bind(n);
|
|
7
|
+
if (Array.isArray(e) || (n = r(e)) || t && e && typeof e.length == "number") {
|
|
8
|
+
n && (e = n);
|
|
9
|
+
var i = 0;
|
|
10
|
+
return function() {
|
|
11
|
+
return i >= e.length ? { done: !0 } : {
|
|
12
|
+
done: !1,
|
|
13
|
+
value: e[i++]
|
|
21
14
|
};
|
|
22
|
-
}
|
|
15
|
+
};
|
|
16
|
+
}
|
|
17
|
+
throw TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
18
|
+
}
|
|
19
|
+
function r(e, t) {
|
|
20
|
+
if (e) {
|
|
21
|
+
if (typeof e == "string") return i(e, t);
|
|
22
|
+
var n = {}.toString.call(e).slice(8, -1);
|
|
23
|
+
return n === "Object" && e.constructor && (n = e.constructor.name), n === "Map" || n === "Set" ? Array.from(e) : n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n) ? i(e, t) : void 0;
|
|
24
|
+
}
|
|
25
|
+
}
|
|
26
|
+
function i(e, t) {
|
|
27
|
+
(t == null || t > e.length) && (t = e.length);
|
|
28
|
+
for (var n = 0, r = Array(t); n < t; n++) r[n] = e[n];
|
|
29
|
+
return r;
|
|
30
|
+
}
|
|
31
|
+
function a(r, i) {
|
|
32
|
+
var a = i.countries, o = i.metadata;
|
|
33
|
+
o = new e(o);
|
|
34
|
+
for (var s = n(a), c; !(c = s()).done;) {
|
|
35
|
+
var l = c.value;
|
|
36
|
+
if (o.selectNumberingPlan(l), o.leadingDigits()) {
|
|
37
|
+
if (r && r.search(o.leadingDigits()) === 0) return l;
|
|
38
|
+
} else if (t({
|
|
39
|
+
phone: r,
|
|
40
|
+
country: l
|
|
41
|
+
}, void 0, o.metadata)) return l;
|
|
23
42
|
}
|
|
24
|
-
return { nationalNumber: e };
|
|
25
43
|
}
|
|
26
44
|
//#endregion
|
|
27
|
-
export {
|
|
45
|
+
export { a as default };
|
|
28
46
|
|
|
29
47
|
//# sourceMappingURL=index260.js.map
|
package/dist/index260.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index260.js","names":[],"sources":["../../../node_modules/libphonenumber-js/es6/helpers/
|
|
1
|
+
{"version":3,"file":"index260.js","names":[],"sources":["../../../node_modules/libphonenumber-js/es6/helpers/getCountryByNationalNumber.js"],"sourcesContent":["function _createForOfIteratorHelperLoose(r, e) { var t = \"undefined\" != typeof Symbol && r[Symbol.iterator] || r[\"@@iterator\"]; if (t) return (t = t.call(r)).next.bind(t); if (Array.isArray(r) || (t = _unsupportedIterableToArray(r)) || e && r && \"number\" == typeof r.length) { t && (r = t); var o = 0; return function () { return o >= r.length ? { done: !0 } : { done: !1, value: r[o++] }; }; } throw new TypeError(\"Invalid attempt to iterate non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\"); }\nfunction _unsupportedIterableToArray(r, a) { if (r) { if (\"string\" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return \"Object\" === t && r.constructor && (t = r.constructor.name), \"Map\" === t || \"Set\" === t ? Array.from(r) : \"Arguments\" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }\nfunction _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }\nimport Metadata from '../metadata.js';\nimport getNumberType from './getNumberType.js';\n\n// Returns the exact country that the `nationalPhoneNumber` belongs to\n// in cases of ambiguity, i.e. when multiple countries share the same \"country calling code\".\nexport default function getCountryByNationalNumber(nationalPhoneNumber, _ref) {\n var countries = _ref.countries,\n metadata = _ref.metadata;\n // Re-create `metadata` because it will be selecting a `country`.\n metadata = new Metadata(metadata);\n\n // const matchingCountries = []\n\n for (var _iterator = _createForOfIteratorHelperLoose(countries), _step; !(_step = _iterator()).done;) {\n var country = _step.value;\n metadata.selectNumberingPlan(country);\n // \"Leading digits\" patterns are only defined for about 20% of all countries.\n // By definition, matching \"leading digits\" is a sufficient but not a necessary\n // condition for a phone number to belong to a country.\n // The point of \"leading digits\" check is that it's the fastest one to get a match.\n // https://gitlab.com/catamphetamine/libphonenumber-js/blob/master/METADATA.md#leading_digits\n // I'd suppose that \"leading digits\" patterns are mutually exclusive for different countries\n // because of the intended use of that feature.\n if (metadata.leadingDigits()) {\n if (nationalPhoneNumber && nationalPhoneNumber.search(metadata.leadingDigits()) === 0) {\n return country;\n }\n }\n // Else perform full validation with all of those\n // fixed-line/mobile/etc regular expressions.\n else if (getNumberType({\n phone: nationalPhoneNumber,\n country: country\n }, undefined, metadata.metadata)) {\n // When multiple countries share the same \"country calling code\",\n // type patterns aren't guaranteed to be unique among them.\n // For example, both `US` and `CA` have the same pattern for `toll_free` numbers.\n // https://gitlab.com/catamphetamine/libphonenumber-js/-/issues/103#note_1417147572\n //\n // That means that this `if` condition could be `true` for multiple countries from the list.\n // Currently, it just returns the first one, which is also the \"main\" country for the \"country calling code\".\n // In an example with `toll_free` numbers above, `\"US\"` would be returned even though\n // it could as well be `\"CA\"`.\n //\n // There was also a time when this attempted to be overly smart\n // and kept track of all such multiple matching countries\n // and then picked the one that matched the `defaultCountry`, if provided.\n // For example, with `toll_free` numbers above, and with `defaultCountry: \"CA\"`,\n // it would've returned `\"CA\"` instead of `\"US\"`.\n // Later it turned out that such \"overly smart\" behavior turned out to be just confusing,\n // so this \"overly smart\" country detection was reverted to returning the \"main\" country\n // for the \"country calling code\".\n // https://gitlab.com/catamphetamine/libphonenumber-js/-/issues/154\n //\n return country;\n //\n // The \"overly smart\" behavior code:\n //\n // if (defaultCountry) {\n // \tif (country === defaultCountry) {\n // \t\treturn country\n // \t} else {\n // \t\tmatchingCountries.push(country)\n // \t}\n // } else {\n // \treturn country\n // }\n }\n }\n\n // // Return the first (\"main\") one of the `matchingCountries`.\n // if (matchingCountries.length > 0) {\n // \treturn matchingCountries[0]\n // }\n}\n//# sourceMappingURL=getCountryByNationalNumber.js.map"],"x_google_ignoreList":[0],"mappings":";;;AAAA,SAAS,EAAgC,GAAG,GAAG;CAAE,IAAI,IAAmB,OAAO,SAAtB,OAAgC,EAAE,OAAO,aAAa,EAAE;AAAe,KAAI,EAAG,SAAQ,IAAI,EAAE,KAAK,EAAE,EAAE,KAAK,KAAK,EAAE;AAAE,KAAI,MAAM,QAAQ,EAAE,KAAK,IAAI,EAA4B,EAAE,KAAK,KAAK,KAAiB,OAAO,EAAE,UAArB,UAA6B;AAAE,QAAM,IAAI;EAAI,IAAI,IAAI;AAAG,SAAO,WAAY;AAAE,UAAO,KAAK,EAAE,SAAS,EAAE,MAAM,CAAC,GAAG,GAAG;IAAE,MAAM,CAAC;IAAG,OAAO,EAAE;IAAM;;;AAAO,OAAU,UAAU,wIAAwI;;AACviB,SAAS,EAA4B,GAAG,GAAG;AAAE,KAAI,GAAG;AAAE,MAAgB,OAAO,KAAnB,SAAsB,QAAO,EAAkB,GAAG,EAAE;EAAE,IAAI,IAAI,EAAE,CAAC,SAAS,KAAK,EAAE,CAAC,MAAM,GAAG,GAAG;AAAE,SAAoB,MAAb,YAAkB,EAAE,gBAAgB,IAAI,EAAE,YAAY,OAAiB,MAAV,SAAyB,MAAV,QAAc,MAAM,KAAK,EAAE,GAAmB,MAAhB,eAAqB,2CAA2C,KAAK,EAAE,GAAG,EAAkB,GAAG,EAAE,GAAG,KAAK;;;AACpX,SAAS,EAAkB,GAAG,GAAG;AAAE,EAAS,KAAR,QAAa,IAAI,EAAE,YAAY,IAAI,EAAE;AAAS,MAAK,IAAI,IAAI,GAAG,IAAI,MAAM,EAAE,EAAE,IAAI,GAAG,IAAK,GAAE,KAAK,EAAE;AAAI,QAAO;;AAMhJ,SAAwB,EAA2B,GAAqB,GAAM;CAC5E,IAAI,IAAY,EAAK,WACnB,IAAW,EAAK;AAElB,KAAW,IAAI,EAAS,EAAS;AAIjC,MAAK,IAAI,IAAY,EAAgC,EAAU,EAAE,GAAO,EAAE,IAAQ,GAAW,EAAE,OAAO;EACpG,IAAI,IAAU,EAAM;AASpB,MARA,EAAS,oBAAoB,EAAQ,EAQjC,EAAS,eAAe;OACtB,KAAuB,EAAoB,OAAO,EAAS,eAAe,CAAC,KAAK,EAClF,QAAO;aAKF,EAAc;GACrB,OAAO;GACE;GACV,EAAE,KAAA,GAAW,EAAS,SAAS,CAqB9B,QAAO"}
|
package/dist/index261.js
CHANGED
|
@@ -1,47 +1,17 @@
|
|
|
1
|
-
import
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
function n(
|
|
5
|
-
var
|
|
6
|
-
|
|
7
|
-
if (
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
value: e[i++]
|
|
14
|
-
};
|
|
15
|
-
};
|
|
16
|
-
}
|
|
17
|
-
throw TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
18
|
-
}
|
|
19
|
-
function r(e, t) {
|
|
20
|
-
if (e) {
|
|
21
|
-
if (typeof e == "string") return i(e, t);
|
|
22
|
-
var n = {}.toString.call(e).slice(8, -1);
|
|
23
|
-
return n === "Object" && e.constructor && (n = e.constructor.name), n === "Map" || n === "Set" ? Array.from(e) : n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n) ? i(e, t) : void 0;
|
|
24
|
-
}
|
|
25
|
-
}
|
|
26
|
-
function i(e, t) {
|
|
27
|
-
(t == null || t > e.length) && (t = e.length);
|
|
28
|
-
for (var n = 0, r = Array(t); n < t; n++) r[n] = e[n];
|
|
29
|
-
return r;
|
|
30
|
-
}
|
|
31
|
-
function a(r, i) {
|
|
32
|
-
var a = i.countries, o = i.metadata;
|
|
33
|
-
o = new e(o);
|
|
34
|
-
for (var s = n(a), c; !(c = s()).done;) {
|
|
35
|
-
var l = c.value;
|
|
36
|
-
if (o.selectNumberingPlan(l), o.leadingDigits()) {
|
|
37
|
-
if (r && r.search(o.leadingDigits()) === 0) return l;
|
|
38
|
-
} else if (t({
|
|
39
|
-
phone: r,
|
|
40
|
-
country: l
|
|
41
|
-
}, void 0, o.metadata)) return l;
|
|
42
|
-
}
|
|
1
|
+
import e from "./index260.js";
|
|
2
|
+
//#region ../../node_modules/libphonenumber-js/es6/helpers/getCountryByCallingCode.js
|
|
3
|
+
var t = !1;
|
|
4
|
+
function n(n, r) {
|
|
5
|
+
var i = r.nationalNumber, a = r.metadata;
|
|
6
|
+
/* istanbul ignore if */
|
|
7
|
+
if (t && a.isNonGeographicCallingCode(n)) return "001";
|
|
8
|
+
var o = a.getCountryCodesForCallingCode(n);
|
|
9
|
+
if (o) return o.length === 1 ? o[0] : e(i, {
|
|
10
|
+
countries: o,
|
|
11
|
+
metadata: a.metadata
|
|
12
|
+
});
|
|
43
13
|
}
|
|
44
14
|
//#endregion
|
|
45
|
-
export {
|
|
15
|
+
export { n as default };
|
|
46
16
|
|
|
47
17
|
//# sourceMappingURL=index261.js.map
|
package/dist/index261.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index261.js","names":[],"sources":["../../../node_modules/libphonenumber-js/es6/helpers/
|
|
1
|
+
{"version":3,"file":"index261.js","names":[],"sources":["../../../node_modules/libphonenumber-js/es6/helpers/getCountryByCallingCode.js"],"sourcesContent":["import getCountryByNationalNumber from './getCountryByNationalNumber.js';\nvar USE_NON_GEOGRAPHIC_COUNTRY_CODE = false;\n\n// Returns the exact country for the `nationalNumber`\n// that belongs to the specified \"country calling code\".\nexport default function getCountryByCallingCode(callingCode, _ref) {\n var nationalPhoneNumber = _ref.nationalNumber,\n metadata = _ref.metadata;\n /* istanbul ignore if */\n if (USE_NON_GEOGRAPHIC_COUNTRY_CODE) {\n if (metadata.isNonGeographicCallingCode(callingCode)) {\n return '001';\n }\n }\n var possibleCountries = metadata.getCountryCodesForCallingCode(callingCode);\n if (!possibleCountries) {\n return;\n }\n // If there's just one country corresponding to the country code,\n // then just return it, without further phone number digits validation.\n if (possibleCountries.length === 1) {\n return possibleCountries[0];\n }\n return getCountryByNationalNumber(nationalPhoneNumber, {\n countries: possibleCountries,\n metadata: metadata.metadata\n });\n}\n//# sourceMappingURL=getCountryByCallingCode.js.map"],"x_google_ignoreList":[0],"mappings":";;AACA,IAAI,IAAkC;AAItC,SAAwB,EAAwB,GAAa,GAAM;CACjE,IAAI,IAAsB,EAAK,gBAC7B,IAAW,EAAK;;AAElB,KAAI,KACE,EAAS,2BAA2B,EAAY,CAClD,QAAO;CAGX,IAAI,IAAoB,EAAS,8BAA8B,EAAY;AACtE,OAQL,QAHI,EAAkB,WAAW,IACxB,EAAkB,KAEpB,EAA2B,GAAqB;EACrD,WAAW;EACX,UAAU,EAAS;EACpB,CAAC"}
|
package/dist/index262.js
CHANGED
|
@@ -1,17 +1,29 @@
|
|
|
1
|
-
import e from "./
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
1
|
+
import e from "./index251.js";
|
|
2
|
+
import t from "./index253.js";
|
|
3
|
+
import n from "./index259.js";
|
|
4
|
+
import r from "./index261.js";
|
|
5
|
+
//#region ../../node_modules/libphonenumber-js/es6/helpers/extractNationalNumber.js
|
|
6
|
+
function i(e, t, i) {
|
|
7
|
+
var s = n(e, i), c = s.carrierCode, l = s.nationalNumber;
|
|
8
|
+
return l !== e && (!a(e, l, i) || i.numberingPlan.possibleLengths() && (t ||= r(i.numberingPlan.callingCode(), {
|
|
9
|
+
nationalNumber: l,
|
|
10
|
+
metadata: i
|
|
11
|
+
}), !o(l, t, i))) ? { nationalNumber: e } : {
|
|
12
|
+
nationalNumber: l,
|
|
13
|
+
carrierCode: c
|
|
14
|
+
};
|
|
15
|
+
}
|
|
16
|
+
function a(e, n, r) {
|
|
17
|
+
return !(t(e, r.nationalNumberPattern()) && !t(n, r.nationalNumberPattern()));
|
|
18
|
+
}
|
|
19
|
+
function o(t, n, r) {
|
|
20
|
+
switch (e(t, n, r)) {
|
|
21
|
+
case "TOO_SHORT":
|
|
22
|
+
case "INVALID_LENGTH": return !1;
|
|
23
|
+
default: return !0;
|
|
24
|
+
}
|
|
13
25
|
}
|
|
14
26
|
//#endregion
|
|
15
|
-
export {
|
|
27
|
+
export { i as default };
|
|
16
28
|
|
|
17
29
|
//# sourceMappingURL=index262.js.map
|
package/dist/index262.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index262.js","names":[],"sources":["../../../node_modules/libphonenumber-js/es6/helpers/
|
|
1
|
+
{"version":3,"file":"index262.js","names":[],"sources":["../../../node_modules/libphonenumber-js/es6/helpers/extractNationalNumber.js"],"sourcesContent":["import extractNationalNumberFromPossiblyIncompleteNumber from './extractNationalNumberFromPossiblyIncompleteNumber.js';\nimport matchesEntirely from './matchesEntirely.js';\nimport checkNumberLength from './checkNumberLength.js';\nimport getCountryByCallingCode from './getCountryByCallingCode.js';\n\n/**\r\n * Strips national prefix and carrier code from a complete phone number.\r\n * The difference from the non-\"FromCompleteNumber\" function is that\r\n * it won't extract national prefix if the resultant number is too short\r\n * to be a complete number for the selected phone numbering plan.\r\n * @param {string} number — Complete phone number digits.\r\n * @param {string?} country — Country, if known.\r\n * @param {Metadata} metadata — Metadata with a phone numbering plan selected.\r\n * @return {object} `{ nationalNumber: string, carrierCode: string? }`.\r\n */\nexport default function extractNationalNumber(number, country, metadata) {\n // Parsing national prefixes and carrier codes\n // is only required for local phone numbers\n // but some people don't understand that\n // and sometimes write international phone numbers\n // with national prefixes (or maybe even carrier codes).\n // http://ucken.blogspot.ru/2016/03/trunk-prefixes-in-skype4b.html\n // Google's original library forgives such mistakes\n // and so does this library, because it has been requested:\n // https://github.com/catamphetamine/libphonenumber-js/issues/127\n var _extractNationalNumbe = extractNationalNumberFromPossiblyIncompleteNumber(number, metadata),\n carrierCode = _extractNationalNumbe.carrierCode,\n nationalNumber = _extractNationalNumbe.nationalNumber;\n if (nationalNumber !== number) {\n if (!shouldHaveExtractedNationalPrefix(number, nationalNumber, metadata)) {\n // Don't strip the national prefix.\n return {\n nationalNumber: number\n };\n }\n // Check the national (significant) number length after extracting national prefix and carrier code.\n // Legacy generated metadata (before `1.0.18`) didn't support the \"possible lengths\" feature.\n if (metadata.numberingPlan.possibleLengths()) {\n // If an exact `country` is not specified, attempt to detect it from the assumed national number.\n if (!country) {\n country = getCountryByCallingCode(metadata.numberingPlan.callingCode(), {\n nationalNumber: nationalNumber,\n metadata: metadata\n });\n }\n\n // The number remaining after stripping the national prefix and carrier code\n // should be long enough to have a possible length for the country.\n // Otherwise, don't strip the national prefix and carrier code,\n // since the original number could be a valid number.\n // This check has been copy-pasted \"as is\" from Google's original library:\n // https://github.com/google/libphonenumber/blob/876268eb1ad6cdc1b7b5bef17fc5e43052702d57/java/libphonenumber/src/com/google/i18n/phonenumbers/PhoneNumberUtil.java#L3236-L3250\n // It doesn't check for the \"possibility\" of the original `number`.\n // I guess it's fine not checking that one. It works as is anyway.\n if (!isPossibleIncompleteNationalNumber(nationalNumber, country, metadata)) {\n // Don't strip the national prefix.\n return {\n nationalNumber: number\n };\n }\n }\n }\n return {\n nationalNumber: nationalNumber,\n carrierCode: carrierCode\n };\n}\n\n// In some countries, the same digit could be a national prefix\n// or a leading digit of a valid phone number.\n// For example, in Russia, national prefix is `8`,\n// and also `800 555 35 35` is a valid number\n// in which `8` is not a national prefix, but the first digit\n// of a national (significant) number.\n// Same's with Belarus:\n// `82004910060` is a valid national (significant) number,\n// but `2004910060` is not.\n// To support such cases (to prevent the code from always stripping\n// national prefix), a condition is imposed: a national prefix\n// is not extracted when the original number is \"viable\" and the\n// resultant number is not, a \"viable\" national number being the one\n// that matches `national_number_pattern`.\nfunction shouldHaveExtractedNationalPrefix(nationalNumberBefore, nationalNumberAfter, metadata) {\n // The equivalent in Google's code is:\n // https://github.com/google/libphonenumber/blob/e326fa1fc4283bb05eb35cb3c15c18f98a31af33/java/libphonenumber/src/com/google/i18n/phonenumbers/PhoneNumberUtil.java#L2969-L3004\n if (matchesEntirely(nationalNumberBefore, metadata.nationalNumberPattern()) && !matchesEntirely(nationalNumberAfter, metadata.nationalNumberPattern())) {\n return false;\n }\n // This \"is possible\" national number (length) check has been commented out\n // because it's superceded by the (effectively) same check done in the\n // `extractNationalNumber()` function after it calls `shouldHaveExtractedNationalPrefix()`.\n // In other words, why run the same check twice if it could only be run once.\n // // Check the national (significant) number length after extracting national prefix and carrier code.\n // // Fixes a minor \"weird behavior\" bug: https://gitlab.com/catamphetamine/libphonenumber-js/-/issues/57\n // // (Legacy generated metadata (before `1.0.18`) didn't support the \"possible lengths\" feature).\n // if (metadata.possibleLengths()) {\n // \tif (isPossibleIncompleteNationalNumber(nationalNumberBefore, metadata) &&\n // \t\t!isPossibleIncompleteNationalNumber(nationalNumberAfter, metadata)) {\n // \t\treturn false\n // \t}\n // }\n return true;\n}\nfunction isPossibleIncompleteNationalNumber(nationalNumber, country, metadata) {\n switch (checkNumberLength(nationalNumber, country, metadata)) {\n case 'TOO_SHORT':\n case 'INVALID_LENGTH':\n // This library ignores \"local-only\" phone numbers (for simplicity).\n // See the readme for more info on what are \"local-only\" phone numbers.\n // case 'IS_POSSIBLE_LOCAL_ONLY':\n return false;\n default:\n return true;\n }\n}\n//# sourceMappingURL=extractNationalNumber.js.map"],"x_google_ignoreList":[0],"mappings":";;;;;AAeA,SAAwB,EAAsB,GAAQ,GAAS,GAAU;CAUvE,IAAI,IAAwB,EAAkD,GAAQ,EAAS,EAC7F,IAAc,EAAsB,aACpC,IAAiB,EAAsB;AAmCzC,QAlCI,MAAmB,MACjB,CAAC,EAAkC,GAAQ,GAAgB,EAAS,IAQpE,EAAS,cAAc,iBAAiB,KAE1C,AACE,MAAU,EAAwB,EAAS,cAAc,aAAa,EAAE;EACtD;EACN;EACX,CAAC,EAWA,CAAC,EAAmC,GAAgB,GAAS,EAAS,KAEjE,EACL,gBAAgB,GACjB,GAIA;EACW;EACH;EACd;;AAiBH,SAAS,EAAkC,GAAsB,GAAqB,GAAU;AAmB9F,QAhBA,EAAI,EAAgB,GAAsB,EAAS,uBAAuB,CAAC,IAAI,CAAC,EAAgB,GAAqB,EAAS,uBAAuB,CAAC;;AAkBxJ,SAAS,EAAmC,GAAgB,GAAS,GAAU;AAC7E,SAAQ,EAAkB,GAAgB,GAAS,EAAS,EAA5D;EACE,KAAK;EACL,KAAK,iBAIH,QAAO;EACT,QACE,QAAO"}
|
package/dist/index263.js
CHANGED
|
@@ -1,29 +1,21 @@
|
|
|
1
|
-
import e from "./
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
import
|
|
5
|
-
//#region ../../node_modules/libphonenumber-js/es6/helpers/
|
|
6
|
-
function
|
|
7
|
-
var
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
}
|
|
16
|
-
function a(e, n, r) {
|
|
17
|
-
return !(t(e, r.nationalNumberPattern()) && !t(n, r.nationalNumberPattern()));
|
|
18
|
-
}
|
|
19
|
-
function o(t, n, r) {
|
|
20
|
-
switch (e(t, n, r)) {
|
|
21
|
-
case "TOO_SHORT":
|
|
22
|
-
case "INVALID_LENGTH": return !1;
|
|
23
|
-
default: return !0;
|
|
1
|
+
import { Metadata as e, getCountryCallingCode as t } from "./index249.js";
|
|
2
|
+
import n from "./index251.js";
|
|
3
|
+
import r from "./index253.js";
|
|
4
|
+
import i from "./index262.js";
|
|
5
|
+
//#region ../../node_modules/libphonenumber-js/es6/helpers/extractCountryCallingCodeFromInternationalNumberWithoutPlusSign.js
|
|
6
|
+
function a(a, o, s, c, l) {
|
|
7
|
+
var u = o || s ? t(o || s, l) : c;
|
|
8
|
+
if (a.indexOf(u) === 0) {
|
|
9
|
+
l = new e(l), l.selectNumberingPlan(o || s, u);
|
|
10
|
+
var d = a.slice(u.length), f = i(d, o, l).nationalNumber, p = i(a, o, l).nationalNumber;
|
|
11
|
+
if (!r(p, l.nationalNumberPattern()) && r(f, l.nationalNumberPattern()) || n(p, o, l) === "TOO_LONG") return {
|
|
12
|
+
countryCallingCode: u,
|
|
13
|
+
number: d
|
|
14
|
+
};
|
|
24
15
|
}
|
|
16
|
+
return { number: a };
|
|
25
17
|
}
|
|
26
18
|
//#endregion
|
|
27
|
-
export {
|
|
19
|
+
export { a as default };
|
|
28
20
|
|
|
29
21
|
//# sourceMappingURL=index263.js.map
|
package/dist/index263.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index263.js","names":[],"sources":["../../../node_modules/libphonenumber-js/es6/helpers/
|
|
1
|
+
{"version":3,"file":"index263.js","names":[],"sources":["../../../node_modules/libphonenumber-js/es6/helpers/extractCountryCallingCodeFromInternationalNumberWithoutPlusSign.js"],"sourcesContent":["import Metadata from '../metadata.js';\nimport matchesEntirely from './matchesEntirely.js';\nimport extractNationalNumber from './extractNationalNumber.js';\nimport checkNumberLength from './checkNumberLength.js';\nimport getCountryCallingCode from '../getCountryCallingCode.js';\n\n/**\r\n * Sometimes some people incorrectly input international phone numbers\r\n * without the leading `+`. This function corrects such input.\r\n * @param {string} number — Phone number digits.\r\n * @param {string} [country] — Exact country of the phone number.\r\n * @param {string} [defaultCountry]\r\n * @param {string} [defaultCallingCode]\r\n * @param {object} metadata\r\n * @return {object} `{ countryCallingCode: string?, number: string }`.\r\n */\nexport default function extractCountryCallingCodeFromInternationalNumberWithoutPlusSign(number, country, defaultCountry, defaultCallingCode, metadata) {\n var countryCallingCode = country || defaultCountry ? getCountryCallingCode(country || defaultCountry, metadata) : defaultCallingCode;\n if (number.indexOf(countryCallingCode) === 0) {\n metadata = new Metadata(metadata);\n metadata.selectNumberingPlan(country || defaultCountry, countryCallingCode);\n var possibleShorterNumber = number.slice(countryCallingCode.length);\n var _extractNationalNumbe = extractNationalNumber(possibleShorterNumber, country, metadata),\n possibleShorterNationalNumber = _extractNationalNumbe.nationalNumber;\n var _extractNationalNumbe2 = extractNationalNumber(number, country, metadata),\n nationalNumber = _extractNationalNumbe2.nationalNumber;\n\n // If the number was not valid before but is valid now,\n // or if it was too long before, we consider the number\n // with the country calling code stripped to be a better result\n // and keep that instead.\n // For example, in Germany (+49), `49` is a valid area code,\n // so if a number starts with `49`, it could be both a valid\n // national German number or an international number without\n // a leading `+`.\n if (!matchesEntirely(nationalNumber, metadata.nationalNumberPattern()) && matchesEntirely(possibleShorterNationalNumber, metadata.nationalNumberPattern()) || checkNumberLength(nationalNumber, country, metadata) === 'TOO_LONG') {\n return {\n countryCallingCode: countryCallingCode,\n number: possibleShorterNumber\n };\n }\n }\n return {\n number: number\n };\n}\n//# sourceMappingURL=extractCountryCallingCodeFromInternationalNumberWithoutPlusSign.js.map"],"x_google_ignoreList":[0],"mappings":";;;;;AAgBA,SAAwB,EAAgE,GAAQ,GAAS,GAAgB,GAAoB,GAAU;CACrJ,IAAI,IAAqB,KAAW,IAAiB,EAAsB,KAAW,GAAgB,EAAS,GAAG;AAClH,KAAI,EAAO,QAAQ,EAAmB,KAAK,GAAG;AAE5C,EADA,IAAW,IAAI,EAAS,EAAS,EACjC,EAAS,oBAAoB,KAAW,GAAgB,EAAmB;EAC3E,IAAI,IAAwB,EAAO,MAAM,EAAmB,OAAO,EAEjE,IAD0B,EAAsB,GAAuB,GAAS,EAAS,CACnC,gBAEtD,IAD2B,EAAsB,GAAQ,GAAS,EAAS,CACnC;AAU1C,MAAI,CAAC,EAAgB,GAAgB,EAAS,uBAAuB,CAAC,IAAI,EAAgB,GAA+B,EAAS,uBAAuB,CAAC,IAAI,EAAkB,GAAgB,GAAS,EAAS,KAAK,WACrN,QAAO;GACe;GACpB,QAAQ;GACT;;AAGL,QAAO,EACG,WACT"}
|
package/dist/index264.js
CHANGED
|
@@ -1,21 +1,39 @@
|
|
|
1
|
-
import { Metadata as e
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
var
|
|
8
|
-
if (
|
|
9
|
-
l =
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
1
|
+
import { Metadata as e } from "./index249.js";
|
|
2
|
+
import t from "./index258.js";
|
|
3
|
+
import n from "./index263.js";
|
|
4
|
+
//#region ../../node_modules/libphonenumber-js/es6/helpers/extractCountryCallingCode.js
|
|
5
|
+
function r(r, i, a, o, s) {
|
|
6
|
+
if (!r) return {};
|
|
7
|
+
var c;
|
|
8
|
+
if (r[0] !== "+") {
|
|
9
|
+
var l = t(r, i || a, o, s);
|
|
10
|
+
if (l && l !== r) c = !0, r = "+" + l;
|
|
11
|
+
else {
|
|
12
|
+
if (i || a || o) {
|
|
13
|
+
var u = n(r, i, a, o, s), d = u.countryCallingCode, f = u.number;
|
|
14
|
+
if (d) return {
|
|
15
|
+
countryCallingCodeSource: "FROM_NUMBER_WITHOUT_PLUS_SIGN",
|
|
16
|
+
countryCallingCode: d,
|
|
17
|
+
number: f
|
|
18
|
+
};
|
|
19
|
+
}
|
|
20
|
+
return { number: r };
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
if (r[1] === "0") return {};
|
|
24
|
+
s = new e(s);
|
|
25
|
+
for (var p = 2; p - 1 <= 3 && p <= r.length;) {
|
|
26
|
+
var m = r.slice(1, p);
|
|
27
|
+
if (s.hasCallingCode(m)) return s.selectNumberingPlan(m), {
|
|
28
|
+
countryCallingCodeSource: c ? "FROM_NUMBER_WITH_IDD" : "FROM_NUMBER_WITH_PLUS_SIGN",
|
|
29
|
+
countryCallingCode: m,
|
|
30
|
+
number: r.slice(p)
|
|
14
31
|
};
|
|
32
|
+
p++;
|
|
15
33
|
}
|
|
16
|
-
return {
|
|
34
|
+
return {};
|
|
17
35
|
}
|
|
18
36
|
//#endregion
|
|
19
|
-
export {
|
|
37
|
+
export { r as default };
|
|
20
38
|
|
|
21
39
|
//# sourceMappingURL=index264.js.map
|