@mittwald/flow-react-components 0.1.0-alpha.349 → 0.1.0-alpha.350

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,20 @@
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.350](https://github.com/mittwald/flow/compare/0.1.0-alpha.349...0.1.0-alpha.350) (2024-11-19)
7
+
8
+ ### Bug Fixes
9
+
10
+ - **LightBox:** fix LightBox controller
11
+ ([5cc4507](https://github.com/mittwald/flow/commit/5cc4507745997e7fa9b5a8e2d2a941c7c72d2e35))
12
+ - **LightBox:** fix LightBox controller
13
+ ([f3e84af](https://github.com/mittwald/flow/commit/f3e84af39e6d927f1bcdd4f0e9d513ff4e2a658b))
14
+
15
+ # Change Log
16
+
17
+ All notable changes to this project will be documented in this file. See
18
+ [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
19
+
6
20
  # [0.1.0-alpha.349](https://github.com/mittwald/flow/compare/0.1.0-alpha.348...0.1.0-alpha.349) (2024-11-18)
7
21
 
8
22
  ### Features
@@ -1,71 +1,74 @@
1
1
  "use client"
2
2
  /* */
3
- import { f as m } from "./flowComponent-D-FBrwbQ.js";
4
- import t from "react";
5
- import { O as p } from "./Overlay-BwfQD0k1.js";
6
- import f from "clsx";
3
+ import { f } from "./flowComponent-D-FBrwbQ.js";
4
+ import o from "react";
5
+ import { O as g } from "./Overlay-BwfQD0k1.js";
6
+ import u from "clsx";
7
+ import "mobx";
8
+ import { u as x } from "./useOverlayController-BwSJj4Ly.js";
7
9
  import "./propsContext-DzAKlmhS.js";
8
- import { PropsContextProvider as g } from "./PropsContextProvider.js";
10
+ import { PropsContextProvider as h } from "./PropsContextProvider.js";
9
11
  import "@react-aria/utils";
10
12
  import "remeda";
11
- import { B as u } from "./Button-DCUWhBV1.js";
13
+ import { B } from "./Button-DCUWhBV1.js";
12
14
  import "@tabler/icons-react";
13
15
  import "./Icon-CxrvfV3P.js";
14
- import { I as x } from "./IconClose-RfQv2X6g.js";
15
- import { A as h } from "./Action-Bcw69Ub4.js";
16
- import { TunnelProvider as B, TunnelExit as v } from "@mittwald/react-tunnel";
17
- import * as E from "react-aria-components";
18
- import { a as d } from "./OverlayTrigger-j2zD8W4S.js";
19
- const y = "flow--light-box", T = "flow--light-box--content", w = "flow--light-box--fit-screen", G = "flow--light-box--actions", L = "flow--light-box--action-group", o = {
20
- lightBox: y,
16
+ import { I as v } from "./IconClose-RfQv2X6g.js";
17
+ import { TunnelProvider as d, TunnelExit as E } from "@mittwald/react-tunnel";
18
+ import * as C from "react-aria-components";
19
+ import { a as y } from "./OverlayTrigger-j2zD8W4S.js";
20
+ const P = "flow--light-box", T = "flow--light-box--content", w = "flow--light-box--fit-screen", G = "flow--light-box--actions", L = "flow--light-box--action-group", t = {
21
+ lightBox: P,
21
22
  content: T,
22
23
  fitScreen: w,
23
24
  actions: G,
24
25
  actionGroup: L
25
- }, J = m("LightBox", (e) => {
26
+ }, Q = f("LightBox", (e) => {
26
27
  const {
27
- controller: r,
28
- children: n,
28
+ controller: n,
29
+ children: i,
29
30
  refProp: N,
30
- className: i,
31
+ className: l,
31
32
  fitScreen: c = !0,
32
- ...l
33
- } = e, a = f(
34
- o.lightBox,
35
- c && o.fitScreen,
36
- i
37
- ), s = {
33
+ ...s
34
+ } = e, a = u(
35
+ t.lightBox,
36
+ c && t.fitScreen,
37
+ l
38
+ ), m = {
38
39
  ActionGroup: {
39
- className: o.actionGroup,
40
+ className: t.actionGroup,
40
41
  Button: { variant: "soft", color: "light" },
41
42
  tunnelId: "actionGroup",
42
43
  ignoreBreakpoint: !0
43
44
  }
44
- };
45
- return /* @__PURE__ */ t.createElement(
46
- p,
45
+ }, p = x("LightBox", {
46
+ reuseControllerFromContext: !0
47
+ }), r = n ?? p;
48
+ return /* @__PURE__ */ o.createElement(
49
+ g,
47
50
  {
48
51
  overlayType: "LightBox",
49
52
  className: a,
50
53
  controller: r,
51
- ...l
54
+ ...s
52
55
  },
53
- /* @__PURE__ */ t.createElement(g, { props: s }, /* @__PURE__ */ t.createElement(B, null, /* @__PURE__ */ t.createElement("div", { className: o.content }, n), /* @__PURE__ */ t.createElement("div", { className: o.actions }, /* @__PURE__ */ t.createElement(h, { closeOverlay: "LightBox" }, /* @__PURE__ */ t.createElement(u, { color: "light", variant: "soft" }, /* @__PURE__ */ t.createElement(x, null))), /* @__PURE__ */ t.createElement(v, { id: "actionGroup" }))))
56
+ /* @__PURE__ */ o.createElement(h, { props: m }, /* @__PURE__ */ o.createElement(d, null, /* @__PURE__ */ o.createElement("div", { className: t.content }, i), /* @__PURE__ */ o.createElement("div", { className: t.actions }, /* @__PURE__ */ o.createElement(B, { color: "light", variant: "soft", onPress: r == null ? void 0 : r.close }, /* @__PURE__ */ o.createElement(v, null)), /* @__PURE__ */ o.createElement(E, { id: "actionGroup" }))))
54
57
  );
55
- }), K = (e) => {
56
- const { children: r, ...n } = e;
57
- return /* @__PURE__ */ t.createElement(
58
- d,
58
+ }), U = (e) => {
59
+ const { children: n, ...i } = e;
60
+ return /* @__PURE__ */ o.createElement(
61
+ y,
59
62
  {
60
63
  overlayType: "LightBox",
61
- ...n,
62
- component: E.DialogTrigger
64
+ ...i,
65
+ component: C.DialogTrigger
63
66
  },
64
- r
67
+ n
65
68
  );
66
69
  };
67
70
  export {
68
- J as LightBox,
69
- K as LightBoxTrigger,
70
- J as default
71
+ Q as LightBox,
72
+ U as LightBoxTrigger,
73
+ Q as default
71
74
  };
@@ -5,3 +5,4 @@ export default meta;
5
5
  type Story = StoryObj<typeof LightBox>;
6
6
  export declare const Default: Story;
7
7
  export declare const WithoutFitScreen: Story;
8
+ export declare const WithController: Story;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mittwald/flow-react-components",
3
- "version": "0.1.0-alpha.349",
3
+ "version": "0.1.0-alpha.350",
4
4
  "type": "module",
5
5
  "description": "A React implementation of Flow, mittwald’s design system",
6
6
  "homepage": "https://mittwald.github.io/flow",
@@ -410,7 +410,7 @@
410
410
  "@chakra-ui/live-region": "^2.1.0",
411
411
  "@internationalized/date": "^3.5.6",
412
412
  "@internationalized/string-compiler": "^3.2.5",
413
- "@mittwald/react-tunnel": "^0.1.0-alpha.349",
413
+ "@mittwald/react-tunnel": "^0.1.0-alpha.350",
414
414
  "@mittwald/react-use-promise": "^2.5.0",
415
415
  "@react-aria/form": "^3.0.10",
416
416
  "@react-aria/utils": "^3.25.3",
@@ -440,7 +440,7 @@
440
440
  },
441
441
  "devDependencies": {
442
442
  "@faker-js/faker": "^9.0.3",
443
- "@mittwald/flow-design-tokens": "^0.1.0-alpha.349",
443
+ "@mittwald/flow-design-tokens": "^0.1.0-alpha.350",
444
444
  "@mittwald/react-use-promise": "^2.5.0",
445
445
  "@nx/storybook": "^20.0.0",
446
446
  "@storybook/addon-a11y": "^8.3.5",
@@ -535,5 +535,5 @@
535
535
  }
536
536
  }
537
537
  },
538
- "gitHead": "9abd015cbaa3978e1bd624bf2f15972e6ac7af65"
538
+ "gitHead": "064a61d717077b0f2da5b05d3291555d3b1acfc4"
539
539
  }