@boxcustodia/library 0.2.3 → 0.2.5

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 (347) hide show
  1. package/dist/index.d.ts +1 -1
  2. package/dist/index.es10.js +1 -1
  3. package/dist/index.es100.js +21 -1059
  4. package/dist/index.es101.js +30 -3674
  5. package/dist/index.es102.js +12 -4
  6. package/dist/index.es103.js +1062 -4
  7. package/dist/index.es104.js +3673 -3
  8. package/dist/index.es105.js +4 -14
  9. package/dist/index.es106.js +4 -5
  10. package/dist/index.es107.js +11 -57
  11. package/dist/index.es108.js +228 -193
  12. package/dist/index.es109.js +5 -4
  13. package/dist/index.es110.js +4 -11
  14. package/dist/index.es111.js +14 -41
  15. package/dist/index.es112.js +5 -11
  16. package/dist/index.es113.js +57 -33
  17. package/dist/index.es115.js +1 -1
  18. package/dist/index.es116.js +1 -1
  19. package/dist/index.es117.js +1 -1
  20. package/dist/index.es118.js +13 -13
  21. package/dist/index.es119.js +813 -55
  22. package/dist/index.es120.js +9 -822
  23. package/dist/index.es121.js +5 -3
  24. package/dist/index.es122.js +64 -11
  25. package/dist/index.es123.js +33 -4
  26. package/dist/index.es124.js +13 -13
  27. package/dist/index.es125.js +13 -33
  28. package/dist/index.es126.js +4 -13
  29. package/dist/index.es127.js +215 -7
  30. package/dist/index.es128.js +7 -215
  31. package/dist/index.es13.js +1 -1
  32. package/dist/index.es130.js +1 -1
  33. package/dist/index.es131.js +1 -1
  34. package/dist/index.es132.js +12 -9
  35. package/dist/index.es133.js +196 -204
  36. package/dist/index.es134.js +41 -10
  37. package/dist/index.es135.js +11 -13
  38. package/dist/index.es136.js +11 -196
  39. package/dist/index.es137.js +204 -41
  40. package/dist/index.es138.js +10 -20
  41. package/dist/index.es139.js +5 -35
  42. package/dist/index.es14.js +1 -1
  43. package/dist/index.es140.js +63 -9
  44. package/dist/index.es141.js +32 -6
  45. package/dist/index.es142.js +645 -60
  46. package/dist/index.es144.js +19 -123
  47. package/dist/index.es145.js +32 -130
  48. package/dist/index.es146.js +11 -14
  49. package/dist/index.es147.js +5 -32
  50. package/dist/index.es148.js +2 -15
  51. package/dist/index.es149.js +124 -8
  52. package/dist/index.es15.js +1 -1
  53. package/dist/index.es150.js +133 -48
  54. package/dist/index.es151.js +14 -6
  55. package/dist/index.es152.js +15 -2
  56. package/dist/index.es153.js +9 -44
  57. package/dist/index.es154.js +48 -648
  58. package/dist/index.es155.js +44 -13
  59. package/dist/index.es156.js +8 -8
  60. package/dist/index.es159.js +3 -3
  61. package/dist/index.es162.js +1 -1
  62. package/dist/index.es163.js +6 -6
  63. package/dist/index.es164.js +2 -2
  64. package/dist/index.es165.js +6 -2
  65. package/dist/index.es166.js +3 -4
  66. package/dist/index.es167.js +2054 -6
  67. package/dist/index.es168.js +4 -3
  68. package/dist/index.es169.js +2 -2054
  69. package/dist/index.es176.js +1 -1
  70. package/dist/index.es177.js +1 -1
  71. package/dist/index.es178.js +1 -1
  72. package/dist/index.es183.js +177 -11
  73. package/dist/index.es184.js +11 -7
  74. package/dist/index.es185.js +21 -6
  75. package/dist/index.es186.js +9 -5
  76. package/dist/index.es187.js +38 -18
  77. package/dist/index.es188.js +18 -6
  78. package/dist/index.es189.js +200 -5
  79. package/dist/index.es190.js +22 -9
  80. package/dist/index.es191.js +25 -6
  81. package/dist/index.es192.js +370 -6
  82. package/dist/index.es193.js +25 -16
  83. package/dist/index.es194.js +12 -12
  84. package/dist/index.es195.js +6 -13
  85. package/dist/index.es196.js +1 -1
  86. package/dist/index.es197.js +19 -7
  87. package/dist/index.es198.js +52 -7
  88. package/dist/index.es199.js +6 -4
  89. package/dist/index.es200.js +6 -515
  90. package/dist/index.es201.js +7 -50
  91. package/dist/index.es202.js +7 -17
  92. package/dist/index.es203.js +16 -10
  93. package/dist/index.es204.js +9 -19
  94. package/dist/index.es205.js +6 -8
  95. package/dist/index.es206.js +6 -7
  96. package/dist/index.es207.js +13 -7
  97. package/dist/index.es208.js +10 -5
  98. package/dist/index.es209.js +84 -6
  99. package/dist/index.es210.js +5 -9
  100. package/dist/index.es211.js +17 -5
  101. package/dist/index.es212.js +5 -8
  102. package/dist/index.es213.js +6 -12
  103. package/dist/index.es214.js +6 -9
  104. package/dist/index.es215.js +9 -8
  105. package/dist/index.es216.js +6 -10
  106. package/dist/index.es217.js +7 -14
  107. package/dist/index.es218.js +5 -6
  108. package/dist/index.es219.js +4 -6
  109. package/dist/index.es22.js +2 -2
  110. package/dist/index.es220.js +5 -6
  111. package/dist/index.es221.js +8 -6
  112. package/dist/index.es222.js +6 -7
  113. package/dist/index.es223.js +15 -9
  114. package/dist/index.es224.js +4 -84
  115. package/dist/index.es225.js +515 -64
  116. package/dist/index.es226.js +47 -35
  117. package/dist/index.es227.js +17 -9
  118. package/dist/index.es228.js +9 -8
  119. package/dist/index.es229.js +19 -8
  120. package/dist/index.es230.js +8 -10
  121. package/dist/index.es231.js +7 -7
  122. package/dist/index.es232.js +7 -7
  123. package/dist/index.es233.js +5 -6
  124. package/dist/index.es234.js +6 -5
  125. package/dist/index.es235.js +9 -15
  126. package/dist/index.es236.js +6 -21
  127. package/dist/index.es237.js +9 -9
  128. package/dist/index.es238.js +13 -38
  129. package/dist/index.es239.js +10 -18
  130. package/dist/index.es240.js +10 -177
  131. package/dist/index.es241.js +15 -25
  132. package/dist/index.es242.js +64 -18
  133. package/dist/index.es243.js +38 -54
  134. package/dist/index.es244.js +10 -16
  135. package/dist/index.es245.js +8 -200
  136. package/dist/index.es246.js +8 -22
  137. package/dist/index.es247.js +7 -24
  138. package/dist/index.es248.js +15 -370
  139. package/dist/index.es249.js +7 -7
  140. package/dist/index.es250.js +1 -1
  141. package/dist/index.es251.js +1 -1
  142. package/dist/index.es252.js +2 -2
  143. package/dist/index.es264.js +1 -1
  144. package/dist/index.es265.js +1 -1
  145. package/dist/index.es266.js +1 -1
  146. package/dist/index.es267.js +1 -1
  147. package/dist/index.es27.js +1 -1
  148. package/dist/index.es273.js +1 -1
  149. package/dist/index.es274.js +1 -1
  150. package/dist/index.es279.js +1 -1
  151. package/dist/index.es28.js +1 -1
  152. package/dist/index.es283.js +16 -15
  153. package/dist/index.es284.js +8 -3
  154. package/dist/index.es285.js +15 -16
  155. package/dist/index.es286.js +3 -8
  156. package/dist/index.es29.js +3 -3
  157. package/dist/index.es290.js +9 -4
  158. package/dist/index.es291.js +5 -57
  159. package/dist/index.es292.js +13 -28
  160. package/dist/index.es293.js +4 -46
  161. package/dist/index.es294.js +6 -66
  162. package/dist/index.es295.js +332 -36
  163. package/dist/index.es296.js +19 -19
  164. package/dist/index.es297.js +4 -68
  165. package/dist/index.es298.js +4 -67
  166. package/dist/index.es299.js +3 -69
  167. package/dist/index.es30.js +23 -23
  168. package/dist/index.es300.js +69 -66
  169. package/dist/index.es301.js +4 -46
  170. package/dist/index.es302.js +4 -46
  171. package/dist/index.es303.js +53 -55
  172. package/dist/index.es304.js +20 -41
  173. package/dist/index.es305.js +38 -34
  174. package/dist/index.es306.js +43 -48
  175. package/dist/index.es307.js +21 -55
  176. package/dist/index.es308.js +13 -91
  177. package/dist/index.es309.js +45 -24
  178. package/dist/index.es310.js +51 -30
  179. package/dist/index.es311.js +54 -32
  180. package/dist/index.es312.js +60 -22
  181. package/dist/index.es313.js +35 -19
  182. package/dist/index.es314.js +38 -21
  183. package/dist/index.es315.js +50 -22
  184. package/dist/index.es316.js +38 -19
  185. package/dist/index.es317.js +34 -21
  186. package/dist/index.es318.js +66 -14
  187. package/dist/index.es319.js +63 -37
  188. package/dist/index.es32.js +2 -2
  189. package/dist/index.es320.js +86 -35
  190. package/dist/index.es321.js +41 -14
  191. package/dist/index.es322.js +41 -14
  192. package/dist/index.es323.js +45 -8
  193. package/dist/index.es324.js +30 -4
  194. package/dist/index.es325.js +30 -13
  195. package/dist/index.es326.js +29 -4
  196. package/dist/index.es327.js +30 -6
  197. package/dist/index.es328.js +27 -331
  198. package/dist/index.es329.js +30 -19
  199. package/dist/index.es33.js +2 -2
  200. package/dist/index.es330.js +20 -4
  201. package/dist/index.es331.js +45 -4
  202. package/dist/index.es332.js +46 -3
  203. package/dist/index.es333.js +17 -69
  204. package/dist/index.es334.js +20 -4
  205. package/dist/index.es335.js +2 -6
  206. package/dist/index.es336.js +2 -34
  207. package/dist/index.es337.js +6 -26
  208. package/dist/index.es338.js +34 -18
  209. package/dist/index.es339.js +25 -4
  210. package/dist/index.es34.js +55 -43
  211. package/dist/index.es340.js +18 -231
  212. package/dist/index.es341.js +5 -100
  213. package/dist/index.es342.js +229 -26
  214. package/dist/index.es343.js +80 -35
  215. package/dist/index.es344.js +28 -2
  216. package/dist/index.es345.js +55 -2
  217. package/dist/index.es346.js +2 -2
  218. package/dist/index.es347.js +1 -1
  219. package/dist/index.es348.js +1 -1
  220. package/dist/index.es349.js +1 -1
  221. package/dist/index.es35.js +2 -2
  222. package/dist/index.es38.js +5 -5
  223. package/dist/index.es387.js +517 -66
  224. package/dist/index.es388.js +125 -29
  225. package/dist/index.es389.js +126 -9
  226. package/dist/index.es39.js +2 -2
  227. package/dist/index.es390.js +2 -153
  228. package/dist/index.es391.js +53 -107
  229. package/dist/index.es392.js +59 -2
  230. package/dist/index.es393.js +67 -53
  231. package/dist/index.es394.js +31 -59
  232. package/dist/index.es395.js +9 -20
  233. package/dist/index.es396.js +151 -99
  234. package/dist/index.es397.js +107 -46
  235. package/dist/index.es398.js +68 -6
  236. package/dist/index.es399.js +31 -2
  237. package/dist/index.es40.js +3 -3
  238. package/dist/index.es400.js +16 -8
  239. package/dist/index.es401.js +140 -326
  240. package/dist/index.es402.js +112 -48
  241. package/dist/index.es403.js +5 -3
  242. package/dist/index.es404.js +2 -2
  243. package/dist/index.es405.js +7 -46
  244. package/dist/index.es406.js +320 -76
  245. package/dist/index.es407.js +48 -12
  246. package/dist/index.es408.js +3 -340
  247. package/dist/index.es409.js +17 -72
  248. package/dist/index.es41.js +1 -1
  249. package/dist/index.es410.js +100 -10
  250. package/dist/index.es411.js +46 -518
  251. package/dist/index.es412.js +2 -127
  252. package/dist/index.es413.js +41 -120
  253. package/dist/index.es414.js +83 -68
  254. package/dist/index.es415.js +14 -31
  255. package/dist/index.es416.js +341 -16
  256. package/dist/index.es417.js +73 -139
  257. package/dist/index.es418.js +11 -114
  258. package/dist/index.es43.js +1 -1
  259. package/dist/index.es437.js +1 -1
  260. package/dist/index.es438.js +1 -1
  261. package/dist/index.es439.js +3 -3
  262. package/dist/index.es44.js +4 -4
  263. package/dist/index.es440.js +1 -1
  264. package/dist/index.es45.js +1 -1
  265. package/dist/index.es453.js +14 -5
  266. package/dist/index.es454.js +27 -14
  267. package/dist/index.es455.js +11 -27
  268. package/dist/index.es456.js +5 -11
  269. package/dist/index.es46.js +1 -1
  270. package/dist/index.es466.js +1 -1
  271. package/dist/index.es467.js +2 -2
  272. package/dist/index.es468.js +2 -2
  273. package/dist/index.es49.js +2 -2
  274. package/dist/index.es50.js +1 -1
  275. package/dist/index.es51.js +4 -4
  276. package/dist/index.es54.js +1 -1
  277. package/dist/index.es55.js +1 -1
  278. package/dist/index.es57.js +2 -2
  279. package/dist/index.es59.js +2 -2
  280. package/dist/index.es61.js +1 -1
  281. package/dist/index.es62.js +1 -1
  282. package/dist/index.es63.js +1 -1
  283. package/dist/index.es65.js +3 -3
  284. package/dist/index.es66.js +2 -2
  285. package/dist/index.es67.js +3 -3
  286. package/dist/index.es7.js +1 -1
  287. package/dist/index.es70.js +1 -1
  288. package/dist/index.es753.js +7 -7
  289. package/dist/index.es762.js +5 -24
  290. package/dist/index.es763.js +17 -8
  291. package/dist/index.es764.js +7 -66
  292. package/dist/index.es765.js +54 -50
  293. package/dist/index.es766.js +17 -69
  294. package/dist/index.es767.js +24 -5
  295. package/dist/index.es768.js +8 -17
  296. package/dist/index.es769.js +66 -7
  297. package/dist/index.es770.js +50 -54
  298. package/dist/index.es771.js +69 -17
  299. package/dist/index.es778.js +21 -6
  300. package/dist/index.es779.js +56 -20
  301. package/dist/index.es780.js +26 -49
  302. package/dist/index.es781.js +9 -34
  303. package/dist/index.es782.js +18 -9
  304. package/dist/index.es783.js +8 -18
  305. package/dist/index.es784.js +12 -8
  306. package/dist/index.es785.js +56 -11
  307. package/dist/index.es786.js +9 -57
  308. package/dist/index.es787.js +14 -9
  309. package/dist/index.es788.js +6 -14
  310. package/dist/index.es789.js +28 -7
  311. package/dist/index.es79.js +1 -1
  312. package/dist/index.es790.js +3 -28
  313. package/dist/index.es791.js +7 -3
  314. package/dist/index.es796.js +1 -1
  315. package/dist/index.es797.js +1 -1
  316. package/dist/index.es798.js +1 -1
  317. package/dist/index.es799.js +1 -1
  318. package/dist/index.es80.js +1 -1
  319. package/dist/index.es800.js +1 -1
  320. package/dist/index.es801.js +1 -1
  321. package/dist/index.es803.js +1 -1
  322. package/dist/index.es806.js +1 -1
  323. package/dist/index.es807.js +2 -2
  324. package/dist/index.es808.js +1 -1
  325. package/dist/index.es822.js +1 -1
  326. package/dist/index.es826.js +1 -1
  327. package/dist/index.es828.js +1 -1
  328. package/dist/index.es829.js +1 -1
  329. package/dist/index.es830.js +1 -1
  330. package/dist/index.es84.js +305 -33
  331. package/dist/index.es85.js +12 -46
  332. package/dist/index.es86.js +32 -29
  333. package/dist/index.es87.js +34 -29
  334. package/dist/index.es88.js +40 -301
  335. package/dist/index.es89.js +30 -12
  336. package/dist/index.es90.js +30 -9
  337. package/dist/index.es91.js +223 -54
  338. package/dist/index.es92.js +11 -55
  339. package/dist/index.es93.js +9 -90
  340. package/dist/index.es94.js +11 -37
  341. package/dist/index.es95.js +40 -23
  342. package/dist/index.es96.js +55 -30
  343. package/dist/index.es97.js +55 -12
  344. package/dist/index.es98.js +86 -253
  345. package/dist/index.es99.js +37 -12
  346. package/dist/style.css +8 -8
  347. package/package.json +1 -1
@@ -1,199 +1,14 @@
1
- import i from "./index.es170.js";
2
- import { forwardRef as f, createElement as s, useRef as $, useEffect as F, Fragment as M, useCallback as y, Children as N } from "react";
3
- import { composeEventHandlers as g } from "./index.es171.js";
4
- import { useComposedRefs as C } from "./index.es172.js";
5
- import { createContextScope as T } from "./index.es173.js";
6
- import { useId as _ } from "./index.es174.js";
7
- import { useControllableState as S } from "./index.es175.js";
8
- import { DismissableLayer as L } from "./index.es176.js";
9
- import { FocusScope as k } from "./index.es177.js";
10
- import { Portal as w } from "./index.es178.js";
11
- import { Presence as x } from "./index.es179.js";
12
- import { Primitive as D } from "./index.es137.js";
13
- import { useFocusGuards as j } from "./index.es180.js";
14
- import G from "./index.es181.js";
15
- import { hideOthers as H } from "./index.es150.js";
16
- import { Slot as K } from "./index.es182.js";
17
- const O = "Dialog", [P, De] = T(O), [U, d] = P(O), V = (e) => {
18
- const { __scopeDialog: r, children: t, open: c, defaultOpen: n, onOpenChange: o, modal: a = !0 } = e, l = $(null), u = $(null), [b = !1, m] = S({
19
- prop: c,
20
- defaultProp: n,
21
- onChange: o
22
- });
23
- return /* @__PURE__ */ s(U, {
24
- scope: r,
25
- triggerRef: l,
26
- contentRef: u,
27
- contentId: _(),
28
- titleId: _(),
29
- descriptionId: _(),
30
- open: b,
31
- onOpenChange: m,
32
- onOpenToggle: y(
33
- () => m(
34
- (I) => !I
35
- ),
36
- [
37
- m
38
- ]
39
- ),
40
- modal: a
41
- }, t);
42
- }, R = "DialogPortal", [Y, h] = P(R, {
43
- forceMount: void 0
44
- }), Z = (e) => {
45
- const { __scopeDialog: r, forceMount: t, children: c, container: n } = e, o = d(R, r);
46
- return /* @__PURE__ */ s(Y, {
47
- scope: r,
48
- forceMount: t
49
- }, N.map(
50
- c,
51
- (a) => /* @__PURE__ */ s(x, {
52
- present: t || o.open
53
- }, /* @__PURE__ */ s(w, {
54
- asChild: !0,
55
- container: n
56
- }, a))
57
- ));
58
- }, v = "DialogOverlay", q = /* @__PURE__ */ f((e, r) => {
59
- const t = h(v, e.__scopeDialog), { forceMount: c = t.forceMount, ...n } = e, o = d(v, e.__scopeDialog);
60
- return o.modal ? /* @__PURE__ */ s(x, {
61
- present: c || o.open
62
- }, /* @__PURE__ */ s(z, i({}, n, {
63
- ref: r
64
- }))) : null;
65
- }), z = /* @__PURE__ */ f((e, r) => {
66
- const { __scopeDialog: t, ...c } = e, n = d(v, t);
67
- return (
68
- // Make sure `Content` is scrollable even when it doesn't live inside `RemoveScroll`
69
- // ie. when `Overlay` and `Content` are siblings
70
- /* @__PURE__ */ s(G, {
71
- as: K,
72
- allowPinchZoom: !0,
73
- shards: [
74
- n.contentRef
75
- ]
76
- }, /* @__PURE__ */ s(D.div, i({
77
- "data-state": A(n.open)
78
- }, c, {
79
- ref: r,
80
- style: {
81
- pointerEvents: "auto",
82
- ...c.style
83
- }
84
- })))
85
- );
86
- }), p = "DialogContent", B = /* @__PURE__ */ f((e, r) => {
87
- const t = h(p, e.__scopeDialog), { forceMount: c = t.forceMount, ...n } = e, o = d(p, e.__scopeDialog);
88
- return /* @__PURE__ */ s(x, {
89
- present: c || o.open
90
- }, o.modal ? /* @__PURE__ */ s(J, i({}, n, {
91
- ref: r
92
- })) : /* @__PURE__ */ s(Q, i({}, n, {
93
- ref: r
94
- })));
95
- }), J = /* @__PURE__ */ f((e, r) => {
96
- const t = d(p, e.__scopeDialog), c = $(null), n = C(r, t.contentRef, c);
97
- return F(() => {
98
- const o = c.current;
99
- if (o) return H(o);
100
- }, []), /* @__PURE__ */ s(E, i({}, e, {
101
- ref: n,
102
- trapFocus: t.open,
103
- disableOutsidePointerEvents: !0,
104
- onCloseAutoFocus: g(e.onCloseAutoFocus, (o) => {
105
- var a;
106
- o.preventDefault(), (a = t.triggerRef.current) === null || a === void 0 || a.focus();
107
- }),
108
- onPointerDownOutside: g(e.onPointerDownOutside, (o) => {
109
- const a = o.detail.originalEvent, l = a.button === 0 && a.ctrlKey === !0;
110
- (a.button === 2 || l) && o.preventDefault();
111
- }),
112
- onFocusOutside: g(
113
- e.onFocusOutside,
114
- (o) => o.preventDefault()
115
- )
116
- }));
117
- }), Q = /* @__PURE__ */ f((e, r) => {
118
- const t = d(p, e.__scopeDialog), c = $(!1), n = $(!1);
119
- return /* @__PURE__ */ s(E, i({}, e, {
120
- ref: r,
121
- trapFocus: !1,
122
- disableOutsidePointerEvents: !1,
123
- onCloseAutoFocus: (o) => {
124
- var a;
125
- if ((a = e.onCloseAutoFocus) === null || a === void 0 || a.call(e, o), !o.defaultPrevented) {
126
- var l;
127
- c.current || (l = t.triggerRef.current) === null || l === void 0 || l.focus(), o.preventDefault();
128
- }
129
- c.current = !1, n.current = !1;
130
- },
131
- onInteractOutside: (o) => {
132
- var a, l;
133
- (a = e.onInteractOutside) === null || a === void 0 || a.call(e, o), o.defaultPrevented || (c.current = !0, o.detail.originalEvent.type === "pointerdown" && (n.current = !0));
134
- const u = o.target;
135
- ((l = t.triggerRef.current) === null || l === void 0 ? void 0 : l.contains(u)) && o.preventDefault(), o.detail.originalEvent.type === "focusin" && n.current && o.preventDefault();
136
- }
137
- }));
138
- }), E = /* @__PURE__ */ f((e, r) => {
139
- const { __scopeDialog: t, trapFocus: c, onOpenAutoFocus: n, onCloseAutoFocus: o, ...a } = e, l = d(p, t), u = $(null), b = C(r, u);
140
- return j(), /* @__PURE__ */ s(M, null, /* @__PURE__ */ s(k, {
141
- asChild: !0,
142
- loop: !0,
143
- trapped: c,
144
- onMountAutoFocus: n,
145
- onUnmountAutoFocus: o
146
- }, /* @__PURE__ */ s(L, i({
147
- role: "dialog",
148
- id: l.contentId,
149
- "aria-describedby": l.descriptionId,
150
- "aria-labelledby": l.titleId,
151
- "data-state": A(l.open)
152
- }, a, {
153
- ref: b,
154
- onDismiss: () => l.onOpenChange(!1)
155
- }))), !1);
156
- }), W = "DialogTitle", me = /* @__PURE__ */ f((e, r) => {
157
- const { __scopeDialog: t, ...c } = e, n = d(W, t);
158
- return /* @__PURE__ */ s(D.h2, i({
159
- id: n.titleId
160
- }, c, {
161
- ref: r
162
- }));
163
- }), X = "DialogDescription", _e = /* @__PURE__ */ f((e, r) => {
164
- const { __scopeDialog: t, ...c } = e, n = d(X, t);
165
- return /* @__PURE__ */ s(D.p, i({
166
- id: n.descriptionId
167
- }, c, {
168
- ref: r
169
- }));
170
- }), ee = "DialogClose", ve = /* @__PURE__ */ f((e, r) => {
171
- const { __scopeDialog: t, ...c } = e, n = d(ee, t);
172
- return /* @__PURE__ */ s(D.button, i({
173
- type: "button"
174
- }, c, {
175
- ref: r,
176
- onClick: g(
177
- e.onClick,
178
- () => n.onOpenChange(!1)
179
- )
180
- }));
181
- });
182
- function A(e) {
183
- return e ? "open" : "closed";
1
+ import * as e from "react";
2
+ function c(o, n) {
3
+ typeof o == "function" ? o(n) : o != null && (o.current = n);
4
+ }
5
+ function u(...o) {
6
+ return (n) => o.forEach((t) => c(t, n));
7
+ }
8
+ function i(...o) {
9
+ return e.useCallback(u(...o), o);
184
10
  }
185
- const xe = V, Ce = Z, Oe = q, Pe = B;
186
11
  export {
187
- Pe as Content,
188
- V as Dialog,
189
- ve as DialogClose,
190
- B as DialogContent,
191
- _e as DialogDescription,
192
- q as DialogOverlay,
193
- Z as DialogPortal,
194
- me as DialogTitle,
195
- Oe as Overlay,
196
- Ce as Portal,
197
- xe as Root,
198
- De as createDialogScope
12
+ u as composeRefs,
13
+ i as useComposedRefs
199
14
  };
@@ -1,44 +1,207 @@
1
- import s from "./index.es170.js";
2
- import { forwardRef as m, useEffect as n, createElement as p } from "react";
3
- import { flushSync as d } from "react-dom";
4
- import { Slot as $ } from "./index.es182.js";
5
- const l = [
6
- "a",
7
- "button",
8
- "div",
9
- "form",
10
- "h2",
11
- "h3",
12
- "img",
13
- "input",
14
- "label",
15
- "li",
16
- "nav",
17
- "ol",
18
- "p",
19
- "span",
20
- "svg",
21
- "ul"
22
- ], E = l.reduce((e, t) => {
23
- const r = /* @__PURE__ */ m((i, o) => {
24
- const { asChild: c, ...f } = i, a = c ? $ : t;
25
- return n(() => {
26
- window[Symbol.for("radix-ui")] = !0;
27
- }, []), /* @__PURE__ */ p(a, s({}, f, {
28
- ref: o
29
- }));
1
+ import C from "./index.es170.js";
2
+ import x from "./index.es290.js";
3
+ import N from "./index.es291.js";
4
+ import v from "./index.es292.js";
5
+ import A from "./index.es293.js";
6
+ import _ from "./index.es294.js";
7
+ import c from "react";
8
+ import E from "./index.es295.js";
9
+ import { classNamesShape as $ } from "./index.es296.js";
10
+ import { forceReflow as S } from "./index.es297.js";
11
+ var T = function(i, p) {
12
+ return i && p && p.split(" ").forEach(function(s) {
13
+ return A(i, s);
14
+ });
15
+ }, d = function(i, p) {
16
+ return i && p && p.split(" ").forEach(function(s) {
17
+ return _(i, s);
30
18
  });
31
- return r.displayName = `Primitive.${t}`, {
32
- ...e,
33
- [t]: r
34
- };
35
- }, {});
36
- function b(e, t) {
37
- e && d(
38
- () => e.dispatchEvent(t)
39
- );
40
- }
19
+ }, g = /* @__PURE__ */ function(u) {
20
+ N(i, u);
21
+ function i() {
22
+ for (var s, t = arguments.length, a = new Array(t), o = 0; o < t; o++)
23
+ a[o] = arguments[o];
24
+ return s = u.call.apply(u, [this].concat(a)) || this, s.appliedClasses = {
25
+ appear: {},
26
+ enter: {},
27
+ exit: {}
28
+ }, s.onEnter = function(e, r) {
29
+ var n = s.resolveArguments(e, r), l = n[0], m = n[1];
30
+ s.removeClasses(l, "exit"), s.addClass(l, m ? "appear" : "enter", "base"), s.props.onEnter && s.props.onEnter(e, r);
31
+ }, s.onEntering = function(e, r) {
32
+ var n = s.resolveArguments(e, r), l = n[0], m = n[1], f = m ? "appear" : "enter";
33
+ s.addClass(l, f, "active"), s.props.onEntering && s.props.onEntering(e, r);
34
+ }, s.onEntered = function(e, r) {
35
+ var n = s.resolveArguments(e, r), l = n[0], m = n[1], f = m ? "appear" : "enter";
36
+ s.removeClasses(l, f), s.addClass(l, f, "done"), s.props.onEntered && s.props.onEntered(e, r);
37
+ }, s.onExit = function(e) {
38
+ var r = s.resolveArguments(e), n = r[0];
39
+ s.removeClasses(n, "appear"), s.removeClasses(n, "enter"), s.addClass(n, "exit", "base"), s.props.onExit && s.props.onExit(e);
40
+ }, s.onExiting = function(e) {
41
+ var r = s.resolveArguments(e), n = r[0];
42
+ s.addClass(n, "exit", "active"), s.props.onExiting && s.props.onExiting(e);
43
+ }, s.onExited = function(e) {
44
+ var r = s.resolveArguments(e), n = r[0];
45
+ s.removeClasses(n, "exit"), s.addClass(n, "exit", "done"), s.props.onExited && s.props.onExited(e);
46
+ }, s.resolveArguments = function(e, r) {
47
+ return s.props.nodeRef ? [s.props.nodeRef.current, e] : [e, r];
48
+ }, s.getClassNames = function(e) {
49
+ var r = s.props.classNames, n = typeof r == "string", l = n && r ? r + "-" : "", m = n ? "" + l + e : r[e], f = n ? m + "-active" : r[e + "Active"], h = n ? m + "-done" : r[e + "Done"];
50
+ return {
51
+ baseClassName: m,
52
+ activeClassName: f,
53
+ doneClassName: h
54
+ };
55
+ }, s;
56
+ }
57
+ var p = i.prototype;
58
+ return p.addClass = function(t, a, o) {
59
+ var e = this.getClassNames(a)[o + "ClassName"], r = this.getClassNames("enter"), n = r.doneClassName;
60
+ a === "appear" && o === "done" && n && (e += " " + n), o === "active" && t && S(t), e && (this.appliedClasses[a][o] = e, T(t, e));
61
+ }, p.removeClasses = function(t, a) {
62
+ var o = this.appliedClasses[a], e = o.base, r = o.active, n = o.done;
63
+ this.appliedClasses[a] = {}, e && d(t, e), r && d(t, r), n && d(t, n);
64
+ }, p.render = function() {
65
+ var t = this.props;
66
+ t.classNames;
67
+ var a = x(t, ["classNames"]);
68
+ return /* @__PURE__ */ c.createElement(E, C({}, a, {
69
+ onEnter: this.onEnter,
70
+ onEntered: this.onEntered,
71
+ onEntering: this.onEntering,
72
+ onExit: this.onExit,
73
+ onExiting: this.onExiting,
74
+ onExited: this.onExited
75
+ }));
76
+ }, i;
77
+ }(c.Component);
78
+ g.defaultProps = {
79
+ classNames: ""
80
+ };
81
+ g.propTypes = process.env.NODE_ENV !== "production" ? C({}, E.propTypes, {
82
+ /**
83
+ * The animation classNames applied to the component as it appears, enters,
84
+ * exits or has finished the transition. A single name can be provided, which
85
+ * will be suffixed for each stage, e.g. `classNames="fade"` applies:
86
+ *
87
+ * - `fade-appear`, `fade-appear-active`, `fade-appear-done`
88
+ * - `fade-enter`, `fade-enter-active`, `fade-enter-done`
89
+ * - `fade-exit`, `fade-exit-active`, `fade-exit-done`
90
+ *
91
+ * A few details to note about how these classes are applied:
92
+ *
93
+ * 1. They are _joined_ with the ones that are already defined on the child
94
+ * component, so if you want to add some base styles, you can use
95
+ * `className` without worrying that it will be overridden.
96
+ *
97
+ * 2. If the transition component mounts with `in={false}`, no classes are
98
+ * applied yet. You might be expecting `*-exit-done`, but if you think
99
+ * about it, a component cannot finish exiting if it hasn't entered yet.
100
+ *
101
+ * 2. `fade-appear-done` and `fade-enter-done` will _both_ be applied. This
102
+ * allows you to define different behavior for when appearing is done and
103
+ * when regular entering is done, using selectors like
104
+ * `.fade-enter-done:not(.fade-appear-done)`. For example, you could apply
105
+ * an epic entrance animation when element first appears in the DOM using
106
+ * [Animate.css](https://daneden.github.io/animate.css/). Otherwise you can
107
+ * simply use `fade-enter-done` for defining both cases.
108
+ *
109
+ * Each individual classNames can also be specified independently like:
110
+ *
111
+ * ```js
112
+ * classNames={{
113
+ * appear: 'my-appear',
114
+ * appearActive: 'my-active-appear',
115
+ * appearDone: 'my-done-appear',
116
+ * enter: 'my-enter',
117
+ * enterActive: 'my-active-enter',
118
+ * enterDone: 'my-done-enter',
119
+ * exit: 'my-exit',
120
+ * exitActive: 'my-active-exit',
121
+ * exitDone: 'my-done-exit',
122
+ * }}
123
+ * ```
124
+ *
125
+ * If you want to set these classes using CSS Modules:
126
+ *
127
+ * ```js
128
+ * import styles from './styles.css';
129
+ * ```
130
+ *
131
+ * you might want to use camelCase in your CSS file, that way could simply
132
+ * spread them instead of listing them one by one:
133
+ *
134
+ * ```js
135
+ * classNames={{ ...styles }}
136
+ * ```
137
+ *
138
+ * @type {string | {
139
+ * appear?: string,
140
+ * appearActive?: string,
141
+ * appearDone?: string,
142
+ * enter?: string,
143
+ * enterActive?: string,
144
+ * enterDone?: string,
145
+ * exit?: string,
146
+ * exitActive?: string,
147
+ * exitDone?: string,
148
+ * }}
149
+ */
150
+ classNames: $,
151
+ /**
152
+ * A `<Transition>` callback fired immediately after the 'enter' or 'appear' class is
153
+ * applied.
154
+ *
155
+ * **Note**: when `nodeRef` prop is passed, `node` is not passed.
156
+ *
157
+ * @type Function(node: HtmlElement, isAppearing: bool)
158
+ */
159
+ onEnter: v.func,
160
+ /**
161
+ * A `<Transition>` callback fired immediately after the 'enter-active' or
162
+ * 'appear-active' class is applied.
163
+ *
164
+ * **Note**: when `nodeRef` prop is passed, `node` is not passed.
165
+ *
166
+ * @type Function(node: HtmlElement, isAppearing: bool)
167
+ */
168
+ onEntering: v.func,
169
+ /**
170
+ * A `<Transition>` callback fired immediately after the 'enter' or
171
+ * 'appear' classes are **removed** and the `done` class is added to the DOM node.
172
+ *
173
+ * **Note**: when `nodeRef` prop is passed, `node` is not passed.
174
+ *
175
+ * @type Function(node: HtmlElement, isAppearing: bool)
176
+ */
177
+ onEntered: v.func,
178
+ /**
179
+ * A `<Transition>` callback fired immediately after the 'exit' class is
180
+ * applied.
181
+ *
182
+ * **Note**: when `nodeRef` prop is passed, `node` is not passed
183
+ *
184
+ * @type Function(node: HtmlElement)
185
+ */
186
+ onExit: v.func,
187
+ /**
188
+ * A `<Transition>` callback fired immediately after the 'exit-active' is applied.
189
+ *
190
+ * **Note**: when `nodeRef` prop is passed, `node` is not passed
191
+ *
192
+ * @type Function(node: HtmlElement)
193
+ */
194
+ onExiting: v.func,
195
+ /**
196
+ * A `<Transition>` callback fired immediately after the 'exit' classes
197
+ * are **removed** and the `exit-done` class is added to the DOM node.
198
+ *
199
+ * **Note**: when `nodeRef` prop is passed, `node` is not passed
200
+ *
201
+ * @type Function(node: HtmlElement)
202
+ */
203
+ onExited: v.func
204
+ }) : {};
41
205
  export {
42
- E as Primitive,
43
- b as dispatchDiscreteCustomEvent
206
+ g as default
44
207
  };
@@ -1,23 +1,13 @@
1
- import { l as o } from "./index.es101.js";
2
- import { isSameDay as t } from "./index.es219.js";
3
- function m(i, l) {
4
- return {
5
- selectMultipleDate: (r) => {
6
- if (!i) return l([r]);
7
- const n = o.findIndex(
8
- i,
9
- (s) => t(s, r)
10
- );
11
- if (n === -1) return l([...i, r]);
12
- const u = [
13
- ...i.slice(0, n),
14
- ...i.slice(n + 1)
15
- ];
16
- l(u);
17
- },
18
- isMultipleSelected: (r) => o.isArray(i) && i.some((n) => t(n, r))
19
- };
1
+ import * as r from "react";
2
+ function o(t) {
3
+ const e = r.useRef(t);
4
+ return r.useEffect(() => {
5
+ e.current = t;
6
+ }), r.useMemo(() => (...n) => {
7
+ var u;
8
+ return (u = e.current) == null ? void 0 : u.call(e, ...n);
9
+ }, []);
20
10
  }
21
11
  export {
22
- m as default
12
+ o as useCallbackRef
23
13
  };
@@ -1,39 +1,9 @@
1
- import { isDateRange as f } from "./index.es104.js";
2
- import { isBefore as R } from "./index.es218.js";
3
- import { eachDayOfInterval as l } from "./index.es194.js";
4
- import { startOfDay as o } from "./index.es192.js";
5
- import { isWithinInterval as y } from "./index.es223.js";
6
- import { isSameDay as e } from "./index.es219.js";
7
- function w(r, i, u) {
8
- const D = (n) => {
9
- if (r == null ? void 0 : r.start) {
10
- const { start: t, end: s } = r;
11
- if (R(n, t) || t && s) {
12
- i({ start: n, end: void 0 });
13
- return;
14
- }
15
- if (g(t, n)) return;
16
- i({
17
- start: t,
18
- end: n
19
- });
20
- } else
21
- i({ start: n, end: void 0 });
22
- }, g = (n, a) => !u || !n || !a ? !1 : l({ start: o(n), end: a }).some((m) => u(m));
23
- return {
24
- selectRangeDate: D,
25
- isInRange: (n) => {
26
- if (!f(r) || !r) return !1;
27
- const { start: a, end: t } = r;
28
- return a && !t ? e(n, a) : !a || !t ? !1 : y(n, {
29
- start: o(a),
30
- end: o(t)
31
- });
32
- },
33
- isFirstDayFromRange: (n) => !r || !f(r) || !r.start ? !1 : e(n, r.start),
34
- isLastDayFromRange: (n) => !r || !f(r) || !r.end ? !1 : e(n, r.end)
1
+ function h(f, c, { checkForDefaultPrevented: p = !0 } = {}) {
2
+ return function(s) {
3
+ if (f == null || f(s), p === !1 || !s.defaultPrevented)
4
+ return c == null ? void 0 : c(s);
35
5
  };
36
6
  }
37
7
  export {
38
- w as default
8
+ h as composeEventHandlers
39
9
  };
@@ -1,4 +1,4 @@
1
- import { l as o } from "./index.es101.js";
1
+ import { l as o } from "./index.es104.js";
2
2
  import { useState as i, useCallback as r } from "react";
3
3
  function O(e) {
4
4
  const [u, n] = i(e), f = r(() => n(e), [e]), b = r(
@@ -1,13 +1,67 @@
1
- import { isDate as n } from "./index.es106.js";
2
- import { isSameDay as l } from "./index.es219.js";
3
- function S(t, i) {
4
- return {
5
- selectSingleDate: (e) => {
6
- i(e);
7
- },
8
- isSingleSelected: (e) => n(t) && l(e, t)
1
+ import * as u from "react";
2
+ import { j as C } from "./index.es83.js";
3
+ function $(e, c) {
4
+ const o = u.createContext(c);
5
+ function a(r) {
6
+ const { children: t, ...n } = r, s = u.useMemo(() => n, Object.values(n));
7
+ return /* @__PURE__ */ C.jsx(o.Provider, { value: s, children: t });
8
+ }
9
+ function i(r) {
10
+ const t = u.useContext(o);
11
+ if (t) return t;
12
+ if (c !== void 0) return c;
13
+ throw new Error(`\`${r}\` must be used within \`${e}\``);
14
+ }
15
+ return a.displayName = e + "Provider", [a, i];
16
+ }
17
+ function j(e, c = []) {
18
+ let o = [];
19
+ function a(r, t) {
20
+ const n = u.createContext(t), s = o.length;
21
+ o = [...o, t];
22
+ function d(m) {
23
+ const { scope: x, children: f, ...p } = m, S = (x == null ? void 0 : x[e][s]) || n, h = u.useMemo(() => p, Object.values(p));
24
+ return /* @__PURE__ */ C.jsx(S.Provider, { value: h, children: f });
25
+ }
26
+ function v(m, x) {
27
+ const f = (x == null ? void 0 : x[e][s]) || n, p = u.useContext(f);
28
+ if (p) return p;
29
+ if (t !== void 0) return t;
30
+ throw new Error(`\`${m}\` must be used within \`${r}\``);
31
+ }
32
+ return d.displayName = r + "Provider", [d, v];
33
+ }
34
+ const i = () => {
35
+ const r = o.map((t) => u.createContext(t));
36
+ return function(n) {
37
+ const s = (n == null ? void 0 : n[e]) || r;
38
+ return u.useMemo(
39
+ () => ({ [`__scope${e}`]: { ...n, [e]: s } }),
40
+ [n, s]
41
+ );
42
+ };
43
+ };
44
+ return i.scopeName = e, [a, P(i, ...c)];
45
+ }
46
+ function P(...e) {
47
+ const c = e[0];
48
+ if (e.length === 1) return c;
49
+ const o = () => {
50
+ const a = e.map((i) => ({
51
+ useScope: i(),
52
+ scopeName: i.scopeName
53
+ }));
54
+ return function(r) {
55
+ const t = a.reduce((n, { useScope: s, scopeName: d }) => {
56
+ const m = s(r)[`__scope${d}`];
57
+ return { ...n, ...m };
58
+ }, {});
59
+ return u.useMemo(() => ({ [`__scope${c.scopeName}`]: t }), [t]);
60
+ };
9
61
  };
62
+ return o.scopeName = c.scopeName, o;
10
63
  }
11
64
  export {
12
- S as default
65
+ $ as createContext,
66
+ j as createContextScope
13
67
  };
@@ -1,9 +1,35 @@
1
- function h(f, c, { checkForDefaultPrevented: p = !0 } = {}) {
2
- return function(s) {
3
- if (f == null || f(s), p === !1 || !s.defaultPrevented)
4
- return c == null ? void 0 : c(s);
5
- };
1
+ import * as n from "react";
2
+ import * as p from "react-dom";
3
+ import { Slot as f } from "./index.es88.js";
4
+ import { j as u } from "./index.es83.js";
5
+ var c = [
6
+ "a",
7
+ "button",
8
+ "div",
9
+ "form",
10
+ "h2",
11
+ "h3",
12
+ "img",
13
+ "input",
14
+ "label",
15
+ "li",
16
+ "nav",
17
+ "ol",
18
+ "p",
19
+ "span",
20
+ "svg",
21
+ "ul"
22
+ ], v = c.reduce((r, i) => {
23
+ const t = n.forwardRef((o, e) => {
24
+ const { asChild: s, ...m } = o, a = s ? f : i;
25
+ return typeof window < "u" && (window[Symbol.for("radix-ui")] = !0), /* @__PURE__ */ u.jsx(a, { ...m, ref: e });
26
+ });
27
+ return t.displayName = `Primitive.${i}`, { ...r, [i]: t };
28
+ }, {});
29
+ function h(r, i) {
30
+ r && p.flushSync(() => r.dispatchEvent(i));
6
31
  }
7
32
  export {
8
- h as composeEventHandlers
33
+ v as Primitive,
34
+ h as dispatchDiscreteCustomEvent
9
35
  };