@hybridcore/ui 1.4.31 → 1.4.32

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 (107) hide show
  1. package/dist/AccordionDetails-mpRYHtGq.js +743 -0
  2. package/dist/{Add-eepk2WTM.js → Add-BKnWHZ7A.js} +10 -9
  3. package/dist/{Box-BPyg-Ybm.js → Box-SSMZuKnS.js} +8 -8
  4. package/dist/{Button-DLwB_sKd.js → Button-jy67CcTH.js} +8 -7
  5. package/dist/{ButtonBase-D0qccOVb.js → ButtonBase-CgQC8DUB.js} +13 -12
  6. package/dist/{CardContent-DFsCCOWk.js → CardContent-CCq4R1KS.js} +14 -13
  7. package/dist/{Checkbox-qy3cjvnb.js → Checkbox-B0P8LhCl.js} +10 -9
  8. package/dist/{Delete-OHEw9lDi.js → Delete-DfyX03ib.js} +1 -1
  9. package/dist/{DialogContent-CxOSq6h9.js → DialogContent-B0_-g7B0.js} +10 -9
  10. package/dist/{FormControlLabel-D9KFjcIx.js → FormControlLabel-BNT5EI0b.js} +10 -9
  11. package/dist/{IconButton-BaiyAtmS.js → IconButton-DekcZv4i.js} +16 -15
  12. package/dist/{Input-CmCkXczh.js → Input-BAbDr3Tk.js} +17 -16
  13. package/dist/{InputAdornment-CZUPEeia.js → InputAdornment-BAVRrRts.js} +8 -7
  14. package/dist/{InputLabel-CWkW8NtU.js → InputLabel-ClDXuWBr.js} +16 -14
  15. package/dist/{List-PpNAWJ_I.js → List-CNeRnfGL.js} +10 -9
  16. package/dist/{ListItem-CZbZ91vp.js → ListItem-N_dSd02S.js} +15 -14
  17. package/dist/{MenuItem-D-INSvZa.js → MenuItem-Lcjh1XlV.js} +11 -10
  18. package/dist/{Modal-KrI5qFIq.js → Modal-CJn-Bqyo.js} +14 -13
  19. package/dist/{OutlinedInput-DkIUD30e.js → OutlinedInput-De2keFJK.js} +28 -27
  20. package/dist/{Paper-btu3j72o.js → Paper-DRRYGupP.js} +22 -21
  21. package/dist/{Select-ClaBvSqf.js → Select-DwAJxKTN.js} +65 -63
  22. package/dist/{Source-Hf_SiWEW.js → Source-CnCcu5UP.js} +123 -123
  23. package/dist/{Tabs-BzelDJKy.js → Tabs-DqdkJU6b.js} +16 -14
  24. package/dist/{Text-D6oGbCdi.js → Text-BT5kPHOo.js} +41 -41
  25. package/dist/{TextField-D87qTh1k.js → TextField-BAXUnwnR.js} +14 -13
  26. package/dist/{Typography-Bm7PFqUT.js → Typography-CLq43OVQ.js} +21 -20
  27. package/dist/components/access/helpers.js +1 -1
  28. package/dist/components/access/index.js +1 -1
  29. package/dist/components/card/index.js +49 -48
  30. package/dist/components/card/styled.js +1 -1
  31. package/dist/components/collapsible-card/style.js +3 -3
  32. package/dist/components/confirm/dialog.js +3 -3
  33. package/dist/components/confirm/index.js +1 -1
  34. package/dist/components/container/index.js +10 -9
  35. package/dist/components/context-menu/index.js +13 -12
  36. package/dist/components/data-security-selectors/dissemination-list/index.js +1 -1
  37. package/dist/components/data-security-selectors/security-level/index.js +7 -7
  38. package/dist/components/geometry-picker/coordinate/index.js +1 -1
  39. package/dist/components/geometry-picker/edit/index.js +2 -2
  40. package/dist/components/geometry-picker/geometry/index.js +1 -1
  41. package/dist/components/geometry-picker/index.js +3 -3
  42. package/dist/components/geometry-picker/kml/index.js +1 -1
  43. package/dist/components/geometry-picker/map/logic.js +19 -19
  44. package/dist/components/geometry-picker/map/style.js +1 -1
  45. package/dist/components/icon-button/index.js +1 -1
  46. package/dist/components/instance-form/components/composite-list/index.js +1 -1
  47. package/dist/components/instance-form/components/variable/index.js +8 -8
  48. package/dist/components/instance-form/components/variables/index.js +1 -1
  49. package/dist/components/instance-hierarchy-table/styled.js +1 -1
  50. package/dist/components/map/helpers/mapbox.js +3 -3
  51. package/dist/components/map/helpers/ol.js +3 -3
  52. package/dist/components/map/logic.js +2 -2
  53. package/dist/components/map/styled.js +2 -2
  54. package/dist/components/property-mapping/index.js +2 -2
  55. package/dist/components/range-selector/components/composite-list-range/index.js +1 -1
  56. package/dist/components/range-selector/components/date-range/index.js +1 -1
  57. package/dist/components/range-selector/index.js +1 -1
  58. package/dist/components/search-input/index.js +4 -4
  59. package/dist/components/tabs/index.js +1 -1
  60. package/dist/components/template-filters/components/filter/index.js +44 -0
  61. package/dist/components/template-filters/components/tab-panel/index.js +27 -0
  62. package/dist/components/template-filters/index.js +39 -0
  63. package/dist/components/template-filters/styled.js +1 -0
  64. package/dist/components/template-form/components/property-list/index.js +7 -7
  65. package/dist/components/template-form/components/property-list/property-list-columns.js +3 -3
  66. package/dist/components/template-form/components/property-list/property-list-form.js +9 -9
  67. package/dist/components/template-form/components/recognition-property-list/index.js +6 -6
  68. package/dist/components/template-form/components/recognition-property-list/recognition-property-list-columns.js +2 -2
  69. package/dist/components/template-form/components/recognition-property-list/recognition-property-list-form.js +7 -7
  70. package/dist/components/template-form/index.js +5 -5
  71. package/dist/components/template-property-filters/property.js +5 -5
  72. package/dist/components/tree-select/index.js +5 -5
  73. package/dist/components/treeview-filter/index.js +384 -318
  74. package/dist/components/treeview-filter/item/index.js +56 -5
  75. package/dist/components/treeview-filter/item/styled.js +38 -0
  76. package/dist/components/treeview-filter/item-label/index.js +27 -26
  77. package/dist/createStyled-CUatW1r9.js +352 -0
  78. package/dist/{createSvgIcon-Cfm1LkEe.js → createSvgIcon-BXjHHQ0B.js} +28 -29
  79. package/dist/{createSvgIcon-DEXLbMwp.js → createSvgIcon-CBoAEepv.js} +9 -8
  80. package/dist/{styled-LNCprp4n.js → createTheme-DVoJnXAT.js} +134 -142
  81. package/dist/createTheme-DrgvKMA_.js +1563 -0
  82. package/dist/{dialog-v5-nL5yy.js → dialog-DPGR2gik.js} +7 -7
  83. package/dist/{exactProp-DkmnwNVS.js → exactProp-H1i70prd.js} +3 -3
  84. package/dist/{extendSxProp-qqdkfHzS.js → extendSxProp-BmK2hLmq.js} +4 -4
  85. package/dist/{has-CjQtZJa9.js → has-9_asnBxn.js} +26 -26
  86. package/dist/{helpers-B4UL9NMD.js → helpers-DaCoWmi2.js} +3 -3
  87. package/dist/{index-oPY7k6mu.js → index-B_GNCJdV.js} +7 -7
  88. package/dist/{index-C1fczHEW.js → index-RfDWDd66.js} +28 -27
  89. package/dist/{listItemTextClasses-DsHGzpPM.js → listItemTextClasses-CC7nbQWN.js} +4 -4
  90. package/dist/main.js +35 -35
  91. package/dist/{objectWithoutPropertiesLoose-BK36oJDi.js → objectWithoutPropertiesLoose-DJteAcBH.js} +2 -2
  92. package/dist/{ol-CHaVTXvL.js → ol-9hySGI6D.js} +3 -3
  93. package/dist/{property-list-form-B1GZ9ZGO.js → property-list-form-DgmTiBvu.js} +36 -35
  94. package/dist/styled-DkqItiLo.js +12 -0
  95. package/dist/unsupportedProp-BND8AB6O.js +25 -0
  96. package/dist/{useTheme-DBiahn6p.js → useTheme-B6oa3v5u.js} +4 -4
  97. package/dist/useTheme-GN5Dc3mG.js +18 -0
  98. package/dist/useThemeProps-BlXpIqSE.js +95 -0
  99. package/dist/{utils-DNe_YYjm.js → utils-BRsEqTye.js} +8 -8
  100. package/package.json +1 -1
  101. package/dist/AccordionDetails-CGs6GZQK.js +0 -454
  102. package/dist/Collapse-CL6LGGZw.js +0 -298
  103. package/dist/createStyled-BzvgQjjR.js +0 -1910
  104. package/dist/index-B0JPwFI9.js +0 -596
  105. package/dist/requirePropFactory-BjhhI-AW.js +0 -18
  106. package/dist/unsupportedProp-BuVD30Gh.js +0 -9
  107. package/dist/useThemeProps-uYx_RkOH.js +0 -109
@@ -1,288 +1,351 @@
1
- import Ne, { jsx as C, jsxs as it, Fragment as ut } from "react/jsx-runtime";
2
- import * as f from "react";
3
- import Se from "react";
4
- import { r as Oe, i as Te } from "../../createSvgIcon-Cfm1LkEe.js";
5
- import { T as dt, D as ft, I as pt } from "../../index-B0JPwFI9.js";
6
- import we from "lodash";
7
- import { Box as ht } from "@mui/material";
8
- import { SearchInput as mt } from "../search-input/index.js";
9
- import { flattenNestedTemplates as xt } from "../../utils/ontology.js";
10
- import { g as gt, u as bt, c as St, a as wt } from "../../useThemeProps-uYx_RkOH.js";
11
- import { P as o } from "../../createStyled-BzvgQjjR.js";
12
- import { g as yt, s as It } from "../../styled-LNCprp4n.js";
13
- import { u as Ct } from "../../useTheme-DBiahn6p.js";
14
- import { u as Nt } from "../../useId-BHG98T5I.js";
15
- import { a as Ot } from "../../ButtonBase-D0qccOVb.js";
16
- import { u as ye } from "../../useControlled-BYdyS7Pn.js";
17
- import { o as Tt } from "../../ownerDocument-CUrv0DIK.js";
18
- function Rt(d) {
19
- return yt("MuiTreeView", d);
1
+ import Te, { jsx as O, jsxs as Se, Fragment as we } from "react/jsx-runtime";
2
+ import * as u from "react";
3
+ import Ne from "react";
4
+ import { r as Ee, i as Re } from "../../createSvgIcon-BXjHHQ0B.js";
5
+ import ht from "./item/index.js";
6
+ import ye from "lodash";
7
+ import { Box as mt, Divider as xt } from "@mui/material";
8
+ import { SearchInput as gt } from "../search-input/index.js";
9
+ import { flattenNestedTemplates as bt } from "../../utils/ontology.js";
10
+ import { g as St, u as wt, c as Nt, a as yt } from "../../useThemeProps-BlXpIqSE.js";
11
+ import { P as s } from "../../createTheme-DrgvKMA_.js";
12
+ import { g as Ct } from "../../createTheme-DVoJnXAT.js";
13
+ import { s as It } from "../../styled-DkqItiLo.js";
14
+ import { u as Ot } from "../../useTheme-B6oa3v5u.js";
15
+ import { u as Tt } from "../../useId-BHG98T5I.js";
16
+ import { a as Et } from "../../ButtonBase-CgQC8DUB.js";
17
+ import { u as Ce } from "../../useControlled-BYdyS7Pn.js";
18
+ import { o as Rt } from "../../ownerDocument-CUrv0DIK.js";
19
+ const De = /* @__PURE__ */ u.createContext({});
20
+ process.env.NODE_ENV !== "production" && (De.displayName = "TreeViewContext");
21
+ function Dt(i, h) {
22
+ let m = 0, p = i.length - 1;
23
+ for (; m <= p; ) {
24
+ const b = Math.floor((m + p) / 2);
25
+ if (i[b].element === h)
26
+ return b;
27
+ i[b].element.compareDocumentPosition(h) & Node.DOCUMENT_POSITION_PRECEDING ? p = b - 1 : m = b + 1;
28
+ }
29
+ return m;
20
30
  }
21
- gt("MuiTreeView", ["root"]);
22
- const kt = (d) => {
31
+ const Pe = /* @__PURE__ */ u.createContext({});
32
+ process.env.NODE_ENV !== "production" && (Pe.displayName = "DescendantContext");
33
+ function ke(i) {
23
34
  const {
24
- classes: b
25
- } = d;
26
- return wt({
35
+ children: h,
36
+ id: m
37
+ } = i, [p, b] = u.useState([]), j = u.useCallback(({
38
+ element: S,
39
+ ...P
40
+ }) => {
41
+ b((N) => {
42
+ let T;
43
+ if (N.length === 0)
44
+ return [{
45
+ ...P,
46
+ element: S,
47
+ index: 0
48
+ }];
49
+ const w = Dt(N, S);
50
+ if (N[w] && N[w].element === S)
51
+ T = N;
52
+ else {
53
+ const x = {
54
+ ...P,
55
+ element: S,
56
+ index: w
57
+ };
58
+ T = N.slice(), T.splice(w, 0, x);
59
+ }
60
+ return T.forEach((x, J) => {
61
+ x.index = J;
62
+ }), T;
63
+ });
64
+ }, []), K = u.useCallback((S) => {
65
+ b((P) => P.filter((N) => S !== N.element));
66
+ }, []), $ = u.useMemo(() => ({
67
+ descendants: p,
68
+ registerDescendant: j,
69
+ unregisterDescendant: K,
70
+ parentId: m
71
+ }), [p, j, K, m]);
72
+ return /* @__PURE__ */ O(Pe.Provider, {
73
+ value: $,
74
+ children: h
75
+ });
76
+ }
77
+ process.env.NODE_ENV !== "production" && (ke.propTypes = {
78
+ children: s.node,
79
+ id: s.string
80
+ });
81
+ function Pt(i) {
82
+ return Ct("MuiTreeView", i);
83
+ }
84
+ St("MuiTreeView", ["root"]);
85
+ const kt = (i) => {
86
+ const {
87
+ classes: h
88
+ } = i;
89
+ return yt({
27
90
  root: ["root"]
28
- }, Rt, b);
29
- }, Et = It("ul", {
91
+ }, Pt, h);
92
+ }, Ft = It("ul", {
30
93
  name: "MuiTreeView",
31
94
  slot: "Root",
32
- overridesResolver: (d, b) => b.root
95
+ overridesResolver: (i, h) => h.root
33
96
  })({
34
97
  padding: 0,
35
98
  margin: 0,
36
99
  listStyle: "none",
37
100
  outline: 0
38
101
  });
39
- function Ft(d) {
40
- return d && d.length === 1 && d.match(/\S/);
102
+ function Mt(i) {
103
+ return i && i.length === 1 && i.match(/\S/);
41
104
  }
42
- function Ie(d, b, E) {
43
- for (let y = b; y < d.length; y += 1)
44
- if (E === d[y])
45
- return y;
105
+ function Ie(i, h, m) {
106
+ for (let p = h; p < i.length; p += 1)
107
+ if (m === i[p])
108
+ return p;
46
109
  return -1;
47
110
  }
48
- function Ce() {
111
+ function Oe() {
49
112
  return !1;
50
113
  }
51
- const Pt = [], At = [], Re = /* @__PURE__ */ f.forwardRef(function(b, E) {
52
- const y = bt({
53
- props: b,
114
+ const _t = [], At = [], Fe = /* @__PURE__ */ u.forwardRef(function(h, m) {
115
+ const p = wt({
116
+ props: h,
54
117
  name: "MuiTreeView"
55
118
  }), {
56
- children: $,
57
- className: Y,
58
- defaultCollapseIcon: Z,
59
- defaultEndIcon: v,
60
- defaultExpanded: A = Pt,
61
- defaultExpandIcon: ee,
62
- defaultParentIcon: te,
63
- defaultSelected: q = At,
64
- disabledItemsFocusable: N = !1,
65
- disableSelection: g = !1,
66
- expanded: ie,
67
- id: I,
68
- multiSelect: p = !1,
69
- onBlur: D,
70
- onFocus: U,
71
- onKeyDown: z,
119
+ children: b,
120
+ className: j,
121
+ defaultCollapseIcon: K,
122
+ defaultEndIcon: $,
123
+ defaultExpanded: S = _t,
124
+ defaultExpandIcon: P,
125
+ defaultParentIcon: N,
126
+ defaultSelected: T = At,
127
+ disabledItemsFocusable: w = !1,
128
+ disableSelection: x = !1,
129
+ expanded: J,
130
+ id: D,
131
+ multiSelect: g = !1,
132
+ onBlur: L,
133
+ onFocus: Q,
134
+ onKeyDown: X,
72
135
  onNodeFocus: ue,
73
- onNodeSelect: O,
74
- onNodeToggle: W,
75
- selected: Fe,
76
- ...Pe
77
- } = y, de = Ct().direction === "rtl", fe = {
78
- ...y,
79
- defaultExpanded: A,
80
- defaultSelected: q,
81
- disabledItemsFocusable: N,
82
- disableSelection: g,
83
- multiSelect: p
84
- }, Ae = kt(fe), pe = Nt(I), re = f.useRef(null), De = Ot(re, E), [a, ne] = f.useState(null), i = f.useRef({}), j = f.useRef({}), [F, he] = ye({
85
- controlled: ie,
86
- default: A,
136
+ onNodeSelect: k,
137
+ onNodeToggle: Y,
138
+ selected: Ae,
139
+ ...Ve
140
+ } = p, de = Ot().direction === "rtl", fe = {
141
+ ...p,
142
+ defaultExpanded: S,
143
+ defaultSelected: T,
144
+ disabledItemsFocusable: w,
145
+ disableSelection: x,
146
+ multiSelect: g
147
+ }, je = kt(fe), pe = Tt(D), ne = u.useRef(null), Ke = Et(ne, m), [c, se] = u.useState(null), d = u.useRef({}), q = u.useRef({}), [A, he] = Ce({
148
+ controlled: J,
149
+ default: S,
87
150
  name: "TreeView",
88
151
  state: "expanded"
89
- }), [h, H] = ye({
90
- controlled: Fe,
91
- default: q,
152
+ }), [y, Z] = Ce({
153
+ controlled: Ae,
154
+ default: T,
92
155
  name: "TreeView",
93
156
  state: "selected"
94
- }), T = f.useCallback((e) => Array.isArray(F) ? F.indexOf(e) !== -1 : !1, [F]), G = f.useCallback((e) => i.current[e] && i.current[e].expandable, []), Me = f.useCallback((e) => Array.isArray(h) ? h.indexOf(e) !== -1 : h === e, [h]), m = f.useCallback((e) => {
95
- let t = i.current[e];
157
+ }), F = u.useCallback((e) => Array.isArray(A) ? A.indexOf(e) !== -1 : !1, [A]), v = u.useCallback((e) => d.current[e] && d.current[e].expandable, []), Le = u.useCallback((e) => Array.isArray(y) ? y.indexOf(e) !== -1 : y === e, [y]), C = u.useCallback((e) => {
158
+ let t = d.current[e];
96
159
  if (!t)
97
160
  return !1;
98
161
  if (t.disabled)
99
162
  return !0;
100
163
  for (; t.parentId != null; )
101
- if (t = i.current[t.parentId], t.disabled)
164
+ if (t = d.current[t.parentId], t.disabled)
102
165
  return !0;
103
166
  return !1;
104
- }, []), _e = (e) => a === e, J = (e) => Object.keys(i.current).map((t) => i.current[t]).filter((t) => t.parentId === e).sort((t, r) => t.index - r.index).map((t) => t.id), S = (e) => {
105
- let t = J(e);
106
- return N || (t = t.filter((r) => !m(r))), t;
107
- }, Q = (e) => {
108
- if (T(e) && S(e).length > 0)
109
- return S(e)[0];
110
- let t = i.current[e];
167
+ }, []), Be = (e) => c === e, ee = (e) => Object.keys(d.current).map((t) => d.current[t]).filter((t) => t.parentId === e).sort((t, r) => t.index - r.index).map((t) => t.id), E = (e) => {
168
+ let t = ee(e);
169
+ return w || (t = t.filter((r) => !C(r))), t;
170
+ }, te = (e) => {
171
+ if (F(e) && E(e).length > 0)
172
+ return E(e)[0];
173
+ let t = d.current[e];
111
174
  for (; t != null; ) {
112
- const r = S(t.parentId), n = r[r.indexOf(t.id) + 1];
175
+ const r = E(t.parentId), n = r[r.indexOf(t.id) + 1];
113
176
  if (n)
114
177
  return n;
115
- t = i.current[t.parentId];
178
+ t = d.current[t.parentId];
116
179
  }
117
180
  return null;
118
- }, se = (e) => {
119
- const t = i.current[e], r = S(t.parentId), n = r.indexOf(e);
181
+ }, oe = (e) => {
182
+ const t = d.current[e], r = E(t.parentId), n = r.indexOf(e);
120
183
  if (n === 0)
121
184
  return t.parentId;
122
- let s = r[n - 1];
123
- for (; T(s) && S(s).length > 0; )
124
- s = S(s).pop();
125
- return s;
126
- }, oe = () => {
127
- let e = S(null).pop();
128
- for (; T(e); )
129
- e = S(e).pop();
185
+ let o = r[n - 1];
186
+ for (; F(o) && E(o).length > 0; )
187
+ o = E(o).pop();
188
+ return o;
189
+ }, ce = () => {
190
+ let e = E(null).pop();
191
+ for (; F(e); )
192
+ e = E(e).pop();
130
193
  return e;
131
- }, ae = () => S(null)[0], je = (e) => i.current[e].parentId, Ve = (e, t) => {
194
+ }, ae = () => E(null)[0], Ue = (e) => d.current[e].parentId, $e = (e, t) => {
132
195
  if (e === t)
133
196
  return [e, t];
134
- const r = i.current[e], n = i.current[t];
197
+ const r = d.current[e], n = d.current[t];
135
198
  if (r.parentId === n.id || n.parentId === r.id)
136
199
  return n.parentId === r.id ? [r.id, n.id] : [n.id, r.id];
137
- const s = [r.id], c = [n.id];
138
- let l = r.parentId, u = n.parentId, x = c.indexOf(l) !== -1, K = s.indexOf(u) !== -1, _ = !0, L = !0;
139
- for (; !K && !x; )
140
- _ && (s.push(l), x = c.indexOf(l) !== -1, _ = l !== null, !x && _ && (l = i.current[l].parentId)), L && !x && (c.push(u), K = s.indexOf(u) !== -1, L = u !== null, !K && L && (u = i.current[u].parentId));
141
- const B = x ? l : u, be = J(B), ct = s[s.indexOf(B) - 1], lt = c[c.indexOf(B) - 1];
142
- return be.indexOf(ct) < be.indexOf(lt) ? [e, t] : [t, e];
143
- }, Ke = (e, t) => {
144
- const [r, n] = Ve(e, t), s = [r];
145
- let c = r;
146
- for (; c !== n; )
147
- c = Q(c), s.push(c);
148
- return s;
149
- }, R = (e, t) => {
150
- t && (ne(t), ue && ue(e, t));
151
- }, me = (e, t) => R(e, Q(t)), Le = (e, t) => R(e, se(t)), Be = (e) => R(e, ae()), $e = (e) => R(e, oe()), qe = (e, t, r) => {
152
- let n, s;
153
- const c = r.toLowerCase(), l = [], u = [];
154
- Object.keys(j.current).forEach((x) => {
155
- const K = j.current[x], _ = i.current[x], L = _.parentId ? T(_.parentId) : !0, B = N ? !1 : m(x);
156
- L && !B && (l.push(x), u.push(K));
157
- }), n = l.indexOf(t) + 1, n >= l.length && (n = 0), s = Ie(u, n, c), s === -1 && (s = Ie(u, 0, c)), s > -1 && R(e, l[s]);
158
- }, X = (e, t = a) => {
200
+ const o = [r.id], a = [n.id];
201
+ let l = r.parentId, f = n.parentId, I = a.indexOf(l) !== -1, W = o.indexOf(f) !== -1, U = !0, G = !0;
202
+ for (; !W && !I; )
203
+ U && (o.push(l), I = a.indexOf(l) !== -1, U = l !== null, !I && U && (l = d.current[l].parentId)), G && !I && (a.push(f), W = o.indexOf(f) !== -1, G = f !== null, !W && G && (f = d.current[f].parentId));
204
+ const H = I ? l : f, be = ee(H), ft = o[o.indexOf(H) - 1], pt = a[a.indexOf(H) - 1];
205
+ return be.indexOf(ft) < be.indexOf(pt) ? [e, t] : [t, e];
206
+ }, qe = (e, t) => {
207
+ const [r, n] = $e(e, t), o = [r];
208
+ let a = r;
209
+ for (; a !== n; )
210
+ a = te(a), o.push(a);
211
+ return o;
212
+ }, M = (e, t) => {
213
+ t && (se(t), ue && ue(e, t));
214
+ }, me = (e, t) => M(e, te(t)), ze = (e, t) => M(e, oe(t)), We = (e) => M(e, ae()), Ge = (e) => M(e, ce()), He = (e, t, r) => {
215
+ let n, o;
216
+ const a = r.toLowerCase(), l = [], f = [];
217
+ Object.keys(q.current).forEach((I) => {
218
+ const W = q.current[I], U = d.current[I], G = U.parentId ? F(U.parentId) : !0, H = w ? !1 : C(I);
219
+ G && !H && (l.push(I), f.push(W));
220
+ }), n = l.indexOf(t) + 1, n >= l.length && (n = 0), o = Ie(f, n, a), o === -1 && (o = Ie(f, 0, a)), o > -1 && M(e, l[o]);
221
+ }, re = (e, t = c) => {
159
222
  let r;
160
- F.indexOf(t) !== -1 ? r = F.filter((n) => n !== t) : r = [t].concat(F), W && W(e, r), he(r);
161
- }, Ue = (e, t) => {
162
- const r = i.current[t], s = J(r.parentId).filter((l) => G(l) && !T(l)), c = F.concat(s);
163
- s.length > 0 && (he(c), W && W(e, c));
164
- }, k = f.useRef(null), M = f.useRef(!1), w = f.useRef([]), ze = (e, t) => {
165
- let r = h.slice();
223
+ A.indexOf(t) !== -1 ? r = A.filter((n) => n !== t) : r = [t].concat(A), Y && Y(e, r), he(r);
224
+ }, Je = (e, t) => {
225
+ const r = d.current[t], o = ee(r.parentId).filter((l) => v(l) && !F(l)), a = A.concat(o);
226
+ o.length > 0 && (he(a), Y && Y(e, a));
227
+ }, _ = u.useRef(null), B = u.useRef(!1), R = u.useRef([]), Qe = (e, t) => {
228
+ let r = y.slice();
166
229
  const {
167
230
  start: n,
168
- next: s,
169
- current: c
231
+ next: o,
232
+ current: a
170
233
  } = t;
171
- !s || !c || (w.current.indexOf(c) === -1 && (w.current = []), M.current ? w.current.indexOf(s) !== -1 ? (r = r.filter((l) => l === n || l !== c), w.current = w.current.filter((l) => l === n || l !== c)) : (r.push(s), w.current.push(s)) : (r.push(s), w.current.push(c, s)), O && O(e, r), H(r));
172
- }, We = (e, t) => {
173
- let r = h.slice();
234
+ !o || !a || (R.current.indexOf(a) === -1 && (R.current = []), B.current ? R.current.indexOf(o) !== -1 ? (r = r.filter((l) => l === n || l !== a), R.current = R.current.filter((l) => l === n || l !== a)) : (r.push(o), R.current.push(o)) : (r.push(o), R.current.push(a, o)), k && k(e, r), Z(r));
235
+ }, Xe = (e, t) => {
236
+ let r = y.slice();
174
237
  const {
175
238
  start: n,
176
- end: s
239
+ end: o
177
240
  } = t;
178
- M.current && (r = r.filter((u) => w.current.indexOf(u) === -1));
179
- let c = Ke(n, s);
180
- c = c.filter((u) => !m(u)), w.current = c;
181
- let l = r.concat(c);
182
- l = l.filter((u, x) => l.indexOf(u) === x), O && O(e, l), H(l);
183
- }, He = (e, t) => {
241
+ B.current && (r = r.filter((f) => R.current.indexOf(f) === -1));
242
+ let a = qe(n, o);
243
+ a = a.filter((f) => !C(f)), R.current = a;
244
+ let l = r.concat(a);
245
+ l = l.filter((f, I) => l.indexOf(f) === I), k && k(e, l), Z(l);
246
+ }, Ye = (e, t) => {
184
247
  let r;
185
- h.indexOf(t) !== -1 ? r = h.filter((n) => n !== t) : r = [t].concat(h), O && O(e, r), H(r);
186
- }, Ge = (e, t) => {
187
- const r = p ? [t] : t;
188
- O && O(e, r), H(r);
189
- }, V = (e, t, r = !1) => t ? (r ? He(e, t) : Ge(e, t), k.current = t, M.current = !1, w.current = [], !0) : !1, P = (e, t, r = !1) => {
248
+ y.indexOf(t) !== -1 ? r = y.filter((n) => n !== t) : r = [t].concat(y), k && k(e, r), Z(r);
249
+ }, Ze = (e, t) => {
250
+ const r = g ? [t] : t;
251
+ k && k(e, r), Z(r);
252
+ }, z = (e, t, r = !1) => t ? (r ? Ye(e, t) : Ze(e, t), _.current = t, B.current = !1, R.current = [], !0) : !1, V = (e, t, r = !1) => {
190
253
  const {
191
- start: n = k.current,
192
- end: s,
193
- current: c
254
+ start: n = _.current,
255
+ end: o,
256
+ current: a
194
257
  } = t;
195
- r ? ze(e, {
258
+ r ? Qe(e, {
196
259
  start: n,
197
- next: s,
198
- current: c
199
- }) : n != null && s != null && We(e, {
260
+ next: o,
261
+ current: a
262
+ }) : n != null && o != null && Xe(e, {
200
263
  start: n,
201
- end: s
202
- }), M.current = !0;
203
- }, Je = (e, t) => {
204
- k.current || (k.current = t);
205
- const r = M.current ? k.current : t;
206
- P(e, {
264
+ end: o
265
+ }), B.current = !0;
266
+ }, ve = (e, t) => {
267
+ _.current || (_.current = t);
268
+ const r = B.current ? _.current : t;
269
+ V(e, {
207
270
  start: r,
208
271
  end: ae()
209
272
  });
210
- }, Qe = (e, t) => {
211
- k.current || (k.current = t);
212
- const r = M.current ? k.current : t;
213
- P(e, {
273
+ }, et = (e, t) => {
274
+ _.current || (_.current = t);
275
+ const r = B.current ? _.current : t;
276
+ V(e, {
214
277
  start: r,
215
- end: oe()
278
+ end: ce()
216
279
  });
217
- }, Xe = (e, t) => {
218
- m(Q(t)) || P(e, {
219
- end: Q(t),
280
+ }, tt = (e, t) => {
281
+ C(te(t)) || V(e, {
282
+ end: te(t),
220
283
  current: t
221
284
  }, !0);
222
- }, Ye = (e, t) => {
223
- m(se(t)) || P(e, {
224
- end: se(t),
285
+ }, rt = (e, t) => {
286
+ C(oe(t)) || V(e, {
287
+ end: oe(t),
225
288
  current: t
226
289
  }, !0);
227
- }, Ze = (e) => {
228
- P(e, {
290
+ }, nt = (e) => {
291
+ V(e, {
229
292
  start: ae(),
230
- end: oe()
293
+ end: ce()
231
294
  });
232
- }, ve = f.useCallback((e) => {
295
+ }, st = u.useCallback((e) => {
233
296
  const {
234
297
  id: t,
235
298
  index: r,
236
299
  parentId: n,
237
- expandable: s,
238
- idAttribute: c,
300
+ expandable: o,
301
+ idAttribute: a,
239
302
  disabled: l
240
303
  } = e;
241
- i.current[t] = {
304
+ d.current[t] = {
242
305
  id: t,
243
306
  index: r,
244
307
  parentId: n,
245
- expandable: s,
246
- idAttribute: c,
308
+ expandable: o,
309
+ idAttribute: a,
247
310
  disabled: l
248
311
  };
249
- }, []), et = f.useCallback((e) => {
312
+ }, []), ot = u.useCallback((e) => {
250
313
  const t = {
251
- ...i.current
314
+ ...d.current
252
315
  };
253
- delete t[e], i.current = t, ne((r) => r === e && re.current === Tt(re.current).activeElement ? J(null)[0] : r);
254
- }, []), tt = f.useCallback((e, t) => {
255
- j.current[e] = t;
256
- }, []), rt = f.useCallback((e) => {
316
+ delete t[e], d.current = t, se((r) => r === e && ne.current === Rt(ne.current).activeElement ? ee(null)[0] : r);
317
+ }, []), ct = u.useCallback((e, t) => {
318
+ q.current[e] = t;
319
+ }, []), at = u.useCallback((e) => {
257
320
  const t = {
258
- ...j.current
321
+ ...q.current
259
322
  };
260
- delete t[e], j.current = t;
261
- }, []), xe = (e) => (G(a) && (T(a) ? me(e, a) : m(a) || X(e)), !0), ge = (e) => {
262
- if (T(a) && !m(a))
263
- return X(e, a), !0;
264
- const t = je(a);
265
- return t ? (R(e, t), !0) : !1;
266
- }, nt = (e) => {
323
+ delete t[e], q.current = t;
324
+ }, []), xe = (e) => (v(c) && (F(c) ? me(e, c) : C(c) || re(e)), !0), ge = (e) => {
325
+ if (F(c) && !C(c))
326
+ return re(e, c), !0;
327
+ const t = Ue(c);
328
+ return t ? (M(e, t), !0) : !1;
329
+ }, lt = (e) => {
267
330
  let t = !1;
268
331
  const r = e.key;
269
- if (e.altKey || e.currentTarget !== e.target || !a)
332
+ if (e.altKey || e.currentTarget !== e.target || !c)
270
333
  return;
271
334
  const n = e.ctrlKey || e.metaKey;
272
335
  switch (r) {
273
336
  case " ":
274
- !g && !m(a) && (p && e.shiftKey ? (P(e, {
275
- end: a
276
- }), t = !0) : p ? t = V(e, a, !0) : t = V(e, a)), e.stopPropagation();
337
+ !x && !C(c) && (g && e.shiftKey ? (V(e, {
338
+ end: c
339
+ }), t = !0) : g ? t = z(e, c, !0) : t = z(e, c)), e.stopPropagation();
277
340
  break;
278
341
  case "Enter":
279
- m(a) || (G(a) ? (X(e), t = !0) : p ? t = V(e, a, !0) : t = V(e, a)), e.stopPropagation();
342
+ C(c) || (v(c) ? (re(e), t = !0) : g ? t = z(e, c, !0) : t = z(e, c)), e.stopPropagation();
280
343
  break;
281
344
  case "ArrowDown":
282
- p && e.shiftKey && !g && Xe(e, a), me(e, a), t = !0;
345
+ g && e.shiftKey && !x && tt(e, c), me(e, c), t = !0;
283
346
  break;
284
347
  case "ArrowUp":
285
- p && e.shiftKey && !g && Ye(e, a), Le(e, a), t = !0;
348
+ g && e.shiftKey && !x && rt(e, c), ze(e, c), t = !0;
286
349
  break;
287
350
  case "ArrowRight":
288
351
  de ? t = ge(e) : t = xe(e);
@@ -291,71 +354,71 @@ const Pt = [], At = [], Re = /* @__PURE__ */ f.forwardRef(function(b, E) {
291
354
  de ? t = xe(e) : t = ge(e);
292
355
  break;
293
356
  case "Home":
294
- p && n && e.shiftKey && !g && !m(a) && Je(e, a), Be(e), t = !0;
357
+ g && n && e.shiftKey && !x && !C(c) && ve(e, c), We(e), t = !0;
295
358
  break;
296
359
  case "End":
297
- p && n && e.shiftKey && !g && !m(a) && Qe(e, a), $e(e), t = !0;
360
+ g && n && e.shiftKey && !x && !C(c) && et(e, c), Ge(e), t = !0;
298
361
  break;
299
362
  default:
300
- r === "*" ? (Ue(e, a), t = !0) : p && n && r.toLowerCase() === "a" && !g ? (Ze(e), t = !0) : !n && !e.shiftKey && Ft(r) && (qe(e, a, r), t = !0);
363
+ r === "*" ? (Je(e, c), t = !0) : g && n && r.toLowerCase() === "a" && !x ? (nt(e), t = !0) : !n && !e.shiftKey && Mt(r) && (He(e, c, r), t = !0);
301
364
  }
302
- t && (e.preventDefault(), e.stopPropagation()), z && z(e);
303
- }, st = (e) => {
365
+ t && (e.preventDefault(), e.stopPropagation()), X && X(e);
366
+ }, it = (e) => {
304
367
  if (e.target === e.currentTarget) {
305
- const t = Array.isArray(h) ? h[0] : h;
306
- R(e, t || S(null)[0]);
368
+ const t = Array.isArray(y) ? y[0] : y;
369
+ M(e, t || E(null)[0]);
307
370
  }
308
- U && U(e);
309
- }, ot = (e) => {
310
- ne(null), D && D(e);
311
- }, at = i.current[a] ? i.current[a].idAttribute : null;
312
- return /* @__PURE__ */ C(dt.Provider, {
371
+ Q && Q(e);
372
+ }, ut = (e) => {
373
+ se(null), L && L(e);
374
+ }, dt = d.current[c] ? d.current[c].idAttribute : null;
375
+ return /* @__PURE__ */ O(De.Provider, {
313
376
  // TODO: fix this lint error
314
377
  // eslint-disable-next-line react/jsx-no-constructed-context-values
315
378
  value: {
316
379
  icons: {
317
- defaultCollapseIcon: Z,
318
- defaultExpandIcon: ee,
319
- defaultParentIcon: te,
320
- defaultEndIcon: v
380
+ defaultCollapseIcon: K,
381
+ defaultExpandIcon: P,
382
+ defaultParentIcon: N,
383
+ defaultEndIcon: $
321
384
  },
322
- focus: R,
323
- toggleExpansion: X,
324
- isExpanded: T,
325
- isExpandable: G,
326
- isFocused: _e,
327
- isSelected: Me,
328
- isDisabled: m,
329
- selectNode: g ? Ce : V,
330
- selectRange: g ? Ce : P,
331
- multiSelect: p,
332
- disabledItemsFocusable: N,
333
- mapFirstChar: tt,
334
- unMapFirstChar: rt,
335
- registerNode: ve,
336
- unregisterNode: et,
385
+ focus: M,
386
+ toggleExpansion: re,
387
+ isExpanded: F,
388
+ isExpandable: v,
389
+ isFocused: Be,
390
+ isSelected: Le,
391
+ isDisabled: C,
392
+ selectNode: x ? Oe : z,
393
+ selectRange: x ? Oe : V,
394
+ multiSelect: g,
395
+ disabledItemsFocusable: w,
396
+ mapFirstChar: ct,
397
+ unMapFirstChar: at,
398
+ registerNode: st,
399
+ unregisterNode: ot,
337
400
  treeId: pe
338
401
  },
339
- children: /* @__PURE__ */ C(ft, {
340
- children: /* @__PURE__ */ C(Et, {
402
+ children: /* @__PURE__ */ O(ke, {
403
+ children: /* @__PURE__ */ O(Ft, {
341
404
  role: "tree",
342
405
  id: pe,
343
- "aria-activedescendant": at,
344
- "aria-multiselectable": p,
345
- className: St(Ae.root, Y),
346
- ref: De,
406
+ "aria-activedescendant": dt,
407
+ "aria-multiselectable": g,
408
+ className: Nt(je.root, j),
409
+ ref: Ke,
347
410
  tabIndex: 0,
348
- onKeyDown: nt,
349
- onFocus: st,
350
- onBlur: ot,
411
+ onKeyDown: lt,
412
+ onFocus: it,
413
+ onBlur: ut,
351
414
  ownerState: fe,
352
- ...Pe,
353
- children: $
415
+ ...Ve,
416
+ children: b
354
417
  })
355
418
  })
356
419
  });
357
420
  });
358
- process.env.NODE_ENV !== "production" && (Re.propTypes = {
421
+ process.env.NODE_ENV !== "production" && (Fe.propTypes = {
359
422
  // ----------------------------- Warning --------------------------------
360
423
  // | These PropTypes are generated from the TypeScript type definitions |
361
424
  // | To update them edit the d.ts file and run "yarn proptypes" |
@@ -363,87 +426,87 @@ process.env.NODE_ENV !== "production" && (Re.propTypes = {
363
426
  /**
364
427
  * The content of the component.
365
428
  */
366
- children: o.node,
429
+ children: s.node,
367
430
  /**
368
431
  * Override or extend the styles applied to the component.
369
432
  */
370
- classes: o.object,
433
+ classes: s.object,
371
434
  /**
372
435
  * @ignore
373
436
  */
374
- className: o.string,
437
+ className: s.string,
375
438
  /**
376
439
  * The default icon used to collapse the node.
377
440
  */
378
- defaultCollapseIcon: o.node,
441
+ defaultCollapseIcon: s.node,
379
442
  /**
380
443
  * The default icon displayed next to a end node. This is applied to all
381
444
  * tree nodes and can be overridden by the TreeItem `icon` prop.
382
445
  */
383
- defaultEndIcon: o.node,
446
+ defaultEndIcon: s.node,
384
447
  /**
385
448
  * Expanded node ids. (Uncontrolled)
386
449
  * @default []
387
450
  */
388
- defaultExpanded: o.arrayOf(o.string),
451
+ defaultExpanded: s.arrayOf(s.string),
389
452
  /**
390
453
  * The default icon used to expand the node.
391
454
  */
392
- defaultExpandIcon: o.node,
455
+ defaultExpandIcon: s.node,
393
456
  /**
394
457
  * The default icon displayed next to a parent node. This is applied to all
395
458
  * parent nodes and can be overridden by the TreeItem `icon` prop.
396
459
  */
397
- defaultParentIcon: o.node,
460
+ defaultParentIcon: s.node,
398
461
  /**
399
462
  * Selected node ids. (Uncontrolled)
400
463
  * When `multiSelect` is true this takes an array of strings; when false (default) a string.
401
464
  * @default []
402
465
  */
403
- defaultSelected: o.oneOfType([o.arrayOf(o.string), o.string]),
466
+ defaultSelected: s.oneOfType([s.arrayOf(s.string), s.string]),
404
467
  /**
405
468
  * If `true`, will allow focus on disabled items.
406
469
  * @default false
407
470
  */
408
- disabledItemsFocusable: o.bool,
471
+ disabledItemsFocusable: s.bool,
409
472
  /**
410
473
  * If `true` selection is disabled.
411
474
  * @default false
412
475
  */
413
- disableSelection: o.bool,
476
+ disableSelection: s.bool,
414
477
  /**
415
478
  * Expanded node ids. (Controlled)
416
479
  */
417
- expanded: o.arrayOf(o.string),
480
+ expanded: s.arrayOf(s.string),
418
481
  /**
419
482
  * This prop is used to help implement the accessibility logic.
420
483
  * If you don't provide this prop. It falls back to a randomly generated id.
421
484
  */
422
- id: o.string,
485
+ id: s.string,
423
486
  /**
424
487
  * If true `ctrl` and `shift` will trigger multiselect.
425
488
  * @default false
426
489
  */
427
- multiSelect: o.bool,
490
+ multiSelect: s.bool,
428
491
  /**
429
492
  * @ignore
430
493
  */
431
- onBlur: o.func,
494
+ onBlur: s.func,
432
495
  /**
433
496
  * @ignore
434
497
  */
435
- onFocus: o.func,
498
+ onFocus: s.func,
436
499
  /**
437
500
  * @ignore
438
501
  */
439
- onKeyDown: o.func,
502
+ onKeyDown: s.func,
440
503
  /**
441
504
  * Callback fired when tree items are focused.
442
505
  *
443
506
  * @param {React.SyntheticEvent} event The event source of the callback **Warning**: This is a generic event not a focus event.
444
507
  * @param {string} value of the focused node.
445
508
  */
446
- onNodeFocus: o.func,
509
+ onNodeFocus: s.func,
447
510
  /**
448
511
  * Callback fired when tree items are selected/unselected.
449
512
  *
@@ -451,99 +514,102 @@ process.env.NODE_ENV !== "production" && (Re.propTypes = {
451
514
  * @param {string[] | string} nodeIds Ids of the selected nodes. When `multiSelect` is true
452
515
  * this is an array of strings; when false (default) a string.
453
516
  */
454
- onNodeSelect: o.func,
517
+ onNodeSelect: s.func,
455
518
  /**
456
519
  * Callback fired when tree items are expanded/collapsed.
457
520
  *
458
521
  * @param {React.SyntheticEvent} event The event source of the callback.
459
522
  * @param {array} nodeIds The ids of the expanded nodes.
460
523
  */
461
- onNodeToggle: o.func,
524
+ onNodeToggle: s.func,
462
525
  /**
463
526
  * Selected node ids. (Controlled)
464
527
  * When `multiSelect` is true this takes an array of strings; when false (default) a string.
465
528
  */
466
- selected: o.oneOfType([o.arrayOf(o.string), o.string]),
529
+ selected: s.oneOfType([s.arrayOf(s.string), s.string]),
467
530
  /**
468
531
  * The system prop that allows defining system overrides as well as additional CSS styles.
469
532
  */
470
- sx: o.oneOfType([o.arrayOf(o.oneOfType([o.func, o.object, o.bool])), o.func, o.object])
533
+ sx: s.oneOfType([s.arrayOf(s.oneOfType([s.func, s.object, s.bool])), s.func, s.object])
471
534
  });
472
- var ce = {}, Dt = Te;
473
- Object.defineProperty(ce, "__esModule", {
535
+ var le = {}, Vt = Re;
536
+ Object.defineProperty(le, "__esModule", {
474
537
  value: !0
475
538
  });
476
- var ke = ce.default = void 0, Mt = Dt(Oe()), _t = Ne;
477
- ke = ce.default = (0, Mt.default)(/* @__PURE__ */ (0, _t.jsx)("path", {
539
+ var Me = le.default = void 0, jt = Vt(Ee()), Kt = Te;
540
+ Me = le.default = (0, jt.default)(/* @__PURE__ */ (0, Kt.jsx)("path", {
478
541
  d: "M16.59 8.59 12 13.17 7.41 8.59 6 10l6 6 6-6z"
479
542
  }), "ExpandMore");
480
- var le = {}, jt = Te;
481
- Object.defineProperty(le, "__esModule", {
543
+ var ie = {}, Lt = Re;
544
+ Object.defineProperty(ie, "__esModule", {
482
545
  value: !0
483
546
  });
484
- var Ee = le.default = void 0, Vt = jt(Oe()), Kt = Ne;
485
- Ee = le.default = (0, Vt.default)(/* @__PURE__ */ (0, Kt.jsx)("path", {
547
+ var _e = ie.default = void 0, Bt = Lt(Ee()), Ut = Te;
548
+ _e = ie.default = (0, Bt.default)(/* @__PURE__ */ (0, Ut.jsx)("path", {
486
549
  d: "M10 6 8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z"
487
550
  }), "ChevronRight");
488
- const rr = ({
489
- data: d,
490
- idKey: b = "id",
491
- selected: E,
492
- expanded: y,
493
- disabled: $,
494
- disableSearch: Y,
495
- onChange: Z,
496
- onToggle: v
551
+ const cr = ({
552
+ data: i,
553
+ idKey: h = "id",
554
+ selected: m,
555
+ expanded: p,
556
+ disabled: b,
557
+ disableSearch: j,
558
+ onChange: K,
559
+ onToggle: $
497
560
  }) => {
498
- const [A, ee] = Se.useState(""), te = xt(d), q = Se.useMemo(() => A.length > 0 ? te.filter(
499
- (I) => I.name.toLowerCase().includes(A)
500
- ) : d, [A, d]);
501
- let N = null;
502
- const g = 500;
503
- return /* @__PURE__ */ it(ut, { children: [
504
- !Y && /* @__PURE__ */ C(ht, { px: 1, children: /* @__PURE__ */ C(
505
- mt,
506
- {
507
- fullWidth: !0,
508
- disableLabel: !0,
509
- placeholder: "Search",
510
- sx: {
511
- "& .MuiInputBase-input": {
512
- p: "8px 0px 8px 12px",
513
- fontSize: "small"
561
+ const [S, P] = Ne.useState(""), N = bt(i), T = Ne.useMemo(() => S.length > 0 ? N.filter(
562
+ (D) => D.name.toLowerCase().includes(S)
563
+ ) : i, [S, i]);
564
+ let w = null;
565
+ const x = 500;
566
+ return /* @__PURE__ */ Se(we, { children: [
567
+ !j && /* @__PURE__ */ Se(we, { children: [
568
+ /* @__PURE__ */ O(mt, { px: 1, pt: 0.75, children: /* @__PURE__ */ O(
569
+ gt,
570
+ {
571
+ fullWidth: !0,
572
+ disableLabel: !0,
573
+ placeholder: "Filter",
574
+ sx: {
575
+ "& .MuiInputBase-input": {
576
+ p: "8px 0px 8px 12px",
577
+ fontSize: "small"
578
+ }
579
+ },
580
+ iconSize: "small",
581
+ onChange: (D) => {
582
+ w && clearTimeout(w), w = setTimeout(() => P(D.toLowerCase()), x);
514
583
  }
515
- },
516
- iconSize: "small",
517
- onChange: (I) => {
518
- N && clearTimeout(N), N = setTimeout(() => ee(I.toLowerCase()), g);
519
584
  }
520
- }
521
- ) }),
522
- /* @__PURE__ */ C(
523
- Re,
585
+ ) }),
586
+ /* @__PURE__ */ O(xt, { sx: { mt: 1.75 } })
587
+ ] }),
588
+ /* @__PURE__ */ O(
589
+ Fe,
524
590
  {
525
591
  "aria-label": "tree view filter",
526
- defaultCollapseIcon: /* @__PURE__ */ C(ke, {}),
527
- defaultExpandIcon: /* @__PURE__ */ C(Ee, {}),
592
+ defaultCollapseIcon: /* @__PURE__ */ O(Me, {}),
593
+ defaultExpandIcon: /* @__PURE__ */ O(_e, {}),
528
594
  disableSelection: !0,
529
- expanded: y,
530
- onNodeToggle: v,
531
- children: q.map((I, p) => {
532
- const D = String(I[b]), U = we.includes(E, D), z = we.includes($, D);
533
- return /* @__PURE__ */ C(
534
- pt,
595
+ expanded: p,
596
+ onNodeToggle: $,
597
+ children: T.map((D, g) => {
598
+ const L = String(D[h]), Q = ye.includes(m, L), X = ye.includes(b, L);
599
+ return /* @__PURE__ */ O(
600
+ ht,
535
601
  {
536
- id: D,
537
- idKey: b,
538
- name: I.name,
539
- checked: U,
540
- disabled: z,
541
- disabledIds: $,
542
- children: I.children,
543
- onChange: Z,
544
- defaultSelected: E
602
+ id: L,
603
+ idKey: h,
604
+ name: D.name,
605
+ checked: Q,
606
+ disabled: X,
607
+ disabledIds: b,
608
+ children: D.children,
609
+ onChange: K,
610
+ defaultSelected: m
545
611
  },
546
- p
612
+ g
547
613
  );
548
614
  })
549
615
  }
@@ -551,5 +617,5 @@ const rr = ({
551
617
  ] });
552
618
  };
553
619
  export {
554
- rr as TreeViewFilter
620
+ cr as TreeViewFilter
555
621
  };