@deviceinsight/ng-ui-scale-lib 9.19.0 → 9.20.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 (32) hide show
  1. package/dist/{AccessEditModal-38c11d48.js → AccessEditModal-ee0139fb.js} +14 -14
  2. package/dist/BundleManagementContainer-093786e5.js +20 -0
  3. package/dist/{BundlesContainer-ff572d82.js → BundlesContainer-54c9cc3a.js} +29 -26
  4. package/dist/{ContextBarContext-0565a593.js → ContextBarContext-0c28ce9d.js} +38167 -46135
  5. package/dist/{DatapointImport-2deee17a.js → DatapointImport-6d394cb5.js} +96 -93
  6. package/dist/{FileUploadInput-87e9d774.js → FileUploadInput-a23ba785.js} +3 -3
  7. package/dist/{Files-f6c464c2.js → Files-4fc0415e.js} +42 -39
  8. package/dist/GlobalPowerBiReports-f9bf0765.js +11079 -0
  9. package/dist/{Graph-fce6bde2.js → Graph-2840eac2.js} +4 -1
  10. package/dist/JsonSettingWidget-8908d40b.js +57 -0
  11. package/dist/{LicensesEditPage-effb07a9.js → LicensesEditPage-3332b87c.js} +33 -30
  12. package/dist/{LicensesList-7832868c.js → LicensesList-6254cd37.js} +12 -9
  13. package/dist/{PropertiesEditPage-e84dd613.js → PropertiesEditPage-5b148652.js} +24 -21
  14. package/dist/{PropertiesList-e8f218de.js → PropertiesList-06478803.js} +14 -11
  15. package/dist/{TemplateEditPage-a3994735.js → TemplateEditPage-94088888.js} +13 -10
  16. package/dist/TemplateTextInput-e8861a0f.js +50 -0
  17. package/dist/{TemplatesListPage-86d0d508.js → TemplatesListPage-866246c6.js} +53 -50
  18. package/dist/{UserGroupAssignments-b2e98796.js → UserGroupAssignments-6feae326.js} +34 -31
  19. package/dist/{UserGroupTheme-6e262174.js → UserGroupTheme-7ee8e92e.js} +14 -11
  20. package/dist/api.d.ts +3 -0
  21. package/dist/api.js +59 -56
  22. package/dist/{index-8f79799f.js → index-34a2015c.js} +7 -7
  23. package/dist/index.js +2761 -2765
  24. package/dist/objectWithoutPropertiesLoose-a4604547.js +26 -0
  25. package/dist/{react-router-824f2efe.js → react-router-d38ecdf4.js} +113 -108
  26. package/dist/style.css +1 -1
  27. package/package.json +4 -4
  28. package/dist/BundleManagementContainer-0efa3cec.js +0 -17
  29. package/dist/GlobalPowerBiReports-f448278b.js +0 -11078
  30. package/dist/JsonSettingWidget-0360cf69.js +0 -54
  31. package/dist/TemplateTextInput-712d3528.js +0 -47
  32. package/dist/extends-0a3e0827.js +0 -13
@@ -1,29 +1,29 @@
1
- import { aA as g, aj as y, a_ as w, az as e, ai as r, bR as I, di as U, dj as _, dk as O, cj as b, dl as m } from "./ContextBarContext-0565a593.js";
1
+ import { ax as A, ah as j, aX as w, aw as e, ag as r, bP as I, df as U, dg as O, dh as _, cg as b, di as m } from "./ContextBarContext-0c28ce9d.js";
2
2
  import { useState as f, useContext as E, useMemo as M } from "react";
3
3
  import { Modal as k, SpinnerContainer as K, Button as x } from "@deviceinsight/ng-ui-basic-components";
4
4
  import { InfoBox as F } from "@deviceinsight/ng-ui-components";
5
- import { searchUserGroups as R } from "@deviceinsight/ng-ui-api-client";
6
- const W = "usergroupsWithoutAccessToTemplate";
7
- function z(o) {
5
+ import { searchUserGroups as W } from "@deviceinsight/ng-ui-api-client";
6
+ const L = "usergroupsWithoutAccessToTemplate";
7
+ function N(o) {
8
8
  return {
9
9
  fields: b,
10
- search: (s, t) => R(o(s), t)
10
+ search: (s, t) => W(o(s), t)
11
11
  };
12
12
  }
13
- function L(o, s) {
13
+ function P(o, s) {
14
14
  return s ? m(
15
15
  s.filter((t) => !o.includes(t)),
16
16
  !1
17
17
  ) : m(o, !0);
18
18
  }
19
19
  function q({ onSave: o, onCancel: s, loading: t, template: n }) {
20
- const [i, T] = f([]), [a, S] = f(!0), { user: u } = E(g), l = n && n.accountGroupsWithAccess || [], C = a ? u.accountGroupIds ?? [] : null, G = M(
20
+ const [i, T] = f([]), [a, S] = f(!0), { user: u } = E(A), l = n && n.accountGroupsWithAccess || [], C = a ? u.accountGroupIds ?? [] : null, G = M(
21
21
  () => Math.random(),
22
22
  // eslint-disable-next-line react-hooks/exhaustive-deps
23
23
  [a]
24
- ), { t: d } = y(), h = w(["ACCESS_TO_ALL_NOTIFICATION_TEMPLATES"]), j = (n == null ? void 0 : n.accountGroupsWithAccess) ?? [], p = [...i, ...j].some(
24
+ ), { t: d } = j(), h = w(["ACCESS_TO_ALL_NOTIFICATION_TEMPLATES"]), g = (n == null ? void 0 : n.accountGroupsWithAccess) ?? [], p = [...i, ...g].some(
25
25
  (c) => u.accountGroupIds.includes(c)
26
- ), A = !h && !p || t;
26
+ ), y = !h && !p || t;
27
27
  return /* @__PURE__ */ e.jsx(
28
28
  k,
29
29
  {
@@ -44,15 +44,15 @@ function q({ onSave: o, onCancel: s, loading: t, template: n }) {
44
44
  /* @__PURE__ */ e.jsx(
45
45
  U,
46
46
  {
47
- searchContext: W,
48
- searchConfig: z(L(l, C)),
49
- columnDefinitions: _(!0),
47
+ searchContext: L,
48
+ searchConfig: N(P(l, C)),
49
+ columnDefinitions: O(!0),
50
50
  uniqueItemKey: (c) => c.id,
51
51
  pageSize: 5,
52
52
  onSelectSome: T,
53
53
  updateTrigger: G,
54
54
  extraHeaderComponent: () => /* @__PURE__ */ e.jsx(
55
- O,
55
+ _,
56
56
  {
57
57
  style: {
58
58
  flexGrow: 1,
@@ -77,7 +77,7 @@ function q({ onSave: o, onCancel: s, loading: t, template: n }) {
77
77
  x,
78
78
  {
79
79
  primary: !0,
80
- disabled: A,
80
+ disabled: y,
81
81
  onClick: () => o([...l, ...i], n),
82
82
  children: /* @__PURE__ */ e.jsx(r, { i18nKey: "general.actions.save", children: "Save" })
83
83
  }
@@ -0,0 +1,20 @@
1
+ import { bw as n, aw as r } from "./ContextBarContext-0c28ce9d.js";
2
+ import { useContext as m, useEffect as s } from "react";
3
+ import { useLocation as i } from "react-router-dom";
4
+ import { messageBoxDismissGroup as a } from "@deviceinsight/ng-ui-components";
5
+ import { M as p } from "./consts-012135e5.js";
6
+ import "@deviceinsight/ng-ui-basic-components";
7
+ import "react-i18next";
8
+ import "i18next";
9
+ import "@deviceinsight/ng-ui-api-client";
10
+ import "ux4iot-react";
11
+ import "react-dom";
12
+ function I({ children: o }) {
13
+ const { setContextInfo: t } = m(n), { pathname: e } = i();
14
+ return s(() => (t(), () => {
15
+ a(p), t();
16
+ }), [e, t]), /* @__PURE__ */ r.jsx("div", { children: o });
17
+ }
18
+ export {
19
+ I as default
20
+ };
@@ -1,12 +1,15 @@
1
- import { aj as S, bi as P, az as e, ai as r, bo as A, ba as I, d8 as T, aT as F, b7 as re, am as ae, d9 as ie, cq as q, da as oe } from "./ContextBarContext-0565a593.js";
1
+ import { ah as S, bf as P, aw as e, ag as r, bl as A, b7 as I, d5 as T, aQ as F, b4 as re, aj as ae, d6 as ie, cn as q, d7 as oe } from "./ContextBarContext-0c28ce9d.js";
2
2
  import { useEffect as D, useState as V, useRef as ce, useCallback as ue, createElement as he } from "react";
3
3
  import { useLocation as me } from "react-router-dom";
4
4
  import { createBundle as xe, deleteBundleFile as je, createBundleFile as fe, releaseBundleVersion as Ee, fetchBundleVersion as G, fetchBundleFiles as z, createBundleVersion as ge, deleteBundleVersion as Be, downloadBundleFile as be, fetchBundleVersions as W, deleteBundle as Ve, fetchAllBundles as De } from "@deviceinsight/ng-ui-api-client";
5
5
  import { messageBoxSuccess as $, messageBoxError as H, ReactableWithClientSidePagination as Ne, Reactable as Te, ContentHeader as ve } from "@deviceinsight/ng-ui-components";
6
- import { Modal as _, SpinnerContainer as N, Button as j, Icon as v, Label as _e, AccordionItem as ye, Accordion as pe } from "@deviceinsight/ng-ui-basic-components";
6
+ import "react-i18next";
7
+ import { Modal as p, SpinnerContainer as N, Button as j, Icon as v, Label as pe, AccordionItem as _e, Accordion as ye } from "@deviceinsight/ng-ui-basic-components";
7
8
  import { B as c, Q, a as Ce } from "./consts-012135e5.js";
8
- import { F as Le } from "./FileUploadInput-87e9d774.js";
9
+ import { F as Le } from "./FileUploadInput-a23ba785.js";
9
10
  import { u as Se, b as Ae } from "./useCanDeleteBundleVersion-64f35949.js";
11
+ import "i18next";
12
+ import "ux4iot-react";
10
13
  import "react-dom";
11
14
  const Y = (n) => {
12
15
  n && setTimeout(() => n.focus(), 0);
@@ -34,7 +37,7 @@ const Y = (n) => {
34
37
  console.warn("Validation error", o);
35
38
  })();
36
39
  return Z(u, !1), /* @__PURE__ */ e.jsx(
37
- _,
40
+ p,
38
41
  {
39
42
  width: 400,
40
43
  header: /* @__PURE__ */ e.jsx(r, { i18nKey: "bundle.create.title", children: "Create new Bundle" }),
@@ -345,7 +348,7 @@ const J = [
345
348
  )
346
349
  }
347
350
  ], X = ({ count: n }) => /* @__PURE__ */ e.jsx(
348
- _e,
351
+ pe,
349
352
  {
350
353
  className: "neutral",
351
354
  style: {
@@ -468,8 +471,8 @@ const J = [
468
471
  },
469
472
  onChange: (E) => {
470
473
  if (E) {
471
- const y = new FormData();
472
- y.append("file", E), B(y);
474
+ const _ = new FormData();
475
+ _.append("file", E), B(_);
473
476
  }
474
477
  }
475
478
  },
@@ -485,7 +488,7 @@ const J = [
485
488
  }, en = {
486
489
  id: "bundlemanagement.releaseBundleVersionSuccess",
487
490
  defaultValue: "The version was published"
488
- }, p = {
491
+ }, y = {
489
492
  id: "bundlemanagement.modalCloseButton",
490
493
  defaultValue: "Close"
491
494
  }, C = {
@@ -524,7 +527,7 @@ const J = [
524
527
  }, [t, b, n]);
525
528
  const B = !!(x.data && x.data.length);
526
529
  return /* @__PURE__ */ e.jsx(
527
- _,
530
+ p,
528
531
  {
529
532
  width: 500,
530
533
  header: t ? /* @__PURE__ */ e.jsx(r, { i18nKey: "bundleversion.editversion", children: "Add Files" }) : /* @__PURE__ */ e.jsx(r, { i18nKey: "bundleversion.addversion", children: "Create new Version" }),
@@ -545,7 +548,7 @@ const J = [
545
548
  children: /* @__PURE__ */ e.jsx(r, { i18nKey: "bundlemanagement.publish", children: "Publish" })
546
549
  }
547
550
  ),
548
- /* @__PURE__ */ e.jsx(j, { onClick: d, "data-testid": c.CANCEL_SAVE_VERSION_BUTTON, children: /* @__PURE__ */ e.jsx(r, { i18nKey: p.id, children: p.defaultValue }) })
551
+ /* @__PURE__ */ e.jsx(j, { onClick: d, "data-testid": c.CANCEL_SAVE_VERSION_BUTTON, children: /* @__PURE__ */ e.jsx(r, { i18nKey: y.id, children: y.defaultValue }) })
549
552
  ] }) : /* @__PURE__ */ e.jsxs(e.Fragment, { children: [
550
553
  /* @__PURE__ */ e.jsx(
551
554
  j,
@@ -590,7 +593,7 @@ const J = [
590
593
  successMessages: hn
591
594
  }), a = Se(n, t), i = () => l(n.id, t.id).then(d).then(s);
592
595
  return /* @__PURE__ */ e.jsx(
593
- _,
596
+ p,
594
597
  {
595
598
  header: /* @__PURE__ */ e.jsx(r, { i18nKey: U.id, children: U.defaultValue }),
596
599
  content: /* @__PURE__ */ e.jsx(cn, { version: t, ...a }),
@@ -626,7 +629,7 @@ const J = [
626
629
  return D(() => {
627
630
  t && (l(n.id, t), u(n.id, t));
628
631
  }, [u, l, t, n]), /* @__PURE__ */ e.jsx(
629
- _,
632
+ p,
630
633
  {
631
634
  width: 500,
632
635
  header: /* @__PURE__ */ e.jsx(r, { i18nKey: "bundleversion.viewVersion", children: "Version Details" }),
@@ -641,7 +644,7 @@ const J = [
641
644
  }
642
645
  )
643
646
  ] }) }),
644
- footer: /* @__PURE__ */ e.jsx(j, { onClick: s, "data-testid": c.MODAL_CLOSE_BUTTON, children: /* @__PURE__ */ e.jsx(r, { i18nKey: p.id, children: p.defaultValue }) })
647
+ footer: /* @__PURE__ */ e.jsx(j, { onClick: s, "data-testid": c.MODAL_CLOSE_BUTTON, children: /* @__PURE__ */ e.jsx(r, { i18nKey: y.id, children: y.defaultValue }) })
645
648
  }
646
649
  );
647
650
  }, En = {
@@ -702,7 +705,7 @@ const J = [
702
705
  s
703
706
  ), [B, f] = V(Bn), {
704
707
  run: E,
705
- data: y,
708
+ data: _,
706
709
  loading: le
707
710
  } = g({
708
711
  requestFunction: W,
@@ -714,7 +717,7 @@ const J = [
714
717
  /* @__PURE__ */ e.jsx(
715
718
  gn,
716
719
  {
717
- versions: y,
720
+ versions: _,
718
721
  paginationSettings: B,
719
722
  setPaginationSettings: f,
720
723
  columnDefs: b,
@@ -765,7 +768,7 @@ const J = [
765
768
  }, Dn = (n) => {
766
769
  const { bundle: t, onDelete: s, isOpen: d } = n, { id: l, name: a } = t;
767
770
  return /* @__PURE__ */ he(
768
- ye,
771
+ _e,
769
772
  {
770
773
  ...n,
771
774
  "data-testid": c.ACCORDION_ITEM + l,
@@ -803,14 +806,14 @@ const J = [
803
806
  }, Tn = ({ bundles: n, onDelete: t, isLoading: s }) => {
804
807
  const d = q(), l = Nn(d, n);
805
808
  return /* @__PURE__ */ e.jsxs(N, { show: s, children: [
806
- /* @__PURE__ */ e.jsx(pe, { accordionClass: "bundles", defaultOpenPageIndex: l, children: (n || []).map((a) => /* @__PURE__ */ e.jsx(Dn, { bundle: a, onDelete: t }, a.name)) }, l),
809
+ /* @__PURE__ */ e.jsx(ye, { accordionClass: "bundles", defaultOpenPageIndex: l, children: (n || []).map((a) => /* @__PURE__ */ e.jsx(Dn, { bundle: a, onDelete: t }, a.name)) }, l),
807
810
  !s && (!n || !n.length) && /* @__PURE__ */ e.jsx(r, { i18nKey: "bundleManagement.noBundles", children: "There are currently no bundles" })
808
811
  ] });
809
812
  }, vn = (n, t) => /* @__PURE__ */ e.jsx("div", { "data-testid": c.DELETE_BUNDLE_DIALOG, children: t || /* @__PURE__ */ e.jsx("p", { children: /* @__PURE__ */ e.jsx(r, { i18nKey: "bundlemanagement.deleteBundleModalBodyError", children: /* @__PURE__ */ e.jsxs(e.Fragment, { children: [
810
813
  "The bundle ",
811
814
  /* @__PURE__ */ e.jsx("strong", { children: n }),
812
815
  " cannot be deleted."
813
- ] }) }) }) }), _n = (n, t) => /* @__PURE__ */ e.jsxs("div", { "data-testid": c.DELETE_BUNDLE_DIALOG, children: [
816
+ ] }) }) }) }), pn = (n, t) => /* @__PURE__ */ e.jsxs("div", { "data-testid": c.DELETE_BUNDLE_DIALOG, children: [
814
817
  /* @__PURE__ */ e.jsx("p", { "data-testid": "deleteBundleModalBody1", children: /* @__PURE__ */ e.jsx(r, { i18nKey: "bundlemanagement.deleteBundleModalBody1", children: /* @__PURE__ */ e.jsxs(e.Fragment, { children: [
815
818
  "Do you really want to delete the bundle ",
816
819
  /* @__PURE__ */ e.jsx("strong", { children: n }),
@@ -822,7 +825,7 @@ const J = [
822
825
  " version(s) and the associated files."
823
826
  ] }) }) }),
824
827
  /* @__PURE__ */ e.jsx("p", { "data-testid": "deleteBundleModalBody3", children: /* @__PURE__ */ e.jsx(r, { i18nKey: "bundlemanagement.deleteBundleModalBody3", children: "This action cannot be undone." }) })
825
- ] }), yn = ({ bundle: n, canBeDeleted: t, error: s, processing: d }) => {
828
+ ] }), _n = ({ bundle: n, canBeDeleted: t, error: s, processing: d }) => {
826
829
  const {
827
830
  run: l,
828
831
  data: a,
@@ -838,20 +841,20 @@ const J = [
838
841
  style: {
839
842
  minHeight: 50
840
843
  },
841
- children: !d && !i && (t ? _n(n.name, a ? a.totalElements.toString() : void 0) : vn(n.name, s))
844
+ children: !d && !i && (t ? pn(n.name, a ? a.totalElements.toString() : void 0) : vn(n.name, s))
842
845
  }
843
846
  ) });
844
- }, pn = [ke], Cn = [Je], Ln = ({ bundle: n, onCancel: t, loadBundles: s }) => {
847
+ }, yn = [ke], Cn = [Je], Ln = ({ bundle: n, onCancel: t, loadBundles: s }) => {
845
848
  const { run: d } = g({
846
849
  requestFunction: Ve,
847
- errorMessages: pn,
850
+ errorMessages: yn,
848
851
  successMessages: Cn
849
852
  }), l = Ae(n), a = () => d(n.id).then(s).then(t);
850
853
  return /* @__PURE__ */ e.jsx(
851
- _,
854
+ p,
852
855
  {
853
856
  header: /* @__PURE__ */ e.jsx(r, { i18nKey: k.id, children: k.defaultValue }),
854
- content: /* @__PURE__ */ e.jsx(yn, { bundle: n, ...l }),
857
+ content: /* @__PURE__ */ e.jsx(_n, { bundle: n, ...l }),
855
858
  footer: /* @__PURE__ */ e.jsxs("div", { children: [
856
859
  /* @__PURE__ */ e.jsx(j, { primary: !0, disabled: !l.canBeDeleted, onClick: a, children: /* @__PURE__ */ e.jsx(r, { i18nKey: C.id, children: C.defaultValue }) }),
857
860
  /* @__PURE__ */ e.jsx(j, { onClick: t, children: /* @__PURE__ */ e.jsx(r, { i18nKey: L.id, children: L.defaultValue }) })
@@ -859,7 +862,7 @@ const J = [
859
862
  width: 500
860
863
  }
861
864
  );
862
- }, Sn = [Ue], Pn = () => {
865
+ }, Sn = [Ue], zn = () => {
863
866
  const n = me(), [t, s] = V(!1), {
864
867
  data: d,
865
868
  loading: l,
@@ -905,5 +908,5 @@ const J = [
905
908
  ] });
906
909
  };
907
910
  export {
908
- Pn as default
911
+ zn as default
909
912
  };