@altinn/altinn-components 0.28.2 → 0.29.1
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/PadlockLocked-CwhOOPnp.js +25 -0
- package/dist/assets/Badge.css +1 -1
- package/dist/assets/ButtonBase.css +1 -1
- package/dist/assets/ButtonIcon.css +1 -1
- package/dist/assets/Flex.css +1 -1
- package/dist/assets/GlobalMenuButton.css +1 -0
- package/dist/assets/Grid.css +1 -1
- package/dist/assets/Heading.css +1 -1
- package/dist/assets/List.css +1 -0
- package/dist/assets/ListItemControls.css +1 -1
- package/dist/assets/ListItemHeader.css +1 -1
- package/dist/assets/MenuItem.css +1 -0
- package/dist/assets/MenuItemBase.css +1 -1
- package/dist/assets/MenuItemLabel.css +1 -1
- package/dist/assets/MenuSearch.css +1 -1
- package/dist/assets/SearchField.css +1 -1
- package/dist/assets/SearchbarField.css +1 -0
- package/dist/assets/Section.css +1 -0
- package/dist/components/Account/AccountList.js +24 -0
- package/dist/components/Account/AccountListItem.js +58 -0
- package/dist/components/Account/AccountListItemControls.js +77 -0
- package/dist/components/Account/AccountMenu.js +56 -0
- package/dist/components/Account/index.js +8 -0
- package/dist/components/Badge/Badge.js +13 -3
- package/dist/components/Button/ButtonBase.js +17 -15
- package/dist/components/Button/ButtonIcon.js +14 -9
- package/dist/components/Button/IconButton.js +18 -16
- package/dist/components/ContextMenu/ContextMenu.js +45 -48
- package/dist/components/Forms/SearchField.js +34 -0
- package/dist/components/Forms/index.js +14 -12
- package/dist/components/GlobalMenu/CurrentAccount.js +27 -0
- package/dist/components/GlobalMenu/GlobalMenu.js +70 -77
- package/dist/components/GlobalMenu/GlobalMenuButton.js +50 -0
- package/dist/components/GlobalMenu/index.js +12 -12
- package/dist/components/Header/Header.js +25 -30
- package/dist/components/Header/HeaderButton.js +45 -64
- package/dist/components/List/List.js +9 -7
- package/dist/components/List/ListItemControls.js +1 -1
- package/dist/components/List/ListItemHeader.js +43 -43
- package/dist/components/List/ListItemLabel.js +36 -28
- package/dist/components/Menu/MenuItem.js +41 -41
- package/dist/components/Menu/MenuItemBase.js +35 -54
- package/dist/components/Menu/MenuItemLabel.js +58 -20
- package/dist/components/Menu/MenuOption.js +32 -41
- package/dist/components/Menu/MenuSearch.js +24 -43
- package/dist/components/Menu/index.js +24 -23
- package/dist/components/Page/Flex.js +5 -5
- package/dist/components/Page/Grid.js +24 -26
- package/dist/components/Page/Section.js +7 -5
- package/dist/components/Page/index.js +20 -22
- package/dist/components/Searchbar/Searchbar.js +6 -6
- package/dist/components/Searchbar/{SearchField.js → SearchbarField.js} +8 -8
- package/dist/components/Searchbar/index.js +6 -6
- package/dist/components/Settings/SettingsItem.js +27 -30
- package/dist/components/Toolbar/ToolbarAccountMenu.js +6 -6
- package/dist/components/Toolbar/ToolbarSearch.js +22 -43
- package/dist/components/Typography/Heading.js +7 -7
- package/dist/components/index.js +404 -401
- package/dist/index.js +404 -401
- package/dist/spacing.css +44 -8
- package/dist/types/lib/components/Account/Account.stories.d.ts +8 -0
- package/dist/types/lib/components/Account/AccountList.d.ts +10 -0
- package/dist/types/lib/components/Account/AccountList.stories.d.ts +18 -0
- package/dist/types/lib/components/Account/AccountListItem.d.ts +18 -0
- package/dist/types/lib/components/{Profile → Account}/AccountListItem.stories.d.ts +16 -6
- package/dist/types/lib/components/Account/AccountListItemControls.d.ts +17 -0
- package/dist/types/lib/components/Account/AccountMenu.d.ts +22 -0
- package/dist/types/lib/components/Account/AccountMenu.stories.d.ts +16 -0
- package/dist/types/lib/components/{Profile → Account}/index.d.ts +1 -0
- package/dist/types/lib/components/Badge/Badge.d.ts +4 -1
- package/dist/types/lib/components/Badge/Badge.stories.d.ts +1 -1
- package/dist/types/lib/components/Button/ButtonBase.d.ts +2 -1
- package/dist/types/lib/components/Button/ButtonIcon.d.ts +3 -2
- package/dist/types/lib/components/Button/IconButton.d.ts +2 -1
- package/dist/types/lib/components/ContextMenu/ContextMenu.d.ts +1 -3
- package/dist/types/lib/components/ContextMenu/ContextMenu.stories.d.ts +2 -1
- package/dist/types/lib/components/Forms/SearchField.d.ts +9 -0
- package/dist/types/lib/components/Forms/SearchField.stories.d.ts +16 -0
- package/dist/types/lib/components/Forms/index.d.ts +1 -0
- package/dist/types/lib/components/GlobalMenu/{AccountButton.d.ts → CurrentAccount.d.ts} +3 -3
- package/dist/types/lib/components/GlobalMenu/GlobalMenu.d.ts +4 -4
- package/dist/types/lib/components/GlobalMenu/GlobalMenu.stories.d.ts +9 -12
- package/dist/types/lib/components/GlobalMenu/GlobalMenuButton.d.ts +13 -0
- package/dist/types/lib/components/GlobalMenu/GlobalMenuButton.stories.d.ts +19 -0
- package/dist/types/lib/components/GlobalMenu/index.d.ts +3 -3
- package/dist/types/lib/components/Header/Header.stories.d.ts +8 -7
- package/dist/types/lib/components/Header/LocaleSwitcher.stories.d.ts +3 -1
- package/dist/types/lib/components/Layout/Layout.stories.d.ts +1 -0
- package/dist/types/lib/components/List/List.d.ts +1 -1
- package/dist/types/lib/components/List/List.stories.d.ts +1 -1
- package/dist/types/lib/components/List/ListItemLabel.d.ts +2 -1
- package/dist/types/lib/components/Menu/Menu.stories.d.ts +5 -0
- package/dist/types/lib/components/Menu/MenuItem.d.ts +6 -7
- package/dist/types/lib/components/Menu/MenuItemBase.d.ts +3 -5
- package/dist/types/lib/components/Menu/MenuItemLabel.d.ts +6 -4
- package/dist/types/lib/components/Menu/MenuSearch.d.ts +1 -1
- package/dist/types/lib/components/Menu/MenuSearch.stories.d.ts +1 -1
- package/dist/types/lib/components/Page/Breadcrumbs.stories.d.ts +19 -0
- package/dist/types/lib/components/Page/BreadcrumbsLink.d.ts +1 -1
- package/dist/types/lib/components/Page/Flex.d.ts +1 -1
- package/dist/types/lib/components/Page/Flex.stories.d.ts +17 -0
- package/dist/types/lib/components/Page/Grid.d.ts +5 -8
- package/dist/types/lib/components/Page/Grid.stories.d.ts +15 -0
- package/dist/types/lib/components/Page/List.stories.d.ts +17 -0
- package/dist/types/lib/components/Page/Section.d.ts +2 -1
- package/dist/types/lib/components/Page/index.d.ts +0 -1
- package/dist/types/lib/components/Search/SearchItem.d.ts +2 -2
- package/dist/types/lib/components/Searchbar/Searchbar.d.ts +2 -2
- package/dist/types/lib/components/Searchbar/{SearchField.d.ts → SearchbarField.d.ts} +2 -2
- package/dist/types/lib/components/Searchbar/index.d.ts +1 -1
- package/dist/types/lib/components/Settings/SettingsItem.d.ts +5 -6
- package/dist/types/lib/components/Settings/SettingsItem.stories.d.ts +8 -6
- package/dist/types/lib/components/Toolbar/Toolbar.stories.d.ts +1 -1
- package/dist/types/lib/components/Toolbar/ToolbarSearch.d.ts +2 -5
- package/dist/types/lib/components/Toolbar/ToolbarSearch.stories.d.ts +1 -0
- package/dist/types/lib/components/Transmission/Transmission.stories.d.ts +7 -7
- package/dist/types/lib/components/Typography/Heading.d.ts +1 -1
- package/dist/types/lib/components/index.d.ts +1 -1
- package/dist/types/lib/stories/Profile/Accounts.stories.d.ts +6 -11
- package/package.json +1 -1
- package/dist/assets/AccountButton.css +0 -1
- package/dist/assets/MenuOption.css +0 -1
- package/dist/assets/ToolbarSearch.css +0 -1
- package/dist/components/GlobalMenu/AccountButton.js +0 -58
- package/dist/components/GlobalMenu/AccountMenu.js +0 -72
- package/dist/components/Page/PageHeader.js +0 -55
- package/dist/components/Profile/AccountList.js +0 -12
- package/dist/components/Profile/AccountListItem.js +0 -88
- package/dist/components/Profile/index.js +0 -6
- package/dist/types/lib/components/GlobalMenu/AccountMenu.d.ts +0 -27
- package/dist/types/lib/components/GlobalMenu/AccountMenu.stories.d.ts +0 -19
- package/dist/types/lib/components/Menu/Examples.stories.d.ts +0 -97
- package/dist/types/lib/components/Page/PageHeader.d.ts +0 -18
- package/dist/types/lib/components/Page/PageHeader.stories.d.ts +0 -16
- package/dist/types/lib/components/Profile/AccountList.d.ts +0 -5
- package/dist/types/lib/components/Profile/AccountListItem.d.ts +0 -12
|
@@ -1,72 +1,53 @@
|
|
|
1
|
-
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import { Badge as f } from "../Badge/Badge.js";
|
|
1
|
+
import { jsxs as _, jsx as o } from "react/jsx-runtime";
|
|
2
|
+
import { c as s } from "../../index-L8X2o7IH.js";
|
|
3
|
+
import { Avatar as b } from "../Avatar/Avatar.js";
|
|
4
|
+
import { AvatarGroup as g } from "../Avatar/AvatarGroup.js";
|
|
5
|
+
import { Badge as a } from "../Badge/Badge.js";
|
|
7
6
|
import { ButtonBase as u } from "../Button/ButtonBase.js";
|
|
8
|
-
import
|
|
9
|
-
import {
|
|
10
|
-
import { Icon as b } from "../Icon/Icon.js";
|
|
7
|
+
import "react";
|
|
8
|
+
import { Icon as f } from "../Icon/Icon.js";
|
|
11
9
|
import "../RootProvider/RootProvider.js";
|
|
12
10
|
import "../Searchbar/AutocompleteBase.js";
|
|
13
11
|
import "../Snackbar/useSnackbar.js";
|
|
14
|
-
import { S as
|
|
15
|
-
import {
|
|
16
|
-
import '../../assets/HeaderButton.css';
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
label: q,
|
|
36
|
-
icon: E,
|
|
37
|
-
avatarGroup: S,
|
|
38
|
-
loginIcon: B,
|
|
39
|
-
closeIcon: z,
|
|
40
|
-
badge: G
|
|
41
|
-
}, K = ({
|
|
42
|
-
className: o,
|
|
43
|
-
as: c = "button",
|
|
44
|
-
color: r = "accent",
|
|
45
|
-
variant: e = "solid",
|
|
46
|
-
avatar: n,
|
|
47
|
-
avatarGroup: i,
|
|
48
|
-
icon: h = x,
|
|
49
|
-
expanded: g,
|
|
50
|
-
label: a = "Menu",
|
|
51
|
-
badge: s,
|
|
12
|
+
import { S as I } from "../../XMark-DIqxCTTQ.js";
|
|
13
|
+
import { S as q } from "../../PadlockLocked-CwhOOPnp.js";
|
|
14
|
+
import '../../assets/HeaderButton.css';const S = "_button_1p2eq_1", x = "_label_1p2eq_12", y = "_icon_1p2eq_18", B = "_avatarGroup_1p2eq_28", G = "_loginIcon_1p2eq_37", k = "_closeIcon_1p2eq_42", j = "_badge_1p2eq_46", e = {
|
|
15
|
+
button: S,
|
|
16
|
+
label: x,
|
|
17
|
+
icon: y,
|
|
18
|
+
avatarGroup: B,
|
|
19
|
+
loginIcon: G,
|
|
20
|
+
closeIcon: k,
|
|
21
|
+
badge: j
|
|
22
|
+
}, O = ({
|
|
23
|
+
className: l,
|
|
24
|
+
as: t = "button",
|
|
25
|
+
color: m = "accent",
|
|
26
|
+
variant: i = "solid",
|
|
27
|
+
avatar: c,
|
|
28
|
+
avatarGroup: d,
|
|
29
|
+
icon: N = q,
|
|
30
|
+
expanded: h,
|
|
31
|
+
label: r = "Menu",
|
|
32
|
+
badge: n,
|
|
52
33
|
...p
|
|
53
|
-
}) =>
|
|
54
|
-
/* @__PURE__ */
|
|
55
|
-
/* @__PURE__ */
|
|
56
|
-
|
|
57
|
-
] }) :
|
|
58
|
-
/* @__PURE__ */
|
|
59
|
-
/* @__PURE__ */
|
|
60
|
-
|
|
61
|
-
] }) :
|
|
62
|
-
/* @__PURE__ */
|
|
63
|
-
/* @__PURE__ */
|
|
64
|
-
|
|
65
|
-
] }) : /* @__PURE__ */
|
|
66
|
-
/* @__PURE__ */
|
|
67
|
-
/* @__PURE__ */
|
|
68
|
-
|
|
34
|
+
}) => h ? /* @__PURE__ */ _(u, { ...p, as: t, variant: i, color: m, className: s(e.button, l), children: [
|
|
35
|
+
/* @__PURE__ */ o("span", { className: e.label, children: r }),
|
|
36
|
+
/* @__PURE__ */ o("span", { className: s(e.icon, e.closeIcon), children: /* @__PURE__ */ o(f, { svgElement: I }) }),
|
|
37
|
+
n && /* @__PURE__ */ o(a, { ...n, className: e.badge })
|
|
38
|
+
] }) : d ? /* @__PURE__ */ _(u, { ...p, as: t, variant: i, color: m, className: s(e.button, l), children: [
|
|
39
|
+
/* @__PURE__ */ o("span", { className: e.label, children: r }),
|
|
40
|
+
/* @__PURE__ */ o(g, { ...d, className: e.avatarGroup }),
|
|
41
|
+
n && /* @__PURE__ */ o(a, { ...n, className: e.badge })
|
|
42
|
+
] }) : c ? /* @__PURE__ */ _(u, { ...p, as: t, variant: i, color: m, className: s(e.button, l), children: [
|
|
43
|
+
/* @__PURE__ */ o("span", { className: e.label, children: r }),
|
|
44
|
+
/* @__PURE__ */ o(b, { type: c == null ? void 0 : c.type, name: c == null ? void 0 : c.name, style: { fontSize: "2.25rem" } }),
|
|
45
|
+
n && /* @__PURE__ */ o(a, { ...n, className: e.badge })
|
|
46
|
+
] }) : /* @__PURE__ */ _(u, { ...p, as: t, variant: i, color: m, className: s(e.button, l), children: [
|
|
47
|
+
/* @__PURE__ */ o("span", { className: e.label, children: r }),
|
|
48
|
+
/* @__PURE__ */ o("span", { className: s(e.icon, e.loginIcon), children: /* @__PURE__ */ o(f, { svgElement: N }) }),
|
|
49
|
+
n && /* @__PURE__ */ o(a, { ...n, className: e.badge })
|
|
69
50
|
] });
|
|
70
51
|
export {
|
|
71
|
-
|
|
52
|
+
O as HeaderButton
|
|
72
53
|
};
|
|
@@ -1,12 +1,14 @@
|
|
|
1
|
-
import { jsx as
|
|
2
|
-
import { createElement as
|
|
3
|
-
import "../../index-L8X2o7IH.js";
|
|
1
|
+
import { jsx as l } from "react/jsx-runtime";
|
|
2
|
+
import { createElement as c } from "react";
|
|
3
|
+
import { c as p } from "../../index-L8X2o7IH.js";
|
|
4
4
|
import "../RootProvider/RootProvider.js";
|
|
5
|
-
import { ListItem as
|
|
5
|
+
import { ListItem as n } from "./ListItem.js";
|
|
6
6
|
import "../Searchbar/AutocompleteBase.js";
|
|
7
7
|
import "../Snackbar/useSnackbar.js";
|
|
8
|
-
import { Flex as
|
|
9
|
-
const
|
|
8
|
+
import { Flex as a } from "../Page/Flex.js";
|
|
9
|
+
import '../../assets/List.css';const f = "_list_14rag_1", x = {
|
|
10
|
+
list: f
|
|
11
|
+
}, k = ({ children: r, className: o, spacing: i, items: m = [], ...s }) => /* @__PURE__ */ l(a, { direction: "col", as: "ul", spacing: i, className: p(x.list, o), ...s, children: r || m.map((t, e) => /* @__PURE__ */ c(n, { ...t, key: `item-${t.id ?? e}` })) });
|
|
10
12
|
export {
|
|
11
|
-
|
|
13
|
+
k as List
|
|
12
14
|
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as t } from "react/jsx-runtime";
|
|
2
2
|
import { c as r } from "../../index-L8X2o7IH.js";
|
|
3
|
-
import '../../assets/ListItemControls.css';const c = "
|
|
3
|
+
import '../../assets/ListItemControls.css';const c = "_controls_mvhfq_1", n = {
|
|
4
4
|
controls: c
|
|
5
5
|
}, e = ({ className: o, children: s }) => /* @__PURE__ */ t("div", { className: r(n.controls, o), children: s });
|
|
6
6
|
export {
|
|
@@ -1,89 +1,89 @@
|
|
|
1
1
|
import { jsxs as l, jsx as e, Fragment as E } from "react/jsx-runtime";
|
|
2
|
-
import { c as
|
|
3
|
-
import { useId as
|
|
4
|
-
import { Icon as
|
|
5
|
-
import { Badge as
|
|
2
|
+
import { c as g } from "../../index-L8X2o7IH.js";
|
|
3
|
+
import { useId as w, isValidElement as z } from "react";
|
|
4
|
+
import { Icon as D } from "../Icon/Icon.js";
|
|
5
|
+
import { Badge as F } from "../Badge/Badge.js";
|
|
6
6
|
import "../RootProvider/RootProvider.js";
|
|
7
|
-
import { ListItemLink as
|
|
8
|
-
import { ListItemLabel as
|
|
9
|
-
import { ListItemIcon as
|
|
10
|
-
import { ListItemControls as
|
|
11
|
-
import { ListItemSelect as
|
|
7
|
+
import { ListItemLink as H } from "./ListItemLink.js";
|
|
8
|
+
import { ListItemLabel as R } from "./ListItemLabel.js";
|
|
9
|
+
import { ListItemIcon as U } from "./ListItemIcon.js";
|
|
10
|
+
import { ListItemControls as V } from "./ListItemControls.js";
|
|
11
|
+
import { ListItemSelect as q } from "./ListItemSelect.js";
|
|
12
12
|
import "../Searchbar/AutocompleteBase.js";
|
|
13
13
|
import "../Snackbar/useSnackbar.js";
|
|
14
|
-
import { S as
|
|
15
|
-
import { S as
|
|
16
|
-
import '../../assets/ListItemHeader.css';const
|
|
17
|
-
header:
|
|
18
|
-
label:
|
|
19
|
-
linkIcon:
|
|
14
|
+
import { S as A, a as G } from "../../ChevronUp-DR4Lz2Jb.js";
|
|
15
|
+
import { S as J } from "../../ChevronRight-BbelnTke.js";
|
|
16
|
+
import '../../assets/ListItemHeader.css';const K = "_header_s4ghf_1", M = "_label_s4ghf_27", O = "_linkIcon_s4ghf_35", o = {
|
|
17
|
+
header: K,
|
|
18
|
+
label: M,
|
|
19
|
+
linkIcon: O
|
|
20
20
|
}, ne = ({
|
|
21
21
|
as: c,
|
|
22
22
|
interactive: p = !0,
|
|
23
|
-
color:
|
|
23
|
+
color: f,
|
|
24
24
|
loading: t,
|
|
25
|
-
disabled:
|
|
26
|
-
collapsible:
|
|
25
|
+
disabled: h,
|
|
26
|
+
collapsible: d,
|
|
27
27
|
linkIcon: I,
|
|
28
28
|
expanded: v,
|
|
29
29
|
select: s,
|
|
30
30
|
href: L,
|
|
31
31
|
onClick: _,
|
|
32
|
-
onKeyPress:
|
|
33
|
-
tabIndex:
|
|
32
|
+
onKeyPress: u,
|
|
33
|
+
tabIndex: S,
|
|
34
34
|
size: i,
|
|
35
|
-
title:
|
|
36
|
-
description:
|
|
37
|
-
icon:
|
|
35
|
+
title: b,
|
|
36
|
+
description: k,
|
|
37
|
+
icon: N,
|
|
38
38
|
active: m,
|
|
39
39
|
badge: r,
|
|
40
40
|
controls: n,
|
|
41
|
-
className:
|
|
42
|
-
children:
|
|
43
|
-
ariaLabel:
|
|
41
|
+
className: x,
|
|
42
|
+
children: y,
|
|
43
|
+
ariaLabel: C
|
|
44
44
|
}) => {
|
|
45
|
-
const a =
|
|
45
|
+
const a = d ? v ? A : G : I ? J : void 0, j = () => r && !t && typeof r == "object" && "label" in r ? /* @__PURE__ */ e(F, { ...r }) : z(r) ? r : null, B = w();
|
|
46
46
|
return /* @__PURE__ */ l(
|
|
47
47
|
"header",
|
|
48
48
|
{
|
|
49
|
-
className:
|
|
50
|
-
"data-color":
|
|
49
|
+
className: g(o.header, x),
|
|
50
|
+
"data-color": f,
|
|
51
51
|
"data-interactive": p,
|
|
52
52
|
"data-size": i,
|
|
53
53
|
"data-has-active-child": m,
|
|
54
54
|
children: [
|
|
55
55
|
/* @__PURE__ */ e(
|
|
56
|
-
|
|
56
|
+
H,
|
|
57
57
|
{
|
|
58
58
|
as: c,
|
|
59
59
|
href: L,
|
|
60
60
|
onClick: _,
|
|
61
|
-
onKeyPress:
|
|
62
|
-
tabIndex:
|
|
61
|
+
onKeyPress: u,
|
|
62
|
+
tabIndex: S,
|
|
63
63
|
loading: t,
|
|
64
|
-
disabled:
|
|
64
|
+
disabled: h || t,
|
|
65
65
|
active: m,
|
|
66
|
-
ariaLabel:
|
|
66
|
+
ariaLabel: C
|
|
67
67
|
}
|
|
68
68
|
),
|
|
69
|
-
s && /* @__PURE__ */ e(
|
|
70
|
-
/* @__PURE__ */ e(
|
|
69
|
+
s && /* @__PURE__ */ e(q, { ...s, className: o.select }),
|
|
70
|
+
/* @__PURE__ */ e(U, { loading: t, icon: N }),
|
|
71
71
|
/* @__PURE__ */ e(
|
|
72
|
-
|
|
72
|
+
R,
|
|
73
73
|
{
|
|
74
74
|
size: i,
|
|
75
75
|
loading: t,
|
|
76
|
-
title:
|
|
77
|
-
description:
|
|
76
|
+
title: b,
|
|
77
|
+
description: k,
|
|
78
78
|
id: B,
|
|
79
79
|
className: o.label,
|
|
80
|
-
children:
|
|
80
|
+
children: y
|
|
81
81
|
}
|
|
82
82
|
),
|
|
83
|
-
/* @__PURE__ */ e(
|
|
84
|
-
|
|
83
|
+
/* @__PURE__ */ e(V, { className: o.controls, children: n && !t ? /* @__PURE__ */ e("span", { style: { position: "relative" }, children: n }) : /* @__PURE__ */ l(E, { children: [
|
|
84
|
+
j(),
|
|
85
85
|
a && /* @__PURE__ */ e("span", { className: o.linkIcon, children: /* @__PURE__ */ e(
|
|
86
|
-
|
|
86
|
+
D,
|
|
87
87
|
{
|
|
88
88
|
svgElement: a,
|
|
89
89
|
style: {
|
|
@@ -1,53 +1,61 @@
|
|
|
1
|
-
import { jsx as
|
|
2
|
-
import { c as
|
|
3
|
-
import { isValidElement as
|
|
1
|
+
import { jsx as t, jsxs as b, Fragment as P } from "react/jsx-runtime";
|
|
2
|
+
import { c as x } from "../../index-L8X2o7IH.js";
|
|
3
|
+
import { isValidElement as _ } from "react";
|
|
4
4
|
import "../RootProvider/RootProvider.js";
|
|
5
|
-
import { Heading as
|
|
5
|
+
import { Heading as e } from "../Typography/Heading.js";
|
|
6
6
|
import "../Searchbar/AutocompleteBase.js";
|
|
7
7
|
import "../Snackbar/useSnackbar.js";
|
|
8
|
-
import '../../assets/ListItemLabel.css';const
|
|
9
|
-
label:
|
|
10
|
-
},
|
|
11
|
-
function
|
|
12
|
-
return typeof r == "string" || typeof r == "number" || typeof r == "boolean" || r === null ||
|
|
8
|
+
import '../../assets/ListItemLabel.css';const g = "_label_1aex5_1", h = {
|
|
9
|
+
label: g
|
|
10
|
+
}, j = (r) => typeof r == "object" && r !== null && "children" in r;
|
|
11
|
+
function z(r) {
|
|
12
|
+
return typeof r == "string" || typeof r == "number" || typeof r == "boolean" || r === null || _(r);
|
|
13
13
|
}
|
|
14
14
|
const y = (r) => {
|
|
15
|
-
const
|
|
15
|
+
const s = {
|
|
16
16
|
as: "h2",
|
|
17
17
|
size: "sm"
|
|
18
18
|
// leading: "tight",
|
|
19
19
|
};
|
|
20
|
-
return
|
|
21
|
-
...
|
|
20
|
+
return j(r) ? { ...s, ...r } : z(r) ? {
|
|
21
|
+
...s,
|
|
22
22
|
children: r
|
|
23
23
|
} : null;
|
|
24
|
-
},
|
|
25
|
-
const
|
|
24
|
+
}, d = (r) => {
|
|
25
|
+
const s = {
|
|
26
26
|
as: "h3",
|
|
27
27
|
size: "xs",
|
|
28
28
|
weight: "normal",
|
|
29
29
|
variant: "subtle"
|
|
30
30
|
// leading: "tight",
|
|
31
31
|
};
|
|
32
|
-
return
|
|
33
|
-
...
|
|
32
|
+
return j(r) ? { ...s, ...r } : z(r) ? {
|
|
33
|
+
...s,
|
|
34
34
|
children: r
|
|
35
35
|
} : null;
|
|
36
|
-
},
|
|
36
|
+
}, I = ({
|
|
37
37
|
loading: r = !1,
|
|
38
|
-
size:
|
|
39
|
-
title:
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
38
|
+
size: s,
|
|
39
|
+
title: o,
|
|
40
|
+
value: p,
|
|
41
|
+
description: c,
|
|
42
|
+
children: n,
|
|
43
|
+
id: l,
|
|
44
|
+
className: a
|
|
44
45
|
}) => {
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
46
|
+
if (o && p) {
|
|
47
|
+
const f = o && d(o), u = p && y(p);
|
|
48
|
+
return /* @__PURE__ */ t("span", { className: x(h.label, a), id: l, "data-size": s, children: n || /* @__PURE__ */ b(P, { children: [
|
|
49
|
+
f && /* @__PURE__ */ t(e, { ...f, loading: r }),
|
|
50
|
+
u && /* @__PURE__ */ t(e, { ...u, loading: r })
|
|
51
|
+
] }) });
|
|
52
|
+
}
|
|
53
|
+
const i = o && y(o), m = c && d(c);
|
|
54
|
+
return /* @__PURE__ */ t("span", { className: x(h.label, a), id: l, "data-size": s, children: n || /* @__PURE__ */ b(P, { children: [
|
|
55
|
+
i && /* @__PURE__ */ t(e, { ...i, loading: r }),
|
|
56
|
+
m && /* @__PURE__ */ t(e, { ...m, loading: r })
|
|
49
57
|
] }) });
|
|
50
58
|
};
|
|
51
59
|
export {
|
|
52
|
-
|
|
60
|
+
I as ListItemLabel
|
|
53
61
|
};
|
|
@@ -1,50 +1,50 @@
|
|
|
1
|
-
import { jsxs as
|
|
2
|
-
import {
|
|
3
|
-
import { MenuItemLabel as g } from "./MenuItemLabel.js";
|
|
4
|
-
import { MenuItemIcon as k } from "./MenuItemIcon.js";
|
|
1
|
+
import { jsxs as u, jsx as o, Fragment as k } from "react/jsx-runtime";
|
|
2
|
+
import { Icon as M } from "../Icon/Icon.js";
|
|
5
3
|
import "../../index-L8X2o7IH.js";
|
|
6
4
|
import "react";
|
|
7
5
|
import "../RootProvider/RootProvider.js";
|
|
6
|
+
import { MenuItemBase as b } from "./MenuItemBase.js";
|
|
7
|
+
import { MenuItemLabel as y } from "./MenuItemLabel.js";
|
|
8
|
+
import { MenuItemIcon as C } from "./MenuItemIcon.js";
|
|
8
9
|
import "../Searchbar/AutocompleteBase.js";
|
|
9
10
|
import "../Snackbar/useSnackbar.js";
|
|
10
|
-
import { S as
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
11
|
+
import { S as _, a as j } from "../../ChevronUp-DR4Lz2Jb.js";
|
|
12
|
+
import { S as w } from "../../ChevronRight-BbelnTke.js";
|
|
13
|
+
import '../../assets/MenuItem.css';const x = "_linkIcon_1owl4_57", m = {
|
|
14
|
+
linkIcon: x
|
|
15
|
+
}, J = ({
|
|
16
|
+
as: i = "a",
|
|
17
|
+
size: n = "md",
|
|
18
|
+
color: s,
|
|
19
|
+
theme: l,
|
|
20
|
+
collapsible: c,
|
|
21
|
+
expanded: r,
|
|
18
22
|
icon: p,
|
|
19
|
-
iconTheme:
|
|
20
|
-
iconBadge:
|
|
21
|
-
avatar: d,
|
|
22
|
-
avatarGroup: j,
|
|
23
|
+
iconTheme: a,
|
|
24
|
+
iconBadge: h,
|
|
23
25
|
title: I,
|
|
24
|
-
description:
|
|
25
|
-
badge:
|
|
26
|
-
|
|
27
|
-
linkIcon:
|
|
28
|
-
label:
|
|
29
|
-
...
|
|
30
|
-
}) =>
|
|
31
|
-
|
|
32
|
-
{
|
|
33
|
-
|
|
34
|
-
size:
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
}
|
|
47
|
-
);
|
|
26
|
+
description: v,
|
|
27
|
+
badge: f,
|
|
28
|
+
controls: e,
|
|
29
|
+
linkIcon: d,
|
|
30
|
+
label: g,
|
|
31
|
+
...S
|
|
32
|
+
}) => {
|
|
33
|
+
const t = c ? r ? _ : j : d ? w : void 0;
|
|
34
|
+
return /* @__PURE__ */ u(b, { as: i, size: n, theme: l, color: s, expanded: r, ...S, children: [
|
|
35
|
+
/* @__PURE__ */ o(C, { size: n, icon: p, theme: a, badge: h }),
|
|
36
|
+
/* @__PURE__ */ o(y, { title: I, description: v, size: n, badge: f, children: g }),
|
|
37
|
+
/* @__PURE__ */ o("span", { className: m.controls, children: e ? /* @__PURE__ */ o("span", { style: { position: "relative" }, children: e }) : /* @__PURE__ */ o(k, { children: t && /* @__PURE__ */ o("span", { className: m.linkIcon, children: /* @__PURE__ */ o(
|
|
38
|
+
M,
|
|
39
|
+
{
|
|
40
|
+
svgElement: t,
|
|
41
|
+
style: {
|
|
42
|
+
fontSize: "1.5rem"
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
) }) }) })
|
|
46
|
+
] });
|
|
47
|
+
};
|
|
48
48
|
export {
|
|
49
|
-
|
|
49
|
+
J as MenuItem
|
|
50
50
|
};
|
|
@@ -1,62 +1,43 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { c as
|
|
3
|
-
import
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
color: l,
|
|
18
|
-
theme: p,
|
|
19
|
-
size: d,
|
|
20
|
-
className: h,
|
|
21
|
-
href: x,
|
|
22
|
-
onClick: n,
|
|
23
|
-
onKeyPress: i,
|
|
24
|
-
tabIndex: j = 0,
|
|
1
|
+
import { jsx as m } from "react/jsx-runtime";
|
|
2
|
+
import { c as l } from "../../index-L8X2o7IH.js";
|
|
3
|
+
import '../../assets/MenuItemBase.css';const I = "_item_1k1tk_1", N = "_content_1k1tk_45", c = {
|
|
4
|
+
item: I,
|
|
5
|
+
content: N
|
|
6
|
+
}, z = ({
|
|
7
|
+
interactive: o = !0,
|
|
8
|
+
as: s,
|
|
9
|
+
color: r,
|
|
10
|
+
theme: d,
|
|
11
|
+
size: i,
|
|
12
|
+
className: p,
|
|
13
|
+
href: _,
|
|
14
|
+
onClick: t,
|
|
15
|
+
onKeyPress: e,
|
|
16
|
+
tabIndex: x = 0,
|
|
25
17
|
hidden: f,
|
|
26
|
-
selected:
|
|
27
|
-
disabled:
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
children: N
|
|
32
|
-
}) => /* @__PURE__ */ a(
|
|
33
|
-
_ || "a",
|
|
18
|
+
selected: h,
|
|
19
|
+
disabled: a = !1,
|
|
20
|
+
children: u
|
|
21
|
+
}) => /* @__PURE__ */ m(
|
|
22
|
+
s || "a",
|
|
34
23
|
{
|
|
35
|
-
tabIndex:
|
|
36
|
-
className:
|
|
37
|
-
"data-
|
|
38
|
-
"data-
|
|
39
|
-
"data-
|
|
24
|
+
tabIndex: a ? "-1" : x ?? 0,
|
|
25
|
+
className: l(c.item, p),
|
|
26
|
+
"data-interactive": o,
|
|
27
|
+
"data-size": i,
|
|
28
|
+
"data-color": r,
|
|
29
|
+
"data-theme": d,
|
|
40
30
|
"aria-hidden": f,
|
|
41
|
-
"aria-disabled":
|
|
42
|
-
"data-selected":
|
|
43
|
-
href:
|
|
44
|
-
onKeyPress: (
|
|
45
|
-
|
|
31
|
+
"aria-disabled": a,
|
|
32
|
+
"data-selected": h,
|
|
33
|
+
href: _,
|
|
34
|
+
onKeyPress: (n) => {
|
|
35
|
+
n.key === "Enter" && (t == null || t()), e == null || e(n);
|
|
46
36
|
},
|
|
47
|
-
onClick:
|
|
48
|
-
children:
|
|
49
|
-
/* @__PURE__ */ a("div", { className: e.content, children: [
|
|
50
|
-
N,
|
|
51
|
-
t && /* @__PURE__ */ c(T, { ...t, theme: (t == null ? void 0 : t.theme) || "surface" })
|
|
52
|
-
] }),
|
|
53
|
-
o && /* @__PURE__ */ a("div", { className: e.action, children: [
|
|
54
|
-
s && /* @__PURE__ */ c("span", { className: e.linkText, children: s }),
|
|
55
|
-
o && /* @__PURE__ */ c(v, { svgElement: o, className: e.linkIcon })
|
|
56
|
-
] })
|
|
57
|
-
]
|
|
37
|
+
onClick: t,
|
|
38
|
+
children: /* @__PURE__ */ m("span", { className: c.content, children: u })
|
|
58
39
|
}
|
|
59
40
|
);
|
|
60
41
|
export {
|
|
61
|
-
|
|
42
|
+
z as MenuItemBase
|
|
62
43
|
};
|