@wrdagency/blockout 1.0.5 → 1.0.7

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 (196) hide show
  1. package/dist/2NBKRL7C-CzwWfv1x.js +76 -0
  2. package/dist/2RSXSRCN-rMUAytae.js +61 -0
  3. package/dist/{4CMBR7SL-xNGezbCB.js → 4CMBR7SL-ChJnawVl.js} +132 -126
  4. package/dist/{5JTVDSTH-CIreO5bC.js → 5JTVDSTH-DcfjjEya.js} +4 -4
  5. package/dist/{5VQZOHHZ-CNzYHc1X.js → 5VQZOHHZ-BN-teS5E.js} +1 -1
  6. package/dist/{6VRAQV3D-BoLhl3hf.js → 6VRAQV3D-DK_p41oq.js} +6 -6
  7. package/dist/A3WPL2ZJ-CpUtG5Sk.js +12 -0
  8. package/dist/{BM6PGYQY-Bhr7peim.js → BM6PGYQY-CkMwDqt0.js} +2 -2
  9. package/dist/Check.es-CMkTf2It.js +38 -0
  10. package/dist/{DG5U6ZEL-C7eLVyh-.js → DG5U6ZEL-GfwW2sqh.js} +3 -3
  11. package/dist/EM5CXX6A-C74NAQPE.js +13 -0
  12. package/dist/{F5MUBM3I-_HauDyEF.js → F5MUBM3I-BbDMTUwx.js} +24 -24
  13. package/dist/{G7GW6PWC-Crp1Jn-8.js → G7GW6PWC-A0eDeXMt.js} +100 -96
  14. package/dist/IWEFDH56-CvOsIcbb.js +19 -0
  15. package/dist/{J2LQO3EC-CcHJqN0I.js → J2LQO3EC-DYtZQQv6.js} +4 -3
  16. package/dist/{KFH4SEIX-D-fCkpQv.js → KFH4SEIX-BFT9WmYk.js} +3 -3
  17. package/dist/{LMDWO4NN-DdLnHzru.js → LMDWO4NN-CIZvvtic.js} +233 -203
  18. package/dist/MAXQOH4L-DBaf8WKp.js +564 -0
  19. package/dist/MR26YJYP-DacZIkgJ.js +287 -0
  20. package/dist/MTZPJQMC-DPwZ6caC.js +13 -0
  21. package/dist/{O2PQ2652-THp22K4G.js → O2PQ2652-D2GSkoLq.js} +6 -6
  22. package/dist/P7GR5CS5-5PtDURPc.js +24 -0
  23. package/dist/{PFRGBC2K-DUhGSIey.js → PFRGBC2K-B9ko--FF.js} +34 -33
  24. package/dist/Plus.es-DJ5SuqNv.js +38 -0
  25. package/dist/RS7LB2H4-BvDKQaCt.js +18 -0
  26. package/dist/RZ4GPYOB-COPqjbOz.js +37 -0
  27. package/dist/{S43UC3DV-erT1ucAd.js → S43UC3DV-CiBKpqp8.js} +3 -3
  28. package/dist/{T7VMP3TM-C-Aesx9K.js → T7VMP3TM-C0xl-w4G.js} +21 -21
  29. package/dist/TP7N7UIH-Dc0CLLi8.js +33 -0
  30. package/dist/{UQQRIHDV-DIXH69U3.js → UQQRIHDV-BBkcyl82.js} +17 -17
  31. package/dist/UYGDZTLQ-9uAEICxv.js +13 -0
  32. package/dist/VIIRIBF3-uvnIyICw.js +31 -0
  33. package/dist/WMYDSCNQ-D4CU76mX.js +61 -0
  34. package/dist/{WYCIER3C-S-jsj0wy.js → WYCIER3C-CaoIoaX7.js} +4 -4
  35. package/dist/{YV4JVR4I-BXEaRiAN.js → YV4JVR4I-w1-dnslS.js} +47 -47
  36. package/dist/assets/index10.css +1 -1
  37. package/dist/assets/index11.css +1 -1
  38. package/dist/assets/index12.css +1 -1
  39. package/dist/assets/index13.css +1 -1
  40. package/dist/assets/index14.css +1 -1
  41. package/dist/assets/index15.css +1 -1
  42. package/dist/assets/index16.css +1 -1
  43. package/dist/assets/index17.css +1 -1
  44. package/dist/assets/index4.css +1 -1
  45. package/dist/assets/style16.css +1 -1
  46. package/dist/assets/style17.css +1 -1
  47. package/dist/assets/style18.css +1 -1
  48. package/dist/assets/style19.css +1 -1
  49. package/dist/assets/style20.css +1 -1
  50. package/dist/assets/style21.css +1 -1
  51. package/dist/assets/style22.css +1 -1
  52. package/dist/assets/style23.css +1 -1
  53. package/dist/assets/style24.css +1 -1
  54. package/dist/assets/style25.css +1 -1
  55. package/dist/assets/style26.css +1 -1
  56. package/dist/assets/style27.css +1 -0
  57. package/dist/components/breadcrumbs/index.js +5 -5
  58. package/dist/components/button/row.js +4 -4
  59. package/dist/components/controls/base-popover-control/index.js +4 -4
  60. package/dist/components/controls/card-number-control/index.js +1 -1
  61. package/dist/components/controls/date-control/index.js +1 -1
  62. package/dist/components/controls/date-control/picker.js +5 -5
  63. package/dist/components/controls/index.d.ts +1 -0
  64. package/dist/components/controls/index.js +12 -10
  65. package/dist/components/controls/list-control/item.js +34 -67
  66. package/dist/components/controls/list-control/list.js +1 -1
  67. package/dist/components/controls/recurrence-control/index.js +19 -18
  68. package/dist/components/controls/select-control/control.js +26 -37
  69. package/dist/components/controls/select-control/select.js +62 -1129
  70. package/dist/components/controls/tag-control/ariakit-experimental.d.ts +7 -0
  71. package/dist/components/controls/tag-control/ariakit-experimental.js +2308 -0
  72. package/dist/components/controls/tag-control/index.d.ts +10 -0
  73. package/dist/components/controls/tag-control/index.js +137 -0
  74. package/dist/components/controls/tag-control/props.d.ts +20 -0
  75. package/dist/components/controls/tag-control/props.js +57 -0
  76. package/dist/components/controls/text-control/index.js +1 -1
  77. package/dist/components/data-view/data/apply.js +15 -15
  78. package/dist/components/data-view/data/filter.js +14 -12
  79. package/dist/components/data-view/index.js +1 -1
  80. package/dist/components/data-view/layouts/grid/empty.js +1 -1
  81. package/dist/components/data-view/layouts/grid/group.js +9 -7
  82. package/dist/components/data-view/layouts/grid/item.js +9 -7
  83. package/dist/components/data-view/layouts/grid/root.js +1 -1
  84. package/dist/components/data-view/layouts/kanban/empty.js +1 -1
  85. package/dist/components/data-view/layouts/kanban/group.js +9 -7
  86. package/dist/components/data-view/layouts/kanban/item.js +9 -7
  87. package/dist/components/data-view/layouts/kanban/root.js +1 -1
  88. package/dist/components/data-view/layouts/list/empty.js +1 -1
  89. package/dist/components/data-view/layouts/list/group.js +9 -7
  90. package/dist/components/data-view/layouts/list/item.js +9 -7
  91. package/dist/components/data-view/layouts/list/root.js +1 -1
  92. package/dist/components/data-view/layouts/table/empty.js +9 -7
  93. package/dist/components/data-view/layouts/table/group.js +10 -8
  94. package/dist/components/data-view/layouts/table/item.js +10 -8
  95. package/dist/components/data-view/layouts/table/root.js +9 -7
  96. package/dist/components/data-view/parts/body/index.js +11 -9
  97. package/dist/components/data-view/parts/controls/index.js +9 -7
  98. package/dist/components/data-view/parts/controls/search.js +9 -7
  99. package/dist/components/data-view/parts/filters/editor.js +8 -6
  100. package/dist/components/data-view/parts/filters/index.js +1 -1
  101. package/dist/components/data-view/parts/filters/list.js +39 -73
  102. package/dist/components/data-view/parts/footer/actions.js +9 -7
  103. package/dist/components/data-view/parts/footer/index.js +9 -7
  104. package/dist/components/data-view/parts/footer/selection.js +9 -7
  105. package/dist/components/data-view/parts/view-control/index.js +23 -21
  106. package/dist/components/data-view/root.js +9 -7
  107. package/dist/components/data-view/slots/group/checkbox.js +9 -7
  108. package/dist/components/data-view/slots/group/context.js +1 -1
  109. package/dist/components/data-view/slots/group/icon.js +1 -1
  110. package/dist/components/data-view/slots/group/index.js +1 -1
  111. package/dist/components/data-view/slots/group/label.js +1 -1
  112. package/dist/components/data-view/slots/index.js +3 -3
  113. package/dist/components/data-view/slots/item/actions.js +1 -1
  114. package/dist/components/data-view/slots/item/checkbox.js +9 -7
  115. package/dist/components/data-view/slots/item/depth.js +3 -3
  116. package/dist/components/data-view/slots/item/description.js +1 -1
  117. package/dist/components/data-view/slots/item/index.js +2 -2
  118. package/dist/components/data-view/slots/item/properties.js +2 -2
  119. package/dist/components/data-view/slots/item/relations.js +3 -3
  120. package/dist/components/data-view/slots/item/tags.js +1 -1
  121. package/dist/components/data-view/slots/item/thumbnail.js +1 -1
  122. package/dist/components/data-view/slots/item/title.js +1 -1
  123. package/dist/components/data-view/slots/item/util.js +2 -2
  124. package/dist/components/data-view/slots/property/field/editable.js +8 -6
  125. package/dist/components/data-view/slots/property/field/index.js +2 -2
  126. package/dist/components/data-view/slots/property/field/static.js +1 -1
  127. package/dist/components/data-view/slots/property/index.js +1 -1
  128. package/dist/components/data-view/slots/property/label.js +1 -1
  129. package/dist/components/data-view/slots/root/checkbox.js +8 -6
  130. package/dist/components/data-view/slots/root/index.js +1 -1
  131. package/dist/components/filesystem/file.js +1 -1
  132. package/dist/components/filesystem/folder.js +29 -80
  133. package/dist/components/filesystem/list.js +1 -1
  134. package/dist/components/filesystem/root.js +1 -1
  135. package/dist/components/index.js +41 -39
  136. package/dist/components/menu/index.js +14 -13
  137. package/dist/components/menu/item.js +1 -1
  138. package/dist/components/menu/items/action.js +1 -1
  139. package/dist/components/menu/items/spacer.js +4 -16
  140. package/dist/components/menu/items/submenu.js +4 -3
  141. package/dist/components/menu/items/toggle.js +1 -1
  142. package/dist/components/pagination/index.js +1 -1
  143. package/dist/components/tabs/list.js +8 -36
  144. package/dist/components/tabs/panel.js +13 -126
  145. package/dist/components/tabs/root.js +14 -166
  146. package/dist/components/tabs/tab.js +5 -79
  147. package/dist/components/toolbar/divider.js +7 -19
  148. package/dist/components/toolbar/index.js +10 -24
  149. package/dist/components/toolbar/root.js +5 -67
  150. package/dist/components/window/index.js +2 -2
  151. package/dist/{composite-provider-R5SnRc_G.js → composite-provider-B-M1AaRb.js} +2 -2
  152. package/dist/disclosure-provider-DW9RmAuE.js +61 -0
  153. package/dist/{filter-C-ZkRgt_.js → filter-GoxwLwkT.js} +14 -12
  154. package/dist/{index-DI0cEpya.js → index-C_xrLeQq.js} +20 -18
  155. package/dist/{index-BW-2OhmK.js → index-DJ2XZnew.js} +7 -5
  156. package/dist/{index-Bj4Ga50P.js → index-DpV0obFX.js} +6 -4
  157. package/dist/index.js +87 -85
  158. package/dist/item-CYpF0or4.js +58 -0
  159. package/dist/{style-tA0yiKCL.js → match-sorter.esm-MNVE8H_6.js} +1 -1
  160. package/dist/menu-button-D0chRxS0.js +416 -0
  161. package/dist/menu-separator-Cy38O3cZ.js +16 -0
  162. package/dist/{picker-BkmBjgWA.js → picker-BAQPD-c9.js} +4 -4
  163. package/dist/popover-provider-DZV1nb7Q.js +10 -0
  164. package/dist/primitives/popover/index.js +2 -2
  165. package/dist/primitives/popover/root.js +12 -3
  166. package/dist/primitives/popover/target.js +1 -1
  167. package/dist/primitives/popover/window.js +3 -3
  168. package/dist/primitives/tooltip/index.js +10 -173
  169. package/dist/select-popover-DYAZyLp4.js +542 -0
  170. package/dist/select-value-CeoMyvpZ.js +15 -0
  171. package/dist/{sortable.esm-De3H-_AA.js → sortable.esm-BuV7eW2H.js} +4 -4
  172. package/dist/{style-C7eFpUVU.js → style-CWAa57kN.js} +1 -1
  173. package/dist/tab-DjNG1rEI.js +79 -0
  174. package/dist/tab-list-DtMnUjoy.js +33 -0
  175. package/dist/tab-panel-DdkeLgKE.js +118 -0
  176. package/dist/tab-provider-BMkHrtIK.js +158 -0
  177. package/dist/tag-remove-BVa8oSsq.js +533 -0
  178. package/dist/toolbar-B7_t1rYu.js +68 -0
  179. package/dist/toolbar-separator-DBoO5XdF.js +16 -0
  180. package/dist/tooltip-anchor-CxZWazuo.js +173 -0
  181. package/package.json +1 -1
  182. package/dist/2NBKRL7C-Cug3TzgR.js +0 -85
  183. package/dist/2RSXSRCN-Bc3g-z-i.js +0 -61
  184. package/dist/A3WPL2ZJ-D0Eh1dEB.js +0 -11
  185. package/dist/EM5CXX6A-DKxCXPnz.js +0 -14
  186. package/dist/MR26YJYP-yD1_RvCA.js +0 -283
  187. package/dist/MTZPJQMC-RLG1q394.js +0 -12
  188. package/dist/P7GR5CS5-Dub2zqTX.js +0 -22
  189. package/dist/RS7LB2H4-C0kmTjy8.js +0 -15
  190. package/dist/RZ4GPYOB-c8s_KHUk.js +0 -37
  191. package/dist/TP7N7UIH-mdk33dnV.js +0 -34
  192. package/dist/UYGDZTLQ-fOwUiOjI.js +0 -12
  193. package/dist/VIIRIBF3-DylpToFV.js +0 -18
  194. package/dist/WMYDSCNQ-D43V-JUe.js +0 -62
  195. package/dist/item-C5GtZF5t.js +0 -470
  196. package/dist/root-C7IYlG1s.js +0 -20
@@ -0,0 +1,533 @@
1
+ import { d as ve, a as ee } from "./S43UC3DV-CiBKpqp8.js";
2
+ import { createContext as he, useContext as W, useRef as ge, useState as te, useEffect as oe, useCallback as be } from "react";
3
+ import { f as _, c as K, a as R, _ as L, m as T, o as P, r as Ce, i as $, a4 as ye, C as Pe, a7 as xe, s as Te, q as ne, j, e as O, ag as re, l as ae, ah as ke, y as z, aa as Ve, n as Ee, G as Se, T as J, V as H, U as A, a5 as Ie } from "./LMDWO4NN-CIZvvtic.js";
4
+ import { jsx as E, jsxs as se, Fragment as De } from "react/jsx-runtime";
5
+ import { c as we, u as Oe, R as _e } from "./G7GW6PWC-A0eDeXMt.js";
6
+ import { u as Ke, d as q, T as ie, e as ue, f as Re, g as Le, h as Ne } from "./MAXQOH4L-DBaf8WKp.js";
7
+ import { a as le, c as Be, s as je, e as Fe, b as Me, d as Q } from "./YV4JVR4I-w1-dnslS.js";
8
+ import { u as ce } from "./6VRAQV3D-DK_p41oq.js";
9
+ import { t as $e } from "./7PRQYBBV-91wrWGjk.js";
10
+ import { u as Ue } from "./5JTVDSTH-DcfjjEya.js";
11
+ import { b as He } from "./PFRGBC2K-B9ko--FF.js";
12
+ import { c as We, b as Ae } from "./4CMBR7SL-ChJnawVl.js";
13
+ var qe = he(!1), Ge = "span", Ze = /* @__PURE__ */ E(
14
+ "svg",
15
+ {
16
+ display: "block",
17
+ fill: "none",
18
+ stroke: "currentColor",
19
+ strokeLinecap: "round",
20
+ strokeLinejoin: "round",
21
+ strokeWidth: 1.5,
22
+ viewBox: "0 0 16 16",
23
+ height: "1em",
24
+ width: "1em",
25
+ children: /* @__PURE__ */ E("polyline", { points: "4,8 7,12 12,4" })
26
+ }
27
+ );
28
+ function ze(n) {
29
+ return n.checked ? n.children || Ze : typeof n.children == "function" ? n.children : null;
30
+ }
31
+ var de = K(
32
+ function(r) {
33
+ var o = r, { store: e, checked: a } = o, s = L(o, ["store", "checked"]);
34
+ const d = W(qe);
35
+ a = a ?? d;
36
+ const i = ze({ checked: a, children: s.children });
37
+ return s = T(P({
38
+ "aria-hidden": !0
39
+ }, s), {
40
+ children: i,
41
+ style: P({
42
+ width: "1em",
43
+ height: "1em",
44
+ pointerEvents: "none"
45
+ }, s.style)
46
+ }), Ce(s);
47
+ }
48
+ ), St = _(function(r) {
49
+ const o = de(r);
50
+ return R(Ge, o);
51
+ }), Je = "span", Qe = K(function(r) {
52
+ var o = r, { store: e, checked: a } = o, s = L(o, ["store", "checked"]);
53
+ const d = W(ve);
54
+ return a = a ?? d, s = de(T(P({}, s), { checked: a })), s;
55
+ }), It = _(function(r) {
56
+ const o = Qe(r);
57
+ return R(Je, o);
58
+ }), Xe = "div";
59
+ function Ye(n, ...r) {
60
+ if (!n) return !1;
61
+ if ("id" in n) {
62
+ const o = r.filter(Boolean).map((e) => `[aria-controls~="${e}"]`).join(", ");
63
+ return o ? n.matches(o) : !1;
64
+ }
65
+ return !1;
66
+ }
67
+ var et = K(
68
+ function(r) {
69
+ var o = r, {
70
+ store: e,
71
+ modal: a,
72
+ tabIndex: s,
73
+ alwaysVisible: d,
74
+ autoFocusOnHide: i = !0,
75
+ hideOnInteractOutside: m = !0
76
+ } = o, u = L(o, [
77
+ "store",
78
+ "modal",
79
+ "tabIndex",
80
+ "alwaysVisible",
81
+ "autoFocusOnHide",
82
+ "hideOnInteractOutside"
83
+ ]);
84
+ const l = ee();
85
+ e = e || l, $(
86
+ e,
87
+ process.env.NODE_ENV !== "production" && "ComboboxPopover must receive a `store` prop or be wrapped in a ComboboxProvider component."
88
+ );
89
+ const b = e.useState("baseElement"), g = ge(!1), C = le(
90
+ e.tag,
91
+ (p) => p == null ? void 0 : p.renderedItems.length
92
+ );
93
+ return u = Ke(P({ store: e, alwaysVisible: d }, u)), u = Oe(T(P({
94
+ store: e,
95
+ modal: a,
96
+ alwaysVisible: d,
97
+ backdrop: !1,
98
+ autoFocusOnShow: !1,
99
+ finalFocus: b,
100
+ preserveTabOrderAnchor: null,
101
+ unstable_treeSnapshotKey: C
102
+ }, u), {
103
+ // When the combobox popover is modal, we make sure to include the
104
+ // combobox input and all the combobox controls (cancel, disclosure) in
105
+ // the list of persistent elements so they make part of the modal context,
106
+ // allowing users to tab through them.
107
+ getPersistentElements() {
108
+ var p;
109
+ const h = ((p = u.getPersistentElements) == null ? void 0 : p.call(u)) || [];
110
+ if (!a || !e) return h;
111
+ const { contentElement: y, baseElement: t } = e.getState();
112
+ if (!t) return h;
113
+ const c = Pe(t), v = [];
114
+ if (y != null && y.id && v.push(`[aria-controls~="${y.id}"]`), t != null && t.id && v.push(`[aria-controls~="${t.id}"]`), !v.length) return [...h, t];
115
+ const x = v.join(","), I = c.querySelectorAll(x);
116
+ return [...h, ...I];
117
+ },
118
+ // The combobox popover should focus on the combobox input when it hides,
119
+ // unless the event was triggered by a click outside the popover, in which
120
+ // case the input shouldn't be re-focused.
121
+ autoFocusOnHide(p) {
122
+ return ye(i, p) ? !1 : g.current ? (g.current = !1, !1) : !0;
123
+ },
124
+ // Make sure we don't hide the popover when the user interacts with the
125
+ // combobox cancel or the combobox disclosure buttons. They will have the
126
+ // aria-controls attribute pointing to either the combobox input or the
127
+ // combobox popover elements.
128
+ hideOnInteractOutside(p) {
129
+ var h, y;
130
+ const t = e == null ? void 0 : e.getState(), c = (h = t == null ? void 0 : t.contentElement) == null ? void 0 : h.id, v = (y = t == null ? void 0 : t.baseElement) == null ? void 0 : y.id;
131
+ if (Ye(p.target, c, v)) return !1;
132
+ const x = typeof m == "function" ? m(p) : m;
133
+ return x && (g.current = p.type === "click"), x;
134
+ }
135
+ })), u;
136
+ }
137
+ ), Dt = we(
138
+ _(function(r) {
139
+ const o = et(r);
140
+ return R(Xe, o);
141
+ }),
142
+ ee
143
+ );
144
+ function G() {
145
+ const [n, r] = te(!1);
146
+ return oe(() => {
147
+ r(xe());
148
+ }, []), n;
149
+ }
150
+ var tt = "div", ot = K(function(r) {
151
+ var o = r, {
152
+ store: e,
153
+ value: a,
154
+ getItem: s,
155
+ removeOnKeyPress: d = !0
156
+ } = o, i = L(o, [
157
+ "store",
158
+ "value",
159
+ "getItem",
160
+ "removeOnKeyPress"
161
+ ]);
162
+ const m = q();
163
+ e = e || m, $(
164
+ e,
165
+ process.env.NODE_ENV !== "production" && "Tag must be wrapped in a TagList component."
166
+ );
167
+ const u = ne(i.id), l = G(), b = be(
168
+ (t) => {
169
+ const c = T(P({}, t), { value: a });
170
+ return s ? s(c) : c;
171
+ },
172
+ [a, s]
173
+ ), g = i.onKeyDown, C = j(d), p = O((t) => {
174
+ if (g == null || g(t), t.defaultPrevented) return;
175
+ const { inputElement: c } = e.getState(), v = t.key === "Backspace";
176
+ if ((v || t.key === "Delete") && C(t)) {
177
+ t.preventDefault(), e.removeValue(a);
178
+ const V = v && e.previous() || e.next();
179
+ e.move(V);
180
+ }
181
+ const I = !t.ctrlKey && !t.metaKey && t.key.length === 1, N = !re(), f = t.key === "v" || t.key === "V", D = (N ? t.ctrlKey : t.metaKey) && f;
182
+ (I || D) && (c == null || c.focus());
183
+ }), [h, y] = te();
184
+ return i = ae(
185
+ i,
186
+ (t) => /* @__PURE__ */ E(ie.Provider, { value: a, children: /* @__PURE__ */ E(ue.Provider, { value: y, children: t }) }),
187
+ [a]
188
+ ), i = T(P({
189
+ id: u,
190
+ role: l ? "listitem" : "option",
191
+ children: a,
192
+ "aria-describedby": h
193
+ }, i), {
194
+ onKeyDown: p
195
+ }), i = ce(T(P({
196
+ store: e
197
+ }, i), {
198
+ getItem: b
199
+ })), i;
200
+ }), wt = Te(
201
+ _(function(r) {
202
+ const o = ot(r);
203
+ return R(tt, o);
204
+ })
205
+ );
206
+ function me(n) {
207
+ return async () => {
208
+ const r = await (n == null ? void 0 : n());
209
+ return me(async () => (await (r == null ? void 0 : r()), n));
210
+ };
211
+ }
212
+ var M = nt();
213
+ function nt({
214
+ limit: n = 100
215
+ } = {}) {
216
+ const r = [];
217
+ let o = [], e = null;
218
+ const a = () => r.length > 0, s = () => o.length > 0;
219
+ return {
220
+ canUndo: a,
221
+ canRedo: s,
222
+ undo: async () => {
223
+ var u;
224
+ a() && (e = null, o.push(await ((u = r.pop()) == null ? void 0 : u())));
225
+ },
226
+ redo: async () => {
227
+ var u;
228
+ s() && (e = null, r.push(await ((u = o.pop()) == null ? void 0 : u())));
229
+ },
230
+ execute: async (u, l) => {
231
+ if (!u) return;
232
+ for (; r.length > n; )
233
+ r.shift();
234
+ const b = l === e;
235
+ e = l ?? null;
236
+ const g = b ? Math.max(0, r.length - 1) : r.length, C = await u();
237
+ if (!C) return;
238
+ o = [];
239
+ const p = r[g];
240
+ r[g] = me(async () => {
241
+ await (C == null ? void 0 : C());
242
+ const h = await (p == null ? void 0 : p());
243
+ return async () => {
244
+ await (h == null ? void 0 : h()), await (u == null ? void 0 : u());
245
+ };
246
+ });
247
+ }
248
+ };
249
+ }
250
+ var rt = "input", at = [`
251
+ `, ";", ",", /\s/];
252
+ function X(n, r = at) {
253
+ const o = n === void 0 ? r : n;
254
+ return o ? $e(o) : [];
255
+ }
256
+ function Y(n, r) {
257
+ for (const o of r) {
258
+ let e = n.match(o);
259
+ for (; (e == null ? void 0 : e.index) === 0; )
260
+ n = n.slice(e[0].length), e = n.match(o);
261
+ if (e)
262
+ return n.split(o);
263
+ }
264
+ return [];
265
+ }
266
+ var st = K(
267
+ function(r) {
268
+ var o = r, {
269
+ store: e,
270
+ tabbable: a = !0,
271
+ delimiter: s,
272
+ addValueOnPaste: d = !0,
273
+ addValueOnChange: i = !0,
274
+ setValueOnChange: m = !0,
275
+ removeOnBackspace: u = !0
276
+ } = o, l = L(o, [
277
+ "store",
278
+ "tabbable",
279
+ "delimiter",
280
+ "addValueOnPaste",
281
+ "addValueOnChange",
282
+ "setValueOnChange",
283
+ "removeOnBackspace"
284
+ ]);
285
+ const b = q();
286
+ e = e || b, $(
287
+ e,
288
+ process.env.NODE_ENV !== "production" && "TagInput must receive a `store` prop or be wrapped in a TagProvider component."
289
+ );
290
+ const g = le(e, "value"), C = l.onPaste, p = j(d), h = O((f) => {
291
+ if (C == null || C(f), f.defaultPrevented) return;
292
+ const k = f.clipboardData.getData("text"), D = X(s), V = Y(k.trim(), D).map((w) => w.trim()).filter((w) => w !== ""), S = Object.assign(f, { values: V });
293
+ if (p(S) && V.length) {
294
+ f.preventDefault();
295
+ for (const w of V)
296
+ e.addValue(w);
297
+ }
298
+ }), y = l.onChange, t = j(m), c = j(i), v = O((f) => {
299
+ if (y == null || y(f), f.defaultPrevented || !e) return;
300
+ const { value: k } = e.getState(), D = ke(f), V = f.currentTarget, { start: S, end: w } = z(V), { value: U } = V;
301
+ if (t(f) && M.execute(() => {
302
+ if (e.setValue(U), queueMicrotask(() => {
303
+ Ve(V, S, w);
304
+ }), U !== k)
305
+ return () => e.setValue(k);
306
+ }, D), S === w && S === U.length) {
307
+ const pe = X(s);
308
+ let B = Y(U, pe);
309
+ const Z = B.pop() || "";
310
+ B = B.map((F) => F.trim()).filter((F) => F !== "");
311
+ const fe = Object.assign(f, { values: B });
312
+ if (B.length && c(fe)) {
313
+ f.preventDefault();
314
+ for (const F of B)
315
+ e.addValue(F);
316
+ M.execute(() => {
317
+ if (e.setValue(Z), Z !== k)
318
+ return () => e.setValue(k);
319
+ }, D);
320
+ }
321
+ }
322
+ }), x = l.onKeyDown, I = j(u), N = O((f) => {
323
+ if (x == null || x(f), !f.defaultPrevented && f.key === "Backspace" && I(f)) {
324
+ const { start: k, end: D } = z(f.currentTarget);
325
+ if (!(k === D && k === 0)) return;
326
+ e.setValues((S) => S.length ? S.slice(0, -1) : S);
327
+ }
328
+ });
329
+ return l = T(P({
330
+ value: g
331
+ }, l), {
332
+ ref: Ee(e.setInputElement, l.ref),
333
+ onPaste: h,
334
+ onChange: v,
335
+ onKeyDown: N
336
+ }), l = ce(P({ store: e, tabbable: a }, l)), l;
337
+ }
338
+ ), Ot = _(function(r) {
339
+ const o = st(r);
340
+ return R(rt, o);
341
+ }), it = "div", ut = K(
342
+ function(r) {
343
+ var o = r, { store: e } = o, a = L(o, ["store"]);
344
+ const s = Re();
345
+ e = e || s, $(
346
+ e,
347
+ process.env.NODE_ENV !== "production" && "TagList must receive a `store` prop or be wrapped in a TagProvider component."
348
+ );
349
+ const d = a.onMouseDown, i = O((t) => {
350
+ if (d == null || d(t), t.defaultPrevented) return;
351
+ const c = t.target, v = t.currentTarget, x = He(c);
352
+ if (!(x === v) && v.contains(x)) return;
353
+ const { inputElement: N } = e.getState();
354
+ Se(t.currentTarget, "mouseup", () => {
355
+ N == null || N.focus();
356
+ });
357
+ }), m = a.onKeyDown, u = O((t) => {
358
+ if (m == null || m(t), t.defaultPrevented) return;
359
+ const c = !re(), v = t.key === "z" || t.key === "Z", x = c ? t.ctrlKey : t.metaKey, I = t.shiftKey && v || c && t.key === "y";
360
+ x && I ? (t.preventDefault(), M.redo()) : x && v && (t.preventDefault(), M.undo());
361
+ });
362
+ a = ae(
363
+ a,
364
+ (t) => /* @__PURE__ */ E(Le, { value: e, children: t }),
365
+ [e]
366
+ ), a = T(P({}, a), {
367
+ onMouseDown: i,
368
+ onKeyDown: u
369
+ }), a = Ue(P({ store: e }, a));
370
+ const l = e.useState(
371
+ (t) => t.orientation === "both" ? void 0 : t.orientation
372
+ ), g = e.useState((t) => t.renderedItems).filter((t) => !!t.value).map((t) => t.id), C = e.useState((t) => {
373
+ var c;
374
+ return (c = t.labelElement) == null ? void 0 : c.id;
375
+ }), p = {};
376
+ for (const t in a)
377
+ if (t === "role" || t.startsWith("aria-")) {
378
+ const c = t;
379
+ p[c] = a[c], delete a[c];
380
+ }
381
+ const h = G(), y = /* @__PURE__ */ se(De, { children: [
382
+ /* @__PURE__ */ E(
383
+ "div",
384
+ T(P({
385
+ role: h ? "list" : "listbox",
386
+ "aria-live": "polite",
387
+ "aria-relevant": "all",
388
+ "aria-atomic": !0,
389
+ "aria-labelledby": C,
390
+ "aria-orientation": l,
391
+ "aria-owns": g.join(" ")
392
+ }, p), {
393
+ style: { position: "fixed" }
394
+ })
395
+ ),
396
+ a.children
397
+ ] });
398
+ return a = T(P({}, a), {
399
+ children: y
400
+ }), a;
401
+ }
402
+ ), _t = _(function(r) {
403
+ const o = ut(r);
404
+ return R(it, o);
405
+ });
406
+ function lt(n = {}) {
407
+ var r;
408
+ const o = (r = n.store) == null ? void 0 : r.getState(), e = We(n), a = J(A({}, e.getState()), {
409
+ inputElement: H(o == null ? void 0 : o.inputElement, null),
410
+ labelElement: H(o == null ? void 0 : o.labelElement, null),
411
+ value: H(n.value, o == null ? void 0 : o.value, n.defaultValue, ""),
412
+ values: H(
413
+ n.values,
414
+ o == null ? void 0 : o.values,
415
+ n.defaultValues,
416
+ []
417
+ )
418
+ }), s = Be(a, e, n.store);
419
+ je(
420
+ s,
421
+ () => Fe(s, ["inputElement", "activeId"], (i) => {
422
+ i.inputElement && i.activeId === void 0 && s.setState("activeId", i.inputElement.id);
423
+ })
424
+ );
425
+ const d = (i) => {
426
+ const { values: m } = s.getState();
427
+ M.execute(() => {
428
+ let u = !0;
429
+ if (s.setState("values", (l) => {
430
+ const b = Ie(i, l);
431
+ return b === l && (u = !1), b;
432
+ }), !!u)
433
+ return () => {
434
+ var l;
435
+ s.setState("values", m), e.move((l = s.getState().inputElement) == null ? void 0 : l.id);
436
+ };
437
+ });
438
+ };
439
+ return J(A(A({}, e), s), {
440
+ setInputElement: (i) => s.setState("inputElement", i),
441
+ setLabelElement: (i) => s.setState("labelElement", i),
442
+ setValue: (i) => s.setState("value", i),
443
+ resetValue: () => s.setState("value", a.value),
444
+ setValues: d,
445
+ addValue: (i) => {
446
+ d((m) => m.includes(i) ? m : [...m, i]);
447
+ },
448
+ removeValue: (i) => d((m) => m.filter((u) => u !== i))
449
+ });
450
+ }
451
+ function ct(n, r, o) {
452
+ return Q(n, o, "value", "setValue"), Q(n, o, "values", "setValues"), Ae(n, r, o);
453
+ }
454
+ function dt(n = {}) {
455
+ const [r, o] = Me(lt, n);
456
+ return ct(r, o, n);
457
+ }
458
+ function Kt(n = {}) {
459
+ const r = dt(n);
460
+ return /* @__PURE__ */ E(Ne, { value: r, children: n.children });
461
+ }
462
+ var mt = "button", pt = K(
463
+ function(r) {
464
+ var o = r, {
465
+ store: e,
466
+ value: a,
467
+ removeOnClick: s = !0
468
+ } = o, d = L(o, [
469
+ "store",
470
+ "value",
471
+ "removeOnClick"
472
+ ]);
473
+ const i = q();
474
+ e = e || i, $(
475
+ e,
476
+ process.env.NODE_ENV !== "production" && "TagRemove must receive a `store` prop or be wrapped in a TagProvider component."
477
+ );
478
+ const m = ne(d.id), u = W(ue), l = W(ie), b = l !== null, g = a ?? l;
479
+ oe(() => (u == null || u(m), () => u == null ? void 0 : u()), [m, u]);
480
+ const C = d.onClick, p = j(s), h = O((c) => {
481
+ if (C == null || C(c), c.defaultPrevented || !e || !g || !p(c)) return;
482
+ const { inputElement: v } = e.getState();
483
+ e.removeValue(g), v == null || v.focus();
484
+ }), y = /* @__PURE__ */ se(
485
+ "svg",
486
+ {
487
+ display: "block",
488
+ viewBox: "0 0 24 24",
489
+ fill: "none",
490
+ stroke: "currentColor",
491
+ strokeWidth: 1.5,
492
+ strokeLinecap: "round",
493
+ strokeLinejoin: "round",
494
+ height: "1em",
495
+ width: "1em",
496
+ "aria-hidden": !0,
497
+ children: [
498
+ /* @__PURE__ */ E("path", { d: "M7.28782 5.46243C7.80963 4.92308 8.07054 4.65341 8.37751 4.46038C8.64963 4.28926 8.94749 4.16299 9.25969 4.0864C9.61186 4 9.98709 4 10.7375 4H16.8C17.9201 4 18.4802 4 18.908 4.21799C19.2843 4.40973 19.5903 4.71569 19.782 5.09202C20 5.51984 20 6.0799 20 7.2V16.8C20 17.9201 20 18.4802 19.782 18.908C19.5903 19.2843 19.2843 19.5903 18.908 19.782C18.4802 20 17.9201 20 16.8 20H10.7512C9.99584 20 9.61818 20 9.264 19.9126C8.95004 19.8351 8.65067 19.7073 8.37748 19.5342C8.06931 19.339 7.80802 19.0663 7.28544 18.521L2.59879 13.63C2.03714 13.0439 1.75631 12.7508 1.65115 12.4158C1.55859 12.121 1.55935 11.8048 1.65332 11.5104C1.7601 11.1759 2.04233 10.8842 2.60679 10.3008L7.28782 5.46243Z" }),
499
+ /* @__PURE__ */ E("path", { d: "M10.052 9L16 15M15.948 9L10 15" })
500
+ ]
501
+ }
502
+ ), t = G() && b;
503
+ return d = T(P({
504
+ id: m,
505
+ children: y,
506
+ role: t ? "button" : void 0,
507
+ "aria-hidden": !t,
508
+ "aria-label": t ? `Remove ${g}` : b ? "Press Delete or Backspace to remove" : void 0
509
+ }, d), {
510
+ onClick: h,
511
+ render: b ? /* @__PURE__ */ E(_e.span, { render: d.render }) : d.render
512
+ }), d;
513
+ }
514
+ ), Rt = _(function(r) {
515
+ const o = pt(r);
516
+ return R(mt, o);
517
+ });
518
+ export {
519
+ Dt as C,
520
+ Kt as T,
521
+ _t as a,
522
+ wt as b,
523
+ Rt as c,
524
+ Ot as d,
525
+ It as e,
526
+ qe as f,
527
+ St as g,
528
+ ot as h,
529
+ st as i,
530
+ ut as j,
531
+ pt as k,
532
+ de as u
533
+ };
@@ -0,0 +1,68 @@
1
+ import { c as d, b as v } from "./4CMBR7SL-ChJnawVl.js";
2
+ import { b as T } from "./YV4JVR4I-w1-dnslS.js";
3
+ import { T as _, V as i, U as S, f as P, c as x, a as C, _ as L, l as h, o as u } from "./LMDWO4NN-CIZvvtic.js";
4
+ import { a as V, T as g } from "./A3WPL2ZJ-CpUtG5Sk.js";
5
+ import { u as j } from "./5JTVDSTH-DcfjjEya.js";
6
+ import { jsx as E } from "react/jsx-runtime";
7
+ function F(t = {}) {
8
+ var r;
9
+ const o = (r = t.store) == null ? void 0 : r.getState();
10
+ return d(_(S({}, t), {
11
+ orientation: i(
12
+ t.orientation,
13
+ o == null ? void 0 : o.orientation,
14
+ "horizontal"
15
+ ),
16
+ focusLoop: i(t.focusLoop, o == null ? void 0 : o.focusLoop, !0)
17
+ }));
18
+ }
19
+ function R(t, r, o) {
20
+ return v(t, r, o);
21
+ }
22
+ function k(t = {}) {
23
+ const [r, o] = T(F, t);
24
+ return R(r, o, t);
25
+ }
26
+ var w = "div", y = x(
27
+ function(r) {
28
+ var o = r, {
29
+ store: n,
30
+ orientation: l,
31
+ virtualFocus: c,
32
+ focusLoop: p,
33
+ rtl: f
34
+ } = o, e = L(o, [
35
+ "store",
36
+ "orientation",
37
+ "virtualFocus",
38
+ "focusLoop",
39
+ "rtl"
40
+ ]);
41
+ const m = V();
42
+ n = n || m;
43
+ const a = k({
44
+ store: n,
45
+ orientation: l,
46
+ virtualFocus: c,
47
+ focusLoop: p,
48
+ rtl: f
49
+ }), b = a.useState(
50
+ (s) => s.orientation === "both" ? void 0 : s.orientation
51
+ );
52
+ return e = h(
53
+ e,
54
+ (s) => /* @__PURE__ */ E(g, { value: a, children: s }),
55
+ [a]
56
+ ), e = u({
57
+ role: "toolbar",
58
+ "aria-orientation": b
59
+ }, e), e = j(u({ store: a }, e)), e;
60
+ }
61
+ ), q = P(function(r) {
62
+ const o = y(r);
63
+ return C(w, o);
64
+ });
65
+ export {
66
+ q as T,
67
+ k as u
68
+ };
@@ -0,0 +1,16 @@
1
+ import { u as p } from "./A3WPL2ZJ-CpUtG5Sk.js";
2
+ import { u as n } from "./TP7N7UIH-Dc0CLLi8.js";
3
+ import { f as u, c as m, a as c, _ as f, o as l } from "./LMDWO4NN-CIZvvtic.js";
4
+ var b = "hr", T = m(
5
+ function(o) {
6
+ var r = o, { store: a } = r, e = f(r, ["store"]);
7
+ const s = p();
8
+ return a = a || s, e = n(l({ store: a }, e)), e;
9
+ }
10
+ ), v = u(function(o) {
11
+ const r = T(o);
12
+ return c(b, r);
13
+ });
14
+ export {
15
+ v as T
16
+ };