@altinn/altinn-components 0.41.4 → 0.41.6
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/assets/MenuItemBase.css +1 -1
- package/dist/assets/MenuOption.css +1 -1
- package/dist/components/Account/AccountList.js +20 -32
- package/dist/components/Account/AccountMenu.js +18 -16
- package/dist/components/Avatar/AvatarGroup.js +12 -12
- package/dist/components/List/ListItemBase.js +35 -33
- package/dist/components/Menu/MenuBase.js +17 -15
- package/dist/components/Menu/MenuItem.js +47 -46
- package/dist/components/Menu/MenuItemBase.js +38 -38
- package/dist/components/Menu/MenuItemLabel.js +36 -42
- package/dist/components/Menu/MenuOption.js +46 -46
- package/dist/components/Settings/SettingsItem.js +42 -27
- package/dist/components/Settings/SettingsItemBase.js +29 -28
- package/dist/components/Settings/SettingsModal.js +33 -9
- package/dist/components/Toolbar/ToolbarOptions.js +9 -9
- package/dist/components/Typography/Heading.js +30 -28
- package/dist/hooks/useMenu.js +31 -31
- package/dist/types/lib/components/Account/AccountList.d.ts +1 -1
- package/dist/types/lib/components/Account/AccountList.stories.d.ts +1 -1
- package/dist/types/lib/components/Account/AccountListItem.stories.d.ts +1 -0
- package/dist/types/lib/components/List/ListItemBase.d.ts +2 -1
- package/dist/types/lib/components/Menu/MenuBase.d.ts +2 -1
- package/dist/types/lib/components/Menu/MenuItem.d.ts +1 -1
- package/dist/types/lib/components/Menu/MenuItemLabel.d.ts +2 -3
- package/dist/types/lib/components/Menu/MenuOption.d.ts +3 -3
- package/dist/types/lib/components/Settings/SettingsItem.d.ts +9 -2
- package/dist/types/lib/components/Settings/SettingsItem.stories.d.ts +4 -1
- package/dist/types/lib/components/Settings/SettingsItemBase.d.ts +1 -1
- package/dist/types/lib/components/Settings/SettingsModal.d.ts +6 -2
- package/dist/types/lib/components/Settings/SettingsModal.stories.d.ts +10 -2
- package/dist/types/lib/components/Toolbar/ToolbarFilter.stories.d.ts +1 -3
- package/dist/types/lib/components/Transmission/Transmission.stories.d.ts +1 -0
- package/dist/types/lib/components/Typography/Heading.d.ts +3 -2
- package/dist/types/lib/components/Typography/Heading.stories.d.ts +1 -1
- package/package.json +1 -1
|
@@ -1,81 +1,75 @@
|
|
|
1
|
-
import { jsx as
|
|
2
|
-
import { c as
|
|
1
|
+
import { jsx as s, jsxs as g, Fragment as b } from "react/jsx-runtime";
|
|
2
|
+
import { c as d } from "../../index-L8X2o7IH.js";
|
|
3
3
|
import { isValidElement as x } from "react";
|
|
4
|
-
import { Heading as
|
|
5
|
-
import { Badge as _ } from "../Badge/Badge.js";
|
|
4
|
+
import { Heading as c } from "../Typography/Heading.js";
|
|
6
5
|
import "../RootProvider/RootProvider.js";
|
|
7
|
-
import { isHeadingProps as
|
|
6
|
+
import { isHeadingProps as o } from "../List/ListItemLabel.js";
|
|
8
7
|
import "../Snackbar/useSnackbar.js";
|
|
9
|
-
import '../../assets/MenuItemLabel.css';const
|
|
10
|
-
label:
|
|
11
|
-
title:
|
|
8
|
+
import '../../assets/MenuItemLabel.css';const h = "_label_1gf5h_1", _ = "_title_1gf5h_22", p = {
|
|
9
|
+
label: h,
|
|
10
|
+
title: _
|
|
12
11
|
};
|
|
13
|
-
function
|
|
12
|
+
function u(r) {
|
|
14
13
|
return typeof r == "string" || typeof r == "number" || typeof r == "boolean" || r === null || x(r);
|
|
15
14
|
}
|
|
16
|
-
const
|
|
15
|
+
const y = (r) => {
|
|
17
16
|
const n = {
|
|
18
17
|
as: "span"
|
|
19
18
|
};
|
|
20
|
-
return
|
|
19
|
+
return o(r) ? { ...n, ...r } : u(r) ? {
|
|
21
20
|
...n,
|
|
22
21
|
children: r
|
|
23
22
|
} : null;
|
|
24
|
-
},
|
|
23
|
+
}, P = (r) => {
|
|
25
24
|
const n = {
|
|
26
25
|
as: "span",
|
|
27
26
|
weight: "normal",
|
|
28
27
|
variant: "subtle"
|
|
29
28
|
};
|
|
30
|
-
return
|
|
29
|
+
return o(r) ? { ...n, ...r } : u(r) ? {
|
|
31
30
|
...n,
|
|
32
31
|
children: r
|
|
33
32
|
} : null;
|
|
34
33
|
};
|
|
35
|
-
function
|
|
34
|
+
function z(r) {
|
|
36
35
|
if (typeof r == "string")
|
|
37
36
|
return r;
|
|
38
|
-
if (
|
|
37
|
+
if (o(r))
|
|
39
38
|
return r.children;
|
|
40
39
|
}
|
|
41
|
-
const
|
|
40
|
+
const A = ({
|
|
42
41
|
className: r,
|
|
43
42
|
size: n = "sm",
|
|
44
|
-
title:
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
loading: c,
|
|
43
|
+
title: a,
|
|
44
|
+
description: i,
|
|
45
|
+
highlightWords: l,
|
|
46
|
+
loading: m,
|
|
49
47
|
children: f
|
|
50
48
|
}) => {
|
|
51
|
-
const
|
|
52
|
-
return /* @__PURE__ */
|
|
53
|
-
|
|
54
|
-
|
|
49
|
+
const t = a && y(a), e = i && P(i);
|
|
50
|
+
return /* @__PURE__ */ s("span", { className: d(p.label, r), "data-size": n, children: f || /* @__PURE__ */ g(b, { children: [
|
|
51
|
+
t && /* @__PURE__ */ s(
|
|
52
|
+
c,
|
|
55
53
|
{
|
|
56
|
-
...
|
|
57
|
-
loading:
|
|
58
|
-
highlightWords:
|
|
59
|
-
className:
|
|
60
|
-
weight:
|
|
61
|
-
children: [
|
|
62
|
-
/* @__PURE__ */ t("span", { children: e.children }),
|
|
63
|
-
l && /* @__PURE__ */ t(_, { ...l })
|
|
64
|
-
]
|
|
54
|
+
...t,
|
|
55
|
+
loading: m,
|
|
56
|
+
highlightWords: l,
|
|
57
|
+
className: p.title,
|
|
58
|
+
weight: t != null && t.weight || n === "lg" ? "medium" : "normal"
|
|
65
59
|
}
|
|
66
60
|
),
|
|
67
|
-
|
|
68
|
-
|
|
61
|
+
e && /* @__PURE__ */ s(
|
|
62
|
+
c,
|
|
69
63
|
{
|
|
70
|
-
...
|
|
71
|
-
loading:
|
|
72
|
-
highlightWords:
|
|
73
|
-
size:
|
|
64
|
+
...e,
|
|
65
|
+
loading: m,
|
|
66
|
+
highlightWords: l,
|
|
67
|
+
size: e.size || n === "lg" ? "xs" : "xxs"
|
|
74
68
|
}
|
|
75
69
|
)
|
|
76
70
|
] }) });
|
|
77
71
|
};
|
|
78
72
|
export {
|
|
79
|
-
|
|
80
|
-
|
|
73
|
+
A as MenuItemLabel,
|
|
74
|
+
z as getAriaLabelFromTitle
|
|
81
75
|
};
|
|
@@ -1,83 +1,83 @@
|
|
|
1
|
-
import { jsx as
|
|
1
|
+
import { jsx as s, jsxs as d } from "react/jsx-runtime";
|
|
2
2
|
import "../../index-L8X2o7IH.js";
|
|
3
3
|
import "react";
|
|
4
|
-
import { Badge as p } from "../Badge/Badge.js";
|
|
5
4
|
import "../RootProvider/RootProvider.js";
|
|
6
|
-
import { MenuItem as
|
|
5
|
+
import { MenuItem as _ } from "./MenuItem.js";
|
|
7
6
|
import "../Snackbar/useSnackbar.js";
|
|
8
|
-
import { S as
|
|
9
|
-
import '../../assets/MenuOption.css';const
|
|
10
|
-
label:
|
|
11
|
-
title:
|
|
7
|
+
import { S as p } from "../../Checkmark-Byz_C9x4.js";
|
|
8
|
+
import '../../assets/MenuOption.css';const N = "_label_sfsij_1", j = "_title_sfsij_13", k = "_count_sfsij_20", v = "_radio_sfsij_25", I = "_checkbox_sfsij_26", M = "_icon_sfsij_59", a = {
|
|
9
|
+
label: N,
|
|
10
|
+
title: j,
|
|
11
|
+
count: k,
|
|
12
12
|
radio: v,
|
|
13
13
|
checkbox: I,
|
|
14
14
|
icon: M
|
|
15
|
-
},
|
|
16
|
-
size:
|
|
17
|
-
type:
|
|
18
|
-
name:
|
|
19
|
-
active:
|
|
20
|
-
value:
|
|
21
|
-
label:
|
|
22
|
-
title:
|
|
15
|
+
}, C = ({
|
|
16
|
+
size: t = "md",
|
|
17
|
+
type: h,
|
|
18
|
+
name: S,
|
|
19
|
+
active: i,
|
|
20
|
+
value: g,
|
|
21
|
+
label: n,
|
|
22
|
+
title: u,
|
|
23
23
|
description: b,
|
|
24
|
-
icon:
|
|
25
|
-
|
|
26
|
-
checked:
|
|
27
|
-
disabled:
|
|
24
|
+
icon: f,
|
|
25
|
+
count: e = 0,
|
|
26
|
+
checked: c = !1,
|
|
27
|
+
disabled: o,
|
|
28
28
|
onMouseEnter: w,
|
|
29
|
-
onClick:
|
|
29
|
+
onClick: r,
|
|
30
30
|
role: l,
|
|
31
31
|
...m
|
|
32
32
|
}) => {
|
|
33
|
-
const
|
|
34
|
-
switch (
|
|
33
|
+
const x = () => {
|
|
34
|
+
switch (h) {
|
|
35
35
|
case "checkbox":
|
|
36
36
|
return /* @__PURE__ */ d("span", { className: a.label, children: [
|
|
37
|
-
/* @__PURE__ */
|
|
38
|
-
/* @__PURE__ */
|
|
37
|
+
/* @__PURE__ */ s("span", { className: a.checkbox, "data-checked": c, children: /* @__PURE__ */ s(p, { className: a.icon, "aria-hidden": !0 }) }),
|
|
38
|
+
/* @__PURE__ */ s("span", { className: a.title, children: n }),
|
|
39
|
+
e > 0 && /* @__PURE__ */ s("span", { className: a.count, children: e })
|
|
39
40
|
] });
|
|
40
41
|
case "radio":
|
|
41
42
|
return /* @__PURE__ */ d("span", { className: a.label, children: [
|
|
42
|
-
/* @__PURE__ */
|
|
43
|
-
/* @__PURE__ */
|
|
43
|
+
/* @__PURE__ */ s("span", { className: a.radio, "data-checked": c, children: /* @__PURE__ */ s(p, { className: a.icon, "aria-hidden": !0 }) }),
|
|
44
|
+
/* @__PURE__ */ s("span", { className: a.title, children: n }),
|
|
45
|
+
e > 0 && /* @__PURE__ */ s("span", { className: a.count, children: e })
|
|
44
46
|
] });
|
|
45
47
|
}
|
|
46
48
|
};
|
|
47
|
-
return
|
|
48
|
-
|
|
49
|
+
return n ? /* @__PURE__ */ s(
|
|
50
|
+
_,
|
|
49
51
|
{
|
|
50
|
-
disabled:
|
|
51
|
-
selected:
|
|
52
|
-
size:
|
|
52
|
+
disabled: o,
|
|
53
|
+
selected: c,
|
|
54
|
+
size: t,
|
|
53
55
|
as: "div",
|
|
54
|
-
active:
|
|
56
|
+
active: i,
|
|
55
57
|
tabIndex: -1,
|
|
56
|
-
onClick:
|
|
58
|
+
onClick: r,
|
|
57
59
|
role: l,
|
|
58
|
-
label: /* @__PURE__ */
|
|
59
|
-
controls: s && /* @__PURE__ */ e(p, { ...s }),
|
|
60
|
+
label: /* @__PURE__ */ s(x, {}),
|
|
60
61
|
...m
|
|
61
62
|
}
|
|
62
|
-
) : /* @__PURE__ */
|
|
63
|
-
|
|
63
|
+
) : /* @__PURE__ */ s(
|
|
64
|
+
_,
|
|
64
65
|
{
|
|
65
|
-
disabled:
|
|
66
|
-
selected:
|
|
67
|
-
size:
|
|
66
|
+
disabled: o,
|
|
67
|
+
selected: c,
|
|
68
|
+
size: t,
|
|
68
69
|
as: "div",
|
|
69
|
-
active:
|
|
70
|
+
active: i,
|
|
70
71
|
tabIndex: -1,
|
|
71
|
-
onClick:
|
|
72
|
+
onClick: r,
|
|
72
73
|
role: l,
|
|
73
|
-
icon:
|
|
74
|
-
title:
|
|
74
|
+
icon: f,
|
|
75
|
+
title: u,
|
|
75
76
|
description: b,
|
|
76
|
-
controls: s && /* @__PURE__ */ e(p, { ...s }),
|
|
77
77
|
...m
|
|
78
78
|
}
|
|
79
79
|
);
|
|
80
80
|
};
|
|
81
81
|
export {
|
|
82
|
-
|
|
82
|
+
C as MenuOption
|
|
83
83
|
};
|
|
@@ -1,54 +1,69 @@
|
|
|
1
|
-
import { jsx as
|
|
1
|
+
import { jsx as i } from "react/jsx-runtime";
|
|
2
2
|
import "../../index-L8X2o7IH.js";
|
|
3
|
-
import { useState as
|
|
3
|
+
import { useState as b } from "react";
|
|
4
4
|
import "../RootProvider/RootProvider.js";
|
|
5
5
|
import "../Snackbar/useSnackbar.js";
|
|
6
|
-
import { Input as
|
|
7
|
-
import { SettingsItemBase as
|
|
8
|
-
import { SettingsModal as
|
|
9
|
-
const
|
|
6
|
+
import { Input as x } from "../Forms/Input.js";
|
|
7
|
+
import { SettingsItemBase as n } from "./SettingsItemBase.js";
|
|
8
|
+
import { SettingsModal as I } from "./SettingsModal.js";
|
|
9
|
+
const O = ({
|
|
10
10
|
loading: a,
|
|
11
|
-
variant:
|
|
12
|
-
id:
|
|
13
|
-
name:
|
|
14
|
-
checked:
|
|
15
|
-
onChange:
|
|
16
|
-
|
|
11
|
+
variant: f = "default",
|
|
12
|
+
id: c = "settings",
|
|
13
|
+
name: m,
|
|
14
|
+
checked: g,
|
|
15
|
+
onChange: h,
|
|
16
|
+
modalProps: e,
|
|
17
|
+
children: v,
|
|
17
18
|
...t
|
|
18
19
|
}) => {
|
|
19
|
-
const [
|
|
20
|
+
const [l, u] = b(!1);
|
|
20
21
|
if (a)
|
|
21
|
-
return /* @__PURE__ */
|
|
22
|
-
switch (
|
|
22
|
+
return /* @__PURE__ */ i(n, { icon: t == null ? void 0 : t.icon, title: t == null ? void 0 : t.title, loading: !0 });
|
|
23
|
+
switch (f) {
|
|
23
24
|
case "switch":
|
|
24
|
-
return /* @__PURE__ */
|
|
25
|
-
|
|
25
|
+
return /* @__PURE__ */ i(
|
|
26
|
+
n,
|
|
26
27
|
{
|
|
27
28
|
...t,
|
|
28
|
-
title:
|
|
29
|
+
title: {
|
|
30
|
+
id: c,
|
|
31
|
+
as: "label",
|
|
32
|
+
children: [t == null ? void 0 : t.title, t == null ? void 0 : t.value].join(": ")
|
|
33
|
+
},
|
|
29
34
|
value: void 0,
|
|
30
35
|
interactive: !1,
|
|
31
|
-
controls: /* @__PURE__ */
|
|
32
|
-
|
|
36
|
+
controls: /* @__PURE__ */ i(
|
|
37
|
+
x,
|
|
33
38
|
{
|
|
34
39
|
type: "checkbox",
|
|
35
40
|
role: "switch",
|
|
36
|
-
"aria-labelledby":
|
|
37
|
-
name:
|
|
41
|
+
"aria-labelledby": c,
|
|
42
|
+
name: m,
|
|
38
43
|
value: t == null ? void 0 : t.value,
|
|
39
|
-
checked:
|
|
40
|
-
onChange:
|
|
44
|
+
checked: g,
|
|
45
|
+
onChange: h,
|
|
41
46
|
style: { marginRight: "0.5em" }
|
|
42
47
|
}
|
|
43
48
|
)
|
|
44
49
|
}
|
|
45
50
|
);
|
|
46
51
|
case "modal":
|
|
47
|
-
return /* @__PURE__ */
|
|
52
|
+
return /* @__PURE__ */ i(n, { ...t, as: "button", linkIcon: !0, onClick: () => u(!0), expanded: l, children: l && /* @__PURE__ */ i(
|
|
53
|
+
I,
|
|
54
|
+
{
|
|
55
|
+
...e,
|
|
56
|
+
icon: (e == null ? void 0 : e.icon) || (t == null ? void 0 : t.icon),
|
|
57
|
+
title: (e == null ? void 0 : e.title) || (t == null ? void 0 : t.title),
|
|
58
|
+
open: l,
|
|
59
|
+
onClose: () => u(!1),
|
|
60
|
+
children: v
|
|
61
|
+
}
|
|
62
|
+
) });
|
|
48
63
|
default:
|
|
49
|
-
return /* @__PURE__ */
|
|
64
|
+
return /* @__PURE__ */ i(n, { ...t });
|
|
50
65
|
}
|
|
51
66
|
};
|
|
52
67
|
export {
|
|
53
|
-
|
|
68
|
+
O as SettingsItem
|
|
54
69
|
};
|
|
@@ -1,47 +1,48 @@
|
|
|
1
|
-
import { jsxs as
|
|
1
|
+
import { jsxs as d, jsx as i } from "react/jsx-runtime";
|
|
2
2
|
import "../../index-L8X2o7IH.js";
|
|
3
3
|
import "react";
|
|
4
4
|
import "../RootProvider/RootProvider.js";
|
|
5
|
-
import { getAriaLabelFromTitle as
|
|
6
|
-
import { ListItemBase as
|
|
7
|
-
import { ListItemHeader as
|
|
8
|
-
import { ListItemLabel as
|
|
5
|
+
import { getAriaLabelFromTitle as f } from "../Menu/MenuItemLabel.js";
|
|
6
|
+
import { ListItemBase as g } from "../List/ListItemBase.js";
|
|
7
|
+
import { ListItemHeader as I } from "../List/ListItemHeader.js";
|
|
8
|
+
import { ListItemLabel as k } from "../List/ListItemLabel.js";
|
|
9
9
|
import "../Snackbar/useSnackbar.js";
|
|
10
|
-
import '../../assets/SettingsItemBase.css';const
|
|
11
|
-
item:
|
|
12
|
-
label:
|
|
13
|
-
header:
|
|
14
|
-
},
|
|
10
|
+
import '../../assets/SettingsItemBase.css';const N = "_item_lk1g7_1", j = "_label_lk1g7_20", x = "_header_lk1g7_24", e = {
|
|
11
|
+
item: N,
|
|
12
|
+
label: j,
|
|
13
|
+
header: x
|
|
14
|
+
}, v = ({
|
|
15
|
+
ref: s,
|
|
15
16
|
loading: t,
|
|
16
|
-
color:
|
|
17
|
-
size:
|
|
17
|
+
color: l,
|
|
18
|
+
size: o,
|
|
18
19
|
expanded: r,
|
|
19
|
-
icon:
|
|
20
|
-
label:
|
|
20
|
+
icon: c,
|
|
21
|
+
label: n,
|
|
21
22
|
title: m,
|
|
22
|
-
value:
|
|
23
|
-
description:
|
|
24
|
-
children:
|
|
25
|
-
highlightWords:
|
|
23
|
+
value: _,
|
|
24
|
+
description: b,
|
|
25
|
+
children: h,
|
|
26
|
+
highlightWords: p,
|
|
26
27
|
...a
|
|
27
28
|
}) => {
|
|
28
|
-
const
|
|
29
|
-
return /* @__PURE__ */
|
|
30
|
-
/* @__PURE__ */ i(
|
|
31
|
-
|
|
29
|
+
const L = a.ariaLabel || f(m);
|
|
30
|
+
return /* @__PURE__ */ d(g, { ref: s, className: e.item, color: l, size: o, expanded: r, children: [
|
|
31
|
+
/* @__PURE__ */ i(I, { ...a, loading: t, ariaLabel: L, className: e.header, icon: c, children: /* @__PURE__ */ i(
|
|
32
|
+
k,
|
|
32
33
|
{
|
|
33
34
|
loading: t,
|
|
34
|
-
highlightWords:
|
|
35
|
+
highlightWords: p,
|
|
35
36
|
className: e.label,
|
|
36
37
|
title: m,
|
|
37
|
-
value:
|
|
38
|
-
description:
|
|
39
|
-
children:
|
|
38
|
+
value: _,
|
|
39
|
+
description: b,
|
|
40
|
+
children: n
|
|
40
41
|
}
|
|
41
42
|
) }),
|
|
42
|
-
r &&
|
|
43
|
+
r && h
|
|
43
44
|
] });
|
|
44
45
|
};
|
|
45
46
|
export {
|
|
46
|
-
|
|
47
|
+
v as SettingsItemBase
|
|
47
48
|
};
|
|
@@ -1,15 +1,39 @@
|
|
|
1
|
-
import { jsxs as e, jsx as
|
|
1
|
+
import { jsxs as e, jsx as d } from "react/jsx-runtime";
|
|
2
|
+
import { createElement as x } from "react";
|
|
2
3
|
import "../../index-L8X2o7IH.js";
|
|
3
|
-
import "
|
|
4
|
+
import { Button as g } from "../Button/Button.js";
|
|
5
|
+
import { ButtonGroup as j } from "../Button/ButtonGroup.js";
|
|
4
6
|
import "../RootProvider/RootProvider.js";
|
|
5
7
|
import "../Snackbar/useSnackbar.js";
|
|
6
|
-
import { ModalBase as
|
|
7
|
-
import { ModalHeader as
|
|
8
|
-
import { ModalBody as
|
|
9
|
-
const
|
|
10
|
-
|
|
11
|
-
|
|
8
|
+
import { ModalBase as y } from "../Modal/ModalBase.js";
|
|
9
|
+
import { ModalHeader as E } from "../Modal/ModalHeader.js";
|
|
10
|
+
import { ModalBody as G } from "../Modal/ModalBody.js";
|
|
11
|
+
const J = ({
|
|
12
|
+
icon: a,
|
|
13
|
+
title: c,
|
|
14
|
+
description: f,
|
|
15
|
+
open: l,
|
|
16
|
+
onClose: i,
|
|
17
|
+
buttons: m,
|
|
18
|
+
children: h,
|
|
19
|
+
...B
|
|
20
|
+
}) => /* @__PURE__ */ e(y, { ...B, open: l, onClose: i, children: [
|
|
21
|
+
/* @__PURE__ */ d(E, { icon: a, title: c, description: f, onClose: i }),
|
|
22
|
+
/* @__PURE__ */ e(G, { children: [
|
|
23
|
+
h,
|
|
24
|
+
(m == null ? void 0 : m.length) && /* @__PURE__ */ d(j, { children: m == null ? void 0 : m.map((r, M) => /* @__PURE__ */ x(
|
|
25
|
+
g,
|
|
26
|
+
{
|
|
27
|
+
...r,
|
|
28
|
+
key: M,
|
|
29
|
+
onClick: (k) => {
|
|
30
|
+
var p;
|
|
31
|
+
(p = r == null ? void 0 : r.onClick) == null || p.call(r, k), r != null && r.close && (i == null || i());
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
)) })
|
|
35
|
+
] })
|
|
12
36
|
] });
|
|
13
37
|
export {
|
|
14
|
-
|
|
38
|
+
J as SettingsModal
|
|
15
39
|
};
|
|
@@ -10,23 +10,23 @@ import { MenuHeader as w } from "../Menu/MenuHeader.js";
|
|
|
10
10
|
import { MenuBase as z, MenuList as D, MenuListItem as m } from "../Menu/MenuBase.js";
|
|
11
11
|
const G = ({
|
|
12
12
|
name: k,
|
|
13
|
-
search:
|
|
14
|
-
optionGroups:
|
|
13
|
+
search: c,
|
|
14
|
+
optionGroups: s = {},
|
|
15
15
|
options: I,
|
|
16
16
|
onChange: n,
|
|
17
17
|
optionType: L,
|
|
18
18
|
keyboardEvents: p,
|
|
19
19
|
onBlurCapture: T
|
|
20
20
|
}) => {
|
|
21
|
-
const
|
|
21
|
+
const a = K(null), { menu: j, setActiveIndex: B } = R({
|
|
22
22
|
items: I,
|
|
23
|
-
groups:
|
|
23
|
+
groups: s,
|
|
24
24
|
groupByKey: "groupId",
|
|
25
25
|
keyboardEvents: p,
|
|
26
|
-
ref:
|
|
26
|
+
ref: a
|
|
27
27
|
});
|
|
28
|
-
return /* @__PURE__ */ v(z, { variant: "default", ref:
|
|
29
|
-
|
|
28
|
+
return /* @__PURE__ */ v(z, { variant: "default", ref: a, children: [
|
|
29
|
+
c && /* @__PURE__ */ e(q, { ...c }),
|
|
30
30
|
/* @__PURE__ */ e(D, { role: "menu", onBlurCapture: T, children: j.map((t, l) => {
|
|
31
31
|
const O = (t == null ? void 0 : t.props) || {}, { title: d, divider: P = !0 } = O;
|
|
32
32
|
return /* @__PURE__ */ v(N, { children: [
|
|
@@ -37,7 +37,7 @@ const G = ({
|
|
|
37
37
|
return !((i = o.props) != null && i.hidden);
|
|
38
38
|
}).map((o, i) => {
|
|
39
39
|
var h;
|
|
40
|
-
const { active: A, onMouseEnter: F } = o, { groupId: u, onClick: E, value: f, checked: M, type: b, ...r } = o.props || {}, { expanded: H } = r, x = r.name || k, y = b || u && ((h =
|
|
40
|
+
const { active: A, onMouseEnter: F } = o, { groupId: u, onClick: E, value: f, checked: M, type: b, ...r } = o.props || {}, { expanded: H } = r, x = r.name || k, y = b || u && ((h = s[u]) == null ? void 0 : h.optionType) || L;
|
|
41
41
|
return /* @__PURE__ */ e(
|
|
42
42
|
m,
|
|
43
43
|
{
|
|
@@ -53,7 +53,7 @@ const G = ({
|
|
|
53
53
|
active: A,
|
|
54
54
|
tabIndex: p ? -1 : 0,
|
|
55
55
|
label: r.label,
|
|
56
|
-
|
|
56
|
+
count: r.count,
|
|
57
57
|
name: x,
|
|
58
58
|
type: y,
|
|
59
59
|
value: f,
|
|
@@ -1,43 +1,45 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { jsx as a } from "react/jsx-runtime";
|
|
3
|
-
import { c as
|
|
3
|
+
import { c as f } from "../../index-L8X2o7IH.js";
|
|
4
4
|
import "react";
|
|
5
|
-
import { Skeleton as
|
|
6
|
-
import { useHighlightedText as
|
|
5
|
+
import { Skeleton as u } from "../Skeleton/Skeleton.js";
|
|
6
|
+
import { useHighlightedText as H } from "./useHighlightedText.js";
|
|
7
7
|
import "../RootProvider/RootProvider.js";
|
|
8
8
|
import "../Snackbar/useSnackbar.js";
|
|
9
|
-
import '../../assets/Heading.css';const
|
|
10
|
-
heading:
|
|
11
|
-
},
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
9
|
+
import '../../assets/Heading.css';const _ = "_heading_1dyne_1", w = {
|
|
10
|
+
heading: _
|
|
11
|
+
}, b = ({
|
|
12
|
+
id: e,
|
|
13
|
+
loading: i,
|
|
14
|
+
highlightWords: o = [],
|
|
15
|
+
as: n = "h2",
|
|
15
16
|
size: t,
|
|
16
|
-
leading:
|
|
17
|
-
weight:
|
|
18
|
-
color:
|
|
19
|
-
variant:
|
|
20
|
-
maxRows:
|
|
21
|
-
className:
|
|
22
|
-
style:
|
|
23
|
-
children:
|
|
17
|
+
leading: r = "tight",
|
|
18
|
+
weight: d = "medium",
|
|
19
|
+
color: m,
|
|
20
|
+
variant: s,
|
|
21
|
+
maxRows: c,
|
|
22
|
+
className: h,
|
|
23
|
+
style: g,
|
|
24
|
+
children: l
|
|
24
25
|
}) => {
|
|
25
|
-
const
|
|
26
|
+
const p = n, x = H(l, o || []);
|
|
26
27
|
return /* @__PURE__ */ a(
|
|
27
|
-
|
|
28
|
+
p,
|
|
28
29
|
{
|
|
29
|
-
|
|
30
|
-
|
|
30
|
+
id: e,
|
|
31
|
+
className: f(w.heading, h),
|
|
32
|
+
style: g,
|
|
31
33
|
"data-size": t,
|
|
32
|
-
"data-leading":
|
|
33
|
-
"data-weight":
|
|
34
|
-
"data-color":
|
|
35
|
-
"data-variant": t === "xxs" && "default" ||
|
|
36
|
-
"data-max-rows":
|
|
37
|
-
children: /* @__PURE__ */ a(
|
|
34
|
+
"data-leading": r,
|
|
35
|
+
"data-weight": d,
|
|
36
|
+
"data-color": m,
|
|
37
|
+
"data-variant": t === "xxs" && "default" || s,
|
|
38
|
+
"data-max-rows": c,
|
|
39
|
+
children: /* @__PURE__ */ a(u, { loading: i, children: x })
|
|
38
40
|
}
|
|
39
41
|
);
|
|
40
42
|
};
|
|
41
43
|
export {
|
|
42
|
-
|
|
44
|
+
b as Heading
|
|
43
45
|
};
|