@mittwald/flow-react-components 0.1.0-alpha.345 → 0.1.0-alpha.346

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.
package/CHANGELOG.md CHANGED
@@ -3,6 +3,18 @@
3
3
  All notable changes to this project will be documented in this file. See
4
4
  [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ # [0.1.0-alpha.346](https://github.com/mittwald/flow/compare/0.1.0-alpha.345...0.1.0-alpha.346) (2024-11-14)
7
+
8
+ ### Bug Fixes
9
+
10
+ - **OverlayController:** fix overlayController handler management
11
+ ([cfd55bf](https://github.com/mittwald/flow/commit/cfd55bf9075a445f2bd6c48d36a0274d0bc32f2f))
12
+
13
+ # Change Log
14
+
15
+ All notable changes to this project will be documented in this file. See
16
+ [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
17
+
6
18
  # [0.1.0-alpha.345](https://github.com/mittwald/flow/compare/0.1.0-alpha.344...0.1.0-alpha.345) (2024-11-14)
7
19
 
8
20
  **Note:** Version bump only for package @mittwald/flow-react-components
@@ -4,7 +4,7 @@ var k = Object.defineProperty;
4
4
  var M = (n, t, e) => t in n ? k(n, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : n[t] = e;
5
5
  var r = (n, t, e) => M(n, typeof t != "symbol" ? t + "" : t, e);
6
6
  import g, { createContext as O, useRef as I, useContext as w } from "react";
7
- import { u as E, O as D } from "./context-Cf7tqFtF.js";
7
+ import { u as E, O as D } from "./context-BaYmTa0I.js";
8
8
  import T from "invariant";
9
9
  import { makeObservable as N, observable as R, action as V, computed as $ } from "mobx";
10
10
  import { u as b } from "./useSelector-DpU7_HMO.js";
package/dist/js/Action.js CHANGED
@@ -1,6 +1,6 @@
1
1
  "use client"
2
2
  /* */
3
- import { A as t } from "./Action-DsQVttvF.js";
3
+ import { A as t } from "./Action-isbDYaAK.js";
4
4
  export {
5
5
  t as Action,
6
6
  t as default
@@ -3,7 +3,7 @@
3
3
  import t from "react";
4
4
  import d from "react-syntax-highlighter";
5
5
  import m from "clsx";
6
- import { C as f } from "./CopyButton-e2EjDU95.js";
6
+ import { C as f } from "./CopyButton-D6eXnqw1.js";
7
7
  const i = "flow--code-block", k = "flow--code-block--copy-button", u = "flow--code-block--light", p = "flow--code-block--dark", e = {
8
8
  codeBlock: i,
9
9
  copyButton: k,
@@ -1,7 +1,7 @@
1
1
  "use client"
2
2
  /* */
3
- import { C as t } from "./ContextMenuTrigger-BbYyy0an.js";
4
- import { a } from "./ContextMenuTrigger-BbYyy0an.js";
3
+ import { C as t } from "./ContextMenuTrigger-C_0tJ4zR.js";
4
+ import { a } from "./ContextMenuTrigger-C_0tJ4zR.js";
5
5
  import { M as n } from "./MenuItem-GX6Zh70q.js";
6
6
  export {
7
7
  t as ContextMenu,
@@ -4,16 +4,16 @@ import e from "react";
4
4
  import * as i from "react-aria-components";
5
5
  import { s } from "./ContextMenu.module-BZingr2B.js";
6
6
  import { f as c } from "./flowComponent-1wOIvUIq.js";
7
- import { P } from "./Popover-BoLYvpo2.js";
7
+ import { P } from "./Popover-D-DgHnsV.js";
8
8
  import { C as E } from "./ClearPropsContext-CUvsbMn8.js";
9
9
  import { PropsContextProvider as O } from "./PropsContextProvider.js";
10
10
  import "@react-aria/utils";
11
11
  import "./propsContext-DzAKlmhS.js";
12
12
  import "remeda";
13
13
  import "mobx";
14
- import { u as T } from "./useOverlayController-D8pgx8nV.js";
15
- import { O as S, a as A } from "./OverlayTrigger-BmB63e4e.js";
16
- import { A as h } from "./Action-DsQVttvF.js";
14
+ import { u as T } from "./useOverlayController-BwSJj4Ly.js";
15
+ import { O as S, a as A } from "./OverlayTrigger-j2zD8W4S.js";
16
+ import { A as h } from "./Action-isbDYaAK.js";
17
17
  const B = c("ContextMenu", (t) => {
18
18
  const {
19
19
  children: r,
@@ -1,16 +1,16 @@
1
1
  "use client"
2
2
  /* */
3
3
  import t from "react";
4
- import { P as c } from "./Popover-BoLYvpo2.js";
4
+ import { P as c } from "./Popover-D-DgHnsV.js";
5
5
  import "./propsContext-DzAKlmhS.js";
6
6
  import { PropsContextProvider as l } from "./PropsContextProvider.js";
7
7
  import "@react-aria/utils";
8
8
  import "remeda";
9
9
  import { f as a } from "./flowComponent-1wOIvUIq.js";
10
10
  import "mobx";
11
- import { u } from "./useOverlayController-D8pgx8nV.js";
11
+ import { u } from "./useOverlayController-BwSJj4Ly.js";
12
12
  import * as f from "react-aria-components";
13
- import { a as x } from "./OverlayTrigger-BmB63e4e.js";
13
+ import { a as x } from "./OverlayTrigger-j2zD8W4S.js";
14
14
  import { useLocalizedStringFormatter as g } from "react-aria";
15
15
  import "@tabler/icons-react";
16
16
  import "./Icon-DGqvukLZ.js";
@@ -15,7 +15,7 @@ import "@react-aria/utils";
15
15
  import "remeda";
16
16
  import "dot-prop";
17
17
  import { f as E } from "./flowComponent-1wOIvUIq.js";
18
- import { A as B } from "./Action-DsQVttvF.js";
18
+ import { A as B } from "./Action-isbDYaAK.js";
19
19
  const g = { "de-DE": {
20
20
  "copyButton.copy": "Kopieren"
21
21
  }, "en-EN": {
@@ -1,6 +1,6 @@
1
1
  "use client"
2
2
  /* */
3
- import { C as t } from "./CopyButton-e2EjDU95.js";
3
+ import { C as t } from "./CopyButton-D6eXnqw1.js";
4
4
  export {
5
5
  t as CopyButton,
6
6
  t as default
@@ -13,9 +13,9 @@ import "./Icon-DGqvukLZ.js";
13
13
  import { a as C } from "./IconCalendar-BjcM88rZ.js";
14
14
  import { F as D } from "./FieldError-BvH18haz.js";
15
15
  import { f as a } from "./FormField.module-CqWpTQKP.js";
16
- import { P as N } from "./Popover-BoLYvpo2.js";
16
+ import { P as N } from "./Popover-D-DgHnsV.js";
17
17
  import "mobx";
18
- import { u as P } from "./useOverlayController-D8pgx8nV.js";
18
+ import { u as P } from "./useOverlayController-BwSJj4Ly.js";
19
19
  import { f as y } from "./flowComponent-1wOIvUIq.js";
20
20
  import { s as F, C as b } from "./CalendarHeader-CdTPgq-8.js";
21
21
  const g = "flow--date-picker--date-input", v = {
@@ -8,7 +8,7 @@ import { PropsContextProvider as f } from "./PropsContextProvider.js";
8
8
  import "@react-aria/utils";
9
9
  import "remeda";
10
10
  import * as t from "react-aria-components";
11
- import { P as g } from "./Popover-BoLYvpo2.js";
11
+ import { P as g } from "./Popover-D-DgHnsV.js";
12
12
  import { s as i, C } from "./CalendarHeader-CdTPgq-8.js";
13
13
  import { B as D } from "./Button-tKo9ydZL.js";
14
14
  import "@tabler/icons-react";
@@ -16,7 +16,7 @@ import "./Icon-DGqvukLZ.js";
16
16
  import { a as R } from "./IconCalendar-BjcM88rZ.js";
17
17
  import { F as N } from "./FieldError-BvH18haz.js";
18
18
  import "mobx";
19
- import { u as P } from "./useOverlayController-D8pgx8nV.js";
19
+ import { u as P } from "./useOverlayController-BwSJj4Ly.js";
20
20
  import { f as v } from "./flowComponent-1wOIvUIq.js";
21
21
  const F = () => /* @__PURE__ */ e.createElement(t.RangeCalendar, { className: c(i.calendar, i.range) }, /* @__PURE__ */ e.createElement(C, null), /* @__PURE__ */ e.createElement(t.CalendarGrid, null, (r) => /* @__PURE__ */ e.createElement(t.CalendarCell, { date: r }))), I = "flow--date-range-picker--date-range-input", b = {
22
22
  dateRangeInput: I
package/dist/js/List.js CHANGED
@@ -13,7 +13,7 @@ import { B as y } from "./Button-tKo9ydZL.js";
13
13
  import { IconArrowBackUp as rt } from "@tabler/icons-react";
14
14
  import { I as ue } from "./Icon-DGqvukLZ.js";
15
15
  import { I as ot } from "./IconContextMenu-CZgbKH5A.js";
16
- import { a as $, C as Y } from "./ContextMenuTrigger-BbYyy0an.js";
16
+ import { a as $, C as Y } from "./ContextMenuTrigger-C_0tJ4zR.js";
17
17
  import { M as _ } from "./MenuItem-GX6Zh70q.js";
18
18
  import { useLocalizedStringFormatter as w } from "react-aria";
19
19
  import { TunnelProvider as ye, TunnelExit as x } from "@mittwald/react-tunnel";
@@ -27,7 +27,7 @@ import { observer as pt } from "mobx-react-lite";
27
27
  import { a as H, T as q } from "./Tooltip-DmYZavnZ.js";
28
28
  import { B as ft } from "./Badge-C3CBqh8m.js";
29
29
  import { makeObservable as St, observable as me, computed as he, action as G } from "mobx";
30
- import "./context-Cf7tqFtF.js";
30
+ import "./context-BaYmTa0I.js";
31
31
  import { u as bt } from "./useOnChange-C1Quwyuz.js";
32
32
  import { S as vt } from "./SearchField-62cVb6e-.js";
33
33
  import { H as Q } from "./Heading-Be_nT-nd.js";
package/dist/js/Modal.js CHANGED
@@ -10,10 +10,10 @@ import { TunnelProvider as g, TunnelExit as y } from "@mittwald/react-tunnel";
10
10
  import { f as C } from "./flowComponent-1wOIvUIq.js";
11
11
  import * as n from "react-aria-components";
12
12
  import "mobx";
13
- import { u as w } from "./useOverlayController-D8pgx8nV.js";
14
- import { O as E, a as h } from "./OverlayTrigger-BmB63e4e.js";
13
+ import { u as w } from "./useOverlayController-BwSJj4Ly.js";
14
+ import { O as E, a as h } from "./OverlayTrigger-j2zD8W4S.js";
15
15
  import { H as O } from "./Header-lMGDqbwd.js";
16
- import { A as M } from "./Action-DsQVttvF.js";
16
+ import { A as M } from "./Action-isbDYaAK.js";
17
17
  import { B as N } from "./Button-tKo9ydZL.js";
18
18
  import "@tabler/icons-react";
19
19
  import "./Icon-DGqvukLZ.js";
@@ -1,7 +1,7 @@
1
1
  "use client"
2
2
  /* */
3
3
  import e from "react";
4
- import { u as m, o as v, O as y } from "./context-Cf7tqFtF.js";
4
+ import { u as m, o as v, O as y } from "./context-BaYmTa0I.js";
5
5
  import "./propsContext-DzAKlmhS.js";
6
6
  import { PropsContextProvider as O } from "./PropsContextProvider.js";
7
7
  import "@react-aria/utils";
@@ -2,11 +2,11 @@
2
2
  /* */
3
3
  import * as o from "react-aria-components";
4
4
  import e from "react";
5
- import { a as y, O as E } from "./OverlayTrigger-BmB63e4e.js";
5
+ import { a as y, O as E } from "./OverlayTrigger-j2zD8W4S.js";
6
6
  import { f as a } from "./flowComponent-1wOIvUIq.js";
7
7
  import l from "clsx";
8
8
  import "mobx";
9
- import { u as x } from "./useOverlayController-D8pgx8nV.js";
9
+ import { u as x } from "./useOverlayController-BwSJj4Ly.js";
10
10
  const R = a("PopoverTrigger", (r) => {
11
11
  const { children: t, ...n } = r;
12
12
  return /* @__PURE__ */ e.createElement(
@@ -1,7 +1,7 @@
1
1
  "use client"
2
2
  /* */
3
- import { P as r } from "./Popover-BoLYvpo2.js";
4
- import { a as p } from "./Popover-BoLYvpo2.js";
3
+ import { P as r } from "./Popover-D-DgHnsV.js";
4
+ import { a as p } from "./Popover-D-DgHnsV.js";
5
5
  export {
6
6
  r as Popover,
7
7
  p as PopoverTrigger,
package/dist/js/Select.js CHANGED
@@ -13,11 +13,11 @@ import "@tabler/icons-react";
13
13
  import "./Icon-DGqvukLZ.js";
14
14
  import { I as F } from "./IconChevronDown-BtCeHe7W.js";
15
15
  import { f as E } from "./flowComponent-1wOIvUIq.js";
16
- import { P } from "./Popover-BoLYvpo2.js";
16
+ import { P } from "./Popover-D-DgHnsV.js";
17
17
  import "mobx";
18
- import { u as C } from "./useOverlayController-D8pgx8nV.js";
18
+ import { u as C } from "./useOverlayController-BwSJj4Ly.js";
19
19
  import { TunnelProvider as y, TunnelExit as I } from "@mittwald/react-tunnel";
20
- import { O as B } from "./OverlayTrigger-BmB63e4e.js";
20
+ import { O as B } from "./OverlayTrigger-j2zD8W4S.js";
21
21
  const D = "flow--select", L = "flow--select--toggle", u = {
22
22
  select: D,
23
23
  toggle: L
package/dist/js/Tabs.js CHANGED
@@ -6,7 +6,7 @@ import u from "clsx";
6
6
  import { TunnelExit as E, TunnelProvider as P, TunnelEntry as f } from "@mittwald/react-tunnel";
7
7
  import { f as O } from "./flowComponent-1wOIvUIq.js";
8
8
  import { useCallbackRef as S } from "use-callback-ref";
9
- import { a as A, C as B } from "./ContextMenuTrigger-BbYyy0an.js";
9
+ import { a as A, C as B } from "./ContextMenuTrigger-C_0tJ4zR.js";
10
10
  import { M as K } from "./MenuItem-GX6Zh70q.js";
11
11
  import { B as L } from "./Button-tKo9ydZL.js";
12
12
  import "@tabler/icons-react";
@@ -0,0 +1,62 @@
1
+ "use client"
2
+ /* */
3
+ var r = Object.defineProperty;
4
+ var a = (s, e, n) => e in s ? r(s, e, { enumerable: !0, configurable: !0, writable: !0, value: n }) : s[e] = n;
5
+ var t = (s, e, n) => a(s, typeof e != "symbol" ? e + "" : e, n);
6
+ import { makeObservable as u, observable as i, action as O } from "mobx";
7
+ import { u as d } from "./useSelector-DpU7_HMO.js";
8
+ import { useRef as o, createContext as h, useContext as c } from "react";
9
+ class l {
10
+ constructor(e) {
11
+ t(this, "isOpen");
12
+ t(this, "onOpenHandlers", /* @__PURE__ */ new Set());
13
+ t(this, "onCloseHandlers", /* @__PURE__ */ new Set());
14
+ u(this, {
15
+ isOpen: i,
16
+ open: O.bound,
17
+ close: O.bound,
18
+ toggle: O.bound,
19
+ setOpen: O.bound
20
+ }), this.isOpen = (e == null ? void 0 : e.isDefaultOpen) ?? !1, e != null && e.onOpen && this.onOpenHandlers.add(e.onOpen), e != null && e.onClose && this.onCloseHandlers.add(e.onClose);
21
+ }
22
+ static useNew(e) {
23
+ return o(new l(e)).current;
24
+ }
25
+ addOnOpen(e) {
26
+ return this.onOpenHandlers.add(e), () => {
27
+ this.onOpenHandlers.delete(e);
28
+ };
29
+ }
30
+ addOnClose(e) {
31
+ return this.onCloseHandlers.add(e), () => {
32
+ this.onCloseHandlers.delete(e);
33
+ };
34
+ }
35
+ executeOnClose() {
36
+ this.onCloseHandlers.forEach((e) => e());
37
+ }
38
+ executeOnOpen() {
39
+ this.onOpenHandlers.forEach((e) => e());
40
+ }
41
+ open() {
42
+ this.isOpen = !0, this.executeOnOpen();
43
+ }
44
+ close() {
45
+ this.isOpen = !1, this.executeOnClose();
46
+ }
47
+ toggle() {
48
+ this.isOpen = !this.isOpen, this.isOpen ? this.executeOnOpen() : this.executeOnClose();
49
+ }
50
+ setOpen(e) {
51
+ this.isOpen = e, e ? this.executeOnOpen() : this.executeOnClose();
52
+ }
53
+ useIsOpen() {
54
+ return d(() => this.isOpen);
55
+ }
56
+ }
57
+ const p = h({}), b = () => c(p);
58
+ export {
59
+ l as O,
60
+ p as o,
61
+ b as u
62
+ };
@@ -1,7 +1,7 @@
1
1
  "use client"
2
2
  /* */
3
- import { O as e } from "./context-Cf7tqFtF.js";
4
- import { u as a } from "./useOverlayController-D8pgx8nV.js";
3
+ import { O as e } from "./context-BaYmTa0I.js";
4
+ import { u as a } from "./useOverlayController-BwSJj4Ly.js";
5
5
  export {
6
6
  e as OverlayController,
7
7
  a as useOverlayController
package/dist/js/hooks.js CHANGED
@@ -2,7 +2,7 @@
2
2
  /* */
3
3
  import "mobx";
4
4
  import { useState as o, useEffect as r } from "react";
5
- import { u as m } from "./useOverlayController-D8pgx8nV.js";
5
+ import { u as m } from "./useOverlayController-BwSJj4Ly.js";
6
6
  import { u as l } from "./useOnChange-C1Quwyuz.js";
7
7
  const n = () => {
8
8
  const [e, t] = o(!1);
@@ -8,7 +8,7 @@ import "@react-aria/utils";
8
8
  import "remeda";
9
9
  import { d as F } from "./dynamic-ClpUSmEt.js";
10
10
  import { F as A } from "./FieldError-BvH18haz.js";
11
- import { a as P, A as y } from "./Action-DsQVttvF.js";
11
+ import { a as P, A as y } from "./Action-isbDYaAK.js";
12
12
  const C = x({}), V = C.Provider, f = () => v(C);
13
13
  function D(t) {
14
14
  var i;
@@ -1,17 +1,24 @@
1
+ type OpenStateHandler = () => void;
2
+ type DisposerFn = () => void;
1
3
  export interface OverlayControllerOptions {
2
4
  isDefaultOpen?: boolean;
3
- onOpen?: () => void;
4
- onClose?: () => void;
5
+ onOpen?: OpenStateHandler;
6
+ onClose?: OpenStateHandler;
5
7
  }
6
8
  export declare class OverlayController {
7
9
  isOpen: boolean;
8
- onOpen?: () => void;
9
- onClose?: () => void;
10
+ private onOpenHandlers;
11
+ private onCloseHandlers;
10
12
  constructor(options?: OverlayControllerOptions);
11
13
  static useNew(options?: OverlayControllerOptions): OverlayController;
14
+ addOnOpen(handler: OpenStateHandler): DisposerFn;
15
+ addOnClose(handler: OpenStateHandler): DisposerFn;
16
+ private executeOnClose;
17
+ private executeOnOpen;
12
18
  open(): void;
13
19
  close(): void;
14
20
  toggle(): void;
15
21
  setOpen(to: boolean): void;
16
22
  useIsOpen(): boolean;
17
23
  }
24
+ export {};
@@ -0,0 +1,25 @@
1
+ "use client"
2
+ /* */
3
+ import { O as C, u as O } from "./context-BaYmTa0I.js";
4
+ import { useEffect as f } from "react";
5
+ const d = (s, l = {}) => {
6
+ const {
7
+ reuseControllerFromContext: u = !0,
8
+ isDefaultOpen: a,
9
+ onOpen: o,
10
+ onClose: e
11
+ } = l, c = C.useNew({
12
+ isDefaultOpen: a,
13
+ onOpen: o,
14
+ onClose: e
15
+ }), n = O()[s], r = u && n ? n : c;
16
+ return f(() => {
17
+ const t = [];
18
+ return o && t.push(r.addOnOpen(o)), e && t.push(r.addOnClose(e)), () => {
19
+ t.forEach((p) => p());
20
+ };
21
+ }, [o, e]), r;
22
+ };
23
+ export {
24
+ d as u
25
+ };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mittwald/flow-react-components",
3
- "version": "0.1.0-alpha.345",
3
+ "version": "0.1.0-alpha.346",
4
4
  "type": "module",
5
5
  "description": "A React implementation of Flow, mittwald’s design system",
6
6
  "homepage": "https://mittwald.github.io/flow",
@@ -405,7 +405,7 @@
405
405
  "@chakra-ui/live-region": "^2.1.0",
406
406
  "@internationalized/date": "^3.5.6",
407
407
  "@internationalized/string-compiler": "^3.2.5",
408
- "@mittwald/react-tunnel": "^0.1.0-alpha.345",
408
+ "@mittwald/react-tunnel": "^0.1.0-alpha.346",
409
409
  "@mittwald/react-use-promise": "^2.5.0",
410
410
  "@react-aria/form": "^3.0.10",
411
411
  "@react-aria/utils": "^3.25.3",
@@ -435,7 +435,7 @@
435
435
  },
436
436
  "devDependencies": {
437
437
  "@faker-js/faker": "^9.0.3",
438
- "@mittwald/flow-design-tokens": "^0.1.0-alpha.345",
438
+ "@mittwald/flow-design-tokens": "^0.1.0-alpha.346",
439
439
  "@mittwald/react-use-promise": "^2.5.0",
440
440
  "@nx/storybook": "^20.0.0",
441
441
  "@storybook/addon-a11y": "^8.3.5",
@@ -530,5 +530,5 @@
530
530
  }
531
531
  }
532
532
  },
533
- "gitHead": "65ea60ca3d52a9f721c98b455e4c44e5d005ea03"
533
+ "gitHead": "b59a2ccadda366c19f4e397b36bb0fbd3cd26c2a"
534
534
  }
@@ -1,50 +0,0 @@
1
- "use client"
2
- /* */
3
- var l = Object.defineProperty;
4
- var o = (n, e, s) => e in n ? l(n, e, { enumerable: !0, configurable: !0, writable: !0, value: s }) : n[e] = s;
5
- var t = (n, e, s) => o(n, typeof e != "symbol" ? e + "" : e, s);
6
- import { makeObservable as u, observable as h, action as O } from "mobx";
7
- import { u as a } from "./useSelector-DpU7_HMO.js";
8
- import { useRef as c, createContext as p, useContext as C } from "react";
9
- class i {
10
- constructor(e) {
11
- t(this, "isOpen");
12
- t(this, "onOpen");
13
- t(this, "onClose");
14
- u(this, {
15
- isOpen: h,
16
- open: O.bound,
17
- close: O.bound,
18
- toggle: O.bound,
19
- setOpen: O.bound
20
- }), this.isOpen = (e == null ? void 0 : e.isDefaultOpen) ?? !1, this.onOpen = e == null ? void 0 : e.onOpen, this.onClose = e == null ? void 0 : e.onClose;
21
- }
22
- static useNew(e) {
23
- return c(new i(e)).current;
24
- }
25
- open() {
26
- var e;
27
- this.isOpen = !0, (e = this.onOpen) == null || e.call(this);
28
- }
29
- close() {
30
- var e;
31
- this.isOpen = !1, (e = this.onClose) == null || e.call(this);
32
- }
33
- toggle() {
34
- var e, s;
35
- this.isOpen = !this.isOpen, this.isOpen ? (e = this.onOpen) == null || e.call(this) : (s = this.onClose) == null || s.call(this);
36
- }
37
- setOpen(e) {
38
- var s, r;
39
- this.isOpen = e, e ? (s = this.onOpen) == null || s.call(this) : (r = this.onClose) == null || r.call(this);
40
- }
41
- useIsOpen() {
42
- return a(() => this.isOpen);
43
- }
44
- }
45
- const f = p({}), g = () => C(f);
46
- export {
47
- i as O,
48
- f as o,
49
- g as u
50
- };
@@ -1,19 +0,0 @@
1
- "use client"
2
- /* */
3
- import { O as C, u as a } from "./context-Cf7tqFtF.js";
4
- const c = (o, r = {}) => {
5
- const {
6
- reuseControllerFromContext: t = !0,
7
- isDefaultOpen: n,
8
- onOpen: l,
9
- onClose: s
10
- } = r, u = C.useNew({
11
- isDefaultOpen: n,
12
- onOpen: l,
13
- onClose: s
14
- }), e = a()[o];
15
- return t && e ? e : u;
16
- };
17
- export {
18
- c as u
19
- };