@hortiview/shared-components 2.3.0 → 2.5.0

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.
Files changed (115) hide show
  1. package/CHANGELOG.md +24 -0
  2. package/README.md +11 -0
  3. package/dist/{AlertBanner-75jjene1.js → AlertBanner-JnX0tJGC.js} +9 -9
  4. package/dist/{BigLoadingSpinner-BbXMCKpm.js → BigLoadingSpinner-chQoiNY9.js} +1 -1
  5. package/dist/{GenericCard-BFYKwkzI.js → GenericCard-c9yuyN3m.js} +3 -3
  6. package/dist/ListAreaService-BY6ZTds9.js +124 -0
  7. package/dist/OfflineView-HbuDPpQL.js +48 -0
  8. package/dist/{_MapCache-B75yWNNd.js → _MapCache-B75dXJyg.js} +2 -2
  9. package/dist/_baseIsEqual-CZNn3LMM.js +241 -0
  10. package/dist/_getAllKeys-tc1bcd1W.js +86 -0
  11. package/dist/{_getTag-BCf9b56Z.js → _getTag-DYHrLaIw.js} +2 -2
  12. package/dist/_setToString-Do1lSQTZ.js +2034 -0
  13. package/dist/assets/ContextMenu.css +1 -1
  14. package/dist/assets/ListAreaService.css +1 -1
  15. package/dist/assets/OfflineView.css +1 -0
  16. package/dist/components/AlertBanner/AlertBanner.js +4 -4
  17. package/dist/components/AlertBanner/AlertBanner.test.js +1 -1
  18. package/dist/components/AlertBanner/LinkBanner.js +3 -3
  19. package/dist/components/BaseView/BaseView.d.ts +14 -1
  20. package/dist/components/BaseView/BaseView.js +47 -41
  21. package/dist/components/BaseView/BaseView.test.js +51 -34
  22. package/dist/components/BasicHeading/BasicHeading.js +2 -2
  23. package/dist/components/BasicHeading/BasicHeading.test.js +1 -1
  24. package/dist/components/BlockView/BlockView.js +1 -1
  25. package/dist/components/ChipCard/ChipCard.js +4 -4
  26. package/dist/components/ContextMenu/ContextMenu.d.ts +12 -1
  27. package/dist/components/ContextMenu/ContextMenu.js +40 -36
  28. package/dist/components/ContextMenu/ContextMenu.test.js +42 -19
  29. package/dist/components/DeleteModal/DeleteModal.d.ts +13 -1
  30. package/dist/components/DeleteModal/DeleteModal.js +53 -49
  31. package/dist/components/DeleteModal/DeleteModal.test.js +35 -11
  32. package/dist/components/DetailContentWrapper/DetailContentWrapper.js +1 -1
  33. package/dist/components/Disclaimer/Disclaimer.js +3 -3
  34. package/dist/components/EmptyView/EmptyView.js +4 -4
  35. package/dist/components/Filter/Filter.js +17 -16
  36. package/dist/components/FormComponents/FormCheckBox/FormCheckBox.js +1 -1
  37. package/dist/components/FormComponents/FormDatePicker/FormDatePicker.js +4 -4
  38. package/dist/components/FormComponents/FormNumber/CustomTextField.js +13 -12
  39. package/dist/components/FormComponents/FormRadio/FormRadio.js +1 -1
  40. package/dist/components/FormComponents/FormSelect/FormSelect.js +1 -1
  41. package/dist/components/FormComponents/FormSelect/SelectTooltipText.js +2 -2
  42. package/dist/components/FormComponents/FormSlider/FormSlider.js +4 -4
  43. package/dist/components/FormComponents/FormText/FormText.js +2 -2
  44. package/dist/components/FormComponents/FormToggle/FormToggle.js +3 -3
  45. package/dist/components/GenericTable/GenericTable.d.ts +3 -1
  46. package/dist/components/GenericTable/GenericTable.js +2013 -2030
  47. package/dist/components/GenericTable/GenericTable.test.js +36 -6
  48. package/dist/components/GenericTable/Mobile/GenericCard.js +4 -4
  49. package/dist/components/GenericTable/Mobile/GenericCard.test.js +1 -1
  50. package/dist/components/GenericTable/Mobile/GenericCardList.js +4 -4
  51. package/dist/components/HashTabView/HashTabView.js +6 -6
  52. package/dist/components/HeaderFilter/HeaderFilter.js +1 -1
  53. package/dist/components/HealthCheckFailed/HealthCheckFailed.js +4 -4
  54. package/dist/components/Iconify/Iconify.js +2 -2
  55. package/dist/components/InfoGroup/InfoGroup.js +3 -3
  56. package/dist/components/ListArea/ListArea.js +36 -35
  57. package/dist/components/ListArea/ListArea.test.js +14 -9
  58. package/dist/components/ListArea/ListAreaService.js +9 -7
  59. package/dist/components/LoadingSpinner/Big/BigLoadingSpinner.js +2 -2
  60. package/dist/components/LoadingSpinner/Big/BigLoadingSpinner.test.js +1 -1
  61. package/dist/components/LoadingSpinner/Default/LoadingSpinner.js +6 -6
  62. package/dist/components/Modal/Modal.d.ts +6 -1
  63. package/dist/components/Modal/Modal.js +134 -118
  64. package/dist/components/ModulePadding/ModulePadding.js +9 -8
  65. package/dist/components/OfflineView/OfflineView.d.ts +68 -0
  66. package/dist/components/OfflineView/OfflineView.js +9 -0
  67. package/dist/components/OfflineView/OfflineView.test.d.ts +1 -0
  68. package/dist/components/OfflineView/OfflineView.test.js +24 -0
  69. package/dist/components/OnboardingBanner/OnboardingBanner.js +7 -7
  70. package/dist/components/OverflowTooltip/OverflowTooltip.js +1 -1
  71. package/dist/components/OverflowTooltip/OverflowTooltip.test.js +1 -1
  72. package/dist/components/SearchBar/SearchBar.js +2 -2
  73. package/dist/components/Select/Select.js +1 -1
  74. package/dist/components/Stepper/Stepper.js +1 -1
  75. package/dist/components/Stepper/components/StepperButton.js +1 -1
  76. package/dist/components/Stepper/components/StepperHeader.js +2 -2
  77. package/dist/components/Stepper/components/StepperIndicator.js +1 -1
  78. package/dist/{get-DFv1gXfq.js → get-B8c-T4F8.js} +1 -1
  79. package/dist/{get-7ACccM2X.js → get-C7KpEkVs.js} +1 -1
  80. package/dist/hooks/useHelperText.js +1 -1
  81. package/dist/{index.es-D54RuMc_.js → index.es--yyG47az.js} +2 -2
  82. package/dist/{index.es-DKDgy7Kt.js → index.es-6c1Xbl0N.js} +1 -1
  83. package/dist/{index.es-BWgXLqXn.js → index.es-BTc2I5pe.js} +2 -2
  84. package/dist/{index.es-BtjV0oNv.js → index.es-Bf149BSP.js} +4 -4
  85. package/dist/{index.es-CoFul5zR.js → index.es-BoWmBoqO.js} +8 -8
  86. package/dist/{index.es-CiqbARoC.js → index.es-Bx1E5MPK.js} +4 -4
  87. package/dist/{index.es-fnFnw2P1.js → index.es-CPqaUyn3.js} +10 -10
  88. package/dist/{index.es-25EARqhH.js → index.es-CUuzYysw.js} +4 -4
  89. package/dist/{index.es-DntoATwO.js → index.es-CbBdaRO2.js} +2 -2
  90. package/dist/{index.es-8GOVkuo-.js → index.es-CqgVUhln.js} +3 -3
  91. package/dist/{index.es-BNHI3ZIK.js → index.es-CzUKBF7E.js} +10 -10
  92. package/dist/{index.es-D-CKRzIB.js → index.es-D-ph6ImM.js} +1 -1
  93. package/dist/{index.es-6TJ1S8Jr.js → index.es-DDo_AHL0.js} +7 -7
  94. package/dist/{index.es-3043KTnb.js → index.es-DErA6zWG.js} +2 -2
  95. package/dist/{index.es-h2lMdt7G.js → index.es-DF11ERDs.js} +2 -2
  96. package/dist/{index.es-B-_jXDuz.js → index.es-DMGNht46.js} +1 -1
  97. package/dist/{index.es-Dvj_qpAp.js → index.es-DOX4XTz_.js} +2 -2
  98. package/dist/index.es-DlzwTKbh.js +311 -0
  99. package/dist/{index.es-CL_Heu1n.js → index.es-DxDU9C_B.js} +1 -1
  100. package/dist/{index.es-0lQcz8m1.js → index.es-Kg9soDed.js} +3 -3
  101. package/dist/{index.es-41ztjcFT.js → index.es-U5-b20Gv.js} +4 -4
  102. package/dist/{index.es-BvrQnJ3j.js → index.es-oOD85ZwA.js} +4 -4
  103. package/dist/{index.es-D6N-XWHe.js → index.es-zQBuWUgU.js} +2 -2
  104. package/dist/{isEmpty-B4GG2s-V.js → isEmpty-DsdC9UUD.js} +2 -2
  105. package/dist/main.d.ts +1 -0
  106. package/dist/main.js +66 -64
  107. package/dist/omit-1Eom1PmQ.js +366 -0
  108. package/dist/{orderBy-Bd48bw88.js → orderBy-CyjsW2ET.js} +31 -30
  109. package/dist/types/GenericTable.d.ts +9 -0
  110. package/dist/types/ListElement.d.ts +23 -9
  111. package/package.json +1 -1
  112. package/dist/ListAreaService-BVtuBN0K.js +0 -110
  113. package/dist/_baseIsEqual-D0Dsajdb.js +0 -317
  114. package/dist/identity-DLWZln-X.js +0 -1763
  115. package/dist/index.es-da0cf7oE.js +0 -569
@@ -1,22 +1,45 @@
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-CX1WJ2Pp.js";
3
- import { ContextMenu as p } from "./ContextMenu.js";
4
- import { a as d, d as k, t as T, g as e } from "../../vi.CjhMlMwf-CKxPQtd6.js";
5
- const C = d.fn(), a = d.fn(), i = d.fn(), g = [
6
- { primaryText: "Open", onClick: C, leadingBlock: "add", "data-testid": "open-testid" },
7
- { primaryText: "Delete", onClick: i, leadingBlock: "delete_outline", "data-testid": "delete-testid" },
8
- { primaryText: "Edit", onClick: a, leadingBlock: "edit", "data-testid": "edit-testid" }
1
+ import { jsx as a } from "react/jsx-runtime";
2
+ import { a as i, s as t, f as o, w as c } from "../../react.esm-CX1WJ2Pp.js";
3
+ import { ContextMenu as d } from "./ContextMenu.js";
4
+ import { a as B, d as I, t as l, g as e } from "../../vi.CjhMlMwf-CKxPQtd6.js";
5
+ const g = B.fn(), m = B.fn(), r = B.fn(), u = [
6
+ { primaryText: "Open", onClick: g, leadingBlock: "add", "data-testid": "open-testid" },
7
+ {
8
+ primaryText: "Delete",
9
+ onClick: r,
10
+ leadingBlock: "delete_outline",
11
+ "data-testid": "delete-testid"
12
+ },
13
+ { primaryText: "Edit", onClick: m, leadingBlock: "edit", "data-testid": "edit-testid" }
9
14
  ];
10
- k("ContextMenu Test", () => {
11
- T("render contextMenu and close it", () => {
12
- B(/* @__PURE__ */ r(p, { actions: g }));
13
- const c = t.getByTestId("open-button"), n = t.getByTestId("selection-menu");
14
- e(n).toBeInTheDocument(), e(n).not.toHaveClass("mdc-menu-surface--open"), o.click(c), s(() => e(n).toHaveClass("mdc-menu-surface--open")), o.click(c), s(() => e(n).not.toHaveClass("mdc-menu-surface--open"));
15
- }), T("render ContextMenu and open it", async () => {
16
- B(/* @__PURE__ */ r(p, { actions: g, triggerOpen: !0 }));
17
- const c = t.getByTestId("open-button"), n = t.getByTestId("selection-menu");
18
- e(n).toBeInTheDocument(), e(n).not.toHaveClass("mdc-menu-surface--open"), o.click(c), await s(() => e(n).toHaveClass("mdc-menu-surface--animating-open")), e(t.getByText("Open")).toBeInTheDocument(), e(t.getByText("Delete")).toBeInTheDocument(), e(t.getByText("Edit")).toBeInTheDocument();
19
- const l = t.getByTestId("open-testid"), m = t.getByTestId("delete-testid"), u = t.getByTestId("edit-testid");
20
- e(l).toBeInTheDocument(), e(m).toBeInTheDocument(), e(u).toBeInTheDocument(), o.click(l), e(C).toHaveBeenCalled(), e(i).not.toHaveBeenCalled(), e(a).not.toHaveBeenCalled(), o.click(m), e(i).toHaveBeenCalled(), o.click(u), e(a).toHaveBeenCalled();
15
+ I("ContextMenu Test", () => {
16
+ l("render contextMenu and close it", () => {
17
+ i(/* @__PURE__ */ a(d, { actions: u }));
18
+ const s = t.getByTestId("open-button"), n = t.getByTestId("selection-menu");
19
+ e(n).toBeInTheDocument(), e(n).not.toHaveClass("mdc-menu-surface--open"), o.click(s), c(() => e(n).toHaveClass("mdc-menu-surface--open")), o.click(s), c(() => e(n).not.toHaveClass("mdc-menu-surface--open"));
20
+ }), l("render ContextMenu and open it", async () => {
21
+ i(/* @__PURE__ */ a(d, { actions: u, triggerOpen: !0 }));
22
+ const s = t.getByTestId("open-button"), n = t.getByTestId("selection-menu");
23
+ e(n).toBeInTheDocument(), e(n).not.toHaveClass("mdc-menu-surface--open"), o.click(s), await c(() => e(n).toHaveClass("mdc-menu-surface--animating-open")), e(t.getByText("Open")).toBeInTheDocument(), e(t.getByText("Delete")).toBeInTheDocument(), e(t.getByText("Edit")).toBeInTheDocument();
24
+ const p = t.getByTestId("open-testid"), T = t.getByTestId("delete-testid"), f = t.getByTestId("edit-testid");
25
+ e(p).toBeInTheDocument(), e(T).toBeInTheDocument(), e(f).toBeInTheDocument(), o.click(p), e(g).toHaveBeenCalled(), e(r).not.toHaveBeenCalled(), e(m).not.toHaveBeenCalled(), o.click(T), e(r).toHaveBeenCalled(), o.click(f), e(m).toHaveBeenCalled();
26
+ }), l("render ContextMenu with offlineView", async () => {
27
+ i(
28
+ /* @__PURE__ */ a(
29
+ d,
30
+ {
31
+ actions: u,
32
+ triggerOpen: !0,
33
+ isOnline: !1,
34
+ offlineViewProps: {
35
+ "data-testid": "offline-test"
36
+ }
37
+ }
38
+ )
39
+ );
40
+ const s = t.getByTestId("open-button");
41
+ o.click(s);
42
+ const n = t.getByTestId("selection-menu");
43
+ await c(() => e(n).toHaveClass("mdc-menu-surface--animating-open")), e(t.getByTestId("offline-test")).toBeInTheDocument();
21
44
  });
22
45
  });
@@ -1,3 +1,5 @@
1
+ import { OfflineViewProps } from '../OfflineView/OfflineView';
2
+
1
3
  type DeleteModalProps = {
2
4
  /**
3
5
  * The title of the modal.
@@ -58,6 +60,14 @@ type DeleteModalProps = {
58
60
  * Default is _true_.
59
61
  */
60
62
  isDeletePossible?: boolean;
63
+ /**
64
+ * Whether the user is online; shows OfflineView when false.
65
+ */
66
+ isOnline?: boolean;
67
+ /**
68
+ * Props forwarded to <OfflineView /> when offline.
69
+ */
70
+ offlineViewProps?: Partial<OfflineViewProps>;
61
71
  };
62
72
  /**
63
73
  * A modal component for deleting items.
@@ -75,7 +85,9 @@ type DeleteModalProps = {
75
85
  * @prop {function} onDelete - The function to call when the confirm button is clicked.
76
86
  * @prop {function} onCancel - A optional function to call when the cancel button is clicked.
77
87
  * @prop {boolean} isDeletePossible - If true, the delete button will be enabled. If false, the delete button will be disabled and the {@link impossibleDeleteHeader} will be displayed. Default is _true_.
88
+ * @prop {boolean} isOnline - Whether the user is online; shows OfflineView when false.
89
+ * @prop {Partial} offlineViewProps - Props forwarded to OfflineView when offline.
78
90
  * @returns {ReactElement} A modal component for deleting items.
79
91
  */
80
- export declare const DeleteModal: ({ title, confirmButtonLabel, cancelButtonLabel, deleteHeader, deleteBody, deleteText, icon, isIconCrossedOut, impossibleDeleteHeader, open, setOpen, onDelete, onCancel, isDeletePossible, }: DeleteModalProps) => import("react/jsx-runtime").JSX.Element;
92
+ export declare const DeleteModal: ({ title, confirmButtonLabel, cancelButtonLabel, deleteHeader, deleteBody, deleteText, icon, isIconCrossedOut, impossibleDeleteHeader, open, setOpen, onDelete, onCancel, isDeletePossible, isOnline, offlineViewProps, }: DeleteModalProps) => import("react/jsx-runtime").JSX.Element;
81
93
  export {};
@@ -1,96 +1,100 @@
1
- import { jsx as o, jsxs as p, Fragment as i } from "react/jsx-runtime";
2
- import { B as u } from "../../index.es-CiqbARoC.js";
3
- import { G as c } from "../../index.es-DntoATwO.js";
4
- import { I as D } from "../../index.es-3043KTnb.js";
5
- import { T as l } from "../../index.es-D54RuMc_.js";
6
- import { u as k } from "../../uniqueId-NU3-C36A.js";
7
- import { AvailableCustomIcons as I } from "../../enums/AvailableCustomIcons.js";
8
- import { u as N } from "../../useBreakpoints-MzTZ0tCT.js";
9
- import { Iconify as O } from "../Iconify/Iconify.js";
10
- import { Modal as S } from "../Modal/Modal.js";
11
- import '../../assets/DeleteModal.css';const x = "_bulletPoint_bd412_1", B = "_modal_bd412_7", M = "_colorDanger_bd412_11", j = "_crossedOut_bd412_15", t = {
12
- bulletPoint: x,
13
- modal: B,
14
- colorDanger: M,
15
- crossedOut: j
16
- }, R = ({
1
+ import { jsx as o, jsxs as f, Fragment as c } from "react/jsx-runtime";
2
+ import { B as p } from "../../index.es-Bx1E5MPK.js";
3
+ import { G as i } from "../../index.es-CbBdaRO2.js";
4
+ import { I } from "../../index.es-DErA6zWG.js";
5
+ import { T as l } from "../../index.es--yyG47az.js";
6
+ import { u as N } from "../../uniqueId-NU3-C36A.js";
7
+ import { AvailableCustomIcons as S } from "../../enums/AvailableCustomIcons.js";
8
+ import { u as x } from "../../useBreakpoints-MzTZ0tCT.js";
9
+ import { Iconify as B } from "../Iconify/Iconify.js";
10
+ import { Modal as M } from "../Modal/Modal.js";
11
+ import '../../assets/DeleteModal.css';const O = "_bulletPoint_bd412_1", j = "_modal_bd412_7", z = "_colorDanger_bd412_11", P = "_crossedOut_bd412_15", t = {
12
+ bulletPoint: O,
13
+ modal: j,
14
+ colorDanger: z,
15
+ crossedOut: P
16
+ }, V = ({
17
17
  title: r,
18
18
  confirmButtonLabel: e,
19
19
  cancelButtonLabel: n,
20
20
  deleteHeader: a,
21
21
  deleteBody: s,
22
- deleteText: f,
23
- icon: b,
24
- isIconCrossedOut: g,
25
- impossibleDeleteHeader: h,
26
- open: v,
22
+ deleteText: b,
23
+ icon: g,
24
+ isIconCrossedOut: h,
25
+ impossibleDeleteHeader: v,
26
+ open: y,
27
27
  setOpen: d,
28
- onDelete: y,
29
- onCancel: _,
30
- isDeletePossible: m = !0
28
+ onDelete: _,
29
+ onCancel: C,
30
+ isDeletePossible: m = !0,
31
+ isOnline: u = !0,
32
+ offlineViewProps: D
31
33
  }) => {
32
- const { isDesktop: C } = N();
34
+ const { isDesktop: k } = x();
33
35
  return /* @__PURE__ */ o(
34
- S,
36
+ M,
35
37
  {
38
+ isOnline: u,
39
+ offlineViewProps: D,
36
40
  className: `${t.modal}`,
37
- modalSize: C ? "small" : "fullscreen",
38
- open: v,
41
+ modalSize: k ? "small" : "fullscreen",
42
+ open: y,
39
43
  title: r,
40
44
  onClose: () => d(!1),
41
45
  primaryButton: /* @__PURE__ */ o(
42
- u,
46
+ p,
43
47
  {
44
48
  "data-testid": "delete-button",
45
49
  variant: "danger",
46
50
  label: e,
47
- onClick: y,
48
- disabled: !m
51
+ onClick: _,
52
+ disabled: !m || !u
49
53
  }
50
54
  ),
51
55
  footerSupplemental: /* @__PURE__ */ o(
52
- u,
56
+ p,
53
57
  {
54
58
  "data-testid": "cancel-button",
55
59
  variant: "text",
56
60
  label: n,
57
61
  onClick: () => {
58
- _?.(), d(!1);
62
+ C?.(), d(!1);
59
63
  }
60
64
  }
61
65
  ),
62
- children: /* @__PURE__ */ p(c, { direction: "vertical", secondaryAlign: "center", children: [
63
- /* @__PURE__ */ o(z, { element: /* @__PURE__ */ o(P, { icon: b }), isCrossedOut: g }),
64
- /* @__PURE__ */ o(c, { direction: "vertical", children: m ? /* @__PURE__ */ o(
65
- A,
66
+ children: /* @__PURE__ */ f(i, { direction: "vertical", secondaryAlign: "center", children: [
67
+ /* @__PURE__ */ o(A, { element: /* @__PURE__ */ o(G, { icon: g }), isCrossedOut: h }),
68
+ /* @__PURE__ */ o(i, { direction: "vertical", children: m ? /* @__PURE__ */ o(
69
+ q,
66
70
  {
67
71
  deleteHeader: a,
68
- deleteText: f,
72
+ deleteText: b,
69
73
  deleteBody: s
70
74
  }
71
- ) : /* @__PURE__ */ o(G, { impossibleDeleteHeader: h }) })
75
+ ) : /* @__PURE__ */ o(F, { impossibleDeleteHeader: v }) })
72
76
  ] })
73
77
  }
74
78
  );
75
- }, z = ({
79
+ }, A = ({
76
80
  element: r,
77
81
  isCrossedOut: e = !1
78
- }) => e ? /* @__PURE__ */ o("span", { className: t.crossedOut, children: r }) : r, P = ({ icon: r }) => r ? typeof r != "string" ? r : Object.values(I).includes(r) ? /* @__PURE__ */ o(
79
- O,
82
+ }) => e ? /* @__PURE__ */ o("span", { className: t.crossedOut, children: r }) : r, G = ({ icon: r }) => r ? typeof r != "string" ? r : Object.values(S).includes(r) ? /* @__PURE__ */ o(
83
+ B,
80
84
  {
81
85
  icon: r,
82
86
  iconSize: "xlarge",
83
87
  className: t.colorDanger
84
88
  }
85
- ) : /* @__PURE__ */ o(D, { icon: r, iconSize: "xlarge", className: t.colorDanger }) : /* @__PURE__ */ o(i, {}), A = ({
89
+ ) : /* @__PURE__ */ o(I, { icon: r, iconSize: "xlarge", className: t.colorDanger }) : /* @__PURE__ */ o(c, {}), q = ({
86
90
  deleteHeader: r,
87
91
  deleteText: e,
88
92
  deleteBody: n
89
- }) => /* @__PURE__ */ p(i, { children: [
93
+ }) => /* @__PURE__ */ f(c, { children: [
90
94
  /* @__PURE__ */ o(l, { level: 1, themeColor: "text-primary-on-background", children: r }),
91
95
  e && typeof e == "string" && /* @__PURE__ */ o(l, { level: 2, themeColor: "text-secondary-on-background", children: e }),
92
- e && typeof e != "string" && /* @__PURE__ */ o(i, { children: e }),
93
- n && e === void 0 && /* @__PURE__ */ o(c, { direction: "vertical", gap: "none", children: n.map((a, s) => /* @__PURE__ */ o(
96
+ e && typeof e != "string" && /* @__PURE__ */ o(c, { children: e }),
97
+ n && e === void 0 && /* @__PURE__ */ o(i, { direction: "vertical", gap: "none", children: n.map((a, s) => /* @__PURE__ */ o(
94
98
  l,
95
99
  {
96
100
  level: 2,
@@ -98,11 +102,11 @@ import '../../assets/DeleteModal.css';const x = "_bulletPoint_bd412_1", B = "_mo
98
102
  themeColor: "text-secondary-on-background",
99
103
  children: a
100
104
  },
101
- k(s.toString())
105
+ N(s.toString())
102
106
  )) })
103
- ] }), G = ({
107
+ ] }), F = ({
104
108
  impossibleDeleteHeader: r
105
109
  }) => /* @__PURE__ */ o(l, { level: 1, themeColor: "text-primary-on-background", children: r });
106
110
  export {
107
- R as DeleteModal
111
+ V as DeleteModal
108
112
  };
@@ -1,12 +1,12 @@
1
1
  import { jsx as n } from "react/jsx-runtime";
2
2
  import { a as c, s as e } from "../../react.esm-CX1WJ2Pp.js";
3
- import { DeleteModal as b } from "./DeleteModal.js";
4
- import { d as B, t as a, a as o, g as t } from "../../vi.CjhMlMwf-CKxPQtd6.js";
5
- B("DeleteModal Test", () => {
6
- a("should render the DeleteModal properly", () => {
3
+ import { DeleteModal as a } from "./DeleteModal.js";
4
+ import { d, t as b, a as o, g as t } from "../../vi.CjhMlMwf-CKxPQtd6.js";
5
+ d("DeleteModal Test", () => {
6
+ b("should render the DeleteModal properly", () => {
7
7
  c(
8
8
  /* @__PURE__ */ n(
9
- b,
9
+ a,
10
10
  {
11
11
  icon: "block",
12
12
  open: !0,
@@ -22,10 +22,10 @@ B("DeleteModal Test", () => {
22
22
  }
23
23
  )
24
24
  ), t(e.getByText("DELETE")).toBeInTheDocument(), t(e.getByTestId("block")).toBeInTheDocument(), t(e.getByText("block 1")).toBeInTheDocument(), t(e.getByText("block 2")).toBeInTheDocument(), t(e.getByText("block 3")).toBeInTheDocument(), t(e.getByText("Remove")).toBeInTheDocument(), t(e.getByText("Cancel")).toBeInTheDocument(), t(e.queryByText("block cant be deleted")).not.toBeInTheDocument();
25
- }), a("should render the DeleteModal properly when isDeletePossible = false", () => {
25
+ }), b("should render the DeleteModal properly when isDeletePossible = false", () => {
26
26
  c(
27
27
  /* @__PURE__ */ n(
28
- b,
28
+ a,
29
29
  {
30
30
  icon: "block",
31
31
  open: !0,
@@ -41,11 +41,11 @@ B("DeleteModal Test", () => {
41
41
  }
42
42
  )
43
43
  ), t(e.getByText("DELETE")).toBeInTheDocument(), t(e.getByTestId("block")).toBeInTheDocument(), t(e.queryByText("block 1")).not.toBeInTheDocument(), t(e.queryByText("block 2")).not.toBeInTheDocument(), t(e.queryByText("block 3")).not.toBeInTheDocument(), t(e.getByText("Remove")).toBeInTheDocument(), t(e.getByText("Remove").parentElement).toBeDisabled(), t(e.getByText("Cancel")).toBeInTheDocument(), t(e.queryByText("block cant be deleted")).toBeInTheDocument();
44
- }), a("should call setOpen with false when clicking on cancel button", () => {
44
+ }), b("should call setOpen with false when clicking on cancel button", () => {
45
45
  const l = o.fn();
46
46
  c(
47
47
  /* @__PURE__ */ n(
48
- b,
48
+ a,
49
49
  {
50
50
  icon: "block",
51
51
  open: !0,
@@ -61,11 +61,11 @@ B("DeleteModal Test", () => {
61
61
  }
62
62
  )
63
63
  ), e.getByText("Cancel").click(), t(l).toHaveBeenCalledWith(!1);
64
- }), a("should call onDelete when clicking on delete button", () => {
64
+ }), b("should call onDelete when clicking on delete button", () => {
65
65
  const l = o.fn();
66
66
  c(
67
67
  /* @__PURE__ */ n(
68
- b,
68
+ a,
69
69
  {
70
70
  icon: "block",
71
71
  open: !0,
@@ -81,5 +81,29 @@ B("DeleteModal Test", () => {
81
81
  }
82
82
  )
83
83
  ), e.getByText("Remove").click(), t(l).toHaveBeenCalled();
84
+ }), b("render DeleteModal with OfflineView", () => {
85
+ const l = o.fn();
86
+ c(
87
+ /* @__PURE__ */ n(
88
+ a,
89
+ {
90
+ icon: "block",
91
+ open: !0,
92
+ setOpen: o.fn(),
93
+ onDelete: l,
94
+ title: "DELETE",
95
+ confirmButtonLabel: "Remove",
96
+ cancelButtonLabel: "Cancel",
97
+ deleteHeader: "Delete my block",
98
+ impossibleDeleteHeader: "block cant be deleted",
99
+ deleteBody: ["block 1", "block 2", "block 3"],
100
+ isDeletePossible: !0,
101
+ isOnline: !1,
102
+ offlineViewProps: {
103
+ "data-testid": "offline-test"
104
+ }
105
+ }
106
+ )
107
+ ), e.getByText("Remove").click(), t(l).not.toHaveBeenCalled(), t(e.getByTestId("offline-test")).toBeInTheDocument();
84
108
  });
85
109
  });
@@ -1,5 +1,5 @@
1
1
  import { jsxs as e, jsx as r, Fragment as n } from "react/jsx-runtime";
2
- import { G as i } from "../../index.es-DntoATwO.js";
2
+ import { G as i } from "../../index.es-CbBdaRO2.js";
3
3
  import { BasicHeading as a } from "../BasicHeading/BasicHeading.js";
4
4
  import '../../assets/DetailContentWrapper.css';const m = "_formContainer_gf66t_1", s = {
5
5
  formContainer: m
@@ -1,7 +1,7 @@
1
1
  import { jsxs as l, jsx as r } from "react/jsx-runtime";
2
- import { G as n } from "../../index.es-DntoATwO.js";
3
- import { I as t } from "../../index.es-3043KTnb.js";
4
- import { d as m, T as d } from "../../index.es-D54RuMc_.js";
2
+ import { G as n } from "../../index.es-CbBdaRO2.js";
3
+ import { I as t } from "../../index.es-DErA6zWG.js";
4
+ import { d as m, T as d } from "../../index.es--yyG47az.js";
5
5
  import '../../assets/Disclaimer.css';const p = "_disclaimer_1k38t_1", y = "_iconArea_1k38t_7", a = {
6
6
  disclaimer: p,
7
7
  iconArea: y
@@ -1,9 +1,9 @@
1
1
  import { jsx as m, jsxs as $ } from "react/jsx-runtime";
2
- import { G as _ } from "../../index.es-DntoATwO.js";
3
- import { c as P, _ as T, P as e } from "../../identity-DLWZln-X.js";
2
+ import { G as _ } from "../../index.es-CbBdaRO2.js";
3
+ import { c as P, _ as T, P as e } from "../../_setToString-Do1lSQTZ.js";
4
4
  import c, { forwardRef as C, useRef as w, useImperativeHandle as H, useMemo as y } from "react";
5
- import { e as N, T as O } from "../../index.es-D54RuMc_.js";
6
- import { I as B } from "../../index.es-3043KTnb.js";
5
+ import { e as N, T as O } from "../../index.es--yyG47az.js";
6
+ import { I as B } from "../../index.es-DErA6zWG.js";
7
7
  const j = {
8
8
  /**
9
9
  * Aligns the Hero contents.
@@ -1,20 +1,21 @@
1
1
  import { jsx as e, jsxs as b, Fragment as D } from "react/jsx-runtime";
2
- import { N as F } from "../../index.es-fnFnw2P1.js";
3
- import { B as p } from "../../index.es-CiqbARoC.js";
4
- import { G as _ } from "../../index.es-DntoATwO.js";
5
- import { I as W } from "../../index.es-0lQcz8m1.js";
6
- import { S as j } from "../../index.es-8GOVkuo-.js";
2
+ import { N as F } from "../../index.es-CPqaUyn3.js";
3
+ import { B as h } from "../../index.es-Bx1E5MPK.js";
4
+ import { G as _ } from "../../index.es-CbBdaRO2.js";
5
+ import { I as W } from "../../index.es-Kg9soDed.js";
6
+ import { S as j } from "../../index.es-CqgVUhln.js";
7
7
  import { useState as v } from "react";
8
8
  import { Iconify as z } from "../Iconify/Iconify.js";
9
9
  import { u as k } from "../../useBreakpoints-MzTZ0tCT.js";
10
10
  import "../../react-tooltip.min-DSY6KDqS.js";
11
- import "../../orderBy-Bd48bw88.js";
11
+ import "../../orderBy-CyjsW2ET.js";
12
12
  import { SearchBar as G } from "../SearchBar/SearchBar.js";
13
13
  import "../../uniqueId-NU3-C36A.js";
14
14
  import { Modal as H } from "../Modal/Modal.js";
15
15
  import { Select as I } from "../Select/Select.js";
16
16
  import "react-hook-form";
17
- import "../../get-DFv1gXfq.js";
17
+ import "../../get-B8c-T4F8.js";
18
+ import "../../omit-1Eom1PmQ.js";
18
19
  import "../../isArray-Dub1wGJM.js";
19
20
  import "../../isString-BW9UHONv.js";
20
21
  import '../../assets/Filter.css';const K = "_filterButton_qtl7a_1", T = "_relativeParent_qtl7a_6", V = "_filterBadge_qtl7a_10", E = "_dense_qtl7a_17", u = {
@@ -22,7 +23,7 @@ import '../../assets/Filter.css';const K = "_filterButton_qtl7a_1", T = "_relati
22
23
  relativeParent: T,
23
24
  filterBadge: V,
24
25
  dense: E
25
- }, mt = ({
26
+ }, ct = ({
26
27
  clearFilterText: m,
27
28
  closeCallback: s,
28
29
  currentFilter: i,
@@ -31,7 +32,7 @@ import '../../assets/Filter.css';const K = "_filterButton_qtl7a_1", T = "_relati
31
32
  filterModalTitle: t,
32
33
  filters: f,
33
34
  modalCancelButtonText: g,
34
- modalConfirmButtonText: h,
35
+ modalConfirmButtonText: p,
35
36
  useModal: o = !0,
36
37
  selectAllLabel: r,
37
38
  "data-testid": w
@@ -67,9 +68,9 @@ import '../../assets/Filter.css';const K = "_filterButton_qtl7a_1", T = "_relati
67
68
  onClose: x,
68
69
  title: t,
69
70
  modalSize: A ? "small" : "fullscreen",
70
- headerActions: /* @__PURE__ */ e(p, { "data-testid": "filter-clear-button", variant: "text", onClick: O, children: m }),
71
+ headerActions: /* @__PURE__ */ e(h, { "data-testid": "filter-clear-button", variant: "text", onClick: O, children: m }),
71
72
  dismissiveButton: /* @__PURE__ */ e(
72
- p,
73
+ h,
73
74
  {
74
75
  "data-testid": "filter-cancel-button",
75
76
  variant: "outlined",
@@ -77,13 +78,13 @@ import '../../assets/Filter.css';const K = "_filterButton_qtl7a_1", T = "_relati
77
78
  children: g
78
79
  }
79
80
  ),
80
- primaryButton: /* @__PURE__ */ e(p, { "data-testid": "filter-confirm-button", variant: "filled", onClick: x, children: h }),
81
+ primaryButton: /* @__PURE__ */ e(h, { "data-testid": "filter-confirm-button", variant: "filled", onClick: x, children: p }),
81
82
  children: /* @__PURE__ */ e(_, { direction: "vertical", "data-testid": "filter-map-filters", children: N(f, c, S, r) })
82
83
  }
83
84
  )
84
85
  ] }) : /* @__PURE__ */ e(_, { secondaryAlign: "center", fullWidth: !0, children: N(f, c, S, r, !1) });
85
- }, N = (m, s, i, d, a = !0) => m.map(({ id: t, title: f, availableOptions: g, icon: h, type: o }) => /* @__PURE__ */ b(_, { fullWidth: !0, secondaryAlign: "center", "data-testid": `filter-${o}-group-${t}`, children: [
86
- h ? /* @__PURE__ */ e(z, { icon: h, iconSize: "medium" }) : null,
86
+ }, N = (m, s, i, d, a = !0) => m.map(({ id: t, title: f, availableOptions: g, icon: p, type: o }) => /* @__PURE__ */ b(_, { fullWidth: !0, secondaryAlign: "center", "data-testid": `filter-${o}-group-${t}`, children: [
87
+ p ? /* @__PURE__ */ e(z, { icon: p, iconSize: "medium" }) : null,
87
88
  o === "select" && /* @__PURE__ */ e(
88
89
  I,
89
90
  {
@@ -157,7 +158,7 @@ import '../../assets/Filter.css';const K = "_filterButton_qtl7a_1", T = "_relati
157
158
  style: { height: "100%", width: t ? void 0 : "100%" },
158
159
  children: [
159
160
  /* @__PURE__ */ e(
160
- p,
161
+ h,
161
162
  {
162
163
  "data-testid": "filter-button",
163
164
  variant: "outlined",
@@ -183,5 +184,5 @@ import '../../assets/Filter.css';const K = "_filterButton_qtl7a_1", T = "_relati
183
184
  );
184
185
  };
185
186
  export {
186
- mt as Filter
187
+ ct as Filter
187
188
  };
@@ -1,5 +1,5 @@
1
1
  import { jsx as r } from "react/jsx-runtime";
2
- import { C as m } from "../../../index.es-BvrQnJ3j.js";
2
+ import { C as m } from "../../../index.es-oOD85ZwA.js";
3
3
  import { useFormContext as k, Controller as C } from "react-hook-form";
4
4
  import '../../../assets/FormCheckBox.css';const b = "_invalid_1l2r2_1", d = "_checkbox_1l2r2_5", c = {
5
5
  invalid: b,
@@ -1,8 +1,8 @@
1
1
  import { jsx as C, jsxs as pa } from "react/jsx-runtime";
2
- import { B as ba } from "../../../index.es-CiqbARoC.js";
3
- import { b as u, a as o, c as d, d as s, r as wa, s as be, t as M, m as j, l as D, f as z, e as N, g as ya, D as Pa } from "../../../index.es-CoFul5zR.js";
4
- import { D as ka } from "../../../index.es-BWgXLqXn.js";
5
- import { P as Ma } from "../../../index.es-D-CKRzIB.js";
2
+ import { B as ba } from "../../../index.es-Bx1E5MPK.js";
3
+ import { b as u, a as o, c as d, d as s, r as wa, s as be, t as M, m as j, l as D, f as z, e as N, g as ya, D as Pa } from "../../../index.es-BoWmBoqO.js";
4
+ import { D as ka } from "../../../index.es-BTc2I5pe.js";
5
+ import { P as Ma } from "../../../index.es-D-ph6ImM.js";
6
6
  import { useMemo as V, useState as $a } from "react";
7
7
  import { useFormContext as Wa, Controller as ja } from "react-hook-form";
8
8
  import { useHelperText as Da } from "../../../hooks/useHelperText.js";
@@ -1,25 +1,26 @@
1
1
  import { jsx as m } from "react/jsx-runtime";
2
- import { T as d } from "../../../index.es-25EARqhH.js";
3
- import { g as u } from "../../../get-DFv1gXfq.js";
4
- import { useMemo as g } from "react";
2
+ import { T as d } from "../../../index.es-CUuzYysw.js";
3
+ import { g as u } from "../../../get-B8c-T4F8.js";
4
+ import { o as g } from "../../../omit-1Eom1PmQ.js";
5
+ import { useMemo as f } from "react";
5
6
  import { useFormContext as v } from "react-hook-form";
6
- import '../../../assets/CustomTextField.css';const f = "_invalid_1dsbr_1", c = {
7
- invalid: f
8
- }, T = ({ ...e }) => {
7
+ import '../../../assets/CustomTextField.css';const c = "_invalid_1dsbr_1", s = {
8
+ invalid: c
9
+ }, C = ({ ...e }) => {
9
10
  const {
10
11
  getFieldState: r,
11
12
  formState: { errors: n },
12
13
  trigger: i,
13
- watch: l
14
- } = v(), a = l(e.propertyName), o = g(() => {
14
+ watch: o
15
+ } = v(), a = o(e.propertyName), l = f(() => {
15
16
  if (!(!a || e.value === null))
16
17
  return e.value;
17
18
  }, [a, e.value]);
18
19
  return /* @__PURE__ */ m(
19
20
  d,
20
21
  {
21
- ...e,
22
- value: o,
22
+ ...g(e, ["propertyName", "formOnBlur", "additionalTrigger"]),
23
+ value: l,
23
24
  "data-testid": `numeric-field-${e.propertyName}`,
24
25
  fullWidth: !0,
25
26
  inputMode: "decimal",
@@ -32,10 +33,10 @@ import '../../../assets/CustomTextField.css';const f = "_invalid_1dsbr_1", c = {
32
33
  },
33
34
  valid: !r(e.propertyName).invalid,
34
35
  helperTextPersistent: u(n, e.propertyName) !== void 0 || e.helperTextPersistent,
35
- className: r(e.propertyName).invalid ? c.invalid : ""
36
+ className: r(e.propertyName).invalid ? s.invalid : ""
36
37
  }
37
38
  );
38
39
  };
39
40
  export {
40
- T as CustomTextField
41
+ C as CustomTextField
41
42
  };
@@ -1,5 +1,5 @@
1
1
  import { jsx as r, Fragment as m } from "react/jsx-runtime";
2
- import { R as d } from "../../../index.es-BtjV0oNv.js";
2
+ import { R as d } from "../../../index.es-Bf149BSP.js";
3
3
  import { useFormContext as s, Controller as c } from "react-hook-form";
4
4
  const g = ({ propertyName: l, options: t }) => {
5
5
  const { control: n, setValue: o } = s(), u = (a) => {
@@ -1,5 +1,5 @@
1
1
  import { jsx as o, Fragment as g, jsxs as k } from "react/jsx-runtime";
2
- import { g as x } from "../../../get-DFv1gXfq.js";
2
+ import { g as x } from "../../../get-B8c-T4F8.js";
3
3
  import { i as G } from "../../../isArray-Dub1wGJM.js";
4
4
  import { useMemo as z } from "react";
5
5
  import { useFormContext as J, Controller as C } from "react-hook-form";
@@ -1,6 +1,6 @@
1
1
  import { jsx as i } from "react/jsx-runtime";
2
- import { G as p } from "../../../index.es-DntoATwO.js";
3
- import { T as d } from "../../../index.es-D54RuMc_.js";
2
+ import { G as p } from "../../../index.es-CbBdaRO2.js";
3
+ import { T as d } from "../../../index.es--yyG47az.js";
4
4
  const m = ({ value: r, textKey: t, valueKey: e }) => {
5
5
  if (!(!r || r.length === 0))
6
6
  return Array.isArray(r) ? /* @__PURE__ */ i(p, { "data-testid": "select-tooltip", direction: "vertical", gap: "dense", children: r?.map((o) => /* @__PURE__ */ i(d, { level: 2, children: o[t] }, o[e])) }) : r?.[t];
@@ -1,9 +1,9 @@
1
1
  import { jsx as Y } from "react/jsx-runtime";
2
- import { _ as O, c as F, P as l } from "../../../identity-DLWZln-X.js";
2
+ import { _ as O, c as F, P as l } from "../../../_setToString-Do1lSQTZ.js";
3
3
  import c, { forwardRef as ft, useRef as tt, useImperativeHandle as et, useCallback as B, useEffect as k, useMemo as rt } from "react";
4
- import { I as nt } from "../../../index.es-3043KTnb.js";
5
- import { T as it } from "../../../index.es-25EARqhH.js";
6
- import { c as at } from "../../../index.es-da0cf7oE.js";
4
+ import { I as nt } from "../../../index.es-DErA6zWG.js";
5
+ import { T as it } from "../../../index.es-CUuzYysw.js";
6
+ import { c as at } from "../../../index.es-DlzwTKbh.js";
7
7
  import { b as dt, c as K } from "../../../tslib.es6-BDCynO9F.js";
8
8
  import { M as gt, a as Et } from "../../../component-neHBNHRu.js";
9
9
  import { M as st, a as bt, m as It, b as St } from "../../../component-DsB0poTj.js";
@@ -1,6 +1,6 @@
1
1
  import { jsx as t, Fragment as v, jsxs as z } from "react/jsx-runtime";
2
- import { T as M } from "../../../index.es-25EARqhH.js";
3
- import { a as P } from "../../../index.es-D54RuMc_.js";
2
+ import { T as M } from "../../../index.es-CUuzYysw.js";
3
+ import { a as P } from "../../../index.es--yyG47az.js";
4
4
  import { useState as V, useCallback as W, useMemo as m } from "react";
5
5
  import { useFormContext as D, Controller as _ } from "react-hook-form";
6
6
  import { useHelperText as E } from "../../../hooks/useHelperText.js";
@@ -1,7 +1,7 @@
1
1
  import { jsx as t, jsxs as p } from "react/jsx-runtime";
2
- import { G as d } from "../../../index.es-DntoATwO.js";
3
- import { S as f } from "../../../index.es-8GOVkuo-.js";
4
- import { a as h } from "../../../index.es-D54RuMc_.js";
2
+ import { G as d } from "../../../index.es-CbBdaRO2.js";
3
+ import { S as f } from "../../../index.es-CqgVUhln.js";
4
+ import { a as h } from "../../../index.es--yyG47az.js";
5
5
  import { u as C } from "../../../uniqueId-NU3-C36A.js";
6
6
  import { useEffect as x } from "react";
7
7
  import { useFormContext as T, Controller as y } from "react-hook-form";
@@ -60,6 +60,8 @@ import { TableLayoutProps } from '../../types/GenericTable';
60
60
  * @param tableActionPosition position of the table actions, can be 'start' or 'end'
61
61
  * @param tableElevationLevel elevation level of the table
62
62
  * @param tableLayout layout of the table, can be 'standard' or 'flex'
63
+ * @param isOnline Whether the user is online; shows OfflineView when false.
64
+ * @param offlineViewProps Props forwarded to OfflineView when offline.
63
65
  * @returns a table based on a given type and data
64
66
  */
65
- export declare const GenericTable: <T>({ data, hiddenColumns, order, cellTemplates, tableActions, noContentText, headerTranslation, pagination, getRowActions, customColumnWidth, title, cardTitleColumn, cardSubTitleColumn, pageTranslation, pageOfTranslation, rowsPerPageTranslation, tableActionPosition, tableElevationLevel, tableLayout, }: TableLayoutProps<T>) => import("react/jsx-runtime").JSX.Element;
67
+ export declare const GenericTable: <T>({ data, hiddenColumns, order, cellTemplates, tableActions, noContentText, headerTranslation, pagination, getRowActions, customColumnWidth, title, cardTitleColumn, cardSubTitleColumn, pageTranslation, pageOfTranslation, rowsPerPageTranslation, tableActionPosition, tableElevationLevel, tableLayout, isOnline, offlineViewProps, }: TableLayoutProps<T>) => import("react/jsx-runtime").JSX.Element;