@hybridcore/ui 1.6.12 → 1.6.13

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 (105) hide show
  1. package/dist/assets/index.css +1 -1
  2. package/dist/assets/index2.css +1 -1
  3. package/dist/components/button/styled.js +1 -1
  4. package/dist/components/charts/_common/format.js +149 -41
  5. package/dist/components/charts/_common/utils.js +16 -11
  6. package/dist/components/collapsible-card/index.js +21 -30
  7. package/dist/components/collapsible-card/styled.js +16 -14
  8. package/dist/components/color-picker/index.js +2227 -3357
  9. package/dist/components/color-picker/styled.js +87 -7
  10. package/dist/components/confirm/dialog.js +89 -8
  11. package/dist/components/confirm/index.js +1 -1
  12. package/dist/components/data-map/index.js +1 -1
  13. package/dist/components/data-map/logic.js +20 -20
  14. package/dist/components/data-security-selectors/dissemination-list/index.js +32 -3117
  15. package/dist/components/date-picker-with-custom-range/index.js +86 -7
  16. package/dist/components/date-range-picker/index.js +464 -452
  17. package/dist/components/document-viewer/components/viewer/index.js +1 -1
  18. package/dist/components/duration-select/index.js +10 -10
  19. package/dist/components/duration-select/styled.js +1 -1
  20. package/dist/components/geometry-picker/coordinate/index.js +14 -14
  21. package/dist/components/geometry-picker/edit/index.js +1 -1
  22. package/dist/components/geometry-picker/geometry/index.js +1 -1
  23. package/dist/components/geometry-picker/kml/index.js +11 -11
  24. package/dist/components/geometry-picker/map/logic.js +145 -3656
  25. package/dist/components/geometry-picker/map/style.js +18 -17
  26. package/dist/components/geometry-picker/parser/coordinate-input/logic.js +43 -1255
  27. package/dist/components/heat-map/index.js +1 -1
  28. package/dist/components/heat-map/logic.js +77 -1924
  29. package/dist/components/instance-hierarchy-table/styled.js +18 -16
  30. package/dist/components/map/helpers/mapbox.js +17 -15
  31. package/dist/components/map/helpers/ol.js +386 -27
  32. package/dist/components/map/index.js +11 -10
  33. package/dist/components/map/logic.js +22 -22
  34. package/dist/components/map/styled.js +31 -27
  35. package/dist/components/metric-card/logic.js +46 -49
  36. package/dist/components/phone-input/index.js +10 -9
  37. package/dist/components/property-mapping/index.js +1 -1
  38. package/dist/components/prr-map/index.js +1 -1
  39. package/dist/components/prr-map/logic.js +27 -26
  40. package/dist/components/range-selector/styled.js +65 -4228
  41. package/dist/components/raster-grid-map/index.js +1 -1
  42. package/dist/components/raster-grid-map/logic.js +60 -57
  43. package/dist/components/simple-pivot-table/index.js +17 -17
  44. package/dist/components/simple-pivot-table/logic.js +67 -76
  45. package/dist/components/sortable-list/index.js +1091 -1264
  46. package/dist/components/template-form/components/property-list/index.js +36 -33
  47. package/dist/components/template-form/components/property-list/property-list-columns.js +19 -18
  48. package/dist/components/template-form/components/property-list/property-list-form.js +137 -601
  49. package/dist/components/template-form/components/recognition-property-list/index.js +40 -37
  50. package/dist/components/template-form/components/recognition-property-list/recognition-property-list-columns.js +11 -10
  51. package/dist/components/template-form/components/recognition-property-list/recognition-property-list-form.js +55 -63
  52. package/dist/components/tree-select/index.js +16 -16
  53. package/dist/index.esm-UfGMjYOL.js +197 -0
  54. package/dist/main.d.ts +54 -8
  55. package/dist/main.js +176 -175
  56. package/package.json +1 -1
  57. package/dist/AccordionSummary-CJppWeqF.js +0 -781
  58. package/dist/Add-CqcD1PWb.js +0 -403
  59. package/dist/Box-DqUMmZjL.js +0 -31
  60. package/dist/Button-C5yquWAB.js +0 -357
  61. package/dist/ButtonBase-BEF7oTOe.js +0 -887
  62. package/dist/Delete-BdyYpINH.js +0 -23
  63. package/dist/DialogContent-BvVjD9z3.js +0 -523
  64. package/dist/FormGroup-CpBsIyYR.js +0 -89
  65. package/dist/IconButton-BoGwbvrP.js +0 -184
  66. package/dist/InputLabel-Dd8RrneV.js +0 -341
  67. package/dist/MenuItem-DwqJqzuM.js +0 -233
  68. package/dist/Modal-MUZygjmQ.js +0 -1158
  69. package/dist/Paper-BkQLdsCI.js +0 -582
  70. package/dist/Select-DHUl_uG3.js +0 -3916
  71. package/dist/Source-BSZST_GH.js +0 -4410
  72. package/dist/SwitchBase-DTndTqI8.js +0 -235
  73. package/dist/Text-ChJRuaD8.js +0 -2197
  74. package/dist/TextField-e2oKaUN1.js +0 -669
  75. package/dist/TransitionGroupContext-BDAp2T0O.js +0 -96
  76. package/dist/Typography-DgsSLCFC.js +0 -178
  77. package/dist/Vector-BmuhQO4p.js +0 -3606
  78. package/dist/Vector-DfTqQEln.js +0 -1735
  79. package/dist/WKT-2wsDT-nq.js +0 -2310
  80. package/dist/assertThisInitialized-C1dAyb4j.js +0 -7
  81. package/dist/assets/index3.css +0 -1
  82. package/dist/assets/index4.css +0 -1
  83. package/dist/clsx-OuTLNxxd.js +0 -16
  84. package/dist/createChainedFunction-C0nujS3O.js +0 -9
  85. package/dist/createSvgIcon-Ch_cT8az.js +0 -185
  86. package/dist/createSvgIcon-DuDuASu1.js +0 -62
  87. package/dist/debounce-46wSf_lW.js +0 -15
  88. package/dist/dialog-BYRnCztH.js +0 -154
  89. package/dist/formControlState-vgaj2ksH.js +0 -10
  90. package/dist/generateUtilityClasses-C3ivN9Ie.js +0 -2973
  91. package/dist/index-DH6qsPBn.js +0 -153
  92. package/dist/index-e9xTIYWt.js +0 -1934
  93. package/dist/index.esm-BLLrbTzY.js +0 -318
  94. package/dist/math-Bvt2Ubuz.js +0 -704
  95. package/dist/objectWithoutPropertiesLoose-DJteAcBH.js +0 -22
  96. package/dist/ol-yOE-NV0X.js +0 -7465
  97. package/dist/ownerWindow-wg6foiOE.js +0 -10
  98. package/dist/setPrototypeOf-NPgp4cYc.js +0 -8
  99. package/dist/styled-SoqbyrkW.js +0 -350
  100. package/dist/unsupportedProp-DuqR2hj9.js +0 -36
  101. package/dist/useControlled-BYdyS7Pn.js +0 -31
  102. package/dist/useFormControl-CatNKXAi.js +0 -10
  103. package/dist/useId-BW-oWmul.js +0 -19
  104. package/dist/useMobilePicker-CY8ndYRL.js +0 -8279
  105. package/dist/useSlot-B_Q4vnX5.js +0 -42
@@ -1,62 +1,65 @@
1
- import { jsxs as r, jsx as e } from "react/jsx-runtime";
2
- import { DataGrid as a } from "@mui/x-data-grid";
3
- import { A as n, a as d, d as s } from "../../../../Add-CqcD1PWb.js";
4
- import m from "./recognition-property-list-columns.js";
5
- import c from "./recognition-property-list-form.js";
6
- import p from "./recognition-property-list-logic.js";
7
- import { B as g } from "../../../../Box-DqUMmZjL.js";
8
- import { T as h } from "../../../../Typography-DgsSLCFC.js";
9
- import { B as u } from "../../../../Button-C5yquWAB.js";
10
- import { D as f, a as y } from "../../../../DialogContent-BvVjD9z3.js";
11
- import { a as b } from "../../../../dialog-BYRnCztH.js";
12
- const L = (i) => {
13
- const { state: l, action: t } = p(i);
14
- return /* @__PURE__ */ r(g, { children: [
15
- /* @__PURE__ */ e(h, { variant: "h6", marginY: 2, children: "Recognition Property List" }),
16
- i.list.length > 0 ? /* @__PURE__ */ e(
17
- a,
1
+ import { jsxs as i, jsx as e } from "react/jsx-runtime";
2
+ import n from "@mui/material/Alert";
3
+ import a from "@mui/material/AlertTitle";
4
+ import d from "@mui/material/Box";
5
+ import m from "@mui/material/Button";
6
+ import c from "@mui/material/Dialog";
7
+ import s from "@mui/material/DialogContent";
8
+ import p from "@mui/material/DialogTitle";
9
+ import g from "@mui/material/Typography";
10
+ import { DataGrid as h } from "@mui/x-data-grid";
11
+ import f from "@mui/icons-material/Add";
12
+ import u from "./recognition-property-list-columns.js";
13
+ import y from "./recognition-property-list-form.js";
14
+ import b from "./recognition-property-list-logic.js";
15
+ const j = (r) => {
16
+ const { state: l, action: o } = b(r);
17
+ return /* @__PURE__ */ i(d, { children: [
18
+ /* @__PURE__ */ e(g, { variant: "h6", marginY: 2, children: "Recognition Property List" }),
19
+ r.list.length > 0 ? /* @__PURE__ */ e(
20
+ h,
18
21
  {
19
- rows: i.list,
20
- columns: m({
21
- onEdit: t.handleOnEditClick,
22
- onDelete: t.handleOnDeleteClick
22
+ rows: r.list,
23
+ columns: u({
24
+ onEdit: o.handleOnEditClick,
25
+ onDelete: o.handleOnDeleteClick
23
26
  }),
24
- getRowId: (o) => `${o.owner}-${o.termValue}-${o.termMatch}-${o.score}-${o.type}`,
27
+ getRowId: (t) => `${t.owner}-${t.termValue}-${t.termMatch}-${t.score}-${t.type}`,
25
28
  autoHeight: !0
26
29
  }
27
- ) : /* @__PURE__ */ r(n, { severity: "info", children: [
28
- /* @__PURE__ */ e(d, { children: "No Recognition Property Added!" }),
30
+ ) : /* @__PURE__ */ i(n, { severity: "info", children: [
31
+ /* @__PURE__ */ e(a, { children: "No Recognition Property Added!" }),
29
32
  "Add least one recognition property before save the template!"
30
33
  ] }),
31
34
  /* @__PURE__ */ e(
32
- u,
35
+ m,
33
36
  {
34
37
  color: "primary",
35
- onClick: t.handleOnAddClick,
38
+ onClick: o.handleOnAddClick,
36
39
  sx: { mt: 2 },
37
- startIcon: /* @__PURE__ */ e(s, {}),
40
+ startIcon: /* @__PURE__ */ e(f, {}),
38
41
  children: "Add Recognition Property"
39
42
  }
40
43
  ),
41
- /* @__PURE__ */ r(
42
- f,
44
+ /* @__PURE__ */ i(
45
+ c,
43
46
  {
44
47
  open: l.dialog.isOpen,
45
- onClose: t.dialog.close,
48
+ onClose: o.dialog.close,
46
49
  "aria-labelledby": "alert-dialog-title",
47
50
  "aria-describedby": "alert-dialog-description",
48
51
  fullWidth: !0,
49
52
  maxWidth: "sm",
50
53
  scroll: "body",
51
54
  children: [
52
- /* @__PURE__ */ e(b, { id: "alert-dialog-title", children: "Add Recognition Property" }),
53
- /* @__PURE__ */ e(y, { className: "pb-30", children: /* @__PURE__ */ e(
54
- c,
55
+ /* @__PURE__ */ e(p, { id: "alert-dialog-title", children: "Add Recognition Property" }),
56
+ /* @__PURE__ */ e(s, { className: "pb-30", children: /* @__PURE__ */ e(
57
+ y,
55
58
  {
56
59
  defaultValues: l.recPropertyForm.defaultValues,
57
- getFormValues: i.getFormValues,
58
- onSubmit: t.handleSubmit,
59
- onCancel: t.dialog.close
60
+ getFormValues: r.getFormValues,
61
+ onSubmit: o.handleSubmit,
62
+ onCancel: o.dialog.close
60
63
  }
61
64
  ) })
62
65
  ]
@@ -65,5 +68,5 @@ const L = (i) => {
65
68
  ] });
66
69
  };
67
70
  export {
68
- L as RecognitionPropertyList
71
+ j as RecognitionPropertyList
69
72
  };
@@ -1,7 +1,8 @@
1
- import { jsxs as i, Fragment as t, jsx as e } from "react/jsx-runtime";
2
- import { d as o, a as l } from "../../../../Delete-BdyYpINH.js";
3
- import { I as d } from "../../../../IconButton-BoGwbvrP.js";
4
- const h = (r) => [
1
+ import { jsxs as o, Fragment as t, jsx as e } from "react/jsx-runtime";
2
+ import d from "@mui/material/IconButton";
3
+ import m from "@mui/icons-material/Edit";
4
+ import a from "@mui/icons-material/Delete";
5
+ const c = (r) => [
5
6
  { field: "ownerType", headerName: "Owner Type", width: 120 },
6
7
  { field: "owner", headerName: "Owner", width: 120 },
7
8
  {
@@ -25,26 +26,26 @@ const h = (r) => [
25
26
  width: 120,
26
27
  sortable: !1,
27
28
  filterable: !1,
28
- renderCell: (a) => /* @__PURE__ */ i(t, { children: [
29
+ renderCell: (i) => /* @__PURE__ */ o(t, { children: [
29
30
  /* @__PURE__ */ e(
30
31
  d,
31
32
  {
32
33
  size: "medium",
33
- onClick: () => r.onEdit(a.row),
34
- children: /* @__PURE__ */ e(o, { color: "secondary" })
34
+ onClick: () => r.onEdit(i.row),
35
+ children: /* @__PURE__ */ e(m, { color: "secondary" })
35
36
  }
36
37
  ),
37
38
  /* @__PURE__ */ e(
38
39
  d,
39
40
  {
40
41
  size: "medium",
41
- onClick: () => r.onDelete(a.row),
42
- children: /* @__PURE__ */ e(l, {})
42
+ onClick: () => r.onDelete(i.row),
43
+ children: /* @__PURE__ */ e(a, {})
43
44
  }
44
45
  )
45
46
  ] })
46
47
  }
47
48
  ];
48
49
  export {
49
- h as default
50
+ c as default
50
51
  };
@@ -1,71 +1,63 @@
1
- import V, { jsxs as o, Fragment as S, jsx as t } from "react/jsx-runtime";
1
+ import { jsxs as o, Fragment as P, jsx as t } from "react/jsx-runtime";
2
2
  import i from "react";
3
- import { i as C } from "../../../../generateUtilityClasses-C3ivN9Ie.js";
4
- import { r as g } from "../../../../createSvgIcon-DuDuASu1.js";
5
- import { RECOGNITION_PROPERTY_OWNER_TYPE as h, RECOGNITION_PROPERTY_TYPE as T, RECOGNITION_PROPERTY_TERM_MATCH as v } from "../../../../constants/index.js";
6
- import { F as c, T as b } from "../../../../TextField-e2oKaUN1.js";
7
- import { I as u } from "../../../../InputLabel-Dd8RrneV.js";
8
- import { S as d } from "../../../../Select-DHUl_uG3.js";
9
- import { M as m } from "../../../../MenuItem-DwqJqzuM.js";
10
- import { B as M } from "../../../../Box-DqUMmZjL.js";
11
- import { B as y } from "../../../../Button-C5yquWAB.js";
12
- var p = {}, q = C;
13
- Object.defineProperty(p, "__esModule", {
14
- value: !0
15
- });
16
- var w = p.default = void 0, N = q(g()), W = V;
17
- w = p.default = (0, N.default)(/* @__PURE__ */ (0, W.jsx)("path", {
18
- d: "M17 3H5c-1.11 0-2 .9-2 2v14c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V7zm-5 16c-1.66 0-3-1.34-3-3s1.34-3 3-3 3 1.34 3 3-1.34 3-3 3m3-10H5V5h10z"
19
- }), "Save");
20
- function L({
21
- defaultValues: x = {
3
+ import V from "@mui/material/Box";
4
+ import h from "@mui/material/Button";
5
+ import s from "@mui/material/FormControl";
6
+ import d from "@mui/material/InputLabel";
7
+ import m from "@mui/material/MenuItem";
8
+ import u from "@mui/material/Select";
9
+ import f from "@mui/material/TextField";
10
+ import _ from "@mui/icons-material/Save";
11
+ import { RECOGNITION_PROPERTY_OWNER_TYPE as T, RECOGNITION_PROPERTY_TYPE as b, RECOGNITION_PROPERTY_TERM_MATCH as y } from "../../../../constants/index.js";
12
+ function G({
13
+ defaultValues: w = {
22
14
  owner: "",
23
- ownerType: h[0],
24
- type: T[0],
15
+ ownerType: T[0],
16
+ type: b[0],
25
17
  termValue: "",
26
- termMatch: v[0],
18
+ termMatch: y[0],
27
19
  score: 0
28
20
  },
29
- getFormValues: R,
21
+ getFormValues: v,
30
22
  onSubmit: E,
31
- onCancel: O
23
+ onCancel: x
32
24
  }) {
33
- const [r, f] = i.useState(x), [I, _] = i.useState([]), [l, s] = i.useState({
25
+ const [r, p] = i.useState(w), [O, R] = i.useState([]), [a, c] = i.useState({
34
26
  termValue: !1,
35
27
  score: !1
36
28
  }), n = (e) => {
37
- f((a) => ({
38
- ...a,
29
+ p((l) => ({
30
+ ...l,
39
31
  [e.target.name]: e.target.type === "checkbox" ? e.target.checked : e.target.value
40
32
  }));
41
- }, P = () => {
33
+ }, I = () => {
42
34
  if (!r.termValue) {
43
- s({ ...l, termValue: !0 });
35
+ c({ ...a, termValue: !0 });
44
36
  return;
45
37
  }
46
38
  if (!r.score) {
47
- s({ ...l, score: !0 });
39
+ c({ ...a, score: !0 });
48
40
  return;
49
41
  }
50
42
  E(r);
51
43
  };
52
- return i.useEffect(() => (l.termValue && r.termValue && s({ ...l, termValue: !1 }), () => {
53
- }), [r.termValue]), i.useEffect(() => (l.score && r.score && s({ ...l, score: !1 }), () => {
44
+ return i.useEffect(() => (a.termValue && r.termValue && c({ ...a, termValue: !1 }), () => {
45
+ }), [r.termValue]), i.useEffect(() => (a.score && r.score && c({ ...a, score: !1 }), () => {
54
46
  }), [r.score]), i.useEffect(() => {
55
47
  if (r.ownerType === "PROPERTY") {
56
- const e = R("properties");
57
- _(e);
48
+ const e = v("properties");
49
+ R(e);
58
50
  }
59
- return r.ownerType === "EVENT" && r.owner !== "" && f((e) => ({
51
+ return r.ownerType === "EVENT" && r.owner !== "" && p((e) => ({
60
52
  ...e,
61
53
  owner: ""
62
54
  })), () => {
63
55
  };
64
- }, [r.ownerType]), /* @__PURE__ */ o(S, { children: [
65
- /* @__PURE__ */ o(c, { fullWidth: !0, variant: "standard", sx: { mb: 2 }, children: [
66
- /* @__PURE__ */ t(u, { id: "owner-type-select-label", children: "Owner Type" }),
56
+ }, [r.ownerType]), /* @__PURE__ */ o(P, { children: [
57
+ /* @__PURE__ */ o(s, { fullWidth: !0, variant: "standard", sx: { mb: 2 }, children: [
58
+ /* @__PURE__ */ t(d, { id: "owner-type-select-label", children: "Owner Type" }),
67
59
  /* @__PURE__ */ t(
68
- d,
60
+ u,
69
61
  {
70
62
  label: "Owner Type",
71
63
  name: "ownerType",
@@ -73,14 +65,14 @@ function L({
73
65
  id: "owner-type-select",
74
66
  value: r.ownerType,
75
67
  onChange: n,
76
- children: h.map((e, a) => /* @__PURE__ */ t(m, { value: e, children: e }, a))
68
+ children: T.map((e, l) => /* @__PURE__ */ t(m, { value: e, children: e }, l))
77
69
  }
78
70
  )
79
71
  ] }),
80
- r.ownerType === "PROPERTY" && /* @__PURE__ */ o(c, { fullWidth: !0, variant: "standard", sx: { mb: 2 }, children: [
81
- /* @__PURE__ */ t(u, { id: "owner-select-label", children: "Owner" }),
72
+ r.ownerType === "PROPERTY" && /* @__PURE__ */ o(s, { fullWidth: !0, variant: "standard", sx: { mb: 2 }, children: [
73
+ /* @__PURE__ */ t(d, { id: "owner-select-label", children: "Owner" }),
82
74
  /* @__PURE__ */ t(
83
- d,
75
+ u,
84
76
  {
85
77
  label: "Owner",
86
78
  name: "owner",
@@ -88,14 +80,14 @@ function L({
88
80
  id: "owner-select",
89
81
  value: r.owner,
90
82
  onChange: n,
91
- children: I.map((e, a) => /* @__PURE__ */ t(m, { value: e.propertyId, children: e.name }, a))
83
+ children: O.map((e, l) => /* @__PURE__ */ t(m, { value: e.propertyId, children: e.name }, l))
92
84
  }
93
85
  )
94
86
  ] }),
95
- /* @__PURE__ */ o(c, { fullWidth: !0, variant: "standard", sx: { mb: 2 }, children: [
96
- /* @__PURE__ */ t(u, { id: "type-select-label", children: "Type" }),
87
+ /* @__PURE__ */ o(s, { fullWidth: !0, variant: "standard", sx: { mb: 2 }, children: [
88
+ /* @__PURE__ */ t(d, { id: "type-select-label", children: "Type" }),
97
89
  /* @__PURE__ */ t(
98
- d,
90
+ u,
99
91
  {
100
92
  label: "Type",
101
93
  name: "type",
@@ -103,14 +95,14 @@ function L({
103
95
  id: "type-select",
104
96
  value: r.type,
105
97
  onChange: n,
106
- children: T.map((e, a) => /* @__PURE__ */ t(m, { value: e, children: e }, a))
98
+ children: b.map((e, l) => /* @__PURE__ */ t(m, { value: e, children: e }, l))
107
99
  }
108
100
  )
109
101
  ] }),
110
- /* @__PURE__ */ o(c, { fullWidth: !0, variant: "standard", sx: { mb: 2 }, children: [
111
- /* @__PURE__ */ t(u, { id: "term-match-select-label", children: "Term Match" }),
102
+ /* @__PURE__ */ o(s, { fullWidth: !0, variant: "standard", sx: { mb: 2 }, children: [
103
+ /* @__PURE__ */ t(d, { id: "term-match-select-label", children: "Term Match" }),
112
104
  /* @__PURE__ */ t(
113
- d,
105
+ u,
114
106
  {
115
107
  label: "Type",
116
108
  name: "termMatch",
@@ -118,12 +110,12 @@ function L({
118
110
  id: "term-match-select",
119
111
  value: r.termMatch,
120
112
  onChange: n,
121
- children: v.map((e, a) => /* @__PURE__ */ t(m, { value: e, children: e }, a))
113
+ children: y.map((e, l) => /* @__PURE__ */ t(m, { value: e, children: e }, l))
122
114
  }
123
115
  )
124
116
  ] }),
125
117
  /* @__PURE__ */ t(
126
- b,
118
+ f,
127
119
  {
128
120
  label: "Term",
129
121
  name: "termValue",
@@ -133,14 +125,14 @@ function L({
133
125
  value: r.termValue,
134
126
  onChange: n,
135
127
  required: !0,
136
- ...l.termValue && {
128
+ ...a.termValue && {
137
129
  error: !0,
138
130
  helperText: "This field is required!"
139
131
  }
140
132
  }
141
133
  ),
142
134
  /* @__PURE__ */ t(
143
- b,
135
+ f,
144
136
  {
145
137
  label: "Score",
146
138
  name: "score",
@@ -150,20 +142,20 @@ function L({
150
142
  value: r.score,
151
143
  onChange: n,
152
144
  required: !0,
153
- ...l.score && {
145
+ ...a.score && {
154
146
  error: !0,
155
147
  helperText: "This field is required!"
156
148
  }
157
149
  }
158
150
  ),
159
- /* @__PURE__ */ o(M, { display: "flex", justifyContent: "flex-end", children: [
160
- /* @__PURE__ */ t(y, { variant: "contained", onClick: O, sx: { marginRight: 2 }, children: "Cancel" }),
151
+ /* @__PURE__ */ o(V, { display: "flex", justifyContent: "flex-end", children: [
152
+ /* @__PURE__ */ t(h, { variant: "contained", onClick: x, sx: { marginRight: 2 }, children: "Cancel" }),
161
153
  /* @__PURE__ */ t(
162
- y,
154
+ h,
163
155
  {
164
156
  variant: "contained",
165
- startIcon: /* @__PURE__ */ t(w, {}),
166
- onClick: P,
157
+ startIcon: /* @__PURE__ */ t(_, {}),
158
+ onClick: I,
167
159
  children: "Save"
168
160
  }
169
161
  )
@@ -171,5 +163,5 @@ function L({
171
163
  ] });
172
164
  }
173
165
  export {
174
- L as default
166
+ G as default
175
167
  };
@@ -1,17 +1,17 @@
1
1
  import { jsxs as d, jsx as l } from "react/jsx-runtime";
2
+ import T from "@mui/material/InputLabel";
2
3
  import c from "lodash";
3
- import { TreeViewFilter as T } from "../treeview-filter/index.js";
4
- import { useTreeSelectLogic as f } from "./logic.js";
5
- import { TreeSelectRoot as g, TreeSelectLabel as S, TreeSelectFormControl as x, TreeSelectInput as C, TreeSelectMenuItem as v, TreeSelectDialog as I, TreeSelectDialogContent as W, TreeSelectDialogActions as D, TreeSelectConfirmButton as L } from "./styled.js";
6
- import { I as O } from "../../InputLabel-Dd8RrneV.js";
4
+ import { TreeViewFilter as f } from "../treeview-filter/index.js";
5
+ import { useTreeSelectLogic as g } from "./logic.js";
6
+ import { TreeSelectRoot as S, TreeSelectLabel as x, TreeSelectFormControl as C, TreeSelectInput as v, TreeSelectMenuItem as I, TreeSelectDialog as W, TreeSelectDialogContent as D, TreeSelectDialogActions as L, TreeSelectConfirmButton as O } from "./styled.js";
7
7
  const K = (e) => {
8
- const { state: h, actions: t } = f(e), { ownerState: s, open: u, expanded: m, selectedItems: i, idKey: o, variant: r, labelPosition: a } = h;
9
- return /* @__PURE__ */ d(g, { ownerState: s, sx: e.sx, children: [
10
- a === "top" && e.label !== void 0 && /* @__PURE__ */ l(S, { children: e.label }),
11
- /* @__PURE__ */ d(x, { variant: r, fullWidth: !0, children: [
12
- a === "default" && e.label !== void 0 && /* @__PURE__ */ l(O, { id: "select-label", children: e.label }),
8
+ const { state: h, actions: t } = g(e), { ownerState: s, open: u, expanded: m, selectedItems: i, idKey: o, variant: r, labelPosition: a } = h;
9
+ return /* @__PURE__ */ d(S, { ownerState: s, sx: e.sx, children: [
10
+ a === "top" && e.label !== void 0 && /* @__PURE__ */ l(x, { children: e.label }),
11
+ /* @__PURE__ */ d(C, { variant: r, fullWidth: !0, children: [
12
+ a === "default" && e.label !== void 0 && /* @__PURE__ */ l(T, { id: "select-label", children: e.label }),
13
13
  /* @__PURE__ */ l(
14
- C,
14
+ v,
15
15
  {
16
16
  label: a === "default" ? e.label : void 0,
17
17
  variant: r,
@@ -20,20 +20,20 @@ const K = (e) => {
20
20
  value: e.selected,
21
21
  open: !1,
22
22
  onOpen: t.handleOpen,
23
- children: i.length > 0 && i.map((n, b) => /* @__PURE__ */ l(v, { value: c.get(n, o) ?? "", children: n == null ? void 0 : n.name }, b))
23
+ children: i.length > 0 && i.map((n, b) => /* @__PURE__ */ l(I, { value: c.get(n, o) ?? "", children: n == null ? void 0 : n.name }, b))
24
24
  }
25
25
  )
26
26
  ] }),
27
27
  /* @__PURE__ */ d(
28
- I,
28
+ W,
29
29
  {
30
30
  open: u,
31
31
  onClose: t.handleClose,
32
32
  fullWidth: !0,
33
33
  maxWidth: "sm",
34
34
  children: [
35
- /* @__PURE__ */ l(W, { children: /* @__PURE__ */ l(
36
- T,
35
+ /* @__PURE__ */ l(D, { children: /* @__PURE__ */ l(
36
+ f,
37
37
  {
38
38
  data: e.data,
39
39
  selected: c.isArray(e.selected) ? e.selected : void 0,
@@ -44,8 +44,8 @@ const K = (e) => {
44
44
  onChange: t.handleChange
45
45
  }
46
46
  ) }),
47
- /* @__PURE__ */ l(D, { children: /* @__PURE__ */ l(
48
- L,
47
+ /* @__PURE__ */ l(L, { children: /* @__PURE__ */ l(
48
+ O,
49
49
  {
50
50
  onClick: t.handleClose,
51
51
  variant: "contained",
@@ -0,0 +1,197 @@
1
+ import L, { useRef as N, useState as q, useCallback as M, useEffect as x, isValidElement as V, createRef as B, cloneElement as P, PureComponent as G } from "react";
2
+ import { findDOMNode as J } from "react-dom";
3
+ import K from "lodash/debounce";
4
+ import Q from "lodash/throttle";
5
+ var T = function(n, t) {
6
+ return T = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(r, e) {
7
+ r.__proto__ = e;
8
+ } || function(r, e) {
9
+ for (var a in e) Object.prototype.hasOwnProperty.call(e, a) && (r[a] = e[a]);
10
+ }, T(n, t);
11
+ };
12
+ function X(n, t) {
13
+ if (typeof t != "function" && t !== null)
14
+ throw new TypeError("Class extends value " + String(t) + " is not a constructor or null");
15
+ T(n, t);
16
+ function r() {
17
+ this.constructor = n;
18
+ }
19
+ n.prototype = t === null ? Object.create(t) : (r.prototype = t.prototype, new r());
20
+ }
21
+ var j = function() {
22
+ return j = Object.assign || function(t) {
23
+ for (var r, e = 1, a = arguments.length; e < a; e++) {
24
+ r = arguments[e];
25
+ for (var d in r) Object.prototype.hasOwnProperty.call(r, d) && (t[d] = r[d]);
26
+ }
27
+ return t;
28
+ }, j.apply(this, arguments);
29
+ };
30
+ function Y(n, t) {
31
+ var r = {};
32
+ for (var e in n) Object.prototype.hasOwnProperty.call(n, e) && t.indexOf(e) < 0 && (r[e] = n[e]);
33
+ if (n != null && typeof Object.getOwnPropertySymbols == "function")
34
+ for (var a = 0, e = Object.getOwnPropertySymbols(n); a < e.length; a++)
35
+ t.indexOf(e[a]) < 0 && Object.prototype.propertyIsEnumerable.call(n, e[a]) && (r[e[a]] = n[e[a]]);
36
+ return r;
37
+ }
38
+ var I = function(n, t, r, e) {
39
+ switch (t) {
40
+ case "debounce":
41
+ return K(n, r, e);
42
+ case "throttle":
43
+ return Q(n, r, e);
44
+ default:
45
+ return n;
46
+ }
47
+ }, F = function(n) {
48
+ return typeof n == "function";
49
+ }, z = function() {
50
+ return typeof window > "u";
51
+ }, U = function(n) {
52
+ return n instanceof Element || n instanceof HTMLDocument;
53
+ };
54
+ (function(n) {
55
+ X(t, n);
56
+ function t(r) {
57
+ var e = n.call(this, r) || this;
58
+ e.cancelHandler = function() {
59
+ e.resizeHandler && e.resizeHandler.cancel && (e.resizeHandler.cancel(), e.resizeHandler = null);
60
+ }, e.attachObserver = function() {
61
+ var s = e.props, o = s.targetRef, u = s.observerOptions;
62
+ if (!z()) {
63
+ o && o.current && (e.targetRef.current = o.current);
64
+ var i = e.getElement();
65
+ i && (e.observableElement && e.observableElement === i || (e.observableElement = i, e.resizeObserver.observe(i, u)));
66
+ }
67
+ }, e.getElement = function() {
68
+ var s = e.props, o = s.querySelector, u = s.targetDomEl;
69
+ if (z())
70
+ return null;
71
+ if (o)
72
+ return document.querySelector(o);
73
+ if (u && U(u))
74
+ return u;
75
+ if (e.targetRef && U(e.targetRef.current))
76
+ return e.targetRef.current;
77
+ var i = J(e);
78
+ if (!i)
79
+ return null;
80
+ var l = e.getRenderType();
81
+ switch (l) {
82
+ case "renderProp":
83
+ return i;
84
+ case "childFunction":
85
+ return i;
86
+ case "child":
87
+ return i;
88
+ case "childArray":
89
+ return i;
90
+ default:
91
+ return i.parentElement;
92
+ }
93
+ }, e.createResizeHandler = function(s) {
94
+ var o = e.props, u = o.handleWidth, i = u === void 0 ? !0 : u, l = o.handleHeight, y = l === void 0 ? !0 : l, p = o.onResize;
95
+ if (!(!i && !y)) {
96
+ var R = function(c) {
97
+ var v = c.width, g = c.height;
98
+ e.state.width === v && e.state.height === g || e.state.width === v && !y || e.state.height === g && !i || (p == null || p(v, g), e.setState({ width: v, height: g }));
99
+ };
100
+ s.forEach(function(c) {
101
+ var v = c && c.contentRect || {}, g = v.width, w = v.height, H = !e.skipOnMount && !z();
102
+ H && R({ width: g, height: w }), e.skipOnMount = !1;
103
+ });
104
+ }
105
+ }, e.getRenderType = function() {
106
+ var s = e.props, o = s.render, u = s.children;
107
+ return F(o) ? "renderProp" : F(u) ? "childFunction" : V(u) ? "child" : Array.isArray(u) ? "childArray" : "parent";
108
+ };
109
+ var a = r.skipOnMount, d = r.refreshMode, m = r.refreshRate, O = m === void 0 ? 1e3 : m, _ = r.refreshOptions;
110
+ return e.state = {
111
+ width: void 0,
112
+ height: void 0
113
+ }, e.sizeRef = {
114
+ current: e.state
115
+ }, e.skipOnMount = a, e.targetRef = B(), e.observableElement = null, z() || (e.resizeHandler = I(e.createResizeHandler, d, O, _), e.resizeObserver = new window.ResizeObserver(e.resizeHandler)), e;
116
+ }
117
+ return t.prototype.componentDidMount = function() {
118
+ this.attachObserver();
119
+ }, t.prototype.componentDidUpdate = function() {
120
+ this.attachObserver(), this.sizeRef.current = this.state;
121
+ }, t.prototype.componentWillUnmount = function() {
122
+ z() || (this.observableElement = null, this.resizeObserver.disconnect(), this.cancelHandler());
123
+ }, t.prototype.render = function() {
124
+ var r = this.props, e = r.render, a = r.children, d = r.nodeType, m = d === void 0 ? "div" : d, O = this.state, _ = O.width, s = O.height, o = { width: _, height: s, targetRef: this.targetRef }, u = this.getRenderType();
125
+ switch (u) {
126
+ case "renderProp":
127
+ return e == null ? void 0 : e(o);
128
+ case "childFunction": {
129
+ var i = a;
130
+ return i == null ? void 0 : i(o);
131
+ }
132
+ case "child": {
133
+ var l = a;
134
+ if (l.type && typeof l.type == "string") {
135
+ o.targetRef;
136
+ var y = Y(o, ["targetRef"]);
137
+ return P(l, y);
138
+ }
139
+ return P(l, o);
140
+ }
141
+ case "childArray": {
142
+ var p = a;
143
+ return p.map(function(R) {
144
+ return !!R && P(R, o);
145
+ });
146
+ }
147
+ default:
148
+ return L.createElement(m, null);
149
+ }
150
+ }, t;
151
+ })(G);
152
+ function re(n) {
153
+ var t = {}, r = t.skipOnMount, e = r === void 0 ? !1 : r, a = t.refreshMode, d = t.refreshRate, m = d === void 0 ? 1e3 : d, O = t.refreshOptions, _ = t.handleWidth, s = _ === void 0 ? !0 : _, o = t.handleHeight, u = o === void 0 ? !0 : o, i = t.targetRef, l = t.observerOptions, y = t.onResize, p = N(e), R = q({
154
+ width: void 0,
155
+ height: void 0
156
+ }), c = R[0], v = R[1], g = q((i == null ? void 0 : i.current) || null), w = g[0], H = g[1];
157
+ i && setTimeout(function() {
158
+ i.current !== w && H(i.current);
159
+ }, 0);
160
+ var k = M(function(f) {
161
+ f !== w && H(f);
162
+ }, [w]);
163
+ k.current = w;
164
+ var D = M(function(f, h) {
165
+ return !(f.width === h.width && f.height === h.height || f.width === h.width && !u || f.height === h.height && !s);
166
+ }, [s, u]), A = M(function(f) {
167
+ if (!(!s && !u)) {
168
+ if (p.current) {
169
+ p.current = !1;
170
+ return;
171
+ }
172
+ f.forEach(function(h) {
173
+ var E = (h == null ? void 0 : h.contentRect) || {}, b = E.width, W = E.height;
174
+ v(function(C) {
175
+ return D(C, { width: b, height: W }) ? { width: b, height: W } : C;
176
+ });
177
+ });
178
+ }
179
+ }, [s, u, p, D]), S = M(I(A, a, m, O), [
180
+ A,
181
+ a,
182
+ m,
183
+ O
184
+ ]);
185
+ return x(function() {
186
+ var f;
187
+ return w ? (f = new window.ResizeObserver(S), f.observe(w, l)) : (c.width || c.height) && v({ width: void 0, height: void 0 }), function() {
188
+ var h, E, b;
189
+ (h = f == null ? void 0 : f.disconnect) === null || h === void 0 || h.call(f), (b = (E = S).cancel) === null || b === void 0 || b.call(E);
190
+ };
191
+ }, [S, w]), x(function() {
192
+ y == null || y(c.width, c.height);
193
+ }, [c]), j({ ref: k }, c);
194
+ }
195
+ export {
196
+ re as u
197
+ };