@rpcbase/ui 0.202.0 → 0.203.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.
Files changed (641) hide show
  1. package/dist/index.js +25 -73
  2. package/dist/index10.js +18 -28
  3. package/dist/index10.js.map +1 -1
  4. package/dist/index100.js +8 -8
  5. package/dist/index100.js.map +1 -1
  6. package/dist/index101.js +8 -7
  7. package/dist/index101.js.map +1 -1
  8. package/dist/index102.js +14 -7
  9. package/dist/index102.js.map +1 -1
  10. package/dist/index103.js +9 -9
  11. package/dist/index103.js.map +1 -1
  12. package/dist/index104.js +14 -148
  13. package/dist/index104.js.map +1 -1
  14. package/dist/index105.js +21 -43
  15. package/dist/index105.js.map +1 -1
  16. package/dist/index106.js +27 -7
  17. package/dist/index106.js.map +1 -1
  18. package/dist/index107.js +8 -10
  19. package/dist/index107.js.map +1 -1
  20. package/dist/index108.js +8 -16
  21. package/dist/index108.js.map +1 -1
  22. package/dist/index109.js +9 -16
  23. package/dist/index109.js.map +1 -1
  24. package/dist/index11.js +1674 -41
  25. package/dist/index11.js.map +1 -1
  26. package/dist/index110.js +9 -10
  27. package/dist/index110.js.map +1 -1
  28. package/dist/index111.js +8 -34
  29. package/dist/index111.js.map +1 -1
  30. package/dist/index112.js +8 -13
  31. package/dist/index112.js.map +1 -1
  32. package/dist/index113.js +11 -13
  33. package/dist/index113.js.map +1 -1
  34. package/dist/index114.js +10 -11
  35. package/dist/index114.js.map +1 -1
  36. package/dist/index115.js +37 -16
  37. package/dist/index115.js.map +1 -1
  38. package/dist/index116.js +10 -104
  39. package/dist/index116.js.map +1 -1
  40. package/dist/index117.js +9 -23
  41. package/dist/index117.js.map +1 -1
  42. package/dist/index118.js +10 -56
  43. package/dist/index118.js.map +1 -1
  44. package/dist/index119.js +12 -75
  45. package/dist/index119.js.map +1 -1
  46. package/dist/index12.js +10 -470
  47. package/dist/index12.js.map +1 -1
  48. package/dist/index120.js +8 -12
  49. package/dist/index120.js.map +1 -1
  50. package/dist/index121.js +9 -23
  51. package/dist/index121.js.map +1 -1
  52. package/dist/index122.js +8 -19
  53. package/dist/index122.js.map +1 -1
  54. package/dist/index123.js +8 -26
  55. package/dist/index123.js.map +1 -1
  56. package/dist/index124.js +9 -9
  57. package/dist/index124.js.map +1 -1
  58. package/dist/index125.js +8 -8
  59. package/dist/index125.js.map +1 -1
  60. package/dist/index126.js +9 -27
  61. package/dist/index126.js.map +1 -1
  62. package/dist/index127.js +11 -38
  63. package/dist/index127.js.map +1 -1
  64. package/dist/index128.js +60 -19
  65. package/dist/index128.js.map +1 -1
  66. package/dist/index129.js +9 -9
  67. package/dist/index129.js.map +1 -1
  68. package/dist/index13.js +22 -140
  69. package/dist/index13.js.map +1 -1
  70. package/dist/index130.js +23 -8
  71. package/dist/index130.js.map +1 -1
  72. package/dist/index131.js +22 -7
  73. package/dist/index131.js.map +1 -1
  74. package/dist/index132.js +37 -7
  75. package/dist/index132.js.map +1 -1
  76. package/dist/index133.js +8 -7
  77. package/dist/index133.js.map +1 -1
  78. package/dist/index134.js +11 -6
  79. package/dist/index134.js.map +1 -1
  80. package/dist/index135.js +17 -9
  81. package/dist/index135.js.map +1 -1
  82. package/dist/index136.js +14 -27
  83. package/dist/index136.js.map +1 -1
  84. package/dist/index137.js +9 -10
  85. package/dist/index137.js.map +1 -1
  86. package/dist/index138.js +8 -9
  87. package/dist/index138.js.map +1 -1
  88. package/dist/index139.js +8 -8
  89. package/dist/index139.js.map +1 -1
  90. package/dist/index14.js +194 -78
  91. package/dist/index14.js.map +1 -1
  92. package/dist/index140.js +8 -6
  93. package/dist/index140.js.map +1 -1
  94. package/dist/index141.js +8 -6
  95. package/dist/index141.js.map +1 -1
  96. package/dist/index142.js +7 -7
  97. package/dist/index142.js.map +1 -1
  98. package/dist/index143.js +9 -6
  99. package/dist/index143.js.map +1 -1
  100. package/dist/index144.js +24 -8
  101. package/dist/index144.js.map +1 -1
  102. package/dist/index145.js +11 -6
  103. package/dist/index145.js.map +1 -1
  104. package/dist/index146.js +10 -6
  105. package/dist/index146.js.map +1 -1
  106. package/dist/index147.js +9 -6
  107. package/dist/index147.js.map +1 -1
  108. package/dist/index148.js +9 -8
  109. package/dist/index148.js.map +1 -1
  110. package/dist/index149.js +7 -10
  111. package/dist/index149.js.map +1 -1
  112. package/dist/index15.js +33 -874
  113. package/dist/index15.js.map +1 -1
  114. package/dist/index150.js +7 -8
  115. package/dist/index150.js.map +1 -1
  116. package/dist/index151.js +9 -50
  117. package/dist/index151.js.map +1 -1
  118. package/dist/index152.js +8 -50
  119. package/dist/index152.js.map +1 -1
  120. package/dist/index153.js +9 -209
  121. package/dist/index153.js.map +1 -1
  122. package/dist/index154.js +8 -25
  123. package/dist/index154.js.map +1 -1
  124. package/dist/index155.js +7 -27
  125. package/dist/index155.js.map +1 -1
  126. package/dist/index156.js +8 -403
  127. package/dist/index156.js.map +1 -1
  128. package/dist/index157.js +32 -609
  129. package/dist/index157.js.map +1 -1
  130. package/dist/index158.js +35 -19
  131. package/dist/index158.js.map +1 -1
  132. package/dist/index159.js +18 -8
  133. package/dist/index159.js.map +1 -1
  134. package/dist/index16.js +57 -23
  135. package/dist/index16.js.map +1 -1
  136. package/dist/index160.js +14 -8
  137. package/dist/index160.js.map +1 -1
  138. package/dist/index161.js +12 -61
  139. package/dist/index161.js.map +1 -1
  140. package/dist/index162.js +19 -69
  141. package/dist/index162.js.map +1 -1
  142. package/dist/index163.js +89 -9
  143. package/dist/index163.js.map +1 -1
  144. package/dist/index164.js +50 -7
  145. package/dist/index164.js.map +1 -1
  146. package/dist/index165.js +20 -10
  147. package/dist/index165.js.map +1 -1
  148. package/dist/index166.js +11 -20
  149. package/dist/index166.js.map +1 -1
  150. package/dist/index167.js +13 -8
  151. package/dist/index167.js.map +1 -1
  152. package/dist/index168.js +8 -8
  153. package/dist/index168.js.map +1 -1
  154. package/dist/index169.js +25 -16
  155. package/dist/index169.js.map +1 -1
  156. package/dist/index17.js +9 -20
  157. package/dist/index17.js.map +1 -1
  158. package/dist/index170.js +10 -13
  159. package/dist/index170.js.map +1 -1
  160. package/dist/index171.js +9 -17
  161. package/dist/index171.js.map +1 -1
  162. package/dist/index172.js +9 -17
  163. package/dist/index172.js.map +1 -1
  164. package/dist/index173.js +7 -8
  165. package/dist/index173.js.map +1 -1
  166. package/dist/index174.js +9 -9
  167. package/dist/index174.js.map +1 -1
  168. package/dist/index175.js +70 -10
  169. package/dist/index175.js.map +1 -1
  170. package/dist/index176.js +20 -9
  171. package/dist/index176.js.map +1 -1
  172. package/dist/index177.js +15 -12
  173. package/dist/index177.js.map +1 -1
  174. package/dist/index178.js +12 -8
  175. package/dist/index178.js.map +1 -1
  176. package/dist/index179.js +23 -8
  177. package/dist/index179.js.map +1 -1
  178. package/dist/index18.js +27 -460
  179. package/dist/index18.js.map +1 -1
  180. package/dist/index180.js +20 -12
  181. package/dist/index180.js.map +1 -1
  182. package/dist/index181.js +58 -8
  183. package/dist/index181.js.map +1 -1
  184. package/dist/index182.js +13 -8
  185. package/dist/index182.js.map +1 -1
  186. package/dist/index183.js +9 -7
  187. package/dist/index183.js.map +1 -1
  188. package/dist/index184.js +29 -14
  189. package/dist/index184.js.map +1 -1
  190. package/dist/index185.js +29 -13
  191. package/dist/index185.js.map +1 -1
  192. package/dist/index186.js +16 -13
  193. package/dist/index186.js.map +1 -1
  194. package/dist/index187.js +16 -14
  195. package/dist/index187.js.map +1 -1
  196. package/dist/index188.js +9 -14
  197. package/dist/index188.js.map +1 -1
  198. package/dist/index189.js +26 -13
  199. package/dist/index189.js.map +1 -1
  200. package/dist/index19.js +65 -666
  201. package/dist/index19.js.map +1 -1
  202. package/dist/index190.js +388 -10
  203. package/dist/index190.js.map +1 -1
  204. package/dist/index191.js +499 -10
  205. package/dist/index191.js.map +1 -1
  206. package/dist/index192.js +134 -9
  207. package/dist/index192.js.map +1 -1
  208. package/dist/index193.js +55 -9
  209. package/dist/index193.js.map +1 -1
  210. package/dist/index194.js +80 -10
  211. package/dist/index194.js.map +1 -1
  212. package/dist/index195.js +902 -9
  213. package/dist/index195.js.map +1 -1
  214. package/dist/index196.js +22 -58
  215. package/dist/index196.js.map +1 -1
  216. package/dist/index197.js +452 -12
  217. package/dist/index197.js.map +1 -1
  218. package/dist/index198.js +7 -22
  219. package/dist/index198.js.map +1 -1
  220. package/dist/index199.js +60 -32
  221. package/dist/index199.js.map +1 -1
  222. package/dist/index2.js +10 -8
  223. package/dist/index20.js +43 -469
  224. package/dist/index20.js.map +1 -1
  225. package/dist/index200.js +63 -15
  226. package/dist/index200.js.map +1 -1
  227. package/dist/index201.js +11 -28
  228. package/dist/index201.js.map +1 -1
  229. package/dist/index202.js +19 -8
  230. package/dist/index202.js.map +1 -1
  231. package/dist/index203.js +148 -20
  232. package/dist/index203.js.map +1 -1
  233. package/dist/index204.js +7 -11
  234. package/dist/index204.js.map +1 -1
  235. package/dist/index205.js +13 -13
  236. package/dist/index205.js.map +1 -1
  237. package/dist/index206.js +107 -13
  238. package/dist/index206.js.map +1 -1
  239. package/dist/index207.js +359 -23
  240. package/dist/index207.js.map +1 -1
  241. package/dist/index208.js +99 -14
  242. package/dist/index208.js.map +1 -1
  243. package/dist/index209.js +329 -12
  244. package/dist/index209.js.map +1 -1
  245. package/dist/index21.js +12 -266
  246. package/dist/index21.js.map +1 -1
  247. package/dist/index210.js +213 -12
  248. package/dist/index210.js.map +1 -1
  249. package/dist/index211.js +22 -8
  250. package/dist/index211.js.map +1 -1
  251. package/dist/index212.js +30 -8
  252. package/dist/index212.js.map +1 -1
  253. package/dist/index213.js +189 -18
  254. package/dist/index213.js.map +1 -1
  255. package/dist/index214.js +21 -13
  256. package/dist/index214.js.map +1 -1
  257. package/dist/index215.js +46 -21
  258. package/dist/index215.js.map +1 -1
  259. package/dist/index216.js +12 -18
  260. package/dist/index216.js.map +1 -1
  261. package/dist/index217.js +28 -16
  262. package/dist/index217.js.map +1 -1
  263. package/dist/index218.js +47 -8
  264. package/dist/index218.js.map +1 -1
  265. package/dist/index219.js +19 -70
  266. package/dist/index219.js.map +1 -1
  267. package/dist/index22.js +16 -8
  268. package/dist/index22.js.map +1 -1
  269. package/dist/index220.js +6 -5
  270. package/dist/index220.js.map +1 -1
  271. package/dist/index221.js +8 -367
  272. package/dist/index221.js.map +1 -1
  273. package/dist/index222.js +24 -265
  274. package/dist/index222.js.map +1 -1
  275. package/dist/index223.js +27 -63
  276. package/dist/index223.js.map +1 -1
  277. package/dist/index224.js +68 -47
  278. package/dist/index224.js.map +1 -1
  279. package/dist/index225.js +17 -172
  280. package/dist/index225.js.map +1 -1
  281. package/dist/index226.js +7 -113
  282. package/dist/index226.js.map +1 -1
  283. package/dist/index227.js +53 -27
  284. package/dist/index227.js.map +1 -1
  285. package/dist/index228.js +8 -10
  286. package/dist/index228.js.map +1 -1
  287. package/dist/index229.js +28 -6
  288. package/dist/index229.js.map +1 -1
  289. package/dist/index23.js +109 -30
  290. package/dist/index23.js.map +1 -1
  291. package/dist/index230.js +16 -8
  292. package/dist/index230.js.map +1 -1
  293. package/dist/index231.js +12 -7
  294. package/dist/index231.js.map +1 -1
  295. package/dist/index232.js +3 -470
  296. package/dist/index233.js +28 -188
  297. package/dist/index233.js.map +1 -1
  298. package/dist/index234.js +68 -107
  299. package/dist/index234.js.map +1 -1
  300. package/dist/index235.js +3 -266
  301. package/dist/index236.js +14 -12
  302. package/dist/index236.js.map +1 -1
  303. package/dist/index237.js +53 -45
  304. package/dist/index237.js.map +1 -1
  305. package/dist/index238.js +117 -7
  306. package/dist/index238.js.map +1 -1
  307. package/dist/index239.js +9 -28
  308. package/dist/index239.js.map +1 -1
  309. package/dist/index24.js +3 -269
  310. package/dist/index24.js.map +1 -1
  311. package/dist/index240.js +15 -31
  312. package/dist/index240.js.map +1 -1
  313. package/dist/index241.js +689 -7
  314. package/dist/index241.js.map +1 -1
  315. package/dist/index242.js +256 -71
  316. package/dist/index242.js.map +1 -1
  317. package/dist/index243.js +704 -184
  318. package/dist/index243.js.map +1 -1
  319. package/dist/index244.js +7433 -49
  320. package/dist/index244.js.map +1 -1
  321. package/dist/index245.js +9 -7
  322. package/dist/index245.js.map +1 -1
  323. package/dist/index246.js +16 -22
  324. package/dist/index246.js.map +1 -1
  325. package/dist/index247.js +8 -15
  326. package/dist/index247.js.map +1 -1
  327. package/dist/index248.js +462 -16
  328. package/dist/index248.js.map +1 -1
  329. package/dist/index249.js +41 -158
  330. package/dist/index249.js.map +1 -1
  331. package/dist/index25.js +11 -179
  332. package/dist/index25.js.map +1 -1
  333. package/dist/index250.js +21 -32
  334. package/dist/index250.js.map +1 -1
  335. package/dist/index251.js +30 -12
  336. package/dist/index251.js.map +1 -1
  337. package/dist/index252.js +8 -52
  338. package/dist/index252.js.map +1 -1
  339. package/dist/index253.js +62 -15
  340. package/dist/index253.js.map +1 -1
  341. package/dist/index254.js +10 -47
  342. package/dist/index254.js.map +1 -1
  343. package/dist/index255.js +14 -97
  344. package/dist/index255.js.map +1 -1
  345. package/dist/index256.js +6 -90
  346. package/dist/index256.js.map +1 -1
  347. package/dist/index257.js +20 -109
  348. package/dist/index257.js.map +1 -1
  349. package/dist/index258.js +28 -55
  350. package/dist/index258.js.map +1 -1
  351. package/dist/index259.js +47 -15
  352. package/dist/index259.js.map +1 -1
  353. package/dist/index26.js +22 -16
  354. package/dist/index26.js.map +1 -1
  355. package/dist/index260.js +16 -40
  356. package/dist/index260.js.map +1 -1
  357. package/dist/index261.js +28 -11
  358. package/dist/index261.js.map +1 -1
  359. package/dist/index262.js +20 -119
  360. package/dist/index262.js.map +1 -1
  361. package/dist/index263.js +38 -20
  362. package/dist/index263.js.map +1 -1
  363. package/dist/index264.js +8 -18
  364. package/dist/index264.js.map +1 -1
  365. package/dist/index265.js +12 -6
  366. package/dist/index265.js.map +1 -1
  367. package/dist/index266.js +11 -39
  368. package/dist/index266.js.map +1 -1
  369. package/dist/index267.js +12 -23
  370. package/dist/index267.js.map +1 -1
  371. package/dist/index268.js +13 -12
  372. package/dist/index268.js.map +1 -1
  373. package/dist/index269.js +10 -11
  374. package/dist/index269.js.map +1 -1
  375. package/dist/index27.js +61 -2924
  376. package/dist/index27.js.map +1 -1
  377. package/dist/index270.js +76 -22
  378. package/dist/index270.js.map +1 -1
  379. package/dist/index271.js +174 -31
  380. package/dist/index271.js.map +1 -1
  381. package/dist/index272.js +118 -20
  382. package/dist/index272.js.map +1 -1
  383. package/dist/index273.js +18 -8
  384. package/dist/index273.js.map +1 -1
  385. package/dist/index274.js +83 -5
  386. package/dist/index274.js.map +1 -1
  387. package/dist/index275.js +49 -26
  388. package/dist/index275.js.map +1 -1
  389. package/dist/index276.js +15 -114
  390. package/dist/index276.js.map +1 -1
  391. package/dist/index277.js +19 -18
  392. package/dist/index277.js.map +1 -1
  393. package/dist/index278.js +98 -523
  394. package/dist/index278.js.map +1 -1
  395. package/dist/index279.js +60 -131
  396. package/dist/index279.js.map +1 -1
  397. package/dist/index28.js +58 -5
  398. package/dist/index28.js.map +1 -1
  399. package/dist/index280.js +109 -134
  400. package/dist/index280.js.map +1 -1
  401. package/dist/index281.js +75 -9
  402. package/dist/index281.js.map +1 -1
  403. package/dist/index282.js +117 -9
  404. package/dist/index282.js.map +1 -1
  405. package/dist/index283.js +59 -7
  406. package/dist/index283.js.map +1 -1
  407. package/dist/index284.js +46 -18
  408. package/dist/index284.js.map +1 -1
  409. package/dist/index285.js +146 -12
  410. package/dist/index285.js.map +1 -1
  411. package/dist/index286.js +143 -9
  412. package/dist/index286.js.map +1 -1
  413. package/dist/index287.js +258 -8
  414. package/dist/index287.js.map +1 -1
  415. package/dist/index288.js +241 -546
  416. package/dist/index288.js.map +1 -1
  417. package/dist/index289.js +302 -50
  418. package/dist/index289.js.map +1 -1
  419. package/dist/index29.js +1 -40
  420. package/dist/index290.js +9 -21
  421. package/dist/index290.js.map +1 -1
  422. package/dist/index291.js +9 -9
  423. package/dist/index291.js.map +1 -1
  424. package/dist/index292.js +10 -11
  425. package/dist/index292.js.map +1 -1
  426. package/dist/index293.js +9 -10
  427. package/dist/index293.js.map +1 -1
  428. package/dist/index294.js +9 -11
  429. package/dist/index294.js.map +1 -1
  430. package/dist/index295.js +24 -15
  431. package/dist/index295.js.map +1 -1
  432. package/dist/index296.js +13 -12
  433. package/dist/index296.js.map +1 -1
  434. package/dist/index297.js +130 -17
  435. package/dist/index297.js.map +1 -1
  436. package/dist/index298.js +167 -23
  437. package/dist/index298.js.map +1 -1
  438. package/dist/index299.js +69 -65
  439. package/dist/index299.js.map +1 -1
  440. package/dist/index3.js +6 -5
  441. package/dist/index3.js.map +1 -1
  442. package/dist/index30.js +6 -6
  443. package/dist/index300.js +113 -72
  444. package/dist/index300.js.map +1 -1
  445. package/dist/index301.js +495 -12
  446. package/dist/index301.js.map +1 -1
  447. package/dist/index302.js +65 -16
  448. package/dist/index302.js.map +1 -1
  449. package/dist/index303.js +7 -69
  450. package/dist/index303.js.map +1 -1
  451. package/dist/index304.js +30 -7
  452. package/dist/index304.js.map +1 -1
  453. package/dist/index305.js +68 -58
  454. package/dist/index305.js.map +1 -1
  455. package/dist/index306.js +155 -70
  456. package/dist/index306.js.map +1 -1
  457. package/dist/index307.js +563 -32
  458. package/dist/index307.js.map +1 -1
  459. package/dist/index308.js +213 -11
  460. package/dist/index308.js.map +1 -1
  461. package/dist/index309.js +335 -156
  462. package/dist/index309.js.map +1 -1
  463. package/dist/index31.js +8 -128
  464. package/dist/index31.js.map +1 -1
  465. package/dist/index310.js +271 -110
  466. package/dist/index310.js.map +1 -1
  467. package/dist/index32.js +8 -234
  468. package/dist/index32.js.map +1 -1
  469. package/dist/index33.js +8 -26
  470. package/dist/index33.js.map +1 -1
  471. package/dist/index34.js +11 -54
  472. package/dist/index34.js.map +1 -1
  473. package/dist/index35.js +13 -24
  474. package/dist/index35.js.map +1 -1
  475. package/dist/index36.js +9 -133
  476. package/dist/index36.js.map +1 -1
  477. package/dist/index37.js +11 -225
  478. package/dist/index37.js.map +1 -1
  479. package/dist/index38.js +12 -94
  480. package/dist/index38.js.map +1 -1
  481. package/dist/index39.js +15 -121
  482. package/dist/index39.js.map +1 -1
  483. package/dist/index4.js +24 -28
  484. package/dist/index4.js.map +1 -1
  485. package/dist/index40.js +9 -8
  486. package/dist/index40.js.map +1 -1
  487. package/dist/index41.js +10 -847
  488. package/dist/index41.js.map +1 -1
  489. package/dist/index42.js +10 -60
  490. package/dist/index42.js.map +1 -1
  491. package/dist/index43.js +12 -10
  492. package/dist/index43.js.map +1 -1
  493. package/dist/index44.js +12 -5
  494. package/dist/index44.js.map +1 -1
  495. package/dist/index45.js +8 -14
  496. package/dist/index45.js.map +1 -1
  497. package/dist/index46.js +8 -21
  498. package/dist/index46.js.map +1 -1
  499. package/dist/index47.js +14 -10
  500. package/dist/index47.js.map +1 -1
  501. package/dist/index48.js +15 -5
  502. package/dist/index48.js.map +1 -1
  503. package/dist/index49.js +10 -26
  504. package/dist/index49.js.map +1 -1
  505. package/dist/index5.js +34 -48
  506. package/dist/index5.js.map +1 -1
  507. package/dist/index50.js +7 -236
  508. package/dist/index50.js.map +1 -1
  509. package/dist/index51.js +9 -9
  510. package/dist/index51.js.map +1 -1
  511. package/dist/index52.js +9 -36
  512. package/dist/index52.js.map +1 -1
  513. package/dist/index53.js +9 -29
  514. package/dist/index53.js.map +1 -1
  515. package/dist/index54.js +12 -10
  516. package/dist/index54.js.map +1 -1
  517. package/dist/index55.js +16 -14
  518. package/dist/index55.js.map +1 -1
  519. package/dist/index56.js +10 -5
  520. package/dist/index56.js.map +1 -1
  521. package/dist/index57.js +10 -5
  522. package/dist/index57.js.map +1 -1
  523. package/dist/index58.js +10 -5
  524. package/dist/index58.js.map +1 -1
  525. package/dist/index59.js +17 -5
  526. package/dist/index59.js.map +1 -1
  527. package/dist/index6.js +42 -227
  528. package/dist/index6.js.map +1 -1
  529. package/dist/index60.js +11 -208
  530. package/dist/index60.js.map +1 -1
  531. package/dist/index61.js +11 -6
  532. package/dist/index61.js.map +1 -1
  533. package/dist/index62.js +70 -50
  534. package/dist/index62.js.map +1 -1
  535. package/dist/index63.js +10 -53
  536. package/dist/index63.js.map +1 -1
  537. package/dist/index64.js +33 -10
  538. package/dist/index64.js.map +1 -1
  539. package/dist/index65.js +13 -18
  540. package/dist/index65.js.map +1 -1
  541. package/dist/index66.js +19 -137
  542. package/dist/index66.js.map +1 -1
  543. package/dist/index67.js +203 -13
  544. package/dist/index67.js.map +1 -1
  545. package/dist/index68.js +22 -218
  546. package/dist/index68.js.map +1 -1
  547. package/dist/index69.js +20 -16
  548. package/dist/index69.js.map +1 -1
  549. package/dist/index7.js +225 -37
  550. package/dist/index7.js.map +1 -1
  551. package/dist/index70.js +125 -49
  552. package/dist/index70.js.map +1 -1
  553. package/dist/index71.js +21 -52
  554. package/dist/index71.js.map +1 -1
  555. package/dist/index72.js +12 -7
  556. package/dist/index72.js.map +1 -1
  557. package/dist/index73.js +12 -8
  558. package/dist/index73.js.map +1 -1
  559. package/dist/index74.js +17 -31
  560. package/dist/index74.js.map +1 -1
  561. package/dist/index75.js +13 -53
  562. package/dist/index75.js.map +1 -1
  563. package/dist/index76.js +13 -12
  564. package/dist/index76.js.map +1 -1
  565. package/dist/index77.js +8 -55
  566. package/dist/index77.js.map +1 -1
  567. package/dist/index78.js +44 -7
  568. package/dist/index78.js.map +1 -1
  569. package/dist/index79.js +383 -7
  570. package/dist/index79.js.map +1 -1
  571. package/dist/index8.js +36 -32
  572. package/dist/index8.js.map +1 -1
  573. package/dist/index80.js +41 -18
  574. package/dist/index80.js.map +1 -1
  575. package/dist/index81.js +25 -9
  576. package/dist/index81.js.map +1 -1
  577. package/dist/index82.js +60 -10
  578. package/dist/index82.js.map +1 -1
  579. package/dist/index83.js +10 -19
  580. package/dist/index83.js.map +1 -1
  581. package/dist/index84.js +8 -7
  582. package/dist/index84.js.map +1 -1
  583. package/dist/index85.js +8 -7
  584. package/dist/index85.js.map +1 -1
  585. package/dist/index86.js +8 -8
  586. package/dist/index86.js.map +1 -1
  587. package/dist/index87.js +8 -8
  588. package/dist/index87.js.map +1 -1
  589. package/dist/index88.js +9 -7
  590. package/dist/index88.js.map +1 -1
  591. package/dist/index89.js +9 -7
  592. package/dist/index89.js.map +1 -1
  593. package/dist/index9.js +33 -181
  594. package/dist/index9.js.map +1 -1
  595. package/dist/index90.js +13 -9
  596. package/dist/index90.js.map +1 -1
  597. package/dist/index91.js +10 -27
  598. package/dist/index91.js.map +1 -1
  599. package/dist/index92.js +9 -9
  600. package/dist/index92.js.map +1 -1
  601. package/dist/index93.js +8 -7
  602. package/dist/index93.js.map +1 -1
  603. package/dist/index94.js +10 -9
  604. package/dist/index94.js.map +1 -1
  605. package/dist/index95.js +50 -8
  606. package/dist/index95.js.map +1 -1
  607. package/dist/index96.js +108 -7
  608. package/dist/index96.js.map +1 -1
  609. package/dist/index97.js +13 -8
  610. package/dist/index97.js.map +1 -1
  611. package/dist/index98.js +9 -7
  612. package/dist/index98.js.map +1 -1
  613. package/dist/index99.js +9 -11
  614. package/dist/index99.js.map +1 -1
  615. package/package.json +6 -6
  616. package/dist/index.js.map +0 -1
  617. package/dist/index2.js.map +0 -1
  618. package/dist/index232.js.map +0 -1
  619. package/dist/index235.js.map +0 -1
  620. package/dist/index29.js.map +0 -1
  621. package/dist/index30.js.map +0 -1
  622. package/dist/index311.js +0 -7
  623. package/dist/index311.js.map +0 -1
  624. package/dist/index312.js +0 -26
  625. package/dist/index312.js.map +0 -1
  626. package/dist/index313.js +0 -19
  627. package/dist/index313.js.map +0 -1
  628. package/dist/index314.js +0 -32
  629. package/dist/index314.js.map +0 -1
  630. package/dist/index315.js +0 -16
  631. package/dist/index315.js.map +0 -1
  632. package/dist/index316.js +0 -10
  633. package/dist/index316.js.map +0 -1
  634. package/dist/index317.js +0 -26
  635. package/dist/index317.js.map +0 -1
  636. package/dist/index318.js +0 -16
  637. package/dist/index318.js.map +0 -1
  638. package/dist/index319.js +0 -31
  639. package/dist/index319.js.map +0 -1
  640. package/dist/index320.js +0 -8
  641. package/dist/index320.js.map +0 -1
package/dist/index36.js CHANGED
@@ -1,133 +1,9 @@
1
- import { getCountryList as E } from "./index148.js";
2
- import { getCountryCallingCode as s } from "./index40.js";
3
- const c = "US", u = E(), f = /* @__PURE__ */ new Map(), m = "__default_locale__", _ = Array.from(new Set(u.map((e) => s(e)))).sort((e, t) => t.length - e.length), O = _.reduce((e, t) => Math.max(e, t.length), 0), y = ["0011", "001", "011", "00", "810"];
4
- function R(e) {
5
- return e && u.includes(e) ? e : c;
6
- }
7
- function C(e) {
8
- if (typeof Intl > "u" || typeof Intl.DisplayNames > "u")
9
- return null;
10
- try {
11
- const t = Array.isArray(e) ? e : e ? [e] : void 0;
12
- return new Intl.DisplayNames(t, {
13
- type: "region"
14
- });
15
- } catch {
16
- return null;
17
- }
18
- }
19
- function N(e) {
20
- const t = C(e), r = C("en");
21
- return u.map((n) => {
22
- const a = s(n), o = t?.of(n) ?? r?.of(n) ?? n, i = r?.of(n) ?? o, g = D(n), l = Array.from(new Set([o, i, n.toUpperCase(), n.toLowerCase(), ...g].filter(Boolean)));
23
- return {
24
- value: n,
25
- name: o,
26
- dialCode: a,
27
- label: `${o} (+${a})`,
28
- flag: A(n),
29
- searchableTokens: l,
30
- normalizedSearchableTokens: l.map((p) => U(p))
31
- };
32
- }).sort((n, a) => {
33
- const o = d(n.value), i = d(a.value);
34
- return o !== i ? o - i : n.name.localeCompare(a.name);
35
- });
36
- }
37
- function d(e) {
38
- return e === "US" ? 0 : e === "CA" ? 1 : s(e) === "1" ? 2 : 3;
39
- }
40
- function b(e) {
41
- return e ? Array.isArray(e) ? e.join("\0") : e : m;
42
- }
43
- function L(e) {
44
- if (e !== m) {
45
- if (e.includes("\0")) {
46
- const t = e.split("\0").filter(Boolean);
47
- return t.length === 0 ? void 0 : t.length === 1 ? t[0] ?? void 0 : t;
48
- }
49
- return e;
50
- }
51
- }
52
- function v(e, t) {
53
- const r = f.get(t);
54
- if (r)
55
- return r;
56
- const n = N(e);
57
- return f.set(t, n), n;
58
- }
59
- function F(e) {
60
- return {
61
- code: e.value,
62
- name: e.name,
63
- dialCode: e.dialCode,
64
- flag: e.flag
65
- };
66
- }
67
- function M(e) {
68
- return {
69
- code: e,
70
- name: e,
71
- dialCode: s(e),
72
- flag: A(e)
73
- };
74
- }
75
- function A(e) {
76
- const t = e?.toUpperCase();
77
- if (!t || t.length !== 2 || /[^A-Z]/.test(t))
78
- return "";
79
- const r = 127397;
80
- return String.fromCodePoint(t.charCodeAt(0) + r, t.charCodeAt(1) + r);
81
- }
82
- const S = /[\u0300-\u036f]/g;
83
- function h(e) {
84
- return e.normalize("NFD").replace(S, "");
85
- }
86
- function U(e) {
87
- return h(e).toLowerCase();
88
- }
89
- function B(e, t) {
90
- let r = Number.MAX_SAFE_INTEGER;
91
- for (const n of e) {
92
- const a = n.indexOf(t);
93
- a >= 0 && a < r && (r = a);
94
- }
95
- return r === Number.MAX_SAFE_INTEGER ? Number.MAX_SAFE_INTEGER : r;
96
- }
97
- function D(e) {
98
- switch (e) {
99
- case "US":
100
- return ["USA", "United States", "America", "United States of America"];
101
- case "GB":
102
- return ["UK", "United Kingdom", "Great Britain", "England"];
103
- case "AE":
104
- return ["UAE", "United Arab Emirates"];
105
- case "KR":
106
- return ["South Korea", "Korea"];
107
- case "CN":
108
- return ["China", "PRC"];
109
- case "CD":
110
- return ["DRC", "Congo-Kinshasa"];
111
- case "CG":
112
- return ["Congo-Brazzaville"];
113
- case "BR":
114
- return ["Brazil"];
115
- default:
116
- return [];
117
- }
118
- }
119
- export {
120
- y as COMMON_IDD_PREFIXES,
121
- _ as COUNTRY_DIAL_CODES,
122
- c as DEFAULT_COUNTRY,
123
- O as MAX_DIAL_CODE_LENGTH,
124
- M as buildFallbackSelectedCountry,
125
- v as getCachedCountryOptions,
126
- b as getLocaleCacheKey,
127
- R as getValidCountry,
128
- U as normalizeSearchValue,
129
- B as optionMatchIndex,
130
- L as parseLocaleCacheKey,
131
- F as toSelectedCountry
132
- };
133
- //# sourceMappingURL=index36.js.map
1
+ //#region ../../node_modules/date-fns/_lib/defaultOptions.js
2
+ var e = {};
3
+ function t() {
4
+ return e;
5
+ }
6
+ //#endregion
7
+ export { t as getDefaultOptions };
8
+
9
+ //# sourceMappingURL=index36.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index36.js","sources":["../src/components/PhoneNumberInput/country-options.ts"],"sourcesContent":["import type { CountryCode } from \"libphonenumber-js\"\nimport { getCountryCallingCode } from \"libphonenumber-js\"\n\nimport type { CountryOption, PhoneNumberSelectedCountry } from \"./types\"\nimport { getCountryList } from \"./countries\"\n\n\nexport const DEFAULT_COUNTRY: CountryCode = \"US\"\nconst COUNTRY_OPTIONS = getCountryList()\n\nconst COUNTRY_OPTIONS_CACHE = new Map<string, CountryOption[]>()\nconst DEFAULT_LOCALE_CACHE_KEY = \"__default_locale__\"\nexport const COUNTRY_DIAL_CODES = Array.from(\n new Set(COUNTRY_OPTIONS.map((code) => getCountryCallingCode(code)))\n).sort((a, b) => b.length - a.length)\nexport const MAX_DIAL_CODE_LENGTH = COUNTRY_DIAL_CODES.reduce(\n (max, dial) => Math.max(max, dial.length),\n 0\n)\nexport const COMMON_IDD_PREFIXES = [\"0011\", \"001\", \"011\", \"00\", \"810\"]\n\nexport function getValidCountry(input: CountryCode | undefined) {\n if (!input) {\n return DEFAULT_COUNTRY\n }\n\n return COUNTRY_OPTIONS.includes(input) ? input : DEFAULT_COUNTRY\n}\n\nfunction createDisplayNames(locale?: string | string[]) {\n if (typeof Intl === \"undefined\" || typeof Intl.DisplayNames === \"undefined\") {\n return null\n }\n\n try {\n const locales = Array.isArray(locale) ? locale : locale ? [locale] : undefined\n return new Intl.DisplayNames(locales, { type: \"region\" })\n } catch {\n return null\n }\n}\n\nfunction buildCountryOptions(locale?: string | string[]) {\n const displayNames = createDisplayNames(locale)\n const englishDisplayNames = createDisplayNames(\"en\")\n\n return COUNTRY_OPTIONS\n .map((country) => {\n const dialCode = getCountryCallingCode(country)\n const localizedName = displayNames?.of(country) ?? englishDisplayNames?.of(country) ?? country\n const englishName = englishDisplayNames?.of(country) ?? localizedName\n const aliasTokens = getCountryAliases(country)\n const searchableTokens = Array.from(\n new Set(\n [localizedName, englishName, country.toUpperCase(), country.toLowerCase(), ...aliasTokens].filter(\n Boolean\n )\n )\n ) as string[]\n return {\n value: country,\n name: localizedName,\n dialCode,\n label: `${localizedName} (+${dialCode})`,\n flag: countryCodeToFlagEmoji(country),\n searchableTokens,\n normalizedSearchableTokens: searchableTokens.map((token) => normalizeSearchValue(token)),\n }\n })\n .sort((a, b) => {\n const priorityA = getCountryPriority(a.value)\n const priorityB = getCountryPriority(b.value)\n if (priorityA !== priorityB) {\n return priorityA - priorityB\n }\n return a.name.localeCompare(b.name)\n })\n}\n\nfunction getCountryPriority(code: CountryCode) {\n if (code === \"US\") return 0\n if (code === \"CA\") return 1\n if (getCountryCallingCode(code) === \"1\") return 2\n return 3\n}\n\nexport function getLocaleCacheKey(locale?: string | string[]) {\n if (!locale) {\n return DEFAULT_LOCALE_CACHE_KEY\n }\n if (Array.isArray(locale)) {\n return locale.join(\"\\u0000\")\n }\n return locale\n}\n\nexport function parseLocaleCacheKey(cacheKey: string): string | string[] | undefined {\n if (cacheKey === DEFAULT_LOCALE_CACHE_KEY) {\n return undefined\n }\n\n if (cacheKey.includes(\"\\u0000\")) {\n const parts = cacheKey.split(\"\\u0000\").filter(Boolean)\n if (parts.length === 0) {\n return undefined\n }\n if (parts.length === 1) {\n return parts[0] ?? undefined\n }\n return parts\n }\n\n return cacheKey\n}\n\nexport function getCachedCountryOptions(locale: string | string[] | undefined, cacheKey: string) {\n const cached = COUNTRY_OPTIONS_CACHE.get(cacheKey)\n if (cached) {\n return cached\n }\n const built = buildCountryOptions(locale)\n COUNTRY_OPTIONS_CACHE.set(cacheKey, built)\n return built\n}\n\nexport function toSelectedCountry(option: CountryOption): PhoneNumberSelectedCountry {\n return {\n code: option.value,\n name: option.name,\n dialCode: option.dialCode,\n flag: option.flag,\n }\n}\n\nexport function buildFallbackSelectedCountry(country: CountryCode): PhoneNumberSelectedCountry {\n return {\n code: country,\n name: country,\n dialCode: getCountryCallingCode(country),\n flag: countryCodeToFlagEmoji(country),\n }\n}\n\nfunction countryCodeToFlagEmoji(country: CountryCode) {\n const upper = country?.toUpperCase()\n\n if (!upper || upper.length !== 2 || /[^A-Z]/.test(upper)) {\n return \"\"\n }\n\n const base = 127397\n return String.fromCodePoint(\n upper.charCodeAt(0) + base,\n upper.charCodeAt(1) + base\n )\n}\n\nconst DIACRITICS_REGEX = /[\\u0300-\\u036f]/g\n\nfunction stripDiacritics(value: string) {\n return value.normalize(\"NFD\").replace(DIACRITICS_REGEX, \"\")\n}\n\nexport function normalizeSearchValue(value: string) {\n return stripDiacritics(value).toLowerCase()\n}\n\nexport function optionMatchIndex(tokens: string[], query: string) {\n let best = Number.MAX_SAFE_INTEGER\n for (const token of tokens) {\n const index = token.indexOf(query)\n if (index >= 0 && index < best) {\n best = index\n }\n }\n return best === Number.MAX_SAFE_INTEGER ? Number.MAX_SAFE_INTEGER : best\n}\n\nfunction getCountryAliases(code: CountryCode): string[] {\n switch (code) {\n case \"US\":\n return [\"USA\", \"United States\", \"America\", \"United States of America\"]\n case \"GB\":\n return [\"UK\", \"United Kingdom\", \"Great Britain\", \"England\"]\n case \"AE\":\n return [\"UAE\", \"United Arab Emirates\"]\n case \"KR\":\n return [\"South Korea\", \"Korea\"]\n case \"CN\":\n return [\"China\", \"PRC\"]\n case \"CD\":\n return [\"DRC\", \"Congo-Kinshasa\"]\n case \"CG\":\n return [\"Congo-Brazzaville\"]\n case \"BR\":\n return [\"Brazil\"]\n default:\n return []\n }\n}\n\n"],"names":["DEFAULT_COUNTRY","COUNTRY_OPTIONS","getCountryList","COUNTRY_OPTIONS_CACHE","Map","DEFAULT_LOCALE_CACHE_KEY","COUNTRY_DIAL_CODES","Array","from","Set","map","code","getCountryCallingCode","sort","a","b","length","MAX_DIAL_CODE_LENGTH","reduce","max","dial","Math","COMMON_IDD_PREFIXES","getValidCountry","input","includes","createDisplayNames","locale","Intl","DisplayNames","locales","isArray","undefined","type","buildCountryOptions","displayNames","englishDisplayNames","country","dialCode","localizedName","of","englishName","aliasTokens","getCountryAliases","searchableTokens","toUpperCase","toLowerCase","filter","Boolean","value","name","label","flag","countryCodeToFlagEmoji","normalizedSearchableTokens","token","normalizeSearchValue","priorityA","getCountryPriority","priorityB","localeCompare","getLocaleCacheKey","join","parseLocaleCacheKey","cacheKey","parts","split","getCachedCountryOptions","cached","get","built","set","toSelectedCountry","option","buildFallbackSelectedCountry","upper","test","base","String","fromCodePoint","charCodeAt","DIACRITICS_REGEX","stripDiacritics","normalize","replace","optionMatchIndex","tokens","query","best","Number","MAX_SAFE_INTEGER","index","indexOf"],"mappings":";;AAOO,MAAMA,IAA+B,MACtCC,IAAkBC,EAAAA,GAElBC,wBAA4BC,IAAAA,GAC5BC,IAA2B,sBACpBC,IAAqBC,MAAMC,KACtC,IAAIC,IAAIR,EAAgBS,IAAKC,OAASC,EAAsBD,CAAI,CAAC,CAAC,CACpE,EAAEE,KAAK,CAACC,GAAGC,MAAMA,EAAEC,SAASF,EAAEE,MAAM,GACvBC,IAAuBX,EAAmBY,OACrD,CAACC,GAAKC,MAASC,KAAKF,IAAIA,GAAKC,EAAKJ,MAAM,GACxC,CACF,GACaM,IAAsB,CAAC,QAAQ,OAAO,OAAO,MAAM,KAAK;AAE9D,SAASC,EAAgBC,GAAgC;AAC9D,SAAKA,KAIEvB,EAAgBwB,SAASD,CAAK,IAAIA,IAHhCxB;AAIX;AAEA,SAAS0B,EAAmBC,GAA4B;AACtD,MAAI,OAAOC,OAAS,OAAe,OAAOA,KAAKC,eAAiB;AAC9D,WAAO;AAGT,MAAI;AACF,UAAMC,IAAUvB,MAAMwB,QAAQJ,CAAM,IAAIA,IAASA,IAAS,CAACA,CAAM,IAAIK;AACrE,WAAO,IAAIJ,KAAKC,aAAaC,GAAS;AAAA,MAAEG,MAAM;AAAA,IAAA,CAAU;AAAA,EAC1D,QAAQ;AACN,WAAO;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C5D;AAEO,SAASzB,EAAqBP,GAAe;AAClD,SAAOiC,EAAgBjC,CAAK,EAAEH,YAAAA;AAChC;AAEO,SAASuC,EAAiBC,GAAkBC,GAAe;AAChE,MAAIC,IAAOC,OAAOC;AAClB,aAAWnC,KAAS+B,GAAQ;AAC1B,UAAMK,IAAQpC,EAAMqC,QAAQL,CAAK;AACjC,IAAII,KAAS,KAAKA,IAAQH,MACxBA,IAAOG;AAAAA,EAEX;AACA,SAAOH,MAASC,OAAOC,mBAAmBD,OAAOC,mBAAmBF;AACtE;AAEA,SAAS7C,EAAkBhC,GAA6B;AACtD,UAAQA,GAAAA;AAAAA,IACN,KAAK;AACH,aAAO,CAAC,OAAO,iBAAiB,WAAW,0BAA0B;AAAA,IACvE,KAAK;AACH,aAAO,CAAC,MAAM,kBAAkB,iBAAiB,SAAS;AAAA,IAC5D,KAAK;AACH,aAAO,CAAC,OAAO,sBAAsB;AAAA,IACvC,KAAK;AACH,aAAO,CAAC,eAAe,OAAO;AAAA,IAChC,KAAK;AACH,aAAO,CAAC,SAAS,KAAK;AAAA,IACxB,KAAK;AACH,aAAO,CAAC,OAAO,gBAAgB;AAAA,IACjC,KAAK;AACH,aAAO,CAAC,mBAAmB;AAAA,IAC7B,KAAK;AACH,aAAO,CAAC,QAAQ;AAAA,IAClB;AACE,aAAO,CAAA;AAAA,EAAA;AAEb;"}
1
+ {"version":3,"file":"index36.js","names":[],"sources":["../../../node_modules/date-fns/_lib/defaultOptions.js"],"sourcesContent":["let defaultOptions = {};\n\nexport function getDefaultOptions() {\n return defaultOptions;\n}\n\nexport function setDefaultOptions(newOptions) {\n defaultOptions = newOptions;\n}\n"],"x_google_ignoreList":[0],"mappings":";AAAA,IAAI,IAAiB,EAAE;AAEvB,SAAgB,IAAoB;AAClC,QAAO"}
package/dist/index37.js CHANGED
@@ -1,225 +1,11 @@
1
- import { MAX_DIAL_CODE_LENGTH as W, COMMON_IDD_PREFIXES as $, DEFAULT_COUNTRY as x, COUNTRY_DIAL_CODES as C } from "./index36.js";
2
- import { getCountryCallingCode as p } from "./index40.js";
3
- import { AsYouType as I } from "./index149.js";
4
- import { validatePhoneNumberLength as D } from "./index150.js";
5
- function g(t) {
6
- return t.replace(/\D/g, "");
7
- }
8
- function P(t) {
9
- return t ? t.length > W ? !1 : C.some((e) => e.startsWith(t)) : !0;
10
- }
11
- const N = /[\u061C\u200B-\u200F\u202A-\u202E\u2066-\u2069\uFEFF]/g;
12
- function T(t) {
13
- return t.replace(N, "");
14
- }
15
- function q(t, e, s = {}) {
16
- const {
17
- force: u = !1
18
- } = s, o = `+${e}`;
19
- if (!t.startsWith(o) || !u)
20
- return t;
21
- const i = t.slice(o.length).trimStart();
22
- if (i.startsWith("0"))
23
- return t;
24
- if (!i)
25
- return `${o} 0`;
26
- const [n, ...r] = i.split(" "), f = `0${n ?? ""}`, l = r.length > 0 ? ` ${r.join(" ")}` : "";
27
- return `${o} ${f}${l}`.replace(/\s\s+/g, " ").trimEnd();
28
- }
29
- const O = {
30
- GG: "GB",
31
- JE: "GB",
32
- IM: "GB"
33
- };
34
- function y(t) {
35
- if (t)
36
- return O[t] ?? t;
37
- }
38
- function _(t, e, s) {
39
- if (!t || !s || (t.nationalNumber ?? "").length < 4)
40
- return;
41
- const o = t.countryCallingCode;
42
- if (!o)
43
- return;
44
- const i = t.getMetadata, n = (typeof i == "function" ? i() : null)?.country_calling_codes?.[o];
45
- if (!n || n.length === 0)
46
- return;
47
- const r = [];
48
- for (const f of n) {
49
- const l = y(f);
50
- l && !r.includes(l) && r.push(l);
51
- }
52
- if (r.length !== 0)
53
- return e && r.includes(e) ? e : r.includes(x) ? x : r[0];
54
- }
55
- function B(t, e, s, u) {
56
- if (!t)
57
- return !1;
58
- if (!u)
59
- return t.startsWith("0");
60
- if (!s || !t.startsWith(s) || !t.slice(s.length).startsWith("0"))
61
- return !1;
62
- const o = t.slice(s.length + 1), i = e.startsWith(s) ? e.slice(s.length) : e;
63
- return o === i;
64
- }
65
- function S(t) {
66
- for (const e of $)
67
- if (t.startsWith(e))
68
- return t.slice(e.length);
69
- return t;
70
- }
71
- function M(t, e, s = {}) {
72
- const {
73
- allowJustPlus: u = !1,
74
- removeNationalPrefix: o = !0,
75
- previousValue: i
76
- } = s, n = T(t).trim();
77
- if (!n)
78
- return "";
79
- if (n === "+")
80
- return u ? "+" : "";
81
- if (n.startsWith("+")) {
82
- const a = g(n);
83
- if (!a)
84
- return u ? "+" : "";
85
- const d = S(a);
86
- if (d !== a)
87
- return d ? `+${d}` : u ? "+" : "";
88
- if (o && e) {
89
- const h = p(e);
90
- if (a.startsWith(h) && a.slice(h.length).startsWith("0")) {
91
- const E = a.slice(h.length + 1);
92
- return E ? `+${h}${E}` : `+${h}`;
93
- }
94
- }
95
- return `+${a}`;
96
- }
97
- const r = g(n);
98
- if (!r)
99
- return "";
100
- const f = S(r);
101
- if (f !== r)
102
- return f ? `+${f}` : u ? "+" : "";
103
- const l = typeof i == "string" ? i : "", m = l && l.startsWith("+") ? g(l) : "";
104
- if (m && m.length > r.length && m.endsWith(r) && m.length - r.length <= W)
105
- return `+${r}`;
106
- if (r === "0")
107
- return "0";
108
- if (o && e && r.length > 1 && r.startsWith("0") && !r.startsWith("00")) {
109
- const a = p(e), d = r.slice(1);
110
- return d ? `+${a}${d}` : `+${a}`;
111
- }
112
- return e ? r.length <= 4 ? `+${r}` : `+${p(e)}${r}` : r;
113
- }
114
- function Y(t, e) {
115
- if (t === "+")
116
- return {
117
- international: "+",
118
- national: "",
119
- formatted: "+",
120
- phoneNumber: null,
121
- detectedCountry: void 0,
122
- inferredCountry: void 0,
123
- hasExplicitInternationalPrefix: !0
124
- };
125
- const s = /^\s*\+/.test(t), u = e ? new I(e) : new I(), o = u.input(t), i = u.getNumber(), c = g(t), n = y(i?.country ?? u.country ?? void 0), r = n ?? !i ? void 0 : y(_(i, e, c)), f = i?.formatInternational() ?? o, l = i?.formatNational() ?? g(f);
126
- return {
127
- international: f,
128
- national: l,
129
- formatted: o,
130
- phoneNumber: i,
131
- detectedCountry: n,
132
- inferredCountry: r,
133
- hasExplicitInternationalPrefix: s
134
- };
135
- }
136
- function v(t, e) {
137
- return t.startsWith(e) ? t.slice(e.length) : t;
138
- }
139
- function H(t, e) {
140
- if (!e || !t)
141
- return null;
142
- try {
143
- return D(t, e) === "TOO_LONG" ? "TOO_LONG" : null;
144
- } catch {
145
- return null;
146
- }
147
- }
148
- function U(t, e, s, u = {}) {
149
- const {
150
- hasRemovedNationalPrefix: o = !1,
151
- detectedCountry: i,
152
- hasExplicitInternationalPrefix: c = !1
153
- } = u;
154
- if (!t)
155
- return {
156
- shouldSuggest: !1,
157
- query: ""
158
- };
159
- if (t === "+")
160
- return {
161
- shouldSuggest: !0,
162
- query: ""
163
- };
164
- const n = g(t);
165
- if (!n)
166
- return {
167
- shouldSuggest: !0,
168
- query: ""
169
- };
170
- if (o)
171
- return {
172
- shouldSuggest: !1,
173
- query: ""
174
- };
175
- if (c && !i)
176
- return P(n) ? {
177
- shouldSuggest: !0,
178
- query: n
179
- } : {
180
- shouldSuggest: !1,
181
- query: ""
182
- };
183
- let r = s?.countryCallingCode ?? null;
184
- if (!r) {
185
- if (e) {
186
- const l = p(e);
187
- n.startsWith(l) && (r = l);
188
- } else if (!c)
189
- return {
190
- shouldSuggest: !1,
191
- query: ""
192
- };
193
- }
194
- return r ? v(n, r).length === 0 ? {
195
- shouldSuggest: !0,
196
- query: n
197
- } : {
198
- shouldSuggest: !1,
199
- query: ""
200
- } : {
201
- shouldSuggest: !0,
202
- query: n
203
- };
204
- }
205
- function V(t, e) {
206
- if (t.shouldSuggest)
207
- return !1;
208
- const {
209
- hasExplicitInternationalPrefix: s = !1,
210
- detectedCountry: u
211
- } = e;
212
- return s ? !!u : !0;
213
- }
214
- export {
215
- B as detectNationalPrefixForDisplay,
216
- Y as formatWithAsYouType,
217
- H as getLengthIssue,
218
- U as getSuggestionState,
219
- q as injectNationalPrefixDisplay,
220
- M as normalizeInputValue,
221
- g as sanitizeDigits,
222
- V as shouldDisplayExplicitCountrySelection,
223
- v as stripPrefix
224
- };
225
- //# sourceMappingURL=index37.js.map
1
+ import e from "./index33.js";
2
+ import { getDefaultOptions as t } from "./index36.js";
3
+ //#region ../../node_modules/date-fns/startOfWeek.js
4
+ function n(n, r) {
5
+ let i = t(), a = r?.weekStartsOn ?? r?.locale?.options?.weekStartsOn ?? i.weekStartsOn ?? i.locale?.options?.weekStartsOn ?? 0, o = e(n, r?.in), s = o.getDay(), c = (s < a ? 7 : 0) + s - a;
6
+ return o.setDate(o.getDate() - c), o.setHours(0, 0, 0, 0), o;
7
+ }
8
+ //#endregion
9
+ export { n as default };
10
+
11
+ //# sourceMappingURL=index37.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index37.js","sources":["../src/components/PhoneNumberInput/normalization.ts"],"sourcesContent":["import type { CountryCode } from \"libphonenumber-js\"\nimport { AsYouType, getCountryCallingCode, validatePhoneNumberLength } from \"libphonenumber-js\"\n\nimport {\n COMMON_IDD_PREFIXES,\n COUNTRY_DIAL_CODES,\n DEFAULT_COUNTRY,\n MAX_DIAL_CODE_LENGTH,\n} from \"./country-options\"\n\n\nexport type LengthIssue = \"TOO_LONG\"\n\nexport function sanitizeDigits(value: string) {\n return value.replace(/\\D/g, \"\")\n}\n\nfunction isDialCodeProgress(digits: string) {\n if (!digits) {\n return true\n }\n\n if (digits.length > MAX_DIAL_CODE_LENGTH) {\n return false\n }\n\n return COUNTRY_DIAL_CODES.some((dial) => dial.startsWith(digits))\n}\n\nconst INVISIBLE_FORMATTING_CHARACTERS =\n /[\\u061C\\u200B-\\u200F\\u202A-\\u202E\\u2066-\\u2069\\uFEFF]/g\n\nfunction stripInvisibleFormatting(value: string) {\n return value.replace(INVISIBLE_FORMATTING_CHARACTERS, \"\")\n}\n\nexport function injectNationalPrefixDisplay(\n international: string,\n dialCode: string,\n options: { force?: boolean } = {}\n) {\n // Preserve a user-typed national trunk (e.g. the French \"0\") purely for display\n // so validation can continue to use the canonical E.164 representation internally.\n const { force = false } = options\n const prefix = `+${dialCode}`\n\n if (!international.startsWith(prefix)) {\n return international\n }\n\n if (!force) {\n return international\n }\n\n const remainder = international.slice(prefix.length).trimStart()\n const alreadyHasTrunk = remainder.startsWith(\"0\")\n\n if (alreadyHasTrunk) {\n return international\n }\n\n if (!remainder) {\n return `${prefix} 0`\n }\n\n const [firstGroup, ...restGroups] = remainder.split(\" \")\n const rebuiltFirstGroup = `0${firstGroup ?? \"\"}`\n const rebuiltRemainder = restGroups.length > 0 ? ` ${restGroups.join(\" \")}` : \"\"\n\n return `${prefix} ${rebuiltFirstGroup}${rebuiltRemainder}`.replace(/\\s\\s+/g, \" \").trimEnd()\n}\n\nconst DETECTED_COUNTRY_OVERRIDES: Partial<Record<CountryCode, CountryCode>> = {\n GG: \"GB\",\n JE: \"GB\",\n IM: \"GB\",\n}\n\nfunction canonicalizeDetectedCountry(candidate: CountryCode | undefined): CountryCode | undefined {\n if (!candidate) {\n return undefined\n }\n return DETECTED_COUNTRY_OVERRIDES[candidate] ?? candidate\n}\n\ntype AsYouTypeNumber = ReturnType<AsYouType[\"getNumber\"]>\n\nfunction inferCountryFromDialCode(\n phoneNumber: AsYouTypeNumber,\n baseCountry: CountryCode | undefined,\n normalizedDigits: string\n): CountryCode | undefined {\n if (!phoneNumber) {\n return undefined\n }\n\n if (!normalizedDigits) {\n return undefined\n }\n\n const nationalDigits = phoneNumber.nationalNumber ?? \"\"\n if (nationalDigits.length < 4) {\n return undefined\n }\n\n const dial = phoneNumber.countryCallingCode\n if (!dial) {\n return undefined\n }\n\n const metadataGetter = (phoneNumber as unknown as { getMetadata?: () => unknown }).getMetadata\n const metadata =\n typeof metadataGetter === \"function\"\n ? (metadataGetter() as {\n country_calling_codes?: Record<string, string[]>\n } | null)\n : null\n\n const candidates = metadata?.country_calling_codes?.[dial]\n if (!candidates || candidates.length === 0) {\n return undefined\n }\n\n const canonicalCandidates: CountryCode[] = []\n for (const candidate of candidates) {\n const canonical = canonicalizeDetectedCountry(candidate as CountryCode)\n if (canonical && !canonicalCandidates.includes(canonical)) {\n canonicalCandidates.push(canonical)\n }\n }\n\n if (canonicalCandidates.length === 0) {\n return undefined\n }\n\n if (baseCountry && canonicalCandidates.includes(baseCountry)) {\n return baseCountry\n }\n\n if (canonicalCandidates.includes(DEFAULT_COUNTRY)) {\n return DEFAULT_COUNTRY\n }\n\n return canonicalCandidates[0]\n}\n\nexport function detectNationalPrefixForDisplay(\n rawDigits: string,\n internationalDigits: string,\n dialCode: string,\n hasExplicitInternationalPrefix: boolean\n) {\n if (!rawDigits) {\n return false\n }\n\n if (!hasExplicitInternationalPrefix) {\n return rawDigits.startsWith(\"0\")\n }\n\n if (!dialCode) {\n return false\n }\n\n if (!rawDigits.startsWith(dialCode)) {\n return false\n }\n\n if (!rawDigits.slice(dialCode.length).startsWith(\"0\")) {\n return false\n }\n\n const rawAfterTrunk = rawDigits.slice(dialCode.length + 1)\n const internationalAfterDial = internationalDigits.startsWith(dialCode)\n ? internationalDigits.slice(dialCode.length)\n : internationalDigits\n\n return rawAfterTrunk === internationalAfterDial\n}\n\nfunction stripIddPrefix(digits: string) {\n for (const prefix of COMMON_IDD_PREFIXES) {\n if (digits.startsWith(prefix)) {\n return digits.slice(prefix.length)\n }\n }\n return digits\n}\n\nexport function normalizeInputValue(\n rawValue: string,\n country: CountryCode | undefined,\n options: {\n allowJustPlus?: boolean\n removeNationalPrefix?: boolean\n previousValue?: string\n } = {}\n) {\n const { allowJustPlus = false, removeNationalPrefix = true, previousValue } = options\n const cleaned = stripInvisibleFormatting(rawValue)\n const trimmed = cleaned.trim()\n\n if (!trimmed) {\n return \"\"\n }\n\n if (trimmed === \"+\") {\n return allowJustPlus ? \"+\" : \"\"\n }\n\n if (trimmed.startsWith(\"+\")) {\n const digits = sanitizeDigits(trimmed)\n if (!digits) {\n return allowJustPlus ? \"+\" : \"\"\n }\n const digitsWithoutIdd = stripIddPrefix(digits)\n if (digitsWithoutIdd !== digits) {\n return digitsWithoutIdd ? `+${digitsWithoutIdd}` : allowJustPlus ? \"+\" : \"\"\n }\n if (removeNationalPrefix && country) {\n const dial = getCountryCallingCode(country)\n if (digits.startsWith(dial) && digits.slice(dial.length).startsWith(\"0\")) {\n const withoutPrefix = digits.slice(dial.length + 1)\n return withoutPrefix ? `+${dial}${withoutPrefix}` : `+${dial}`\n }\n }\n return `+${digits}`\n }\n\n const digitsOnly = sanitizeDigits(trimmed)\n if (!digitsOnly) {\n return \"\"\n }\n\n const digitsWithoutIdd = stripIddPrefix(digitsOnly)\n if (digitsWithoutIdd !== digitsOnly) {\n return digitsWithoutIdd ? `+${digitsWithoutIdd}` : allowJustPlus ? \"+\" : \"\"\n }\n\n const previousNormalized = typeof previousValue === \"string\" ? previousValue : \"\"\n const previousDigits =\n previousNormalized && previousNormalized.startsWith(\"+\")\n ? sanitizeDigits(previousNormalized)\n : \"\"\n\n if (previousDigits && previousDigits.length > digitsOnly.length) {\n if (previousDigits.endsWith(digitsOnly)) {\n const removedPrefixLength = previousDigits.length - digitsOnly.length\n if (removedPrefixLength <= MAX_DIAL_CODE_LENGTH) {\n return `+${digitsOnly}`\n }\n }\n }\n\n if (digitsOnly === \"0\") {\n return \"0\"\n }\n\n if (\n removeNationalPrefix &&\n country &&\n digitsOnly.length > 1 &&\n digitsOnly.startsWith(\"0\") &&\n !digitsOnly.startsWith(\"00\")\n ) {\n const dial = getCountryCallingCode(country)\n const withoutPrefix = digitsOnly.slice(1)\n return withoutPrefix ? `+${dial}${withoutPrefix}` : `+${dial}`\n }\n\n if (!country) {\n return digitsOnly\n }\n\n if (digitsOnly.length <= 4) {\n return `+${digitsOnly}`\n }\n\n const dial = getCountryCallingCode(country)\n return `+${dial}${digitsOnly}`\n}\n\nexport function formatWithAsYouType(value: string, baseCountry?: CountryCode) {\n if (value === \"+\") {\n return {\n international: \"+\",\n national: \"\",\n formatted: \"+\",\n phoneNumber: null,\n detectedCountry: undefined,\n inferredCountry: undefined,\n hasExplicitInternationalPrefix: true,\n }\n }\n\n const hasExplicitInternationalPrefix = /^\\s*\\+/.test(value)\n const formatter = baseCountry ? new AsYouType(baseCountry) : new AsYouType()\n const formatted = formatter.input(value)\n const phoneNumber = formatter.getNumber()\n const digits = sanitizeDigits(value)\n const detectedCountry = canonicalizeDetectedCountry(\n (phoneNumber?.country ?? formatter.country ?? undefined) as CountryCode | undefined\n )\n const inferredCountry =\n detectedCountry ?? !phoneNumber\n ? undefined\n : canonicalizeDetectedCountry(\n inferCountryFromDialCode(phoneNumber, baseCountry, digits)\n )\n\n const international = phoneNumber?.formatInternational() ?? formatted\n const national = phoneNumber?.formatNational() ?? sanitizeDigits(international)\n\n return {\n international,\n national,\n formatted,\n phoneNumber,\n detectedCountry,\n inferredCountry,\n hasExplicitInternationalPrefix,\n }\n}\n\nexport function stripPrefix(value: string, prefix: string) {\n return value.startsWith(prefix) ? value.slice(prefix.length) : value\n}\n\nexport function getLengthIssue(value: string, country: CountryCode | undefined): LengthIssue | null {\n if (!country || !value) {\n return null\n }\n\n try {\n const result = validatePhoneNumberLength(value, country)\n return result === \"TOO_LONG\" ? \"TOO_LONG\" : null\n } catch {\n return null\n }\n}\n\ntype SuggestionState = {\n shouldSuggest: boolean\n query: string\n}\n\nexport function getSuggestionState(\n normalized: string,\n baseCountry: CountryCode | undefined,\n phoneNumber: ReturnType<AsYouType[\"getNumber\"]>,\n options: {\n hasRemovedNationalPrefix?: boolean\n detectedCountry?: CountryCode\n hasExplicitInternationalPrefix?: boolean\n } = {}\n): SuggestionState {\n const {\n hasRemovedNationalPrefix = false,\n detectedCountry,\n hasExplicitInternationalPrefix = false,\n } = options\n\n if (!normalized) {\n return { shouldSuggest: false, query: \"\" }\n }\n\n if (normalized === \"+\") {\n return { shouldSuggest: true, query: \"\" }\n }\n\n const digits = sanitizeDigits(normalized)\n if (!digits) {\n return { shouldSuggest: true, query: \"\" }\n }\n\n if (hasRemovedNationalPrefix) {\n return { shouldSuggest: false, query: \"\" }\n }\n\n if (hasExplicitInternationalPrefix && !detectedCountry) {\n if (!isDialCodeProgress(digits)) {\n return { shouldSuggest: false, query: \"\" }\n }\n return { shouldSuggest: true, query: digits }\n }\n\n let dial = phoneNumber?.countryCallingCode ?? null\n if (!dial) {\n if (baseCountry) {\n const baseDial = getCountryCallingCode(baseCountry)\n if (digits.startsWith(baseDial)) {\n dial = baseDial\n }\n } else if (!hasExplicitInternationalPrefix) {\n return { shouldSuggest: false, query: \"\" }\n }\n }\n\n if (!dial) {\n return { shouldSuggest: true, query: digits }\n }\n\n const nationalDigits = stripPrefix(digits, dial)\n if (nationalDigits.length === 0) {\n return { shouldSuggest: true, query: digits }\n }\n\n return { shouldSuggest: false, query: \"\" }\n}\n\nexport function shouldDisplayExplicitCountrySelection(\n suggestion: SuggestionState,\n options: { detectedCountry?: CountryCode; hasExplicitInternationalPrefix?: boolean }\n) {\n if (suggestion.shouldSuggest) {\n return false\n }\n\n const { hasExplicitInternationalPrefix = false, detectedCountry } = options\n\n if (!hasExplicitInternationalPrefix) {\n return true\n }\n\n return Boolean(detectedCountry)\n}\n"],"names":["sanitizeDigits","value","replace","isDialCodeProgress","digits","length","MAX_DIAL_CODE_LENGTH","COUNTRY_DIAL_CODES","some","dial","startsWith","INVISIBLE_FORMATTING_CHARACTERS","stripInvisibleFormatting","injectNationalPrefixDisplay","international","dialCode","options","force","prefix","remainder","slice","trimStart","firstGroup","restGroups","split","rebuiltFirstGroup","rebuiltRemainder","join","trimEnd","DETECTED_COUNTRY_OVERRIDES","GG","JE","IM","canonicalizeDetectedCountry","candidate","inferCountryFromDialCode","phoneNumber","baseCountry","normalizedDigits","nationalNumber","countryCallingCode","metadataGetter","getMetadata","candidates","country_calling_codes","canonicalCandidates","canonical","includes","push","DEFAULT_COUNTRY","detectNationalPrefixForDisplay","rawDigits","internationalDigits","hasExplicitInternationalPrefix","rawAfterTrunk","internationalAfterDial","stripIddPrefix","COMMON_IDD_PREFIXES","normalizeInputValue","rawValue","country","allowJustPlus","removeNationalPrefix","previousValue","trimmed","trim","digitsWithoutIdd","getCountryCallingCode","withoutPrefix","digitsOnly","previousNormalized","previousDigits","endsWith","formatWithAsYouType","national","formatted","detectedCountry","undefined","inferredCountry","test","formatter","AsYouType","input","getNumber","formatInternational","formatNational","stripPrefix","getLengthIssue","validatePhoneNumberLength","getSuggestionState","normalized","hasRemovedNationalPrefix","shouldSuggest","query","baseDial","shouldDisplayExplicitCountrySelection","suggestion","Boolean"],"mappings":";;;;AAaO,SAASA,EAAeC,GAAe;AAC5C,SAAOA,EAAMC,QAAQ,OAAO,EAAE;AAChC;AAEA,SAASC,EAAmBC,GAAgB;AAC1C,SAAKA,IAIDA,EAAOC,SAASC,IACX,KAGFC,EAAmBC,KAAMC,CAAAA,MAASA,EAAKC,WAAWN,CAAM,CAAC,IAPvD;AAQX;AAEA,MAAMO,IACJ;AAEF,SAASC,EAAyBX,GAAe;AAC/C,SAAOA,EAAMC,QAAQS,GAAiC,EAAE;AAC1D;AAEO,SAASE,EACdC,GACAC,GACAC,IAA+B,CAAA,GAC/B;AAGA,QAAM;AAAA,IAAEC,OAAAA,IAAQ;AAAA,EAAA,IAAUD,GACpBE,IAAS,IAAIH,CAAQ;AAM3B,MAJI,CAACD,EAAcJ,WAAWQ,CAAM,KAIhC,CAACD;AACH,WAAOH;AAGT,QAAMK,IAAYL,EAAcM,MAAMF,EAAOb,MAAM,EAAEgB,UAAAA;AAGrD,MAFwBF,EAAUT,WAAW,GAAG;AAG9C,WAAOI;AAGT,MAAI,CAACK;AACH,WAAO,GAAGD,CAAM;AAGlB,QAAM,CAACI,GAAY,GAAGC,CAAU,IAAIJ,EAAUK,MAAM,GAAG,GACjDC,IAAoB,IAAIH,KAAc,EAAE,IACxCI,IAAmBH,EAAWlB,SAAS,IAAI,IAAIkB,EAAWI,KAAK,GAAG,CAAC,KAAK;AAE9E,SAAO,GAAGT,CAAM,IAAIO,CAAiB,GAAGC,CAAgB,GAAGxB,QAAQ,UAAU,GAAG,EAAE0B,QAAAA;AACpF;AAEA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AAAA,MAAEwF,eAAe;AAAA,MAAOC,OAAO;AAAA,IAAA;AAK1C,MAAIpF,IAAO2B,GAAaI,sBAAsB;AAC9C,MAAI,CAAC/B;AACH,QAAI4B,GAAa;AACf,YAAMyD,IAAW3B,EAAsB9B,CAAW;AAClD,MAAIjC,EAAOM,WAAWoF,CAAQ,MAC5BrF,IAAOqF;AAAAA,IAEX,WAAW,CAACzC;AACV,aAAO;AAAA,QAAEuC,eAAe;AAAA,QAAOC,OAAO;AAAA,MAAA;AAAA;AAI1C,SAAKpF,IAIkB6E,EAAYlF,GAAQK,CAAI,EAC5BJ,WAAW,IACrB;AAAA,IAAEuF,eAAe;AAAA,IAAMC,OAAOzF;AAAAA,EAAAA,IAGhC;AAAA,IAAEwF,eAAe;AAAA,IAAOC,OAAO;AAAA,EAAA,IAR7B;AAAA,IAAED,eAAe;AAAA,IAAMC,OAAOzF;AAAAA,EAAAA;AASzC;AAEO,SAAS2F,EACdC,GACAhF,GACA;AACA,MAAIgF,EAAWJ;AACb,WAAO;AAGT,QAAM;AAAA,IAAEvC,gCAAAA,IAAiC;AAAA,IAAOuB,iBAAAA;AAAAA,EAAAA,IAAoB5D;AAEpE,SAAKqC,IAIE4C,EAAQrB,IAHN;AAIX;"}
1
+ {"version":3,"file":"index37.js","names":[],"sources":["../../../node_modules/date-fns/startOfWeek.js"],"sourcesContent":["import { getDefaultOptions } from \"./_lib/defaultOptions.js\";\nimport { toDate } from \"./toDate.js\";\n\n/**\n * The {@link startOfWeek} function options.\n */\n\n/**\n * @name startOfWeek\n * @category Week Helpers\n * @summary Return the start of a week for the given date.\n *\n * @description\n * Return the start of a week for the given date.\n * The result will be in the local timezone.\n *\n * @typeParam DateType - The `Date` type, the function operates on. Gets inferred from passed arguments. Allows to use extensions like [`UTCDate`](https://github.com/date-fns/utc).\n * @typeParam ResultDate - The result `Date` type, it is the type returned from the context function if it is passed, or inferred from the arguments.\n *\n * @param date - The original date\n * @param options - An object with options\n *\n * @returns The start of a week\n *\n * @example\n * // The start of a week for 2 September 2014 11:55:00:\n * const result = startOfWeek(new Date(2014, 8, 2, 11, 55, 0))\n * //=> Sun Aug 31 2014 00:00:00\n *\n * @example\n * // If the week starts on Monday, the start of the week for 2 September 2014 11:55:00:\n * const result = startOfWeek(new Date(2014, 8, 2, 11, 55, 0), { weekStartsOn: 1 })\n * //=> Mon Sep 01 2014 00:00:00\n */\nexport function startOfWeek(date, options) {\n const defaultOptions = getDefaultOptions();\n const weekStartsOn =\n options?.weekStartsOn ??\n options?.locale?.options?.weekStartsOn ??\n defaultOptions.weekStartsOn ??\n defaultOptions.locale?.options?.weekStartsOn ??\n 0;\n\n const _date = toDate(date, options?.in);\n const day = _date.getDay();\n const diff = (day < weekStartsOn ? 7 : 0) + day - weekStartsOn;\n\n _date.setDate(_date.getDate() - diff);\n _date.setHours(0, 0, 0, 0);\n return _date;\n}\n\n// Fallback for modularized imports:\nexport default startOfWeek;\n"],"x_google_ignoreList":[0],"mappings":";;;AAkCA,SAAgB,EAAY,GAAM,GAAS;CACzC,IAAM,IAAiB,GAAmB,EACpC,IACJ,GAAS,gBACT,GAAS,QAAQ,SAAS,gBAC1B,EAAe,gBACf,EAAe,QAAQ,SAAS,gBAChC,GAEI,IAAQ,EAAO,GAAM,GAAS,GAAG,EACjC,IAAM,EAAM,QAAQ,EACpB,KAAQ,IAAM,IAAe,IAAI,KAAK,IAAM;AAIlD,QAFA,EAAM,QAAQ,EAAM,SAAS,GAAG,EAAK,EACrC,EAAM,SAAS,GAAG,GAAG,GAAG,EAAE,EACnB"}
package/dist/index38.js CHANGED
@@ -1,94 +1,12 @@
1
- function c(t) {
2
- if (!t)
3
- return !1;
4
- const e = t.charCodeAt(0);
5
- return e >= 48 && e <= 57;
6
- }
7
- function l(t, e) {
8
- let n = 0;
9
- const r = Math.min(e, t.length);
10
- for (let i = 0; i < r; i += 1)
11
- c(t[i] ?? "") && (n += 1);
12
- return n;
13
- }
14
- function a(t, e) {
15
- if (e <= 0)
16
- return t.startsWith("+") ? Math.min(1, t.length) : 0;
17
- let n = 0;
18
- for (let r = 0; r < t.length; r += 1)
19
- if (c(t[r] ?? "") && (n += 1, n === e))
20
- return r + 1;
21
- return t.length;
22
- }
23
- function g(t) {
24
- return !t || c(t) ? !1 : t !== "+";
25
- }
26
- function h(t, e) {
27
- let n = e;
28
- for (; n > 0; ) {
29
- const r = t[n - 1] ?? "";
30
- if (!g(r))
31
- break;
32
- n -= 1;
33
- }
34
- return n;
35
- }
36
- function S(t, e) {
37
- let n = e;
38
- for (; n < t.length; ) {
39
- const r = t[n] ?? "";
40
- if (!g(r))
41
- break;
42
- n += 1;
43
- }
44
- return n;
45
- }
46
- function m(t) {
47
- const {
48
- value: e
49
- } = t, n = t.selectionStart ?? e.length, r = t.selectionEnd ?? n, i = n <= 1 && e.startsWith("+"), o = r <= 1 && e.startsWith("+");
50
- return {
51
- selectionStart: n,
52
- selectionEnd: r,
53
- startDigits: l(e, n),
54
- endDigits: l(e, r),
55
- preserveStartIndex: i,
56
- preserveEndIndex: o,
57
- wasAtStart: n === 0,
58
- wasAtEnd: r === e.length
59
- };
60
- }
61
- function u(t, e) {
62
- if (t.selectionStart === t.selectionEnd) {
63
- if (t.wasAtEnd) {
64
- const f = e.length;
65
- return {
66
- start: f,
67
- end: f
68
- };
69
- }
70
- if (t.wasAtStart)
71
- return {
72
- start: 0,
73
- end: 0
74
- };
75
- }
76
- const n = t.preserveStartIndex ? Math.min(t.selectionStart, e.length) : a(e, t.startDigits), r = t.preserveEndIndex ? Math.min(t.selectionEnd, e.length) : a(e, t.endDigits);
77
- let i = n, o = r;
78
- t.wasAtStart && (i = 0), t.wasAtEnd && (o = e.length), t.selectionStart === t.selectionEnd && (i = o);
79
- const d = Math.min(Math.max(i, 0), e.length), s = Math.min(Math.max(o, 0), e.length);
80
- return d > s ? {
81
- start: s,
82
- end: s
83
- } : {
84
- start: d,
85
- end: s
86
- };
87
- }
88
- export {
89
- m as captureSelectionSnapshot,
90
- u as resolveSelection,
91
- h as skipFormattingCharactersLeft,
92
- S as skipFormattingCharactersRight
93
- };
94
- //# sourceMappingURL=index38.js.map
1
+ import e from "./index37.js";
2
+ //#region ../../node_modules/date-fns/startOfISOWeek.js
3
+ function t(t, n) {
4
+ return e(t, {
5
+ ...n,
6
+ weekStartsOn: 1
7
+ });
8
+ }
9
+ //#endregion
10
+ export { t as default };
11
+
12
+ //# sourceMappingURL=index38.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index38.js","sources":["../src/components/PhoneNumberInput/selection.ts"],"sourcesContent":["function isDigitCharacter(char: string) {\n if (!char) {\n return false\n }\n const code = char.charCodeAt(0)\n return code >= 48 && code <= 57\n}\n\nfunction countDigitsBefore(value: string, index: number) {\n let count = 0\n const limit = Math.min(index, value.length)\n for (let position = 0; position < limit; position += 1) {\n if (isDigitCharacter(value[position] ?? \"\")) {\n count += 1\n }\n }\n return count\n}\n\nfunction findIndexForDigitCount(value: string, digitCount: number) {\n if (digitCount <= 0) {\n return value.startsWith(\"+\") ? Math.min(1, value.length) : 0\n }\n\n let seen = 0\n for (let index = 0; index < value.length; index += 1) {\n if (isDigitCharacter(value[index] ?? \"\")) {\n seen += 1\n if (seen === digitCount) {\n return index + 1\n }\n }\n }\n\n return value.length\n}\n\nfunction isFormattingCharacter(char: string) {\n if (!char) {\n return false\n }\n if (isDigitCharacter(char)) {\n return false\n }\n return char !== \"+\"\n}\n\nexport function skipFormattingCharactersLeft(value: string, index: number) {\n let position = index\n while (position > 0) {\n const next = value[position - 1] ?? \"\"\n if (!isFormattingCharacter(next)) {\n break\n }\n position -= 1\n }\n return position\n}\n\nexport function skipFormattingCharactersRight(value: string, index: number) {\n let position = index\n while (position < value.length) {\n const next = value[position] ?? \"\"\n if (!isFormattingCharacter(next)) {\n break\n }\n position += 1\n }\n return position\n}\n\ntype SelectionSnapshot = {\n selectionStart: number\n selectionEnd: number\n startDigits: number\n endDigits: number\n preserveStartIndex: boolean\n preserveEndIndex: boolean\n wasAtStart: boolean\n wasAtEnd: boolean\n}\n\nexport function captureSelectionSnapshot(input: HTMLInputElement): SelectionSnapshot {\n const { value } = input\n const selectionStart = input.selectionStart ?? value.length\n const selectionEnd = input.selectionEnd ?? selectionStart\n const preserveStartIndex = selectionStart <= 1 && value.startsWith(\"+\")\n const preserveEndIndex = selectionEnd <= 1 && value.startsWith(\"+\")\n\n return {\n selectionStart,\n selectionEnd,\n startDigits: countDigitsBefore(value, selectionStart),\n endDigits: countDigitsBefore(value, selectionEnd),\n preserveStartIndex,\n preserveEndIndex,\n wasAtStart: selectionStart === 0,\n wasAtEnd: selectionEnd === value.length,\n }\n}\n\nexport function resolveSelection(snapshot: SelectionSnapshot, value: string) {\n if (snapshot.selectionStart === snapshot.selectionEnd) {\n if (snapshot.wasAtEnd) {\n const end = value.length\n return { start: end, end }\n }\n if (snapshot.wasAtStart) {\n return { start: 0, end: 0 }\n }\n }\n\n const start = snapshot.preserveStartIndex\n ? Math.min(snapshot.selectionStart, value.length)\n : findIndexForDigitCount(value, snapshot.startDigits)\n const end = snapshot.preserveEndIndex\n ? Math.min(snapshot.selectionEnd, value.length)\n : findIndexForDigitCount(value, snapshot.endDigits)\n\n let resolvedStart = start\n let resolvedEnd = end\n\n if (snapshot.wasAtStart) {\n resolvedStart = 0\n }\n\n if (snapshot.wasAtEnd) {\n resolvedEnd = value.length\n }\n\n if (snapshot.selectionStart === snapshot.selectionEnd) {\n resolvedStart = resolvedEnd\n }\n\n const clampedStart = Math.min(Math.max(resolvedStart, 0), value.length)\n const clampedEnd = Math.min(Math.max(resolvedEnd, 0), value.length)\n\n if (clampedStart > clampedEnd) {\n return { start: clampedEnd, end: clampedEnd }\n }\n\n return { start: clampedStart, end: clampedEnd }\n}\n\n"],"names":["isDigitCharacter","char","code","charCodeAt","countDigitsBefore","value","index","count","limit","Math","min","length","position","findIndexForDigitCount","digitCount","startsWith","seen","isFormattingCharacter","skipFormattingCharactersLeft","next","skipFormattingCharactersRight","captureSelectionSnapshot","input","selectionStart","selectionEnd","preserveStartIndex","preserveEndIndex","startDigits","endDigits","wasAtStart","wasAtEnd","resolveSelection","snapshot","end","start","resolvedStart","resolvedEnd","clampedStart","max","clampedEnd"],"mappings":"AAAA,SAASA,EAAiBC,GAAc;AACtC,MAAI,CAACA;AACH,WAAO;AAET,QAAMC,IAAOD,EAAKE,WAAW,CAAC;AAC9B,SAAOD,KAAQ,MAAMA,KAAQ;AAC/B;AAEA,SAASE,EAAkBC,GAAeC,GAAe;AACvD,MAAIC,IAAQ;AACZ,QAAMC,IAAQC,KAAKC,IAAIJ,GAAOD,EAAMM,MAAM;AAC1C,WAASC,IAAW,GAAGA,IAAWJ,GAAOI,KAAY;AACnD,IAAIZ,EAAiBK,EAAMO,CAAQ,KAAK,EAAE,MACxCL,KAAS;AAGb,SAAOA;AACT;AAEA,SAASM,EAAuBR,GAAeS,GAAoB;AACjE,MAAIA,KAAc;AAChB,WAAOT,EAAMU,WAAW,GAAG,IAAIN,KAAKC,IAAI,GAAGL,EAAMM,MAAM,IAAI;AAG7D,MAAIK,IAAO;AACX,WAASV,IAAQ,GAAGA,IAAQD,EAAMM,QAAQL,KAAS;AACjD,QAAIN,EAAiBK,EAAMC,CAAK,KAAK,EAAE,MACrCU,KAAQ,GACJA,MAASF;AACX,aAAOR,IAAQ;AAKrB,SAAOD,EAAMM;AACf;AAEA,SAASM,EAAsBhB,GAAc;AAI3C,SAHI,CAACA,KAGDD,EAAiBC,CAAI,IAChB,KAEFA,MAAS;AAClB;AAEO,SAASiB,EAA6Bb,GAAeC,GAAe;AACzE,MAAIM,IAAWN;AACf,SAAOM,IAAW,KAAG;AACnB,UAAMO,IAAOd,EAAMO,IAAW,CAAC,KAAK;AACpC,QAAI,CAACK,EAAsBE,CAAI;AAC7B;AAEFP,IAAAA,KAAY;AAAA,EACd;AACA,SAAOA;AACT;AAEO,SAASQ,EAA8Bf,GAAeC,GAAe;AAC1E,MAAIM,IAAWN;AACf,SAAOM,IAAWP,EAAMM,UAAQ;AAC9B,U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AElB,EAAID,EAASH,eACXM,IAAgB,IAGdH,EAASF,aACXM,IAAc/B,EAAMM,SAGlBqB,EAAST,mBAAmBS,EAASR,iBACvCW,IAAgBC;AAGlB,QAAMC,IAAe5B,KAAKC,IAAID,KAAK6B,IAAIH,GAAe,CAAC,GAAG9B,EAAMM,MAAM,GAChE4B,IAAa9B,KAAKC,IAAID,KAAK6B,IAAIF,GAAa,CAAC,GAAG/B,EAAMM,MAAM;AAElE,SAAI0B,IAAeE,IACV;AAAA,IAAEL,OAAOK;AAAAA,IAAYN,KAAKM;AAAAA,EAAAA,IAG5B;AAAA,IAAEL,OAAOG;AAAAA,IAAcJ,KAAKM;AAAAA,EAAAA;AACrC;"}
1
+ {"version":3,"file":"index38.js","names":[],"sources":["../../../node_modules/date-fns/startOfISOWeek.js"],"sourcesContent":["import { startOfWeek } from \"./startOfWeek.js\";\n\n/**\n * The {@link startOfISOWeek} function options.\n */\n\n/**\n * @name startOfISOWeek\n * @category ISO Week Helpers\n * @summary Return the start of an ISO week for the given date.\n *\n * @description\n * Return the start of an ISO week for the given date.\n * The result will be in the local timezone.\n *\n * ISO week-numbering year: http://en.wikipedia.org/wiki/ISO_week_date\n *\n * @typeParam DateType - The `Date` type, the function operates on. Gets inferred from passed arguments. Allows to use extensions like [`UTCDate`](https://github.com/date-fns/utc).\n * @typeParam ResultDate - The result `Date` type, it is the type returned from the context function if it is passed, or inferred from the arguments.\n *\n * @param date - The original date\n * @param options - An object with options\n *\n * @returns The start of an ISO week\n *\n * @example\n * // The start of an ISO week for 2 September 2014 11:55:00:\n * const result = startOfISOWeek(new Date(2014, 8, 2, 11, 55, 0))\n * //=> Mon Sep 01 2014 00:00:00\n */\nexport function startOfISOWeek(date, options) {\n return startOfWeek(date, { ...options, weekStartsOn: 1 });\n}\n\n// Fallback for modularized imports:\nexport default startOfISOWeek;\n"],"x_google_ignoreList":[0],"mappings":";;AA8BA,SAAgB,EAAe,GAAM,GAAS;AAC5C,QAAO,EAAY,GAAM;EAAE,GAAG;EAAS,cAAc;EAAG,CAAC"}