@hortiview/shared-components 0.0.11102 → 0.0.11146
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/BigLoadingSpinner-C3wTbTD0.js +17 -0
- package/dist/GenericCard-B8x1DMa8.js +81 -0
- package/dist/ListAreaService-CRX4eEUJ.js +108 -0
- package/dist/_Map-Dtlps7IZ.js +113 -0
- package/dist/{_commonjsHelpers-CT_km90n.js → _commonjsHelpers-BkfeUUK-.js} +2 -4
- package/dist/_overArg-_0pUmCsX.js +14 -0
- package/dist/assets/Filter.css +1 -0
- package/dist/assets/GenericTable.css +1 -0
- package/dist/assets/main.css +1 -0
- package/dist/components/AlertBanner/AlertBanner.js +22 -16
- package/dist/components/AlertBanner/AlertBanner.test.js +2 -2
- package/dist/components/BaseView/BaseView.js +33 -26
- package/dist/components/BaseView/BaseView.test.js +25 -25
- package/dist/components/BasicHeading/BasicHeading.js +50 -41
- package/dist/components/BasicHeading/BasicHeading.test.js +2 -2
- package/dist/components/BlockView/BlockView.js +51 -42
- package/dist/components/BlockView/BlockView.test.js +2 -2
- package/dist/components/ChipCard/ChipCard.js +12 -10
- package/dist/components/ChipCard/ChipCard.test.js +2 -2
- package/dist/components/ContextMenu/ContextMenu.js +29 -25
- package/dist/components/ContextMenu/ContextMenu.test.js +2 -2
- package/dist/components/DeleteModal/DeleteModal.js +58 -53
- package/dist/components/DeleteModal/DeleteModal.test.js +2 -2
- package/dist/components/Disclaimer/Disclaimer.js +11 -8
- package/dist/components/Disclaimer/Disclaimer.test.js +2 -2
- package/dist/components/EmptyView/EmptyView.test.js +2 -2
- package/dist/components/Filter/Filter.js +107 -125
- package/dist/components/Filter/Filter.test.js +2 -2
- package/dist/components/FormComponents/FormCheckBox/FormCheckBox.js +19 -19
- package/dist/components/FormComponents/FormCheckBox/FormCheckBox.test.js +2 -2
- package/dist/components/FormComponents/FormDatePicker/FormDatePicker.d.ts +3 -0
- package/dist/components/FormComponents/FormDatePicker/FormDatePicker.js +6081 -7102
- package/dist/components/FormComponents/FormDatePicker/FormDatePicker.test.js +2 -2
- package/dist/components/FormComponents/FormNumber/CustomTextField.js +16 -14
- package/dist/components/FormComponents/FormNumber/FormNumber.d.ts +2 -2
- package/dist/components/FormComponents/FormNumber/FormNumber.js +2 -2
- package/dist/components/FormComponents/FormNumber/FormNumber.test.js +4 -4
- package/dist/components/FormComponents/FormRadio/FormRadio.test.js +2 -2
- package/dist/components/FormComponents/FormSelect/FormSelect.d.ts +1 -1
- package/dist/components/FormComponents/FormSelect/FormSelect.js +109 -102
- package/dist/components/FormComponents/FormSelect/FormSelect.test.js +3 -3
- package/dist/components/FormComponents/FormSelect/SelectTooltipText.js +5 -5
- package/dist/components/FormComponents/FormSlider/FormSlider.test.js +2 -2
- package/dist/components/FormComponents/FormText/FormText.js +95 -96
- package/dist/components/FormComponents/FormText/FormText.test.js +13 -13
- package/dist/components/FormComponents/FormToggle/FormToggle.d.ts +31 -0
- package/dist/components/FormComponents/FormToggle/FormToggle.js +43 -0
- package/dist/components/FormComponents/FormToggle/FormToggle.test.d.ts +1 -0
- package/dist/components/FormComponents/FormToggle/FormToggle.test.js +50 -0
- package/dist/components/FormattedNumberDisplay/FormattedNumberDisplay.js +1 -1
- package/dist/components/GenericTable/GenericTable.js +64 -81
- package/dist/components/GenericTable/GenericTable.test.js +2 -2
- package/dist/components/GenericTable/GenericTableService.js +41 -43
- package/dist/components/GenericTable/Mobile/GenericCard.js +6 -68
- package/dist/components/GenericTable/Mobile/GenericCard.test.js +3 -3
- package/dist/components/GenericTable/Mobile/GenericCardList.js +8 -9
- package/dist/components/GenericTable/Mobile/GenericCardList.test.js +2 -2
- package/dist/components/HashTabView/HashTabView.js +62 -52
- package/dist/components/HashTabView/HashTabView.test.js +2 -2
- package/dist/components/HeaderFilter/HeaderFilter.js +16 -14
- package/dist/components/HeaderFilter/HeaderFilter.test.js +2 -2
- package/dist/components/HealthCheckFailed/HealthCheckFailed.js +27 -20
- package/dist/components/HealthCheckFailed/HealthCheckFailed.test.js +2 -2
- package/dist/components/Iconify/Iconify.js +56 -6
- package/dist/components/Iconify/Iconify.test.js +3 -3
- package/dist/components/InfoGroup/InfoGroup.js +36 -30
- package/dist/components/InfoGroup/InfoGroup.test.js +2 -2
- package/dist/components/ListArea/ListArea.js +45 -357
- package/dist/components/ListArea/ListArea.test.js +4 -4
- package/dist/components/ListArea/ListAreaService.js +8 -92
- package/dist/components/LoadingSpinner/Big/BigLoadingSpinner.js +5 -9
- package/dist/components/LoadingSpinner/Big/BigLoadingSpinner.test.js +3 -4
- package/dist/components/LoadingSpinner/Default/LoadingSpinner.js +28 -26
- package/dist/components/LoadingSpinner/Default/LoadingSpinner.test.js +2 -2
- package/dist/components/Modal/Modal.js +6 -4
- package/dist/components/OverflowTooltip/OverflowTooltip.js +21 -19
- package/dist/components/OverflowTooltip/OverflowTooltip.test.js +3 -3
- package/dist/components/OverflowTooltip/OverflowTooltipService.js +1 -2
- package/dist/components/Scrollbar/scrollbar.test.js +2 -2
- package/dist/components/SearchBar/SearchBar.js +22 -20
- package/dist/components/SearchBar/SearchBar.test.js +2 -2
- package/dist/components/VerticalDivider/VerticalDivider.js +6 -4
- package/dist/components/VerticalDivider/VerticalDivider.test.js +2 -2
- package/dist/get-BiqanC9_.js +7 -0
- package/dist/get-P-5PYZOE.js +426 -0
- package/dist/hooks/useBreakpoints.test.js +2 -2
- package/dist/hooks/useHelperText.d.ts +13 -0
- package/dist/hooks/useHelperText.js +25 -0
- package/dist/index-DzM8o582.js +10881 -0
- package/dist/isArray-2zMxXFEr.js +83 -0
- package/dist/isArray-C_5XvIlE.js +7 -0
- package/dist/isEmpty-BimaZd5G.js +225 -0
- package/dist/isString-BOHPtrlm.js +44 -0
- package/dist/magic-string.es-D4UQQyt0.js +859 -0
- package/dist/main.d.ts +1 -0
- package/dist/main.js +33 -31
- package/dist/orderBy-BVQIswlJ.js +765 -0
- package/dist/{react-number-format.es-BeIT_PM7.js → react-number-format.es-BD3_OvMU.js} +156 -159
- package/dist/react-tooltip.min-c2wVkjF2.js +1354 -0
- package/dist/react.esm-FR1-H8iU.js +13471 -0
- package/dist/services/UtilService.js +12 -19
- package/dist/services/services.test.js +1 -1
- package/dist/vi.CjhMlMwf-DWv7vrn7.js +12192 -0
- package/package.json +8 -6
- package/dist/BlockView.module-BPlNT5uh.js +0 -15
- package/dist/HashTabView.module-ZhwSfDeQ.js +0 -16
- package/dist/HeaderFilter.module-DiBmulr5.js +0 -7
- package/dist/Iconify-DoU6pP1o.js +0 -97
- package/dist/_Map-DKsHX-kc.js +0 -59
- package/dist/_baseToString-dkhmFwqS.js +0 -198
- package/dist/_equalByTag-BZEJl6ST.js +0 -158
- package/dist/_overArg-BC4qXKbU.js +0 -9
- package/dist/alertBanner.module-BPiKN0gh.js +0 -11
- package/dist/assets/genericTable.css +0 -1
- package/dist/baseView.module-uWbm_a5f.js +0 -12
- package/dist/basicHeading.module-BYb8xvuk.js +0 -16
- package/dist/bigLoadingSpinner.module-GgbFol8k.js +0 -11
- package/dist/chipCard.module-BjpKuf1b.js +0 -7
- package/dist/contextMenu.module-vNQHb48g.js +0 -9
- package/dist/deleteModal.module-Ds3MDzdl.js +0 -10
- package/dist/disclaimer.module-BZydt-Q_.js +0 -8
- package/dist/formDatePicker.module-BV3ma_7y.js +0 -11
- package/dist/formNumber.module-BA05Gi6_.js +0 -7
- package/dist/formSelect.module-PUiLDSD4.js +0 -15
- package/dist/formText.module-C0by6_DK.js +0 -12
- package/dist/genericCard.module-DrQu86jX.js +0 -15
- package/dist/genericTable.module-Dk3yy2S3.js +0 -17
- package/dist/get-BJn2Enx7.js +0 -47
- package/dist/healthCheckFailed.module-B5P1ogjs.js +0 -12
- package/dist/iconify.module-Cru5NS2X.js +0 -80
- package/dist/index-IMXII42b.js +0 -11708
- package/dist/infoGroup.module-Cxw88dfC.js +0 -12
- package/dist/isArray-thIeLpc5.js +0 -35
- package/dist/isPlainObject-BlCDf1Kc.js +0 -18
- package/dist/listArea.module-BhO_OJ1S.js +0 -20
- package/dist/loadingSpinner.module-CLtqSMWA.js +0 -7
- package/dist/magic-string.es-irX7syie.js +0 -732
- package/dist/modal.module-BlDp1Wiq.js +0 -7
- package/dist/overflowTooltip.module-YyRN2MGc.js +0 -7
- package/dist/react-tooltip.min-BzHiZW8k.js +0 -1380
- package/dist/react.esm-CHvVvf3L.js +0 -12786
- package/dist/searchBar.module-9gKyrZRT.js +0 -7
- package/dist/verticalDivider.module-C3_GL-fH.js +0 -7
- package/dist/vi.JYQecGiw-BpOAB4v6.js +0 -9796
- /package/dist/assets/{alertBanner.css → AlertBanner.css} +0 -0
- /package/dist/assets/{baseView.css → BaseView.css} +0 -0
- /package/dist/assets/{basicHeading.css → BasicHeading.css} +0 -0
- /package/dist/assets/{bigLoadingSpinner.css → BigLoadingSpinner.css} +0 -0
- /package/dist/assets/{chipCard.css → ChipCard.css} +0 -0
- /package/dist/assets/{contextMenu.css → ContextMenu.css} +0 -0
- /package/dist/assets/{formNumber.css → CustomTextField.css} +0 -0
- /package/dist/assets/{deleteModal.css → DeleteModal.css} +0 -0
- /package/dist/assets/{disclaimer.css → Disclaimer.css} +0 -0
- /package/dist/assets/{formDatePicker.css → FormDatePicker.css} +0 -0
- /package/dist/assets/{formSelect.css → FormSelect.css} +0 -0
- /package/dist/assets/{formText.css → FormText.css} +0 -0
- /package/dist/assets/{genericCard.css → GenericCard.css} +0 -0
- /package/dist/assets/{healthCheckFailed.css → HealthCheckFailed.css} +0 -0
- /package/dist/assets/{iconify.css → Iconify.css} +0 -0
- /package/dist/assets/{infoGroup.css → InfoGroup.css} +0 -0
- /package/dist/assets/{listArea.css → ListAreaService.css} +0 -0
- /package/dist/assets/{loadingSpinner.css → LoadingSpinner.css} +0 -0
- /package/dist/assets/{modal.css → Modal.css} +0 -0
- /package/dist/assets/{overflowTooltip.css → OverflowTooltip.css} +0 -0
- /package/dist/assets/{searchBar.css → SearchBar.css} +0 -0
- /package/dist/assets/{verticalDivider.css → VerticalDivider.css} +0 -0
|
@@ -1,70 +1,79 @@
|
|
|
1
|
-
import
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
const
|
|
9
|
-
|
|
1
|
+
import "../../assets/BasicHeading.css";
|
|
2
|
+
import { jsxs as o, jsx as i } from "react/jsx-runtime";
|
|
3
|
+
import { TypoDisplay as u, TypoBody as y, Icon as C } from "@element/react-components";
|
|
4
|
+
import { Iconify as w } from "../Iconify/Iconify.js";
|
|
5
|
+
import { AvailableCustomIcons as j } from "../../enums/AvailableCustomIcons.js";
|
|
6
|
+
import { u as I } from "../../useBreakpoints-MzTZ0tCT.js";
|
|
7
|
+
import { OverflowTooltip as B } from "../OverflowTooltip/OverflowTooltip.js";
|
|
8
|
+
const N = "_pageHeader_gwnjc_1", H = "_actionButtonContainer_gwnjc_16", b = "_leadingIcon_gwnjc_31", x = "_headingWrapper_gwnjc_35", A = "_headingContainer_gwnjc_40", T = "_invisible_gwnjc_45", W = "_withAvatar_gwnjc_49", $ = "_iconContainer_gwnjc_54", n = {
|
|
9
|
+
pageHeader: N,
|
|
10
|
+
actionButtonContainer: H,
|
|
11
|
+
leadingIcon: b,
|
|
12
|
+
headingWrapper: x,
|
|
13
|
+
headingContainer: A,
|
|
14
|
+
invisible: T,
|
|
15
|
+
withAvatar: W,
|
|
16
|
+
iconContainer: $
|
|
17
|
+
}, k = ({ icon: e }) => e ? typeof e != "string" ? /* @__PURE__ */ i("div", { className: n.iconContainer, children: e }) : e in j ? /* @__PURE__ */ i(
|
|
18
|
+
w,
|
|
10
19
|
{
|
|
11
|
-
icon:
|
|
12
|
-
className:
|
|
20
|
+
icon: e,
|
|
21
|
+
className: n.leadingIcon,
|
|
13
22
|
iconSize: "large",
|
|
14
23
|
iconType: "filled"
|
|
15
24
|
}
|
|
16
|
-
) : /* @__PURE__ */
|
|
17
|
-
children:
|
|
18
|
-
marginBottom:
|
|
25
|
+
) : /* @__PURE__ */ i(C, { iconSize: "large", iconType: "filled", icon: e, className: n.leadingIcon }) : null, R = ({
|
|
26
|
+
children: e,
|
|
27
|
+
marginBottom: t,
|
|
19
28
|
heading: a,
|
|
20
29
|
icon: d,
|
|
21
|
-
className:
|
|
22
|
-
subHeading:
|
|
23
|
-
subHeadingLevel:
|
|
24
|
-
invisibleButton:
|
|
25
|
-
level:
|
|
26
|
-
fontWeight:
|
|
27
|
-
withAvatar:
|
|
30
|
+
className: p,
|
|
31
|
+
subHeading: r,
|
|
32
|
+
subHeadingLevel: g = 2,
|
|
33
|
+
invisibleButton: m = !1,
|
|
34
|
+
level: s = 4,
|
|
35
|
+
fontWeight: c = 400,
|
|
36
|
+
withAvatar: _ = !1
|
|
28
37
|
}) => {
|
|
29
|
-
const { isDesktop:
|
|
30
|
-
if (
|
|
31
|
-
return typeof
|
|
38
|
+
const { isDesktop: l } = I(), f = l ? s : s + 1, h = c === "bold" ? 500 : c, v = () => {
|
|
39
|
+
if (t !== void 0)
|
|
40
|
+
return typeof t == "number" ? `${t}px` : "2rem";
|
|
32
41
|
};
|
|
33
|
-
return /* @__PURE__ */
|
|
42
|
+
return /* @__PURE__ */ o(
|
|
34
43
|
"div",
|
|
35
44
|
{
|
|
36
|
-
className:
|
|
37
|
-
style: { marginBottom:
|
|
45
|
+
className: n.pageHeader,
|
|
46
|
+
style: { marginBottom: v() },
|
|
38
47
|
"data-testid": "HeaderContainer",
|
|
39
48
|
children: [
|
|
40
|
-
/* @__PURE__ */
|
|
49
|
+
/* @__PURE__ */ o(
|
|
41
50
|
"div",
|
|
42
51
|
{
|
|
43
|
-
className: `${
|
|
52
|
+
className: `${_ && l ? n.withAvatar : ""} ${n.headingWrapper}`,
|
|
44
53
|
children: [
|
|
45
|
-
/* @__PURE__ */
|
|
46
|
-
/* @__PURE__ */
|
|
47
|
-
/* @__PURE__ */
|
|
48
|
-
|
|
54
|
+
/* @__PURE__ */ i(k, { icon: d }),
|
|
55
|
+
/* @__PURE__ */ o("div", { className: r ? n.headingContainer : "", children: [
|
|
56
|
+
/* @__PURE__ */ i(B, { id: a, text: a, children: /* @__PURE__ */ i(
|
|
57
|
+
u,
|
|
49
58
|
{
|
|
50
|
-
level:
|
|
59
|
+
level: f,
|
|
51
60
|
"data-testid": "Header",
|
|
52
|
-
className:
|
|
53
|
-
style: { fontWeight:
|
|
61
|
+
className: p ?? "",
|
|
62
|
+
style: { fontWeight: h },
|
|
54
63
|
children: a
|
|
55
64
|
}
|
|
56
65
|
) }),
|
|
57
|
-
/* @__PURE__ */
|
|
66
|
+
/* @__PURE__ */ i(y, { level: g, children: r })
|
|
58
67
|
] })
|
|
59
68
|
]
|
|
60
69
|
}
|
|
61
70
|
),
|
|
62
|
-
/* @__PURE__ */
|
|
71
|
+
/* @__PURE__ */ i(
|
|
63
72
|
"div",
|
|
64
73
|
{
|
|
65
|
-
className: `${
|
|
74
|
+
className: `${n.actionButtonContainer} ${m && n.invisible}`,
|
|
66
75
|
"data-testid": "RightPart",
|
|
67
|
-
children:
|
|
76
|
+
children: e
|
|
68
77
|
}
|
|
69
78
|
)
|
|
70
79
|
]
|
|
@@ -72,5 +81,5 @@ const $ = ({ icon: i }) => i ? typeof i != "string" ? /* @__PURE__ */ t("div", {
|
|
|
72
81
|
);
|
|
73
82
|
};
|
|
74
83
|
export {
|
|
75
|
-
|
|
84
|
+
R as BasicHeading
|
|
76
85
|
};
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { jsx as o, Fragment as c } from "react/jsx-runtime";
|
|
2
2
|
import { Button as g } from "@element/react-components";
|
|
3
3
|
import { BasicHeading as a } from "./BasicHeading.js";
|
|
4
|
-
import { a as i, s as n } from "../../react.esm-
|
|
5
|
-
import { d as h, t as s, g as e } from "../../vi.
|
|
4
|
+
import { a as i, s as n } from "../../react.esm-FR1-H8iU.js";
|
|
5
|
+
import { d as h, t as s, g as e } from "../../vi.CjhMlMwf-DWv7vrn7.js";
|
|
6
6
|
h("BasicHeading-Test", () => {
|
|
7
7
|
s("render small container without content", () => {
|
|
8
8
|
i(/* @__PURE__ */ o(a, { heading: "Test" }));
|
|
@@ -1,57 +1,66 @@
|
|
|
1
|
-
import
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
const j =
|
|
7
|
-
|
|
1
|
+
import "../../assets/BlockView.css";
|
|
2
|
+
import { jsxs as h, jsx as c } from "react/jsx-runtime";
|
|
3
|
+
import { TypoSubtitle as T, TypoDisplay as L } from "@element/react-components";
|
|
4
|
+
import { useState as R, useEffect as B, useMemo as C } from "react";
|
|
5
|
+
import { getBlockNumberByDto as E } from "../../services/BlockService.js";
|
|
6
|
+
const A = "_grid_lihp2_1", D = "_black_lihp2_11", S = "_blockLayout_lihp2_15", M = "_blockRow_lihp2_27", V = "_block_lihp2_15", j = "_active_lihp2_46", q = "_error_lihp2_52", F = "_empty_lihp2_58", G = "_blockText_lihp2_62", e = {
|
|
7
|
+
grid: A,
|
|
8
|
+
black: D,
|
|
9
|
+
blockLayout: S,
|
|
10
|
+
blockRow: M,
|
|
11
|
+
block: V,
|
|
12
|
+
active: j,
|
|
13
|
+
error: q,
|
|
14
|
+
empty: F,
|
|
15
|
+
blockText: G
|
|
16
|
+
}, P = ({
|
|
17
|
+
rows: n,
|
|
8
18
|
columns: t,
|
|
9
|
-
hideText:
|
|
10
|
-
errorBlocks:
|
|
11
|
-
showNumbers:
|
|
12
|
-
clickable:
|
|
13
|
-
size:
|
|
14
|
-
onClick:
|
|
15
|
-
currentBlock:
|
|
16
|
-
blocks:
|
|
17
|
-
blockViewTitle:
|
|
19
|
+
hideText: b = !1,
|
|
20
|
+
errorBlocks: y = [],
|
|
21
|
+
showNumbers: f = !0,
|
|
22
|
+
clickable: v = !0,
|
|
23
|
+
size: m = 15,
|
|
24
|
+
onClick: k = null,
|
|
25
|
+
currentBlock: i,
|
|
26
|
+
blocks: _,
|
|
27
|
+
blockViewTitle: N,
|
|
18
28
|
blockLabel: g
|
|
19
29
|
}) => {
|
|
20
|
-
const [
|
|
21
|
-
|
|
22
|
-
if (!
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
return /* @__PURE__ */ i(
|
|
30
|
+
const [d, p] = R(0);
|
|
31
|
+
B(() => {
|
|
32
|
+
if (!i) return;
|
|
33
|
+
const l = E(i, t);
|
|
34
|
+
p(l);
|
|
35
|
+
}, [i, t]);
|
|
36
|
+
const w = C(() => n * t, [n, t]), $ = (l) => {
|
|
37
|
+
k && k(l, i ?? void 0);
|
|
38
|
+
}, x = ({ row: l, column: r }) => _.length === 0 ? !0 : _.some((s) => s.position?.row === l && s.position?.column === r);
|
|
39
|
+
return /* @__PURE__ */ h("div", { "data-testid": "block-view-container", className: e.grid, children: [
|
|
40
|
+
!b && /* @__PURE__ */ c(T, { level: 1, bold: !0, className: e.black, children: N }),
|
|
41
|
+
/* @__PURE__ */ c("div", { className: e.blockLayout, style: { width: `${m}rem`, height: `${m}rem` }, children: Array.from({ length: n }).map((l, r) => /* @__PURE__ */ c("div", { className: e.blockRow, children: Array.from({ length: t }).map((s, a) => {
|
|
42
|
+
const o = t * r + a + 1, u = x({ row: r + 1, column: a + 1 });
|
|
43
|
+
return /* @__PURE__ */ c(
|
|
35
44
|
"div",
|
|
36
45
|
{
|
|
37
46
|
"data-testid": "block-view-block",
|
|
38
|
-
className: `${e.block} ${
|
|
39
|
-
id: `block${
|
|
40
|
-
onClick:
|
|
41
|
-
|
|
47
|
+
className: `${e.block} ${d === o ? e.active : ""} ${u ? "" : e.empty} ${y.includes(o) ? e.error : ""}`,
|
|
48
|
+
id: `block${o}`,
|
|
49
|
+
onClick: v ? () => {
|
|
50
|
+
p(o), $({ row: r + 1, column: a + 1 });
|
|
42
51
|
} : void 0,
|
|
43
|
-
children:
|
|
52
|
+
children: f && u && /* @__PURE__ */ c(
|
|
44
53
|
"div",
|
|
45
54
|
{
|
|
46
|
-
className: `${e.blockText} ${
|
|
47
|
-
children:
|
|
55
|
+
className: `${e.blockText} ${d === o ? e.black : ""}`,
|
|
56
|
+
children: o
|
|
48
57
|
}
|
|
49
58
|
)
|
|
50
59
|
},
|
|
51
|
-
|
|
60
|
+
o
|
|
52
61
|
);
|
|
53
|
-
}) },
|
|
54
|
-
!
|
|
62
|
+
}) }, r)) }),
|
|
63
|
+
!b && /* @__PURE__ */ h(L, { themeColor: "primary", level: 6, children: [
|
|
55
64
|
w,
|
|
56
65
|
" ",
|
|
57
66
|
g
|
|
@@ -59,5 +68,5 @@ const j = ({
|
|
|
59
68
|
] });
|
|
60
69
|
};
|
|
61
70
|
export {
|
|
62
|
-
|
|
71
|
+
P as BlockView
|
|
63
72
|
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as l } from "react/jsx-runtime";
|
|
2
|
-
import { a as s, s as o, f as n } from "../../react.esm-
|
|
2
|
+
import { a as s, s as o, f as n } from "../../react.esm-FR1-H8iU.js";
|
|
3
3
|
import { BlockView as i } from "./BlockView.js";
|
|
4
|
-
import { d as a, v as B, t as r, g as t } from "../../vi.
|
|
4
|
+
import { d as a, v as B, t as r, g as t } from "../../vi.CjhMlMwf-DWv7vrn7.js";
|
|
5
5
|
a("BlockView Test", () => {
|
|
6
6
|
const c = B.fn(), e = {
|
|
7
7
|
id: "1",
|
|
@@ -1,23 +1,25 @@
|
|
|
1
|
-
import
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
const
|
|
1
|
+
import "../../assets/ChipCard.css";
|
|
2
|
+
import { jsx as i } from "react/jsx-runtime";
|
|
3
|
+
import { Card as e, Chips as o } from "@element/react-components";
|
|
4
|
+
import { OverflowTooltip as a } from "../OverflowTooltip/OverflowTooltip.js";
|
|
5
|
+
const d = "_entityContainer_1g0x2_1", c = {
|
|
6
|
+
entityContainer: d
|
|
7
|
+
}, C = ({ label: t, icon: r, className: n = "" }) => /* @__PURE__ */ i(
|
|
6
8
|
e,
|
|
7
9
|
{
|
|
8
10
|
"data-testid": "chip-card",
|
|
9
11
|
variant: "flat",
|
|
10
12
|
bodyAlignment: "centered",
|
|
11
13
|
themeColor: "primary-50",
|
|
12
|
-
className: `${
|
|
13
|
-
children: /* @__PURE__ */
|
|
14
|
-
|
|
14
|
+
className: `${c.entityContainer} ${n}`,
|
|
15
|
+
children: /* @__PURE__ */ i(a, { id: `chip_card_${t}`, text: t, children: /* @__PURE__ */ i(
|
|
16
|
+
o,
|
|
15
17
|
{
|
|
16
18
|
"data-testid": `${t}-chip`,
|
|
17
19
|
chips: [
|
|
18
20
|
{
|
|
19
21
|
label: t,
|
|
20
|
-
leadingIcon:
|
|
22
|
+
leadingIcon: r
|
|
21
23
|
}
|
|
22
24
|
],
|
|
23
25
|
variant: "outlined"
|
|
@@ -26,5 +28,5 @@ const h = ({ label: t, icon: i, className: o = "" }) => /* @__PURE__ */ r(
|
|
|
26
28
|
}
|
|
27
29
|
);
|
|
28
30
|
export {
|
|
29
|
-
|
|
31
|
+
C as ChipCard
|
|
30
32
|
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as e } from "react/jsx-runtime";
|
|
2
|
-
import { a, s as i } from "../../react.esm-
|
|
2
|
+
import { a, s as i } from "../../react.esm-FR1-H8iU.js";
|
|
3
3
|
import { ChipCard as n } from "./ChipCard.js";
|
|
4
|
-
import { d as s, t as c, g as t } from "../../vi.
|
|
4
|
+
import { d as s, t as c, g as t } from "../../vi.CjhMlMwf-DWv7vrn7.js";
|
|
5
5
|
s("ChipCard Component", () => {
|
|
6
6
|
const r = "Test Label", o = "domain";
|
|
7
7
|
c("renders the correct label and icon", () => {
|
|
@@ -1,22 +1,26 @@
|
|
|
1
|
-
import
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
const
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
1
|
+
import "../../assets/ContextMenu.css";
|
|
2
|
+
import { jsx as o } from "react/jsx-runtime";
|
|
3
|
+
import { Menu as a, List as f, ListItem as d, IconButton as _ } from "@element/react-components";
|
|
4
|
+
import { useState as p, useCallback as c, useEffect as I } from "react";
|
|
5
|
+
import { uniqueId as v } from "lodash";
|
|
6
|
+
const y = "_menu_ol91v_1", C = "_icon_ol91v_5", k = "_listItem_ol91v_9", i = {
|
|
7
|
+
menu: y,
|
|
8
|
+
icon: C,
|
|
9
|
+
listItem: k
|
|
10
|
+
}, B = ({
|
|
11
|
+
triggerOpen: l = null,
|
|
12
|
+
actions: m,
|
|
13
|
+
iconOrientation: r = "vertical"
|
|
10
14
|
}) => {
|
|
11
|
-
const [t,
|
|
12
|
-
|
|
13
|
-
}, [t]), s =
|
|
14
|
-
|
|
15
|
+
const [t, n] = p(!1), u = c(() => {
|
|
16
|
+
n(!t);
|
|
17
|
+
}, [t]), s = c(() => {
|
|
18
|
+
n(!1);
|
|
15
19
|
}, []);
|
|
16
|
-
return
|
|
17
|
-
|
|
18
|
-
}, [
|
|
19
|
-
|
|
20
|
+
return I(() => {
|
|
21
|
+
n(l !== null ? l : !1);
|
|
22
|
+
}, [l]), /* @__PURE__ */ o(
|
|
23
|
+
a,
|
|
20
24
|
{
|
|
21
25
|
className: i.menu,
|
|
22
26
|
"data-testid": "selection-menu",
|
|
@@ -24,18 +28,18 @@ const T = ({
|
|
|
24
28
|
surfaceOnly: !0,
|
|
25
29
|
hoistToBody: !0,
|
|
26
30
|
onClose: s,
|
|
27
|
-
trigger: /* @__PURE__ */
|
|
28
|
-
|
|
31
|
+
trigger: /* @__PURE__ */ o(
|
|
32
|
+
_,
|
|
29
33
|
{
|
|
30
34
|
className: i.icon,
|
|
31
35
|
variant: t ? "filled-primary" : void 0,
|
|
32
36
|
"data-testid": "open-button",
|
|
33
|
-
icon:
|
|
34
|
-
onClick:
|
|
37
|
+
icon: r === "vertical" ? "more_vert" : "more_horiz",
|
|
38
|
+
onClick: u
|
|
35
39
|
}
|
|
36
40
|
),
|
|
37
|
-
children: /* @__PURE__ */
|
|
38
|
-
|
|
41
|
+
children: /* @__PURE__ */ o(f, { children: m.map((e) => /* @__PURE__ */ o(
|
|
42
|
+
d,
|
|
39
43
|
{
|
|
40
44
|
className: i.listItem,
|
|
41
45
|
...e,
|
|
@@ -45,12 +49,12 @@ const T = ({
|
|
|
45
49
|
e?.onClick?.(), e.closeOnClick !== !1 && s();
|
|
46
50
|
}
|
|
47
51
|
},
|
|
48
|
-
|
|
52
|
+
v(`LI_${e.primaryText?.toString()}_`)
|
|
49
53
|
)) })
|
|
50
54
|
},
|
|
51
55
|
"selectionmenu"
|
|
52
56
|
);
|
|
53
57
|
};
|
|
54
58
|
export {
|
|
55
|
-
|
|
59
|
+
B as ContextMenu
|
|
56
60
|
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as r } from "react/jsx-runtime";
|
|
2
|
-
import { a as B, s as t, f as o, w as s } from "../../react.esm-
|
|
2
|
+
import { a as B, s as t, f as o, w as s } from "../../react.esm-FR1-H8iU.js";
|
|
3
3
|
import { ContextMenu as p } from "./ContextMenu.js";
|
|
4
|
-
import { v as l, d as k, t as T, g as e } from "../../vi.
|
|
4
|
+
import { v as l, d as k, t as T, g as e } from "../../vi.CjhMlMwf-DWv7vrn7.js";
|
|
5
5
|
const C = l.fn(), a = l.fn(), i = l.fn(), g = [
|
|
6
6
|
{ primaryText: "Open", onClick: C, leadingBlock: "add" },
|
|
7
7
|
{ primaryText: "Delete", onClick: i, leadingBlock: "delete_outline" },
|
|
@@ -1,88 +1,93 @@
|
|
|
1
|
-
import
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
const
|
|
1
|
+
import "../../assets/DeleteModal.css";
|
|
2
|
+
import { jsx as o, jsxs as p, Fragment as c } from "react/jsx-runtime";
|
|
3
|
+
import { Group as i, Button as u, Icon as D, TypoBody as l } from "@element/react-components";
|
|
4
|
+
import { uniqueId as I } from "lodash";
|
|
5
|
+
import { AvailableCustomIcons as O } from "../../enums/AvailableCustomIcons.js";
|
|
6
|
+
import { u as N } from "../../useBreakpoints-MzTZ0tCT.js";
|
|
7
|
+
import { Iconify as S } from "../Iconify/Iconify.js";
|
|
8
|
+
import { Modal as x } from "../Modal/Modal.js";
|
|
9
|
+
const M = "_bulletPoint_1kyg0_1", j = "_modal_1kyg0_6", z = "_colorDanger_1kyg0_10", B = "_crossedOut_1kyg0_14", t = {
|
|
10
|
+
bulletPoint: M,
|
|
11
|
+
modal: j,
|
|
12
|
+
colorDanger: z,
|
|
13
|
+
crossedOut: B
|
|
14
|
+
}, R = ({
|
|
10
15
|
title: e,
|
|
11
|
-
confirmButtonLabel:
|
|
16
|
+
confirmButtonLabel: r,
|
|
12
17
|
cancelButtonLabel: n,
|
|
13
18
|
deleteHeader: a,
|
|
14
|
-
deleteBody:
|
|
15
|
-
deleteText:
|
|
16
|
-
icon:
|
|
19
|
+
deleteBody: s,
|
|
20
|
+
deleteText: g,
|
|
21
|
+
icon: f,
|
|
17
22
|
isIconCrossedOut: h,
|
|
18
|
-
impossibleDeleteHeader:
|
|
19
|
-
open:
|
|
20
|
-
setOpen:
|
|
21
|
-
onDelete:
|
|
22
|
-
isDeletePossible:
|
|
23
|
+
impossibleDeleteHeader: y,
|
|
24
|
+
open: b,
|
|
25
|
+
setOpen: d,
|
|
26
|
+
onDelete: k,
|
|
27
|
+
isDeletePossible: m = !0
|
|
23
28
|
}) => {
|
|
24
|
-
const { isDesktop:
|
|
25
|
-
|
|
29
|
+
const { isDesktop: _ } = N(), v = (C) => {
|
|
30
|
+
C.detail.action === "close" && d(!1);
|
|
26
31
|
};
|
|
27
|
-
return /* @__PURE__ */
|
|
28
|
-
|
|
32
|
+
return /* @__PURE__ */ o(
|
|
33
|
+
x,
|
|
29
34
|
{
|
|
30
35
|
className: t.modal,
|
|
31
|
-
modalSize:
|
|
32
|
-
open:
|
|
33
|
-
onClose:
|
|
36
|
+
modalSize: _ ? "small" : "fullscreen",
|
|
37
|
+
open: b,
|
|
38
|
+
onClose: v,
|
|
34
39
|
title: e,
|
|
35
|
-
primaryButton: /* @__PURE__ */
|
|
40
|
+
primaryButton: /* @__PURE__ */ o(
|
|
36
41
|
u,
|
|
37
42
|
{
|
|
38
43
|
"data-testid": "delete-button",
|
|
39
44
|
variant: "danger",
|
|
40
|
-
label:
|
|
41
|
-
onClick:
|
|
42
|
-
disabled: !
|
|
45
|
+
label: r,
|
|
46
|
+
onClick: k,
|
|
47
|
+
disabled: !m
|
|
43
48
|
}
|
|
44
49
|
),
|
|
45
|
-
footerSupplemental: /* @__PURE__ */
|
|
50
|
+
footerSupplemental: /* @__PURE__ */ o(
|
|
46
51
|
u,
|
|
47
52
|
{
|
|
48
53
|
"data-testid": "cancel-button",
|
|
49
54
|
variant: "text",
|
|
50
55
|
label: n,
|
|
51
|
-
onClick: () =>
|
|
56
|
+
onClick: () => d(!1)
|
|
52
57
|
}
|
|
53
58
|
),
|
|
54
|
-
children: /* @__PURE__ */ p(
|
|
55
|
-
/* @__PURE__ */
|
|
56
|
-
/* @__PURE__ */
|
|
57
|
-
|
|
59
|
+
children: /* @__PURE__ */ p(i, { direction: "vertical", secondaryAlign: "center", children: [
|
|
60
|
+
/* @__PURE__ */ o(P, { element: /* @__PURE__ */ o(A, { icon: f }), isCrossedOut: h }),
|
|
61
|
+
/* @__PURE__ */ o(i, { direction: "vertical", children: m ? /* @__PURE__ */ o(
|
|
62
|
+
q,
|
|
58
63
|
{
|
|
59
64
|
deleteHeader: a,
|
|
60
|
-
deleteText:
|
|
61
|
-
deleteBody:
|
|
65
|
+
deleteText: g,
|
|
66
|
+
deleteBody: s
|
|
62
67
|
}
|
|
63
|
-
) : /* @__PURE__ */
|
|
68
|
+
) : /* @__PURE__ */ o(F, { impossibleDeleteHeader: y }) })
|
|
64
69
|
] })
|
|
65
70
|
}
|
|
66
71
|
);
|
|
67
|
-
},
|
|
72
|
+
}, P = ({
|
|
68
73
|
element: e,
|
|
69
|
-
isCrossedOut:
|
|
70
|
-
}) =>
|
|
71
|
-
|
|
74
|
+
isCrossedOut: r = !1
|
|
75
|
+
}) => r ? /* @__PURE__ */ o("span", { className: t.crossedOut, children: e }) : e, A = ({ icon: e }) => e ? typeof e != "string" ? e : Object.values(O).includes(e) ? /* @__PURE__ */ o(
|
|
76
|
+
S,
|
|
72
77
|
{
|
|
73
78
|
icon: e,
|
|
74
79
|
iconSize: "xlarge",
|
|
75
80
|
className: t.colorDanger
|
|
76
81
|
}
|
|
77
|
-
) : /* @__PURE__ */
|
|
82
|
+
) : /* @__PURE__ */ o(D, { icon: e, iconSize: "xlarge", className: t.colorDanger }) : /* @__PURE__ */ o(c, {}), q = ({
|
|
78
83
|
deleteHeader: e,
|
|
79
|
-
deleteText:
|
|
84
|
+
deleteText: r,
|
|
80
85
|
deleteBody: n
|
|
81
|
-
}) => /* @__PURE__ */ p(
|
|
82
|
-
/* @__PURE__ */
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
n &&
|
|
86
|
+
}) => /* @__PURE__ */ p(c, { children: [
|
|
87
|
+
/* @__PURE__ */ o(l, { level: 1, themeColor: "text-primary-on-background", children: e }),
|
|
88
|
+
r && typeof r == "string" && /* @__PURE__ */ o(l, { level: 2, themeColor: "text-secondary-on-background", children: r }),
|
|
89
|
+
r && typeof r != "string" && /* @__PURE__ */ o(c, { children: r }),
|
|
90
|
+
n && r === void 0 && /* @__PURE__ */ o(i, { direction: "vertical", gap: "none", children: n.map((a, s) => /* @__PURE__ */ o(
|
|
86
91
|
l,
|
|
87
92
|
{
|
|
88
93
|
level: 2,
|
|
@@ -90,11 +95,11 @@ const L = ({
|
|
|
90
95
|
themeColor: "text-secondary-on-background",
|
|
91
96
|
children: a
|
|
92
97
|
},
|
|
93
|
-
|
|
98
|
+
I(s.toString())
|
|
94
99
|
)) })
|
|
95
|
-
] }),
|
|
100
|
+
] }), F = ({
|
|
96
101
|
impossibleDeleteHeader: e
|
|
97
|
-
}) => /* @__PURE__ */
|
|
102
|
+
}) => /* @__PURE__ */ o(l, { level: 1, themeColor: "text-primary-on-background", children: e });
|
|
98
103
|
export {
|
|
99
|
-
|
|
104
|
+
R as DeleteModal
|
|
100
105
|
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as n } from "react/jsx-runtime";
|
|
2
|
-
import { a as c, s as e } from "../../react.esm-
|
|
2
|
+
import { a as c, s as e } from "../../react.esm-FR1-H8iU.js";
|
|
3
3
|
import { DeleteModal as b } from "./DeleteModal.js";
|
|
4
|
-
import { d as B, t as a, v as o, g as t } from "../../vi.
|
|
4
|
+
import { d as B, t as a, v as o, g as t } from "../../vi.CjhMlMwf-DWv7vrn7.js";
|
|
5
5
|
B("DeleteModal Test", () => {
|
|
6
6
|
a("should render the DeleteModal properly", () => {
|
|
7
7
|
c(
|
|
@@ -1,16 +1,19 @@
|
|
|
1
|
-
import
|
|
2
|
-
import {
|
|
3
|
-
import { s as
|
|
4
|
-
const
|
|
5
|
-
|
|
1
|
+
import "../../assets/Disclaimer.css";
|
|
2
|
+
import { jsxs as n, jsx as r } from "react/jsx-runtime";
|
|
3
|
+
import { Group as s, TypoSubtitle as t, TypoBody as m, Icon as d } from "@element/react-components";
|
|
4
|
+
const p = "_disclaimer_1k38t_1", y = "_iconArea_1k38t_7", c = {
|
|
5
|
+
disclaimer: p,
|
|
6
|
+
iconArea: y
|
|
7
|
+
}, f = ({ text: o, subtext: e, icon: i, level: l = 2, bold: a = !1 }) => /* @__PURE__ */ n(
|
|
8
|
+
s,
|
|
6
9
|
{
|
|
7
10
|
direction: i || e ? "vertical" : "horizontal",
|
|
8
11
|
secondaryAlign: "center",
|
|
9
12
|
primaryAlign: "center",
|
|
10
13
|
children: [
|
|
11
|
-
/* @__PURE__ */ r(
|
|
12
|
-
e && /* @__PURE__ */ r(
|
|
13
|
-
i && /* @__PURE__ */ r("div", { className:
|
|
14
|
+
/* @__PURE__ */ r(t, { className: c.disclaimer, level: l, bold: a, children: o }),
|
|
15
|
+
e && /* @__PURE__ */ r(m, { level: 2, children: e }),
|
|
16
|
+
i && /* @__PURE__ */ r("div", { className: c.iconArea, children: /* @__PURE__ */ r(d, { className: c.Icon, icon: i, iconSize: "large" }) })
|
|
14
17
|
]
|
|
15
18
|
}
|
|
16
19
|
);
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as o } from "react/jsx-runtime";
|
|
2
|
-
import { a as r, s as t } from "../../react.esm-
|
|
2
|
+
import { a as r, s as t } from "../../react.esm-FR1-H8iU.js";
|
|
3
3
|
import { Disclaimer as s } from "./Disclaimer.js";
|
|
4
|
-
import { d as i, t as m, g as e } from "../../vi.
|
|
4
|
+
import { d as i, t as m, g as e } from "../../vi.CjhMlMwf-DWv7vrn7.js";
|
|
5
5
|
i("Disclaimer test", () => {
|
|
6
6
|
m("should render with default text", () => {
|
|
7
7
|
r(/* @__PURE__ */ o(s, { text: "disclaimer.default" })), e(t.getByText("disclaimer.default")).toBeInTheDocument();
|