@mittwald/flow-react-components 0.1.0-alpha.61 → 0.1.0-alpha.62
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-DT6jWAqa.js → Action-CeKzQsag.js} +1 -1
- package/dist/Action.js +1 -1
- package/dist/Avatar.js +1 -1
- package/dist/Breadcrumb.js +1 -1
- package/dist/{Button-K1ktUAEv.js → Button-Byf2Pi9z.js} +3 -3
- package/dist/Button.js +1 -1
- package/dist/ButtonGroup.js +1 -1
- package/dist/{Checkbox-De7ZNCuQ.js → Checkbox-CBAAtfxq.js} +2 -2
- package/dist/Checkbox.js +1 -1
- package/dist/{CheckboxButton-D8M2QcSR.js → CheckboxButton-BYp2HCfN.js} +1 -1
- package/dist/CheckboxButton.js +1 -1
- package/dist/CheckboxGroup.js +2 -2
- package/dist/Content.js +1 -1
- package/dist/ContextMenu.js +2 -2
- package/dist/{ContextMenuItem-FeOABGAA.js → ContextMenuItem-jQjIDLgf.js} +4 -4
- package/dist/CopyButton.js +4 -4
- package/dist/FieldDescription.js +2 -2
- package/dist/{FieldError-D2Xf1SUy.js → FieldError-D9ZaMqoL.js} +2 -2
- package/dist/FieldError.js +1 -1
- package/dist/Header.js +1 -1
- package/dist/Heading.js +1 -1
- package/dist/{Icon-QRU6ff6c.js → Icon-DnhU6oCr.js} +1 -1
- package/dist/Icon.js +1 -1
- package/dist/{IconCheck-CDLMv3G3.js → IconCheck-VQzoZYpg.js} +1 -1
- package/dist/{IconCheckboxEmpty-K4aq2aRv.js → IconCheckboxEmpty-BYBEifGn.js} +1 -1
- package/dist/{IconCheckboxIndeterminate-DyTX9k0O.js → IconCheckboxIndeterminate-DCWISQ9y.js} +1 -1
- package/dist/{IconChevronDown-n2DJdnRB.js → IconChevronDown-BmKMxrq1.js} +1 -1
- package/dist/{IconChevronRight-BOY7IxRM.js → IconChevronRight-ngvPFPMg.js} +1 -1
- package/dist/{IconClose-DYvIbwoN.js → IconClose-BkmXvQ2z.js} +1 -1
- package/dist/{IconContextMenu-DFvw_d9h.js → IconContextMenu-B7uKuktv.js} +1 -1
- package/dist/{IconCopy-CYChwYCx.js → IconCopy-BmKbdWWX.js} +1 -1
- package/dist/{IconDanger-CP4R6i5T.js → IconDanger-C0Tcw4tP.js} +1 -1
- package/dist/{IconPlus-DazBjEoi.js → IconPlus-DfL7-kUg.js} +1 -1
- package/dist/{IconRadioOn-BqCA-noy.js → IconRadioOn-VUVt3QQC.js} +1 -1
- package/dist/{IconSucceeded-CHBiied9.js → IconSucceeded-CENvDJzH.js} +1 -1
- package/dist/{IconWarning-DYI5SVhB.js → IconWarning-43TmpPox.js} +1 -1
- package/dist/Icons.js +14 -14
- package/dist/Image.js +1 -1
- package/dist/Initials.js +1 -1
- package/dist/InlineAlert.js +2 -2
- package/dist/{Label-CJOiPsOr.js → Label-BBWAOhU5.js} +1 -1
- package/dist/Label.js +1 -1
- package/dist/LayoutCard.js +1 -1
- package/dist/{Link-DWMWhCqU.js → Link-3bAuyVEg.js} +1 -1
- package/dist/Link.js +1 -1
- package/dist/List.js +7 -7
- package/dist/NumberField.js +4 -4
- package/dist/RadioGroup.js +4 -4
- package/dist/StatusBadge.js +3 -3
- package/dist/{StatusIcon-DHa4uxfZ.js → StatusIcon-D6re4qSI.js} +2 -2
- package/dist/StatusIcon.js +1 -1
- package/dist/Switch.js +4 -4
- package/dist/Tabs.js +44 -0
- package/dist/{Text-Dd9tXlc8.js → Text-BdJNMX4h.js} +1 -1
- package/dist/Text.js +1 -1
- package/dist/TextArea.js +1 -1
- package/dist/TextField.js +1 -1
- package/dist/{TextFieldBase-BdkqA5-_.js → TextFieldBase-Dtcmh0_x.js} +1 -1
- package/dist/{flowComponent-C3IF_aaP.js → flowComponent-Dfn_Z9Yx.js} +1 -1
- package/dist/styles.css +1 -1
- package/dist/types/components/Tabs/Tabs.d.ts +7 -0
- package/dist/types/components/Tabs/components/Tab/Tab.d.ts +7 -0
- package/dist/types/components/Tabs/components/Tab/context.d.ts +7 -0
- package/dist/types/components/Tabs/components/Tab/index.d.ts +4 -0
- package/dist/types/components/Tabs/components/TabTitle/TabTitle.d.ts +7 -0
- package/dist/types/components/Tabs/components/TabTitle/index.d.ts +4 -0
- package/dist/types/components/Tabs/index.d.ts +3 -0
- package/dist/types/components/Tabs/stories/Default.stories.d.ts +8 -0
- package/dist/types/components/propTypes/index.d.ts +1 -1
- package/dist/useProps-DqP5wneE.js +77 -0
- package/package.json +8 -4
- package/dist/useProps-BiJ72z10.js +0 -77
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { FC, PropsWithChildren } from 'react';
|
|
2
|
+
|
|
3
|
+
import * as Aria from "react-aria-components";
|
|
4
|
+
export interface TabTitleProps extends Omit<Aria.TabProps, "children" | "id">, PropsWithChildren {
|
|
5
|
+
}
|
|
6
|
+
export declare const TabTitle: FC<TabTitleProps>;
|
|
7
|
+
export default TabTitle;
|
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
"use client"
|
|
2
|
+
/* */
|
|
3
|
+
import { mergeProps as u } from "@react-aria/utils";
|
|
4
|
+
import { u as p } from "./propsContext-CauylOgH.js";
|
|
5
|
+
import c, { isValidElement as d } from "react";
|
|
6
|
+
import { pickBy as a, omit as m } from "remeda";
|
|
7
|
+
import { P as C } from "./PropsContextProvider-BcOGMJkn.js";
|
|
8
|
+
const f = {
|
|
9
|
+
Action: !0,
|
|
10
|
+
Avatar: !0,
|
|
11
|
+
Button: !0,
|
|
12
|
+
ButtonGroup: !0,
|
|
13
|
+
Content: !0,
|
|
14
|
+
ContextMenu: !0,
|
|
15
|
+
CopyButton: !0,
|
|
16
|
+
FieldDescription: !0,
|
|
17
|
+
FieldError: !0,
|
|
18
|
+
Header: !0,
|
|
19
|
+
Heading: !0,
|
|
20
|
+
Icon: !0,
|
|
21
|
+
Image: !0,
|
|
22
|
+
Initials: !0,
|
|
23
|
+
InlineAlert: !0,
|
|
24
|
+
Label: !0,
|
|
25
|
+
LayoutCard: !0,
|
|
26
|
+
Link: !0,
|
|
27
|
+
Radio: !0,
|
|
28
|
+
StatusBadge: !0,
|
|
29
|
+
Switch: !0,
|
|
30
|
+
TestComponent: !0,
|
|
31
|
+
Text: !0
|
|
32
|
+
}, i = Object.keys(
|
|
33
|
+
f
|
|
34
|
+
);
|
|
35
|
+
function l(t) {
|
|
36
|
+
return !!t && typeof t == "object" && "__dynamicProp" in t;
|
|
37
|
+
}
|
|
38
|
+
function s(t) {
|
|
39
|
+
return typeof t == "string" && i.includes(t);
|
|
40
|
+
}
|
|
41
|
+
function y(t) {
|
|
42
|
+
return !s(t);
|
|
43
|
+
}
|
|
44
|
+
const P = (t, r) => {
|
|
45
|
+
const e = {};
|
|
46
|
+
for (const n in t)
|
|
47
|
+
if (y(n)) {
|
|
48
|
+
const o = t[n];
|
|
49
|
+
l(o) && (e[n] = o.__dynamicProp(r));
|
|
50
|
+
}
|
|
51
|
+
return e;
|
|
52
|
+
};
|
|
53
|
+
function x(t) {
|
|
54
|
+
return !!t && typeof t == "object" && "children" in t && !!t.children;
|
|
55
|
+
}
|
|
56
|
+
const h = (t) => a(t, (r, e) => s(e)), v = (t, r) => {
|
|
57
|
+
if (!x(r))
|
|
58
|
+
return {};
|
|
59
|
+
const e = r.children;
|
|
60
|
+
if (!Array.isArray(e) && !d(e))
|
|
61
|
+
return {};
|
|
62
|
+
const n = h(t);
|
|
63
|
+
return Object.keys(n).length === 0 ? {} : {
|
|
64
|
+
children: /* @__PURE__ */ c.createElement(C, { props: n }, r.children)
|
|
65
|
+
};
|
|
66
|
+
}, B = (t, r) => {
|
|
67
|
+
const e = p()[t], n = e ? P(e, r) : void 0, o = e ? v(e, r) : void 0;
|
|
68
|
+
return u(
|
|
69
|
+
e && m(e, i),
|
|
70
|
+
r,
|
|
71
|
+
n,
|
|
72
|
+
o
|
|
73
|
+
);
|
|
74
|
+
};
|
|
75
|
+
export {
|
|
76
|
+
B as u
|
|
77
|
+
};
|
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.62",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "A React implementation of Flow, mittwald’s design system",
|
|
6
6
|
"homepage": "https://mittwald.github.io/flow",
|
|
@@ -154,6 +154,10 @@
|
|
|
154
154
|
"types": "./dist/types/components/Switch/index.d.ts",
|
|
155
155
|
"import": "./dist/Switch.js"
|
|
156
156
|
},
|
|
157
|
+
"./Tabs": {
|
|
158
|
+
"types": "./dist/types/components/Tabs/index.d.ts",
|
|
159
|
+
"import": "./dist/Tabs.js"
|
|
160
|
+
},
|
|
157
161
|
"./Text": {
|
|
158
162
|
"types": "./dist/types/components/Text/index.d.ts",
|
|
159
163
|
"import": "./dist/Text.js"
|
|
@@ -194,7 +198,7 @@
|
|
|
194
198
|
"test:unit": "run vitest run"
|
|
195
199
|
},
|
|
196
200
|
"dependencies": {
|
|
197
|
-
"@mittwald/react-tunnel": "^0.1.0-alpha.
|
|
201
|
+
"@mittwald/react-tunnel": "^0.1.0-alpha.62",
|
|
198
202
|
"@mittwald/react-use-promise": "^2.3.13",
|
|
199
203
|
"@react-aria/utils": "^3.23.2",
|
|
200
204
|
"@react-types/shared": "^3.22.1",
|
|
@@ -217,7 +221,7 @@
|
|
|
217
221
|
},
|
|
218
222
|
"devDependencies": {
|
|
219
223
|
"@faker-js/faker": "^8.4.1",
|
|
220
|
-
"@mittwald/flow-design-tokens": "^0.1.0-alpha.
|
|
224
|
+
"@mittwald/flow-design-tokens": "^0.1.0-alpha.62",
|
|
221
225
|
"@mittwald/react-use-promise": "^2.3.13",
|
|
222
226
|
"@nx/storybook": "^18.2.3",
|
|
223
227
|
"@storybook/addon-a11y": "^8.0.6",
|
|
@@ -287,5 +291,5 @@
|
|
|
287
291
|
"optional": true
|
|
288
292
|
}
|
|
289
293
|
},
|
|
290
|
-
"gitHead": "
|
|
294
|
+
"gitHead": "f4c0987a7cf134236a1cbd42a8c132da0dad5381"
|
|
291
295
|
}
|
|
@@ -1,77 +0,0 @@
|
|
|
1
|
-
"use client"
|
|
2
|
-
/* */
|
|
3
|
-
import { mergeProps as s } from "@react-aria/utils";
|
|
4
|
-
import { u } from "./propsContext-CauylOgH.js";
|
|
5
|
-
import p, { isValidElement as c } from "react";
|
|
6
|
-
import { pickBy as d } from "remeda";
|
|
7
|
-
import { P as a } from "./PropsContextProvider-BcOGMJkn.js";
|
|
8
|
-
function m(t) {
|
|
9
|
-
return !!t && typeof t == "object" && "__dynamicProp" in t;
|
|
10
|
-
}
|
|
11
|
-
const C = {
|
|
12
|
-
Action: !0,
|
|
13
|
-
Avatar: !0,
|
|
14
|
-
Button: !0,
|
|
15
|
-
ButtonGroup: !0,
|
|
16
|
-
Content: !0,
|
|
17
|
-
ContextMenu: !0,
|
|
18
|
-
CopyButton: !0,
|
|
19
|
-
FieldDescription: !0,
|
|
20
|
-
FieldError: !0,
|
|
21
|
-
Header: !0,
|
|
22
|
-
Heading: !0,
|
|
23
|
-
Icon: !0,
|
|
24
|
-
Image: !0,
|
|
25
|
-
Initials: !0,
|
|
26
|
-
InlineAlert: !0,
|
|
27
|
-
Label: !0,
|
|
28
|
-
LayoutCard: !0,
|
|
29
|
-
Link: !0,
|
|
30
|
-
Radio: !0,
|
|
31
|
-
StatusBadge: !0,
|
|
32
|
-
Switch: !0,
|
|
33
|
-
TestComponent: !0,
|
|
34
|
-
Text: !0
|
|
35
|
-
}, f = Object.keys(
|
|
36
|
-
C
|
|
37
|
-
);
|
|
38
|
-
function i(t) {
|
|
39
|
-
return typeof t == "string" && f.includes(t);
|
|
40
|
-
}
|
|
41
|
-
function l(t) {
|
|
42
|
-
return !i(t);
|
|
43
|
-
}
|
|
44
|
-
const y = (t, r) => {
|
|
45
|
-
const e = {};
|
|
46
|
-
for (const n in t)
|
|
47
|
-
if (l(n)) {
|
|
48
|
-
const o = t[n];
|
|
49
|
-
m(o) && (e[n] = o.__dynamicProp(r));
|
|
50
|
-
}
|
|
51
|
-
return e;
|
|
52
|
-
};
|
|
53
|
-
function P(t) {
|
|
54
|
-
return !!t && typeof t == "object" && "children" in t && !!t.children;
|
|
55
|
-
}
|
|
56
|
-
const x = (t) => d(t, (r, e) => i(e)), h = (t, r) => {
|
|
57
|
-
if (!P(r))
|
|
58
|
-
return {};
|
|
59
|
-
const e = r.children;
|
|
60
|
-
if (!Array.isArray(e) && !c(e))
|
|
61
|
-
return {};
|
|
62
|
-
const n = x(t);
|
|
63
|
-
return Object.keys(n).length === 0 ? {} : {
|
|
64
|
-
children: /* @__PURE__ */ p.createElement(a, { props: n }, r.children)
|
|
65
|
-
};
|
|
66
|
-
}, A = (t, r) => {
|
|
67
|
-
const e = u()[t], n = e ? y(e, r) : void 0, o = e ? h(e, r) : void 0;
|
|
68
|
-
return s(
|
|
69
|
-
e,
|
|
70
|
-
r,
|
|
71
|
-
n,
|
|
72
|
-
o
|
|
73
|
-
);
|
|
74
|
-
};
|
|
75
|
-
export {
|
|
76
|
-
A as u
|
|
77
|
-
};
|