@rpcbase/ui 0.248.0 → 0.250.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 (445) hide show
  1. package/dist/index105.js +36 -36
  2. package/dist/index117.js +6 -6
  3. package/dist/index120.js +10 -10
  4. package/dist/index122.js +2 -2
  5. package/dist/index123.js +3 -3
  6. package/dist/index124.js +1 -1
  7. package/dist/index126.js +2 -2
  8. package/dist/index128.js +2 -2
  9. package/dist/index167.js +3 -3
  10. package/dist/index172.js +9 -9
  11. package/dist/index175.js +1 -1
  12. package/dist/index176.js +4 -4
  13. package/dist/index178.js +1 -1
  14. package/dist/index182.js +2 -2
  15. package/dist/index184.js +5 -5
  16. package/dist/index185.js +13 -13
  17. package/dist/index186.js +1 -1
  18. package/dist/index188.js +6 -6
  19. package/dist/index189.js +1 -1
  20. package/dist/index192.js +2 -2
  21. package/dist/index193.js +6 -6
  22. package/dist/index194.js +20 -59
  23. package/dist/index194.js.map +1 -1
  24. package/dist/index195.js +66 -8
  25. package/dist/index195.js.map +1 -1
  26. package/dist/index196.js +6 -87
  27. package/dist/index196.js.map +1 -1
  28. package/dist/index197.js +5 -19
  29. package/dist/index197.js.map +1 -1
  30. package/dist/index198.js +11 -16
  31. package/dist/index198.js.map +1 -1
  32. package/dist/index199.js +3 -5
  33. package/dist/index199.js.map +1 -1
  34. package/dist/index200.js +49 -4
  35. package/dist/index200.js.map +1 -1
  36. package/dist/index201.js +4 -7
  37. package/dist/index201.js.map +1 -1
  38. package/dist/index202.js +29 -4
  39. package/dist/index202.js.map +1 -1
  40. package/dist/index203.js +16 -6
  41. package/dist/index203.js.map +1 -1
  42. package/dist/index204.js +5 -16
  43. package/dist/index204.js.map +1 -1
  44. package/dist/index205.js +21 -4
  45. package/dist/index205.js.map +1 -1
  46. package/dist/index206.js +53 -4
  47. package/dist/index206.js.map +1 -1
  48. package/dist/index207.js +20 -12
  49. package/dist/index207.js.map +1 -1
  50. package/dist/index208.js +41 -9
  51. package/dist/index208.js.map +1 -1
  52. package/dist/index209.js +39 -13
  53. package/dist/index209.js.map +1 -1
  54. package/dist/index210.js +46 -14
  55. package/dist/index210.js.map +1 -1
  56. package/dist/index211.js +20 -4
  57. package/dist/index211.js.map +1 -1
  58. package/dist/index212.js +70 -5
  59. package/dist/index212.js.map +1 -1
  60. package/dist/index213.js +17 -6
  61. package/dist/index213.js.map +1 -1
  62. package/dist/index214.js +3 -5
  63. package/dist/index214.js.map +1 -1
  64. package/dist/index215.js +11 -54
  65. package/dist/index215.js.map +1 -1
  66. package/dist/index216.js +13 -8
  67. package/dist/index216.js.map +1 -1
  68. package/dist/index217.js +18 -4
  69. package/dist/index217.js.map +1 -1
  70. package/dist/index218.js +36 -4
  71. package/dist/index218.js.map +1 -1
  72. package/dist/index219.js +239 -8
  73. package/dist/index219.js.map +1 -1
  74. package/dist/index220.js +252 -4
  75. package/dist/index220.js.map +1 -1
  76. package/dist/index221.js +68 -4
  77. package/dist/index221.js.map +1 -1
  78. package/dist/index222.js +99 -3
  79. package/dist/index222.js.map +1 -1
  80. package/dist/index223.js +83 -10
  81. package/dist/index223.js.map +1 -1
  82. package/dist/index224.js +3 -9
  83. package/dist/index224.js.map +1 -1
  84. package/dist/index225.js +29 -9
  85. package/dist/index225.js.map +1 -1
  86. package/dist/index226.js +16 -10
  87. package/dist/index226.js.map +1 -1
  88. package/dist/index227.js +35 -11
  89. package/dist/index227.js.map +1 -1
  90. package/dist/index228.js +17 -9
  91. package/dist/index228.js.map +1 -1
  92. package/dist/index229.js +3 -6
  93. package/dist/index229.js.map +1 -1
  94. package/dist/index230.js +26 -5
  95. package/dist/index230.js.map +1 -1
  96. package/dist/index231.js +28 -4
  97. package/dist/index231.js.map +1 -1
  98. package/dist/index232.js +4 -6
  99. package/dist/index232.js.map +1 -1
  100. package/dist/index233.js +78 -6
  101. package/dist/index233.js.map +1 -1
  102. package/dist/index234.js +272 -5
  103. package/dist/index234.js.map +1 -1
  104. package/dist/index235.js +10 -15
  105. package/dist/index235.js.map +1 -1
  106. package/dist/index236.js +10 -7
  107. package/dist/index236.js.map +1 -1
  108. package/dist/index237.js +25 -10
  109. package/dist/index237.js.map +1 -1
  110. package/dist/index238.js +16 -10
  111. package/dist/index238.js.map +1 -1
  112. package/dist/index239.js +125 -21
  113. package/dist/index239.js.map +1 -1
  114. package/dist/index240.js +5 -8
  115. package/dist/index240.js.map +1 -1
  116. package/dist/index241.js +65 -9
  117. package/dist/index241.js.map +1 -1
  118. package/dist/index242.js +14 -10
  119. package/dist/index242.js.map +1 -1
  120. package/dist/index243.js +7 -4
  121. package/dist/index243.js.map +1 -1
  122. package/dist/index244.js +5 -5
  123. package/dist/index244.js.map +1 -1
  124. package/dist/index245.js +3 -16
  125. package/dist/index245.js.map +1 -1
  126. package/dist/index246.js +10 -9
  127. package/dist/index246.js.map +1 -1
  128. package/dist/index247.js +7 -18
  129. package/dist/index247.js.map +1 -1
  130. package/dist/index248.js +132 -19
  131. package/dist/index248.js.map +1 -1
  132. package/dist/index249.js +397 -10
  133. package/dist/index249.js.map +1 -1
  134. package/dist/index250.js +5 -30
  135. package/dist/index250.js.map +1 -1
  136. package/dist/index251.js +52 -12
  137. package/dist/index251.js.map +1 -1
  138. package/dist/index252.js +11 -25
  139. package/dist/index252.js.map +1 -1
  140. package/dist/index253.js +27 -5
  141. package/dist/index253.js.map +1 -1
  142. package/dist/index254.js +12 -20
  143. package/dist/index254.js.map +1 -1
  144. package/dist/index255.js +57 -65
  145. package/dist/index255.js.map +1 -1
  146. package/dist/index256.js +8 -6
  147. package/dist/index256.js.map +1 -1
  148. package/dist/index257.js +87 -5
  149. package/dist/index257.js.map +1 -1
  150. package/dist/index258.js +19 -11
  151. package/dist/index258.js.map +1 -1
  152. package/dist/index259.js +16 -3
  153. package/dist/index259.js.map +1 -1
  154. package/dist/index260.js +4 -49
  155. package/dist/index260.js.map +1 -1
  156. package/dist/index261.js +6 -4
  157. package/dist/index261.js.map +1 -1
  158. package/dist/index262.js +6 -29
  159. package/dist/index262.js.map +1 -1
  160. package/dist/index263.js +4 -16
  161. package/dist/index263.js.map +1 -1
  162. package/dist/index264.js +6 -5
  163. package/dist/index264.js.map +1 -1
  164. package/dist/index265.js +16 -21
  165. package/dist/index265.js.map +1 -1
  166. package/dist/index266.js +4 -53
  167. package/dist/index266.js.map +1 -1
  168. package/dist/index267.js +4 -20
  169. package/dist/index267.js.map +1 -1
  170. package/dist/index268.js +12 -41
  171. package/dist/index268.js.map +1 -1
  172. package/dist/index269.js +9 -39
  173. package/dist/index269.js.map +1 -1
  174. package/dist/index270.js +14 -46
  175. package/dist/index270.js.map +1 -1
  176. package/dist/index271.js +13 -20
  177. package/dist/index271.js.map +1 -1
  178. package/dist/index272.js +4 -70
  179. package/dist/index272.js.map +1 -1
  180. package/dist/index273.js +5 -17
  181. package/dist/index273.js.map +1 -1
  182. package/dist/index274.js +6 -3
  183. package/dist/index274.js.map +1 -1
  184. package/dist/index275.js +5 -11
  185. package/dist/index275.js.map +1 -1
  186. package/dist/index276.js +53 -12
  187. package/dist/index276.js.map +1 -1
  188. package/dist/index277.js +8 -18
  189. package/dist/index277.js.map +1 -1
  190. package/dist/index278.js +4 -36
  191. package/dist/index278.js.map +1 -1
  192. package/dist/index279.js +4 -239
  193. package/dist/index279.js.map +1 -1
  194. package/dist/index280.js +8 -252
  195. package/dist/index280.js.map +1 -1
  196. package/dist/index281.js +4 -68
  197. package/dist/index281.js.map +1 -1
  198. package/dist/index282.js +4 -99
  199. package/dist/index282.js.map +1 -1
  200. package/dist/index283.js +3 -83
  201. package/dist/index283.js.map +1 -1
  202. package/dist/index284.js +10 -3
  203. package/dist/index284.js.map +1 -1
  204. package/dist/index285.js +9 -29
  205. package/dist/index285.js.map +1 -1
  206. package/dist/index286.js +9 -16
  207. package/dist/index286.js.map +1 -1
  208. package/dist/index287.js +11 -35
  209. package/dist/index287.js.map +1 -1
  210. package/dist/index288.js +10 -17
  211. package/dist/index288.js.map +1 -1
  212. package/dist/index289.js +9 -3
  213. package/dist/index289.js.map +1 -1
  214. package/dist/index290.js +6 -26
  215. package/dist/index290.js.map +1 -1
  216. package/dist/index291.js +5 -28
  217. package/dist/index291.js.map +1 -1
  218. package/dist/index292.js +5 -4
  219. package/dist/index292.js.map +1 -1
  220. package/dist/index293.js +5 -78
  221. package/dist/index293.js.map +1 -1
  222. package/dist/index294.js +6 -272
  223. package/dist/index294.js.map +1 -1
  224. package/dist/index295.js +5 -11
  225. package/dist/index295.js.map +1 -1
  226. package/dist/index296.js +16 -10
  227. package/dist/index296.js.map +1 -1
  228. package/dist/index297.js +7 -25
  229. package/dist/index297.js.map +1 -1
  230. package/dist/index298.js +10 -16
  231. package/dist/index298.js.map +1 -1
  232. package/dist/index299.js +9 -124
  233. package/dist/index299.js.map +1 -1
  234. package/dist/index300.js +21 -5
  235. package/dist/index300.js.map +1 -1
  236. package/dist/index301.js +8 -65
  237. package/dist/index301.js.map +1 -1
  238. package/dist/index302.js +10 -14
  239. package/dist/index302.js.map +1 -1
  240. package/dist/index303.js +9 -7
  241. package/dist/index303.js.map +1 -1
  242. package/dist/index304.js +4 -5
  243. package/dist/index304.js.map +1 -1
  244. package/dist/index305.js +5 -3
  245. package/dist/index305.js.map +1 -1
  246. package/dist/index306.js +16 -10
  247. package/dist/index306.js.map +1 -1
  248. package/dist/index307.js +9 -7
  249. package/dist/index307.js.map +1 -1
  250. package/dist/index308.js +17 -132
  251. package/dist/index308.js.map +1 -1
  252. package/dist/index309.js +18 -397
  253. package/dist/index309.js.map +1 -1
  254. package/dist/index310.js +13 -5
  255. package/dist/index310.js.map +1 -1
  256. package/dist/index311.js +29 -52
  257. package/dist/index311.js.map +1 -1
  258. package/dist/index312.js +12 -11
  259. package/dist/index312.js.map +1 -1
  260. package/dist/index313.js +25 -27
  261. package/dist/index313.js.map +1 -1
  262. package/dist/index314.js +5 -11
  263. package/dist/index314.js.map +1 -1
  264. package/dist/index317.js +1 -1
  265. package/dist/index318.js +1 -1
  266. package/dist/index321.js +2 -2
  267. package/dist/index322.js +1 -1
  268. package/dist/index325.js +1 -1
  269. package/dist/index330.js +3 -135
  270. package/dist/index330.js.map +1 -1
  271. package/dist/index331.js +134 -16
  272. package/dist/index331.js.map +1 -1
  273. package/dist/index332.js +17 -15
  274. package/dist/index332.js.map +1 -1
  275. package/dist/index333.js +15 -3
  276. package/dist/index333.js.map +1 -1
  277. package/dist/index334.js +2 -2
  278. package/dist/index338.js +24 -8
  279. package/dist/index338.js.map +1 -1
  280. package/dist/index339.js +28 -11
  281. package/dist/index339.js.map +1 -1
  282. package/dist/index340.js +15 -7
  283. package/dist/index340.js.map +1 -1
  284. package/dist/index341.js +8 -13
  285. package/dist/index341.js.map +1 -1
  286. package/dist/index342.js +11 -3
  287. package/dist/index342.js.map +1 -1
  288. package/dist/index343.js +8 -3
  289. package/dist/index343.js.map +1 -1
  290. package/dist/index344.js +12 -16
  291. package/dist/index344.js.map +1 -1
  292. package/dist/index345.js +3 -24
  293. package/dist/index345.js.map +1 -1
  294. package/dist/index346.js +3 -28
  295. package/dist/index346.js.map +1 -1
  296. package/dist/index347.js +50 -15
  297. package/dist/index347.js.map +1 -1
  298. package/dist/index348.js +5 -51
  299. package/dist/index348.js.map +1 -1
  300. package/dist/index349.js +4 -4
  301. package/dist/index351.js +17 -5
  302. package/dist/index351.js.map +1 -1
  303. package/dist/index357.js +1 -1
  304. package/dist/index358.js +5 -5
  305. package/dist/index359.js +1 -1
  306. package/dist/index362.js +4 -5
  307. package/dist/index362.js.map +1 -1
  308. package/dist/index363.js +6 -18
  309. package/dist/index363.js.map +1 -1
  310. package/dist/index364.js +3 -13
  311. package/dist/index364.js.map +1 -1
  312. package/dist/index365.js +12 -4
  313. package/dist/index365.js.map +1 -1
  314. package/dist/index366.js +19 -10
  315. package/dist/index366.js.map +1 -1
  316. package/dist/index367.js +45 -6
  317. package/dist/index367.js.map +1 -1
  318. package/dist/index368.js +18 -3
  319. package/dist/index368.js.map +1 -1
  320. package/dist/index369.js +5 -21
  321. package/dist/index369.js.map +1 -1
  322. package/dist/index370.js +200 -44
  323. package/dist/index370.js.map +1 -1
  324. package/dist/index371.js +73 -17
  325. package/dist/index371.js.map +1 -1
  326. package/dist/index372.js +124 -5
  327. package/dist/index372.js.map +1 -1
  328. package/dist/index373.js +4 -200
  329. package/dist/index373.js.map +1 -1
  330. package/dist/index374.js +18 -74
  331. package/dist/index374.js.map +1 -1
  332. package/dist/index375.js +12 -123
  333. package/dist/index375.js.map +1 -1
  334. package/dist/index379.js +4 -4
  335. package/dist/index380.js +3 -3
  336. package/dist/index382.js +1 -1
  337. package/dist/index384.js +1 -1
  338. package/dist/index385.js +2 -2
  339. package/dist/index388.js +2 -2
  340. package/dist/index389.js +2 -2
  341. package/dist/index392.js +3 -5
  342. package/dist/index392.js.map +1 -1
  343. package/dist/index393.js +3 -5
  344. package/dist/index393.js.map +1 -1
  345. package/dist/index394.js +5 -4
  346. package/dist/index394.js.map +1 -1
  347. package/dist/index395.js +4 -15
  348. package/dist/index395.js.map +1 -1
  349. package/dist/index396.js +4 -9
  350. package/dist/index396.js.map +1 -1
  351. package/dist/index397.js +15 -5
  352. package/dist/index397.js.map +1 -1
  353. package/dist/index398.js +8 -4
  354. package/dist/index398.js.map +1 -1
  355. package/dist/index399.js +5 -545
  356. package/dist/index399.js.map +1 -1
  357. package/dist/index400.js +5 -47
  358. package/dist/index400.js.map +1 -1
  359. package/dist/index401.js +543 -15
  360. package/dist/index401.js.map +1 -1
  361. package/dist/index402.js +47 -6
  362. package/dist/index402.js.map +1 -1
  363. package/dist/index403.js +17 -7
  364. package/dist/index403.js.map +1 -1
  365. package/dist/index404.js +5 -6
  366. package/dist/index404.js.map +1 -1
  367. package/dist/index405.js +7 -7
  368. package/dist/index405.js.map +1 -1
  369. package/dist/index406.js +6 -11
  370. package/dist/index406.js.map +1 -1
  371. package/dist/index407.js +7 -8
  372. package/dist/index407.js.map +1 -1
  373. package/dist/index408.js +11 -12
  374. package/dist/index408.js.map +1 -1
  375. package/dist/index409.js +9 -3
  376. package/dist/index409.js.map +1 -1
  377. package/dist/index410.js +13 -3
  378. package/dist/index410.js.map +1 -1
  379. package/dist/index411.js +3 -15
  380. package/dist/index411.js.map +1 -1
  381. package/dist/index412.js +15 -3
  382. package/dist/index412.js.map +1 -1
  383. package/dist/index413.js +1 -1
  384. package/dist/index414.js +7 -4
  385. package/dist/index414.js.map +1 -1
  386. package/dist/index415.js +2 -56
  387. package/dist/index415.js.map +1 -1
  388. package/dist/index416.js +43 -67
  389. package/dist/index416.js.map +1 -1
  390. package/dist/index417.js +56 -31
  391. package/dist/index417.js.map +1 -1
  392. package/dist/index418.js +8 -9
  393. package/dist/index418.js.map +1 -1
  394. package/dist/index419.js +2 -153
  395. package/dist/index419.js.map +1 -1
  396. package/dist/index420.js +54 -107
  397. package/dist/index420.js.map +1 -1
  398. package/dist/index421.js +55 -7
  399. package/dist/index421.js.map +1 -1
  400. package/dist/index422.js +33 -2
  401. package/dist/index422.js.map +1 -1
  402. package/dist/index423.js +4 -43
  403. package/dist/index423.js.map +1 -1
  404. package/dist/index424.js +55 -55
  405. package/dist/index424.js.map +1 -1
  406. package/dist/index425.js +68 -8
  407. package/dist/index425.js.map +1 -1
  408. package/dist/index426.js +31 -2
  409. package/dist/index426.js.map +1 -1
  410. package/dist/index427.js +9 -55
  411. package/dist/index427.js.map +1 -1
  412. package/dist/index428.js +152 -55
  413. package/dist/index428.js.map +1 -1
  414. package/dist/index429.js +107 -32
  415. package/dist/index429.js.map +1 -1
  416. package/dist/index430.js +2 -16
  417. package/dist/index430.js.map +1 -1
  418. package/dist/index431.js +2 -29
  419. package/dist/index431.js.map +1 -1
  420. package/dist/index432.js +2 -13
  421. package/dist/index432.js.map +1 -1
  422. package/dist/index433.js +2 -7
  423. package/dist/index433.js.map +1 -1
  424. package/dist/index434.js +16 -2
  425. package/dist/index434.js.map +1 -1
  426. package/dist/index435.js +29 -2
  427. package/dist/index435.js.map +1 -1
  428. package/dist/index436.js +13 -2
  429. package/dist/index436.js.map +1 -1
  430. package/dist/index437.js +7 -2
  431. package/dist/index437.js.map +1 -1
  432. package/dist/index49.js +30 -30
  433. package/dist/index50.js +21 -21
  434. package/dist/index51.js +1 -1
  435. package/dist/index52.js +8 -8
  436. package/dist/index53.js +2 -2
  437. package/dist/index55.js +16 -16
  438. package/dist/index56.js +4 -4
  439. package/dist/index57.js +3 -3
  440. package/dist/index58.js +7 -7
  441. package/dist/index59.js +4 -4
  442. package/dist/index60.js +12 -12
  443. package/dist/index61.js +2 -2
  444. package/dist/index62.js +2 -2
  445. package/package.json +1 -1
package/dist/index298.js CHANGED
@@ -1,20 +1,14 @@
1
- import * as e from "react";
2
- import { ownerDocument as m } from "./index284.js";
3
- import { useScrollLock as p } from "./index375.js";
4
- import { useIsoLayoutEffect as h } from "./index261.js";
5
- const S = 20;
6
- function L(t, c, o, l) {
7
- const [s, r] = e.useState(!1);
8
- h(() => {
9
- if (!t || !c || o == null) {
10
- r(!1);
11
- return;
12
- }
13
- const u = m(o).documentElement.clientWidth, f = o.offsetWidth;
14
- r(u > 0 && f > 0 && f >= u - S);
15
- }, [t, c, o]), p(t && (!c || s), l);
1
+ function i(e, o, h, r) {
2
+ const { numberOfMonths: f = 1 } = h, n = [];
3
+ for (let t = 0; t < f; t++) {
4
+ const s = r.addMonths(e, t);
5
+ if (o && s > o)
6
+ break;
7
+ n.push(s);
8
+ }
9
+ return n;
16
10
  }
17
11
  export {
18
- L as useAnchoredPopupScrollLock
12
+ i as getDisplayMonths
19
13
  };
20
14
  //# sourceMappingURL=index298.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index298.js","sources":["../../../node_modules/@base-ui/react/utils/useAnchoredPopupScrollLock.mjs"],"sourcesContent":["'use client';\n\nimport * as React from 'react';\nimport { ownerDocument } from '@base-ui/utils/owner';\nimport { useScrollLock } from '@base-ui/utils/useScrollLock';\nimport { useIsoLayoutEffect } from '@base-ui/utils/useIsoLayoutEffect';\n\n// Touch-opened popups normally avoid scroll locking so users can still swipe outside to dismiss.\n// This hook re-enables scroll lock only when the popup is effectively full-width.\n// Treat popups with up to 20px of total horizontal gutter as full-width so common ~10px side\n// padding still locks scroll, since that leaves too little outside space for a reliable swipe.\nconst VIEWPORT_WIDTH_TOLERANCE_PX = 20;\n\n/**\n * Manages scroll lock for anchored popups. For non-touch opens, scroll lock is applied when\n * enabled. For touch opens, scroll lock is applied only when the positioner width is effectively\n * viewport-sized.\n */\nexport function useAnchoredPopupScrollLock(enabled, touchOpen, positionerElement, referenceElement) {\n const [touchOpenShouldLockScroll, setTouchOpenShouldLockScroll] = React.useState(false);\n useIsoLayoutEffect(() => {\n if (!enabled || !touchOpen || positionerElement == null) {\n setTouchOpenShouldLockScroll(false);\n return;\n }\n const viewportWidth = ownerDocument(positionerElement).documentElement.clientWidth;\n const popupWidth = positionerElement.offsetWidth;\n setTouchOpenShouldLockScroll(viewportWidth > 0 && popupWidth > 0 && popupWidth >= viewportWidth - VIEWPORT_WIDTH_TOLERANCE_PX);\n }, [enabled, touchOpen, positionerElement]);\n useScrollLock(enabled && (!touchOpen || touchOpenShouldLockScroll), referenceElement);\n}"],"names":["VIEWPORT_WIDTH_TOLERANCE_PX","useAnchoredPopupScrollLock","enabled","touchOpen","positionerElement","referenceElement","touchOpenShouldLockScroll","setTouchOpenShouldLockScroll","React","useIsoLayoutEffect","viewportWidth","ownerDocument","popupWidth","useScrollLock"],"mappings":";;;;AAWA,MAAMA,IAA8B;AAO7B,SAASC,EAA2BC,GAASC,GAAWC,GAAmBC,GAAkB;AAClG,QAAM,CAACC,GAA2BC,CAA4B,IAAIC,EAAM,SAAS,EAAK;AACtF,EAAAC,EAAmB,MAAM;AACvB,QAAI,CAACP,KAAW,CAACC,KAAaC,KAAqB,MAAM;AACvD,MAAAG,EAA6B,EAAK;AAClC;AAAA,IACF;AACA,UAAMG,IAAgBC,EAAcP,CAAiB,EAAE,gBAAgB,aACjEQ,IAAaR,EAAkB;AACrC,IAAAG,EAA6BG,IAAgB,KAAKE,IAAa,KAAKA,KAAcF,IAAgBV,CAA2B;AAAA,EAC/H,GAAG,CAACE,GAASC,GAAWC,CAAiB,CAAC,GAC1CS,EAAcX,MAAY,CAACC,KAAaG,IAA4BD,CAAgB;AACtF;","x_google_ignoreList":[0]}
1
+ {"version":3,"file":"index298.js","sources":["../../../node_modules/react-day-picker/dist/esm/helpers/getDisplayMonths.js"],"sourcesContent":["/**\n * Returns the months to display in the calendar.\n *\n * @param firstDisplayedMonth The first month currently displayed in the\n * calendar.\n * @param calendarEndMonth The latest month the user can navigate to.\n * @param props The DayPicker props, including `numberOfMonths`.\n * @param dateLib The date library to use for date manipulation.\n * @returns An array of dates representing the months to display.\n */\nexport function getDisplayMonths(firstDisplayedMonth, calendarEndMonth, props, dateLib) {\n const { numberOfMonths = 1 } = props;\n const months = [];\n for (let i = 0; i < numberOfMonths; i++) {\n const month = dateLib.addMonths(firstDisplayedMonth, i);\n if (calendarEndMonth && month > calendarEndMonth) {\n break;\n }\n months.push(month);\n }\n return months;\n}\n"],"names":["getDisplayMonths","firstDisplayedMonth","calendarEndMonth","props","dateLib","numberOfMonths","months","i","month"],"mappings":"AAUO,SAASA,EAAiBC,GAAqBC,GAAkBC,GAAOC,GAAS;AACpF,QAAM,EAAE,gBAAAC,IAAiB,EAAC,IAAKF,GACzBG,IAAS,CAAA;AACf,WAASC,IAAI,GAAGA,IAAIF,GAAgBE,KAAK;AACrC,UAAMC,IAAQJ,EAAQ,UAAUH,GAAqBM,CAAC;AACtD,QAAIL,KAAoBM,IAAQN;AAC5B;AAEJ,IAAAI,EAAO,KAAKE,CAAK;AAAA,EACrB;AACA,SAAOF;AACX;","x_google_ignoreList":[0]}
package/dist/index299.js CHANGED
@@ -1,129 +1,14 @@
1
- const S = ["top", "right", "bottom", "left"], m = Math.min, h = Math.max, w = Math.round, C = Math.floor, j = (t) => ({
2
- x: t,
3
- y: t
4
- }), p = {
5
- left: "right",
6
- right: "left",
7
- bottom: "top",
8
- top: "bottom"
9
- };
10
- function L(t, n, e) {
11
- return h(t, m(n, e));
12
- }
13
- function E(t, n) {
14
- return typeof t == "function" ? t(n) : t;
15
- }
16
- function g(t) {
17
- return t.split("-")[0];
18
- }
19
- function a(t) {
20
- return t.split("-")[1];
21
- }
22
- function x(t) {
23
- return t === "x" ? "y" : "x";
24
- }
25
- function b(t) {
26
- return t === "y" ? "height" : "width";
27
- }
28
- function d(t) {
29
- const n = t[0];
30
- return n === "t" || n === "b" ? "y" : "x";
31
- }
32
- function A(t) {
33
- return x(d(t));
34
- }
35
- function R(t, n, e) {
36
- e === void 0 && (e = !1);
37
- const r = a(t), i = A(t), o = b(i);
38
- let c = i === "x" ? r === (e ? "end" : "start") ? "right" : "left" : r === "start" ? "bottom" : "top";
39
- return n.reference[o] > n.floating[o] && (c = f(c)), [c, f(c)];
40
- }
41
- function T(t) {
42
- const n = f(t);
43
- return [s(t), n, s(n)];
44
- }
45
- function s(t) {
46
- return t.includes("start") ? t.replace("start", "end") : t.replace("end", "start");
47
- }
48
- const u = ["left", "right"], l = ["right", "left"], P = ["top", "bottom"], y = ["bottom", "top"];
49
- function O(t, n, e) {
50
- switch (t) {
51
- case "top":
52
- case "bottom":
53
- return e ? n ? l : u : n ? u : l;
54
- case "left":
55
- case "right":
56
- return n ? P : y;
57
- default:
58
- return [];
1
+ function u(i, o, n, e) {
2
+ const { month: s, defaultMonth: M, today: c = e.today(), numberOfMonths: f = 1 } = i;
3
+ let t = s || M || c;
4
+ const { differenceInCalendarMonths: h, addMonths: l, startOfMonth: r } = e;
5
+ if (n && h(n, t) < f - 1) {
6
+ const d = -1 * (f - 1);
7
+ t = l(n, d);
59
8
  }
60
- }
61
- function k(t, n, e, r) {
62
- const i = a(t);
63
- let o = O(g(t), e === "start", r);
64
- return i && (o = o.map((c) => c + "-" + i), n && (o = o.concat(o.map(s)))), o;
65
- }
66
- function f(t) {
67
- const n = g(t);
68
- return p[n] + t.slice(n.length);
69
- }
70
- function M(t) {
71
- return {
72
- top: 0,
73
- right: 0,
74
- bottom: 0,
75
- left: 0,
76
- ...t
77
- };
78
- }
79
- function q(t) {
80
- return typeof t != "number" ? M(t) : {
81
- top: t,
82
- right: t,
83
- bottom: t,
84
- left: t
85
- };
86
- }
87
- function z(t) {
88
- const {
89
- x: n,
90
- y: e,
91
- width: r,
92
- height: i
93
- } = t;
94
- return {
95
- width: r,
96
- height: i,
97
- top: e,
98
- left: n,
99
- right: n + r,
100
- bottom: e + i,
101
- x: n,
102
- y: e
103
- };
9
+ return o && h(t, o) < 0 && (t = o), r(t);
104
10
  }
105
11
  export {
106
- L as clamp,
107
- j as createCoords,
108
- E as evaluate,
109
- M as expandPaddingObject,
110
- C as floor,
111
- a as getAlignment,
112
- A as getAlignmentAxis,
113
- R as getAlignmentSides,
114
- b as getAxisLength,
115
- T as getExpandedPlacements,
116
- s as getOppositeAlignmentPlacement,
117
- x as getOppositeAxis,
118
- k as getOppositeAxisPlacements,
119
- f as getOppositePlacement,
120
- q as getPaddingObject,
121
- g as getSide,
122
- d as getSideAxis,
123
- h as max,
124
- m as min,
125
- z as rectToClientRect,
126
- w as round,
127
- S as sides
12
+ u as getInitialMonth
128
13
  };
129
14
  //# sourceMappingURL=index299.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index299.js","sources":["../../../node_modules/@floating-ui/utils/dist/floating-ui.utils.mjs"],"sourcesContent":["/**\n * Custom positioning reference element.\n * @see https://floating-ui.com/docs/virtual-elements\n */\n\nconst sides = ['top', 'right', 'bottom', 'left'];\nconst alignments = ['start', 'end'];\nconst placements = /*#__PURE__*/sides.reduce((acc, side) => acc.concat(side, side + \"-\" + alignments[0], side + \"-\" + alignments[1]), []);\nconst min = Math.min;\nconst max = Math.max;\nconst round = Math.round;\nconst floor = Math.floor;\nconst createCoords = v => ({\n x: v,\n y: v\n});\nconst oppositeSideMap = {\n left: 'right',\n right: 'left',\n bottom: 'top',\n top: 'bottom'\n};\nfunction clamp(start, value, end) {\n return max(start, min(value, end));\n}\nfunction evaluate(value, param) {\n return typeof value === 'function' ? value(param) : value;\n}\nfunction getSide(placement) {\n return placement.split('-')[0];\n}\nfunction getAlignment(placement) {\n return placement.split('-')[1];\n}\nfunction getOppositeAxis(axis) {\n return axis === 'x' ? 'y' : 'x';\n}\nfunction getAxisLength(axis) {\n return axis === 'y' ? 'height' : 'width';\n}\nfunction getSideAxis(placement) {\n const firstChar = placement[0];\n return firstChar === 't' || firstChar === 'b' ? 'y' : 'x';\n}\nfunction getAlignmentAxis(placement) {\n return getOppositeAxis(getSideAxis(placement));\n}\nfunction getAlignmentSides(placement, rects, rtl) {\n if (rtl === void 0) {\n rtl = false;\n }\n const alignment = getAlignment(placement);\n const alignmentAxis = getAlignmentAxis(placement);\n const length = getAxisLength(alignmentAxis);\n let mainAlignmentSide = alignmentAxis === 'x' ? alignment === (rtl ? 'end' : 'start') ? 'right' : 'left' : alignment === 'start' ? 'bottom' : 'top';\n if (rects.reference[length] > rects.floating[length]) {\n mainAlignmentSide = getOppositePlacement(mainAlignmentSide);\n }\n return [mainAlignmentSide, getOppositePlacement(mainAlignmentSide)];\n}\nfunction getExpandedPlacements(placement) {\n const oppositePlacement = getOppositePlacement(placement);\n return [getOppositeAlignmentPlacement(placement), oppositePlacement, getOppositeAlignmentPlacement(oppositePlacement)];\n}\nfunction getOppositeAlignmentPlacement(placement) {\n return placement.includes('start') ? placement.replace('start', 'end') : placement.replace('end', 'start');\n}\nconst lrPlacement = ['left', 'right'];\nconst rlPlacement = ['right', 'left'];\nconst tbPlacement = ['top', 'bottom'];\nconst btPlacement = ['bottom', 'top'];\nfunction getSideList(side, isStart, rtl) {\n switch (side) {\n case 'top':\n case 'bottom':\n if (rtl) return isStart ? rlPlacement : lrPlacement;\n return isStart ? lrPlacement : rlPlacement;\n case 'left':\n case 'right':\n return isStart ? tbPlacement : btPlacement;\n default:\n return [];\n }\n}\nfunction getOppositeAxisPlacements(placement, flipAlignment, direction, rtl) {\n const alignment = getAlignment(placement);\n let list = getSideList(getSide(placement), direction === 'start', rtl);\n if (alignment) {\n list = list.map(side => side + \"-\" + alignment);\n if (flipAlignment) {\n list = list.concat(list.map(getOppositeAlignmentPlacement));\n }\n }\n return list;\n}\nfunction getOppositePlacement(placement) {\n const side = getSide(placement);\n return oppositeSideMap[side] + placement.slice(side.length);\n}\nfunction expandPaddingObject(padding) {\n return {\n top: 0,\n right: 0,\n bottom: 0,\n left: 0,\n ...padding\n };\n}\nfunction getPaddingObject(padding) {\n return typeof padding !== 'number' ? expandPaddingObject(padding) : {\n top: padding,\n right: padding,\n bottom: padding,\n left: padding\n };\n}\nfunction rectToClientRect(rect) {\n const {\n x,\n y,\n width,\n height\n } = rect;\n return {\n width,\n height,\n top: y,\n left: x,\n right: x + width,\n bottom: y + height,\n x,\n y\n };\n}\n\nexport { alignments, clamp, createCoords, evaluate, expandPaddingObject, floor, getAlignment, getAlignmentAxis, getAlignmentSides, getAxisLength, getExpandedPlacements, getOppositeAlignmentPlacement, getOppositeAxis, getOppositeAxisPlacements, getOppositePlacement, getPaddingObject, getSide, getSideAxis, max, min, placements, rectToClientRect, round, sides };\n"],"names":["sides","min","max","round","floor","createCoords","v","oppositeSideMap","clamp","start","value","end","evaluate","param","getSide","placement","getAlignment","getOppositeAxis","axis","getAxisLength","getSideAxis","firstChar","getAlignmentAxis","getAlignmentSides","rects","rtl","alignment","alignmentAxis","length","mainAlignmentSide","getOppositePlacement","getExpandedPlacements","oppositePlacement","getOppositeAlignmentPlacement","lrPlacement","rlPlacement","tbPlacement","btPlacement","getSideList","side","isStart","getOppositeAxisPlacements","flipAlignment","direction","list","expandPaddingObject","padding","getPaddingObject","rectToClientRect","rect","x","y","width","height"],"mappings":"AAKK,MAACA,IAAQ,CAAC,OAAO,SAAS,UAAU,MAAM,GAGzCC,IAAM,KAAK,KACXC,IAAM,KAAK,KACXC,IAAQ,KAAK,OACbC,IAAQ,KAAK,OACbC,IAAe,CAAAC,OAAM;AAAA,EACzB,GAAGA;AAAA,EACH,GAAGA;AACL,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AClE,KAAKA;AAAA,IACL,OAAOA;AAAA,IACP,QAAQA;AAAA,IACR,MAAMA;AAAA,EACV;AACA;AACA,SAASE,EAAiBC,GAAM;AAC9B,QAAM;AAAA,IACJ,GAAAC;AAAA,IACA,GAAAC;AAAA,IACA,OAAAC;AAAA,IACA,QAAAC;AAAA,EACJ,IAAMJ;AACJ,SAAO;AAAA,IACL,OAAAG;AAAA,IACA,QAAAC;AAAA,IACA,KAAKF;AAAA,IACL,MAAMD;AAAA,IACN,OAAOA,IAAIE;AAAA,IACX,QAAQD,IAAIE;AAAA,IACZ,GAAAH;AAAA,IACA,GAAAC;AAAA,EACJ;AACA;","x_google_ignoreList":[0]}
1
+ {"version":3,"file":"index299.js","sources":["../../../node_modules/react-day-picker/dist/esm/helpers/getInitialMonth.js"],"sourcesContent":["/**\n * Determines the initial month to display in the calendar based on the provided\n * props.\n *\n * This function calculates the starting month, considering constraints such as\n * `startMonth`, `endMonth`, and the number of months to display.\n *\n * @param props The DayPicker props, including navigation and date constraints.\n * @param dateLib The date library to use for date manipulation.\n * @returns The initial month to display.\n */\nexport function getInitialMonth(props, navStart, navEnd, dateLib) {\n const { month, defaultMonth, today = dateLib.today(), numberOfMonths = 1, } = props;\n let initialMonth = month || defaultMonth || today;\n const { differenceInCalendarMonths, addMonths, startOfMonth } = dateLib;\n if (navEnd &&\n differenceInCalendarMonths(navEnd, initialMonth) < numberOfMonths - 1) {\n const offset = -1 * (numberOfMonths - 1);\n initialMonth = addMonths(navEnd, offset);\n }\n if (navStart && differenceInCalendarMonths(initialMonth, navStart) < 0) {\n initialMonth = navStart;\n }\n return startOfMonth(initialMonth);\n}\n"],"names":["getInitialMonth","props","navStart","navEnd","dateLib","month","defaultMonth","today","numberOfMonths","initialMonth","differenceInCalendarMonths","addMonths","startOfMonth","offset"],"mappings":"AAWO,SAASA,EAAgBC,GAAOC,GAAUC,GAAQC,GAAS;AAC9D,QAAM,EAAE,OAAAC,GAAO,cAAAC,GAAc,OAAAC,IAAQH,EAAQ,SAAS,gBAAAI,IAAiB,EAAC,IAAMP;AAC9E,MAAIQ,IAAeJ,KAASC,KAAgBC;AAC5C,QAAM,EAAE,4BAAAG,GAA4B,WAAAC,GAAW,cAAAC,EAAY,IAAKR;AAChE,MAAID,KACAO,EAA2BP,GAAQM,CAAY,IAAID,IAAiB,GAAG;AACvE,UAAMK,IAAS,MAAML,IAAiB;AACtC,IAAAC,IAAeE,EAAUR,GAAQU,CAAM;AAAA,EAC3C;AACA,SAAIX,KAAYQ,EAA2BD,GAAcP,CAAQ,IAAI,MACjEO,IAAeP,IAEZU,EAAaH,CAAY;AACpC;","x_google_ignoreList":[0]}
package/dist/index300.js CHANGED
@@ -1,9 +1,25 @@
1
- function t(e, n, r, d) {
2
- return e.addEventListener(n, r, d), () => {
3
- e.removeEventListener(n, r, d);
4
- };
1
+ import { CalendarDay as F } from "./index259.js";
2
+ import { CalendarWeek as N } from "./index261.js";
3
+ import { CalendarMonth as P } from "./index260.js";
4
+ function j(l, f, e, c) {
5
+ const { addDays: y, endOfBroadcastWeek: D, endOfISOWeek: h, endOfMonth: k, endOfWeek: C, getISOWeek: I, getWeek: M, startOfBroadcastWeek: S, startOfISOWeek: g, startOfWeek: w } = c, o = l.reduce((W, t) => {
6
+ const x = e.broadcastCalendar ? S(t, c) : e.ISOWeek ? g(t) : w(t), d = e.broadcastCalendar ? D(t) : e.ISOWeek ? h(k(t)) : C(k(t)), a = f.filter((r) => r >= x && r <= d), O = e.broadcastCalendar ? 35 : 42;
7
+ if (e.fixedWeeks && a.length < O) {
8
+ const r = f.filter((n) => {
9
+ const s = O - a.length;
10
+ return n > d && n <= y(d, s);
11
+ });
12
+ a.push(...r);
13
+ }
14
+ const b = a.reduce((r, n) => {
15
+ const s = e.ISOWeek ? I(n) : M(n), i = r.find((B) => B.weekNumber === s), u = new F(n, t, c);
16
+ return i ? i.days.push(u) : r.push(new N(s, [u])), r;
17
+ }, []), v = new P(t, b);
18
+ return W.push(v), W;
19
+ }, []);
20
+ return e.reverseMonths ? o.reverse() : o;
5
21
  }
6
22
  export {
7
- t as addEventListener
23
+ j as getMonths
8
24
  };
9
25
  //# sourceMappingURL=index300.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index300.js","sources":["../../../node_modules/@base-ui/utils/addEventListener.mjs"],"sourcesContent":["/**\n * Adds an event listener and returns a cleanup function to remove it.\n */\n\nexport function addEventListener(target, type, listener, options) {\n target.addEventListener(type, listener, options);\n return () => {\n target.removeEventListener(type, listener, options);\n };\n}"],"names":["addEventListener","target","type","listener","options"],"mappings":"AAIO,SAASA,EAAiBC,GAAQC,GAAMC,GAAUC,GAAS;AAChE,SAAAH,EAAO,iBAAiBC,GAAMC,GAAUC,CAAO,GACxC,MAAM;AACX,IAAAH,EAAO,oBAAoBC,GAAMC,GAAUC,CAAO;AAAA,EACpD;AACF;","x_google_ignoreList":[0]}
1
+ {"version":3,"file":"index300.js","sources":["../../../node_modules/react-day-picker/dist/esm/helpers/getMonths.js"],"sourcesContent":["import { CalendarDay, CalendarMonth, CalendarWeek } from \"../classes/index.js\";\n/**\n * Returns the months to display in the calendar.\n *\n * This function generates `CalendarMonth` objects for each month to be\n * displayed, including their weeks and days, based on the provided display\n * months and dates.\n *\n * @param displayMonths The months (as dates) to display in the calendar.\n * @param dates The dates to display in the calendar.\n * @param props Options from the DayPicker props context.\n * @param dateLib The date library to use for date manipulation.\n * @returns An array of `CalendarMonth` objects representing the months to\n * display.\n */\nexport function getMonths(displayMonths, dates, props, dateLib) {\n const { addDays, endOfBroadcastWeek, endOfISOWeek, endOfMonth, endOfWeek, getISOWeek, getWeek, startOfBroadcastWeek, startOfISOWeek, startOfWeek, } = dateLib;\n const dayPickerMonths = displayMonths.reduce((months, month) => {\n const firstDateOfFirstWeek = props.broadcastCalendar\n ? startOfBroadcastWeek(month, dateLib)\n : props.ISOWeek\n ? startOfISOWeek(month)\n : startOfWeek(month);\n const lastDateOfLastWeek = props.broadcastCalendar\n ? endOfBroadcastWeek(month)\n : props.ISOWeek\n ? endOfISOWeek(endOfMonth(month))\n : endOfWeek(endOfMonth(month));\n /** The dates to display in the month. */\n const monthDates = dates.filter((date) => {\n return date >= firstDateOfFirstWeek && date <= lastDateOfLastWeek;\n });\n const nrOfDaysWithFixedWeeks = props.broadcastCalendar ? 35 : 42;\n if (props.fixedWeeks && monthDates.length < nrOfDaysWithFixedWeeks) {\n const extraDates = dates.filter((date) => {\n const daysToAdd = nrOfDaysWithFixedWeeks - monthDates.length;\n return (date > lastDateOfLastWeek &&\n date <= addDays(lastDateOfLastWeek, daysToAdd));\n });\n monthDates.push(...extraDates);\n }\n const weeks = monthDates.reduce((weeks, date) => {\n const weekNumber = props.ISOWeek ? getISOWeek(date) : getWeek(date);\n const week = weeks.find((week) => week.weekNumber === weekNumber);\n const day = new CalendarDay(date, month, dateLib);\n if (!week) {\n weeks.push(new CalendarWeek(weekNumber, [day]));\n }\n else {\n week.days.push(day);\n }\n return weeks;\n }, []);\n const dayPickerMonth = new CalendarMonth(month, weeks);\n months.push(dayPickerMonth);\n return months;\n }, []);\n if (!props.reverseMonths) {\n return dayPickerMonths;\n }\n else {\n return dayPickerMonths.reverse();\n }\n}\n"],"names":["getMonths","displayMonths","dates","props","dateLib","addDays","endOfBroadcastWeek","endOfISOWeek","endOfMonth","endOfWeek","getISOWeek","getWeek","startOfBroadcastWeek","startOfISOWeek","startOfWeek","dayPickerMonths","months","month","firstDateOfFirstWeek","lastDateOfLastWeek","monthDates","date","nrOfDaysWithFixedWeeks","extraDates","daysToAdd","weeks","weekNumber","week","day","CalendarDay","CalendarWeek","dayPickerMonth","CalendarMonth"],"mappings":";;;AAeO,SAASA,EAAUC,GAAeC,GAAOC,GAAOC,GAAS;AAC5D,QAAM,EAAE,SAAAC,GAAS,oBAAAC,GAAoB,cAAAC,GAAc,YAAAC,GAAY,WAAAC,GAAW,YAAAC,GAAY,SAAAC,GAAS,sBAAAC,GAAsB,gBAAAC,GAAgB,aAAAC,EAAW,IAAMV,GAChJW,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1,12 @@
1
- import { useRefWithInit as u } from "./index256.js";
2
- import { useOnMount as h } from "./index367.js";
3
- const s = null;
4
- let l = globalThis.requestAnimationFrame;
5
- class o {
6
- /* This implementation uses an array as a backing data-structure for frame callbacks.
7
- * It allows `O(1)` callback cancelling by inserting a `null` in the array, though it
8
- * never calls the native `cancelAnimationFrame` if there are no frames left. This can
9
- * be much more efficient if there is a call pattern that alterns as
10
- * "request-cancel-request-cancel-…".
11
- * But in the case of "request-request-…-cancel-cancel-…", it leaves the final animation
12
- * frame to run anyway. We turn that frame into a `O(1)` no-op via `callbacksCount`. */
13
- callbacks = [];
14
- callbacksCount = 0;
15
- nextId = 1;
16
- startId = 1;
17
- isScheduled = !1;
18
- tick = (t) => {
19
- this.isScheduled = !1;
20
- const e = this.callbacks, r = this.callbacksCount;
21
- if (this.callbacks = [], this.callbacksCount = 0, this.startId = this.nextId, r > 0)
22
- for (let i = 0; i < e.length; i += 1)
23
- e[i]?.(t);
24
- };
25
- request(t) {
26
- const e = this.nextId;
27
- this.nextId += 1, this.callbacks.push(t), this.callbacksCount += 1;
28
- const r = process.env.NODE_ENV !== "production" && l !== requestAnimationFrame && (l = requestAnimationFrame, !0);
29
- return (!this.isScheduled || r) && (requestAnimationFrame(this.tick), this.isScheduled = !0), e;
30
- }
31
- cancel(t) {
32
- const e = t - this.startId;
33
- e < 0 || e >= this.callbacks.length || (this.callbacks[e] = null, this.callbacksCount -= 1);
34
- }
35
- }
36
- const c = new o();
37
- class a {
38
- static create() {
39
- return new a();
40
- }
41
- static request(t) {
42
- return c.request(t);
43
- }
44
- static cancel(t) {
45
- return c.cancel(t);
46
- }
47
- currentId = s;
48
- /**
49
- * Executes `fn` after `delay`, clearing any previously scheduled call.
50
- */
51
- request(t) {
52
- this.cancel(), this.currentId = c.request(() => {
53
- this.currentId = s, t();
54
- });
55
- }
56
- cancel = () => {
57
- this.currentId !== s && (c.cancel(this.currentId), this.currentId = s);
58
- };
59
- disposeEffect = () => this.cancel;
60
- }
61
- function k() {
62
- const n = u(a.create).current;
63
- return h(n.disposeEffect), n;
1
+ function c(n, r) {
2
+ let { startMonth: t, endMonth: a } = n;
3
+ const { startOfYear: f, startOfDay: o, startOfMonth: s, endOfMonth: i, addYears: y, endOfYear: h, today: e } = r, d = n.captionLayout === "dropdown" || n.captionLayout === "dropdown-years";
4
+ return t ? t = s(t) : !t && d && (t = f(y(n.today ?? e(), -100))), a ? a = i(a) : !a && d && (a = h(n.today ?? e())), [
5
+ t && o(t),
6
+ a && o(a)
7
+ ];
64
8
  }
65
9
  export {
66
- a as AnimationFrame,
67
- k as useAnimationFrame
10
+ c as getNavMonths
68
11
  };
69
12
  //# sourceMappingURL=index301.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index301.js","sources":["../../../node_modules/@base-ui/utils/useAnimationFrame.mjs"],"sourcesContent":["'use client';\n\nimport { useRefWithInit } from \"./useRefWithInit.mjs\";\nimport { useOnMount } from \"./useOnMount.mjs\";\n/** Unlike `setTimeout`, rAF doesn't guarantee a positive integer return value, so we can't have\n * a monomorphic `uint` type with `0` meaning empty.\n * See warning note at:\n * https://developer.mozilla.org/en-US/docs/Web/API/Window/requestAnimationFrame#return_value */\nconst EMPTY = null;\nlet LAST_RAF = globalThis.requestAnimationFrame;\nclass Scheduler {\n /* This implementation uses an array as a backing data-structure for frame callbacks.\n * It allows `O(1)` callback cancelling by inserting a `null` in the array, though it\n * never calls the native `cancelAnimationFrame` if there are no frames left. This can\n * be much more efficient if there is a call pattern that alterns as\n * \"request-cancel-request-cancel-…\".\n * But in the case of \"request-request-…-cancel-cancel-…\", it leaves the final animation\n * frame to run anyway. We turn that frame into a `O(1)` no-op via `callbacksCount`. */\n\n callbacks = [];\n callbacksCount = 0;\n nextId = 1;\n startId = 1;\n isScheduled = false;\n tick = timestamp => {\n this.isScheduled = false;\n const currentCallbacks = this.callbacks;\n const currentCallbacksCount = this.callbacksCount;\n\n // Update these before iterating, callbacks could call `requestAnimationFrame` again.\n this.callbacks = [];\n this.callbacksCount = 0;\n this.startId = this.nextId;\n if (currentCallbacksCount > 0) {\n for (let i = 0; i < currentCallbacks.length; i += 1) {\n currentCallbacks[i]?.(timestamp);\n }\n }\n };\n request(fn) {\n const id = this.nextId;\n this.nextId += 1;\n this.callbacks.push(fn);\n this.callbacksCount += 1;\n\n /* In a test environment with fake timers, a fake `requestAnimationFrame` can be called\n * but there's no guarantee that the animation frame will actually run before the fake\n * timers are teared, which leaves `isScheduled` set, but won't run our `tick()`. */\n const didRAFChange = process.env.NODE_ENV !== 'production' && LAST_RAF !== requestAnimationFrame && (LAST_RAF = requestAnimationFrame, true);\n if (!this.isScheduled || didRAFChange) {\n requestAnimationFrame(this.tick);\n this.isScheduled = true;\n }\n return id;\n }\n cancel(id) {\n const index = id - this.startId;\n if (index < 0 || index >= this.callbacks.length) {\n return;\n }\n this.callbacks[index] = null;\n this.callbacksCount -= 1;\n }\n}\nconst scheduler = new Scheduler();\nexport class AnimationFrame {\n static create() {\n return new AnimationFrame();\n }\n static request(fn) {\n return scheduler.request(fn);\n }\n static cancel(id) {\n return scheduler.cancel(id);\n }\n currentId = EMPTY;\n\n /**\n * Executes `fn` after `delay`, clearing any previously scheduled call.\n */\n request(fn) {\n this.cancel();\n this.currentId = scheduler.request(() => {\n this.currentId = EMPTY;\n fn();\n });\n }\n cancel = () => {\n if (this.currentId !== EMPTY) {\n scheduler.cancel(this.currentId);\n this.currentId = EMPTY;\n }\n };\n disposeEffect = () => {\n return this.cancel;\n };\n}\n\n/**\n * A `requestAnimationFrame` with automatic cleanup and guard.\n */\nexport function useAnimationFrame() {\n const timeout = useRefWithInit(AnimationFrame.create).current;\n useOnMount(timeout.disposeEffect);\n return timeout;\n}"],"names":["EMPTY","LAST_RAF","Scheduler","timestamp","currentCallbacks","currentCallbacksCount","fn","id","didRAFChange","index","scheduler","AnimationFrame","useAnimationFrame","timeout","useRefWithInit","useOnMount"],"mappings":";;AAQA,MAAMA,IAAQ;AACd,IAAIC,IAAW,WAAW;A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;AACV,SAAK,OAAM,GACX,KAAK,YAAYI,EAAU,QAAQ,MAAM;AACvC,WAAK,YAAYV,GACjBM,EAAE;AAAA,IACJ,CAAC;AAAA,EACH;AAAA,EACA,SAAS,MAAM;AACb,IAAI,KAAK,cAAcN,MACrBU,EAAU,OAAO,KAAK,SAAS,GAC/B,KAAK,YAAYV;AAAA,EAErB;AAAA,EACA,gBAAgB,MACP,KAAK;AAEhB;AAKO,SAASY,IAAoB;AAClC,QAAMC,IAAUC,EAAeH,EAAe,MAAM,EAAE;AACtD,SAAAI,EAAWF,EAAQ,aAAa,GACzBA;AACT;","x_google_ignoreList":[0]}
1
+ {"version":3,"file":"index301.js","sources":["../../../node_modules/react-day-picker/dist/esm/helpers/getNavMonth.js"],"sourcesContent":["/**\n * Returns the start and end months for calendar navigation.\n *\n * @param props The DayPicker props, including navigation and layout options.\n * @param dateLib The date library to use for date manipulation.\n * @returns A tuple containing the start and end months for navigation.\n */\nexport function getNavMonths(props, dateLib) {\n let { startMonth, endMonth } = props;\n const { startOfYear, startOfDay, startOfMonth, endOfMonth, addYears, endOfYear, today, } = dateLib;\n const hasYearDropdown = props.captionLayout === \"dropdown\" ||\n props.captionLayout === \"dropdown-years\";\n if (startMonth) {\n startMonth = startOfMonth(startMonth);\n }\n else if (!startMonth && hasYearDropdown) {\n startMonth = startOfYear(addYears(props.today ?? today(), -100));\n }\n if (endMonth) {\n endMonth = endOfMonth(endMonth);\n }\n else if (!endMonth && hasYearDropdown) {\n endMonth = endOfYear(props.today ?? today());\n }\n return [\n startMonth ? startOfDay(startMonth) : startMonth,\n endMonth ? startOfDay(endMonth) : endMonth,\n ];\n}\n"],"names":["getNavMonths","props","dateLib","startMonth","endMonth","startOfYear","startOfDay","startOfMonth","endOfMonth","addYears","endOfYear","today","hasYearDropdown"],"mappings":"AAOO,SAASA,EAAaC,GAAOC,GAAS;AACzC,MAAI,EAAE,YAAAC,GAAY,UAAAC,EAAQ,IAAKH;AAC/B,QAAM,EAAE,aAAAI,GAAa,YAAAC,GAAY,cAAAC,GAAc,YAAAC,GAAY,UAAAC,GAAU,WAAAC,GAAW,OAAAC,EAAK,IAAMT,GACrFU,IAAkBX,EAAM,kBAAkB,cAC5CA,EAAM,kBAAkB;AAC5B,SAAIE,IACAA,IAAaI,EAAaJ,CAAU,IAE/B,CAACA,KAAcS,MACpBT,IAAaE,EAAYI,EAASR,EAAM,SAASU,EAAK,GAAI,IAAI,CAAC,IAE/DP,IACAA,IAAWI,EAAWJ,CAAQ,IAEzB,CAACA,KAAYQ,MAClBR,IAAWM,EAAUT,EAAM,SAASU,EAAK,CAAE,IAExC;AAAA,IACHR,KAAaG,EAAWH,CAAU;AAAA,IAClCC,KAAWE,EAAWF,CAAQ;AAAA,EACtC;AACA;","x_google_ignoreList":[0]}
package/dist/index302.js CHANGED
@@ -1,17 +1,13 @@
1
- import { j as s } from "./index30.js";
2
- const e = "base-ui-disable-scrollbar", r = {
3
- className: e,
4
- getElement(l) {
5
- return /* @__PURE__ */ s.jsx("style", {
6
- nonce: l,
7
- href: e,
8
- precedence: "base-ui:low",
9
- children: `.${e}{scrollbar-width:none}.${e}::-webkit-scrollbar{display:none}`
10
- });
11
- }
12
- };
13
- process.env.NODE_ENV !== "production" && (r.getElement.displayName = "styleDisableScrollbar.getElement");
1
+ function h(n, t, e, s) {
2
+ if (e.disableNavigation)
3
+ return;
4
+ const { pagedNavigation: u, numberOfMonths: f = 1 } = e, { startOfMonth: a, addMonths: o, differenceInCalendarMonths: d } = s, i = u ? f : 1, r = a(n);
5
+ if (!t)
6
+ return o(r, i);
7
+ if (!(d(t, n) < f))
8
+ return o(r, i);
9
+ }
14
10
  export {
15
- r as styleDisableScrollbar
11
+ h as getNextMonth
16
12
  };
17
13
  //# sourceMappingURL=index302.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index302.js","sources":["../../../node_modules/@base-ui/react/utils/styles.mjs"],"sourcesContent":["import { jsx as _jsx } from \"react/jsx-runtime\";\nconst DISABLE_SCROLLBAR_CLASS_NAME = 'base-ui-disable-scrollbar';\nexport const styleDisableScrollbar = {\n className: DISABLE_SCROLLBAR_CLASS_NAME,\n getElement(nonce) {\n return /*#__PURE__*/_jsx(\"style\", {\n nonce: nonce,\n href: DISABLE_SCROLLBAR_CLASS_NAME,\n precedence: \"base-ui:low\",\n children: `.${DISABLE_SCROLLBAR_CLASS_NAME}{scrollbar-width:none}.${DISABLE_SCROLLBAR_CLASS_NAME}::-webkit-scrollbar{display:none}`\n });\n }\n};\nif (process.env.NODE_ENV !== \"production\") styleDisableScrollbar.getElement.displayName = \"styleDisableScrollbar.getElement\";"],"names":["DISABLE_SCROLLBAR_CLASS_NAME","styleDisableScrollbar","nonce","_jsx"],"mappings":";AACA,MAAMA,IAA+B,6BACxBC,IAAwB;AAAA,EACnC,WAAWD;AAAA,EACX,WAAWE,GAAO;AAChB,WAAoBC,gBAAAA,EAAAA,IAAK,SAAS;AAAA,MAChC,OAAOD;AAAA,MACP,MAAMF;AAAA,MACN,YAAY;AAAA,MACZ,UAAU,IAAIA,CAA4B,0BAA0BA,CAA4B;AAAA,IACtG,CAAK;AAAA,EACH;AACF;AACI,QAAQ,IAAI,aAAa,iBAAcC,EAAsB,WAAW,cAAc;","x_google_ignoreList":[0]}
1
+ {"version":3,"file":"index302.js","sources":["../../../node_modules/react-day-picker/dist/esm/helpers/getNextMonth.js"],"sourcesContent":["/**\n * Returns the next month the user can navigate to, based on the given options.\n *\n * The next month is not always the next calendar month:\n *\n * - If it is after the `calendarEndMonth`, it returns `undefined`.\n * - If paged navigation is enabled, it skips forward by the number of displayed\n * months.\n *\n * @param firstDisplayedMonth The first month currently displayed in the\n * calendar.\n * @param calendarEndMonth The latest month the user can navigate to.\n * @param options Navigation options, including `numberOfMonths` and\n * `pagedNavigation`.\n * @param dateLib The date library to use for date manipulation.\n * @returns The next month, or `undefined` if navigation is not possible.\n */\nexport function getNextMonth(firstDisplayedMonth, calendarEndMonth, options, dateLib) {\n if (options.disableNavigation) {\n return undefined;\n }\n const { pagedNavigation, numberOfMonths = 1 } = options;\n const { startOfMonth, addMonths, differenceInCalendarMonths } = dateLib;\n const offset = pagedNavigation ? numberOfMonths : 1;\n const month = startOfMonth(firstDisplayedMonth);\n if (!calendarEndMonth) {\n return addMonths(month, offset);\n }\n const monthsDiff = differenceInCalendarMonths(calendarEndMonth, firstDisplayedMonth);\n if (monthsDiff < numberOfMonths) {\n return undefined;\n }\n return addMonths(month, offset);\n}\n"],"names":["getNextMonth","firstDisplayedMonth","calendarEndMonth","options","dateLib","pagedNavigation","numberOfMonths","startOfMonth","addMonths","differenceInCalendarMonths","offset","month"],"mappings":"AAiBO,SAASA,EAAaC,GAAqBC,GAAkBC,GAASC,GAAS;AAClF,MAAID,EAAQ;AACR;AAEJ,QAAM,EAAE,iBAAAE,GAAiB,gBAAAC,IAAiB,EAAC,IAAKH,GAC1C,EAAE,cAAAI,GAAc,WAAAC,GAAW,4BAAAC,EAA0B,IAAKL,GAC1DM,IAASL,IAAkBC,IAAiB,GAC5CK,IAAQJ,EAAaN,CAAmB;AAC9C,MAAI,CAACC;AACD,WAAOM,EAAUG,GAAOD,CAAM;AAGlC,MAAI,EADeD,EAA2BP,GAAkBD,CAAmB,IAClEK;AAGjB,WAAOE,EAAUG,GAAOD,CAAM;AAClC;","x_google_ignoreList":[0]}
package/dist/index303.js CHANGED
@@ -1,11 +1,13 @@
1
- import * as o from "react";
2
- const t = /* @__PURE__ */ o.createContext(void 0);
3
- process.env.NODE_ENV !== "production" && (t.displayName = "ToolbarRootContext");
4
- function r(e) {
5
- return o.useContext(t);
1
+ function c(i, t, e, s) {
2
+ if (e.disableNavigation)
3
+ return;
4
+ const { pagedNavigation: r, numberOfMonths: d } = e, { startOfMonth: u, addMonths: f, differenceInCalendarMonths: a } = s, o = r ? d ?? 1 : 1, n = u(i);
5
+ if (!t)
6
+ return f(n, -o);
7
+ if (!(a(n, t) <= 0))
8
+ return f(n, -o);
6
9
  }
7
10
  export {
8
- t as ToolbarRootContext,
9
- r as useToolbarRootContext
11
+ c as getPreviousMonth
10
12
  };
11
13
  //# sourceMappingURL=index303.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index303.js","sources":["../../../node_modules/@base-ui/react/toolbar/root/ToolbarRootContext.mjs"],"sourcesContent":["'use client';\n\nimport _formatErrorMessage from \"@base-ui/utils/formatErrorMessage\";\nimport * as React from 'react';\nexport const ToolbarRootContext = /*#__PURE__*/React.createContext(undefined);\nif (process.env.NODE_ENV !== \"production\") ToolbarRootContext.displayName = \"ToolbarRootContext\";\nexport function useToolbarRootContext(optional) {\n const context = React.useContext(ToolbarRootContext);\n if (context === undefined && !optional) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? 'Base UI: ToolbarRootContext is missing. Toolbar parts must be placed within <Toolbar.Root>.' : _formatErrorMessage(69));\n }\n return context;\n}"],"names":["ToolbarRootContext","React","useToolbarRootContext","optional"],"mappings":";AAIY,MAACA,IAAkC,gBAAAC,EAAM,cAAc,MAAS;AACxE,QAAQ,IAAI,aAAa,iBAAcD,EAAmB,cAAc;AACrE,SAASE,EAAsBC,GAAU;AAK9C,SAJgBF,EAAM,WAAWD,CAAkB;AAKrD;","x_google_ignoreList":[0]}
1
+ {"version":3,"file":"index303.js","sources":["../../../node_modules/react-day-picker/dist/esm/helpers/getPreviousMonth.js"],"sourcesContent":["/**\n * Returns the previous month the user can navigate to, based on the given\n * options.\n *\n * The previous month is not always the previous calendar month:\n *\n * - If it is before the `calendarStartMonth`, it returns `undefined`.\n * - If paged navigation is enabled, it skips back by the number of displayed\n * months.\n *\n * @param firstDisplayedMonth The first month currently displayed in the\n * calendar.\n * @param calendarStartMonth The earliest month the user can navigate to.\n * @param options Navigation options, including `numberOfMonths` and\n * `pagedNavigation`.\n * @param dateLib The date library to use for date manipulation.\n * @returns The previous month, or `undefined` if navigation is not possible.\n */\nexport function getPreviousMonth(firstDisplayedMonth, calendarStartMonth, options, dateLib) {\n if (options.disableNavigation) {\n return undefined;\n }\n const { pagedNavigation, numberOfMonths } = options;\n const { startOfMonth, addMonths, differenceInCalendarMonths } = dateLib;\n const offset = pagedNavigation ? (numberOfMonths ?? 1) : 1;\n const month = startOfMonth(firstDisplayedMonth);\n if (!calendarStartMonth) {\n return addMonths(month, -offset);\n }\n const monthsDiff = differenceInCalendarMonths(month, calendarStartMonth);\n if (monthsDiff <= 0) {\n return undefined;\n }\n return addMonths(month, -offset);\n}\n"],"names":["getPreviousMonth","firstDisplayedMonth","calendarStartMonth","options","dateLib","pagedNavigation","numberOfMonths","startOfMonth","addMonths","differenceInCalendarMonths","offset","month"],"mappings":"AAkBO,SAASA,EAAiBC,GAAqBC,GAAoBC,GAASC,GAAS;AACxF,MAAID,EAAQ;AACR;AAEJ,QAAM,EAAE,iBAAAE,GAAiB,gBAAAC,EAAc,IAAKH,GACtC,EAAE,cAAAI,GAAc,WAAAC,GAAW,4BAAAC,EAA0B,IAAKL,GAC1DM,IAASL,IAAmBC,KAAkB,IAAK,GACnDK,IAAQJ,EAAaN,CAAmB;AAC9C,MAAI,CAACC;AACD,WAAOM,EAAUG,GAAO,CAACD,CAAM;AAGnC,MAAI,EADeD,EAA2BE,GAAOT,CAAkB,KACrD;AAGlB,WAAOM,EAAUG,GAAO,CAACD,CAAM;AACnC;","x_google_ignoreList":[0]}
package/dist/index304.js CHANGED
@@ -1,9 +1,8 @@
1
- import { EMPTY_OBJECT as r } from "./index264.js";
2
- import { DISABLED_TRANSITIONS_STYLE as o } from "./index191.js";
3
- function T(t) {
4
- return t === "starting" ? o : r;
1
+ function i(e) {
2
+ const t = [];
3
+ return e.reduce((c, n) => c.concat(n.weeks.slice()), t.slice());
5
4
  }
6
5
  export {
7
- T as getDisabledMountTransitionStyles
6
+ i as getWeeks
8
7
  };
9
8
  //# sourceMappingURL=index304.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index304.js","sources":["../../../node_modules/@base-ui/react/utils/getDisabledMountTransitionStyles.mjs"],"sourcesContent":["import { EMPTY_OBJECT } from '@base-ui/utils/empty';\nimport { DISABLED_TRANSITIONS_STYLE } from \"../internals/constants.mjs\";\nexport function getDisabledMountTransitionStyles(transitionStatus) {\n return transitionStatus === 'starting' ? DISABLED_TRANSITIONS_STYLE : EMPTY_OBJECT;\n}"],"names":["getDisabledMountTransitionStyles","transitionStatus","DISABLED_TRANSITIONS_STYLE","EMPTY_OBJECT"],"mappings":";;AAEO,SAASA,EAAiCC,GAAkB;AACjE,SAAOA,MAAqB,aAAaC,IAA6BC;AACxE;","x_google_ignoreList":[0]}
1
+ {"version":3,"file":"index304.js","sources":["../../../node_modules/react-day-picker/dist/esm/helpers/getWeeks.js"],"sourcesContent":["/**\n * Returns an array of calendar weeks from an array of calendar months.\n *\n * @param months The array of calendar months.\n * @returns An array of calendar weeks.\n */\nexport function getWeeks(months) {\n const initialWeeks = [];\n return months.reduce((weeks, month) => {\n return weeks.concat(month.weeks.slice());\n }, initialWeeks.slice());\n}\n"],"names":["getWeeks","months","initialWeeks","weeks","month"],"mappings":"AAMO,SAASA,EAASC,GAAQ;AAC7B,QAAMC,IAAe,CAAA;AACrB,SAAOD,EAAO,OAAO,CAACE,GAAOC,MAClBD,EAAM,OAAOC,EAAM,MAAM,MAAK,CAAE,GACxCF,EAAa,OAAO;AAC3B;","x_google_ignoreList":[0]}
package/dist/index305.js CHANGED
@@ -1,7 +1,9 @@
1
- function t(E, m = Number.MIN_SAFE_INTEGER, r = Number.MAX_SAFE_INTEGER) {
2
- return Math.max(m, Math.min(E, r));
1
+ import { useState as o } from "react";
2
+ function a(t, e) {
3
+ const [u, n] = o(t);
4
+ return [e === void 0 ? u : e, n];
3
5
  }
4
6
  export {
5
- t as clamp
7
+ a as useControlledValue
6
8
  };
7
9
  //# sourceMappingURL=index305.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index305.js","sources":["../../../node_modules/@base-ui/react/internals/clamp.mjs"],"sourcesContent":["export function clamp(val, min = Number.MIN_SAFE_INTEGER, max = Number.MAX_SAFE_INTEGER) {\n return Math.max(min, Math.min(val, max));\n}"],"names":["clamp","val","min","max"],"mappings":"AAAO,SAASA,EAAMC,GAAKC,IAAM,OAAO,kBAAkBC,IAAM,OAAO,kBAAkB;AACvF,SAAO,KAAK,IAAID,GAAK,KAAK,IAAID,GAAKE,CAAG,CAAC;AACzC;","x_google_ignoreList":[0]}
1
+ {"version":3,"file":"index305.js","sources":["../../../node_modules/react-day-picker/dist/esm/helpers/useControlledValue.js"],"sourcesContent":["import { useState } from \"react\";\n/**\n * A custom hook for managing both controlled and uncontrolled component states.\n *\n * This hook allows a component to support both controlled and uncontrolled\n * states by determining whether the `controlledValue` is provided. If it is\n * undefined, the hook falls back to using the internal state.\n *\n * @example\n * // Uncontrolled usage\n * const [value, setValue] = useControlledValue(0, undefined);\n *\n * // Controlled usage\n * const [value, setValue] = useControlledValue(0, props.value);\n *\n * @template T - The type of the value.\n * @param defaultValue The initial value for the uncontrolled state.\n * @param controlledValue The value for the controlled state. If undefined, the\n * component will use the uncontrolled state.\n * @returns A tuple where the first element is the current value (either\n * controlled or uncontrolled) and the second element is a setter function to\n * update the value.\n */\nexport function useControlledValue(defaultValue, controlledValue) {\n const [uncontrolledValue, setValue] = useState(defaultValue);\n const value = controlledValue === undefined ? uncontrolledValue : controlledValue;\n return [value, setValue];\n}\n"],"names":["useControlledValue","defaultValue","controlledValue","uncontrolledValue","setValue","useState"],"mappings":";AAuBO,SAASA,EAAmBC,GAAcC,GAAiB;AAC9D,QAAM,CAACC,GAAmBC,CAAQ,IAAIC,EAASJ,CAAY;AAE3D,SAAO,CADOC,MAAoB,SAAYC,IAAoBD,GACnDE,CAAQ;AAC3B;","x_google_ignoreList":[0]}
package/dist/index306.js CHANGED
@@ -1,14 +1,20 @@
1
- import * as e from "react";
2
- const t = /* @__PURE__ */ e.createContext(void 0);
3
- process.env.NODE_ENV !== "production" && (t.displayName = "CSPContext");
4
- const n = {
5
- disableStyleElements: !1
6
- };
7
- function o() {
8
- return e.useContext(t) ?? n;
1
+ import { DayFlag as s } from "./index118.js";
2
+ var d;
3
+ (function(e) {
4
+ e[e.Today = 0] = "Today", e[e.Selected = 1] = "Selected", e[e.LastFocused = 2] = "LastFocused", e[e.FocusedModifier = 3] = "FocusedModifier";
5
+ })(d || (d = {}));
6
+ function l(e) {
7
+ return !e[s.disabled] && !e[s.hidden] && !e[s.outside];
8
+ }
9
+ function F(e, u, t, n) {
10
+ let f, c = -1;
11
+ for (const o of e) {
12
+ const a = u(o);
13
+ l(a) && (a[s.focused] && c < d.FocusedModifier ? (f = o, c = d.FocusedModifier) : n?.isEqualTo(o) && c < d.LastFocused ? (f = o, c = d.LastFocused) : t(o.date) && c < d.Selected ? (f = o, c = d.Selected) : a[s.today] && c < d.Today && (f = o, c = d.Today));
14
+ }
15
+ return f || (f = e.find((o) => l(u(o)))), f;
9
16
  }
10
17
  export {
11
- t as CSPContext,
12
- o as useCSPContext
18
+ F as calculateFocusTarget
13
19
  };
14
20
  //# sourceMappingURL=index306.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index306.js","sources":["../../../node_modules/@base-ui/react/internals/csp-context/CSPContext.mjs"],"sourcesContent":["'use client';\n\nimport * as React from 'react';\n/**\n * @internal\n */\nexport const CSPContext = /*#__PURE__*/React.createContext(undefined);\nif (process.env.NODE_ENV !== \"production\") CSPContext.displayName = \"CSPContext\";\nconst DEFAULT_CSP_CONTEXT_VALUE = {\n disableStyleElements: false\n};\n\n/**\n * @internal\n */\nexport function useCSPContext() {\n return React.useContext(CSPContext) ?? DEFAULT_CSP_CONTEXT_VALUE;\n}"],"names":["CSPContext","React","DEFAULT_CSP_CONTEXT_VALUE","useCSPContext"],"mappings":";AAMY,MAACA,IAA0B,gBAAAC,EAAM,cAAc,MAAS;AAChE,QAAQ,IAAI,aAAa,iBAAcD,EAAW,cAAc;AACpE,MAAME,IAA4B;AAAA,EAChC,sBAAsB;AACxB;AAKO,SAASC,IAAgB;AAC9B,SAAOF,EAAM,WAAWD,CAAU,KAAKE;AACzC;","x_google_ignoreList":[0]}
1
+ {"version":3,"file":"index306.js","sources":["../../../node_modules/react-day-picker/dist/esm/helpers/calculateFocusTarget.js"],"sourcesContent":["import { DayFlag } from \"../UI.js\";\nvar FocusTargetPriority;\n(function (FocusTargetPriority) {\n FocusTargetPriority[FocusTargetPriority[\"Today\"] = 0] = \"Today\";\n FocusTargetPriority[FocusTargetPriority[\"Selected\"] = 1] = \"Selected\";\n FocusTargetPriority[FocusTargetPriority[\"LastFocused\"] = 2] = \"LastFocused\";\n FocusTargetPriority[FocusTargetPriority[\"FocusedModifier\"] = 3] = \"FocusedModifier\";\n})(FocusTargetPriority || (FocusTargetPriority = {}));\n/**\n * Determines if a day is focusable based on its modifiers.\n *\n * A day is considered focusable if it is not disabled, hidden, or outside the\n * displayed month.\n *\n * @param modifiers The modifiers applied to the day.\n * @returns `true` if the day is focusable, otherwise `false`.\n */\nfunction isFocusableDay(modifiers) {\n return (!modifiers[DayFlag.disabled] &&\n !modifiers[DayFlag.hidden] &&\n !modifiers[DayFlag.outside]);\n}\n/**\n * Calculates the focus target day based on priority.\n *\n * This function determines the day that should receive focus in the calendar,\n * prioritizing days with specific modifiers (e.g., \"focused\", \"today\") or\n * selection states.\n *\n * @param days The array of `CalendarDay` objects to evaluate.\n * @param getModifiers A function to retrieve the modifiers for a given day.\n * @param isSelected A function to determine if a day is selected.\n * @param lastFocused The last focused day, if any.\n * @returns The `CalendarDay` that should receive focus, or `undefined` if no\n * focusable day is found.\n */\nexport function calculateFocusTarget(days, getModifiers, isSelected, lastFocused) {\n let focusTarget;\n let foundFocusTargetPriority = -1;\n for (const day of days) {\n const modifiers = getModifiers(day);\n if (isFocusableDay(modifiers)) {\n if (modifiers[DayFlag.focused] &&\n foundFocusTargetPriority < FocusTargetPriority.FocusedModifier) {\n focusTarget = day;\n foundFocusTargetPriority = FocusTargetPriority.FocusedModifier;\n }\n else if (lastFocused?.isEqualTo(day) &&\n foundFocusTargetPriority < FocusTargetPriority.LastFocused) {\n focusTarget = day;\n foundFocusTargetPriority = FocusTargetPriority.LastFocused;\n }\n else if (isSelected(day.date) &&\n foundFocusTargetPriority < FocusTargetPriority.Selected) {\n focusTarget = day;\n foundFocusTargetPriority = FocusTargetPriority.Selected;\n }\n else if (modifiers[DayFlag.today] &&\n foundFocusTargetPriority < FocusTargetPriority.Today) {\n focusTarget = day;\n foundFocusTargetPriority = FocusTargetPriority.Today;\n }\n }\n }\n if (!focusTarget) {\n // Return the first day that is focusable\n focusTarget = days.find((day) => isFocusableDay(getModifiers(day)));\n }\n return focusTarget;\n}\n"],"names":["FocusTargetPriority","isFocusableDay","modifiers","DayFlag","calculateFocusTarget","days","getModifiers","isSelected","lastFocused","focusTarget","foundFocusTargetPriority","day"],"mappings":";AACA,IAAIA;AAAA,CACH,SAAUA,GAAqB;AAC5B,EAAAA,EAAoBA,EAAoB,QAAW,CAAC,IAAI,SACxDA,EAAoBA,EAAoB,WAAc,CAAC,IAAI,YAC3DA,EAAoBA,EAAoB,cAAiB,CAAC,IAAI,eAC9DA,EAAoBA,EAAoB,kBAAqB,CAAC,IAAI;AACtE,GAAGA,MAAwBA,IAAsB,CAAA,EAAG;AAUpD,SAASC,EAAeC,GAAW;AAC/B,SAAQ,CAACA,EAAUC,EAAQ,QAAQ,KAC/B,CAACD,EAAUC,EAAQ,MAAM,KACzB,CAACD,EAAUC,EAAQ,OAAO;AAClC;AAeO,SAASC,EAAqBC,GAAMC,GAAcC,GAAYC,GAAa;AAC9E,MAAIC,GACAC,IAA2B;AAC/B,aAAWC,KAAON,GAAM;AACpB,UAAMH,IAAYI,EAAaK,CAAG;AAClC,IAAIV,EAAeC,CAAS,MACpBA,EAAUC,EAAQ,OAAO,KACzBO,IAA2BV,EAAoB,mBAC/CS,IAAcE,GACdD,IAA2BV,EAAoB,mBAE1CQ,GAAa,UAAUG,CAAG,KAC/BD,IAA2BV,EAAoB,eAC/CS,IAAcE,GACdD,IAA2BV,EAAoB,eAE1CO,EAAWI,EAAI,IAAI,KACxBD,IAA2BV,EAAoB,YAC/CS,IAAcE,GACdD,IAA2BV,EAAoB,YAE1CE,EAAUC,EAAQ,KAAK,KAC5BO,IAA2BV,EAAoB,UAC/CS,IAAcE,GACdD,IAA2BV,EAAoB;AAAA,EAG3D;AACA,SAAKS,MAEDA,IAAcJ,EAAK,KAAK,CAACM,MAAQV,EAAeK,EAAaK,CAAG,CAAC,CAAC,IAE/DF;AACX;","x_google_ignoreList":[0]}
package/dist/index307.js CHANGED
@@ -1,11 +1,13 @@
1
- import * as t from "react";
2
- const e = /* @__PURE__ */ t.createContext(void 0);
3
- process.env.NODE_ENV !== "production" && (e.displayName = "DirectionContext");
4
- function o() {
5
- return t.useContext(e)?.direction ?? "ltr";
1
+ import { dateMatchModifiers as u } from "./index32.js";
2
+ import { getFocusableDate as g } from "./index375.js";
3
+ import { CalendarDay as m } from "./index259.js";
4
+ function h(t, i, a, d, f, e, n, s = 0) {
5
+ if (s > 365)
6
+ return;
7
+ const o = g(t, i, a.date, d, f, e, n), r = !!(e.disabled && u(o, e.disabled, n)), l = !!(e.hidden && u(o, e.hidden, n)), D = o, c = new m(o, D, n);
8
+ return !r && !l ? c : h(t, i, c, d, f, e, n, s + 1);
6
9
  }
7
10
  export {
8
- e as DirectionContext,
9
- o as useDirection
11
+ h as getNextFocus
10
12
  };
11
13
  //# sourceMappingURL=index307.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index307.js","sources":["../../../node_modules/@base-ui/react/internals/direction-context/DirectionContext.mjs"],"sourcesContent":["'use client';\n\nimport * as React from 'react';\n/**\n * @internal\n */\nexport const DirectionContext = /*#__PURE__*/React.createContext(undefined);\nif (process.env.NODE_ENV !== \"production\") DirectionContext.displayName = \"DirectionContext\";\nexport function useDirection() {\n const context = React.useContext(DirectionContext);\n return context?.direction ?? 'ltr';\n}"],"names":["DirectionContext","React","useDirection"],"mappings":";AAMY,MAACA,IAAgC,gBAAAC,EAAM,cAAc,MAAS;AACtE,QAAQ,IAAI,aAAa,iBAAcD,EAAiB,cAAc;AACnE,SAASE,IAAe;AAE7B,SADgBD,EAAM,WAAWD,CAAgB,GACjC,aAAa;AAC/B;","x_google_ignoreList":[0]}
1
+ {"version":3,"file":"index307.js","sources":["../../../node_modules/react-day-picker/dist/esm/helpers/getNextFocus.js"],"sourcesContent":["import { CalendarDay } from \"../classes/index.js\";\nimport { dateMatchModifiers } from \"../utils/dateMatchModifiers.js\";\nimport { getFocusableDate } from \"./getFocusableDate.js\";\n/**\n * Determines the next focusable day in the calendar.\n *\n * This function recursively calculates the next focusable day based on the\n * movement direction and modifiers applied to the days.\n *\n * @param moveBy The unit of movement (e.g., \"day\", \"week\").\n * @param moveDir The direction of movement (\"before\" or \"after\").\n * @param refDay The currently focused day.\n * @param calendarStartMonth The earliest month the user can navigate to.\n * @param calendarEndMonth The latest month the user can navigate to.\n * @param props The DayPicker props, including modifiers and configuration\n * options.\n * @param dateLib The date library to use for date manipulation.\n * @param attempt The current recursion attempt (used to limit recursion depth).\n * @returns The next focusable day, or `undefined` if no focusable day is found.\n */\nexport function getNextFocus(moveBy, moveDir, refDay, calendarStartMonth, calendarEndMonth, props, dateLib, attempt = 0) {\n if (attempt > 365) {\n // Limit the recursion to 365 attempts\n return undefined;\n }\n const focusableDate = getFocusableDate(moveBy, moveDir, refDay.date, calendarStartMonth, calendarEndMonth, props, dateLib);\n const isDisabled = Boolean(props.disabled &&\n dateMatchModifiers(focusableDate, props.disabled, dateLib));\n const isHidden = Boolean(props.hidden && dateMatchModifiers(focusableDate, props.hidden, dateLib));\n const targetMonth = focusableDate;\n const focusDay = new CalendarDay(focusableDate, targetMonth, dateLib);\n if (!isDisabled && !isHidden) {\n return focusDay;\n }\n // Recursively attempt to find the next focusable date\n return getNextFocus(moveBy, moveDir, focusDay, calendarStartMonth, calendarEndMonth, props, dateLib, attempt + 1);\n}\n"],"names":["getNextFocus","moveBy","moveDir","refDay","calendarStartMonth","calendarEndMonth","props","dateLib","attempt","focusableDate","getFocusableDate","isDisabled","dateMatchModifiers","isHidden","targetMonth","focusDay","CalendarDay"],"mappings":";;;AAoBO,SAASA,EAAaC,GAAQC,GAASC,GAAQC,GAAoBC,GAAkBC,GAAOC,GAASC,IAAU,GAAG;AACrH,MAAIA,IAAU;AAEV;AAEJ,QAAMC,IAAgBC,EAAiBT,GAAQC,GAASC,EAAO,MAAMC,GAAoBC,GAAkBC,GAAOC,CAAO,GACnHI,IAAa,GAAQL,EAAM,YAC7BM,EAAmBH,GAAeH,EAAM,UAAUC,CAAO,IACvDM,IAAW,GAAQP,EAAM,UAAUM,EAAmBH,GAAeH,EAAM,QAAQC,CAAO,IAC1FO,IAAcL,GACdM,IAAW,IAAIC,EAAYP,GAAeK,GAAaP,CAAO;AACpE,SAAI,CAACI,KAAc,CAACE,IACTE,IAGJf,EAAaC,GAAQC,GAASa,GAAUX,GAAoBC,GAAkBC,GAAOC,GAASC,IAAU,CAAC;AACpH;","x_google_ignoreList":[0]}