@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.
- package/dist/{Action-7EQNT1az.js → Action-BLnSsHE1.js} +86 -70
- package/dist/Action.js +1 -1
- package/dist/CopyButton.js +1 -1
- package/dist/Header-uOS96l33.js +11 -0
- package/dist/Header.js +3 -8
- package/dist/Modal.js +3 -3
- package/dist/OffCanvas.js +22 -17
- package/dist/{Overlay-CUZ1KZa8.js → Overlay-BWA78Wvu.js} +1 -1
- package/dist/OverlayTrigger.js +2 -2
- package/dist/Table.js +40 -0
- package/dist/{context-CEG7VfKL.js → context-D3hdrTHO.js} +1 -1
- package/dist/controller.js +1 -1
- package/dist/hooks.js +10 -3
- package/dist/styles.css +1 -1
- package/dist/types/components/Action/lib/execution/ActionExecution.d.ts +2 -0
- package/dist/types/components/OffCanvas/stories/EdgeCases.stories.d.ts +7 -0
- package/dist/types/components/Table/Table.d.ts +7 -0
- package/dist/types/components/Table/components/TableBody/TableBody.d.ts +7 -0
- package/dist/types/components/Table/components/TableBody/index.d.ts +4 -0
- package/dist/types/components/Table/components/TableCell/TableCell.d.ts +7 -0
- package/dist/types/components/Table/components/TableCell/index.d.ts +4 -0
- package/dist/types/components/Table/components/TableColumn/TableColumn.d.ts +7 -0
- package/dist/types/components/Table/components/TableColumn/index.d.ts +4 -0
- package/dist/types/components/Table/components/TableHeader/TableHeader.d.ts +7 -0
- package/dist/types/components/Table/components/TableHeader/index.d.ts +4 -0
- package/dist/types/components/Table/components/TableRow/TableRow.d.ts +7 -0
- package/dist/types/components/Table/components/TableRow/index.d.ts +4 -0
- package/dist/types/components/Table/index.d.ts +9 -0
- package/dist/types/components/Table/stories/Default.stories.d.ts +7 -0
- package/dist/types/lib/hooks/index.d.ts +1 -0
- package/dist/types/lib/hooks/useOnChange.d.ts +3 -0
- package/dist/{index-BlZLqtIV.js → useOverlayController-CGKumeGL.js} +7 -7
- package/package.json +34 -30
|
@@ -3,6 +3,7 @@ import { ActionState } from './ActionState';
|
|
|
3
3
|
interface ActionExecutionOptions {
|
|
4
4
|
showFeedback?: boolean;
|
|
5
5
|
resetAfterDone?: boolean;
|
|
6
|
+
resetDelayMs?: number;
|
|
6
7
|
onFeedbackDone?: (...args: unknown[]) => void;
|
|
7
8
|
}
|
|
8
9
|
export declare class ActionExecution {
|
|
@@ -15,6 +16,7 @@ export declare class ActionExecution {
|
|
|
15
16
|
onAsyncStart(): void;
|
|
16
17
|
onSucceeded(): Promise<void>;
|
|
17
18
|
onFailed(error: unknown): Promise<void>;
|
|
19
|
+
setResetDelay(ms: number): void;
|
|
18
20
|
private startFailedFeedback;
|
|
19
21
|
private startSucceededFeedback;
|
|
20
22
|
private resetAfterDone;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { Table } from './Table';
|
|
2
|
+
|
|
3
|
+
export { type TableProps, Table } from './Table';
|
|
4
|
+
export * from './components/TableBody';
|
|
5
|
+
export * from './components/TableCell';
|
|
6
|
+
export * from './components/TableColumn';
|
|
7
|
+
export * from './components/TableHeader';
|
|
8
|
+
export * from './components/TableRow';
|
|
9
|
+
export default Table;
|
|
@@ -3,14 +3,14 @@
|
|
|
3
3
|
var p = Object.defineProperty;
|
|
4
4
|
var a = (t, e, o) => e in t ? p(t, e, { enumerable: !0, configurable: !0, writable: !0, value: o }) : t[e] = o;
|
|
5
5
|
var i = (t, e, o) => (a(t, typeof e != "symbol" ? e + "" : e, o), o);
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
6
|
+
import { useRef as c, createContext as O, useContext as m } from "react";
|
|
7
|
+
import { makeObservable as C, observable as b, action as s } from "mobx";
|
|
8
8
|
import { u as d } from "./useSelector-DpU7_HMO.js";
|
|
9
9
|
class n {
|
|
10
10
|
constructor(e = !1) {
|
|
11
11
|
i(this, "isOpen");
|
|
12
|
-
|
|
13
|
-
isOpen:
|
|
12
|
+
C(this, {
|
|
13
|
+
isOpen: b,
|
|
14
14
|
open: s.bound,
|
|
15
15
|
close: s.bound,
|
|
16
16
|
toggle: s.bound,
|
|
@@ -18,7 +18,7 @@ class n {
|
|
|
18
18
|
}), this.isOpen = e;
|
|
19
19
|
}
|
|
20
20
|
static useNew(e) {
|
|
21
|
-
return
|
|
21
|
+
return c(new n(e)).current;
|
|
22
22
|
}
|
|
23
23
|
open() {
|
|
24
24
|
this.isOpen = !0;
|
|
@@ -36,10 +36,10 @@ class n {
|
|
|
36
36
|
return d(() => this.isOpen);
|
|
37
37
|
}
|
|
38
38
|
}
|
|
39
|
-
const l =
|
|
39
|
+
const l = O(
|
|
40
40
|
void 0
|
|
41
41
|
), g = l.Provider, w = (t = {}) => {
|
|
42
|
-
const { reuseControllerFromContext: e = !0, defaultOpen: o } = t, u = n.useNew(o), r =
|
|
42
|
+
const { reuseControllerFromContext: e = !0, defaultOpen: o } = t, u = n.useNew(o), r = m(l);
|
|
43
43
|
return e && r ? r : u;
|
|
44
44
|
};
|
|
45
45
|
export {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mittwald/flow-react-components",
|
|
3
|
-
"version": "0.1.0-alpha.
|
|
3
|
+
"version": "0.1.0-alpha.126",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "A React implementation of Flow, mittwald’s design system",
|
|
6
6
|
"homepage": "https://mittwald.github.io/flow",
|
|
@@ -198,6 +198,10 @@
|
|
|
198
198
|
"types": "./dist/types/components/Switch/index.d.ts",
|
|
199
199
|
"import": "./dist/Switch.js"
|
|
200
200
|
},
|
|
201
|
+
"./Table": {
|
|
202
|
+
"types": "./dist/types/components/Table/index.d.ts",
|
|
203
|
+
"import": "./dist/Table.js"
|
|
204
|
+
},
|
|
201
205
|
"./Tabs": {
|
|
202
206
|
"types": "./dist/types/components/Tabs/index.d.ts",
|
|
203
207
|
"import": "./dist/Tabs.js"
|
|
@@ -251,12 +255,12 @@
|
|
|
251
255
|
},
|
|
252
256
|
"dependencies": {
|
|
253
257
|
"@chakra-ui/live-region": "^2.1.0",
|
|
254
|
-
"@mittwald/react-tunnel": "^0.1.0-alpha.
|
|
258
|
+
"@mittwald/react-tunnel": "^0.1.0-alpha.126",
|
|
255
259
|
"@mittwald/react-use-promise": "^2.3.13",
|
|
256
|
-
"@react-aria/utils": "^3.24.
|
|
257
|
-
"@react-types/shared": "^3.23.
|
|
258
|
-
"@storybook/test": "^8.1.
|
|
259
|
-
"@tabler/icons-react": "^3.
|
|
260
|
+
"@react-aria/utils": "^3.24.1",
|
|
261
|
+
"@react-types/shared": "^3.23.1",
|
|
262
|
+
"@storybook/test": "^8.1.2",
|
|
263
|
+
"@tabler/icons-react": "^3.5.0",
|
|
260
264
|
"@tanstack/react-table": "^8.17.3",
|
|
261
265
|
"clsx": "^2.1.1",
|
|
262
266
|
"copy-to-clipboard": "^3.3.3",
|
|
@@ -266,31 +270,31 @@
|
|
|
266
270
|
"mobx": "^6.12.3",
|
|
267
271
|
"mobx-react-lite": "^4.0.7",
|
|
268
272
|
"object-code": "^1.3.3",
|
|
269
|
-
"react-aria": "^3.33.
|
|
270
|
-
"react-aria-components": "^1.2.
|
|
273
|
+
"react-aria": "^3.33.1",
|
|
274
|
+
"react-aria-components": "^1.2.1",
|
|
271
275
|
"react-children-utilities": "^2.10.0",
|
|
272
|
-
"react-stately": "^3.31.
|
|
276
|
+
"react-stately": "^3.31.1",
|
|
273
277
|
"remeda": "^1.61.0",
|
|
274
278
|
"use-callback-ref": "^1.3.2"
|
|
275
279
|
},
|
|
276
280
|
"devDependencies": {
|
|
277
281
|
"@faker-js/faker": "^8.4.1",
|
|
278
|
-
"@mittwald/flow-design-tokens": "^0.1.0-alpha.
|
|
282
|
+
"@mittwald/flow-design-tokens": "^0.1.0-alpha.126",
|
|
279
283
|
"@mittwald/react-use-promise": "^2.3.13",
|
|
280
|
-
"@nx/storybook": "^19.0.
|
|
281
|
-
"@storybook/addon-a11y": "^8.1.
|
|
282
|
-
"@storybook/addon-actions": "^8.1.
|
|
283
|
-
"@storybook/addon-essentials": "^8.1.
|
|
284
|
-
"@storybook/addon-interactions": "^8.1.
|
|
285
|
-
"@storybook/addon-links": "^8.1.
|
|
286
|
-
"@storybook/blocks": "^8.1.
|
|
287
|
-
"@storybook/components": "^8.1.
|
|
288
|
-
"@storybook/core-events": "^8.1.
|
|
289
|
-
"@storybook/manager-api": "^8.1.
|
|
290
|
-
"@storybook/preview-api": "^8.1.
|
|
291
|
-
"@storybook/react": "^8.1.
|
|
292
|
-
"@storybook/react-vite": "^8.1.
|
|
293
|
-
"@storybook/theming": "^8.1.
|
|
284
|
+
"@nx/storybook": "^19.0.5",
|
|
285
|
+
"@storybook/addon-a11y": "^8.1.2",
|
|
286
|
+
"@storybook/addon-actions": "^8.1.2",
|
|
287
|
+
"@storybook/addon-essentials": "^8.1.2",
|
|
288
|
+
"@storybook/addon-interactions": "^8.1.2",
|
|
289
|
+
"@storybook/addon-links": "^8.1.2",
|
|
290
|
+
"@storybook/blocks": "^8.1.2",
|
|
291
|
+
"@storybook/components": "^8.1.2",
|
|
292
|
+
"@storybook/core-events": "^8.1.2",
|
|
293
|
+
"@storybook/manager-api": "^8.1.2",
|
|
294
|
+
"@storybook/preview-api": "^8.1.2",
|
|
295
|
+
"@storybook/react": "^8.1.2",
|
|
296
|
+
"@storybook/react-vite": "^8.1.2",
|
|
297
|
+
"@storybook/theming": "^8.1.2",
|
|
294
298
|
"@testing-library/dom": "^10.1.0",
|
|
295
299
|
"@testing-library/jest-dom": "^6.4.5",
|
|
296
300
|
"@testing-library/react": "~15.0.7",
|
|
@@ -308,7 +312,7 @@
|
|
|
308
312
|
"fs-jetpack": "^5.1.0",
|
|
309
313
|
"happy-dom": "^14.11.0",
|
|
310
314
|
"next": "^14.2.3",
|
|
311
|
-
"nx": "^19.0.
|
|
315
|
+
"nx": "^19.0.5",
|
|
312
316
|
"postcss": "^8.4.38",
|
|
313
317
|
"postcss-nested-import": "^1.3.0",
|
|
314
318
|
"postcss-nesting": "^12.1.4",
|
|
@@ -317,12 +321,12 @@
|
|
|
317
321
|
"react": "^18.3.1",
|
|
318
322
|
"react-dom": "^18.3.1",
|
|
319
323
|
"react-element-to-jsx-string": "^15.0.0",
|
|
320
|
-
"react-hook-form": "^7.51.
|
|
321
|
-
"rollup": "^4.
|
|
324
|
+
"react-hook-form": "^7.51.5",
|
|
325
|
+
"rollup": "^4.18.0",
|
|
322
326
|
"sass": "^1.77.2",
|
|
323
|
-
"storybook": "^8.1.
|
|
327
|
+
"storybook": "^8.1.2",
|
|
324
328
|
"storybook-addon-rtl": "^1.0.0",
|
|
325
|
-
"tsx": "^4.10.
|
|
329
|
+
"tsx": "^4.10.5",
|
|
326
330
|
"typescript": "^5.4.5",
|
|
327
331
|
"typescript-plugin-css-modules": "^5.1.0",
|
|
328
332
|
"vite": "^5.2.11",
|
|
@@ -351,5 +355,5 @@
|
|
|
351
355
|
"optional": true
|
|
352
356
|
}
|
|
353
357
|
},
|
|
354
|
-
"gitHead": "
|
|
358
|
+
"gitHead": "a34b368d9d2e9482b38ba871af6d94b3d92e258b"
|
|
355
359
|
}
|