@rpcbase/ui 0.183.0 → 0.185.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 (640) hide show
  1. package/dist/index10.js +25 -24
  2. package/dist/index10.js.map +1 -1
  3. package/dist/index100.js +107 -5
  4. package/dist/index100.js.map +1 -1
  5. package/dist/index101.js +262 -4
  6. package/dist/index101.js.map +1 -1
  7. package/dist/index102.js +9 -4
  8. package/dist/index102.js.map +1 -1
  9. package/dist/index103.js +42 -6
  10. package/dist/index103.js.map +1 -1
  11. package/dist/index104.js +4 -145
  12. package/dist/index104.js.map +1 -1
  13. package/dist/index105.js +45 -38
  14. package/dist/index105.js.map +1 -1
  15. package/dist/index106.js +52 -5
  16. package/dist/index106.js.map +1 -1
  17. package/dist/index107.js +4 -7
  18. package/dist/index107.js.map +1 -1
  19. package/dist/index108.js +3 -12
  20. package/dist/index108.js.map +1 -1
  21. package/dist/index109.js +15 -13
  22. package/dist/index109.js.map +1 -1
  23. package/dist/index11.js +34 -66
  24. package/dist/index11.js.map +1 -1
  25. package/dist/index110.js +5 -7
  26. package/dist/index110.js.map +1 -1
  27. package/dist/index111.js +7 -31
  28. package/dist/index111.js.map +1 -1
  29. package/dist/index112.js +16 -10
  30. package/dist/index112.js.map +1 -1
  31. package/dist/index113.js +4 -10
  32. package/dist/index113.js.map +1 -1
  33. package/dist/index114.js +4 -8
  34. package/dist/index114.js.map +1 -1
  35. package/dist/index115.js +5 -13
  36. package/dist/index115.js.map +1 -1
  37. package/dist/index116.js +5 -101
  38. package/dist/index116.js.map +1 -1
  39. package/dist/index117.js +5 -20
  40. package/dist/index117.js.map +1 -1
  41. package/dist/index118.js +4 -53
  42. package/dist/index118.js.map +1 -1
  43. package/dist/index119.js +6 -72
  44. package/dist/index119.js.map +1 -1
  45. package/dist/index12.js +556 -525
  46. package/dist/index12.js.map +1 -1
  47. package/dist/index120.js +24 -9
  48. package/dist/index120.js.map +1 -1
  49. package/dist/index121.js +6 -20
  50. package/dist/index121.js.map +1 -1
  51. package/dist/index122.js +4 -16
  52. package/dist/index122.js.map +1 -1
  53. package/dist/index123.js +6 -23
  54. package/dist/index123.js.map +1 -1
  55. package/dist/index124.js +5 -6
  56. package/dist/index124.js.map +1 -1
  57. package/dist/index125.js +4 -5
  58. package/dist/index125.js.map +1 -1
  59. package/dist/index126.js +5 -23
  60. package/dist/index126.js.map +1 -1
  61. package/dist/index127.js +5 -35
  62. package/dist/index127.js.map +1 -1
  63. package/dist/index128.js +9 -16
  64. package/dist/index128.js.map +1 -1
  65. package/dist/index129.js +5 -6
  66. package/dist/index129.js.map +1 -1
  67. package/dist/index13.js +128 -118
  68. package/dist/index13.js.map +1 -1
  69. package/dist/index130.js +4 -4
  70. package/dist/index130.js.map +1 -1
  71. package/dist/index131.js +4 -4
  72. package/dist/index131.js.map +1 -1
  73. package/dist/index132.js +6 -4
  74. package/dist/index132.js.map +1 -1
  75. package/dist/index133.js +145 -4
  76. package/dist/index133.js.map +1 -1
  77. package/dist/index134.js +39 -3
  78. package/dist/index134.js.map +1 -1
  79. package/dist/index135.js +4 -6
  80. package/dist/index135.js.map +1 -1
  81. package/dist/index136.js +8 -24
  82. package/dist/index136.js.map +1 -1
  83. package/dist/index137.js +13 -7
  84. package/dist/index137.js.map +1 -1
  85. package/dist/index138.js +13 -6
  86. package/dist/index138.js.map +1 -1
  87. package/dist/index139.js +7 -5
  88. package/dist/index139.js.map +1 -1
  89. package/dist/index14.js +74 -74
  90. package/dist/index14.js.map +1 -1
  91. package/dist/index140.js +31 -3
  92. package/dist/index140.js.map +1 -1
  93. package/dist/index141.js +10 -3
  94. package/dist/index141.js.map +1 -1
  95. package/dist/index142.js +10 -4
  96. package/dist/index142.js.map +1 -1
  97. package/dist/index143.js +8 -3
  98. package/dist/index143.js.map +1 -1
  99. package/dist/index144.js +13 -4
  100. package/dist/index144.js.map +1 -1
  101. package/dist/index145.js +101 -3
  102. package/dist/index145.js.map +1 -1
  103. package/dist/index146.js +20 -4
  104. package/dist/index146.js.map +1 -1
  105. package/dist/index147.js +53 -3
  106. package/dist/index147.js.map +1 -1
  107. package/dist/index148.js +71 -45
  108. package/dist/index148.js.map +1 -1
  109. package/dist/index149.js +9 -205
  110. package/dist/index149.js.map +1 -1
  111. package/dist/index15.js +763 -624
  112. package/dist/index15.js.map +1 -1
  113. package/dist/index150.js +20 -21
  114. package/dist/index150.js.map +1 -1
  115. package/dist/index151.js +16 -24
  116. package/dist/index151.js.map +1 -1
  117. package/dist/index152.js +23 -399
  118. package/dist/index152.js.map +1 -1
  119. package/dist/index153.js +6 -46
  120. package/dist/index153.js.map +1 -1
  121. package/dist/index154.js +5 -605
  122. package/dist/index154.js.map +1 -1
  123. package/dist/index155.js +23 -5
  124. package/dist/index155.js.map +1 -1
  125. package/dist/index156.js +34 -68
  126. package/dist/index156.js.map +1 -1
  127. package/dist/index157.js +16 -2
  128. package/dist/index157.js.map +1 -1
  129. package/dist/index158.js +6 -363
  130. package/dist/index158.js.map +1 -1
  131. package/dist/index159.js +4 -261
  132. package/dist/index159.js.map +1 -1
  133. package/dist/index16.js +20 -22
  134. package/dist/index16.js.map +1 -1
  135. package/dist/index160.js +4 -60
  136. package/dist/index160.js.map +1 -1
  137. package/dist/index161.js +4 -46
  138. package/dist/index161.js.map +1 -1
  139. package/dist/index162.js +4 -169
  140. package/dist/index162.js.map +1 -1
  141. package/dist/index163.js +3 -109
  142. package/dist/index163.js.map +1 -1
  143. package/dist/index164.js +6 -24
  144. package/dist/index164.js.map +1 -1
  145. package/dist/index165.js +24 -8
  146. package/dist/index165.js.map +1 -1
  147. package/dist/index166.js +7 -4
  148. package/dist/index166.js.map +1 -1
  149. package/dist/index167.js +6 -5
  150. package/dist/index167.js.map +1 -1
  151. package/dist/index168.js +5 -4
  152. package/dist/index168.js.map +1 -1
  153. package/dist/index169.js +3 -466
  154. package/dist/index169.js.map +1 -1
  155. package/dist/index17.js +17 -17
  156. package/dist/index17.js.map +1 -1
  157. package/dist/index170.js +3 -185
  158. package/dist/index170.js.map +1 -1
  159. package/dist/index171.js +4 -107
  160. package/dist/index171.js.map +1 -1
  161. package/dist/index172.js +3 -262
  162. package/dist/index172.js.map +1 -1
  163. package/dist/index173.js +4 -9
  164. package/dist/index173.js.map +1 -1
  165. package/dist/index174.js +3 -42
  166. package/dist/index174.js.map +1 -1
  167. package/dist/index175.js +3 -4
  168. package/dist/index175.js.map +1 -1
  169. package/dist/index176.js +3 -58
  170. package/dist/index176.js.map +1 -1
  171. package/dist/index177.js +46 -8
  172. package/dist/index177.js.map +1 -1
  173. package/dist/index178.js +201 -62
  174. package/dist/index178.js.map +1 -1
  175. package/dist/index179.js +22 -20
  176. package/dist/index179.js.map +1 -1
  177. package/dist/index18.js +411 -341
  178. package/dist/index18.js.map +1 -1
  179. package/dist/index180.js +24 -16
  180. package/dist/index180.js.map +1 -1
  181. package/dist/index181.js +398 -4
  182. package/dist/index181.js.map +1 -1
  183. package/dist/index182.js +604 -4
  184. package/dist/index182.js.map +1 -1
  185. package/dist/index183.js +13 -6
  186. package/dist/index183.js.map +1 -1
  187. package/dist/index184.js +154 -4
  188. package/dist/index184.js.map +1 -1
  189. package/dist/index185.js +30 -7
  190. package/dist/index185.js.map +1 -1
  191. package/dist/index186.js +9 -17
  192. package/dist/index186.js.map +1 -1
  193. package/dist/index187.js +47 -5
  194. package/dist/index187.js.map +1 -1
  195. package/dist/index188.js +11 -5
  196. package/dist/index188.js.map +1 -1
  197. package/dist/index189.js +44 -13
  198. package/dist/index189.js.map +1 -1
  199. package/dist/index19.js +626 -660
  200. package/dist/index19.js.map +1 -1
  201. package/dist/index190.js +95 -10
  202. package/dist/index190.js.map +1 -1
  203. package/dist/index191.js +86 -14
  204. package/dist/index191.js.map +1 -1
  205. package/dist/index192.js +105 -14
  206. package/dist/index192.js.map +1 -1
  207. package/dist/index193.js +52 -5
  208. package/dist/index193.js.map +1 -1
  209. package/dist/index194.js +11 -6
  210. package/dist/index194.js.map +1 -1
  211. package/dist/index195.js +37 -7
  212. package/dist/index195.js.map +1 -1
  213. package/dist/index196.js +8 -6
  214. package/dist/index196.js.map +1 -1
  215. package/dist/index197.js +116 -9
  216. package/dist/index197.js.map +1 -1
  217. package/dist/index198.js +17 -5
  218. package/dist/index198.js.map +1 -1
  219. package/dist/index199.js +15 -5
  220. package/dist/index199.js.map +1 -1
  221. package/dist/index20.js +442 -634
  222. package/dist/index20.js.map +1 -1
  223. package/dist/index200.js +3 -9
  224. package/dist/index200.js.map +1 -1
  225. package/dist/index201.js +36 -5
  226. package/dist/index201.js.map +1 -1
  227. package/dist/index202.js +20 -5
  228. package/dist/index202.js.map +1 -1
  229. package/dist/index203.js +9 -4
  230. package/dist/index203.js.map +1 -1
  231. package/dist/index204.js +8 -11
  232. package/dist/index204.js.map +1 -1
  233. package/dist/index205.js +19 -10
  234. package/dist/index205.js.map +1 -1
  235. package/dist/index206.js +28 -10
  236. package/dist/index206.js.map +1 -1
  237. package/dist/index207.js +16 -11
  238. package/dist/index207.js.map +1 -1
  239. package/dist/index208.js +58 -11
  240. package/dist/index208.js.map +1 -1
  241. package/dist/index209.js +8 -10
  242. package/dist/index209.js.map +1 -1
  243. package/dist/index21.js +254 -200
  244. package/dist/index21.js.map +1 -1
  245. package/dist/index210.js +66 -7
  246. package/dist/index210.js.map +1 -1
  247. package/dist/index211.js +19 -6
  248. package/dist/index211.js.map +1 -1
  249. package/dist/index212.js +16 -5
  250. package/dist/index212.js.map +1 -1
  251. package/dist/index213.js +5 -6
  252. package/dist/index213.js.map +1 -1
  253. package/dist/index214.js +5 -7
  254. package/dist/index214.js.map +1 -1
  255. package/dist/index215.js +6 -6
  256. package/dist/index215.js.map +1 -1
  257. package/dist/index216.js +4 -55
  258. package/dist/index216.js.map +1 -1
  259. package/dist/index217.js +7 -16
  260. package/dist/index217.js.map +1 -1
  261. package/dist/index218.js +17 -7
  262. package/dist/index218.js.map +1 -1
  263. package/dist/index219.js +5 -10
  264. package/dist/index219.js.map +1 -1
  265. package/dist/index22.js +1 -1
  266. package/dist/index22.js.map +1 -1
  267. package/dist/index220.js +5 -10
  268. package/dist/index220.js.map +1 -1
  269. package/dist/index221.js +13 -21
  270. package/dist/index221.js.map +1 -1
  271. package/dist/index222.js +10 -10
  272. package/dist/index222.js.map +1 -1
  273. package/dist/index223.js +14 -9
  274. package/dist/index223.js.map +1 -1
  275. package/dist/index224.js +14 -9
  276. package/dist/index224.js.map +1 -1
  277. package/dist/index225.js +5 -4
  278. package/dist/index225.js.map +1 -1
  279. package/dist/index226.js +6 -5
  280. package/dist/index226.js.map +1 -1
  281. package/dist/index227.js +7 -16
  282. package/dist/index227.js.map +1 -1
  283. package/dist/index228.js +6 -9
  284. package/dist/index228.js.map +1 -1
  285. package/dist/index229.js +9 -18
  286. package/dist/index229.js.map +1 -1
  287. package/dist/index23.js +27 -34
  288. package/dist/index23.js.map +1 -1
  289. package/dist/index230.js +5 -15
  290. package/dist/index230.js.map +1 -1
  291. package/dist/index231.js +5 -12
  292. package/dist/index231.js.map +1 -1
  293. package/dist/index232.js +9 -29
  294. package/dist/index232.js.map +1 -1
  295. package/dist/index233.js +5 -12
  296. package/dist/index233.js.map +1 -1
  297. package/dist/index234.js +5 -25
  298. package/dist/index234.js.map +1 -1
  299. package/dist/index235.js +4 -5
  300. package/dist/index235.js.map +1 -1
  301. package/dist/index236.js +11 -24
  302. package/dist/index236.js.map +1 -1
  303. package/dist/index237.js +10 -28
  304. package/dist/index237.js.map +1 -1
  305. package/dist/index238.js +11 -5
  306. package/dist/index238.js.map +1 -1
  307. package/dist/index239.js +11 -67
  308. package/dist/index239.js.map +1 -1
  309. package/dist/index24.js +219 -222
  310. package/dist/index24.js.map +1 -1
  311. package/dist/index240.js +11 -180
  312. package/dist/index240.js.map +1 -1
  313. package/dist/index241.js +10 -46
  314. package/dist/index241.js.map +1 -1
  315. package/dist/index242.js +7 -13
  316. package/dist/index242.js.map +1 -1
  317. package/dist/index243.js +6 -154
  318. package/dist/index243.js.map +1 -1
  319. package/dist/index244.js +5 -30
  320. package/dist/index244.js.map +1 -1
  321. package/dist/index245.js +6 -9
  322. package/dist/index245.js.map +1 -1
  323. package/dist/index246.js +7 -47
  324. package/dist/index246.js.map +1 -1
  325. package/dist/index247.js +6 -11
  326. package/dist/index247.js.map +1 -1
  327. package/dist/index248.js +54 -43
  328. package/dist/index248.js.map +1 -1
  329. package/dist/index249.js +13 -92
  330. package/dist/index249.js.map +1 -1
  331. package/dist/index25.js +46 -50
  332. package/dist/index25.js.map +1 -1
  333. package/dist/index250.js +7 -86
  334. package/dist/index250.js.map +1 -1
  335. package/dist/index251.js +8 -103
  336. package/dist/index251.js.map +1 -1
  337. package/dist/index252.js +9 -51
  338. package/dist/index252.js.map +1 -1
  339. package/dist/index253.js +21 -11
  340. package/dist/index253.js.map +1 -1
  341. package/dist/index254.js +10 -37
  342. package/dist/index254.js.map +1 -1
  343. package/dist/index255.js +8 -7
  344. package/dist/index255.js.map +1 -1
  345. package/dist/index256.js +9 -116
  346. package/dist/index256.js.map +1 -1
  347. package/dist/index257.js +4 -17
  348. package/dist/index257.js.map +1 -1
  349. package/dist/index258.js +5 -15
  350. package/dist/index258.js.map +1 -1
  351. package/dist/index259.js +16 -3
  352. package/dist/index259.js.map +1 -1
  353. package/dist/index260.js +9 -36
  354. package/dist/index260.js.map +1 -1
  355. package/dist/index261.js +18 -20
  356. package/dist/index261.js.map +1 -1
  357. package/dist/index262.js +15 -9
  358. package/dist/index262.js.map +1 -1
  359. package/dist/index263.js +12 -8
  360. package/dist/index263.js.map +1 -1
  361. package/dist/index264.js +28 -18
  362. package/dist/index264.js.map +1 -1
  363. package/dist/index265.js +11 -27
  364. package/dist/index265.js.map +1 -1
  365. package/dist/index266.js +23 -14
  366. package/dist/index266.js.map +1 -1
  367. package/dist/index267.js +5 -4
  368. package/dist/index267.js.map +1 -1
  369. package/dist/index268.js +24 -18
  370. package/dist/index268.js.map +1 -1
  371. package/dist/index269.js +29 -13
  372. package/dist/index269.js.map +1 -1
  373. package/dist/index270.js +5 -5
  374. package/dist/index270.js.map +1 -1
  375. package/dist/index271.js +68 -3
  376. package/dist/index271.js.map +1 -1
  377. package/dist/index272.js +179 -22
  378. package/dist/index272.js.map +1 -1
  379. package/dist/index273.js +43 -109
  380. package/dist/index273.js.map +1 -1
  381. package/dist/index274.js +20 -15
  382. package/dist/index274.js.map +1 -1
  383. package/dist/index275.js +4 -524
  384. package/dist/index275.js.map +1 -1
  385. package/dist/index276.js +18 -127
  386. package/dist/index276.js.map +1 -1
  387. package/dist/index277.js +12 -133
  388. package/dist/index277.js.map +1 -1
  389. package/dist/index278.js +5 -21
  390. package/dist/index278.js.map +1 -1
  391. package/dist/index279.js +3 -6
  392. package/dist/index279.js.map +1 -1
  393. package/dist/index28.js +3 -37
  394. package/dist/index28.js.map +1 -1
  395. package/dist/index280.js +23 -5
  396. package/dist/index280.js.map +1 -1
  397. package/dist/index281.js +113 -4
  398. package/dist/index281.js.map +1 -1
  399. package/dist/index282.js +15 -15
  400. package/dist/index282.js.map +1 -1
  401. package/dist/index283.js +524 -8
  402. package/dist/index283.js.map +1 -1
  403. package/dist/index284.js +127 -5
  404. package/dist/index284.js.map +1 -1
  405. package/dist/index285.js +133 -4
  406. package/dist/index285.js.map +1 -1
  407. package/dist/index286.js +5 -545
  408. package/dist/index286.js.map +1 -1
  409. package/dist/index287.js +6 -47
  410. package/dist/index287.js.map +1 -1
  411. package/dist/index288.js +4 -18
  412. package/dist/index288.js.map +1 -1
  413. package/dist/index289.js +15 -6
  414. package/dist/index289.js.map +1 -1
  415. package/dist/index29.js +37 -3
  416. package/dist/index29.js.map +1 -1
  417. package/dist/index290.js +8 -8
  418. package/dist/index290.js.map +1 -1
  419. package/dist/index291.js +5 -7
  420. package/dist/index291.js.map +1 -1
  421. package/dist/index292.js +4 -8
  422. package/dist/index292.js.map +1 -1
  423. package/dist/index293.js +545 -12
  424. package/dist/index293.js.map +1 -1
  425. package/dist/index294.js +47 -10
  426. package/dist/index294.js.map +1 -1
  427. package/dist/index295.js +17 -13
  428. package/dist/index295.js.map +1 -1
  429. package/dist/index296.js +7 -69
  430. package/dist/index296.js.map +1 -1
  431. package/dist/index297.js +9 -9
  432. package/dist/index297.js.map +1 -1
  433. package/dist/index298.js +8 -14
  434. package/dist/index298.js.map +1 -1
  435. package/dist/index299.js +9 -66
  436. package/dist/index299.js.map +1 -1
  437. package/dist/index3.js.map +1 -1
  438. package/dist/index30.js +3 -125
  439. package/dist/index30.js.map +1 -1
  440. package/dist/index300.js +12 -64
  441. package/dist/index300.js.map +1 -1
  442. package/dist/index301.js +9 -4
  443. package/dist/index301.js.map +1 -1
  444. package/dist/index302.js +14 -56
  445. package/dist/index302.js.map +1 -1
  446. package/dist/index303.js +65 -68
  447. package/dist/index303.js.map +1 -1
  448. package/dist/index304.js +68 -30
  449. package/dist/index304.js.map +1 -1
  450. package/dist/index305.js +9 -9
  451. package/dist/index305.js.map +1 -1
  452. package/dist/index306.js +13 -152
  453. package/dist/index306.js.map +1 -1
  454. package/dist/index307.js +65 -107
  455. package/dist/index307.js.map +1 -1
  456. package/dist/index308.js +4 -3
  457. package/dist/index308.js.map +1 -1
  458. package/dist/index309.js +56 -23
  459. package/dist/index309.js.map +1 -1
  460. package/dist/index31.js +120 -227
  461. package/dist/index31.js.map +1 -1
  462. package/dist/index310.js +68 -16
  463. package/dist/index310.js.map +1 -1
  464. package/dist/index311.js +31 -29
  465. package/dist/index311.js.map +1 -1
  466. package/dist/index312.js +9 -13
  467. package/dist/index312.js.map +1 -1
  468. package/dist/index313.js +153 -7
  469. package/dist/index313.js.map +1 -1
  470. package/dist/index314.js +107 -22
  471. package/dist/index314.js.map +1 -1
  472. package/dist/index315.js +4 -13
  473. package/dist/index315.js.map +1 -1
  474. package/dist/index316.js +22 -27
  475. package/dist/index316.js.map +1 -1
  476. package/dist/index317.js +16 -5
  477. package/dist/index317.js.map +1 -1
  478. package/dist/index318.js +32 -0
  479. package/dist/index318.js.map +1 -0
  480. package/dist/index319.js +16 -0
  481. package/dist/index319.js.map +1 -0
  482. package/dist/index32.js +229 -21
  483. package/dist/index32.js.map +1 -1
  484. package/dist/index320.js +10 -0
  485. package/dist/index320.js.map +1 -0
  486. package/dist/index321.js +26 -0
  487. package/dist/index321.js.map +1 -0
  488. package/dist/index322.js +16 -0
  489. package/dist/index322.js.map +1 -0
  490. package/dist/index323.js +31 -0
  491. package/dist/index323.js.map +1 -0
  492. package/dist/index324.js +8 -0
  493. package/dist/index324.js.map +1 -0
  494. package/dist/index33.js +23 -50
  495. package/dist/index33.js.map +1 -1
  496. package/dist/index34.js +50 -2640
  497. package/dist/index34.js.map +1 -1
  498. package/dist/index35.js +2598 -351
  499. package/dist/index35.js.map +1 -1
  500. package/dist/index36.js +375 -214
  501. package/dist/index36.js.map +1 -1
  502. package/dist/index37.js +230 -19
  503. package/dist/index37.js.map +1 -1
  504. package/dist/index38.js +18 -138
  505. package/dist/index38.js.map +1 -1
  506. package/dist/index39.js +113 -170
  507. package/dist/index39.js.map +1 -1
  508. package/dist/index4.js +17 -15
  509. package/dist/index4.js.map +1 -1
  510. package/dist/index40.js +209 -64
  511. package/dist/index40.js.map +1 -1
  512. package/dist/index41.js +86 -94
  513. package/dist/index41.js.map +1 -1
  514. package/dist/index42.js +118 -5
  515. package/dist/index42.js.map +1 -1
  516. package/dist/index43.js +5 -843
  517. package/dist/index43.js.map +1 -1
  518. package/dist/index44.js +832 -54
  519. package/dist/index44.js.map +1 -1
  520. package/dist/index45.js +57 -8
  521. package/dist/index45.js.map +1 -1
  522. package/dist/index46.js +8 -2
  523. package/dist/index46.js.map +1 -1
  524. package/dist/index47.js +2 -24
  525. package/dist/index47.js.map +1 -1
  526. package/dist/index48.js +11 -233
  527. package/dist/index48.js.map +1 -1
  528. package/dist/index49.js +19 -205
  529. package/dist/index49.js.map +1 -1
  530. package/dist/index5.js +34 -34
  531. package/dist/index5.js.map +1 -1
  532. package/dist/index50.js +7 -3
  533. package/dist/index50.js.map +1 -1
  534. package/dist/index51.js +2 -7
  535. package/dist/index51.js.map +1 -1
  536. package/dist/index52.js +22 -46
  537. package/dist/index52.js.map +1 -1
  538. package/dist/index53.js +232 -25
  539. package/dist/index53.js.map +1 -1
  540. package/dist/index54.js +50 -47
  541. package/dist/index54.js.map +1 -1
  542. package/dist/index55.js +2 -8
  543. package/dist/index55.js.map +1 -1
  544. package/dist/index56.js +2 -15
  545. package/dist/index56.js.map +1 -1
  546. package/dist/index57.js +5 -133
  547. package/dist/index57.js.map +1 -1
  548. package/dist/index58.js +7 -10
  549. package/dist/index58.js.map +1 -1
  550. package/dist/index59.js +5 -216
  551. package/dist/index59.js.map +1 -1
  552. package/dist/index6.js +154 -120
  553. package/dist/index6.js.map +1 -1
  554. package/dist/index60.js +2 -13
  555. package/dist/index60.js.map +1 -1
  556. package/dist/index61.js +2 -34
  557. package/dist/index61.js.map +1 -1
  558. package/dist/index62.js +6 -46
  559. package/dist/index62.js.map +1 -1
  560. package/dist/index63.js +33 -7
  561. package/dist/index63.js.map +1 -1
  562. package/dist/index64.js +24 -47
  563. package/dist/index64.js.map +1 -1
  564. package/dist/index65.js +8 -4
  565. package/dist/index65.js.map +1 -1
  566. package/dist/index66.js +11 -5
  567. package/dist/index66.js.map +1 -1
  568. package/dist/index67.js +202 -25
  569. package/dist/index67.js.map +1 -1
  570. package/dist/index68.js +4 -50
  571. package/dist/index68.js.map +1 -1
  572. package/dist/index69.js +48 -9
  573. package/dist/index69.js.map +1 -1
  574. package/dist/index7.js +29 -24
  575. package/dist/index7.js.map +1 -1
  576. package/dist/index70.js +49 -10
  577. package/dist/index70.js.map +1 -1
  578. package/dist/index71.js +7 -53
  579. package/dist/index71.js.map +1 -1
  580. package/dist/index72.js +14 -5
  581. package/dist/index72.js.map +1 -1
  582. package/dist/index73.js +133 -7
  583. package/dist/index73.js.map +1 -1
  584. package/dist/index74.js +10 -5
  585. package/dist/index74.js.map +1 -1
  586. package/dist/index75.js +217 -2
  587. package/dist/index75.js.map +1 -1
  588. package/dist/index76.js +13 -2
  589. package/dist/index76.js.map +1 -1
  590. package/dist/index77.js +47 -52
  591. package/dist/index77.js.map +1 -1
  592. package/dist/index78.js +49 -4
  593. package/dist/index78.js.map +1 -1
  594. package/dist/index79.js +4 -5
  595. package/dist/index79.js.map +1 -1
  596. package/dist/index8.js +21 -24
  597. package/dist/index8.js.map +1 -1
  598. package/dist/index80.js +5 -15
  599. package/dist/index80.js.map +1 -1
  600. package/dist/index81.js +28 -6
  601. package/dist/index81.js.map +1 -1
  602. package/dist/index82.js +50 -8
  603. package/dist/index82.js.map +1 -1
  604. package/dist/index83.js +9 -17
  605. package/dist/index83.js.map +1 -1
  606. package/dist/index84.js +5 -4
  607. package/dist/index84.js.map +1 -1
  608. package/dist/index85.js +68 -4
  609. package/dist/index85.js.map +1 -1
  610. package/dist/index86.js +2 -6
  611. package/dist/index86.js.map +1 -1
  612. package/dist/index87.js +363 -5
  613. package/dist/index87.js.map +1 -1
  614. package/dist/index88.js +261 -4
  615. package/dist/index88.js.map +1 -1
  616. package/dist/index89.js +60 -4
  617. package/dist/index89.js.map +1 -1
  618. package/dist/index9.js +138 -187
  619. package/dist/index9.js.map +1 -1
  620. package/dist/index90.js +46 -6
  621. package/dist/index90.js.map +1 -1
  622. package/dist/index91.js +169 -24
  623. package/dist/index91.js.map +1 -1
  624. package/dist/index92.js +109 -6
  625. package/dist/index92.js.map +1 -1
  626. package/dist/index93.js +24 -4
  627. package/dist/index93.js.map +1 -1
  628. package/dist/index94.js +8 -7
  629. package/dist/index94.js.map +1 -1
  630. package/dist/index95.js +4 -5
  631. package/dist/index95.js.map +1 -1
  632. package/dist/index96.js +5 -4
  633. package/dist/index96.js.map +1 -1
  634. package/dist/index97.js +4 -5
  635. package/dist/index97.js.map +1 -1
  636. package/dist/index98.js +466 -4
  637. package/dist/index98.js.map +1 -1
  638. package/dist/index99.js +185 -8
  639. package/dist/index99.js.map +1 -1
  640. package/package.json +1 -1
@@ -1 +1 @@
1
- {"version":3,"file":"index248.js","sources":["../../../node_modules/libphonenumber-js/es6/helpers/extractCountryCallingCode.js"],"sourcesContent":["import stripIddPrefix from './stripIddPrefix.js';\nimport extractCountryCallingCodeFromInternationalNumberWithoutPlusSign from './extractCountryCallingCodeFromInternationalNumberWithoutPlusSign.js';\nimport Metadata from '../metadata.js';\nimport { MAX_LENGTH_COUNTRY_CODE } from '../constants.js';\n\n/**\r\n * Converts a phone number digits (possibly with a `+`)\r\n * into a calling code and the rest phone number digits.\r\n * The \"rest phone number digits\" could include\r\n * a national prefix, carrier code, and national\r\n * (significant) number.\r\n * @param {string} number — Phone number digits (possibly with a `+`).\r\n * @param {string} [country] — Country.\r\n * @param {string} [defaultCountry] — Default country.\r\n * @param {string} [defaultCallingCode] — Default calling code (some phone numbering plans are non-geographic).\r\n * @param {object} metadata\r\n * @return {object} `{ countryCallingCodeSource: string?, countryCallingCode: string?, number: string }`\r\n * @example\r\n * // Returns `{ countryCallingCode: \"1\", number: \"2133734253\" }`.\r\n * extractCountryCallingCode('2133734253', null, 'US', null, metadata)\r\n * extractCountryCallingCode('2133734253', null, null, '1', metadata)\r\n * extractCountryCallingCode('+12133734253', null, null, null, metadata)\r\n * extractCountryCallingCode('+12133734253', null, 'RU', null, metadata)\r\n */\nexport default function extractCountryCallingCode(number, country, defaultCountry, defaultCallingCode, metadata) {\n if (!number) {\n return {};\n }\n var isNumberWithIddPrefix;\n\n // If this is not an international phone number,\n // then either extract an \"IDD\" prefix, or extract a\n // country calling code from a number by autocorrecting it\n // by prepending a leading `+` in cases when it starts\n // with the country calling code.\n // https://wikitravel.org/en/International_dialling_prefix\n // https://github.com/catamphetamine/libphonenumber-js/issues/376\n if (number[0] !== '+') {\n // Convert an \"out-of-country\" dialing phone number\n // to a proper international phone number.\n var numberWithoutIDD = stripIddPrefix(number, country || defaultCountry, defaultCallingCode, metadata);\n // If an IDD prefix was stripped then\n // convert the number to international one\n // for subsequent parsing.\n if (numberWithoutIDD && numberWithoutIDD !== number) {\n isNumberWithIddPrefix = true;\n number = '+' + numberWithoutIDD;\n } else {\n // Check to see if the number starts with the country calling code\n // for the default country. If so, we remove the country calling code,\n // and do some checks on the validity of the number before and after.\n // https://github.com/catamphetamine/libphonenumber-js/issues/376\n if (country || defaultCountry || defaultCallingCode) {\n var _extractCountryCallin = extractCountryCallingCodeFromInternationalNumberWithoutPlusSign(number, country, defaultCountry, defaultCallingCode, metadata),\n countryCallingCode = _extractCountryCallin.countryCallingCode,\n shorterNumber = _extractCountryCallin.number;\n if (countryCallingCode) {\n return {\n countryCallingCodeSource: 'FROM_NUMBER_WITHOUT_PLUS_SIGN',\n countryCallingCode: countryCallingCode,\n number: shorterNumber\n };\n }\n }\n return {\n // No need to set it to `UNSPECIFIED`. It can be just `undefined`.\n // countryCallingCodeSource: 'UNSPECIFIED',\n number: number\n };\n }\n }\n\n // `number` can only be international at this point.\n\n // Fast abortion: country codes do not begin with a '0'\n if (number[1] === '0') {\n return {};\n }\n metadata = new Metadata(metadata);\n\n // The thing with country phone codes\n // is that they are orthogonal to each other\n // i.e. there's no such country phone code A\n // for which country phone code B exists\n // where B starts with A.\n // Therefore, while scanning digits,\n // if a valid country code is found,\n // that means that it is the country code.\n //\n var i = 2;\n while (i - 1 <= MAX_LENGTH_COUNTRY_CODE && i <= number.length) {\n var _countryCallingCode = number.slice(1, i);\n if (metadata.hasCallingCode(_countryCallingCode)) {\n metadata.selectNumberingPlan(_countryCallingCode);\n return {\n countryCallingCodeSource: isNumberWithIddPrefix ? 'FROM_NUMBER_WITH_IDD' : 'FROM_NUMBER_WITH_PLUS_SIGN',\n countryCallingCode: _countryCallingCode,\n number: number.slice(i)\n };\n }\n i++;\n }\n return {};\n}\n\n// The possible values for the returned `countryCallingCodeSource` are:\n//\n// Copy-pasted from:\n// https://github.com/google/libphonenumber/blob/master/resources/phonenumber.proto\n//\n// // The source from which the country_code is derived. This is not set in the\n// // general parsing method, but in the method that parses and keeps raw_input.\n// // New fields could be added upon request.\n// enum CountryCodeSource {\n// // Default value returned if this is not set, because the phone number was\n// // created using parse, not parseAndKeepRawInput. hasCountryCodeSource will\n// // return false if this is the case.\n// UNSPECIFIED = 0;\n//\n// // The country_code is derived based on a phone number with a leading \"+\",\n// // e.g. the French number \"+33 1 42 68 53 00\".\n// FROM_NUMBER_WITH_PLUS_SIGN = 1;\n//\n// // The country_code is derived based on a phone number with a leading IDD,\n// // e.g. the French number \"011 33 1 42 68 53 00\", as it is dialled from US.\n// FROM_NUMBER_WITH_IDD = 5;\n//\n// // The country_code is derived based on a phone number without a leading\n// // \"+\", e.g. the French number \"33 1 42 68 53 00\" when defaultCountry is\n// // supplied as France.\n// FROM_NUMBER_WITHOUT_PLUS_SIGN = 10;\n//\n// // The country_code is derived NOT based on the phone number itself, but\n// // from the defaultCountry parameter provided in the parsing function by the\n// // clients. This happens mostly for numbers written in the national format\n// // (without country code). For example, this would be set when parsing the\n// // French number \"01 42 68 53 00\", when defaultCountry is supplied as\n// // France.\n// FROM_DEFAULT_COUNTRY = 20;\n// }\n//# sourceMappingURL=extractCountryCallingCode.js.map"],"names":["extractCountryCallingCode","number","country","defaultCountry","defaultCallingCode","metadata","isNumberWithIddPrefix","numberWithoutIDD","stripIddPrefix","_extractCountryCallin","extractCountryCallingCodeFromInternationalNumberWithoutPlusSign","countryCallingCode","shorterNumber","Metadata","i","MAX_LENGTH_COUNTRY_CODE","_countryCallingCode"],"mappings":";;;;AAwBe,SAASA,EAA0BC,GAAQC,GAASC,GAAgBC,GAAoBC,GAAU;AAC/G,MAAI,CAACJ;AACH,WAAO,CAAA;AAET,MAAIK;AASJ,MAAIL,EAAO,CAAC,MAAM,KAAK;AAGrB,QAAIM,IAAmBC,EAAeP,GAAQC,KAAWC,GAAgBC,GAAoBC,CAAQ;AAIrG,QAAIE,KAAoBA,MAAqBN;AAC3C,MAAAK,IAAwB,IACxBL,IAAS,MAAMM;AAAA,SACV;AAKL,UAAIL,KAAWC,KAAkBC,GAAoB;AACnD,YAAIK,IAAwBC,EAAgET,GAAQC,GAASC,GAAgBC,GAAoBC,CAAQ,GACvJM,IAAqBF,EAAsB,oBAC3CG,IAAgBH,EAAsB;AACxC,YAAIE;AACF,iBAAO;AAAA,YACL,0BAA0B;AAAA,YAC1B,oBAAoBA;AAAA,YACpB,QAAQC;AAAA,UACpB;AAAA,MAEM;AACA,aAAO;AAAA;AAAA;AAAA,QAGL,QAAQX;AAAA,MAChB;AAAA,IACI;AAAA,EACF;AAKA,MAAIA,EAAO,CAAC,MAAM;AAChB,WAAO,CAAA;AAET,EAAAI,IAAW,IAAIQ,EAASR,CAAQ;AAYhC,WADIS,IAAI,GACDA,IAAI,KAAKC,KAA2BD,KAAKb,EAAO,UAAQ;AAC7D,QAAIe,IAAsBf,EAAO,MAAM,GAAGa,CAAC;AAC3C,QAAIT,EAAS,eAAeW,CAAmB;AAC7C,aAAAX,EAAS,oBAAoBW,CAAmB,GACzC;AAAA,QACL,0BAA0BV,IAAwB,yBAAyB;AAAA,QAC3E,oBAAoBU;AAAA,QACpB,QAAQf,EAAO,MAAMa,CAAC;AAAA,MAC9B;AAEI,IAAAA;AAAA,EACF;AACA,SAAO,CAAA;AACT;","x_google_ignoreList":[0]}
1
+ {"version":3,"file":"index248.js","sources":["../../../node_modules/date-fns/format.js"],"sourcesContent":["import { defaultLocale } from \"./_lib/defaultLocale.js\";\nimport { getDefaultOptions } from \"./_lib/defaultOptions.js\";\nimport { formatters } from \"./_lib/format/formatters.js\";\nimport { longFormatters } from \"./_lib/format/longFormatters.js\";\nimport {\n isProtectedDayOfYearToken,\n isProtectedWeekYearToken,\n warnOrThrowProtectedError,\n} from \"./_lib/protectedTokens.js\";\nimport { isValid } from \"./isValid.js\";\nimport { toDate } from \"./toDate.js\";\n\n// Rexports of internal for libraries to use.\n// See: https://github.com/date-fns/date-fns/issues/3638#issuecomment-1877082874\nexport { formatters, longFormatters };\n\n// This RegExp consists of three parts separated by `|`:\n// - [yYQqMLwIdDecihHKkms]o matches any available ordinal number token\n// (one of the certain letters followed by `o`)\n// - (\\w)\\1* matches any sequences of the same letter\n// - '' matches two quote characters in a row\n// - '(''|[^'])+('|$) matches anything surrounded by two quote characters ('),\n// except a single quote symbol, which ends the sequence.\n// Two quote characters do not end the sequence.\n// If there is no matching single quote\n// then the sequence will continue until the end of the string.\n// - . matches any single character unmatched by previous parts of the RegExps\nconst formattingTokensRegExp =\n /[yYQqMLwIdDecihHKkms]o|(\\w)\\1*|''|'(''|[^'])+('|$)|./g;\n\n// This RegExp catches symbols escaped by quotes, and also\n// sequences of symbols P, p, and the combinations like `PPPPPPPppppp`\nconst longFormattingTokensRegExp = /P+p+|P+|p+|''|'(''|[^'])+('|$)|./g;\n\nconst escapedStringRegExp = /^'([^]*?)'?$/;\nconst doubleQuoteRegExp = /''/g;\nconst unescapedLatinCharacterRegExp = /[a-zA-Z]/;\n\nexport { format as formatDate };\n\n/**\n * The {@link format} function options.\n */\n\n/**\n * @name format\n * @alias formatDate\n * @category Common Helpers\n * @summary Format the date.\n *\n * @description\n * Return the formatted date string in the given format. The result may vary by locale.\n *\n * > ⚠️ Please note that the `format` tokens differ from Moment.js and other libraries.\n * > See: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md\n *\n * The characters wrapped between two single quotes characters (') are escaped.\n * Two single quotes in a row, whether inside or outside a quoted sequence, represent a 'real' single quote.\n * (see the last example)\n *\n * Format of the string is based on Unicode Technical Standard #35:\n * https://www.unicode.org/reports/tr35/tr35-dates.html#Date_Field_Symbol_Table\n * with a few additions (see note 7 below the table).\n *\n * Accepted patterns:\n * | Unit | Pattern | Result examples | Notes |\n * |---------------------------------|---------|-----------------------------------|-------|\n * | Era | G..GGG | AD, BC | |\n * | | GGGG | Anno Domini, Before Christ | 2 |\n * | | GGGGG | A, B | |\n * | Calendar year | y | 44, 1, 1900, 2017 | 5 |\n * | | yo | 44th, 1st, 0th, 17th | 5,7 |\n * | | yy | 44, 01, 00, 17 | 5 |\n * | | yyy | 044, 001, 1900, 2017 | 5 |\n * | | yyyy | 0044, 0001, 1900, 2017 | 5 |\n * | | yyyyy | ... | 3,5 |\n * | Local week-numbering year | Y | 44, 1, 1900, 2017 | 5 |\n * | | Yo | 44th, 1st, 1900th, 2017th | 5,7 |\n * | | YY | 44, 01, 00, 17 | 5,8 |\n * | | YYY | 044, 001, 1900, 2017 | 5 |\n * | | YYYY | 0044, 0001, 1900, 2017 | 5,8 |\n * | | YYYYY | ... | 3,5 |\n * | ISO week-numbering year | R | -43, 0, 1, 1900, 2017 | 5,7 |\n * | | RR | -43, 00, 01, 1900, 2017 | 5,7 |\n * | | RRR | -043, 000, 001, 1900, 2017 | 5,7 |\n * | | RRRR | -0043, 0000, 0001, 1900, 2017 | 5,7 |\n * | | RRRRR | ... | 3,5,7 |\n * | Extended year | u | -43, 0, 1, 1900, 2017 | 5 |\n * | | uu | -43, 01, 1900, 2017 | 5 |\n * | | uuu | -043, 001, 1900, 2017 | 5 |\n * | | uuuu | -0043, 0001, 1900, 2017 | 5 |\n * | | uuuuu | ... | 3,5 |\n * | Quarter (formatting) | Q | 1, 2, 3, 4 | |\n * | | Qo | 1st, 2nd, 3rd, 4th | 7 |\n * | | QQ | 01, 02, 03, 04 | |\n * | | QQQ | Q1, Q2, Q3, Q4 | |\n * | | QQQQ | 1st quarter, 2nd quarter, ... | 2 |\n * | | QQQQQ | 1, 2, 3, 4 | 4 |\n * | Quarter (stand-alone) | q | 1, 2, 3, 4 | |\n * | | qo | 1st, 2nd, 3rd, 4th | 7 |\n * | | qq | 01, 02, 03, 04 | |\n * | | qqq | Q1, Q2, Q3, Q4 | |\n * | | qqqq | 1st quarter, 2nd quarter, ... | 2 |\n * | | qqqqq | 1, 2, 3, 4 | 4 |\n * | Month (formatting) | M | 1, 2, ..., 12 | |\n * | | Mo | 1st, 2nd, ..., 12th | 7 |\n * | | MM | 01, 02, ..., 12 | |\n * | | MMM | Jan, Feb, ..., Dec | |\n * | | MMMM | January, February, ..., December | 2 |\n * | | MMMMM | J, F, ..., D | |\n * | Month (stand-alone) | L | 1, 2, ..., 12 | |\n * | | Lo | 1st, 2nd, ..., 12th | 7 |\n * | | LL | 01, 02, ..., 12 | |\n * | | LLL | Jan, Feb, ..., Dec | |\n * | | LLLL | January, February, ..., December | 2 |\n * | | LLLLL | J, F, ..., D | |\n * | Local week of year | w | 1, 2, ..., 53 | |\n * | | wo | 1st, 2nd, ..., 53th | 7 |\n * | | ww | 01, 02, ..., 53 | |\n * | ISO week of year | I | 1, 2, ..., 53 | 7 |\n * | | Io | 1st, 2nd, ..., 53th | 7 |\n * | | II | 01, 02, ..., 53 | 7 |\n * | Day of month | d | 1, 2, ..., 31 | |\n * | | do | 1st, 2nd, ..., 31st | 7 |\n * | | dd | 01, 02, ..., 31 | |\n * | Day of year | D | 1, 2, ..., 365, 366 | 9 |\n * | | Do | 1st, 2nd, ..., 365th, 366th | 7 |\n * | | DD | 01, 02, ..., 365, 366 | 9 |\n * | | DDD | 001, 002, ..., 365, 366 | |\n * | | DDDD | ... | 3 |\n * | Day of week (formatting) | E..EEE | Mon, Tue, Wed, ..., Sun | |\n * | | EEEE | Monday, Tuesday, ..., Sunday | 2 |\n * | | EEEEE | M, T, W, T, F, S, S | |\n * | | EEEEEE | Mo, Tu, We, Th, Fr, Sa, Su | |\n * | ISO day of week (formatting) | i | 1, 2, 3, ..., 7 | 7 |\n * | | io | 1st, 2nd, ..., 7th | 7 |\n * | | ii | 01, 02, ..., 07 | 7 |\n * | | iii | Mon, Tue, Wed, ..., Sun | 7 |\n * | | iiii | Monday, Tuesday, ..., Sunday | 2,7 |\n * | | iiiii | M, T, W, T, F, S, S | 7 |\n * | | iiiiii | Mo, Tu, We, Th, Fr, Sa, Su | 7 |\n * | Local day of week (formatting) | e | 2, 3, 4, ..., 1 | |\n * | | eo | 2nd, 3rd, ..., 1st | 7 |\n * | | ee | 02, 03, ..., 01 | |\n * | | eee | Mon, Tue, Wed, ..., Sun | |\n * | | eeee | Monday, Tuesday, ..., Sunday | 2 |\n * | | eeeee | M, T, W, T, F, S, S | |\n * | | eeeeee | Mo, Tu, We, Th, Fr, Sa, Su | |\n * | Local day of week (stand-alone) | c | 2, 3, 4, ..., 1 | |\n * | | co | 2nd, 3rd, ..., 1st | 7 |\n * | | cc | 02, 03, ..., 01 | |\n * | | ccc | Mon, Tue, Wed, ..., Sun | |\n * | | cccc | Monday, Tuesday, ..., Sunday | 2 |\n * | | ccccc | M, T, W, T, F, S, S | |\n * | | cccccc | Mo, Tu, We, Th, Fr, Sa, Su | |\n * | AM, PM | a..aa | AM, PM | |\n * | | aaa | am, pm | |\n * | | aaaa | a.m., p.m. | 2 |\n * | | aaaaa | a, p | |\n * | AM, PM, noon, midnight | b..bb | AM, PM, noon, midnight | |\n * | | bbb | am, pm, noon, midnight | |\n * | | bbbb | a.m., p.m., noon, midnight | 2 |\n * | | bbbbb | a, p, n, mi | |\n * | Flexible day period | B..BBB | at night, in the morning, ... | |\n * | | BBBB | at night, in the morning, ... | 2 |\n * | | BBBBB | at night, in the morning, ... | |\n * | Hour [1-12] | h | 1, 2, ..., 11, 12 | |\n * | | ho | 1st, 2nd, ..., 11th, 12th | 7 |\n * | | hh | 01, 02, ..., 11, 12 | |\n * | Hour [0-23] | H | 0, 1, 2, ..., 23 | |\n * | | Ho | 0th, 1st, 2nd, ..., 23rd | 7 |\n * | | HH | 00, 01, 02, ..., 23 | |\n * | Hour [0-11] | K | 1, 2, ..., 11, 0 | |\n * | | Ko | 1st, 2nd, ..., 11th, 0th | 7 |\n * | | KK | 01, 02, ..., 11, 00 | |\n * | Hour [1-24] | k | 24, 1, 2, ..., 23 | |\n * | | ko | 24th, 1st, 2nd, ..., 23rd | 7 |\n * | | kk | 24, 01, 02, ..., 23 | |\n * | Minute | m | 0, 1, ..., 59 | |\n * | | mo | 0th, 1st, ..., 59th | 7 |\n * | | mm | 00, 01, ..., 59 | |\n * | Second | s | 0, 1, ..., 59 | |\n * | | so | 0th, 1st, ..., 59th | 7 |\n * | | ss | 00, 01, ..., 59 | |\n * | Fraction of second | S | 0, 1, ..., 9 | |\n * | | SS | 00, 01, ..., 99 | |\n * | | SSS | 000, 001, ..., 999 | |\n * | | SSSS | ... | 3 |\n * | Timezone (ISO-8601 w/ Z) | X | -08, +0530, Z | |\n * | | XX | -0800, +0530, Z | |\n * | | XXX | -08:00, +05:30, Z | |\n * | | XXXX | -0800, +0530, Z, +123456 | 2 |\n * | | XXXXX | -08:00, +05:30, Z, +12:34:56 | |\n * | Timezone (ISO-8601 w/o Z) | x | -08, +0530, +00 | |\n * | | xx | -0800, +0530, +0000 | |\n * | | xxx | -08:00, +05:30, +00:00 | 2 |\n * | | xxxx | -0800, +0530, +0000, +123456 | |\n * | | xxxxx | -08:00, +05:30, +00:00, +12:34:56 | |\n * | Timezone (GMT) | O...OOO | GMT-8, GMT+5:30, GMT+0 | |\n * | | OOOO | GMT-08:00, GMT+05:30, GMT+00:00 | 2 |\n * | Timezone (specific non-locat.) | z...zzz | GMT-8, GMT+5:30, GMT+0 | 6 |\n * | | zzzz | GMT-08:00, GMT+05:30, GMT+00:00 | 2,6 |\n * | Seconds timestamp | t | 512969520 | 7 |\n * | | tt | ... | 3,7 |\n * | Milliseconds timestamp | T | 512969520900 | 7 |\n * | | TT | ... | 3,7 |\n * | Long localized date | P | 04/29/1453 | 7 |\n * | | PP | Apr 29, 1453 | 7 |\n * | | PPP | April 29th, 1453 | 7 |\n * | | PPPP | Friday, April 29th, 1453 | 2,7 |\n * | Long localized time | p | 12:00 AM | 7 |\n * | | pp | 12:00:00 AM | 7 |\n * | | ppp | 12:00:00 AM GMT+2 | 7 |\n * | | pppp | 12:00:00 AM GMT+02:00 | 2,7 |\n * | Combination of date and time | Pp | 04/29/1453, 12:00 AM | 7 |\n * | | PPpp | Apr 29, 1453, 12:00:00 AM | 7 |\n * | | PPPppp | April 29th, 1453 at ... | 7 |\n * | | PPPPpppp| Friday, April 29th, 1453 at ... | 2,7 |\n * Notes:\n * 1. \"Formatting\" units (e.g. formatting quarter) in the default en-US locale\n * are the same as \"stand-alone\" units, but are different in some languages.\n * \"Formatting\" units are declined according to the rules of the language\n * in the context of a date. \"Stand-alone\" units are always nominative singular:\n *\n * `format(new Date(2017, 10, 6), 'do LLLL', {locale: cs}) //=> '6. listopad'`\n *\n * `format(new Date(2017, 10, 6), 'do MMMM', {locale: cs}) //=> '6. listopadu'`\n *\n * 2. Any sequence of the identical letters is a pattern, unless it is escaped by\n * the single quote characters (see below).\n * If the sequence is longer than listed in table (e.g. `EEEEEEEEEEE`)\n * the output will be the same as default pattern for this unit, usually\n * the longest one (in case of ISO weekdays, `EEEE`). Default patterns for units\n * are marked with \"2\" in the last column of the table.\n *\n * `format(new Date(2017, 10, 6), 'MMM') //=> 'Nov'`\n *\n * `format(new Date(2017, 10, 6), 'MMMM') //=> 'November'`\n *\n * `format(new Date(2017, 10, 6), 'MMMMM') //=> 'N'`\n *\n * `format(new Date(2017, 10, 6), 'MMMMMM') //=> 'November'`\n *\n * `format(new Date(2017, 10, 6), 'MMMMMMM') //=> 'November'`\n *\n * 3. Some patterns could be unlimited length (such as `yyyyyyyy`).\n * The output will be padded with zeros to match the length of the pattern.\n *\n * `format(new Date(2017, 10, 6), 'yyyyyyyy') //=> '00002017'`\n *\n * 4. `QQQQQ` and `qqqqq` could be not strictly numerical in some locales.\n * These tokens represent the shortest form of the quarter.\n *\n * 5. The main difference between `y` and `u` patterns are B.C. years:\n *\n * | Year | `y` | `u` |\n * |------|-----|-----|\n * | AC 1 | 1 | 1 |\n * | BC 1 | 1 | 0 |\n * | BC 2 | 2 | -1 |\n *\n * Also `yy` always returns the last two digits of a year,\n * while `uu` pads single digit years to 2 characters and returns other years unchanged:\n *\n * | Year | `yy` | `uu` |\n * |------|------|------|\n * | 1 | 01 | 01 |\n * | 14 | 14 | 14 |\n * | 376 | 76 | 376 |\n * | 1453 | 53 | 1453 |\n *\n * The same difference is true for local and ISO week-numbering years (`Y` and `R`),\n * except local week-numbering years are dependent on `options.weekStartsOn`\n * and `options.firstWeekContainsDate` (compare [getISOWeekYear](https://date-fns.org/docs/getISOWeekYear)\n * and [getWeekYear](https://date-fns.org/docs/getWeekYear)).\n *\n * 6. Specific non-location timezones are currently unavailable in `date-fns`,\n * so right now these tokens fall back to GMT timezones.\n *\n * 7. These patterns are not in the Unicode Technical Standard #35:\n * - `i`: ISO day of week\n * - `I`: ISO week of year\n * - `R`: ISO week-numbering year\n * - `t`: seconds timestamp\n * - `T`: milliseconds timestamp\n * - `o`: ordinal number modifier\n * - `P`: long localized date\n * - `p`: long localized time\n *\n * 8. `YY` and `YYYY` tokens represent week-numbering years but they are often confused with years.\n * You should enable `options.useAdditionalWeekYearTokens` to use them. See: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md\n *\n * 9. `D` and `DD` tokens represent days of the year but they are often confused with days of the month.\n * You should enable `options.useAdditionalDayOfYearTokens` to use them. See: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md\n *\n * @param date - The original date\n * @param format - The string of tokens\n * @param options - An object with options\n *\n * @returns The formatted date string\n *\n * @throws `date` must not be Invalid Date\n * @throws `options.locale` must contain `localize` property\n * @throws `options.locale` must contain `formatLong` property\n * @throws use `yyyy` instead of `YYYY` for formatting years using [format provided] to the input [input provided]; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md\n * @throws use `yy` instead of `YY` for formatting years using [format provided] to the input [input provided]; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md\n * @throws use `d` instead of `D` for formatting days of the month using [format provided] to the input [input provided]; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md\n * @throws use `dd` instead of `DD` for formatting days of the month using [format provided] to the input [input provided]; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md\n * @throws format string contains an unescaped latin alphabet character\n *\n * @example\n * // Represent 11 February 2014 in middle-endian format:\n * const result = format(new Date(2014, 1, 11), 'MM/dd/yyyy')\n * //=> '02/11/2014'\n *\n * @example\n * // Represent 2 July 2014 in Esperanto:\n * import { eoLocale } from 'date-fns/locale/eo'\n * const result = format(new Date(2014, 6, 2), \"do 'de' MMMM yyyy\", {\n * locale: eoLocale\n * })\n * //=> '2-a de julio 2014'\n *\n * @example\n * // Escape string by single quote characters:\n * const result = format(new Date(2014, 6, 2, 15), \"h 'o''clock'\")\n * //=> \"3 o'clock\"\n */\nexport function format(date, formatStr, options) {\n const defaultOptions = getDefaultOptions();\n const locale = options?.locale ?? defaultOptions.locale ?? defaultLocale;\n\n const firstWeekContainsDate =\n options?.firstWeekContainsDate ??\n options?.locale?.options?.firstWeekContainsDate ??\n defaultOptions.firstWeekContainsDate ??\n defaultOptions.locale?.options?.firstWeekContainsDate ??\n 1;\n\n const weekStartsOn =\n options?.weekStartsOn ??\n options?.locale?.options?.weekStartsOn ??\n defaultOptions.weekStartsOn ??\n defaultOptions.locale?.options?.weekStartsOn ??\n 0;\n\n const originalDate = toDate(date, options?.in);\n\n if (!isValid(originalDate)) {\n throw new RangeError(\"Invalid time value\");\n }\n\n let parts = formatStr\n .match(longFormattingTokensRegExp)\n .map((substring) => {\n const firstCharacter = substring[0];\n if (firstCharacter === \"p\" || firstCharacter === \"P\") {\n const longFormatter = longFormatters[firstCharacter];\n return longFormatter(substring, locale.formatLong);\n }\n return substring;\n })\n .join(\"\")\n .match(formattingTokensRegExp)\n .map((substring) => {\n // Replace two single quote characters with one single quote character\n if (substring === \"''\") {\n return { isToken: false, value: \"'\" };\n }\n\n const firstCharacter = substring[0];\n if (firstCharacter === \"'\") {\n return { isToken: false, value: cleanEscapedString(substring) };\n }\n\n if (formatters[firstCharacter]) {\n return { isToken: true, value: substring };\n }\n\n if (firstCharacter.match(unescapedLatinCharacterRegExp)) {\n throw new RangeError(\n \"Format string contains an unescaped latin alphabet character `\" +\n firstCharacter +\n \"`\",\n );\n }\n\n return { isToken: false, value: substring };\n });\n\n // invoke localize preprocessor (only for french locales at the moment)\n if (locale.localize.preprocessor) {\n parts = locale.localize.preprocessor(originalDate, parts);\n }\n\n const formatterOptions = {\n firstWeekContainsDate,\n weekStartsOn,\n locale,\n };\n\n return parts\n .map((part) => {\n if (!part.isToken) return part.value;\n\n const token = part.value;\n\n if (\n (!options?.useAdditionalWeekYearTokens &&\n isProtectedWeekYearToken(token)) ||\n (!options?.useAdditionalDayOfYearTokens &&\n isProtectedDayOfYearToken(token))\n ) {\n warnOrThrowProtectedError(token, formatStr, String(date));\n }\n\n const formatter = formatters[token[0]];\n return formatter(originalDate, token, locale.localize, formatterOptions);\n })\n .join(\"\");\n}\n\nfunction cleanEscapedString(input) {\n const matched = input.match(escapedStringRegExp);\n\n if (!matched) {\n return input;\n }\n\n return matched[1].replace(doubleQuoteRegExp, \"'\");\n}\n\n// Fallback for modularized imports:\nexport default format;\n"],"names":["formattingTokensRegExp","longFormattingTokensRegExp","escapedStringRegExp","doubleQuoteRegExp","unescapedLatinCharacterRegExp","format","date","formatStr","options","defaultOptions","getDefaultOptions","locale","defaultLocale","firstWeekContainsDate","weekStartsOn","originalDate","toDate","isValid","parts","substring","firstCharacter","longFormatter","longFormatters","cleanEscapedString","formatters","formatterOptions","part","token","isProtectedWeekYearToken","isProtectedDayOfYearToken","warnOrThrowProtectedError","formatter","input","matched"],"mappings":";;;;;;;AA2BA,MAAMA,IACJ,yDAIIC,IAA6B,qCAE7BC,IAAsB,gBACtBC,IAAoB,OACpBC,IAAgC;AAoS/B,SAASC,EAAOC,GAAMC,GAAWC,GAAS;AAC/C,QAAMC,IAAiBC,EAAiB,GAClCC,IAASH,GAAS,UAAUC,EAAe,UAAUG,GAErDC,IACJL,GAAS,yBACTA,GAAS,QAAQ,SAAS,yBAC1BC,EAAe,yBACfA,EAAe,QAAQ,SAAS,yBAChC,GAEIK,IACJN,GAAS,gBACTA,GAAS,QAAQ,SAAS,gBAC1BC,EAAe,gBACfA,EAAe,QAAQ,SAAS,gBAChC,GAEIM,IAAeC,EAAOV,GAAME,GAAS,EAAE;AAE7C,MAAI,CAACS,EAAQF,CAAY;AACvB,UAAM,IAAI,WAAW,oBAAo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AAUc,CAAgB;AAAA,EACzE,CAAC,EACA,KAAK,EAAE;AACZ;AAEA,SAASF,EAAmBS,GAAO;AACjC,QAAMC,IAAUD,EAAM,MAAM9B,CAAmB;AAE/C,SAAK+B,IAIEA,EAAQ,CAAC,EAAE,QAAQ9B,GAAmB,GAAG,IAHvC6B;AAIX;","x_google_ignoreList":[0]}
package/dist/index249.js CHANGED
@@ -1,99 +1,20 @@
1
- import N from "./index259.js";
2
- import g from "./index164.js";
3
- import m, { getCountryCallingCode as s } from "./index169.js";
4
- import h from "./index262.js";
5
- import { formatRFC3966 as I } from "./index255.js";
6
- var l = {
7
- formatExtension: function(t, r, e) {
8
- return "".concat(t).concat(e.ext()).concat(r);
1
+ function j(r, n, I, W) {
2
+ const s = r[0], o = r[r.length - 1], { ISOWeek: c, fixedWeeks: u, broadcastCalendar: a } = I ?? {}, { addDays: i, differenceInCalendarDays: M, differenceInCalendarMonths: C, endOfBroadcastWeek: O, endOfISOWeek: k, endOfMonth: h, endOfWeek: l, isAfter: E, startOfBroadcastWeek: F, startOfISOWeek: S, startOfWeek: p } = W, g = a ? F(s, W) : c ? S(s) : p(s), D = a ? O(o) : c ? k(h(o)) : l(h(o)), f = n && (a ? O(n) : c ? k(n) : l(n)), x = f && E(D, f) ? f : D, A = M(x, g), B = C(o, s) + 1, e = [];
3
+ for (let t = 0; t <= A; t++) {
4
+ const d = i(g, t);
5
+ e.push(d);
9
6
  }
10
- };
11
- function O(n, t, r, e) {
12
- if (r ? r = E({}, l, r) : r = l, e = new m(e), n.country && n.country !== "001") {
13
- if (!e.hasCountry(n.country))
14
- throw new Error("Unknown country: ".concat(n.country));
15
- e.selectNumberingPlan(n.country);
16
- } else if (n.countryCallingCode)
17
- e.selectNumberingPlan(n.countryCallingCode);
18
- else return n.phone || "";
19
- var o = e.countryCallingCode(), a = r.v2 ? n.nationalNumber : n.phone, c;
20
- switch (t) {
21
- case "NATIONAL":
22
- return a ? (c = f(a, n.carrierCode, "NATIONAL", e, r), u(c, n.ext, e, r.formatExtension)) : "";
23
- case "INTERNATIONAL":
24
- return a ? (c = f(a, null, "INTERNATIONAL", e, r), c = "+".concat(o, " ").concat(c), u(c, n.ext, e, r.formatExtension)) : "+".concat(o);
25
- case "E.164":
26
- return "+".concat(o).concat(a);
27
- case "RFC3966":
28
- return I({
29
- number: "+".concat(o).concat(a),
30
- ext: n.ext
31
- });
32
- // For reference, here's Google's IDD formatter:
33
- // https://github.com/google/libphonenumber/blob/32719cf74e68796788d1ca45abc85dcdc63ba5b9/java/libphonenumber/src/com/google/i18n/phonenumbers/PhoneNumberUtil.java#L1546
34
- // Not saying that this IDD formatter replicates it 1:1, but it seems to work.
35
- // Who would even need to format phone numbers in IDD format anyway?
36
- case "IDD":
37
- if (!r.fromCountry)
38
- return;
39
- var i = A(a, n.carrierCode, o, r.fromCountry, e);
40
- return i ? u(i, n.ext, e, r.formatExtension) : void 0;
41
- default:
42
- throw new Error('Unknown "format" argument passed to "formatNumber()": "'.concat(t, '"'));
43
- }
44
- }
45
- function f(n, t, r, e, o) {
46
- var a = x(e.formats(), n);
47
- return a ? g(n, a, {
48
- useInternationalFormat: r === "INTERNATIONAL",
49
- withNationalPrefix: !(a.nationalPrefixIsOptionalWhenFormattingInNationalFormat() && o && o.nationalPrefix === !1),
50
- carrierCode: t,
51
- metadata: e
52
- }) : n;
53
- }
54
- function x(n, t) {
55
- return v(n, function(r) {
56
- if (r.leadingDigitsPatterns().length > 0) {
57
- var e = r.leadingDigitsPatterns()[r.leadingDigitsPatterns().length - 1];
58
- if (t.search(e) !== 0)
59
- return !1;
7
+ const y = (a ? 35 : 42) * B;
8
+ if (u && e.length < y) {
9
+ const t = y - e.length;
10
+ for (let d = 0; d < t; d++) {
11
+ const T = i(e[e.length - 1], 1);
12
+ e.push(T);
60
13
  }
61
- return N(t, r.pattern());
62
- });
63
- }
64
- function u(n, t, r, e) {
65
- return t ? e(n, t, r) : n;
66
- }
67
- function A(n, t, r, e, o) {
68
- var a = s(e, o.metadata);
69
- if (a === r) {
70
- var c = f(n, t, "NATIONAL", o);
71
- return r === "1" ? r + " " + c : c;
72
- }
73
- var i = h(e, void 0, o.metadata);
74
- if (i)
75
- return "".concat(i, " ").concat(r, " ").concat(f(n, null, "INTERNATIONAL", o));
76
- }
77
- function E() {
78
- for (var n = 1, t = arguments.length, r = new Array(t), e = 0; e < t; e++)
79
- r[e] = arguments[e];
80
- for (; n < r.length; ) {
81
- if (r[n])
82
- for (var o in r[n])
83
- r[0][o] = r[n][o];
84
- n++;
85
- }
86
- return r[0];
87
- }
88
- function v(n, t) {
89
- for (var r = 0; r < n.length; ) {
90
- if (t(n[r]))
91
- return n[r];
92
- r++;
93
14
  }
15
+ return e;
94
16
  }
95
17
  export {
96
- x as chooseFormatForNumber,
97
- O as default
18
+ j as getDates
98
19
  };
99
20
  //# sourceMappingURL=index249.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index249.js","sources":["../../../node_modules/libphonenumber-js/es6/format.js"],"sourcesContent":["// This is a port of Google Android `libphonenumber`'s\n// `phonenumberutil.js` of December 31th, 2018.\n//\n// https://github.com/googlei18n/libphonenumber/commits/master/javascript/i18n/phonenumbers/phonenumberutil.js\n\nimport matchesEntirely from './helpers/matchesEntirely.js';\nimport formatNationalNumberUsingFormat from './helpers/formatNationalNumberUsingFormat.js';\nimport Metadata, { getCountryCallingCode } from './metadata.js';\nimport getIddPrefix from './helpers/getIddPrefix.js';\nimport { formatRFC3966 } from './helpers/RFC3966.js';\nvar DEFAULT_OPTIONS = {\n formatExtension: function formatExtension(formattedNumber, extension, metadata) {\n return \"\".concat(formattedNumber).concat(metadata.ext()).concat(extension);\n }\n};\n\n/**\r\n * Formats a phone number.\r\n *\r\n * format(phoneNumberInstance, 'INTERNATIONAL', { ..., v2: true }, metadata)\r\n * format(phoneNumberInstance, 'NATIONAL', { ..., v2: true }, metadata)\r\n *\r\n * format({ phone: '8005553535', country: 'RU' }, 'INTERNATIONAL', { ... }, metadata)\r\n * format({ phone: '8005553535', country: 'RU' }, 'NATIONAL', undefined, metadata)\r\n *\r\n * @param {object|PhoneNumber} input — If `options.v2: true` flag is passed, the `input` should be a `PhoneNumber` instance. Otherwise, it should be an object of shape `{ phone: '...', country: '...' }`.\r\n * @param {string} format\r\n * @param {object} [options]\r\n * @param {object} metadata\r\n * @return {string}\r\n */\nexport default function formatNumber(input, format, options, metadata) {\n // Apply default options.\n if (options) {\n // Using ES6 \"rest spread\" syntax here didn't work with `babel`/`istanbul`\n // for some weird reason: this line of code would cause the code coverage\n // to show as not 100%. That's because `babel`/`istanbul`, for some weird reason,\n // apparently doesn't know how to properly exclude Babel polyfills from code coverage.\n //\n // options = { ...DEFAULT_OPTIONS, ...options }\n //\n options = merge({}, DEFAULT_OPTIONS, options);\n } else {\n options = DEFAULT_OPTIONS;\n }\n metadata = new Metadata(metadata);\n\n // Normally, the `input` object is supposed to be a `PhoneNumber` class instance.\n // Also, according to the `PhoneNumber` class source code, `country` can't be \"001\".\n // It means that normally `input.country` or `input.countryCallingCode` is supposed\n // to be present because either of the two is always required to exist in a `PhoneNumber` instance.\n // This means that realistically, it's gonna step into either the first `if`\n // or the following `else if`, and normally it won't even reach the legacy-compatibility\n // `else return input.phone || ''` part.\n // So normally, it won't ever return an empty string here.\n if (input.country && input.country !== '001') {\n // Validate `input.country`.\n if (!metadata.hasCountry(input.country)) {\n throw new Error(\"Unknown country: \".concat(input.country));\n }\n metadata.selectNumberingPlan(input.country);\n } else if (input.countryCallingCode) {\n metadata.selectNumberingPlan(input.countryCallingCode);\n } else return input.phone || '';\n var countryCallingCode = metadata.countryCallingCode();\n var nationalNumber = options.v2 ? input.nationalNumber : input.phone;\n\n // This variable should have been declared inside `case`s\n // but Babel has a bug and it says \"duplicate variable declaration\".\n var number;\n switch (format) {\n case 'NATIONAL':\n // Normally, the `input` object is supposed to be a `PhoneNumber` class instance,\n // and a `PhoneNumber` class instance is always required to have a `nationalNumber`.\n // This means that the `if (!nationalNumber)` below is just for legacy-compatibility\n // and it normally can't really happen, so normally it won't ever return an empty string here.\n if (!nationalNumber) {\n return '';\n }\n number = formatNationalNumber(nationalNumber, input.carrierCode, 'NATIONAL', metadata, options);\n return addExtension(number, input.ext, metadata, options.formatExtension);\n case 'INTERNATIONAL':\n // Legacy argument support.\n // (`{ country: ..., phone: '' }`)\n if (!nationalNumber) {\n return \"+\".concat(countryCallingCode);\n }\n number = formatNationalNumber(nationalNumber, null, 'INTERNATIONAL', metadata, options);\n number = \"+\".concat(countryCallingCode, \" \").concat(number);\n return addExtension(number, input.ext, metadata, options.formatExtension);\n case 'E.164':\n // `E.164` doesn't define \"phone number extensions\".\n return \"+\".concat(countryCallingCode).concat(nationalNumber);\n case 'RFC3966':\n return formatRFC3966({\n number: \"+\".concat(countryCallingCode).concat(nationalNumber),\n ext: input.ext\n });\n\n // For reference, here's Google's IDD formatter:\n // https://github.com/google/libphonenumber/blob/32719cf74e68796788d1ca45abc85dcdc63ba5b9/java/libphonenumber/src/com/google/i18n/phonenumbers/PhoneNumberUtil.java#L1546\n // Not saying that this IDD formatter replicates it 1:1, but it seems to work.\n // Who would even need to format phone numbers in IDD format anyway?\n case 'IDD':\n // If the required `fromCountry` parameter is not passed, it will return `undefined`.\n if (!options.fromCountry) {\n return;\n // throw new Error('`fromCountry` option not passed for IDD-prefixed formatting.')\n }\n var formattedNumber = formatIDD(nationalNumber, input.carrierCode, countryCallingCode, options.fromCountry, metadata);\n // If the country of the phone number doesn't support IDD calling, it will return `undefined`.\n if (!formattedNumber) {\n return;\n }\n return addExtension(formattedNumber, input.ext, metadata, options.formatExtension);\n default:\n throw new Error(\"Unknown \\\"format\\\" argument passed to \\\"formatNumber()\\\": \\\"\".concat(format, \"\\\"\"));\n }\n}\nfunction formatNationalNumber(number, carrierCode, formatAs, metadata, options) {\n var format = chooseFormatForNumber(metadata.formats(), number);\n if (!format) {\n return number;\n }\n return formatNationalNumberUsingFormat(number, format, {\n useInternationalFormat: formatAs === 'INTERNATIONAL',\n withNationalPrefix: format.nationalPrefixIsOptionalWhenFormattingInNationalFormat() && options && options.nationalPrefix === false ? false : true,\n carrierCode: carrierCode,\n metadata: metadata\n });\n}\nexport function chooseFormatForNumber(availableFormats, nationalNumber) {\n // Using a `for ... of` loop here didn't work with `babel`/`istanbul`:\n // for some weird reason, it showed code coverage less than 100%.\n // That's because `babel`/`istanbul`, for some weird reason,\n // apparently doesn't know how to properly exclude Babel polyfills from code coverage.\n //\n // for (const format of availableFormats) { ... }\n //\n return pickFirstMatchingElement(availableFormats, function (format) {\n // Validate leading digits.\n // The test case for \"else path\" could be found by searching for\n // \"format.leadingDigitsPatterns().length === 0\".\n if (format.leadingDigitsPatterns().length > 0) {\n // The last leading_digits_pattern is used here, as it is the most detailed\n var lastLeadingDigitsPattern = format.leadingDigitsPatterns()[format.leadingDigitsPatterns().length - 1];\n // If leading digits don't match then move on to the next phone number format\n if (nationalNumber.search(lastLeadingDigitsPattern) !== 0) {\n return false;\n }\n }\n // Check that the national number matches the phone number format regular expression\n return matchesEntirely(nationalNumber, format.pattern());\n });\n}\nfunction addExtension(formattedNumber, ext, metadata, formatExtension) {\n return ext ? formatExtension(formattedNumber, ext, metadata) : formattedNumber;\n}\nfunction formatIDD(nationalNumber, carrierCode, countryCallingCode, fromCountry, metadata) {\n var fromCountryCallingCode = getCountryCallingCode(fromCountry, metadata.metadata);\n // When calling within the same country calling code.\n if (fromCountryCallingCode === countryCallingCode) {\n var formattedNumber = formatNationalNumber(nationalNumber, carrierCode, 'NATIONAL', metadata);\n // For NANPA regions, return the national format for these regions\n // but prefix it with the country calling code.\n if (countryCallingCode === '1') {\n return countryCallingCode + ' ' + formattedNumber;\n }\n // If regions share a country calling code, the country calling code need\n // not be dialled. This also applies when dialling within a region, so this\n // if clause covers both these cases. Technically this is the case for\n // dialling from La Reunion to other overseas departments of France (French\n // Guiana, Martinique, Guadeloupe), but not vice versa - so we don't cover\n // this edge case for now and for those cases return the version including\n // country calling code. Details here:\n // http://www.petitfute.com/voyage/225-info-pratiques-reunion\n //\n return formattedNumber;\n }\n var iddPrefix = getIddPrefix(fromCountry, undefined, metadata.metadata);\n if (iddPrefix) {\n return \"\".concat(iddPrefix, \" \").concat(countryCallingCode, \" \").concat(formatNationalNumber(nationalNumber, null, 'INTERNATIONAL', metadata));\n }\n}\nfunction merge() {\n var i = 1;\n for (var _len = arguments.length, objects = new Array(_len), _key = 0; _key < _len; _key++) {\n objects[_key] = arguments[_key];\n }\n while (i < objects.length) {\n if (objects[i]) {\n for (var key in objects[i]) {\n objects[0][key] = objects[i][key];\n }\n }\n i++;\n }\n return objects[0];\n}\nfunction pickFirstMatchingElement(elements, testFunction) {\n var i = 0;\n while (i < elements.length) {\n if (testFunction(elements[i])) {\n return elements[i];\n }\n i++;\n }\n}\n//# sourceMappingURL=format.js.map"],"names":["DEFAULT_OPTIONS","formattedNumber","extension","metadata","formatNumber","input","format","options","merge","Metadata","countryCallingCode","nationalNumber","number","formatNationalNumber","addExtension","formatRFC3966","formatIDD","carrierCode","formatAs","chooseFormatForNumber","formatNationalNumberUsingFormat","availableFormats","pickFirstMatchingElement","lastLeadingDigitsPattern","matchesEntirely","ext","formatExtension","fromCountry","fromCountryCallingCode","getCountryCallingCode","iddPrefix","getIddPrefix","i","_len","objects","_key","key","elements","testFunction"],"mappings":";;;;;AAUA,IAAIA,IAAkB;AAAA,EACpB,iBAAiB,SAAyBC,GAAiBC,GAAWC,GAAU;AAC9E,WAAO,GAAG,OAAOF,CAAe,EAAE,OAAOE,EAAS,IAAG,CAAE,EAAE,OAAOD,CAAS;AAAA,EAC3E;AACF;AAiBe,SAASE,EAAaC,GAAOC,GAAQC,GAASJ,GAAU;AAwBrE,MAtBII,IAQFA,IAAUC,EAAM,IAAIR,GAAiBO,CAAO,IAE5CA,IAAUP,GAEZG,IAAW,IAAIM,EAASN,CAAQ,GAU5BE,EAAM,WAAWA,EAAM,YAAY,OAAO;AAE5C,QAAI,CAACF,EAAS,WAAWE,EAAM,OAAO;AACpC,YAAM,IAAI,MAA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,IAAQ;AAEf,WADIwB,IAAI,GACCC,IAAO,UAAU,QAAQC,IAAU,IAAI,MAAMD,CAAI,GAAGE,IAAO,GAAGA,IAAOF,GAAME;AAClF,IAAAD,EAAQC,CAAI,IAAI,UAAUA,CAAI;AAEhC,SAAOH,IAAIE,EAAQ,UAAQ;AACzB,QAAIA,EAAQF,CAAC;AACX,eAASI,KAAOF,EAAQF,CAAC;AACvB,QAAAE,EAAQ,CAAC,EAAEE,CAAG,IAAIF,EAAQF,CAAC,EAAEI,CAAG;AAGpC,IAAAJ;AAAA,EACF;AACA,SAAOE,EAAQ,CAAC;AAClB;AACA,SAASZ,EAAyBe,GAAUC,GAAc;AAExD,WADIN,IAAI,GACDA,IAAIK,EAAS,UAAQ;AAC1B,QAAIC,EAAaD,EAASL,CAAC,CAAC;AAC1B,aAAOK,EAASL,CAAC;AAEnB,IAAAA;AAAA,EACF;AACF;","x_google_ignoreList":[0]}
1
+ {"version":3,"file":"index249.js","sources":["../../../node_modules/react-day-picker/dist/esm/helpers/getDates.js"],"sourcesContent":["/**\n * Returns all the dates to display in the calendar.\n *\n * This function calculates the range of dates to display based on the provided\n * display months, constraints, and calendar configuration.\n *\n * @param displayMonths The months to display in the calendar.\n * @param maxDate The maximum date to include in the range.\n * @param props The DayPicker props, including calendar configuration options.\n * @param dateLib The date library to use for date manipulation.\n * @returns An array of dates to display in the calendar.\n */\nexport function getDates(displayMonths, maxDate, props, dateLib) {\n const firstMonth = displayMonths[0];\n const lastMonth = displayMonths[displayMonths.length - 1];\n const { ISOWeek, fixedWeeks, broadcastCalendar } = props ?? {};\n const { addDays, differenceInCalendarDays, differenceInCalendarMonths, endOfBroadcastWeek, endOfISOWeek, endOfMonth, endOfWeek, isAfter, startOfBroadcastWeek, startOfISOWeek, startOfWeek, } = dateLib;\n const startWeekFirstDate = broadcastCalendar\n ? startOfBroadcastWeek(firstMonth, dateLib)\n : ISOWeek\n ? startOfISOWeek(firstMonth)\n : startOfWeek(firstMonth);\n const displayMonthsWeekEnd = broadcastCalendar\n ? endOfBroadcastWeek(lastMonth)\n : ISOWeek\n ? endOfISOWeek(endOfMonth(lastMonth))\n : endOfWeek(endOfMonth(lastMonth));\n // If maxDate is set, clamp the grid to the end of that week.\n const constraintWeekEnd = maxDate &&\n (broadcastCalendar\n ? endOfBroadcastWeek(maxDate)\n : ISOWeek\n ? endOfISOWeek(maxDate)\n : endOfWeek(maxDate));\n // Pick the earliest week end between the displayed months and the constraint.\n const gridEndDate = constraintWeekEnd && isAfter(displayMonthsWeekEnd, constraintWeekEnd)\n ? constraintWeekEnd\n : displayMonthsWeekEnd;\n const nOfDays = differenceInCalendarDays(gridEndDate, startWeekFirstDate);\n const nOfMonths = differenceInCalendarMonths(lastMonth, firstMonth) + 1;\n const dates = [];\n for (let i = 0; i <= nOfDays; i++) {\n const date = addDays(startWeekFirstDate, i);\n dates.push(date);\n }\n // If fixed weeks is enabled, add the extra dates to the array\n const nrOfDaysWithFixedWeeks = broadcastCalendar ? 35 : 42;\n const extraDates = nrOfDaysWithFixedWeeks * nOfMonths;\n if (fixedWeeks && dates.length < extraDates) {\n const daysToAdd = extraDates - dates.length;\n for (let i = 0; i < daysToAdd; i++) {\n const date = addDays(dates[dates.length - 1], 1);\n dates.push(date);\n }\n }\n return dates;\n}\n"],"names":["getDates","displayMonths","maxDate","props","dateLib","firstMonth","lastMonth","ISOWeek","fixedWeeks","broadcastCalendar","addDays","differenceInCalendarDays","differenceInCalendarMonths","endOfBroadcastWeek","endOfISOWeek","endOfMonth","endOfWeek","isAfter","startOfBroadcastWeek","startOfISOWeek","startOfWeek","startWeekFirstDate","displayMonthsWeekEnd","constraintWeekEnd","gridEndDate","nOfDays","nOfMonths","dates","i","date","extraDates","daysToAdd"],"mappings":"AAYO,SAASA,EAASC,GAAeC,GAASC,GAAOC,GAAS;AAC7D,QAAMC,IAAaJ,EAAc,CAAC,GAC5BK,IAAYL,EAAcA,EAAc,SAAS,CAAC,GAClD,EAAE,SAAAM,GAAS,YAAAC,GAAY,mBAAAC,EAAiB,IAAKN,KAAS,CAAA,GACtD,EAAE,SAAAO,GAAS,0BAAAC,GAA0B,4BAAAC,GAA4B,oBAAAC,GAAoB,cAAAC,GAAc,YAAAC,GAAY,WAAAC,GAAW,SAAAC,GAAS,sBAAAC,GAAsB,gBAAAC,GAAgB,aAAAC,EAAW,IAAMhB,GAC1LiB,IAAqBZ,IACrBS,EAAqBb,GAAYD,CAAO,IACxCG,IACIY,EAAed,CAAU,IACzBe,EAAYf,CAAU,GAC1BiB,IAAuBb,IACvBI,EAAmBP,CAAS,IAC5BC,IACIO,EAAaC,EAAWT,CAAS,CAAC,IAClCU,EAAUD,EAAWT,CAAS,CAAC,GAEnCiB,IAAoBrB,MACrBO,IACKI,EAAmBX,CAAO,IAC1BK,IACIO,EAAaZ,CAAO,IACpBc,EAAUd,CAAO,IAEzBsB,IAAcD,KAAqBN,EAAQK,GAAsBC,CAAiB,IAClFA,IACAD,GACAG,IAAUd,EAAyBa,GAAaH,CAAkB,GAClEK,IAAYd,EAA2BN,GAAWD,CAAU,IAAI,GAChEsB,IAAQ,CAAA;AACd,WAASC,IAAI,GAAGA,KAAKH,GAASG,KAAK;AAC/B,UAAMC,IAAOnB,EAAQW,GAAoBO,CAAC;AAC1C,IAAAD,EAAM,KAAKE,CAAI;AAAA,EACnB;AAGA,QAAMC,KADyBrB,IAAoB,KAAK,MACZiB;AAC5C,MAAIlB,KAAcmB,EAAM,SAASG,GAAY;AACzC,UAAMC,IAAYD,IAAaH,EAAM;AACrC,aAASC,IAAI,GAAGA,IAAIG,GAAWH,KAAK;AAChC,YAAMC,IAAOnB,EAAQiB,EAAMA,EAAM,SAAS,CAAC,GAAG,CAAC;AAC/C,MAAAA,EAAM,KAAKE,CAAI;AAAA,IACnB;AAAA,EACJ;AACA,SAAOF;AACX;","x_google_ignoreList":[0]}
package/dist/index25.js CHANGED
@@ -1,12 +1,17 @@
1
- import { j as e } from "./index29.js";
1
+ import { j as e } from "./index30.js";
2
2
  import { useState as g, useMemo as A, useEffect as k } from "react";
3
3
  import { Loader2 as S } from "lucide-react";
4
4
  import { cn as w } from "./index2.js";
5
- const D = [
6
- { value: "off", label: "Off" },
7
- { value: "daily", label: "Daily" },
8
- { value: "weekly", label: "Weekly" }
9
- ], f = (r) => {
5
+ const D = [{
6
+ value: "off",
7
+ label: "Off"
8
+ }, {
9
+ value: "daily",
10
+ label: "Daily"
11
+ }, {
12
+ value: "weekly",
13
+ label: "Weekly"
14
+ }], f = (r) => {
10
15
  const o = r?.digestFrequency, s = o === "off" || o === "daily" || o === "weekly" ? o : "weekly", p = Array.isArray(r?.topicPreferences) ? r.topicPreferences.map((i) => ({
11
16
  topic: typeof i.topic == "string" ? i.topic.trim() : "",
12
17
  inApp: i.inApp === !0,
@@ -16,7 +21,9 @@ const D = [
16
21
  return {
17
22
  digestFrequency: s,
18
23
  topicPreferences: p,
19
- ...typeof r?.lastDigestSentAt == "string" ? { lastDigestSentAt: r.lastDigestSentAt } : {}
24
+ ...typeof r?.lastDigestSentAt == "string" ? {
25
+ lastDigestSentAt: r.lastDigestSentAt
26
+ } : {}
20
27
  };
21
28
  }, T = (r) => {
22
29
  if (!Array.isArray(r)) return [];
@@ -53,9 +60,10 @@ function z({
53
60
  className: r,
54
61
  topics: o
55
62
  }) {
56
- const [s, p] = g(!0), [i, d] = g(!1), [j, u] = g(null), [m, h] = g(
57
- () => f({ digestFrequency: "weekly", topicPreferences: [] })
58
- ), a = A(() => T(o), [o]), P = async () => {
63
+ const [s, p] = g(!0), [i, d] = g(!1), [j, u] = g(null), [m, h] = g(() => f({
64
+ digestFrequency: "weekly",
65
+ topicPreferences: []
66
+ })), a = A(() => T(o), [o]), P = async () => {
59
67
  p(!0), u(null);
60
68
  try {
61
69
  const t = await fetch("/api/rb/notifications/settings", {
@@ -78,7 +86,9 @@ function z({
78
86
  try {
79
87
  const c = await fetch("/api/rb/notifications/settings", {
80
88
  method: "PUT",
81
- headers: { "Content-Type": "application/json" },
89
+ headers: {
90
+ "Content-Type": "application/json"
91
+ },
82
92
  credentials: "include",
83
93
  body: JSON.stringify({
84
94
  digestFrequency: t.digestFrequency,
@@ -103,7 +113,15 @@ function z({
103
113
  a.length !== 0 && h((t) => y(t, a));
104
114
  }, [a]);
105
115
  const N = (t, c) => {
106
- const l = m.topicPreferences.some((x) => x.topic === t) ? m.topicPreferences.map((x) => x.topic === t ? c(x) : x) : [...m.topicPreferences, c({ topic: t, inApp: !0, emailDigest: !0, push: !1 })], b = f({ ...m, topicPreferences: l });
116
+ const l = m.topicPreferences.some((x) => x.topic === t) ? m.topicPreferences.map((x) => x.topic === t ? c(x) : x) : [...m.topicPreferences, c({
117
+ topic: t,
118
+ inApp: !0,
119
+ emailDigest: !0,
120
+ push: !1
121
+ })], b = f({
122
+ ...m,
123
+ topicPreferences: l
124
+ });
107
125
  h(b), v(b);
108
126
  };
109
127
  return s ? /* @__PURE__ */ e.jsx("div", { className: w("flex items-center justify-center py-10 text-muted-foreground", r), children: /* @__PURE__ */ e.jsx(S, { className: "h-4 w-4 animate-spin" }) }) : /* @__PURE__ */ e.jsxs("div", { className: w("space-y-4", r), children: [
@@ -112,18 +130,13 @@ function z({
112
130
  /* @__PURE__ */ e.jsx("div", { className: "text-sm font-semibold", children: "Email digest" }),
113
131
  /* @__PURE__ */ e.jsx("div", { className: "mt-1 text-xs text-muted-foreground", children: "Choose how often we email you a summary." })
114
132
  ] }),
115
- /* @__PURE__ */ e.jsx(
116
- "select",
117
- {
118
- value: m.digestFrequency,
119
- onChange: (t) => {
120
- const c = t.target.value, n = f({ ...m, digestFrequency: c });
121
- h(n), v(n);
122
- },
123
- className: "h-9 rounded-md border bg-background px-2 text-sm",
124
- children: D.map((t) => /* @__PURE__ */ e.jsx("option", { value: t.value, children: t.label }, t.value))
125
- }
126
- )
133
+ /* @__PURE__ */ e.jsx("select", { value: m.digestFrequency, onChange: (t) => {
134
+ const c = t.target.value, n = f({
135
+ ...m,
136
+ digestFrequency: c
137
+ });
138
+ h(n), v(n);
139
+ }, className: "h-9 rounded-md border bg-background px-2 text-sm", children: D.map((t) => /* @__PURE__ */ e.jsx("option", { value: t.value, children: t.label }, t.value)) })
127
140
  ] }) }),
128
141
  /* @__PURE__ */ e.jsxs("div", { className: "rounded-md border bg-background p-4", children: [
129
142
  /* @__PURE__ */ e.jsx("div", { className: "flex items-start justify-between gap-3", children: /* @__PURE__ */ e.jsxs("div", { children: [
@@ -145,32 +158,15 @@ function z({
145
158
  c?.description ? /* @__PURE__ */ e.jsx("span", { className: "text-xs text-muted-foreground", children: c.description }) : null,
146
159
  /* @__PURE__ */ e.jsx("span", { className: "text-[11px] text-muted-foreground", children: t.topic })
147
160
  ] }) }),
148
- /* @__PURE__ */ e.jsx("td", { className: "py-3 pr-4", children: /* @__PURE__ */ e.jsx(
149
- "input",
150
- {
151
- type: "checkbox",
152
- checked: t.inApp,
153
- onChange: (n) => N(t.topic, (l) => ({ ...l, inApp: n.target.checked }))
154
- }
155
- ) }),
156
- /* @__PURE__ */ e.jsx("td", { className: "py-3 pr-4", children: /* @__PURE__ */ e.jsx(
157
- "input",
158
- {
159
- type: "checkbox",
160
- checked: t.emailDigest,
161
- onChange: (n) => N(t.topic, (l) => ({ ...l, emailDigest: n.target.checked }))
162
- }
163
- ) }),
164
- /* @__PURE__ */ e.jsx("td", { className: "py-3 pr-4", children: /* @__PURE__ */ e.jsx(
165
- "input",
166
- {
167
- type: "checkbox",
168
- checked: t.push,
169
- disabled: !0,
170
- className: "opacity-50",
171
- "aria-label": "Push notifications (coming soon)"
172
- }
173
- ) })
161
+ /* @__PURE__ */ e.jsx("td", { className: "py-3 pr-4", children: /* @__PURE__ */ e.jsx("input", { type: "checkbox", checked: t.inApp, onChange: (n) => N(t.topic, (l) => ({
162
+ ...l,
163
+ inApp: n.target.checked
164
+ })) }) }),
165
+ /* @__PURE__ */ e.jsx("td", { className: "py-3 pr-4", children: /* @__PURE__ */ e.jsx("input", { type: "checkbox", checked: t.emailDigest, onChange: (n) => N(t.topic, (l) => ({
166
+ ...l,
167
+ emailDigest: n.target.checked
168
+ })) }) }),
169
+ /* @__PURE__ */ e.jsx("td", { className: "py-3 pr-4", children: /* @__PURE__ */ e.jsx("input", { type: "checkbox", checked: t.push, disabled: !0, className: "opacity-50", "aria-label": "Push notifications (coming soon)" }) })
174
170
  ] }, t.topic);
175
171
  }) })
176
172
  ] }) }),
@@ -1 +1 @@
1
- {"version":3,"file":"index25.js","sources":["../src/components/Notifications/NotificationsSettings.tsx"],"sourcesContent":["import { useEffect, useMemo, useState } from \"react\"\nimport { Loader2 } from \"lucide-react\"\n\nimport { cn } from \"@/lib/utils\"\n\nimport type { NotificationDigestFrequency, NotificationSettings, NotificationTopicCatalogItem, NotificationTopicPreference } from \"./types\"\n\n\ntype SettingsResponse = {\n ok?: boolean\n error?: string\n settings?: NotificationSettings\n}\n\nconst digestValues: Array<{ value: NotificationDigestFrequency; label: string }> = [\n { value: \"off\", label: \"Off\" },\n { value: \"daily\", label: \"Daily\" },\n { value: \"weekly\", label: \"Weekly\" },\n]\n\nconst normalizeSettings = (settings: NotificationSettings | undefined): NotificationSettings => {\n const digestFrequency = settings?.digestFrequency\n const frequency: NotificationDigestFrequency =\n digestFrequency === \"off\" || digestFrequency === \"daily\" || digestFrequency === \"weekly\"\n ? digestFrequency\n : \"weekly\"\n\n const topicPreferences = Array.isArray(settings?.topicPreferences)\n ? settings!.topicPreferences\n .map((pref) => ({\n topic: typeof pref.topic === \"string\" ? pref.topic.trim() : \"\",\n inApp: pref.inApp === true,\n emailDigest: pref.emailDigest === true,\n push: pref.push === true,\n }))\n .filter((pref) => pref.topic.length > 0)\n : []\n\n return {\n digestFrequency: frequency,\n topicPreferences,\n ...(typeof settings?.lastDigestSentAt === \"string\" ? { lastDigestSentAt: settings.lastDigestSentAt } : {}),\n }\n}\n\nconst normalizeTopics = (topics: NotificationTopicCatalogItem[] | undefined): NotificationTopicCatalogItem[] => {\n if (!Array.isArray(topics)) return []\n\n const seen = new Set<string>()\n return topics\n .map((topic) => ({\n topic: typeof topic.topic === \"string\" ? topic.topic.trim() : \"\",\n title: typeof topic.title === \"string\" ? topic.title.trim() : \"\",\n description: typeof topic.description === \"string\" ? topic.description.trim() : undefined,\n }))\n .filter((topic) => topic.topic.length > 0)\n .filter((topic) => {\n if (seen.has(topic.topic)) return false\n seen.add(topic.topic)\n return true\n })\n}\n\nconst applyTopicsToSettings = (\n settings: NotificationSettings,\n topics: NotificationTopicCatalogItem[],\n): NotificationSettings => {\n const defaults: NotificationTopicPreference = {\n topic: \"\",\n inApp: true,\n emailDigest: true,\n push: false,\n }\n\n const byTopic = new Map(settings.topicPreferences.map((pref) => [pref.topic, pref]))\n return {\n ...settings,\n topicPreferences: topics.map((topic) => {\n const existing = byTopic.get(topic.topic)\n return existing\n ? {\n topic: topic.topic,\n inApp: existing.inApp === true,\n emailDigest: existing.emailDigest === true,\n push: existing.push === true,\n }\n : {\n ...defaults,\n topic: topic.topic,\n }\n }),\n }\n}\n\nexport function NotificationsSettings({\n className,\n topics,\n}: {\n className?: string\n topics?: NotificationTopicCatalogItem[]\n}) {\n const [loading, setLoading] = useState(true)\n const [saving, setSaving] = useState(false)\n const [error, setError] = useState<string | null>(null)\n const [settings, setSettings] = useState<NotificationSettings>(() =>\n normalizeSettings({ digestFrequency: \"weekly\", topicPreferences: [] }),\n )\n\n const normalizedTopics = useMemo(() => normalizeTopics(topics), [topics])\n\n const loadSettings = async () => {\n setLoading(true)\n setError(null)\n try {\n const res = await fetch(\"/api/rb/notifications/settings\", {\n method: \"GET\",\n credentials: \"include\",\n })\n const json = (await res.json().catch(() => null)) as SettingsResponse | null\n if (!res.ok || !json?.ok) {\n setError(json?.error || \"Unable to load notification settings.\")\n return\n }\n const normalized = normalizeSettings(json.settings)\n setSettings(normalizedTopics.length > 0 ? applyTopicsToSettings(normalized, normalizedTopics) : normalized)\n } catch {\n setError(\"Unable to load notification settings.\")\n } finally {\n setLoading(false)\n }\n }\n\n const saveSettings = async (next: NotificationSettings) => {\n setSaving(true)\n setError(null)\n try {\n const res = await fetch(\"/api/rb/notifications/settings\", {\n method: \"PUT\",\n headers: { \"Content-Type\": \"application/json\" },\n credentials: \"include\",\n body: JSON.stringify({\n digestFrequency: next.digestFrequency,\n topicPreferences: next.topicPreferences,\n }),\n })\n const json = (await res.json().catch(() => null)) as SettingsResponse | null\n if (!res.ok || !json?.ok) {\n setError(json?.error || \"Unable to save notification settings.\")\n return\n }\n const normalized = normalizeSettings(json.settings)\n setSettings(normalizedTopics.length > 0 ? applyTopicsToSettings(normalized, normalizedTopics) : normalized)\n } catch {\n setError(\"Unable to save notification settings.\")\n } finally {\n setSaving(false)\n }\n }\n\n useEffect(() => {\n void loadSettings()\n }, [])\n\n useEffect(() => {\n if (normalizedTopics.length === 0) return\n setSettings((current) => applyTopicsToSettings(current, normalizedTopics))\n }, [normalizedTopics])\n\n const updatePreference = (topic: string, update: (p: NotificationTopicPreference) => NotificationTopicPreference) => {\n const hasExisting = settings.topicPreferences.some((p) => p.topic === topic)\n const nextPrefs = hasExisting\n ? settings.topicPreferences.map((p) => (p.topic === topic ? update(p) : p))\n : [...settings.topicPreferences, update({ topic, inApp: true, emailDigest: true, push: false })]\n const next = normalizeSettings({ ...settings, topicPreferences: nextPrefs })\n setSettings(next)\n void saveSettings(next)\n }\n\n if (loading) {\n return (\n <div className={cn(\"flex items-center justify-center py-10 text-muted-foreground\", className)}>\n <Loader2 className=\"h-4 w-4 animate-spin\" />\n </div>\n )\n }\n\n return (\n <div className={cn(\"space-y-4\", className)}>\n <div className=\"rounded-md border bg-background p-4\">\n <div className=\"flex items-start justify-between gap-3\">\n <div>\n <div className=\"text-sm font-semibold\">Email digest</div>\n <div className=\"mt-1 text-xs text-muted-foreground\">Choose how often we email you a summary.</div>\n </div>\n <select\n value={settings.digestFrequency}\n onChange={(e) => {\n const value = e.target.value as NotificationDigestFrequency\n const next = normalizeSettings({ ...settings, digestFrequency: value })\n setSettings(next)\n void saveSettings(next)\n }}\n className=\"h-9 rounded-md border bg-background px-2 text-sm\"\n >\n {digestValues.map((opt) => (\n <option key={opt.value} value={opt.value}>\n {opt.label}\n </option>\n ))}\n </select>\n </div>\n </div>\n\n <div className=\"rounded-md border bg-background p-4\">\n <div className=\"flex items-start justify-between gap-3\">\n <div>\n <div className=\"text-sm font-semibold\">Topics</div>\n <div className=\"mt-1 text-xs text-muted-foreground\">Choose where you receive each topic.</div>\n </div>\n </div>\n\n {normalizedTopics.length === 0 ? (\n <div className=\"mt-4 text-sm text-muted-foreground\">No topics configured.</div>\n ) : (\n <div className=\"mt-4 overflow-x-auto\">\n <table className=\"w-full text-sm\">\n <thead>\n <tr className=\"text-left text-xs text-muted-foreground\">\n <th className=\"py-2 pr-4 font-medium\">Topic</th>\n <th className=\"py-2 pr-4 font-medium\">In-app</th>\n <th className=\"py-2 pr-4 font-medium\">Email digest</th>\n <th className=\"py-2 pr-4 font-medium\">Push</th>\n </tr>\n </thead>\n <tbody>\n {settings.topicPreferences.map((pref) => {\n const meta = normalizedTopics.find((topic) => topic.topic === pref.topic)\n return (\n <tr key={pref.topic} className=\"border-t align-top\">\n <td className=\"py-3 pr-4\">\n <div className=\"flex flex-col gap-1\">\n <span className=\"font-medium\">{meta?.title || pref.topic}</span>\n {meta?.description ? (\n <span className=\"text-xs text-muted-foreground\">{meta.description}</span>\n ) : null}\n <span className=\"text-[11px] text-muted-foreground\">{pref.topic}</span>\n </div>\n </td>\n <td className=\"py-3 pr-4\">\n <input\n type=\"checkbox\"\n checked={pref.inApp}\n onChange={(e) =>\n updatePreference(pref.topic, (p) => ({ ...p, inApp: e.target.checked }))\n }\n />\n </td>\n <td className=\"py-3 pr-4\">\n <input\n type=\"checkbox\"\n checked={pref.emailDigest}\n onChange={(e) =>\n updatePreference(pref.topic, (p) => ({ ...p, emailDigest: e.target.checked }))\n }\n />\n </td>\n <td className=\"py-3 pr-4\">\n <input\n type=\"checkbox\"\n checked={pref.push}\n disabled\n className=\"opacity-50\"\n aria-label=\"Push notifications (coming soon)\"\n />\n </td>\n </tr>\n )\n })}\n </tbody>\n </table>\n </div>\n )}\n\n {error ? (\n <div className=\"mt-3 text-sm text-destructive\">{error}</div>\n ) : saving ? (\n <div className=\"mt-3 text-xs text-muted-foreground\">Saving…</div>\n ) : null}\n </div>\n </div>\n )\n}\n"],"names":["digestValues","normalizeSettings","settings","digestFrequency","frequency","topicPreferences","pref","normalizeTopics","topics","seen","topic","applyTopicsToSettings","defaults","byTopic","existing","NotificationsSettings","className","loading","setLoading","useState","saving","setSaving","error","setError","setSettings","normalizedTopics","useMemo","loadSettings","res","json","normalized","saveSettings","next","useEffect","current","updatePreference","update","nextPrefs","p","jsx","cn","Loader2","jsxs","e","value","opt","meta"],"mappings":";;;;AAcA,MAAMA,IAA6E;AAAA,EACjF,EAAE,OAAO,OAAO,OAAO,MAAA;AAAA,EACvB,EAAE,OAAO,SAAS,OAAO,QAAA;AAAA,EACzB,EAAE,OAAO,UAAU,OAAO,SAAA;AAC5B,GAEMC,IAAoB,CAACC,MAAqE;AAC9F,QAAMC,IAAkBD,GAAU,iBAC5BE,IACJD,MAAoB,SAASA,MAAoB,WAAWA,MAAoB,WAC5EA,IACA,UAEAE,IAAmB,MAAM,QAAQH,GAAU,gBAAgB,IAC7DA,EAAU,iBACT,IAAI,CAACI,OAAU;AAAA,IACd,OAAO,OAAOA,EAAK,SAAU,WAAWA,EAAK,MAAM,SAAS;AAAA,IAC5D,OAAOA,EAAK,UAAU;AAAA,IACtB,aAAaA,EAAK,gBAAgB;AAAA,IAClC,MAAMA,EAAK,SAAS;AAAA,EAAA,EACpB,EACD,OAAO,CAACA,MAASA,EAAK,MAAM,SAAS,CAAC,IACvC,CAAA;AAEJ,SAAO;AAAA,IACL,iBAAiBF;AAAA,IACjB,kBAAAC;AAAA,IACA,GAAI,OAAOH,GAAU,oBAAqB,WAAW,EAAE,kBAAkBA,EAAS,qBAAqB,CAAA;AAAA,EAAC;AAE5G,GAEMK,IAAkB,CAACC,MAAuF;AAC9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C,EAAK;AAAA,gBACd,UAAU,CAACqC,MACTR,EAAiB7B,EAAK,OAAO,CAACgC,OAAO,EAAE,GAAGA,GAAG,OAAOK,EAAE,OAAO,UAAU;AAAA,cAAA;AAAA,YAAA,GAG7E;AAAA,YACAJ,gBAAAA,EAAAA,IAAC,MAAA,EAAG,WAAU,aACZ,UAAAA,gBAAAA,EAAAA;AAAAA,cAAC;AAAA,cAAA;AAAA,gBACC,MAAK;AAAA,gBACL,SAASjC,EAAK;AAAA,gBACd,UAAU,CAACqC,MACTR,EAAiB7B,EAAK,OAAO,CAACgC,OAAO,EAAE,GAAGA,GAAG,aAAaK,EAAE,OAAO,UAAU;AAAA,cAAA;AAAA,YAAA,GAGnF;AAAA,YACAJ,gBAAAA,EAAAA,IAAC,MAAA,EAAG,WAAU,aACZ,UAAAA,gBAAAA,EAAAA;AAAAA,cAAC;AAAA,cAAA;AAAA,gBACC,MAAK;AAAA,gBACL,SAASjC,EAAK;AAAA,gBACd,UAAQ;AAAA,gBACR,WAAU;AAAA,gBACV,cAAW;AAAA,cAAA;AAAA,YAAA,EACb,CACF;AAAA,UAAA,EAAA,GApCOA,EAAK,KAqCd;AAAA,QAEJ,CAAC,EAAA,CACH;AAAA,MAAA,EAAA,CACF,EAAA,CACF;AAAA,MAGDgB,IACCiB,gBAAAA,EAAAA,IAAC,OAAA,EAAI,WAAU,iCAAiC,UAAAjB,EAAA,CAAM,IACpDF,IACFmB,gBAAAA,EAAAA,IAAC,OAAA,EAAI,WAAU,sCAAqC,qBAAO,IACzD;AAAA,IAAA,EAAA,CACN;AAAA,EAAA,GACF;AAEJ;"}
1
+ {"version":3,"file":"index25.js","sources":["../src/components/Notifications/NotificationsSettings.tsx"],"sourcesContent":["import { useEffect, useMemo, useState } from \"react\"\nimport { Loader2 } from \"lucide-react\"\n\nimport { cn } from \"@/lib/utils\"\n\nimport type { NotificationDigestFrequency, NotificationSettings, NotificationTopicCatalogItem, NotificationTopicPreference } from \"./types\"\n\n\ntype SettingsResponse = {\n ok?: boolean\n error?: string\n settings?: NotificationSettings\n}\n\nconst digestValues: Array<{ value: NotificationDigestFrequency; label: string }> = [\n { value: \"off\", label: \"Off\" },\n { value: \"daily\", label: \"Daily\" },\n { value: \"weekly\", label: \"Weekly\" },\n]\n\nconst normalizeSettings = (settings: NotificationSettings | undefined): NotificationSettings => {\n const digestFrequency = settings?.digestFrequency\n const frequency: NotificationDigestFrequency =\n digestFrequency === \"off\" || digestFrequency === \"daily\" || digestFrequency === \"weekly\"\n ? digestFrequency\n : \"weekly\"\n\n const topicPreferences = Array.isArray(settings?.topicPreferences)\n ? settings!.topicPreferences\n .map((pref) => ({\n topic: typeof pref.topic === \"string\" ? pref.topic.trim() : \"\",\n inApp: pref.inApp === true,\n emailDigest: pref.emailDigest === true,\n push: pref.push === true,\n }))\n .filter((pref) => pref.topic.length > 0)\n : []\n\n return {\n digestFrequency: frequency,\n topicPreferences,\n ...(typeof settings?.lastDigestSentAt === \"string\" ? { lastDigestSentAt: settings.lastDigestSentAt } : {}),\n }\n}\n\nconst normalizeTopics = (topics: NotificationTopicCatalogItem[] | undefined): NotificationTopicCatalogItem[] => {\n if (!Array.isArray(topics)) return []\n\n const seen = new Set<string>()\n return topics\n .map((topic) => ({\n topic: typeof topic.topic === \"string\" ? topic.topic.trim() : \"\",\n title: typeof topic.title === \"string\" ? topic.title.trim() : \"\",\n description: typeof topic.description === \"string\" ? topic.description.trim() : undefined,\n }))\n .filter((topic) => topic.topic.length > 0)\n .filter((topic) => {\n if (seen.has(topic.topic)) return false\n seen.add(topic.topic)\n return true\n })\n}\n\nconst applyTopicsToSettings = (\n settings: NotificationSettings,\n topics: NotificationTopicCatalogItem[],\n): NotificationSettings => {\n const defaults: NotificationTopicPreference = {\n topic: \"\",\n inApp: true,\n emailDigest: true,\n push: false,\n }\n\n const byTopic = new Map(settings.topicPreferences.map((pref) => [pref.topic, pref]))\n return {\n ...settings,\n topicPreferences: topics.map((topic) => {\n const existing = byTopic.get(topic.topic)\n return existing\n ? {\n topic: topic.topic,\n inApp: existing.inApp === true,\n emailDigest: existing.emailDigest === true,\n push: existing.push === true,\n }\n : {\n ...defaults,\n topic: topic.topic,\n }\n }),\n }\n}\n\nexport function NotificationsSettings({\n className,\n topics,\n}: {\n className?: string\n topics?: NotificationTopicCatalogItem[]\n}) {\n const [loading, setLoading] = useState(true)\n const [saving, setSaving] = useState(false)\n const [error, setError] = useState<string | null>(null)\n const [settings, setSettings] = useState<NotificationSettings>(() =>\n normalizeSettings({ digestFrequency: \"weekly\", topicPreferences: [] }),\n )\n\n const normalizedTopics = useMemo(() => normalizeTopics(topics), [topics])\n\n const loadSettings = async () => {\n setLoading(true)\n setError(null)\n try {\n const res = await fetch(\"/api/rb/notifications/settings\", {\n method: \"GET\",\n credentials: \"include\",\n })\n const json = (await res.json().catch(() => null)) as SettingsResponse | null\n if (!res.ok || !json?.ok) {\n setError(json?.error || \"Unable to load notification settings.\")\n return\n }\n const normalized = normalizeSettings(json.settings)\n setSettings(normalizedTopics.length > 0 ? applyTopicsToSettings(normalized, normalizedTopics) : normalized)\n } catch {\n setError(\"Unable to load notification settings.\")\n } finally {\n setLoading(false)\n }\n }\n\n const saveSettings = async (next: NotificationSettings) => {\n setSaving(true)\n setError(null)\n try {\n const res = await fetch(\"/api/rb/notifications/settings\", {\n method: \"PUT\",\n headers: { \"Content-Type\": \"application/json\" },\n credentials: \"include\",\n body: JSON.stringify({\n digestFrequency: next.digestFrequency,\n topicPreferences: next.topicPreferences,\n }),\n })\n const json = (await res.json().catch(() => null)) as SettingsResponse | null\n if (!res.ok || !json?.ok) {\n setError(json?.error || \"Unable to save notification settings.\")\n return\n }\n const normalized = normalizeSettings(json.settings)\n setSettings(normalizedTopics.length > 0 ? applyTopicsToSettings(normalized, normalizedTopics) : normalized)\n } catch {\n setError(\"Unable to save notification settings.\")\n } finally {\n setSaving(false)\n }\n }\n\n useEffect(() => {\n void loadSettings()\n }, [])\n\n useEffect(() => {\n if (normalizedTopics.length === 0) return\n setSettings((current) => applyTopicsToSettings(current, normalizedTopics))\n }, [normalizedTopics])\n\n const updatePreference = (topic: string, update: (p: NotificationTopicPreference) => NotificationTopicPreference) => {\n const hasExisting = settings.topicPreferences.some((p) => p.topic === topic)\n const nextPrefs = hasExisting\n ? settings.topicPreferences.map((p) => (p.topic === topic ? update(p) : p))\n : [...settings.topicPreferences, update({ topic, inApp: true, emailDigest: true, push: false })]\n const next = normalizeSettings({ ...settings, topicPreferences: nextPrefs })\n setSettings(next)\n void saveSettings(next)\n }\n\n if (loading) {\n return (\n <div className={cn(\"flex items-center justify-center py-10 text-muted-foreground\", className)}>\n <Loader2 className=\"h-4 w-4 animate-spin\" />\n </div>\n )\n }\n\n return (\n <div className={cn(\"space-y-4\", className)}>\n <div className=\"rounded-md border bg-background p-4\">\n <div className=\"flex items-start justify-between gap-3\">\n <div>\n <div className=\"text-sm font-semibold\">Email digest</div>\n <div className=\"mt-1 text-xs text-muted-foreground\">Choose how often we email you a summary.</div>\n </div>\n <select\n value={settings.digestFrequency}\n onChange={(e) => {\n const value = e.target.value as NotificationDigestFrequency\n const next = normalizeSettings({ ...settings, digestFrequency: value })\n setSettings(next)\n void saveSettings(next)\n }}\n className=\"h-9 rounded-md border bg-background px-2 text-sm\"\n >\n {digestValues.map((opt) => (\n <option key={opt.value} value={opt.value}>\n {opt.label}\n </option>\n ))}\n </select>\n </div>\n </div>\n\n <div className=\"rounded-md border bg-background p-4\">\n <div className=\"flex items-start justify-between gap-3\">\n <div>\n <div className=\"text-sm font-semibold\">Topics</div>\n <div className=\"mt-1 text-xs text-muted-foreground\">Choose where you receive each topic.</div>\n </div>\n </div>\n\n {normalizedTopics.length === 0 ? (\n <div className=\"mt-4 text-sm text-muted-foreground\">No topics configured.</div>\n ) : (\n <div className=\"mt-4 overflow-x-auto\">\n <table className=\"w-full text-sm\">\n <thead>\n <tr className=\"text-left text-xs text-muted-foreground\">\n <th className=\"py-2 pr-4 font-medium\">Topic</th>\n <th className=\"py-2 pr-4 font-medium\">In-app</th>\n <th className=\"py-2 pr-4 font-medium\">Email digest</th>\n <th className=\"py-2 pr-4 font-medium\">Push</th>\n </tr>\n </thead>\n <tbody>\n {settings.topicPreferences.map((pref) => {\n const meta = normalizedTopics.find((topic) => topic.topic === pref.topic)\n return (\n <tr key={pref.topic} className=\"border-t align-top\">\n <td className=\"py-3 pr-4\">\n <div className=\"flex flex-col gap-1\">\n <span className=\"font-medium\">{meta?.title || pref.topic}</span>\n {meta?.description ? (\n <span className=\"text-xs text-muted-foreground\">{meta.description}</span>\n ) : null}\n <span className=\"text-[11px] text-muted-foreground\">{pref.topic}</span>\n </div>\n </td>\n <td className=\"py-3 pr-4\">\n <input\n type=\"checkbox\"\n checked={pref.inApp}\n onChange={(e) =>\n updatePreference(pref.topic, (p) => ({ ...p, inApp: e.target.checked }))\n }\n />\n </td>\n <td className=\"py-3 pr-4\">\n <input\n type=\"checkbox\"\n checked={pref.emailDigest}\n onChange={(e) =>\n updatePreference(pref.topic, (p) => ({ ...p, emailDigest: e.target.checked }))\n }\n />\n </td>\n <td className=\"py-3 pr-4\">\n <input\n type=\"checkbox\"\n checked={pref.push}\n disabled\n className=\"opacity-50\"\n aria-label=\"Push notifications (coming soon)\"\n />\n </td>\n </tr>\n )\n })}\n </tbody>\n </table>\n </div>\n )}\n\n {error ? (\n <div className=\"mt-3 text-sm text-destructive\">{error}</div>\n ) : saving ? (\n <div className=\"mt-3 text-xs text-muted-foreground\">Saving…</div>\n ) : null}\n </div>\n </div>\n )\n}\n"],"names":["digestValues","value","label","normalizeSettings","settings","digestFrequency","frequency","topicPreferences","Array","isArray","map","pref","topic","trim","inApp","emailDigest","push","filter","length","lastDigestSentAt","normalizeTopics","topics","seen","Set","title","description","undefined","has","add","applyTopicsToSettings","defaults","byTopic","Map","existing","get","NotificationsSettings","className","loading","setLoading","useState","saving","setSaving","error","setError","setSettings","normalizedTopics","useMemo","loadSettings","res","fetch","method","credentials","json","catch","ok","normalized","saveSettings","next","headers","body","JSON","stringify","useEffect","current","updatePreference","update","nextPrefs","some","p","jsx","cn","Loader2","jsxs","e","target","opt","meta","find","checked"],"mappings":";;;;AAcA,MAAMA,IAA6E,CACjF;AAAA,EAAEC,OAAO;AAAA,EAAOC,OAAO;AAAM,GAC7B;AAAA,EAAED,OAAO;AAAA,EAASC,OAAO;AAAQ,GACjC;AAAA,EAAED,OAAO;AAAA,EAAUC,OAAO;AAAS,CAAC,GAGhCC,IAAoBA,CAACC,MAAqE;AAC9F,QAAMC,IAAkBD,GAAUC,iBAC5BC,IACJD,MAAoB,SAASA,MAAoB,WAAWA,MAAoB,WAC5EA,IACA,UAEAE,IAAmBC,MAAMC,QAAQL,GAAUG,gBAAgB,IAC7DH,EAAUG,iBACTG,IAAKC,CAAAA,OAAU;AAAA,IACdC,OAAO,OAAOD,EAAKC,SAAU,WAAWD,EAAKC,MAAMC,SAAS;AAAA,IAC5DC,OAAOH,EAAKG,UAAU;AAAA,IACtBC,aAAaJ,EAAKI,gBAAgB;AAAA,IAClCC,MAAML,EAAKK,SAAS;AAAA,EAAA,EACpB,EACDC,OAAQN,CAAAA,MAASA,EAAKC,MAAMM,SAAS,CAAC,IACvC,CAAA;AAEJ,SAAO;AAAA,IACLb,iBAAiBC;AAAAA,IACjBC,kBAAAA;AAAAA,IACA,GAAI,OAAOH,GAAUe,oBAAqB,WAAW;AAAA,MAAEA,kBAAkBf,EAASe;AAAAA,IAAAA,IAAqB,CAAA;AAAA,EAAC;AAE5G,GAEMC,IAAkBA,CAACC,MAAuF;AAC9G,MAAI,CAACb,MAAMC,QAAQY,CAAM,UAAU,CAAA;AAEnC,QAAMC,wBAAWC,IAAAA;AACjB,SAAOF,EACJX,IAAKE,CAAAA,OAAW;AAAA,IACfA,OAAO,OAAOA,EAAMA,SAAU,WAAWA,EAAMA,MAAMC,SAAS;AAAA,IAC9DW,OAAO,OAAOZ,EAAMY,SAAU,WAAWZ,EAAMY,MAAMX,SAAS;AAAA,IAC9DY,aAAa,OAAOb,E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AiBrD,EAAKC,OAAQwD,CAAAA,OAAO;AAAA,cAAE,GAAGA;AAAAA,cAAGtD,OAAO2D,EAAEC,OAAOI;AAAAA,YAAAA,EAAU,GACxE,GAEL;AAAA,kCACC,MAAA,EAAG,WAAU,aACZ,UAAAT,gBAAAA,EAAAA,IAAC,WACC,MAAK,YACL,SAAS1D,EAAKI,aACd,UAAW0D,CAAAA,MACTT,EAAiBrD,EAAKC,OAAQwD,CAAAA,OAAO;AAAA,cAAE,GAAGA;AAAAA,cAAGrD,aAAa0D,EAAEC,OAAOI;AAAAA,YAAAA,EAAU,GAC9E,GAEL;AAAA,kCACC,MAAA,EAAG,WAAU,aACZ,UAAAT,gBAAAA,EAAAA,IAAC,WACC,MAAK,YACL,SAAS1D,EAAKK,MACd,UAAQ,IACR,WAAU,cACV,cAAW,oCAAkC,EAAA,CAEjD;AAAA,UAAA,EAAA,GApCOL,EAAKC,KAqCd;AAAA,QAEJ,CAAC,EAAA,CACH;AAAA,MAAA,EAAA,CACF,EAAA,CACF;AAAA,MAGD8B,IACC2B,gBAAAA,EAAAA,IAAC,OAAA,EAAI,WAAU,iCAAiC3B,UAAAA,EAAAA,CAAM,IACpDF,IACF6B,gBAAAA,EAAAA,IAAC,OAAA,EAAI,WAAU,sCAAqC,qBAAO,IACzD;AAAA,IAAA,EAAA,CACN;AAAA,EAAA,GACF;AAEJ;"}
package/dist/index250.js CHANGED
@@ -1,90 +1,11 @@
1
- function i(r) {
2
- "@babel/helpers - typeof";
3
- return i = typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? function(t) {
4
- return typeof t;
5
- } : function(t) {
6
- return t && typeof Symbol == "function" && t.constructor === Symbol && t !== Symbol.prototype ? "symbol" : typeof t;
7
- }, i(r);
1
+ function a(c) {
2
+ const e = [];
3
+ return c.reduce((s, t) => {
4
+ const n = t.weeks.reduce((r, i) => r.concat(i.days.slice()), e.slice());
5
+ return s.concat(n.slice());
6
+ }, e.slice());
8
7
  }
9
- function a(r, t, n) {
10
- return Object.defineProperty(r, "prototype", { writable: !1 }), r;
11
- }
12
- function s(r, t) {
13
- if (!(r instanceof t)) throw new TypeError("Cannot call a class as a function");
14
- }
15
- function l(r, t, n) {
16
- return t = c(t), y(r, p() ? Reflect.construct(t, n || [], c(r).constructor) : t.apply(r, n));
17
- }
18
- function y(r, t) {
19
- if (t && (i(t) == "object" || typeof t == "function")) return t;
20
- if (t !== void 0) throw new TypeError("Derived constructors may only return object or undefined");
21
- return b(r);
22
- }
23
- function b(r) {
24
- if (r === void 0) throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
25
- return r;
26
- }
27
- function _(r, t) {
28
- if (typeof t != "function" && t !== null) throw new TypeError("Super expression must either be null or a function");
29
- r.prototype = Object.create(t && t.prototype, { constructor: { value: r, writable: !0, configurable: !0 } }), Object.defineProperty(r, "prototype", { writable: !1 }), t && u(r, t);
30
- }
31
- function f(r) {
32
- var t = typeof Map == "function" ? /* @__PURE__ */ new Map() : void 0;
33
- return f = function(e) {
34
- if (e === null || !v(e)) return e;
35
- if (typeof e != "function") throw new TypeError("Super expression must either be null or a function");
36
- if (t !== void 0) {
37
- if (t.has(e)) return t.get(e);
38
- t.set(e, o);
39
- }
40
- function o() {
41
- return h(e, arguments, c(this).constructor);
42
- }
43
- return o.prototype = Object.create(e.prototype, { constructor: { value: o, enumerable: !1, writable: !0, configurable: !0 } }), u(o, e);
44
- }, f(r);
45
- }
46
- function h(r, t, n) {
47
- if (p()) return Reflect.construct.apply(null, arguments);
48
- var e = [null];
49
- e.push.apply(e, t);
50
- var o = new (r.bind.apply(r, e))();
51
- return n && u(o, n.prototype), o;
52
- }
53
- function p() {
54
- try {
55
- var r = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {
56
- }));
57
- } catch {
58
- }
59
- return (p = function() {
60
- return !!r;
61
- })();
62
- }
63
- function v(r) {
64
- try {
65
- return Function.toString.call(r).indexOf("[native code]") !== -1;
66
- } catch {
67
- return typeof r == "function";
68
- }
69
- }
70
- function u(r, t) {
71
- return u = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function(n, e) {
72
- return n.__proto__ = e, n;
73
- }, u(r, t);
74
- }
75
- function c(r) {
76
- return c = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function(t) {
77
- return t.__proto__ || Object.getPrototypeOf(t);
78
- }, c(r);
79
- }
80
- var O = /* @__PURE__ */ (function(r) {
81
- function t(n) {
82
- var e;
83
- return s(this, t), e = l(this, t, [n]), Object.setPrototypeOf(e, t.prototype), e.name = e.constructor.name, e;
84
- }
85
- return _(t, r), a(t);
86
- })(/* @__PURE__ */ f(Error));
87
8
  export {
88
- O as default
9
+ a as getDays
89
10
  };
90
11
  //# sourceMappingURL=index250.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index250.js","sources":["../../../node_modules/libphonenumber-js/es6/ParseError.js"],"sourcesContent":["function _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 _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); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\n// https://stackoverflow.com/a/46971044/970769\n// \"Breaking changes in Typescript 2.1\"\n// \"Extending built-ins like Error, Array, and Map may no longer work.\"\n// \"As a recommendation, you can manually adjust the prototype immediately after any super(...) calls.\"\n// https://github.com/Microsoft/TypeScript-wiki/blob/main/Breaking-Changes.md#extending-built-ins-like-error-array-and-map-may-no-longer-work\nvar ParseError = /*#__PURE__*/function (_Error) {\n function ParseError(code) {\n var _this;\n _classCallCheck(this, ParseError);\n _this = _callSuper(this, ParseError, [code]);\n // Set the prototype explicitly.\n // Any subclass of FooError will have to manually set the prototype as well.\n Object.setPrototypeOf(_this, ParseError.prototype);\n _this.name = _this.constructor.name;\n return _this;\n }\n _inherits(ParseError, _Error);\n return _createClass(ParseError);\n}(/*#__PURE__*/_wrapNativeSuper(Error));\nexport { ParseError as default };\n//# sourceMappingURL=ParseError.js.map"],"names":["_typeof","o","_createClass","e","r","t","_classCallCheck","a","n","_callSuper","_getPrototypeOf","_possibleConstructorReturn","_isNativeReflectConstruct","_assertThisInitialized","_inherits","_setPrototypeOf","_wrapNativeSuper","_isNativeFunction","Wrapper","_construct","p","ParseError","_Error","code","_this"],"mappings":"AAAA,SAASA,EAAQC,GAAG;AAAE;AAA2B,SAAOD,IAAwB,OAAO,UAArB,cAA2C,OAAO,OAAO,YAA1B,WAAqC,SAAUC,GAAG;AAAE,WAAO,OAAOA;AAAA,EAAG,IAAI,SAAUA,GAAG;AAAE,WAAOA,KAAmB,OAAO,UAArB,cAA+BA,EAAE,gBAAgB,UAAUA,MAAM,OAAO,YAAY,WAAW,OA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B,OAAOA,KAArB;AAAA,EAAwB;AAAE;AACvJ,SAASU,EAAgBV,GAAGF,GAAG;AAAE,SAAOY,IAAkB,OAAO,iBAAiB,OAAO,eAAe,KAAI,IAAK,SAAUV,GAAG,GAAG;AAAE,WAAOA,EAAE,YAAY,GAAGA;AAAA,EAAG,GAAGU,EAAgBV,GAAGF,CAAC;AAAG;AACxL,SAASO,EAAgBL,GAAG;AAAE,SAAOK,IAAkB,OAAO,iBAAiB,OAAO,eAAe,KAAI,IAAK,SAAU,GAAG;AAAE,WAAO,EAAE,aAAa,OAAO,eAAe,CAAC;AAAA,EAAG,GAAGA,EAAgBL,CAAC;AAAG;AAMjM,IAACgB,IAA0B,0BAAUC,GAAQ;AAC9C,WAASD,EAAWE,GAAM;AACxB,QAAIC;AACJ,WAAAlB,EAAgB,MAAMe,CAAU,GAChCG,IAAQf,EAAW,MAAMY,GAAY,CAACE,CAAI,CAAC,GAG3C,OAAO,eAAeC,GAAOH,EAAW,SAAS,GACjDG,EAAM,OAAOA,EAAM,YAAY,MACxBA;AAAA,EACT;AACA,SAAAV,EAAUO,GAAYC,CAAM,GACrBpB,EAAamB,CAAU;AAChC,GAAe,gBAAAL,EAAiB,KAAK,CAAC;","x_google_ignoreList":[0]}
1
+ {"version":3,"file":"index250.js","sources":["../../../node_modules/react-day-picker/dist/esm/helpers/getDays.js"],"sourcesContent":["/**\n * Returns all the days belonging to the calendar by merging the days in the\n * weeks for each month.\n *\n * @param calendarMonths The array of calendar months.\n * @returns An array of `CalendarDay` objects representing all the days in the\n * calendar.\n */\nexport function getDays(calendarMonths) {\n const initialDays = [];\n return calendarMonths.reduce((days, month) => {\n const weekDays = month.weeks.reduce((weekDays, week) => {\n return weekDays.concat(week.days.slice());\n }, initialDays.slice());\n return days.concat(weekDays.slice());\n }, initialDays.slice());\n}\n"],"names":["getDays","calendarMonths","initialDays","days","month","weekDays","week"],"mappings":"AAQO,SAASA,EAAQC,GAAgB;AACpC,QAAMC,IAAc,CAAA;AACpB,SAAOD,EAAe,OAAO,CAACE,GAAMC,MAAU;AAC1C,UAAMC,IAAWD,EAAM,MAAM,OAAO,CAACC,GAAUC,MACpCD,EAAS,OAAOC,EAAK,KAAK,MAAK,CAAE,GACzCJ,EAAY,OAAO;AACtB,WAAOC,EAAK,OAAOE,EAAS,MAAK,CAAE;AAAA,EACvC,GAAGH,EAAY,OAAO;AAC1B;","x_google_ignoreList":[0]}