@rpcbase/ui 0.159.0 → 0.160.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/components/HoursPicker/index.d.ts +9 -6
- package/dist/components/HoursPicker/index.d.ts.map +1 -1
- package/dist/components/Select/index.d.ts.map +1 -1
- package/dist/index.js +32 -31
- package/dist/index100.js +105 -126
- package/dist/index100.js.map +1 -1
- package/dist/index101.js +24 -20
- package/dist/index101.js.map +1 -1
- package/dist/index102.js +8 -76
- package/dist/index102.js.map +1 -1
- package/dist/index103.js +4 -18
- package/dist/index103.js.map +1 -1
- package/dist/index104.js +5 -101
- package/dist/index104.js.map +1 -1
- package/dist/index105.js +5 -5
- package/dist/index105.js.map +1 -1
- package/dist/index106.js +466 -14
- package/dist/index106.js.map +1 -1
- package/dist/index107.js +186 -2
- package/dist/index107.js.map +1 -1
- package/dist/index108.js +107 -7
- package/dist/index108.js.map +1 -1
- package/dist/index109.js +241 -305
- package/dist/index109.js.map +1 -1
- package/dist/index110.js +9 -49
- package/dist/index110.js.map +1 -1
- package/dist/index111.js +42 -5
- package/dist/index111.js.map +1 -1
- package/dist/index112.js +4 -68
- package/dist/index112.js.map +1 -1
- package/dist/index113.js +52 -2
- package/dist/index113.js.map +1 -1
- package/dist/index114.js +4 -363
- package/dist/index114.js.map +1 -1
- package/dist/index115.js +4 -261
- package/dist/index115.js.map +1 -1
- package/dist/index116.js +15 -60
- package/dist/index116.js.map +1 -1
- package/dist/index117.js +5 -46
- package/dist/index117.js.map +1 -1
- package/dist/index118.js +7 -169
- package/dist/index118.js.map +1 -1
- package/dist/index119.js +16 -109
- package/dist/index119.js.map +1 -1
- package/dist/index120.js +4 -24
- package/dist/index120.js.map +1 -1
- package/dist/index121.js +5 -8
- package/dist/index121.js.map +1 -1
- package/dist/index122.js +5 -4
- package/dist/index122.js.map +1 -1
- package/dist/index123.js +5 -5
- package/dist/index123.js.map +1 -1
- package/dist/index124.js +3 -3
- package/dist/index124.js.map +1 -1
- package/dist/index125.js +4 -466
- package/dist/index125.js.map +1 -1
- package/dist/index126.js +6 -185
- package/dist/index126.js.map +1 -1
- package/dist/index127.js +24 -107
- package/dist/index127.js.map +1 -1
- package/dist/index128.js +6 -262
- package/dist/index128.js.map +1 -1
- package/dist/index129.js +4 -9
- package/dist/index129.js.map +1 -1
- package/dist/index130.js +6 -42
- package/dist/index130.js.map +1 -1
- package/dist/index131.js +5 -4
- package/dist/index131.js.map +1 -1
- package/dist/index132.js +5 -52
- package/dist/index132.js.map +1 -1
- package/dist/index133.js +5 -4
- package/dist/index133.js.map +1 -1
- package/dist/index134.js +3 -3
- package/dist/index134.js.map +1 -1
- package/dist/index135.js +6 -13
- package/dist/index135.js.map +1 -1
- package/dist/index136.js +4 -4
- package/dist/index136.js.map +1 -1
- package/dist/index137.js +4 -7
- package/dist/index137.js.map +1 -1
- package/dist/index138.js +4 -16
- package/dist/index138.js.map +1 -1
- package/dist/index139.js +6 -4
- package/dist/index139.js.map +1 -1
- package/dist/index140.js +145 -4
- package/dist/index140.js.map +1 -1
- package/dist/index141.js +39 -5
- package/dist/index141.js.map +1 -1
- package/dist/index142.js +4 -5
- package/dist/index142.js.map +1 -1
- package/dist/index143.js +7 -4
- package/dist/index143.js.map +1 -1
- package/dist/index144.js +13 -4
- package/dist/index144.js.map +1 -1
- package/dist/index145.js +13 -6
- package/dist/index145.js.map +1 -1
- package/dist/index146.js +7 -24
- package/dist/index146.js.map +1 -1
- package/dist/index147.js +31 -6
- package/dist/index147.js.map +1 -1
- package/dist/index148.js +10 -4
- package/dist/index148.js.map +1 -1
- package/dist/index149.js +10 -6
- package/dist/index149.js.map +1 -1
- package/dist/index150.js +8 -5
- package/dist/index150.js.map +1 -1
- package/dist/index151.js +13 -4
- package/dist/index151.js.map +1 -1
- package/dist/index152.js +101 -5
- package/dist/index152.js.map +1 -1
- package/dist/index153.js +20 -5
- package/dist/index153.js.map +1 -1
- package/dist/index154.js +53 -8
- package/dist/index154.js.map +1 -1
- package/dist/index155.js +72 -5
- package/dist/index155.js.map +1 -1
- package/dist/index156.js +9 -4
- package/dist/index156.js.map +1 -1
- package/dist/index157.js +20 -4
- package/dist/index157.js.map +1 -1
- package/dist/index158.js +16 -6
- package/dist/index158.js.map +1 -1
- package/dist/index159.js +23 -145
- package/dist/index159.js.map +1 -1
- package/dist/index160.js +6 -39
- package/dist/index160.js.map +1 -1
- package/dist/index161.js +5 -4
- package/dist/index161.js.map +1 -1
- package/dist/index162.js +23 -7
- package/dist/index162.js.map +1 -1
- package/dist/index163.js +35 -14
- package/dist/index163.js.map +1 -1
- package/dist/index164.js +16 -14
- package/dist/index164.js.map +1 -1
- package/dist/index165.js +6 -7
- package/dist/index165.js.map +1 -1
- package/dist/index166.js +4 -31
- package/dist/index166.js.map +1 -1
- package/dist/index167.js +4 -10
- package/dist/index167.js.map +1 -1
- package/dist/index168.js +4 -10
- package/dist/index168.js.map +1 -1
- package/dist/index169.js +4 -8
- package/dist/index169.js.map +1 -1
- package/dist/index170.js +3 -13
- package/dist/index170.js.map +1 -1
- package/dist/index171.js +6 -101
- package/dist/index171.js.map +1 -1
- package/dist/index172.js +24 -20
- package/dist/index172.js.map +1 -1
- package/dist/index173.js +7 -53
- package/dist/index173.js.map +1 -1
- package/dist/index174.js +6 -72
- package/dist/index174.js.map +1 -1
- package/dist/index175.js +5 -9
- package/dist/index175.js.map +1 -1
- package/dist/index176.js +3 -20
- package/dist/index176.js.map +1 -1
- package/dist/index177.js +3 -16
- package/dist/index177.js.map +1 -1
- package/dist/index178.js +4 -23
- package/dist/index178.js.map +1 -1
- package/dist/index179.js +3 -6
- package/dist/index179.js.map +1 -1
- package/dist/index18.js +475 -465
- package/dist/index18.js.map +1 -1
- package/dist/index180.js +4 -5
- package/dist/index180.js.map +1 -1
- package/dist/index181.js +3 -23
- package/dist/index181.js.map +1 -1
- package/dist/index182.js +4 -35
- package/dist/index182.js.map +1 -1
- package/dist/index183.js +4 -16
- package/dist/index183.js.map +1 -1
- package/dist/index184.js +3 -6
- package/dist/index184.js.map +1 -1
- package/dist/index185.js +33 -4
- package/dist/index185.js.map +1 -1
- package/dist/index186.js +249 -4
- package/dist/index186.js.map +1 -1
- package/dist/index187.js +114 -4
- package/dist/index187.js.map +1 -1
- package/dist/index188.js +219 -4
- package/dist/index188.js.map +1 -1
- package/dist/index189.js +66 -3
- package/dist/index189.js.map +1 -1
- package/dist/index190.js +20 -6
- package/dist/index190.js.map +1 -1
- package/dist/index191.js +210 -24
- package/dist/index191.js.map +1 -1
- package/dist/index192.js +319 -7
- package/dist/index192.js.map +1 -1
- package/dist/index193.js +130 -6
- package/dist/index193.js.map +1 -1
- package/dist/index194.js +20 -5
- package/dist/index194.js.map +1 -1
- package/dist/index195.js +75 -3
- package/dist/index195.js.map +1 -1
- package/dist/index196.js +18 -3
- package/dist/index196.js.map +1 -1
- package/dist/index197.js +101 -4
- package/dist/index197.js.map +1 -1
- package/dist/index198.js +5 -4
- package/dist/index198.js.map +1 -1
- package/dist/index199.js +14 -4
- package/dist/index199.js.map +1 -1
- package/dist/index20.js +113 -105
- package/dist/index20.js.map +1 -1
- package/dist/index200.js +2 -4
- package/dist/index200.js.map +1 -1
- package/dist/index201.js +7 -3
- package/dist/index201.js.map +1 -1
- package/dist/index202.js +326 -3
- package/dist/index202.js.map +1 -1
- package/dist/index203.js +46 -602
- package/dist/index203.js.map +1 -1
- package/dist/index205.js +3 -3
- package/dist/index206.js +3 -3
- package/dist/index209.js +1 -1
- package/dist/index210.js +1 -1
- package/dist/index215.js +63 -60
- package/dist/index215.js.map +1 -1
- package/dist/index216.js +179 -47
- package/dist/index216.js.map +1 -1
- package/dist/index217.js +46 -39
- package/dist/index217.js.map +1 -1
- package/dist/index218.js +13 -100
- package/dist/index218.js.map +1 -1
- package/dist/index219.js +151 -94
- package/dist/index219.js.map +1 -1
- package/dist/index220.js +27 -96
- package/dist/index220.js.map +1 -1
- package/dist/index221.js +9 -13
- package/dist/index221.js.map +1 -1
- package/dist/index222.js +40 -147
- package/dist/index222.js.map +1 -1
- package/dist/index223.js +10 -29
- package/dist/index223.js.map +1 -1
- package/dist/index224.js +44 -9
- package/dist/index224.js.map +1 -1
- package/dist/index225.js +88 -40
- package/dist/index225.js.map +1 -1
- package/dist/index226.js +85 -10
- package/dist/index226.js.map +1 -1
- package/dist/index227.js +102 -41
- package/dist/index227.js.map +1 -1
- package/dist/index228.js +45 -88
- package/dist/index228.js.map +1 -1
- package/dist/index229.js +10 -85
- package/dist/index229.js.map +1 -1
- package/dist/index230.js +28 -96
- package/dist/index230.js.map +1 -1
- package/dist/index231.js +8 -52
- package/dist/index231.js.map +1 -1
- package/dist/index232.js +115 -10
- package/dist/index232.js.map +1 -1
- package/dist/index233.js +16 -36
- package/dist/index233.js.map +1 -1
- package/dist/index234.js +15 -8
- package/dist/index234.js.map +1 -1
- package/dist/index235.js +3 -116
- package/dist/index235.js.map +1 -1
- package/dist/index236.js +35 -16
- package/dist/index236.js.map +1 -1
- package/dist/index237.js +19 -14
- package/dist/index237.js.map +1 -1
- package/dist/index238.js +9 -3
- package/dist/index238.js.map +1 -1
- package/dist/index239.js +8 -36
- package/dist/index239.js.map +1 -1
- package/dist/index240.js +58 -20
- package/dist/index240.js.map +1 -1
- package/dist/index241.js +8 -9
- package/dist/index241.js.map +1 -1
- package/dist/index242.js +66 -8
- package/dist/index242.js.map +1 -1
- package/dist/index243.js +18 -18
- package/dist/index243.js.map +1 -1
- package/dist/index244.js +15 -27
- package/dist/index244.js.map +1 -1
- package/dist/index245.js +4 -15
- package/dist/index245.js.map +1 -1
- package/dist/index246.js +4 -57
- package/dist/index246.js.map +1 -1
- package/dist/index247.js +6 -8
- package/dist/index247.js.map +1 -1
- package/dist/index248.js +4 -66
- package/dist/index248.js.map +1 -1
- package/dist/index249.js +7 -19
- package/dist/index249.js.map +1 -1
- package/dist/index250.js +17 -16
- package/dist/index250.js.map +1 -1
- package/dist/index251.js +5 -5
- package/dist/index251.js.map +1 -1
- package/dist/index252.js +5 -5
- package/dist/index252.js.map +1 -1
- package/dist/index253.js +13 -6
- package/dist/index253.js.map +1 -1
- package/dist/index254.js +10 -4
- package/dist/index254.js.map +1 -1
- package/dist/index255.js +14 -7
- package/dist/index255.js.map +1 -1
- package/dist/index256.js +14 -17
- package/dist/index256.js.map +1 -1
- package/dist/index257.js +5 -5
- package/dist/index257.js.map +1 -1
- package/dist/index258.js +6 -5
- package/dist/index258.js.map +1 -1
- package/dist/index259.js +7 -13
- package/dist/index259.js.map +1 -1
- package/dist/index260.js +5 -9
- package/dist/index260.js.map +1 -1
- package/dist/index261.js +9 -14
- package/dist/index261.js.map +1 -1
- package/dist/index262.js +5 -14
- package/dist/index262.js.map +1 -1
- package/dist/index263.js +5 -5
- package/dist/index263.js.map +1 -1
- package/dist/index264.js +9 -6
- package/dist/index264.js.map +1 -1
- package/dist/index265.js +5 -7
- package/dist/index265.js.map +1 -1
- package/dist/index266.js +5 -6
- package/dist/index266.js.map +1 -1
- package/dist/index267.js +4 -9
- package/dist/index267.js.map +1 -1
- package/dist/index268.js +11 -5
- package/dist/index268.js.map +1 -1
- package/dist/index269.js +10 -5
- package/dist/index269.js.map +1 -1
- package/dist/index270.js +10 -9
- package/dist/index270.js.map +1 -1
- package/dist/index271.js +11 -5
- package/dist/index271.js.map +1 -1
- package/dist/index272.js +11 -5
- package/dist/index272.js.map +1 -1
- package/dist/index273.js +10 -4
- package/dist/index273.js.map +1 -1
- package/dist/index274.js +7 -11
- package/dist/index274.js.map +1 -1
- package/dist/index275.js +6 -10
- package/dist/index275.js.map +1 -1
- package/dist/index276.js +5 -10
- package/dist/index276.js.map +1 -1
- package/dist/index277.js +6 -11
- package/dist/index277.js.map +1 -1
- package/dist/index278.js +6 -10
- package/dist/index278.js.map +1 -1
- package/dist/index279.js +6 -10
- package/dist/index279.js.map +1 -1
- package/dist/index280.js +55 -7
- package/dist/index280.js.map +1 -1
- package/dist/index281.js +19 -6
- package/dist/index281.js.map +1 -1
- package/dist/index282.js +28 -5
- package/dist/index282.js.map +1 -1
- package/dist/index283.js +16 -6
- package/dist/index283.js.map +1 -1
- package/dist/index284.js +23 -7
- package/dist/index284.js.map +1 -1
- package/dist/index285.js +16 -6
- package/dist/index285.js.map +1 -1
- package/dist/index286.js +7 -55
- package/dist/index286.js.map +1 -1
- package/dist/index287.js +10 -23
- package/dist/index287.js.map +1 -1
- package/dist/index288.js +9 -15
- package/dist/index288.js.map +1 -1
- package/dist/index289.js +21 -7
- package/dist/index289.js.map +1 -1
- package/dist/index29.js +1 -1
- package/dist/index290.js +10 -10
- package/dist/index290.js.map +1 -1
- package/dist/index291.js +9 -10
- package/dist/index291.js.map +1 -1
- package/dist/index292.js +9 -21
- package/dist/index292.js.map +1 -1
- package/dist/index293.js +4 -10
- package/dist/index293.js.map +1 -1
- package/dist/index294.js +5 -9
- package/dist/index294.js.map +1 -1
- package/dist/index295.js +16 -9
- package/dist/index295.js.map +1 -1
- package/dist/index296.js +9 -4
- package/dist/index296.js.map +1 -1
- package/dist/index297.js +18 -5
- package/dist/index297.js.map +1 -1
- package/dist/index298.js +15 -16
- package/dist/index298.js.map +1 -1
- package/dist/index299.js +12 -9
- package/dist/index299.js.map +1 -1
- package/dist/index30.js +14 -14
- package/dist/index300.js +29 -18
- package/dist/index300.js.map +1 -1
- package/dist/index301.js +12 -15
- package/dist/index301.js.map +1 -1
- package/dist/index302.js +25 -12
- package/dist/index302.js.map +1 -1
- package/dist/index303.js +5 -29
- package/dist/index303.js.map +1 -1
- package/dist/index304.js +62 -10
- package/dist/index304.js.map +1 -1
- package/dist/index305.js +48 -25
- package/dist/index305.js.map +1 -1
- package/dist/index306.js +39 -5
- package/dist/index306.js.map +1 -1
- package/dist/index307.js +98 -65
- package/dist/index307.js.map +1 -1
- package/dist/index308.js +94 -177
- package/dist/index308.js.map +1 -1
- package/dist/index309.js +98 -45
- package/dist/index309.js.map +1 -1
- package/dist/index31.js +3 -3
- package/dist/index310.js +2 -5
- package/dist/index310.js.map +1 -1
- package/dist/index311.js +2 -3
- package/dist/index311.js.map +1 -1
- package/dist/index312.js +5 -24
- package/dist/index312.js.map +1 -1
- package/dist/index313.js +3 -113
- package/dist/index313.js.map +1 -1
- package/dist/index314.js +23 -15
- package/dist/index314.js.map +1 -1
- package/dist/index315.js +107 -519
- package/dist/index315.js.map +1 -1
- package/dist/index316.js +14 -126
- package/dist/index316.js.map +1 -1
- package/dist/index317.js +516 -125
- package/dist/index317.js.map +1 -1
- package/dist/index318.js +128 -2
- package/dist/index318.js.map +1 -1
- package/dist/index319.js +134 -2
- package/dist/index319.js.map +1 -1
- package/dist/index32.js +2 -2
- package/dist/index320.js +1 -1
- package/dist/index325.js +2 -2
- package/dist/index326.js +1 -1
- package/dist/index33.js +1 -1
- package/dist/index336.js +2 -2
- package/dist/index339.js +1 -1
- package/dist/index34.js +1 -1
- package/dist/index340.js +2 -2
- package/dist/index342.js +1 -1
- package/dist/index343.js +1 -1
- package/dist/index344.js +1 -1
- package/dist/index345.js +1 -1
- package/dist/index35.js +1 -1
- package/dist/index355.js +11 -21
- package/dist/index355.js.map +1 -1
- package/dist/index356.js +26 -11
- package/dist/index356.js.map +1 -1
- package/dist/index357.js +4 -27
- package/dist/index357.js.map +1 -1
- package/dist/index358.js +22 -4
- package/dist/index358.js.map +1 -1
- package/dist/index36.js +1 -1
- package/dist/index39.js +2 -2
- package/dist/index40.js +24 -24
- package/dist/index42.js +1 -1
- package/dist/index50.js +2 -2
- package/dist/index55.js +1 -1
- package/dist/index56.js +1 -1
- package/dist/index59.js +1 -1
- package/dist/index66.js +4 -4
- package/dist/index68.js +1 -1
- package/dist/index77.js +1 -1
- package/dist/index78.js +53 -11
- package/dist/index78.js.map +1 -1
- package/dist/index79.js +1 -1
- package/dist/index80.js +2 -2
- package/dist/index81.js +2 -2
- package/dist/index82.js +12 -2
- package/dist/index82.js.map +1 -1
- package/dist/index83.js +2 -2
- package/dist/index84.js +2 -47
- package/dist/index84.js.map +1 -1
- package/dist/index85.js +41 -200
- package/dist/index85.js.map +1 -1
- package/dist/index86.js +204 -20
- package/dist/index86.js.map +1 -1
- package/dist/index87.js +22 -25
- package/dist/index87.js.map +1 -1
- package/dist/index88.js +23 -398
- package/dist/index88.js.map +1 -1
- package/dist/index89.js +392 -39
- package/dist/index89.js.map +1 -1
- package/dist/index90.js +44 -51
- package/dist/index90.js.map +1 -1
- package/dist/index91.js +605 -3
- package/dist/index91.js.map +1 -1
- package/dist/index92.js +5 -33
- package/dist/index92.js.map +1 -1
- package/dist/index93.js +65 -246
- package/dist/index93.js.map +1 -1
- package/dist/index94.js +2 -115
- package/dist/index94.js.map +1 -1
- package/dist/index95.js +359 -215
- package/dist/index95.js.map +1 -1
- package/dist/index96.js +257 -62
- package/dist/index96.js.map +1 -1
- package/dist/index97.js +58 -18
- package/dist/index97.js.map +1 -1
- package/dist/index98.js +44 -207
- package/dist/index98.js.map +1 -1
- package/dist/index99.js +159 -309
- package/dist/index99.js.map +1 -1
- package/package.json +1 -1
package/dist/index99.js
CHANGED
|
@@ -1,323 +1,173 @@
|
|
|
1
|
-
import
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
import "./index103.js";
|
|
11
|
-
class h extends y {
|
|
12
|
-
/** */
|
|
13
|
-
/** */
|
|
14
|
-
/** Single char for empty input */
|
|
15
|
-
/** Single char for filled input */
|
|
16
|
-
/** Show placeholder only when needed */
|
|
17
|
-
/** Enable characters overwriting */
|
|
18
|
-
/** */
|
|
19
|
-
/** */
|
|
20
|
-
/** */
|
|
21
|
-
constructor(e) {
|
|
22
|
-
super({
|
|
23
|
-
...h.DEFAULTS,
|
|
24
|
-
...e,
|
|
25
|
-
definitions: Object.assign({}, _.DEFAULT_DEFINITIONS, e?.definitions)
|
|
26
|
-
});
|
|
27
|
-
}
|
|
28
|
-
updateOptions(e) {
|
|
29
|
-
super.updateOptions(e);
|
|
30
|
-
}
|
|
31
|
-
_update(e) {
|
|
32
|
-
e.definitions = Object.assign({}, this.definitions, e.definitions), super._update(e), this._rebuildMask();
|
|
33
|
-
}
|
|
34
|
-
_rebuildMask() {
|
|
35
|
-
const e = this.definitions;
|
|
36
|
-
this._blocks = [], this.exposeBlock = void 0, this._stops = [], this._maskedBlocks = {};
|
|
37
|
-
const s = this.mask;
|
|
38
|
-
if (!s || !e) return;
|
|
39
|
-
let t = !1, l = !1;
|
|
40
|
-
for (let i = 0; i < s.length; ++i) {
|
|
41
|
-
if (this.blocks) {
|
|
42
|
-
const p = s.slice(i), g = Object.keys(this.blocks).filter((u) => p.indexOf(u) === 0);
|
|
43
|
-
g.sort((u, d) => d.length - u.length);
|
|
44
|
-
const c = g[0];
|
|
45
|
-
if (c) {
|
|
46
|
-
const {
|
|
47
|
-
expose: u,
|
|
48
|
-
repeat: d,
|
|
49
|
-
...E
|
|
50
|
-
} = b(this.blocks[c]), B = {
|
|
51
|
-
lazy: this.lazy,
|
|
52
|
-
eager: this.eager,
|
|
53
|
-
placeholderChar: this.placeholderChar,
|
|
54
|
-
displayChar: this.displayChar,
|
|
55
|
-
overwrite: this.overwrite,
|
|
56
|
-
autofix: this.autofix,
|
|
57
|
-
...E,
|
|
58
|
-
repeat: d,
|
|
59
|
-
parent: this
|
|
60
|
-
}, f = d != null ? new x.RepeatBlock(
|
|
61
|
-
B
|
|
62
|
-
/* TODO */
|
|
63
|
-
) : T(B);
|
|
64
|
-
f && (this._blocks.push(f), u && (this.exposeBlock = f), this._maskedBlocks[c] || (this._maskedBlocks[c] = []), this._maskedBlocks[c].push(this._blocks.length - 1)), i += c.length - 1;
|
|
65
|
-
continue;
|
|
66
|
-
}
|
|
67
|
-
}
|
|
68
|
-
let o = s[i], a = o in e;
|
|
69
|
-
if (o === h.STOP_CHAR) {
|
|
70
|
-
this._stops.push(this._blocks.length);
|
|
71
|
-
continue;
|
|
72
|
-
}
|
|
73
|
-
if (o === "{" || o === "}") {
|
|
74
|
-
t = !t;
|
|
75
|
-
continue;
|
|
76
|
-
}
|
|
77
|
-
if (o === "[" || o === "]") {
|
|
78
|
-
l = !l;
|
|
79
|
-
continue;
|
|
80
|
-
}
|
|
81
|
-
if (o === h.ESCAPE_CHAR) {
|
|
82
|
-
if (++i, o = s[i], !o) break;
|
|
83
|
-
a = !1;
|
|
84
|
-
}
|
|
85
|
-
const n = a ? new _({
|
|
86
|
-
isOptional: l,
|
|
87
|
-
lazy: this.lazy,
|
|
88
|
-
eager: this.eager,
|
|
89
|
-
placeholderChar: this.placeholderChar,
|
|
90
|
-
displayChar: this.displayChar,
|
|
91
|
-
...b(e[o]),
|
|
92
|
-
parent: this
|
|
93
|
-
}) : new C({
|
|
94
|
-
char: o,
|
|
95
|
-
eager: this.eager,
|
|
96
|
-
isUnmasking: t
|
|
97
|
-
});
|
|
98
|
-
this._blocks.push(n);
|
|
99
|
-
}
|
|
100
|
-
}
|
|
101
|
-
get state() {
|
|
102
|
-
return {
|
|
103
|
-
...super.state,
|
|
104
|
-
_blocks: this._blocks.map((e) => e.state)
|
|
1
|
+
import w from "./index219.js";
|
|
2
|
+
function p(r, e) {
|
|
3
|
+
var t = typeof Symbol < "u" && r[Symbol.iterator] || r["@@iterator"];
|
|
4
|
+
if (t) return (t = t.call(r)).next.bind(t);
|
|
5
|
+
if (Array.isArray(r) || (t = S(r)) || e) {
|
|
6
|
+
t && (r = t);
|
|
7
|
+
var n = 0;
|
|
8
|
+
return function() {
|
|
9
|
+
return n >= r.length ? { done: !0 } : { done: !1, value: r[n++] };
|
|
105
10
|
};
|
|
106
11
|
}
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
} = e;
|
|
116
|
-
this._blocks.forEach((l, i) => l.state = s[i]), super.state = t;
|
|
117
|
-
}
|
|
118
|
-
reset() {
|
|
119
|
-
super.reset(), this._blocks.forEach((e) => e.reset());
|
|
120
|
-
}
|
|
121
|
-
get isComplete() {
|
|
122
|
-
return this.exposeBlock ? this.exposeBlock.isComplete : this._blocks.every((e) => e.isComplete);
|
|
123
|
-
}
|
|
124
|
-
get isFilled() {
|
|
125
|
-
return this._blocks.every((e) => e.isFilled);
|
|
126
|
-
}
|
|
127
|
-
get isFixed() {
|
|
128
|
-
return this._blocks.every((e) => e.isFixed);
|
|
129
|
-
}
|
|
130
|
-
get isOptional() {
|
|
131
|
-
return this._blocks.every((e) => e.isOptional);
|
|
132
|
-
}
|
|
133
|
-
doCommit() {
|
|
134
|
-
this._blocks.forEach((e) => e.doCommit()), super.doCommit();
|
|
135
|
-
}
|
|
136
|
-
get unmaskedValue() {
|
|
137
|
-
return this.exposeBlock ? this.exposeBlock.unmaskedValue : this._blocks.reduce((e, s) => e += s.unmaskedValue, "");
|
|
138
|
-
}
|
|
139
|
-
set unmaskedValue(e) {
|
|
140
|
-
if (this.exposeBlock) {
|
|
141
|
-
const s = this.extractTail(this._blockStartPos(this._blocks.indexOf(this.exposeBlock)) + this.exposeBlock.displayValue.length);
|
|
142
|
-
this.exposeBlock.unmaskedValue = e, this.appendTail(s), this.doCommit();
|
|
143
|
-
} else super.unmaskedValue = e;
|
|
144
|
-
}
|
|
145
|
-
get value() {
|
|
146
|
-
return this.exposeBlock ? this.exposeBlock.value : (
|
|
147
|
-
// TODO return _value when not in change?
|
|
148
|
-
this._blocks.reduce((e, s) => e += s.value, "")
|
|
149
|
-
);
|
|
150
|
-
}
|
|
151
|
-
set value(e) {
|
|
152
|
-
if (this.exposeBlock) {
|
|
153
|
-
const s = this.extractTail(this._blockStartPos(this._blocks.indexOf(this.exposeBlock)) + this.exposeBlock.displayValue.length);
|
|
154
|
-
this.exposeBlock.value = e, this.appendTail(s), this.doCommit();
|
|
155
|
-
} else super.value = e;
|
|
156
|
-
}
|
|
157
|
-
get typedValue() {
|
|
158
|
-
return this.exposeBlock ? this.exposeBlock.typedValue : super.typedValue;
|
|
159
|
-
}
|
|
160
|
-
set typedValue(e) {
|
|
161
|
-
if (this.exposeBlock) {
|
|
162
|
-
const s = this.extractTail(this._blockStartPos(this._blocks.indexOf(this.exposeBlock)) + this.exposeBlock.displayValue.length);
|
|
163
|
-
this.exposeBlock.typedValue = e, this.appendTail(s), this.doCommit();
|
|
164
|
-
} else super.typedValue = e;
|
|
165
|
-
}
|
|
166
|
-
get displayValue() {
|
|
167
|
-
return this._blocks.reduce((e, s) => e += s.displayValue, "");
|
|
168
|
-
}
|
|
169
|
-
appendTail(e) {
|
|
170
|
-
return super.appendTail(e).aggregate(this._appendPlaceholder());
|
|
171
|
-
}
|
|
172
|
-
_appendEager() {
|
|
173
|
-
var e;
|
|
174
|
-
const s = new k();
|
|
175
|
-
let t = (e = this._mapPosToBlock(this.displayValue.length)) == null ? void 0 : e.index;
|
|
176
|
-
if (t == null) return s;
|
|
177
|
-
this._blocks[t].isFilled && ++t;
|
|
178
|
-
for (let l = t; l < this._blocks.length; ++l) {
|
|
179
|
-
const i = this._blocks[l]._appendEager();
|
|
180
|
-
if (!i.inserted) break;
|
|
181
|
-
s.aggregate(i);
|
|
182
|
-
}
|
|
183
|
-
return s;
|
|
184
|
-
}
|
|
185
|
-
_appendCharRaw(e, s) {
|
|
186
|
-
s === void 0 && (s = {});
|
|
187
|
-
const t = this._mapPosToBlock(this.displayValue.length), l = new k();
|
|
188
|
-
if (!t) return l;
|
|
189
|
-
for (let o = t.index, a; a = this._blocks[o]; ++o) {
|
|
190
|
-
var i;
|
|
191
|
-
const n = a._appendChar(e, {
|
|
192
|
-
...s,
|
|
193
|
-
_beforeTailState: (i = s._beforeTailState) == null || (i = i._blocks) == null ? void 0 : i[o]
|
|
194
|
-
});
|
|
195
|
-
if (l.aggregate(n), n.consumed) break;
|
|
196
|
-
}
|
|
197
|
-
return l;
|
|
198
|
-
}
|
|
199
|
-
extractTail(e, s) {
|
|
200
|
-
e === void 0 && (e = 0), s === void 0 && (s = this.displayValue.length);
|
|
201
|
-
const t = new m();
|
|
202
|
-
return e === s || this._forEachBlocksInRange(e, s, (l, i, o, a) => {
|
|
203
|
-
const n = l.extractTail(o, a);
|
|
204
|
-
n.stop = this._findStopBefore(i), n.from = this._blockStartPos(i), n instanceof m && (n.blockIndex = i), t.extend(n);
|
|
205
|
-
}), t;
|
|
206
|
-
}
|
|
207
|
-
extractInput(e, s, t) {
|
|
208
|
-
if (e === void 0 && (e = 0), s === void 0 && (s = this.displayValue.length), t === void 0 && (t = {}), e === s) return "";
|
|
209
|
-
let l = "";
|
|
210
|
-
return this._forEachBlocksInRange(e, s, (i, o, a, n) => {
|
|
211
|
-
l += i.extractInput(a, n, t);
|
|
212
|
-
}), l;
|
|
213
|
-
}
|
|
214
|
-
_findStopBefore(e) {
|
|
215
|
-
let s;
|
|
216
|
-
for (let t = 0; t < this._stops.length; ++t) {
|
|
217
|
-
const l = this._stops[t];
|
|
218
|
-
if (l <= e) s = l;
|
|
219
|
-
else break;
|
|
220
|
-
}
|
|
221
|
-
return s;
|
|
12
|
+
throw new TypeError(`Invalid attempt to iterate non-iterable instance.
|
|
13
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`);
|
|
14
|
+
}
|
|
15
|
+
function S(r, e) {
|
|
16
|
+
if (r) {
|
|
17
|
+
if (typeof r == "string") return v(r, e);
|
|
18
|
+
var t = {}.toString.call(r).slice(8, -1);
|
|
19
|
+
return t === "Object" && r.constructor && (t = r.constructor.name), t === "Map" || t === "Set" ? Array.from(r) : t === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? v(r, e) : void 0;
|
|
222
20
|
}
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
21
|
+
}
|
|
22
|
+
function v(r, e) {
|
|
23
|
+
(e == null || e > r.length) && (e = r.length);
|
|
24
|
+
for (var t = 0, n = Array(e); t < e; t++) n[t] = r[t];
|
|
25
|
+
return n;
|
|
26
|
+
}
|
|
27
|
+
function f(r) {
|
|
28
|
+
"@babel/helpers - typeof";
|
|
29
|
+
return f = typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? function(e) {
|
|
30
|
+
return typeof e;
|
|
31
|
+
} : function(e) {
|
|
32
|
+
return e && typeof Symbol == "function" && e.constructor === Symbol && e !== Symbol.prototype ? "symbol" : typeof e;
|
|
33
|
+
}, f(r);
|
|
34
|
+
}
|
|
35
|
+
function C(r, e) {
|
|
36
|
+
if (!(r instanceof e)) throw new TypeError("Cannot call a class as a function");
|
|
37
|
+
}
|
|
38
|
+
function P(r, e) {
|
|
39
|
+
for (var t = 0; t < e.length; t++) {
|
|
40
|
+
var n = e[t];
|
|
41
|
+
n.enumerable = n.enumerable || !1, n.configurable = !0, "value" in n && (n.writable = !0), Object.defineProperty(r, O(n.key), n);
|
|
236
42
|
}
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
43
|
+
}
|
|
44
|
+
function A(r, e, t) {
|
|
45
|
+
return e && P(r.prototype, e), Object.defineProperty(r, "prototype", { writable: !1 }), r;
|
|
46
|
+
}
|
|
47
|
+
function O(r) {
|
|
48
|
+
var e = M(r, "string");
|
|
49
|
+
return f(e) == "symbol" ? e : e + "";
|
|
50
|
+
}
|
|
51
|
+
function M(r, e) {
|
|
52
|
+
if (f(r) != "object" || !r) return r;
|
|
53
|
+
var t = r[Symbol.toPrimitive];
|
|
54
|
+
if (t !== void 0) {
|
|
55
|
+
var n = t.call(r, e);
|
|
56
|
+
if (f(n) != "object") return n;
|
|
57
|
+
throw new TypeError("@@toPrimitive must return a primitive value.");
|
|
58
|
+
}
|
|
59
|
+
return String(r);
|
|
60
|
+
}
|
|
61
|
+
var E = /* @__PURE__ */ (function() {
|
|
62
|
+
function r(e) {
|
|
63
|
+
C(this, r), this.matchTree = new w().parse(e);
|
|
64
|
+
}
|
|
65
|
+
return A(r, [{
|
|
66
|
+
key: "match",
|
|
67
|
+
value: function(t) {
|
|
68
|
+
var n = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {}, i = n.allowOverflow;
|
|
69
|
+
if (!t)
|
|
70
|
+
throw new Error("String is required");
|
|
71
|
+
var o = l(t.split(""), this.matchTree, !0);
|
|
72
|
+
if (o && o.match && delete o.matchedChars, !(o && o.overflow && !i))
|
|
73
|
+
return o;
|
|
247
74
|
}
|
|
248
|
-
}
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
75
|
+
}]);
|
|
76
|
+
})();
|
|
77
|
+
function l(r, e, t) {
|
|
78
|
+
if (typeof e == "string") {
|
|
79
|
+
var n = r.join("");
|
|
80
|
+
return e.indexOf(n) === 0 ? r.length === e.length ? {
|
|
81
|
+
match: !0,
|
|
82
|
+
matchedChars: r
|
|
83
|
+
} : {
|
|
84
|
+
partialMatch: !0
|
|
85
|
+
// matchedChars: characters
|
|
86
|
+
} : n.indexOf(e) === 0 ? t && r.length > e.length ? {
|
|
87
|
+
overflow: !0
|
|
88
|
+
} : {
|
|
89
|
+
match: !0,
|
|
90
|
+
matchedChars: r.slice(0, e.length)
|
|
91
|
+
} : void 0;
|
|
92
|
+
}
|
|
93
|
+
if (Array.isArray(e)) {
|
|
94
|
+
for (var i = r.slice(), o = 0; o < e.length; ) {
|
|
95
|
+
var s = e[o], a = l(i, s, t && o === e.length - 1);
|
|
96
|
+
if (a) {
|
|
97
|
+
if (a.overflow)
|
|
98
|
+
return a;
|
|
99
|
+
if (a.match) {
|
|
100
|
+
if (i = i.slice(a.matchedChars.length), i.length === 0)
|
|
101
|
+
return o === e.length - 1 ? {
|
|
102
|
+
match: !0,
|
|
103
|
+
matchedChars: r
|
|
104
|
+
} : {
|
|
105
|
+
partialMatch: !0
|
|
106
|
+
// matchedChars: characters
|
|
107
|
+
};
|
|
108
|
+
} else {
|
|
109
|
+
if (a.partialMatch)
|
|
110
|
+
return {
|
|
111
|
+
partialMatch: !0
|
|
112
|
+
// matchedChars: characters
|
|
113
|
+
};
|
|
114
|
+
throw new Error(`Unsupported match result:
|
|
115
|
+
`.concat(JSON.stringify(a, null, 2)));
|
|
116
|
+
}
|
|
117
|
+
} else return;
|
|
118
|
+
o++;
|
|
262
119
|
}
|
|
120
|
+
return t ? {
|
|
121
|
+
overflow: !0
|
|
122
|
+
} : {
|
|
123
|
+
match: !0,
|
|
124
|
+
matchedChars: r.slice(0, r.length - i.length)
|
|
125
|
+
};
|
|
263
126
|
}
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
127
|
+
switch (e.op) {
|
|
128
|
+
case "|":
|
|
129
|
+
for (var c, d = p(e.args), h; !(h = d()).done; ) {
|
|
130
|
+
var g = h.value, u = l(r, g, t);
|
|
131
|
+
if (u) {
|
|
132
|
+
if (u.overflow)
|
|
133
|
+
return u;
|
|
134
|
+
if (u.match)
|
|
135
|
+
return {
|
|
136
|
+
match: !0,
|
|
137
|
+
matchedChars: u.matchedChars
|
|
138
|
+
};
|
|
139
|
+
if (u.partialMatch)
|
|
140
|
+
c = !0;
|
|
141
|
+
else
|
|
142
|
+
throw new Error(`Unsupported match result:
|
|
143
|
+
`.concat(JSON.stringify(u, null, 2)));
|
|
144
|
+
}
|
|
280
145
|
}
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
146
|
+
return c ? {
|
|
147
|
+
partialMatch: !0
|
|
148
|
+
// matchedChars: ...
|
|
149
|
+
} : void 0;
|
|
150
|
+
case "[]":
|
|
151
|
+
for (var b = p(e.args), m; !(m = b()).done; ) {
|
|
152
|
+
var y = m.value;
|
|
153
|
+
if (r[0] === y)
|
|
154
|
+
return r.length === 1 ? {
|
|
155
|
+
match: !0,
|
|
156
|
+
matchedChars: r
|
|
157
|
+
} : t ? {
|
|
158
|
+
overflow: !0
|
|
159
|
+
} : {
|
|
160
|
+
match: !0,
|
|
161
|
+
matchedChars: [y]
|
|
162
|
+
};
|
|
284
163
|
}
|
|
285
|
-
return
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
totalInputPositions(e, s) {
|
|
290
|
-
e === void 0 && (e = 0), s === void 0 && (s = this.displayValue.length);
|
|
291
|
-
let t = 0;
|
|
292
|
-
return this._forEachBlocksInRange(e, s, (l, i, o, a) => {
|
|
293
|
-
t += l.totalInputPositions(o, a);
|
|
294
|
-
}), t;
|
|
295
|
-
}
|
|
296
|
-
/** Get block by name */
|
|
297
|
-
maskedBlock(e) {
|
|
298
|
-
return this.maskedBlocks(e)[0];
|
|
299
|
-
}
|
|
300
|
-
/** Get all blocks by name */
|
|
301
|
-
maskedBlocks(e) {
|
|
302
|
-
const s = this._maskedBlocks[e];
|
|
303
|
-
return s ? s.map((t) => this._blocks[t]) : [];
|
|
304
|
-
}
|
|
305
|
-
pad(e) {
|
|
306
|
-
const s = new k();
|
|
307
|
-
return this._forEachBlocksInRange(0, this.displayValue.length, (t) => s.aggregate(t.pad(e))), s;
|
|
164
|
+
return;
|
|
165
|
+
/* istanbul ignore next */
|
|
166
|
+
default:
|
|
167
|
+
throw new Error("Unsupported instruction tree: ".concat(e));
|
|
308
168
|
}
|
|
309
169
|
}
|
|
310
|
-
h.DEFAULTS = {
|
|
311
|
-
...y.DEFAULTS,
|
|
312
|
-
lazy: !0,
|
|
313
|
-
placeholderChar: "_"
|
|
314
|
-
};
|
|
315
|
-
h.STOP_CHAR = "`";
|
|
316
|
-
h.ESCAPE_CHAR = "\\";
|
|
317
|
-
h.InputDefinition = _;
|
|
318
|
-
h.FixedDefinition = C;
|
|
319
|
-
x.MaskedPattern = h;
|
|
320
170
|
export {
|
|
321
|
-
|
|
171
|
+
E as default
|
|
322
172
|
};
|
|
323
173
|
//# sourceMappingURL=index99.js.map
|
package/dist/index99.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index99.js","sources":["../../../node_modules/imask/esm/masked/pattern.js"],"sourcesContent":["import ChangeDetails from '../core/change-details.js';\nimport IMask from '../core/holder.js';\nimport { DIRECTION } from '../core/utils.js';\nimport Masked from './base.js';\nimport createMask, { normalizeOpts } from './factory.js';\nimport ChunksTailDetails from './pattern/chunk-tail-details.js';\nimport PatternCursor from './pattern/cursor.js';\nimport PatternFixedDefinition from './pattern/fixed-definition.js';\nimport PatternInputDefinition from './pattern/input-definition.js';\nimport './regexp.js';\nimport '../core/continuous-tail-details.js';\n\n/** Pattern mask */\nclass MaskedPattern extends Masked {\n /** */\n\n /** */\n\n /** Single char for empty input */\n\n /** Single char for filled input */\n\n /** Show placeholder only when needed */\n\n /** Enable characters overwriting */\n\n /** */\n\n /** */\n\n /** */\n\n constructor(opts) {\n super({\n ...MaskedPattern.DEFAULTS,\n ...opts,\n definitions: Object.assign({}, PatternInputDefinition.DEFAULT_DEFINITIONS, opts == null ? void 0 : opts.definitions)\n });\n }\n updateOptions(opts) {\n super.updateOptions(opts);\n }\n _update(opts) {\n opts.definitions = Object.assign({}, this.definitions, opts.definitions);\n super._update(opts);\n this._rebuildMask();\n }\n _rebuildMask() {\n const defs = this.definitions;\n this._blocks = [];\n this.exposeBlock = undefined;\n this._stops = [];\n this._maskedBlocks = {};\n const pattern = this.mask;\n if (!pattern || !defs) return;\n let unmaskingBlock = false;\n let optionalBlock = false;\n for (let i = 0; i < pattern.length; ++i) {\n if (this.blocks) {\n const p = pattern.slice(i);\n const bNames = Object.keys(this.blocks).filter(bName => p.indexOf(bName) === 0);\n // order by key length\n bNames.sort((a, b) => b.length - a.length);\n // use block name with max length\n const bName = bNames[0];\n if (bName) {\n const {\n expose,\n repeat,\n ...bOpts\n } = normalizeOpts(this.blocks[bName]); // TODO type Opts<Arg & Extra>\n const blockOpts = {\n lazy: this.lazy,\n eager: this.eager,\n placeholderChar: this.placeholderChar,\n displayChar: this.displayChar,\n overwrite: this.overwrite,\n autofix: this.autofix,\n ...bOpts,\n repeat,\n parent: this\n };\n const maskedBlock = repeat != null ? new IMask.RepeatBlock(blockOpts /* TODO */) : createMask(blockOpts);\n if (maskedBlock) {\n this._blocks.push(maskedBlock);\n if (expose) this.exposeBlock = maskedBlock;\n\n // store block index\n if (!this._maskedBlocks[bName]) this._maskedBlocks[bName] = [];\n this._maskedBlocks[bName].push(this._blocks.length - 1);\n }\n i += bName.length - 1;\n continue;\n }\n }\n let char = pattern[i];\n let isInput = (char in defs);\n if (char === MaskedPattern.STOP_CHAR) {\n this._stops.push(this._blocks.length);\n continue;\n }\n if (char === '{' || char === '}') {\n unmaskingBlock = !unmaskingBlock;\n continue;\n }\n if (char === '[' || char === ']') {\n optionalBlock = !optionalBlock;\n continue;\n }\n if (char === MaskedPattern.ESCAPE_CHAR) {\n ++i;\n char = pattern[i];\n if (!char) break;\n isInput = false;\n }\n const def = isInput ? new PatternInputDefinition({\n isOptional: optionalBlock,\n lazy: this.lazy,\n eager: this.eager,\n placeholderChar: this.placeholderChar,\n displayChar: this.displayChar,\n ...normalizeOpts(defs[char]),\n parent: this\n }) : new PatternFixedDefinition({\n char,\n eager: this.eager,\n isUnmasking: unmaskingBlock\n });\n this._blocks.push(def);\n }\n }\n get state() {\n return {\n ...super.state,\n _blocks: this._blocks.map(b => b.state)\n };\n }\n set state(state) {\n if (!state) {\n this.reset();\n return;\n }\n const {\n _blocks,\n ...maskedState\n } = state;\n this._blocks.forEach((b, bi) => b.state = _blocks[bi]);\n super.state = maskedState;\n }\n reset() {\n super.reset();\n this._blocks.forEach(b => b.reset());\n }\n get isComplete() {\n return this.exposeBlock ? this.exposeBlock.isComplete : this._blocks.every(b => b.isComplete);\n }\n get isFilled() {\n return this._blocks.every(b => b.isFilled);\n }\n get isFixed() {\n return this._blocks.every(b => b.isFixed);\n }\n get isOptional() {\n return this._blocks.every(b => b.isOptional);\n }\n doCommit() {\n this._blocks.forEach(b => b.doCommit());\n super.doCommit();\n }\n get unmaskedValue() {\n return this.exposeBlock ? this.exposeBlock.unmaskedValue : this._blocks.reduce((str, b) => str += b.unmaskedValue, '');\n }\n set unmaskedValue(unmaskedValue) {\n if (this.exposeBlock) {\n const tail = this.extractTail(this._blockStartPos(this._blocks.indexOf(this.exposeBlock)) + this.exposeBlock.displayValue.length);\n this.exposeBlock.unmaskedValue = unmaskedValue;\n this.appendTail(tail);\n this.doCommit();\n } else super.unmaskedValue = unmaskedValue;\n }\n get value() {\n return this.exposeBlock ? this.exposeBlock.value :\n // TODO return _value when not in change?\n this._blocks.reduce((str, b) => str += b.value, '');\n }\n set value(value) {\n if (this.exposeBlock) {\n const tail = this.extractTail(this._blockStartPos(this._blocks.indexOf(this.exposeBlock)) + this.exposeBlock.displayValue.length);\n this.exposeBlock.value = value;\n this.appendTail(tail);\n this.doCommit();\n } else super.value = value;\n }\n get typedValue() {\n return this.exposeBlock ? this.exposeBlock.typedValue : super.typedValue;\n }\n set typedValue(value) {\n if (this.exposeBlock) {\n const tail = this.extractTail(this._blockStartPos(this._blocks.indexOf(this.exposeBlock)) + this.exposeBlock.displayValue.length);\n this.exposeBlock.typedValue = value;\n this.appendTail(tail);\n this.doCommit();\n } else super.typedValue = value;\n }\n get displayValue() {\n return this._blocks.reduce((str, b) => str += b.displayValue, '');\n }\n appendTail(tail) {\n return super.appendTail(tail).aggregate(this._appendPlaceholder());\n }\n _appendEager() {\n var _this$_mapPosToBlock;\n const details = new ChangeDetails();\n let startBlockIndex = (_this$_mapPosToBlock = this._mapPosToBlock(this.displayValue.length)) == null ? void 0 : _this$_mapPosToBlock.index;\n if (startBlockIndex == null) return details;\n\n // TODO test if it works for nested pattern masks\n if (this._blocks[startBlockIndex].isFilled) ++startBlockIndex;\n for (let bi = startBlockIndex; bi < this._blocks.length; ++bi) {\n const d = this._blocks[bi]._appendEager();\n if (!d.inserted) break;\n details.aggregate(d);\n }\n return details;\n }\n _appendCharRaw(ch, flags) {\n if (flags === void 0) {\n flags = {};\n }\n const blockIter = this._mapPosToBlock(this.displayValue.length);\n const details = new ChangeDetails();\n if (!blockIter) return details;\n for (let bi = blockIter.index, block; block = this._blocks[bi]; ++bi) {\n var _flags$_beforeTailSta;\n const blockDetails = block._appendChar(ch, {\n ...flags,\n _beforeTailState: (_flags$_beforeTailSta = flags._beforeTailState) == null || (_flags$_beforeTailSta = _flags$_beforeTailSta._blocks) == null ? void 0 : _flags$_beforeTailSta[bi]\n });\n details.aggregate(blockDetails);\n if (blockDetails.consumed) break; // go next char\n }\n return details;\n }\n extractTail(fromPos, toPos) {\n if (fromPos === void 0) {\n fromPos = 0;\n }\n if (toPos === void 0) {\n toPos = this.displayValue.length;\n }\n const chunkTail = new ChunksTailDetails();\n if (fromPos === toPos) return chunkTail;\n this._forEachBlocksInRange(fromPos, toPos, (b, bi, bFromPos, bToPos) => {\n const blockChunk = b.extractTail(bFromPos, bToPos);\n blockChunk.stop = this._findStopBefore(bi);\n blockChunk.from = this._blockStartPos(bi);\n if (blockChunk instanceof ChunksTailDetails) blockChunk.blockIndex = bi;\n chunkTail.extend(blockChunk);\n });\n return chunkTail;\n }\n extractInput(fromPos, toPos, flags) {\n if (fromPos === void 0) {\n fromPos = 0;\n }\n if (toPos === void 0) {\n toPos = this.displayValue.length;\n }\n if (flags === void 0) {\n flags = {};\n }\n if (fromPos === toPos) return '';\n let input = '';\n this._forEachBlocksInRange(fromPos, toPos, (b, _, fromPos, toPos) => {\n input += b.extractInput(fromPos, toPos, flags);\n });\n return input;\n }\n _findStopBefore(blockIndex) {\n let stopBefore;\n for (let si = 0; si < this._stops.length; ++si) {\n const stop = this._stops[si];\n if (stop <= blockIndex) stopBefore = stop;else break;\n }\n return stopBefore;\n }\n\n /** Appends placeholder depending on laziness */\n _appendPlaceholder(toBlockIndex) {\n const details = new ChangeDetails();\n if (this.lazy && toBlockIndex == null) return details;\n const startBlockIter = this._mapPosToBlock(this.displayValue.length);\n if (!startBlockIter) return details;\n const startBlockIndex = startBlockIter.index;\n const endBlockIndex = toBlockIndex != null ? toBlockIndex : this._blocks.length;\n this._blocks.slice(startBlockIndex, endBlockIndex).forEach(b => {\n if (!b.lazy || toBlockIndex != null) {\n var _blocks2;\n details.aggregate(b._appendPlaceholder((_blocks2 = b._blocks) == null ? void 0 : _blocks2.length));\n }\n });\n return details;\n }\n\n /** Finds block in pos */\n _mapPosToBlock(pos) {\n let accVal = '';\n for (let bi = 0; bi < this._blocks.length; ++bi) {\n const block = this._blocks[bi];\n const blockStartPos = accVal.length;\n accVal += block.displayValue;\n if (pos <= accVal.length) {\n return {\n index: bi,\n offset: pos - blockStartPos\n };\n }\n }\n }\n _blockStartPos(blockIndex) {\n return this._blocks.slice(0, blockIndex).reduce((pos, b) => pos += b.displayValue.length, 0);\n }\n _forEachBlocksInRange(fromPos, toPos, fn) {\n if (toPos === void 0) {\n toPos = this.displayValue.length;\n }\n const fromBlockIter = this._mapPosToBlock(fromPos);\n if (fromBlockIter) {\n const toBlockIter = this._mapPosToBlock(toPos);\n // process first block\n const isSameBlock = toBlockIter && fromBlockIter.index === toBlockIter.index;\n const fromBlockStartPos = fromBlockIter.offset;\n const fromBlockEndPos = toBlockIter && isSameBlock ? toBlockIter.offset : this._blocks[fromBlockIter.index].displayValue.length;\n fn(this._blocks[fromBlockIter.index], fromBlockIter.index, fromBlockStartPos, fromBlockEndPos);\n if (toBlockIter && !isSameBlock) {\n // process intermediate blocks\n for (let bi = fromBlockIter.index + 1; bi < toBlockIter.index; ++bi) {\n fn(this._blocks[bi], bi, 0, this._blocks[bi].displayValue.length);\n }\n\n // process last block\n fn(this._blocks[toBlockIter.index], toBlockIter.index, 0, toBlockIter.offset);\n }\n }\n }\n remove(fromPos, toPos) {\n if (fromPos === void 0) {\n fromPos = 0;\n }\n if (toPos === void 0) {\n toPos = this.displayValue.length;\n }\n const removeDetails = super.remove(fromPos, toPos);\n this._forEachBlocksInRange(fromPos, toPos, (b, _, bFromPos, bToPos) => {\n removeDetails.aggregate(b.remove(bFromPos, bToPos));\n });\n return removeDetails;\n }\n nearestInputPos(cursorPos, direction) {\n if (direction === void 0) {\n direction = DIRECTION.NONE;\n }\n if (!this._blocks.length) return 0;\n const cursor = new PatternCursor(this, cursorPos);\n if (direction === DIRECTION.NONE) {\n // -------------------------------------------------\n // NONE should only go out from fixed to the right!\n // -------------------------------------------------\n if (cursor.pushRightBeforeInput()) return cursor.pos;\n cursor.popState();\n if (cursor.pushLeftBeforeInput()) return cursor.pos;\n return this.displayValue.length;\n }\n\n // FORCE is only about a|* otherwise is 0\n if (direction === DIRECTION.LEFT || direction === DIRECTION.FORCE_LEFT) {\n // try to break fast when *|a\n if (direction === DIRECTION.LEFT) {\n cursor.pushRightBeforeFilled();\n if (cursor.ok && cursor.pos === cursorPos) return cursorPos;\n cursor.popState();\n }\n\n // forward flow\n cursor.pushLeftBeforeInput();\n cursor.pushLeftBeforeRequired();\n cursor.pushLeftBeforeFilled();\n\n // backward flow\n if (direction === DIRECTION.LEFT) {\n cursor.pushRightBeforeInput();\n cursor.pushRightBeforeRequired();\n if (cursor.ok && cursor.pos <= cursorPos) return cursor.pos;\n cursor.popState();\n if (cursor.ok && cursor.pos <= cursorPos) return cursor.pos;\n cursor.popState();\n }\n if (cursor.ok) return cursor.pos;\n if (direction === DIRECTION.FORCE_LEFT) return 0;\n cursor.popState();\n if (cursor.ok) return cursor.pos;\n cursor.popState();\n if (cursor.ok) return cursor.pos;\n return 0;\n }\n if (direction === DIRECTION.RIGHT || direction === DIRECTION.FORCE_RIGHT) {\n // forward flow\n cursor.pushRightBeforeInput();\n cursor.pushRightBeforeRequired();\n if (cursor.pushRightBeforeFilled()) return cursor.pos;\n if (direction === DIRECTION.FORCE_RIGHT) return this.displayValue.length;\n\n // backward flow\n cursor.popState();\n if (cursor.ok) return cursor.pos;\n cursor.popState();\n if (cursor.ok) return cursor.pos;\n return this.nearestInputPos(cursorPos, DIRECTION.LEFT);\n }\n return cursorPos;\n }\n totalInputPositions(fromPos, toPos) {\n if (fromPos === void 0) {\n fromPos = 0;\n }\n if (toPos === void 0) {\n toPos = this.displayValue.length;\n }\n let total = 0;\n this._forEachBlocksInRange(fromPos, toPos, (b, _, bFromPos, bToPos) => {\n total += b.totalInputPositions(bFromPos, bToPos);\n });\n return total;\n }\n\n /** Get block by name */\n maskedBlock(name) {\n return this.maskedBlocks(name)[0];\n }\n\n /** Get all blocks by name */\n maskedBlocks(name) {\n const indices = this._maskedBlocks[name];\n if (!indices) return [];\n return indices.map(gi => this._blocks[gi]);\n }\n pad(flags) {\n const details = new ChangeDetails();\n this._forEachBlocksInRange(0, this.displayValue.length, b => details.aggregate(b.pad(flags)));\n return details;\n }\n}\nMaskedPattern.DEFAULTS = {\n ...Masked.DEFAULTS,\n lazy: true,\n placeholderChar: '_'\n};\nMaskedPattern.STOP_CHAR = '`';\nMaskedPattern.ESCAPE_CHAR = '\\\\';\nMaskedPattern.InputDefinition = PatternInputDefinition;\nMaskedPattern.FixedDefinition = PatternFixedDefinition;\nIMask.MaskedPattern = MaskedPattern;\n\nexport { MaskedPattern as default };\n"],"names":["MaskedPattern","Masked","opts","PatternInputDefinition","defs","pattern","unmaskingBlock","optionalBlock","bNames","bName","a","b","expose","repeat","bOpts","normalizeOpts","blockOpts","maskedBlock","IMask","createMask","char","isInput","def","PatternFixedDefinition","state","_blocks","maskedState","bi","str","unmaskedValue","tail","value","_this$_mapPosToBlock","details","ChangeDetails","startBlockIndex","d","ch","flags","blockIter","block","_flags$_beforeTailSta","blockDetails","fromPos","toPos","chunkTail","ChunksTailDetails","bFromPos","bToPos","blockChunk","input","_","blockIndex","stopBefore","si","stop","toBlockIndex","startBlockIter","endBlockIndex","_blocks2","pos","accVal","blockStartPos","fn","fromBlockIter","toBlockIter","isSameBlock","fromBlockStartPos","fromBlockEndPos","removeDetails","cursorPos","direction","DIRECTION","cursor","PatternCursor","total","name","indices","gi"],"mappings":";;;;;;;;;;AAaA,MAAMA,UAAsBC,EAAO;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAmBjC,YAAYC,GAAM;AAChB,UAAM;AAAA,MACJ,GAAGF,EAAc;AAAA,MACjB,GAAGE;AAAA,MACH,aAAa,OAAO,OAAO,CAAA,GAAIC,EAAuB,qBAA6CD,GAAK,WAAW;AAAA,IACzH,CAAK;AAAA,EACH;AAAA,EACA,cAAcA,GAAM;AAClB,UAAM,cAAcA,CAAI;AAAA,EAC1B;AAAA,EACA,QAAQA,GAAM;AACZ,IAAAA,EAAK,cAAc,OAAO,OAAO,CAAA,GAAI,KAAK,aAAaA,EAAK,WAAW,GACvE,MAAM,QAAQA,CAAI,GAClB,KAAK,aAAY;AAAA,EACnB;AAAA,EACA,eAAe;AACb,UAAME,IAAO,KAAK;AAClB,SAAK,UAAU,CAAA,GACf,KAAK,cAAc,QACnB,KAAK,SAAS,CAAA,GACd,KAAK,gBAAgB,CAAA;AACrB,UAAMC,IAAU,KAAK;AACrB,QAAI,CAACA,KAAW,CAACD,EAAM;AACvB,QAAIE,IAAiB,IACjBC,IAAgB;AACpB,aAAS,IAAI,GAAG,IAAIF,EAAQ,QAAQ,EAAE,GAAG;AACvC,UAAI,KAAK,QAAQ;AACf,cAAM,IAAIA,EAAQ,MAAM,CAAC,GACnBG,IAAS,OAAO,KAAK,KAAK,MAAM,EAAE,OAAO,CAAAC,MAAS,EAAE,QAAQA,CAAK,MAAM,CAAC;AAE9E,QAAAD,EAAO,KAAK,CAACE,GAAGC,MAAMA,EAAE,SAASD,EAAE,MAAM;AAEzC,cAAMD,IAAQD,EAAO,CAAC;AACtB,YAAIC,GAAO;AACT,gBAAM;AAAA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AAIxC,GAAO;AACT,UAAML,IAAU,IAAIC,EAAa;AACjC,gBAAK,sBAAsB,GAAG,KAAK,aAAa,QAAQ,CAAAvB,MAAKsB,EAAQ,UAAUtB,EAAE,IAAI2B,CAAK,CAAC,CAAC,GACrFL;AAAA,EACT;AACF;AACAjC,EAAc,WAAW;AAAA,EACvB,GAAGC,EAAO;AAAA,EACV,MAAM;AAAA,EACN,iBAAiB;AACnB;AACAD,EAAc,YAAY;AAC1BA,EAAc,cAAc;AAC5BA,EAAc,kBAAkBG;AAChCH,EAAc,kBAAkBuB;AAChCL,EAAM,gBAAgBlB;","x_google_ignoreList":[0]}
|
|
1
|
+
{"version":3,"file":"index99.js","sources":["../../../node_modules/libphonenumber-js/es6/AsYouTypeFormatter.PatternMatcher.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; }\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nimport PatternParser from './AsYouTypeFormatter.PatternParser.js';\nvar PatternMatcher = /*#__PURE__*/function () {\n function PatternMatcher(pattern) {\n _classCallCheck(this, PatternMatcher);\n this.matchTree = new PatternParser().parse(pattern);\n }\n return _createClass(PatternMatcher, [{\n key: \"match\",\n value: function match(string) {\n var _ref = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {},\n allowOverflow = _ref.allowOverflow;\n if (!string) {\n throw new Error('String is required');\n }\n var result = _match(string.split(''), this.matchTree, true);\n if (result && result.match) {\n delete result.matchedChars;\n }\n if (result && result.overflow) {\n if (!allowOverflow) {\n return;\n }\n }\n return result;\n }\n }]);\n}();\n/**\r\n * Matches `characters` against a pattern compiled into a `tree`.\r\n * @param {string[]} characters\r\n * @param {Tree} tree — A pattern compiled into a `tree`. See the `*.d.ts` file for the description of the `tree` structure.\r\n * @param {boolean} last — Whether it's the last (rightmost) subtree on its level of the match tree.\r\n * @return {object} See the `*.d.ts` file for the description of the result object.\r\n */\nexport { PatternMatcher as default };\nfunction _match(characters, tree, last) {\n // If `tree` is a string, then `tree` is a single character.\n // That's because when a pattern is parsed, multi-character-string parts\n // of a pattern are compiled into arrays of single characters.\n // I still wrote this piece of code for a \"general\" hypothetical case\n // when `tree` could be a string of several characters, even though\n // such case is not possible with the current implementation.\n if (typeof tree === 'string') {\n var characterString = characters.join('');\n if (tree.indexOf(characterString) === 0) {\n // `tree` is always a single character.\n // If `tree.indexOf(characterString) === 0`\n // then `characters.length === tree.length`.\n /* istanbul ignore else */\n if (characters.length === tree.length) {\n return {\n match: true,\n matchedChars: characters\n };\n }\n // `tree` is always a single character.\n // If `tree.indexOf(characterString) === 0`\n // then `characters.length === tree.length`.\n /* istanbul ignore next */\n return {\n partialMatch: true\n // matchedChars: characters\n };\n }\n if (characterString.indexOf(tree) === 0) {\n if (last) {\n // The `else` path is not possible because `tree` is always a single character.\n // The `else` case for `characters.length > tree.length` would be\n // `characters.length <= tree.length` which means `characters.length <= 1`.\n // `characters` array can't be empty, so that means `characters === [tree]`,\n // which would also mean `tree.indexOf(characterString) === 0` and that'd mean\n // that the `if (tree.indexOf(characterString) === 0)` condition before this\n // `if` condition would be entered, and returned from there, not reaching this code.\n /* istanbul ignore else */\n if (characters.length > tree.length) {\n return {\n overflow: true\n };\n }\n }\n return {\n match: true,\n matchedChars: characters.slice(0, tree.length)\n };\n }\n return;\n }\n if (Array.isArray(tree)) {\n var restCharacters = characters.slice();\n var i = 0;\n while (i < tree.length) {\n var subtree = tree[i];\n var result = _match(restCharacters, subtree, last && i === tree.length - 1);\n if (!result) {\n return;\n } else if (result.overflow) {\n return result;\n } else if (result.match) {\n // Continue with the next subtree with the rest of the characters.\n restCharacters = restCharacters.slice(result.matchedChars.length);\n if (restCharacters.length === 0) {\n if (i === tree.length - 1) {\n return {\n match: true,\n matchedChars: characters\n };\n } else {\n return {\n partialMatch: true\n // matchedChars: characters\n };\n }\n }\n } else {\n /* istanbul ignore else */\n if (result.partialMatch) {\n return {\n partialMatch: true\n // matchedChars: characters\n };\n } else {\n throw new Error(\"Unsupported match result:\\n\".concat(JSON.stringify(result, null, 2)));\n }\n }\n i++;\n }\n // If `last` then overflow has already been checked\n // by the last element of the `tree` array.\n /* istanbul ignore if */\n if (last) {\n return {\n overflow: true\n };\n }\n return {\n match: true,\n matchedChars: characters.slice(0, characters.length - restCharacters.length)\n };\n }\n switch (tree.op) {\n case '|':\n var partialMatch;\n for (var _iterator = _createForOfIteratorHelperLoose(tree.args), _step; !(_step = _iterator()).done;) {\n var branch = _step.value;\n var _result = _match(characters, branch, last);\n if (_result) {\n if (_result.overflow) {\n return _result;\n } else if (_result.match) {\n return {\n match: true,\n matchedChars: _result.matchedChars\n };\n } else {\n /* istanbul ignore else */\n if (_result.partialMatch) {\n partialMatch = true;\n } else {\n throw new Error(\"Unsupported match result:\\n\".concat(JSON.stringify(_result, null, 2)));\n }\n }\n }\n }\n if (partialMatch) {\n return {\n partialMatch: true\n // matchedChars: ...\n };\n }\n // Not even a partial match.\n return;\n case '[]':\n for (var _iterator2 = _createForOfIteratorHelperLoose(tree.args), _step2; !(_step2 = _iterator2()).done;) {\n var _char = _step2.value;\n if (characters[0] === _char) {\n if (characters.length === 1) {\n return {\n match: true,\n matchedChars: characters\n };\n }\n if (last) {\n return {\n overflow: true\n };\n }\n return {\n match: true,\n matchedChars: [_char]\n };\n }\n }\n // No character matches.\n return;\n\n /* istanbul ignore next */\n default:\n throw new Error(\"Unsupported instruction tree: \".concat(tree));\n }\n}\n//# sourceMappingURL=AsYouTypeFormatter.PatternMatcher.js.map"],"names":["_createForOfIteratorHelperLoose","_unsupportedIterableToArray","o","a","_arrayLikeToArray","e","_typeof","_classCallCheck","n","_defineProperties","r","_toPropertyKey","_createClass","t","i","_toPrimitive","PatternMatcher","pattern","PatternParser","string","_ref","allowOverflow","result","_match","characters","tree","last","characterString","restCharacters","subtree","partialMatch","_iterator","_step","branch","_result","_iterator2","_step2","_char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