@mittwald/flow-react-components 0.1.0-alpha.124 → 0.1.0-alpha.126

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 (33) hide show
  1. package/dist/{Action-7EQNT1az.js → Action-BLnSsHE1.js} +86 -70
  2. package/dist/Action.js +1 -1
  3. package/dist/CopyButton.js +1 -1
  4. package/dist/Header-uOS96l33.js +11 -0
  5. package/dist/Header.js +3 -8
  6. package/dist/Modal.js +3 -3
  7. package/dist/OffCanvas.js +22 -17
  8. package/dist/{Overlay-CUZ1KZa8.js → Overlay-BWA78Wvu.js} +1 -1
  9. package/dist/OverlayTrigger.js +2 -2
  10. package/dist/Table.js +40 -0
  11. package/dist/{context-CEG7VfKL.js → context-D3hdrTHO.js} +1 -1
  12. package/dist/controller.js +1 -1
  13. package/dist/hooks.js +10 -3
  14. package/dist/styles.css +1 -1
  15. package/dist/types/components/Action/lib/execution/ActionExecution.d.ts +2 -0
  16. package/dist/types/components/OffCanvas/stories/EdgeCases.stories.d.ts +7 -0
  17. package/dist/types/components/Table/Table.d.ts +7 -0
  18. package/dist/types/components/Table/components/TableBody/TableBody.d.ts +7 -0
  19. package/dist/types/components/Table/components/TableBody/index.d.ts +4 -0
  20. package/dist/types/components/Table/components/TableCell/TableCell.d.ts +7 -0
  21. package/dist/types/components/Table/components/TableCell/index.d.ts +4 -0
  22. package/dist/types/components/Table/components/TableColumn/TableColumn.d.ts +7 -0
  23. package/dist/types/components/Table/components/TableColumn/index.d.ts +4 -0
  24. package/dist/types/components/Table/components/TableHeader/TableHeader.d.ts +7 -0
  25. package/dist/types/components/Table/components/TableHeader/index.d.ts +4 -0
  26. package/dist/types/components/Table/components/TableRow/TableRow.d.ts +7 -0
  27. package/dist/types/components/Table/components/TableRow/index.d.ts +4 -0
  28. package/dist/types/components/Table/index.d.ts +9 -0
  29. package/dist/types/components/Table/stories/Default.stories.d.ts +7 -0
  30. package/dist/types/lib/hooks/index.d.ts +1 -0
  31. package/dist/types/lib/hooks/useOnChange.d.ts +3 -0
  32. package/dist/{index-BlZLqtIV.js → useOverlayController-CGKumeGL.js} +7 -7
  33. package/package.json +34 -30
@@ -1,23 +1,23 @@
1
1
  "use client"
2
2
  /* */
3
- var N = Object.defineProperty;
4
- var R = (t, e, n) => e in t ? N(t, e, { enumerable: !0, configurable: !0, writable: !0, value: n }) : t[e] = n;
5
- var l = (t, e, n) => (R(t, typeof e != "symbol" ? e + "" : e, n), n);
6
- import r, { useEffect as T } from "react";
7
- import { u as m, a as W, A as G } from "./context-CEG7VfKL.js";
3
+ var $ = Object.defineProperty;
4
+ var N = (t, e, n) => e in t ? $(t, e, { enumerable: !0, configurable: !0, writable: !0, value: n }) : t[e] = n;
5
+ var l = (t, e, n) => (N(t, typeof e != "symbol" ? e + "" : e, n), n);
6
+ import r, { useEffect as W } from "react";
7
+ import { u as h, a as G, A as L } from "./context-D3hdrTHO.js";
8
8
  import "./propsContext-CauylOgH.js";
9
- import { P as v } from "./PropsContextProvider-ChpH8eF2.js";
9
+ import { P as M } from "./PropsContextProvider-ChpH8eF2.js";
10
10
  import "@react-aria/utils";
11
11
  import "remeda";
12
- import { W as L } from "./Wrap-DGT1h1o3.js";
13
- const d = () => {
14
- }, U = (t, e = {}) => {
12
+ import { W as U } from "./Wrap-DGT1h1o3.js";
13
+ const u = () => {
14
+ }, j = (t, e = {}) => {
15
15
  const {
16
- onSync: n = d,
17
- onAsync: o = d,
18
- then: s = d,
19
- catch: i = d,
20
- finally: c = d
16
+ onSync: n = u,
17
+ onAsync: o = u,
18
+ then: s = u,
19
+ catch: i = u,
20
+ finally: c = u
21
21
  } = e;
22
22
  try {
23
23
  const a = t();
@@ -25,12 +25,12 @@ const d = () => {
25
25
  } catch (a) {
26
26
  n(), i(a), c();
27
27
  }
28
- }, P = (t) => new Promise((e) => setTimeout(e, t)), b = {
28
+ }, P = (t) => new Promise((e) => setTimeout(e, t)), x = {
29
29
  pending: 1e3,
30
30
  succeeded: 1500,
31
31
  failed: 2e3
32
32
  };
33
- class j {
33
+ class q {
34
34
  constructor(e, n, o = {}) {
35
35
  l(this, "options");
36
36
  l(this, "state");
@@ -41,12 +41,18 @@ class j {
41
41
  resetAfterDone: s = !0,
42
42
  onFeedbackDone: i = () => {
43
43
  },
44
- showFeedback: c = !1
44
+ showFeedback: c = !1,
45
+ resetDelayMs: a = 0
45
46
  } = o;
46
- this.state = e, this.args = n, this.options = { resetAfterDone: s, onFeedbackDone: i, showFeedback: c };
47
+ this.state = e, this.args = n, this.options = {
48
+ resetAfterDone: s,
49
+ onFeedbackDone: i,
50
+ showFeedback: c,
51
+ resetDelayMs: a
52
+ };
47
53
  }
48
54
  onAsyncStart() {
49
- this.options.showFeedback = !0, this.state.updateState("isExecuting"), setTimeout(() => this.startPending(), b.pending);
55
+ this.options.showFeedback = !0, this.state.updateState("isExecuting"), setTimeout(() => this.startPending(), x.pending);
50
56
  }
51
57
  onSucceeded() {
52
58
  return this.onDone();
@@ -54,14 +60,19 @@ class j {
54
60
  async onFailed(e) {
55
61
  this.error = e ?? new Error("Unknown error"), console.error(e), await this.onDone();
56
62
  }
63
+ setResetDelay(e) {
64
+ this.options.resetDelayMs = e;
65
+ }
57
66
  async startFailedFeedback() {
58
- this.state.updateState("isFailed"), await P(b.failed), this.resetAfterDone();
67
+ this.state.updateState("isFailed"), await P(x.failed), this.resetAfterDone();
59
68
  }
60
69
  async startSucceededFeedback() {
61
- this.state.updateState("isSucceeded"), await P(b.succeeded), this.resetAfterDone();
70
+ this.state.updateState("isSucceeded"), await P(x.succeeded), this.resetAfterDone();
62
71
  }
63
72
  resetAfterDone() {
64
- this.options.resetAfterDone && this.state.updateState("isIdle"), this.error || this.options.onFeedbackDone(...this.args);
73
+ setTimeout(() => {
74
+ this.options.resetAfterDone && this.state.updateState("isIdle"), this.error || this.options.onFeedbackDone(...this.args);
75
+ }, this.options.resetDelayMs);
65
76
  }
66
77
  async onDone() {
67
78
  this.isDone = !0, this.options.showFeedback ? this.error ? await this.startFailedFeedback() : await this.startSucceededFeedback() : this.resetAfterDone();
@@ -70,20 +81,20 @@ class j {
70
81
  this.isDone || this.state.updateState("isPending");
71
82
  }
72
83
  }
73
- const M = (t) => (...e) => {
84
+ const v = (t) => (...e) => {
74
85
  const n = [...t], o = n.shift();
75
86
  if (o) {
76
- const s = o(...e), i = () => n.length === 0 ? s : M(n)(...e);
87
+ const s = o(...e), i = () => n.length === 0 ? s : v(n)(...e);
77
88
  return s instanceof Promise ? s.then(i) : i();
78
89
  }
79
- }, q = () => {
80
- }, y = () => {
90
+ }, z = () => {
91
+ }, b = () => {
81
92
  var n;
82
- const t = m(), e = t.actionProps.confirm || t.actionProps.abort ? ((n = t.parentContext) == null ? void 0 : n.state) ?? t.state : t.state;
93
+ const t = h(), e = t.actionProps.confirm || t.actionProps.abort ? ((n = t.parentContext) == null ? void 0 : n.state) ?? t.state : t.state;
83
94
  return {
84
95
  state: e,
85
96
  execute: async (...o) => {
86
- var E;
97
+ var D;
87
98
  const {
88
99
  actionProps: s,
89
100
  confirmationModalController: i,
@@ -91,50 +102,55 @@ const M = (t) => (...e) => {
91
102
  parentContext: a
92
103
  } = t;
93
104
  if (s.abort) {
94
- (E = a == null ? void 0 : a.confirmationModalController) == null || E.close();
105
+ (D = a == null ? void 0 : a.confirmationModalController) == null || D.close();
95
106
  return;
96
107
  }
97
108
  if (c && !i.isOpen) {
98
109
  i.open();
99
110
  return;
100
111
  }
101
- const h = new j(e, o, s), A = [];
102
- let u, p, f = t;
103
- for (; f; ) {
112
+ const f = new q(e, o, s), A = [];
113
+ let d, p, m = t;
114
+ for (; m; ) {
104
115
  const {
105
116
  actionProps: C,
106
- overlayController: O,
107
- confirmationModalController: S,
108
- needsConfirmation: B
109
- } = f, {
110
- action: g,
111
- toggleOverlay: F,
112
- openOverlay: D,
113
- closeOverlay: k,
114
- break: $
117
+ overlayController: B,
118
+ confirmationModalController: E,
119
+ needsConfirmation: R
120
+ } = m, {
121
+ action: S,
122
+ toggleOverlay: g,
123
+ openOverlay: F,
124
+ closeOverlay: w,
125
+ break: T
115
126
  } = C;
116
- if ($)
127
+ if (T)
117
128
  break;
118
- if (B)
119
- if (u) {
120
- p = S;
129
+ if (R)
130
+ if (d) {
131
+ p = E;
121
132
  break;
122
133
  } else
123
- u = S;
124
- const x = (w) => typeof w == "boolean" ? O : w;
134
+ d = E;
135
+ const y = (k) => typeof k == "boolean" ? B : k;
125
136
  A.push(
126
- g || (F ? x(F).toggle : D ? x(D).open : k ? x(k).close : q)
127
- ), f = f.parentContext;
137
+ S || (g ? y(g).toggle : F ? y(F).open : w ? y(w).close : z)
138
+ ), m = m.parentContext;
128
139
  }
129
- await U(() => M(A)(o), {
130
- onAsync: () => h.onAsyncStart(),
131
- then: () => h.onSucceeded(),
132
- catch: (C) => h.onFailed(C)
133
- }), p && p.open(), u && u.close();
140
+ const O = v(A);
141
+ f.setResetDelay(
142
+ d ? 500 : 0
143
+ ), await j(() => O(o), {
144
+ onAsync: () => f.onAsyncStart(),
145
+ then: async () => {
146
+ await f.onSucceeded(), p && p.open(), d && d.close();
147
+ },
148
+ catch: (C) => f.onFailed(C)
149
+ });
134
150
  }
135
151
  };
136
152
  }, I = (t, e) => {
137
- const { actionProps: n, needsConfirmation: o } = m(), s = y(), i = s.state.useState();
153
+ const { actionProps: n, needsConfirmation: o } = h(), s = b(), i = s.state.useState();
138
154
  return o ? /* @__PURE__ */ r.createElement(t, { ...e, onPress: s.execute }) : n.abort ? /* @__PURE__ */ r.createElement(
139
155
  t,
140
156
  {
@@ -153,8 +169,8 @@ const M = (t) => (...e) => {
153
169
  isFailed: i === "isFailed"
154
170
  }
155
171
  );
156
- }, z = (t, e) => {
157
- const { needsConfirmation: n } = m(), o = y(), s = o.state.useState();
172
+ }, H = (t, e) => {
173
+ const { needsConfirmation: n } = h(), o = b(), s = o.state.useState();
158
174
  return n ? /* @__PURE__ */ r.createElement(t, { ...e, onPress: o.execute }) : /* @__PURE__ */ r.createElement(
159
175
  t,
160
176
  {
@@ -163,17 +179,17 @@ const M = (t) => (...e) => {
163
179
  "aria-disabled": s !== "isIdle"
164
180
  }
165
181
  );
166
- }, H = (t, e) => {
182
+ }, J = (t, e) => {
167
183
  const n = e.color === "secondary", o = e.color === "primary" || e.color === "danger" || e.color === "accent";
168
184
  if (!o && !n)
169
185
  return /* @__PURE__ */ r.createElement(t, { ...e });
170
186
  const s = { Button: { render: I } };
171
- return /* @__PURE__ */ r.createElement(v, { props: s }, /* @__PURE__ */ r.createElement(K, { abort: n, confirm: o }, /* @__PURE__ */ r.createElement(t, { ...e })));
172
- }, J = (t, e) => {
187
+ return /* @__PURE__ */ r.createElement(M, { props: s }, /* @__PURE__ */ r.createElement(Q, { abort: n, confirm: o }, /* @__PURE__ */ r.createElement(t, { ...e })));
188
+ }, K = (t, e) => {
173
189
  if (e.slot !== "actionConfirm")
174
190
  return /* @__PURE__ */ r.createElement(t, { ...e });
175
- const n = m(), o = y().state.useState();
176
- T(() => (n.needsConfirmation = !0, () => {
191
+ const n = h(), o = b().state.useState();
192
+ W(() => (n.needsConfirmation = !0, () => {
177
193
  n.needsConfirmation = !1;
178
194
  }), [n]);
179
195
  const s = o === "isIdle" ? e.isDismissable : !1;
@@ -185,13 +201,13 @@ const M = (t) => (...e) => {
185
201
  isDismissable: s
186
202
  }
187
203
  );
188
- }, K = (t) => {
189
- const { children: e, ...n } = t, o = W(n), s = !!o.parentContext && !!o.parentContext.parentContext, i = {
204
+ }, Q = (t) => {
205
+ const { children: e, ...n } = t, o = G(n), s = !!o.parentContext && !!o.parentContext.parentContext, i = {
190
206
  Modal: {
191
- render: J,
207
+ render: K,
192
208
  ButtonGroup: {
193
209
  Button: {
194
- render: H
210
+ render: J
195
211
  }
196
212
  }
197
213
  },
@@ -199,11 +215,11 @@ const M = (t) => (...e) => {
199
215
  render: I
200
216
  },
201
217
  Link: {
202
- render: z
218
+ render: H
203
219
  }
204
220
  };
205
- return /* @__PURE__ */ r.createElement(G, { value: o }, /* @__PURE__ */ r.createElement(L, { if: !s }, /* @__PURE__ */ r.createElement(
206
- v,
221
+ return /* @__PURE__ */ r.createElement(L, { value: o }, /* @__PURE__ */ r.createElement(U, { if: !s }, /* @__PURE__ */ r.createElement(
222
+ M,
207
223
  {
208
224
  props: i,
209
225
  dependencies: [o],
@@ -213,5 +229,5 @@ const M = (t) => (...e) => {
213
229
  )));
214
230
  };
215
231
  export {
216
- K as A
232
+ Q as A
217
233
  };
package/dist/Action.js CHANGED
@@ -1,6 +1,6 @@
1
1
  "use client"
2
2
  /* */
3
- import { A as t } from "./Action-7EQNT1az.js";
3
+ import { A as t } from "./Action-BLnSsHE1.js";
4
4
  export {
5
5
  t as Action,
6
6
  t as default
@@ -15,7 +15,7 @@ import "@react-aria/utils";
15
15
  import "remeda";
16
16
  import "dot-prop";
17
17
  import { f as C } from "./flowComponent-Cv_SURLH.js";
18
- import { A as E } from "./Action-7EQNT1az.js";
18
+ import { A as E } from "./Action-BLnSsHE1.js";
19
19
  const B = {
20
20
  "de-DE": {
21
21
  "copyButton.copy": "Kopieren"
@@ -0,0 +1,11 @@
1
+ "use client"
2
+ /* */
3
+ import a from "react";
4
+ import { f as c } from "./flowComponent-Cv_SURLH.js";
5
+ const s = c("Header", (e) => {
6
+ const { children: r, refProp: t, elementType: o = "header", ...n } = e, m = o;
7
+ return /* @__PURE__ */ a.createElement(m, { ...n, ref: t }, r);
8
+ });
9
+ export {
10
+ s as H
11
+ };
package/dist/Header.js CHANGED
@@ -1,12 +1,7 @@
1
1
  "use client"
2
2
  /* */
3
- import m from "react";
4
- import { f } from "./flowComponent-Cv_SURLH.js";
5
- const p = f("Header", (e) => {
6
- const { children: r, refProp: t, elementType: o = "header", ...n } = e, a = o;
7
- return /* @__PURE__ */ m.createElement(a, { ...n, ref: t }, r);
8
- });
3
+ import { H as e } from "./Header-uOS96l33.js";
9
4
  export {
10
- p as Header,
11
- p as default
5
+ e as Header,
6
+ e as default
12
7
  };
package/dist/Modal.js CHANGED
@@ -8,10 +8,10 @@ import "@react-aria/utils";
8
8
  import "remeda";
9
9
  import { TunnelProvider as p, TunnelExit as c } from "@mittwald/react-tunnel";
10
10
  import { f as u } from "./flowComponent-Cv_SURLH.js";
11
- import { O as w } from "./Overlay-CUZ1KZa8.js";
11
+ import { O as w } from "./Overlay-BWA78Wvu.js";
12
12
  import "mobx";
13
- import "./index-BlZLqtIV.js";
14
- import "./context-CEG7VfKL.js";
13
+ import "./useOverlayController-CGKumeGL.js";
14
+ import "./context-D3hdrTHO.js";
15
15
  const v = "flow--modal", z = "flow--modal--button-group", C = "flow--modal--content", b = "flow--modal--off-canvas", t = {
16
16
  modal: v,
17
17
  "modal-zoom": "flow--modal--modal-zoom",
package/dist/OffCanvas.js CHANGED
@@ -1,42 +1,47 @@
1
1
  "use client"
2
2
  /* */
3
- import o from "react";
3
+ import e from "react";
4
4
  import c from "clsx";
5
5
  import { B as f } from "./Button-tEtjVHFC.js";
6
6
  import "@tabler/icons-react";
7
7
  import "./Icon-DXq5lwp4.js";
8
8
  import { I as m } from "./IconClose-BuJDcvk1.js";
9
- import { A as i } from "./Action-7EQNT1az.js";
10
- import { O as p } from "./Overlay-CUZ1KZa8.js";
9
+ import { A as i } from "./Action-BLnSsHE1.js";
10
+ import { O as p } from "./Overlay-BWA78Wvu.js";
11
11
  import "mobx";
12
- import "./index-BlZLqtIV.js";
12
+ import "./useOverlayController-CGKumeGL.js";
13
13
  import "./propsContext-CauylOgH.js";
14
14
  import { P as v } from "./PropsContextProvider-ChpH8eF2.js";
15
15
  import "@react-aria/utils";
16
16
  import "remeda";
17
- const u = "flow--off-canvas", d = "flow--off-canvas--close-button", t = {
18
- offCanvas: u,
17
+ import { TunnelProvider as d, TunnelExit as u } from "@mittwald/react-tunnel";
18
+ import { H as E } from "./Header-uOS96l33.js";
19
+ const C = "flow--off-canvas", h = "flow--off-canvas--header", w = "flow--off-canvas--close-button", o = {
20
+ offCanvas: C,
19
21
  "off-canvas-slide-in": "flow--off-canvas--off-canvas-slide-in",
20
22
  "off-canvas-slide-out": "flow--off-canvas--off-canvas-slide-out",
21
- closeButton: d
22
- }, z = (s) => {
23
- const { controller: a, children: e, className: r } = s, n = c(t.offCanvas, r), l = {
23
+ header: h,
24
+ closeButton: w
25
+ }, q = (t) => {
26
+ const { controller: a, children: r, className: n } = t, s = c(o.offCanvas, n), l = {
24
27
  Heading: {
25
- slot: "title"
28
+ slot: "title",
29
+ tunnelId: "heading",
30
+ levelVisual: 4,
31
+ level: 2
26
32
  }
27
33
  };
28
- return /* @__PURE__ */ o.createElement(p, { controller: a, className: n }, /* @__PURE__ */ o.createElement(i, { closeOverlay: !0 }, /* @__PURE__ */ o.createElement(
34
+ return /* @__PURE__ */ e.createElement(p, { controller: a, className: s }, /* @__PURE__ */ e.createElement(v, { props: l }, /* @__PURE__ */ e.createElement(d, null, /* @__PURE__ */ e.createElement(E, { className: o.header }, /* @__PURE__ */ e.createElement(u, { id: "heading" }), /* @__PURE__ */ e.createElement(i, { closeOverlay: !0 }, /* @__PURE__ */ e.createElement(
29
35
  f,
30
36
  {
31
37
  variant: "plain",
32
- size: "s",
33
38
  color: "secondary",
34
- className: t.closeButton
39
+ className: o.closeButton
35
40
  },
36
- /* @__PURE__ */ o.createElement(m, null)
37
- )), /* @__PURE__ */ o.createElement(v, { props: l }, e));
41
+ /* @__PURE__ */ e.createElement(m, null)
42
+ ))), r)));
38
43
  };
39
44
  export {
40
- z as OffCanvas,
41
- z as default
45
+ q as OffCanvas,
46
+ q as default
42
47
  };
@@ -3,7 +3,7 @@
3
3
  import * as r from "react-aria-components";
4
4
  import e from "react";
5
5
  import y from "clsx";
6
- import { u as p, a as u } from "./index-BlZLqtIV.js";
6
+ import { u as p, a as u } from "./useOverlayController-CGKumeGL.js";
7
7
  import "mobx";
8
8
  const O = "flow--overlay", f = {
9
9
  overlay: O,
@@ -2,8 +2,8 @@
2
2
  /* */
3
3
  import r from "react";
4
4
  import "mobx";
5
- import { u as l, a as m } from "./index-BlZLqtIV.js";
6
- import { A as p } from "./Action-7EQNT1az.js";
5
+ import { u as l, a as m } from "./useOverlayController-CGKumeGL.js";
6
+ import { A as p } from "./Action-BLnSsHE1.js";
7
7
  import "./propsContext-CauylOgH.js";
8
8
  import { P as i } from "./PropsContextProvider-ChpH8eF2.js";
9
9
  import "@react-aria/utils";
package/dist/Table.js ADDED
@@ -0,0 +1,40 @@
1
+ "use client"
2
+ /* */
3
+ import o from "react";
4
+ import * as n from "react-aria-components";
5
+ import r from "clsx";
6
+ const m = "flow--table--table-container", b = "flow--table", d = "flow--table--header", N = "flow--table--body", i = "flow--table--cell", u = "flow--table--column", c = {
7
+ tableContainer: m,
8
+ table: b,
9
+ header: d,
10
+ body: N,
11
+ cell: i,
12
+ column: u
13
+ }, h = (e) => {
14
+ const { children: a, className: t, ...l } = e, s = r(c.table, t);
15
+ return /* @__PURE__ */ o.createElement("div", { className: c.tableContainer }, /* @__PURE__ */ o.createElement(n.Table, { className: s, ...l }, a));
16
+ }, w = (e) => {
17
+ const { children: a, className: t, ...l } = e, s = r(c.body, t);
18
+ return /* @__PURE__ */ o.createElement(n.TableBody, { className: s, ...l }, a);
19
+ }, T = (e) => {
20
+ const { children: a, className: t, ...l } = e, s = r(c.cell, t);
21
+ return /* @__PURE__ */ o.createElement(n.Cell, { className: s, ...l }, a);
22
+ }, y = (e) => {
23
+ const { children: a, className: t, ...l } = e, s = r(c.column, t);
24
+ return /* @__PURE__ */ o.createElement(n.Column, { isRowHeader: !0, className: s, ...l }, a);
25
+ }, E = (e) => {
26
+ const { children: a, className: t, ...l } = e, s = r(c.header, t);
27
+ return /* @__PURE__ */ o.createElement(n.TableHeader, { className: s, ...l }, a);
28
+ }, p = (e) => {
29
+ const { children: a, className: t, ...l } = e, s = r(c.row, t);
30
+ return /* @__PURE__ */ o.createElement(n.Row, { className: s, ...l }, a);
31
+ };
32
+ export {
33
+ h as Table,
34
+ w as TableBody,
35
+ T as TableCell,
36
+ y as TableColumn,
37
+ E as TableHeader,
38
+ p as TableRow,
39
+ h as default
40
+ };
@@ -4,7 +4,7 @@ var u = Object.defineProperty;
4
4
  var m = (e, t, o) => t in e ? u(e, t, { enumerable: !0, configurable: !0, writable: !0, value: o }) : e[t] = o;
5
5
  var a = (e, t, o) => (m(e, typeof t != "symbol" ? t + "" : t, o), o);
6
6
  import { useRef as C, createContext as f, useMemo as d, useContext as p } from "react";
7
- import { O as i, u as l } from "./index-BlZLqtIV.js";
7
+ import { O as i, u as l } from "./useOverlayController-CGKumeGL.js";
8
8
  import { makeObservable as v, observable as x, action as w } from "mobx";
9
9
  import { u as b } from "./useSelector-DpU7_HMO.js";
10
10
  class r {
@@ -1,6 +1,6 @@
1
1
  "use client"
2
2
  /* */
3
- import { O as l, u as o } from "./index-BlZLqtIV.js";
3
+ import { O as l, u as o } from "./useOverlayController-CGKumeGL.js";
4
4
  export {
5
5
  l as OverlayController,
6
6
  o as useOverlayController
package/dist/hooks.js CHANGED
@@ -1,8 +1,15 @@
1
1
  "use client"
2
2
  /* */
3
3
  import "mobx";
4
- import "react";
5
- import { u as l } from "./index-BlZLqtIV.js";
4
+ import { useRef as n, useEffect as s } from "react";
5
+ import { u as i } from "./useOverlayController-CGKumeGL.js";
6
+ const m = (r, e, t = []) => {
7
+ const o = n(r);
8
+ s(() => {
9
+ o.current !== r && e(), o.current = r;
10
+ }, [r, e, ...t]);
11
+ };
6
12
  export {
7
- l as useOverlayController
13
+ m as useOnChange,
14
+ i as useOverlayController
8
15
  };