@astrato-io/visualizations 0.9.0 → 0.10.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +10 -0
- package/README.md +7 -3
- package/THIRD_PARTY_NOTICES.md +163 -14
- package/VISUALIZATION_DEFINITIONS.md +376 -36
- package/chunks/{Button-5CxPEACP.js → Button-Dn3rJrYf.js} +4 -4
- package/chunks/{CircularProgress-DFS-LQb7.js → CircularProgress-BFeu06Yb.js} +39 -39
- package/chunks/FieldTypeIcon-DrMoGpHJ.js +22 -0
- package/chunks/{LinearProgress-CjIQfkNA.js → LinearProgress-ClO6GUjN.js} +9 -9
- package/chunks/{MenuOption-Cb7B7x6z.js → MenuOption-Czc34u4q.js} +143 -142
- package/chunks/{Title-CtFw1bVg.js → Title-BgYnaVTR.js} +22 -22
- package/chunks/_createAggregator-BMu9uRax.js +50 -0
- package/chunks/{app-filter-bar.compiler-B9775gLJ.js → app-filter-bar.compiler-CVir0wkl.js} +10 -10
- package/chunks/bar-layout-C_UgRlVl.js +9 -0
- package/chunks/{bar.compiler-B7wlH_Ro.js → bar.compiler-DYuFdi9J.js} +100 -82
- package/chunks/{builder-Dxo7D7c6.js → builder-C-TKA-My.js} +70 -37
- package/chunks/color-rules-DYJL4fIW.js +15 -0
- package/chunks/color-settings-DJFoFTip.js +5 -0
- package/chunks/{coloring-B-Wa8D5P.js → coloring-BtnPiQ_o.js} +37 -37
- package/chunks/createSimplePaletteValueFilter--zrZxRV9.js +2005 -0
- package/chunks/defaults-Dtk7fg3C.js +3 -0
- package/chunks/{definitions-DNpzD9tY.js → definitions-CT304NDn.js} +655 -417
- package/chunks/{escobar-C4Nm3eJ7.js → escobar-CvEV2ES1.js} +7441 -7127
- package/chunks/{extend-preset-BVKFtoe-.js → extend-preset-D9-JP92b.js} +998 -933
- package/chunks/{filter.compiler-BlS3zoy_.js → filter.compiler-CXeZznks.js} +7 -7
- package/chunks/{filtering-CGuLpg7u.js → filtering-8_bFv-jb.js} +333 -377
- package/chunks/handlers-C6CZ0XJA.js +15399 -0
- package/chunks/{icon-picker-styles-DYQgVEKG.js → icon-picker-styles-BXiJ1SZS.js} +11 -11
- package/chunks/isEqual-D8Ay63xR.js +16 -0
- package/chunks/{isFocusVisible-B1_z03UT.js → isFocusVisible-Bu8gGZu5.js} +1 -1
- package/chunks/label-format-type-C46pzgx7.js +17 -0
- package/chunks/{line.compiler-Bo9i9qag.js → line.compiler-DmHpmQCC.js} +9 -9
- package/chunks/{logger-3lng-wOw.js → logger-DdZpR7xZ.js} +79 -72
- package/chunks/map.compiler-Q_Y1Pvat.js +343 -0
- package/chunks/{metadata-Fmx1swpK.js → metadata-BQm_TXI1.js} +1 -1
- package/chunks/{number.compiler-CdLd5aGW.js → number.compiler-DQdg6zTy.js} +7 -7
- package/chunks/operations-DKQWuLL7.js +31315 -0
- package/chunks/{range-CzO4isKK.js → range-BdhzvYQ_.js} +2 -2
- package/chunks/{react-dom-BwZT0N3F.js → react-dom-BGP4tbXV.js} +70 -70
- package/chunks/{render-wrappers-CAuvgMxi.js → render-wrappers-BZpyDnJy.js} +1 -1
- package/chunks/{requirements-CYpVh65U.js → requirements-e8Fe96ag.js} +60 -58
- package/chunks/shared-C_2F90xq.js +1337 -0
- package/chunks/standalone-4MsKiqs0.js +355 -0
- package/chunks/standalone-B794g9pE.js +1012 -0
- package/chunks/{standalone-C6XDHYAM.js → standalone-B8ZSqauS.js} +110 -110
- package/chunks/{standalone-5DnapeHH.js → standalone-BA2YXyJS.js} +126 -124
- package/chunks/{standalone-CXniic5x.js → standalone-BDrXVxlP.js} +6 -5
- package/chunks/{standalone-B6s_xG2u.js → standalone-BE_ONgiG.js} +116 -116
- package/chunks/{standalone-CPUiiWNP.js → standalone-BTY3w_JA.js} +37 -37
- package/chunks/standalone-BgumbdaJ2.js +357 -0
- package/chunks/{standalone-DWPfdP0A.js → standalone-BkbiH-o8.js} +482 -482
- package/chunks/standalone-Blh4qejk.js +689 -0
- package/chunks/standalone-CXY4FpF7.js +773 -0
- package/chunks/{standalone-BvWdpUL3.js → standalone-CY_kjarf.js} +34 -31
- package/chunks/{standalone-DuwTOBXH.js → standalone-CaTxAydz.js} +587 -587
- package/chunks/{standalone-BDrQMxLi.js → standalone-Cc98Pdr6.js} +1799 -1015
- package/chunks/{standalone-DMCwtebn.js → standalone-Cl0TSfqC.js} +125 -125
- package/chunks/{standalone-CoQxJ6ov.js → standalone-CsoMmE9T.js} +778 -778
- package/chunks/standalone-DH0xTEes.js +2 -0
- package/chunks/{standalone-LFVgLhia.js → standalone-DHRalbVO.js} +311 -303
- package/chunks/standalone-DNh9NcMa.js +580 -0
- package/chunks/standalone-DcnHjNnC.js +2 -0
- package/chunks/{standalone-r4ObFvys.js → standalone-DflyWtuR.js} +217 -215
- package/chunks/standalone-DrHdGkY7.js +762 -0
- package/chunks/standalone-c_rROMtx.js +287 -0
- package/chunks/standalone-drcFLeN6.js +6 -0
- package/chunks/{standalone-CNkHsynO.js → standalone-wOWRCpdn.js} +54 -56
- package/chunks/{standalone-Cu73fzSr.js → standalone-z0o52o5t.js} +5128 -4908
- package/chunks/{table.compiler-C1qjqXaT.js → table.compiler-COaHE9VD.js} +18 -18
- package/chunks/{useFieldName-mWrD_uk_.js → useFieldName-CdnCWzhd.js} +1 -1
- package/chunks/{utils-DYYD4Zzf.js → utils-DganVptf.js} +4758 -4747
- package/chunks/{view-7fH6mGmY.js → view-Bzlros43.js} +2021 -1665
- package/chunks/{visualization-filters-mVnsnvLP.js → visualization-filters-D7i6oh1Z.js} +3177 -2425
- package/chunks/{with-html-element-B0Clt4jY.js → with-html-element-CiIhFEa5.js} +3740 -3547
- package/definitions.js +2 -2
- package/docs/operations/astrato-app-filter-bar.md +1 -1
- package/docs/operations/bar.md +303 -2
- package/docs/operations/combo.md +262 -1
- package/docs/operations/date-picker.md +1 -1
- package/docs/operations/distribution-gauge.md +1 -1
- package/docs/operations/dot.md +148 -1
- package/docs/operations/filter.md +1 -1
- package/docs/operations/gauge.md +1 -1
- package/docs/operations/heatMap.md +1 -1
- package/docs/operations/histogram.md +262 -1
- package/docs/operations/iframe.md +1 -1
- package/docs/operations/image.md +1 -1
- package/docs/operations/index.md +7 -7
- package/docs/operations/line.md +280 -1
- package/docs/operations/number.md +1 -1
- package/docs/operations/pie.md +1 -1
- package/docs/operations/radar.md +1 -1
- package/docs/operations/sankey.md +1 -1
- package/docs/operations/scatter.md +148 -1
- package/docs/operations/shape.md +1 -1
- package/docs/operations/simpleTextObject.md +1 -1
- package/docs/operations/slider.md +1 -1
- package/docs/operations/table.md +374 -157
- package/docs/operations/tree.md +1 -1
- package/docs/operations/treemap.md +1 -1
- package/docs/operations/waterfall.md +1 -1
- package/docs/operations/word-cloud.md +1 -1
- package/getters.js +2 -2
- package/index.js +482 -434
- package/metadata.js +2 -2
- package/operations.js +5 -5
- package/package.json +72 -67
- package/src/definitions/index.d.ts +7 -1
- package/src/definitions/model/definitions/available-fields.d.ts +2 -2
- package/src/definitions/model/definitions/compilers/compile.d.ts +1 -0
- package/src/definitions/model/definitions/data-item-resolution.d.ts +3 -3
- package/src/definitions/model/definitions/descriptors/descriptor-metadata.d.ts +219 -7
- package/src/definitions/model/definitions/index.d.ts +2 -1
- package/src/definitions/model/definitions/schema-registry.d.ts +305 -0
- package/src/definitions/model/definitions/schemas/bar.schema.d.ts +2 -0
- package/src/definitions/model/definitions/schemas/common.schema.d.ts +4 -3
- package/src/definitions/model/definitions/schemas/index.d.ts +1 -0
- package/src/definitions/model/definitions/schemas/map.schema.d.ts +590 -0
- package/src/definitions/model/definitions/types/compilation.types.d.ts +9 -1
- package/src/definitions/model/definitions/types/definition.types.d.ts +2 -2
- package/src/definitions/model/definitions/types/index.d.ts +1 -1
- package/src/index.d.ts +1 -1
- package/src/operations/index.d.ts +1 -1
- package/src/types.d.ts +17 -13
- package/chunks/FieldTypeIcon-pSVQFemC.js +0 -22
- package/chunks/ToggleButton-Br9HCPCv.js +0 -150
- package/chunks/color-rules-CN7TcGrC.js +0 -6
- package/chunks/color-settings-3VRlf_Vw.js +0 -6
- package/chunks/handlers-CMbyj5y1.js +0 -12930
- package/chunks/isEqual-DBg_b35N.js +0 -12
- package/chunks/label-format-type-weq1XfcX.js +0 -8
- package/chunks/operations-HSqnCRvv.js +0 -26324
- package/chunks/shared-DFoJxjVN.js +0 -1218
- package/chunks/standalone-530a5lvf.js +0 -1003
- package/chunks/standalone-B4jrf4KE.js +0 -354
- package/chunks/standalone-BMoJXGYe.js +0 -2
- package/chunks/standalone-BfvGggeM2.js +0 -355
- package/chunks/standalone-CMJJIi9v.js +0 -2
- package/chunks/standalone-C_Jd4gkj.js +0 -6
- package/chunks/standalone-CiaaibTa.js +0 -518
- package/chunks/standalone-DBeXQrwH.js +0 -468
- package/chunks/standalone-DpSRmAWx.js +0 -287
- package/chunks/standalone-kzAhwH19.js +0 -689
- package/chunks/standalone-mb7LwEiq.js +0 -3874
- /package/chunks/{src-BOS6SqkZ2.js → src-BOS6SqkZ.js} +0 -0
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
import { o as e } from "./rolldown-runtime-DleVn1XH.js";
|
|
2
|
-
import {
|
|
3
|
-
import { $ as
|
|
4
|
-
import { s as
|
|
5
|
-
import { A as z, I as
|
|
6
|
-
import { C as
|
|
7
|
-
import { _ as
|
|
8
|
-
import { a as
|
|
9
|
-
import { f as
|
|
10
|
-
import { n as
|
|
11
|
-
import { d as
|
|
12
|
-
import { t as
|
|
13
|
-
function
|
|
14
|
-
return
|
|
2
|
+
import { Ji as t, Ki as n, Ns as r, Oa as i, Za as a, ho as o, ll as s, mo as c, na as l, po as u, sa as d, ws as f } from "./visualization-filters-D7i6oh1Z.js";
|
|
3
|
+
import { $ as p, A as m, An as h, Er as g, G as _, K as v, Kn as y, Mr as b, Pr as x, Sn as S, W as C, X as w, Y as T, Z as E, Zt as D, c as O, ci as k, f as A, h as j, it as M, jt as N, k as P, l as F, m as I, n as L, wt as R, zr as ee } from "./utils-DganVptf.js";
|
|
4
|
+
import { s as te } from "./logger-DdZpR7xZ.js";
|
|
5
|
+
import { A as z, I as ne, P as re, a as ie, d as B, h as ae, m as oe, u as se } from "./MenuOption-Czc34u4q.js";
|
|
6
|
+
import { C as ce, a as le, b as ue, c as de, d as fe, g as pe, h as me, i as he, l as ge, n as _e, o as ve, r as ye, s as be, t as xe, u as Se, v as Ce, y as we } from "./filtering-8_bFv-jb.js";
|
|
7
|
+
import { _ as Te, a as Ee, c as De, d as V, f as H, g as Oe, i as ke, l as Ae, m as je, o as Me, u as Ne, v as Pe } from "./react-dom-BGP4tbXV.js";
|
|
8
|
+
import { a as Fe, i as U, n as Ie } from "./isFocusVisible-Bu8gGZu5.js";
|
|
9
|
+
import { f as Le, g as Re, l as W, n as ze, p as Be, y as Ve } from "./Title-BgYnaVTR.js";
|
|
10
|
+
import { n as He, r as Ue, t as We } from "./CircularProgress-BFeu06Yb.js";
|
|
11
|
+
import { d as Ge, f as G, p as Ke } from "./responsive.styles-FItb913l.js";
|
|
12
|
+
import { t as qe } from "./Button-Dn3rJrYf.js";
|
|
13
|
+
function Je(e) {
|
|
14
|
+
return Pe("MuiCheckbox", e);
|
|
15
15
|
}
|
|
16
|
-
var
|
|
16
|
+
var Ye = Te("MuiCheckbox", [
|
|
17
17
|
"root",
|
|
18
18
|
"checked",
|
|
19
19
|
"disabled",
|
|
@@ -23,18 +23,18 @@ var Je = we("MuiCheckbox", [
|
|
|
23
23
|
"sizeSmall",
|
|
24
24
|
"sizeMedium"
|
|
25
25
|
]);
|
|
26
|
-
function
|
|
27
|
-
return
|
|
26
|
+
function Xe({ props: e, name: t }) {
|
|
27
|
+
return ce({
|
|
28
28
|
props: e,
|
|
29
29
|
name: t,
|
|
30
|
-
defaultTheme:
|
|
31
|
-
themeId:
|
|
30
|
+
defaultTheme: v,
|
|
31
|
+
themeId: R
|
|
32
32
|
});
|
|
33
33
|
}
|
|
34
|
-
function
|
|
35
|
-
return
|
|
34
|
+
function Ze(e) {
|
|
35
|
+
return Pe("MuiSvgIcon", e);
|
|
36
36
|
}
|
|
37
|
-
|
|
37
|
+
Te("MuiSvgIcon", [
|
|
38
38
|
"root",
|
|
39
39
|
"colorPrimary",
|
|
40
40
|
"colorSecondary",
|
|
@@ -46,31 +46,31 @@ we("MuiSvgIcon", [
|
|
|
46
46
|
"fontSizeMedium",
|
|
47
47
|
"fontSizeLarge"
|
|
48
48
|
]);
|
|
49
|
-
var K = /* @__PURE__ */ e(
|
|
49
|
+
var K = /* @__PURE__ */ e(k(), 1), q = ee(), Qe = (e) => {
|
|
50
50
|
let { color: t, fontSize: n, classes: r } = e;
|
|
51
|
-
return
|
|
51
|
+
return je({ root: [
|
|
52
52
|
"root",
|
|
53
|
-
t !== "inherit" && `color${
|
|
54
|
-
`fontSize${
|
|
55
|
-
] },
|
|
56
|
-
},
|
|
53
|
+
t !== "inherit" && `color${De(t)}`,
|
|
54
|
+
`fontSize${De(n)}`
|
|
55
|
+
] }, Ze, r);
|
|
56
|
+
}, $e = V("svg", {
|
|
57
57
|
name: "MuiSvgIcon",
|
|
58
58
|
slot: "Root",
|
|
59
59
|
overridesResolver: (e, t) => {
|
|
60
60
|
let { ownerState: n } = e;
|
|
61
61
|
return [
|
|
62
62
|
t.root,
|
|
63
|
-
n.color !== "inherit" && t[`color${
|
|
64
|
-
t[`fontSize${
|
|
63
|
+
n.color !== "inherit" && t[`color${De(n.color)}`],
|
|
64
|
+
t[`fontSize${De(n.fontSize)}`]
|
|
65
65
|
];
|
|
66
66
|
}
|
|
67
|
-
})(
|
|
67
|
+
})(Ne(({ theme: e }) => ({
|
|
68
68
|
userSelect: "none",
|
|
69
69
|
width: "1em",
|
|
70
70
|
height: "1em",
|
|
71
71
|
display: "inline-block",
|
|
72
72
|
flexShrink: 0,
|
|
73
|
-
...
|
|
73
|
+
...Ee(e, "fill", { duration: (e.vars ?? e).transitions?.duration?.shorter }),
|
|
74
74
|
variants: [
|
|
75
75
|
{
|
|
76
76
|
props: (e) => !e.hasSvgAsChild,
|
|
@@ -109,8 +109,8 @@ var K = /* @__PURE__ */ e(D(), 1), q = j(), Ze = (e) => {
|
|
|
109
109
|
style: { color: void 0 }
|
|
110
110
|
}
|
|
111
111
|
]
|
|
112
|
-
}))),
|
|
113
|
-
let n =
|
|
112
|
+
}))), et = /*#__PURE__*/ K.forwardRef(function(e, t) {
|
|
113
|
+
let n = Ae({
|
|
114
114
|
props: e,
|
|
115
115
|
name: "MuiSvgIcon"
|
|
116
116
|
}), { children: r, className: i, color: a = "inherit", component: o = "svg", fontSize: s = "medium", htmlColor: c, inheritViewBox: l = !1, titleAccess: u, viewBox: d = "0 0 24 24", ...f } = n, p = /*#__PURE__*/ K.isValidElement(r) && r.type === "svg", m = {
|
|
@@ -124,10 +124,10 @@ var K = /* @__PURE__ */ e(D(), 1), q = j(), Ze = (e) => {
|
|
|
124
124
|
hasSvgAsChild: p
|
|
125
125
|
}, h = {};
|
|
126
126
|
l || (h.viewBox = d);
|
|
127
|
-
let g =
|
|
128
|
-
return /*#__PURE__*/ (0, q.jsxs)(
|
|
127
|
+
let g = Qe(m);
|
|
128
|
+
return /*#__PURE__*/ (0, q.jsxs)($e, {
|
|
129
129
|
as: o,
|
|
130
|
-
className:
|
|
130
|
+
className: M(g.root, i),
|
|
131
131
|
focusable: "false",
|
|
132
132
|
color: c,
|
|
133
133
|
"aria-hidden": !u || void 0,
|
|
@@ -140,22 +140,22 @@ var K = /* @__PURE__ */ e(D(), 1), q = j(), Ze = (e) => {
|
|
|
140
140
|
children: [p ? r.props.children : r, u ? /*#__PURE__*/ (0, q.jsx)("title", { children: u }) : null]
|
|
141
141
|
});
|
|
142
142
|
});
|
|
143
|
-
|
|
144
|
-
function
|
|
143
|
+
et.muiName = "SvgIcon";
|
|
144
|
+
function tt(e, t) {
|
|
145
145
|
function n(t, n) {
|
|
146
|
-
return /*#__PURE__*/ (0, q.jsx)(
|
|
146
|
+
return /*#__PURE__*/ (0, q.jsx)(et, {
|
|
147
147
|
"data-testid": void 0,
|
|
148
148
|
ref: n,
|
|
149
149
|
...t,
|
|
150
150
|
children: e
|
|
151
151
|
});
|
|
152
152
|
}
|
|
153
|
-
return n.muiName =
|
|
153
|
+
return n.muiName = et.muiName, /*#__PURE__*/ K.memo(/*#__PURE__*/ K.forwardRef(n));
|
|
154
154
|
}
|
|
155
|
-
function
|
|
156
|
-
return
|
|
155
|
+
function nt(e) {
|
|
156
|
+
return Pe("MuiCollapse", e);
|
|
157
157
|
}
|
|
158
|
-
|
|
158
|
+
Te("MuiCollapse", [
|
|
159
159
|
"root",
|
|
160
160
|
"horizontal",
|
|
161
161
|
"vertical",
|
|
@@ -164,16 +164,16 @@ we("MuiCollapse", [
|
|
|
164
164
|
"wrapper",
|
|
165
165
|
"wrapperInner"
|
|
166
166
|
]);
|
|
167
|
-
var
|
|
167
|
+
var rt = {}, it = (e) => {
|
|
168
168
|
let { orientation: t, classes: n } = e;
|
|
169
|
-
return
|
|
169
|
+
return je({
|
|
170
170
|
root: ["root", t],
|
|
171
171
|
entered: ["entered"],
|
|
172
172
|
hidden: ["hidden"],
|
|
173
173
|
wrapper: ["wrapper", t],
|
|
174
174
|
wrapperInner: ["wrapperInner", t]
|
|
175
|
-
},
|
|
176
|
-
},
|
|
175
|
+
}, nt, n);
|
|
176
|
+
}, at = V("div", {
|
|
177
177
|
name: "MuiCollapse",
|
|
178
178
|
slot: "Root",
|
|
179
179
|
overridesResolver: (e, t) => {
|
|
@@ -185,7 +185,7 @@ var nt = {}, rt = (e) => {
|
|
|
185
185
|
n.state === "exited" && !n.in && n.collapsedSize === "0px" && t.hidden
|
|
186
186
|
];
|
|
187
187
|
}
|
|
188
|
-
})(
|
|
188
|
+
})(Ne(({ theme: e }) => ({
|
|
189
189
|
height: 0,
|
|
190
190
|
overflow: "hidden",
|
|
191
191
|
transition: e.transitions.create("height"),
|
|
@@ -217,7 +217,7 @@ var nt = {}, rt = (e) => {
|
|
|
217
217
|
style: { visibility: "hidden" }
|
|
218
218
|
}
|
|
219
219
|
]
|
|
220
|
-
}))),
|
|
220
|
+
}))), ot = V("div", {
|
|
221
221
|
name: "MuiCollapse",
|
|
222
222
|
slot: "Wrapper"
|
|
223
223
|
})({
|
|
@@ -230,7 +230,7 @@ var nt = {}, rt = (e) => {
|
|
|
230
230
|
height: "100%"
|
|
231
231
|
}
|
|
232
232
|
}]
|
|
233
|
-
}),
|
|
233
|
+
}), st = V("div", {
|
|
234
234
|
name: "MuiCollapse",
|
|
235
235
|
slot: "WrapperInner"
|
|
236
236
|
})({
|
|
@@ -242,94 +242,94 @@ var nt = {}, rt = (e) => {
|
|
|
242
242
|
height: "100%"
|
|
243
243
|
}
|
|
244
244
|
}]
|
|
245
|
-
}),
|
|
246
|
-
let n =
|
|
245
|
+
}), ct = /*#__PURE__*/ K.forwardRef(function(e, t) {
|
|
246
|
+
let n = Ae({
|
|
247
247
|
props: e,
|
|
248
248
|
name: "MuiCollapse"
|
|
249
|
-
}), { addEndListener: r, children: i, className: a, collapsedSize: o = "0px", component: s, disablePrefersReducedMotion: c = !1, easing: l, in: u, onEnter: d, onEntered: f, onEntering: p, onExit: m, onExited:
|
|
249
|
+
}), { addEndListener: r, children: i, className: a, collapsedSize: o = "0px", component: s, disablePrefersReducedMotion: c = !1, easing: l, in: u, onEnter: d, onEntered: f, onEntering: p, onExit: m, onExited: h, onExiting: g, orientation: v = "vertical", slots: y = rt, slotProps: b = rt, style: x, timeout: S = T.standard, TransitionComponent: C = Be, ...w } = n, E = {
|
|
250
250
|
...n,
|
|
251
251
|
orientation: v,
|
|
252
252
|
collapsedSize: o
|
|
253
|
-
}, D =
|
|
254
|
-
k.current && N && (k.current.style.position = "absolute"), e.style[P] =
|
|
255
|
-
}),
|
|
253
|
+
}, D = it(E), O = _(), k = K.useRef(null), A = K.useRef(null), j = typeof o == "number" ? `${o}px` : o, N = v === "horizontal", P = N ? "width" : "height", F = Le(O.motion.reducedMotion, c), I = K.useRef(null), L = Ve(t, I), R = () => k.current ? k.current[N ? "clientWidth" : "clientHeight"] : 0, ee = Me(I, (e, t) => {
|
|
254
|
+
k.current && N && (k.current.style.position = "absolute"), e.style[P] = j, d && d(e, t);
|
|
255
|
+
}), te = Me(I, (e, t) => {
|
|
256
256
|
let n = R();
|
|
257
257
|
k.current && N && (k.current.style.position = "");
|
|
258
|
-
let { duration: r, easing: i } =
|
|
258
|
+
let { duration: r, easing: i } = ke({
|
|
259
259
|
style: x,
|
|
260
260
|
timeout: S,
|
|
261
261
|
easing: l
|
|
262
262
|
}, { mode: "enter" });
|
|
263
263
|
if (S === "auto" && !F.shouldReduceMotion) {
|
|
264
264
|
let e = O.transitions.getAutoHeightDuration(n);
|
|
265
|
-
|
|
266
|
-
} else
|
|
265
|
+
A.current = e;
|
|
266
|
+
} else A.current = null;
|
|
267
267
|
let a = F.getTransitionTiming({
|
|
268
|
-
duration:
|
|
268
|
+
duration: A.current ?? r,
|
|
269
269
|
delay: void 0
|
|
270
270
|
});
|
|
271
271
|
e.style.transitionDuration = typeof a.duration == "string" ? a.duration : `${a.duration}ms`, e.style[P] = `${n}px`, e.style.transitionTimingFunction = i, p && p(e, t);
|
|
272
|
-
}),
|
|
272
|
+
}), z = Me(I, (e, t) => {
|
|
273
273
|
e.style[P] = "auto", f && f(e, t);
|
|
274
|
-
}), ne =
|
|
274
|
+
}), ne = Me(I, (e) => {
|
|
275
275
|
e.style[P] = `${R()}px`, m && m(e);
|
|
276
|
-
}), re =
|
|
277
|
-
let t = R(), { duration: n, easing: r } =
|
|
276
|
+
}), re = Me(I, h), ie = Me(I, (e) => {
|
|
277
|
+
let t = R(), { duration: n, easing: r } = ke({
|
|
278
278
|
style: x,
|
|
279
279
|
timeout: S,
|
|
280
280
|
easing: l
|
|
281
281
|
}, { mode: "exit" });
|
|
282
282
|
if (S === "auto" && !F.shouldReduceMotion) {
|
|
283
283
|
let e = O.transitions.getAutoHeightDuration(t);
|
|
284
|
-
|
|
285
|
-
} else
|
|
284
|
+
A.current = e;
|
|
285
|
+
} else A.current = null;
|
|
286
286
|
let i = F.getTransitionTiming({
|
|
287
|
-
duration:
|
|
287
|
+
duration: A.current ?? n,
|
|
288
288
|
delay: void 0
|
|
289
289
|
});
|
|
290
|
-
e.style.transitionDuration = typeof i.duration == "string" ? i.duration : `${i.duration}ms`, e.style[P] =
|
|
291
|
-
}),
|
|
290
|
+
e.style.transitionDuration = typeof i.duration == "string" ? i.duration : `${i.duration}ms`, e.style[P] = j, e.style.transitionTimingFunction = r, g && g(e);
|
|
291
|
+
}), B = r ? (e) => {
|
|
292
292
|
r(I.current, e);
|
|
293
293
|
} : void 0, ae = {
|
|
294
294
|
slots: y,
|
|
295
295
|
slotProps: b,
|
|
296
296
|
component: s
|
|
297
|
-
}, [oe, se] =
|
|
297
|
+
}, [oe, se] = Ie("root", {
|
|
298
298
|
ref: L,
|
|
299
|
-
className:
|
|
300
|
-
elementType:
|
|
299
|
+
className: M(D.root, a),
|
|
300
|
+
elementType: at,
|
|
301
301
|
externalForwardedProps: ae,
|
|
302
302
|
ownerState: E,
|
|
303
303
|
additionalProps: { style: {
|
|
304
|
-
[N ? "minWidth" : "minHeight"]:
|
|
304
|
+
[N ? "minWidth" : "minHeight"]: j,
|
|
305
305
|
...x
|
|
306
306
|
} }
|
|
307
|
-
}), [ce, le] =
|
|
307
|
+
}), [ce, le] = Ie("wrapper", {
|
|
308
308
|
ref: k,
|
|
309
309
|
className: D.wrapper,
|
|
310
|
-
elementType:
|
|
310
|
+
elementType: ot,
|
|
311
311
|
externalForwardedProps: ae,
|
|
312
312
|
ownerState: E
|
|
313
|
-
}), [ue, de] =
|
|
313
|
+
}), [ue, de] = Ie("wrapperInner", {
|
|
314
314
|
className: D.wrapperInner,
|
|
315
|
-
elementType:
|
|
315
|
+
elementType: st,
|
|
316
316
|
externalForwardedProps: ae,
|
|
317
317
|
ownerState: E
|
|
318
318
|
});
|
|
319
319
|
return /*#__PURE__*/ (0, q.jsx)(C, {
|
|
320
320
|
in: u,
|
|
321
321
|
onEnter: ee,
|
|
322
|
-
onEntered:
|
|
323
|
-
onEntering:
|
|
322
|
+
onEntered: z,
|
|
323
|
+
onEntering: te,
|
|
324
324
|
onExit: ne,
|
|
325
325
|
onExited: re,
|
|
326
|
-
onExiting:
|
|
327
|
-
addEndListener:
|
|
328
|
-
getAutoTimeout: S === "auto" ? () =>
|
|
326
|
+
onExiting: ie,
|
|
327
|
+
addEndListener: B,
|
|
328
|
+
getAutoTimeout: S === "auto" ? () => A.current : void 0,
|
|
329
329
|
reduceMotion: F.shouldReduceMotion,
|
|
330
330
|
nodeRef: I,
|
|
331
331
|
timeout: S === "auto" ? null : S,
|
|
332
|
-
...
|
|
332
|
+
...w,
|
|
333
333
|
children: (e, { ownerState: t, ...n }) => {
|
|
334
334
|
let r = {
|
|
335
335
|
...E,
|
|
@@ -337,9 +337,9 @@ var nt = {}, rt = (e) => {
|
|
|
337
337
|
};
|
|
338
338
|
return /*#__PURE__*/ (0, q.jsx)(oe, {
|
|
339
339
|
...se,
|
|
340
|
-
className:
|
|
340
|
+
className: M(se.className, {
|
|
341
341
|
entered: D.entered,
|
|
342
|
-
exited: !u &&
|
|
342
|
+
exited: !u && j === "0px" && D.hidden
|
|
343
343
|
}[e]),
|
|
344
344
|
ownerState: r,
|
|
345
345
|
...n,
|
|
@@ -356,11 +356,11 @@ var nt = {}, rt = (e) => {
|
|
|
356
356
|
}
|
|
357
357
|
});
|
|
358
358
|
});
|
|
359
|
-
|
|
360
|
-
function
|
|
361
|
-
return
|
|
359
|
+
ct && (ct.muiSupportAuto = !0);
|
|
360
|
+
function lt(e) {
|
|
361
|
+
return Pe("PrivateSwitchBase", e);
|
|
362
362
|
}
|
|
363
|
-
|
|
363
|
+
Te("PrivateSwitchBase", [
|
|
364
364
|
"root",
|
|
365
365
|
"checked",
|
|
366
366
|
"disabled",
|
|
@@ -368,18 +368,18 @@ we("PrivateSwitchBase", [
|
|
|
368
368
|
"edgeStart",
|
|
369
369
|
"edgeEnd"
|
|
370
370
|
]);
|
|
371
|
-
var
|
|
371
|
+
var ut = (e) => {
|
|
372
372
|
let { classes: t, checked: n, disabled: r, edge: i } = e;
|
|
373
|
-
return
|
|
373
|
+
return je({
|
|
374
374
|
root: [
|
|
375
375
|
"root",
|
|
376
376
|
n && "checked",
|
|
377
377
|
r && "disabled",
|
|
378
|
-
i && `edge${
|
|
378
|
+
i && `edge${De(i)}`
|
|
379
379
|
],
|
|
380
380
|
input: ["input"]
|
|
381
|
-
},
|
|
382
|
-
},
|
|
381
|
+
}, lt, t);
|
|
382
|
+
}, dt = V(He, { name: "MuiSwitchBase" })({
|
|
383
383
|
padding: 9,
|
|
384
384
|
borderRadius: "50%",
|
|
385
385
|
variants: [
|
|
@@ -406,9 +406,9 @@ var lt = (e) => {
|
|
|
406
406
|
style: { marginRight: -12 }
|
|
407
407
|
}
|
|
408
408
|
]
|
|
409
|
-
}),
|
|
409
|
+
}), ft = V("input", {
|
|
410
410
|
name: "MuiSwitchBase",
|
|
411
|
-
shouldForwardProp:
|
|
411
|
+
shouldForwardProp: H
|
|
412
412
|
})({
|
|
413
413
|
cursor: "inherit",
|
|
414
414
|
position: "absolute",
|
|
@@ -420,13 +420,13 @@ var lt = (e) => {
|
|
|
420
420
|
margin: 0,
|
|
421
421
|
padding: 0,
|
|
422
422
|
zIndex: 1
|
|
423
|
-
}),
|
|
424
|
-
let { autoFocus: n, checked: r, checkedIcon: i, defaultChecked: a, disabled: o, disableFocusRipple: s = !1, edge: c = !1, icon: l, id: u, name: d, onBlur: f, onChange: p, onFocus: m, readOnly: h, required: g = !1, tabIndex: _, type: v, value: y, slots: b = {}, slotProps: x = {}, ...S } = e, { nativeButton: C, ...w } = S, [T, E] =
|
|
423
|
+
}), pt = /*#__PURE__*/ K.forwardRef(function(e, t) {
|
|
424
|
+
let { autoFocus: n, checked: r, checkedIcon: i, defaultChecked: a, disabled: o, disableFocusRipple: s = !1, edge: c = !1, icon: l, id: u, name: d, onBlur: f, onChange: p, onFocus: m, readOnly: h, required: g = !1, tabIndex: _, type: v, value: y, slots: b = {}, slotProps: x = {}, ...S } = e, { nativeButton: C, ...w } = S, [T, E] = Re({
|
|
425
425
|
controlled: r,
|
|
426
426
|
default: !!a,
|
|
427
427
|
name: "SwitchBase",
|
|
428
428
|
state: "checked"
|
|
429
|
-
}), D =
|
|
429
|
+
}), D = ue(), O = (e) => {
|
|
430
430
|
m && m(e), D && D.onFocus && D.onFocus(e);
|
|
431
431
|
}, k = (e) => {
|
|
432
432
|
f && f(e), D && D.onBlur && D.onBlur(e);
|
|
@@ -442,12 +442,12 @@ var lt = (e) => {
|
|
|
442
442
|
disabled: j,
|
|
443
443
|
disableFocusRipple: s,
|
|
444
444
|
edge: c
|
|
445
|
-
}, P =
|
|
445
|
+
}, P = ut(N), F = {
|
|
446
446
|
slots: b,
|
|
447
447
|
slotProps: x
|
|
448
|
-
}, [I, L] =
|
|
448
|
+
}, [I, L] = Ie("root", {
|
|
449
449
|
ref: t,
|
|
450
|
-
elementType:
|
|
450
|
+
elementType: dt,
|
|
451
451
|
className: P.root,
|
|
452
452
|
shouldForwardComponentProp: !0,
|
|
453
453
|
externalForwardedProps: {
|
|
@@ -472,8 +472,8 @@ var lt = (e) => {
|
|
|
472
472
|
tabIndex: null,
|
|
473
473
|
internalDisabledThemeFocusVisible: !0
|
|
474
474
|
}
|
|
475
|
-
}), [R, ee] =
|
|
476
|
-
elementType:
|
|
475
|
+
}), [R, ee] = Ie("input", {
|
|
476
|
+
elementType: ft,
|
|
477
477
|
className: P.input,
|
|
478
478
|
externalForwardedProps: F,
|
|
479
479
|
getSlotProps: (e) => ({
|
|
@@ -501,19 +501,19 @@ var lt = (e) => {
|
|
|
501
501
|
...L,
|
|
502
502
|
children: [/*#__PURE__*/ (0, q.jsx)(R, { ...ee }), T ? i : l]
|
|
503
503
|
});
|
|
504
|
-
}),
|
|
505
|
-
let { classes: t, indeterminate: n, color: r, size: i } = e, a =
|
|
504
|
+
}), mt = tt(/*#__PURE__*/ (0, q.jsx)("path", { d: "M19 5v14H5V5h14m0-2H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2z" }), "CheckBoxOutlineBlank"), ht = tt(/*#__PURE__*/ (0, q.jsx)("path", { d: "M19 3H5c-1.11 0-2 .9-2 2v14c0 1.1.89 2 2 2h14c1.11 0 2-.9 2-2V5c0-1.1-.89-2-2-2zm-9 14l-5-5 1.41-1.41L10 14.17l7.59-7.59L19 8l-9 9z" }), "CheckBox"), gt = tt(/*#__PURE__*/ (0, q.jsx)("path", { d: "M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-2 10H7v-2h10v2z" }), "IndeterminateCheckBox"), _t = (e) => {
|
|
505
|
+
let { classes: t, indeterminate: n, color: r, size: i } = e, a = je({ root: [
|
|
506
506
|
"root",
|
|
507
507
|
n && "indeterminate",
|
|
508
|
-
`color${
|
|
509
|
-
`size${
|
|
510
|
-
] },
|
|
508
|
+
`color${De(r)}`,
|
|
509
|
+
`size${De(i)}`
|
|
510
|
+
] }, Je, t);
|
|
511
511
|
return {
|
|
512
512
|
...t,
|
|
513
513
|
...a
|
|
514
514
|
};
|
|
515
|
-
},
|
|
516
|
-
shouldForwardProp: (e) =>
|
|
515
|
+
}, vt = V(pt, {
|
|
516
|
+
shouldForwardProp: (e) => H(e) || e === "classes",
|
|
517
517
|
name: "MuiCheckbox",
|
|
518
518
|
slot: "Root",
|
|
519
519
|
overridesResolver: (e, t) => {
|
|
@@ -521,14 +521,14 @@ var lt = (e) => {
|
|
|
521
521
|
return [
|
|
522
522
|
t.root,
|
|
523
523
|
n.indeterminate && t.indeterminate,
|
|
524
|
-
t[`size${
|
|
525
|
-
n.color !== "default" && t[`color${
|
|
524
|
+
t[`size${De(n.size)}`],
|
|
525
|
+
n.color !== "default" && t[`color${De(n.color)}`]
|
|
526
526
|
];
|
|
527
527
|
}
|
|
528
|
-
})(
|
|
528
|
+
})(Ne(({ theme: e }) => ({
|
|
529
529
|
color: (e.vars || e).palette.text.secondary,
|
|
530
|
-
...e.focusVisible && { [`&.${
|
|
531
|
-
...
|
|
530
|
+
...e.focusVisible && { [`&.${Ue.focusVisible} svg:first-of-type`]: {
|
|
531
|
+
...w,
|
|
532
532
|
borderRadius: (e.vars || e).shape.borderRadius,
|
|
533
533
|
...e.focusVisible
|
|
534
534
|
} },
|
|
@@ -540,18 +540,18 @@ var lt = (e) => {
|
|
|
540
540
|
},
|
|
541
541
|
style: { "&:hover": { backgroundColor: e.alpha((e.vars || e).palette.action.active, (e.vars || e).palette.action.hoverOpacity) } }
|
|
542
542
|
},
|
|
543
|
-
...Object.entries(e.palette).filter(
|
|
543
|
+
...Object.entries(e.palette).filter(Ke()).map(([t]) => ({
|
|
544
544
|
props: {
|
|
545
545
|
color: t,
|
|
546
546
|
disableRipple: !1
|
|
547
547
|
},
|
|
548
548
|
style: { "&:hover": { backgroundColor: e.alpha((e.vars || e).palette[t].main, (e.vars || e).palette.action.hoverOpacity) } }
|
|
549
549
|
})),
|
|
550
|
-
...Object.entries(e.palette).filter(
|
|
550
|
+
...Object.entries(e.palette).filter(Ke()).map(([t]) => ({
|
|
551
551
|
props: { color: t },
|
|
552
552
|
style: {
|
|
553
|
-
[`&.${
|
|
554
|
-
[`&.${
|
|
553
|
+
[`&.${Ye.checked}, &.${Ye.indeterminate}`]: { color: (e.vars || e).palette[t].main },
|
|
554
|
+
[`&.${Ye.disabled}`]: { color: (e.vars || e).palette.action.disabled }
|
|
555
555
|
}
|
|
556
556
|
})),
|
|
557
557
|
{
|
|
@@ -559,24 +559,24 @@ var lt = (e) => {
|
|
|
559
559
|
style: { "&:hover": { "@media (hover: none)": { backgroundColor: "transparent" } } }
|
|
560
560
|
}
|
|
561
561
|
]
|
|
562
|
-
}))),
|
|
563
|
-
let n =
|
|
562
|
+
}))), yt = /*#__PURE__*/ (0, q.jsx)(ht, {}), bt = /*#__PURE__*/ (0, q.jsx)(mt, {}), xt = /*#__PURE__*/ (0, q.jsx)(gt, {}), St = /*#__PURE__*/ K.forwardRef(function(e, t) {
|
|
563
|
+
let n = Ae({
|
|
564
564
|
props: e,
|
|
565
565
|
name: "MuiCheckbox"
|
|
566
|
-
}), { checkedIcon: r =
|
|
566
|
+
}), { checkedIcon: r = yt, color: i = "primary", icon: a = bt, indeterminate: o = !1, indeterminateIcon: s = xt, size: c = "medium", disableRipple: l = !1, className: u, slots: d = {}, slotProps: f = {}, ...p } = n, m = o ? s : a, h = o ? s : r, g = {
|
|
567
567
|
...n,
|
|
568
568
|
disableRipple: l,
|
|
569
569
|
color: i,
|
|
570
570
|
indeterminate: o,
|
|
571
571
|
size: c
|
|
572
|
-
}, _ =
|
|
573
|
-
|
|
572
|
+
}, _ = _t(g), v = typeof f.input == "function" ? f.input(g) : f.input, y = K.useRef(null), b = Ve(y, v?.ref);
|
|
573
|
+
ne(() => {
|
|
574
574
|
y.current && (y.current.indeterminate = o);
|
|
575
575
|
});
|
|
576
|
-
let [x, S] =
|
|
576
|
+
let [x, S] = Ie("root", {
|
|
577
577
|
ref: t,
|
|
578
|
-
elementType:
|
|
579
|
-
className:
|
|
578
|
+
elementType: vt,
|
|
579
|
+
className: M(_.root, u),
|
|
580
580
|
shouldForwardComponentProp: !0,
|
|
581
581
|
externalForwardedProps: {
|
|
582
582
|
slots: d,
|
|
@@ -591,7 +591,7 @@ var lt = (e) => {
|
|
|
591
591
|
disableRipple: n.disableRipple,
|
|
592
592
|
slots: d,
|
|
593
593
|
slotProps: { input: {
|
|
594
|
-
...
|
|
594
|
+
...re(v, {
|
|
595
595
|
"data-indeterminate": o,
|
|
596
596
|
onChange: (e) => {
|
|
597
597
|
e.target.indeterminate = o;
|
|
@@ -605,13 +605,13 @@ var lt = (e) => {
|
|
|
605
605
|
...S,
|
|
606
606
|
classes: _
|
|
607
607
|
});
|
|
608
|
-
}),
|
|
608
|
+
}), Ct = (e) => ({
|
|
609
609
|
hasImage: !!e.dimensions[1]?.dataItem,
|
|
610
610
|
hasMeasure: !!e.measures[0]?.dataItem,
|
|
611
611
|
searchEnabled: !!e.filterSettings?.searchable,
|
|
612
612
|
quickSelection: !!e.filterSettings?.quickSelect
|
|
613
|
-
}), J =
|
|
614
|
-
...e &&
|
|
613
|
+
}), J = te(), wt = /* @__PURE__ */ e(S()), Tt = C({ menuTrigger: ({ responsive: e, isDisplayImportant: t }) => ({
|
|
614
|
+
...e && Ge,
|
|
615
615
|
display: t ? "inline-flex !important" : "inline-flex",
|
|
616
616
|
alignItems: "center",
|
|
617
617
|
justifyContent: "center",
|
|
@@ -647,11 +647,11 @@ var lt = (e) => {
|
|
|
647
647
|
}
|
|
648
648
|
}
|
|
649
649
|
}) });
|
|
650
|
-
function
|
|
651
|
-
let { isPreview: t, areSelectedValues: n, arePendingValues: r, isNotEnabled: i, responsive: a, onClear: o, onDeselectAll: s, onSelectAll: c, onSelectExcluded: l, toggleNotOperator: u, onLockClick: d, isSingleSelectField: f = !1 } = e, [p, m] = (0, K.useState)(!1), h =
|
|
650
|
+
function Et(e) {
|
|
651
|
+
let { isPreview: t, areSelectedValues: n, arePendingValues: r, isNotEnabled: i, responsive: a, onClear: o, onDeselectAll: s, onSelectAll: c, onSelectExcluded: l, toggleNotOperator: u, onLockClick: d, isSingleSelectField: f = !1 } = e, [p, m] = (0, K.useState)(!1), h = Tt({
|
|
652
652
|
responsive: a,
|
|
653
653
|
isDisplayImportant: !0
|
|
654
|
-
}), _ =
|
|
654
|
+
}), _ = D().daedalus.getWorkbookProperties()?.isLockUnlockFieldsEnabled ?? !1, v = [{
|
|
655
655
|
disabled: t || !r,
|
|
656
656
|
key: "clear",
|
|
657
657
|
label: "Clear",
|
|
@@ -694,12 +694,12 @@ function Tt(e) {
|
|
|
694
694
|
type: "option",
|
|
695
695
|
icon: { right: /* @__PURE__ */ (0, q.jsx)(y, {}) },
|
|
696
696
|
onClick: d
|
|
697
|
-
}), /* @__PURE__ */ (0, q.jsx)(
|
|
697
|
+
}), /* @__PURE__ */ (0, q.jsx)(ze, {
|
|
698
698
|
open: p,
|
|
699
699
|
placement: "bottom-end",
|
|
700
700
|
title: /* @__PURE__ */ (0, q.jsx)(z, {
|
|
701
701
|
onClickAway: () => m(!1),
|
|
702
|
-
children: /* @__PURE__ */ (0, q.jsx)(
|
|
702
|
+
children: /* @__PURE__ */ (0, q.jsx)(ie, {
|
|
703
703
|
appearance: "legacy",
|
|
704
704
|
onClose: () => m(!1),
|
|
705
705
|
options: v,
|
|
@@ -711,7 +711,7 @@ function Tt(e) {
|
|
|
711
711
|
onClick: () => m(!p),
|
|
712
712
|
"data-testid": "filter-button-icon-dots",
|
|
713
713
|
className: h.menuTrigger,
|
|
714
|
-
children: /* @__PURE__ */ (0, q.jsx)(
|
|
714
|
+
children: /* @__PURE__ */ (0, q.jsx)(g, {
|
|
715
715
|
fill: "currentColor",
|
|
716
716
|
size: 20
|
|
717
717
|
})
|
|
@@ -727,31 +727,31 @@ function Y() {
|
|
|
727
727
|
return e;
|
|
728
728
|
}, Y.apply(null, arguments);
|
|
729
729
|
}
|
|
730
|
-
var
|
|
731
|
-
function
|
|
732
|
-
let n = K.useRef(
|
|
733
|
-
return n.current ===
|
|
730
|
+
var Dt = {};
|
|
731
|
+
function Ot(e, t) {
|
|
732
|
+
let n = K.useRef(Dt);
|
|
733
|
+
return n.current === Dt && (n.current = e(t)), n;
|
|
734
734
|
}
|
|
735
|
-
function
|
|
736
|
-
let i =
|
|
737
|
-
return
|
|
735
|
+
function kt(e, t, n, r) {
|
|
736
|
+
let i = Ot(At).current;
|
|
737
|
+
return jt(i, e, t, n, r) && Mt(i, [
|
|
738
738
|
e,
|
|
739
739
|
t,
|
|
740
740
|
n,
|
|
741
741
|
r
|
|
742
742
|
]), i.callback;
|
|
743
743
|
}
|
|
744
|
-
function
|
|
744
|
+
function At() {
|
|
745
745
|
return {
|
|
746
746
|
callback: null,
|
|
747
747
|
cleanup: null,
|
|
748
748
|
refs: []
|
|
749
749
|
};
|
|
750
750
|
}
|
|
751
|
-
function
|
|
751
|
+
function jt(e, t, n, r, i) {
|
|
752
752
|
return e.refs[0] !== t || e.refs[1] !== n || e.refs[2] !== r || e.refs[3] !== i;
|
|
753
753
|
}
|
|
754
|
-
function
|
|
754
|
+
function Mt(e, t) {
|
|
755
755
|
if (e.refs = t, t.every((e) => e == null)) {
|
|
756
756
|
e.callback = null;
|
|
757
757
|
return;
|
|
@@ -792,13 +792,13 @@ function jt(e, t) {
|
|
|
792
792
|
}
|
|
793
793
|
};
|
|
794
794
|
}
|
|
795
|
-
function Mt(e) {
|
|
796
|
-
return Ye;
|
|
797
|
-
}
|
|
798
795
|
function Nt(e) {
|
|
799
|
-
return
|
|
796
|
+
return Xe;
|
|
797
|
+
}
|
|
798
|
+
function Pt(e) {
|
|
799
|
+
return Pe("MuiSimpleTreeView", e);
|
|
800
800
|
}
|
|
801
|
-
|
|
801
|
+
Te("MuiSimpleTreeView", [
|
|
802
802
|
"root",
|
|
803
803
|
"item",
|
|
804
804
|
"itemContent",
|
|
@@ -807,24 +807,24 @@ we("MuiSimpleTreeView", [
|
|
|
807
807
|
"itemLabel",
|
|
808
808
|
"itemCheckbox"
|
|
809
809
|
]);
|
|
810
|
-
var
|
|
811
|
-
function
|
|
810
|
+
var Ft = Object.freeze([]), It = Object.freeze({});
|
|
811
|
+
function Lt(e, t) {
|
|
812
812
|
return function(n, ...r) {
|
|
813
813
|
let i = new URL(e);
|
|
814
814
|
return i.searchParams.set("code", n.toString()), r.forEach((e) => i.searchParams.append("args[]", e)), `${t} error #${n}; visit ${i} for the full message.`;
|
|
815
815
|
};
|
|
816
816
|
}
|
|
817
|
-
var
|
|
818
|
-
let e = K.useContext(
|
|
819
|
-
if (e == null) throw Error(
|
|
817
|
+
var Rt = Lt("https://base-ui.com/production-error", "Base UI"), zt = Lt("https://mui.com/x/production-error", "MUI X"), Bt = /*#__PURE__*/ K.createContext(null), Vt = () => {
|
|
818
|
+
let e = K.useContext(Bt);
|
|
819
|
+
if (e == null) throw Error(zt(190));
|
|
820
820
|
return e;
|
|
821
|
-
},
|
|
821
|
+
}, Ht = /*#__PURE__*/ K.createContext({
|
|
822
822
|
classes: {},
|
|
823
823
|
slots: {},
|
|
824
824
|
slotProps: {}
|
|
825
|
-
}),
|
|
826
|
-
let { store: t, apiRef: n, rootRef: r } = e, i =
|
|
827
|
-
|
|
825
|
+
}), Ut = () => K.useContext(Ht), Wt = (e) => {
|
|
826
|
+
let { store: t, apiRef: n, rootRef: r } = e, i = Ot(() => t.buildPublicAPI()).current;
|
|
827
|
+
Gt(i, n);
|
|
828
828
|
let a = K.useCallback((e) => {
|
|
829
829
|
let n = null, r = null, i = [], a = {};
|
|
830
830
|
t.itemPluginManager.listPlugins().forEach((t) => {
|
|
@@ -876,11 +876,11 @@ var Lt = It("https://base-ui.com/production-error", "Base UI"), Rt = It("https:/
|
|
|
876
876
|
r
|
|
877
877
|
]);
|
|
878
878
|
};
|
|
879
|
-
function
|
|
879
|
+
function Gt(e, t) {
|
|
880
880
|
t != null && t.current !== e && (t.current = e);
|
|
881
881
|
}
|
|
882
|
-
function
|
|
883
|
-
let { store: t, apiRef: n, rootRef: r, classes: i =
|
|
882
|
+
function Kt(e) {
|
|
883
|
+
let { store: t, apiRef: n, rootRef: r, classes: i = It, slots: a = It, slotProps: o = It, children: s } = e, c = Wt({
|
|
884
884
|
store: t,
|
|
885
885
|
apiRef: n,
|
|
886
886
|
rootRef: r
|
|
@@ -913,15 +913,15 @@ function Gt(e) {
|
|
|
913
913
|
o.loading,
|
|
914
914
|
o.itemLoader
|
|
915
915
|
]);
|
|
916
|
-
return /*#__PURE__*/ (0, q.jsx)(
|
|
916
|
+
return /*#__PURE__*/ (0, q.jsx)(Bt.Provider, {
|
|
917
917
|
value: c,
|
|
918
|
-
children: /*#__PURE__*/ (0, q.jsx)(
|
|
918
|
+
children: /*#__PURE__*/ (0, q.jsx)(Ht.Provider, {
|
|
919
919
|
value: l,
|
|
920
920
|
children: s
|
|
921
921
|
})
|
|
922
922
|
});
|
|
923
923
|
}
|
|
924
|
-
function
|
|
924
|
+
function qt(e, t) {
|
|
925
925
|
if (e == null) return {};
|
|
926
926
|
var n = {};
|
|
927
927
|
for (var r in e) if ({}.hasOwnProperty.call(e, r)) {
|
|
@@ -930,7 +930,7 @@ function Kt(e, t) {
|
|
|
930
930
|
}
|
|
931
931
|
return n;
|
|
932
932
|
}
|
|
933
|
-
var
|
|
933
|
+
var Jt = [
|
|
934
934
|
"apiRef",
|
|
935
935
|
"slots",
|
|
936
936
|
"slotProps",
|
|
@@ -954,8 +954,8 @@ var qt = [
|
|
|
954
954
|
"onItemFocus",
|
|
955
955
|
"itemHeight"
|
|
956
956
|
];
|
|
957
|
-
function
|
|
958
|
-
let { apiRef: t, slots: n, slotProps: r, disabledItemsFocusable: i, onItemClick: a, itemChildrenIndentation: o, id: s, expandedItems: c, defaultExpandedItems: l, onExpandedItemsChange: u, onItemExpansionToggle: d, expansionTrigger: f, disableSelection: p, selectedItems: m, defaultSelectedItems: h, multiSelect: g, checkboxSelection: _, selectionPropagation: v, onSelectedItemsChange: y, onItemSelectionToggle: b, onItemFocus: x, itemHeight: S } = e, C =
|
|
957
|
+
function Yt(e) {
|
|
958
|
+
let { apiRef: t, slots: n, slotProps: r, disabledItemsFocusable: i, onItemClick: a, itemChildrenIndentation: o, id: s, expandedItems: c, defaultExpandedItems: l, onExpandedItemsChange: u, onItemExpansionToggle: d, expansionTrigger: f, disableSelection: p, selectedItems: m, defaultSelectedItems: h, multiSelect: g, checkboxSelection: _, selectionPropagation: v, onSelectedItemsChange: y, onItemSelectionToggle: b, onItemFocus: x, itemHeight: S } = e, C = qt(e, Jt);
|
|
959
959
|
return {
|
|
960
960
|
apiRef: t,
|
|
961
961
|
slots: n,
|
|
@@ -1004,18 +1004,18 @@ function Jt(e) {
|
|
|
1004
1004
|
forwardedProps: C
|
|
1005
1005
|
};
|
|
1006
1006
|
}
|
|
1007
|
-
var
|
|
1007
|
+
var Xt = {
|
|
1008
1008
|
maxSize: 1,
|
|
1009
1009
|
equalityCheck: Object.is
|
|
1010
|
-
},
|
|
1011
|
-
memoize:
|
|
1012
|
-
memoizeOptions:
|
|
1013
|
-
}),
|
|
1010
|
+
}, Zt = Ce({
|
|
1011
|
+
memoize: we,
|
|
1012
|
+
memoizeOptions: Xt
|
|
1013
|
+
}), Qt = ((e) => {
|
|
1014
1014
|
let t = e?.memoizeOptions, n = e;
|
|
1015
1015
|
return e !== void 0 && (e.memoize === void 0 ? typeof t == "object" && t && !Array.isArray(t) && (n = {
|
|
1016
1016
|
...e,
|
|
1017
1017
|
memoizeOptions: {
|
|
1018
|
-
...
|
|
1018
|
+
...Xt,
|
|
1019
1019
|
...t
|
|
1020
1020
|
}
|
|
1021
1021
|
}) : t === void 0 && (n = {
|
|
@@ -1023,7 +1023,7 @@ var Yt = {
|
|
|
1023
1023
|
memoizeOptions: void 0
|
|
1024
1024
|
})), (...e) => {
|
|
1025
1025
|
let t = /* @__PURE__ */ new WeakMap(), r = 1, i = e[e.length - 1], a = e.length === 1 ? [(e) => e, i] : e, o = a.length - 1, s = i.length === 0 ? 0 : i.length - o;
|
|
1026
|
-
if (s < 0 || s > 3) throw Error(
|
|
1026
|
+
if (s < 0 || s > 3) throw Error(Rt(2));
|
|
1027
1027
|
return (e, o, c, l) => {
|
|
1028
1028
|
let u = e.__cacheKey__;
|
|
1029
1029
|
u || (u = { id: r }, e.__cacheKey__ = u, r += 1);
|
|
@@ -1061,7 +1061,7 @@ var Yt = {
|
|
|
1061
1061
|
];
|
|
1062
1062
|
break;
|
|
1063
1063
|
}
|
|
1064
|
-
n && (e = [...e, n]), d =
|
|
1064
|
+
n && (e = [...e, n]), d = Zt(...e), d.selectorArgs = r, t.set(u, d);
|
|
1065
1065
|
}
|
|
1066
1066
|
switch (s) {
|
|
1067
1067
|
case 3: d.selectorArgs[2] = l;
|
|
@@ -1077,22 +1077,22 @@ var Yt = {
|
|
|
1077
1077
|
}
|
|
1078
1078
|
};
|
|
1079
1079
|
};
|
|
1080
|
-
})(),
|
|
1081
|
-
function
|
|
1082
|
-
return
|
|
1080
|
+
})(), $t = 19;
|
|
1081
|
+
function en(e) {
|
|
1082
|
+
return $t >= e;
|
|
1083
1083
|
}
|
|
1084
|
-
var
|
|
1085
|
-
function
|
|
1086
|
-
return
|
|
1084
|
+
var tn = [], nn = void 0;
|
|
1085
|
+
function rn() {
|
|
1086
|
+
return nn;
|
|
1087
1087
|
}
|
|
1088
|
-
function
|
|
1089
|
-
|
|
1088
|
+
function an(e) {
|
|
1089
|
+
tn.push(e);
|
|
1090
1090
|
}
|
|
1091
|
-
var
|
|
1091
|
+
var on = m(), sn = /* @__PURE__ */ e(P(), 1), cn = en(19) ? un : dn;
|
|
1092
1092
|
function X(e, t, n, r, i) {
|
|
1093
|
-
return
|
|
1093
|
+
return cn(e, t, n, r, i);
|
|
1094
1094
|
}
|
|
1095
|
-
function
|
|
1095
|
+
function ln(e, t, n, r, i) {
|
|
1096
1096
|
let a = K.useCallback(() => t(e.getSnapshot(), n, r, i), [
|
|
1097
1097
|
e,
|
|
1098
1098
|
t,
|
|
@@ -1100,9 +1100,9 @@ function cn(e, t, n, r, i) {
|
|
|
1100
1100
|
r,
|
|
1101
1101
|
i
|
|
1102
1102
|
]);
|
|
1103
|
-
return (0,
|
|
1103
|
+
return (0, on.useSyncExternalStore)(e.subscribe, a, a);
|
|
1104
1104
|
}
|
|
1105
|
-
|
|
1105
|
+
an({
|
|
1106
1106
|
before(e) {
|
|
1107
1107
|
e.syncIndex = 0, e.didInitialize || (e.syncTick = 1, e.syncHooks = [], e.didChangeStore = !0, e.getSnapshot = () => {
|
|
1108
1108
|
let t = !1;
|
|
@@ -1122,12 +1122,12 @@ rn({
|
|
|
1122
1122
|
return () => {
|
|
1123
1123
|
for (let e of r) e();
|
|
1124
1124
|
};
|
|
1125
|
-
}), (0,
|
|
1125
|
+
}), (0, on.useSyncExternalStore)(e.subscribe, e.getSnapshot, e.getSnapshot));
|
|
1126
1126
|
}
|
|
1127
1127
|
});
|
|
1128
|
-
function
|
|
1129
|
-
let a =
|
|
1130
|
-
if (!a) return
|
|
1128
|
+
function un(e, t, n, r, i) {
|
|
1129
|
+
let a = rn();
|
|
1130
|
+
if (!a) return ln(e, t, n, r, i);
|
|
1131
1131
|
let o = a.syncIndex;
|
|
1132
1132
|
a.syncIndex += 1;
|
|
1133
1133
|
let s;
|
|
@@ -1140,10 +1140,10 @@ function ln(e, t, n, r, i) {
|
|
|
1140
1140
|
value: t(e.getSnapshot(), n, r, i)
|
|
1141
1141
|
}, a.syncHooks.push(s)), s.value;
|
|
1142
1142
|
}
|
|
1143
|
-
function
|
|
1144
|
-
return (0,
|
|
1143
|
+
function dn(e, t, n, r, i) {
|
|
1144
|
+
return (0, sn.useSyncExternalStoreWithSelector)(e.subscribe, e.getSnapshot, e.getSnapshot, (e) => t(e, n, r, i));
|
|
1145
1145
|
}
|
|
1146
|
-
var
|
|
1146
|
+
var fn = class {
|
|
1147
1147
|
static create(e) {
|
|
1148
1148
|
return new this(e);
|
|
1149
1149
|
}
|
|
@@ -1185,19 +1185,19 @@ var dn = class {
|
|
|
1185
1185
|
use(e, t, n, r) {
|
|
1186
1186
|
return X(this, e, t, n, r);
|
|
1187
1187
|
}
|
|
1188
|
-
},
|
|
1189
|
-
function
|
|
1190
|
-
K.useEffect(e,
|
|
1188
|
+
}, pn = { ...K }, mn = typeof document < "u" ? K.useLayoutEffect : () => {};
|
|
1189
|
+
function hn(e) {
|
|
1190
|
+
K.useEffect(e, Ft);
|
|
1191
1191
|
}
|
|
1192
|
-
var
|
|
1193
|
-
treeId:
|
|
1194
|
-
treeItemIdAttribute: (e, t, n) => n ?? `${
|
|
1195
|
-
},
|
|
1192
|
+
var gn = (e) => e.providedTreeId ?? e.treeId, _n = {
|
|
1193
|
+
treeId: gn,
|
|
1194
|
+
treeItemIdAttribute: (e, t, n) => n ?? `${gn(e) ?? ""}-${t}`
|
|
1195
|
+
}, vn = (e) => {
|
|
1196
1196
|
let t = {};
|
|
1197
1197
|
return e.forEach((e, n) => {
|
|
1198
1198
|
t[e] = n;
|
|
1199
1199
|
}), t;
|
|
1200
|
-
},
|
|
1200
|
+
}, yn = (e, t) => {
|
|
1201
1201
|
if (t == null) return !1;
|
|
1202
1202
|
let n = e[t];
|
|
1203
1203
|
if (!n) return !1;
|
|
@@ -1208,10 +1208,10 @@ var hn = (e) => e.providedTreeId ?? e.treeId, gn = {
|
|
|
1208
1208
|
}
|
|
1209
1209
|
return !1;
|
|
1210
1210
|
};
|
|
1211
|
-
function
|
|
1211
|
+
function bn(e) {
|
|
1212
1212
|
let { storeParameters: t, items: n, parentId: r, depth: i, isItemExpandable: a, otherItemsMetaLookup: o } = e, s = {}, c = {}, l = [], u = [], d = (e) => {
|
|
1213
1213
|
let n = t.getItemId ? t.getItemId(e) : e.id;
|
|
1214
|
-
|
|
1214
|
+
Sn({
|
|
1215
1215
|
id: n,
|
|
1216
1216
|
parentId: r,
|
|
1217
1217
|
item: e,
|
|
@@ -1219,7 +1219,7 @@ function yn(e) {
|
|
|
1219
1219
|
siblingsMetaLookup: s
|
|
1220
1220
|
});
|
|
1221
1221
|
let d = t.getItemLabel ? t.getItemLabel(e) : e.label;
|
|
1222
|
-
if (d == null) throw Error(
|
|
1222
|
+
if (d == null) throw Error(zt(192, JSON.stringify(e)));
|
|
1223
1223
|
let f = (t.getItemChildren ? t.getItemChildren(e) : e.children) || [];
|
|
1224
1224
|
u.push({
|
|
1225
1225
|
id: n,
|
|
@@ -1240,13 +1240,13 @@ function yn(e) {
|
|
|
1240
1240
|
metaLookup: s,
|
|
1241
1241
|
modelLookup: c,
|
|
1242
1242
|
orderedChildrenIds: l,
|
|
1243
|
-
childrenIndexes:
|
|
1243
|
+
childrenIndexes: vn(l),
|
|
1244
1244
|
itemsChildren: u
|
|
1245
1245
|
};
|
|
1246
1246
|
}
|
|
1247
|
-
function
|
|
1247
|
+
function xn(e) {
|
|
1248
1248
|
let { storeParameters: t, items: n, parentId: r, depth: i, isItemExpandable: a, existingItemMetaLookup: o } = e, s = {}, c = {}, l = {}, u = {}, d = Y({}, o), f = (e, n, r) => {
|
|
1249
|
-
let i =
|
|
1249
|
+
let i = bn({
|
|
1250
1250
|
storeParameters: t,
|
|
1251
1251
|
items: e,
|
|
1252
1252
|
parentId: n,
|
|
@@ -1264,29 +1264,29 @@ function bn(e) {
|
|
|
1264
1264
|
itemChildrenIndexesLookup: u
|
|
1265
1265
|
};
|
|
1266
1266
|
}
|
|
1267
|
-
function
|
|
1268
|
-
if (e == null) throw Error(
|
|
1269
|
-
if (i[e] != null || r[e] != null && r[e].parentId !== t) throw Error(
|
|
1267
|
+
function Sn({ id: e, parentId: t, item: n, itemMetaLookup: r, siblingsMetaLookup: i }) {
|
|
1268
|
+
if (e == null) throw Error(zt(193, JSON.stringify(n)));
|
|
1269
|
+
if (i[e] != null || r[e] != null && r[e].parentId !== t) throw Error(zt(194, e));
|
|
1270
1270
|
}
|
|
1271
|
-
var
|
|
1271
|
+
var Cn = [], Z = {
|
|
1272
1272
|
domStructure: (e) => e.domStructure,
|
|
1273
1273
|
disabledItemFocusable: (e) => e.disabledItemsFocusable,
|
|
1274
1274
|
itemMetaLookup: (e) => e.itemMetaLookup,
|
|
1275
1275
|
itemOrderedChildrenIdsLookup: (e) => e.itemOrderedChildrenIdsLookup,
|
|
1276
1276
|
itemMeta: (e, t) => e.itemMetaLookup[t ?? "__TREE_VIEW_ROOT_PARENT_ID__"] ?? null,
|
|
1277
|
-
itemOrderedChildrenIds: (e, t) => e.itemOrderedChildrenIdsLookup[t ?? "__TREE_VIEW_ROOT_PARENT_ID__"] ??
|
|
1277
|
+
itemOrderedChildrenIds: (e, t) => e.itemOrderedChildrenIdsLookup[t ?? "__TREE_VIEW_ROOT_PARENT_ID__"] ?? Cn,
|
|
1278
1278
|
itemModel: (e, t) => e.itemModelLookup[t],
|
|
1279
|
-
isItemDisabled: (e, t) =>
|
|
1279
|
+
isItemDisabled: (e, t) => yn(e.itemMetaLookup, t),
|
|
1280
1280
|
itemIndex: (e, t) => {
|
|
1281
1281
|
let n = e.itemMetaLookup[t];
|
|
1282
1282
|
return n == null ? -1 : e.itemChildrenIndexesLookup[n.parentId ?? "__TREE_VIEW_ROOT_PARENT_ID__"][n.id];
|
|
1283
1283
|
},
|
|
1284
1284
|
itemParentId: (e, t) => e.itemMetaLookup[t]?.parentId ?? null,
|
|
1285
1285
|
itemDepth: (e, t) => e.itemMetaLookup[t]?.depth ?? 0,
|
|
1286
|
-
canItemBeFocused: (e, t) => e.disabledItemsFocusable || e.itemModelLookup[t] != null && !
|
|
1286
|
+
canItemBeFocused: (e, t) => e.disabledItemsFocusable || e.itemModelLookup[t] != null && !yn(e.itemMetaLookup, t),
|
|
1287
1287
|
itemChildrenIndentation: (e) => e.itemChildrenIndentation,
|
|
1288
1288
|
itemHeight: (e) => e.itemHeight
|
|
1289
|
-
},
|
|
1289
|
+
}, wn = class {
|
|
1290
1290
|
constructor(e) {
|
|
1291
1291
|
this.store = e;
|
|
1292
1292
|
}
|
|
@@ -1301,7 +1301,7 @@ var Sn = [], Z = {
|
|
|
1301
1301
|
let r = n;
|
|
1302
1302
|
return e[r] !== t[r];
|
|
1303
1303
|
});
|
|
1304
|
-
static buildItemsStateIfNeeded = (e) =>
|
|
1304
|
+
static buildItemsStateIfNeeded = (e) => xn({
|
|
1305
1305
|
storeParameters: e,
|
|
1306
1306
|
items: e.items,
|
|
1307
1307
|
parentId: null,
|
|
@@ -1325,8 +1325,8 @@ var Sn = [], Z = {
|
|
|
1325
1325
|
};
|
|
1326
1326
|
addItems = ({ items: e, parentId: t = null, index: n }) => {
|
|
1327
1327
|
if (e.length === 0) return;
|
|
1328
|
-
if (t != null && Z.itemMeta(this.store.state, t) == null) throw Error(
|
|
1329
|
-
let r = t == null ? -1 : Z.itemDepth(this.store.state, t), i = this.store.parameters.dataSource, { itemMetaLookup: a, itemModelLookup: o, itemOrderedChildrenIdsLookup: s, itemChildrenIndexesLookup: c } =
|
|
1328
|
+
if (t != null && Z.itemMeta(this.store.state, t) == null) throw Error(zt(295, t));
|
|
1329
|
+
let r = t == null ? -1 : Z.itemDepth(this.store.state, t), i = this.store.parameters.dataSource, { itemMetaLookup: a, itemModelLookup: o, itemOrderedChildrenIdsLookup: s, itemChildrenIndexesLookup: c } = xn({
|
|
1330
1330
|
storeParameters: this.store.parameters,
|
|
1331
1331
|
items: e,
|
|
1332
1332
|
parentId: t,
|
|
@@ -1334,11 +1334,11 @@ var Sn = [], Z = {
|
|
|
1334
1334
|
isItemExpandable: (e, t) => t != null && t.length > 0 || i != null && i.getChildrenCount(e) !== 0,
|
|
1335
1335
|
existingItemMetaLookup: this.store.state.itemMetaLookup
|
|
1336
1336
|
});
|
|
1337
|
-
for (let e of Object.keys(a)) if (this.store.state.itemMetaLookup[e] != null) throw Error(
|
|
1337
|
+
for (let e of Object.keys(a)) if (this.store.state.itemMetaLookup[e] != null) throw Error(zt(194, e));
|
|
1338
1338
|
let l = t ?? "__TREE_VIEW_ROOT_PARENT_ID__", u = Z.itemOrderedChildrenIds(this.store.state, t), d = n ?? u.length;
|
|
1339
|
-
if (d < 0 || d > u.length) throw Error(
|
|
1339
|
+
if (d < 0 || d > u.length) throw Error(zt(296, d, u.length));
|
|
1340
1340
|
let f = s[l], p = [...u];
|
|
1341
|
-
p.splice(d, 0, ...f), s[l] = p, c[l] =
|
|
1341
|
+
p.splice(d, 0, ...f), s[l] = p, c[l] = vn(p);
|
|
1342
1342
|
let m = Y({}, this.store.state.itemMetaLookup, a);
|
|
1343
1343
|
t != null && !m[t].expandable && (m[t] = Y({}, m[t], { expandable: !0 })), this.store.update({
|
|
1344
1344
|
itemMetaLookup: m,
|
|
@@ -1358,7 +1358,7 @@ var Sn = [], Z = {
|
|
|
1358
1358
|
getItemDOMElement = (e) => {
|
|
1359
1359
|
let t = Z.itemMeta(this.store.state, e);
|
|
1360
1360
|
if (t == null) return null;
|
|
1361
|
-
let n =
|
|
1361
|
+
let n = _n.treeItemIdAttribute(this.store.state, e, t.idAttribute);
|
|
1362
1362
|
return document.getElementById(n);
|
|
1363
1363
|
};
|
|
1364
1364
|
setItemChildren = ({ items: e, parentId: t, getChildrenCount: n, recursive: r = !1 }) => {
|
|
@@ -1369,9 +1369,9 @@ var Sn = [], Z = {
|
|
|
1369
1369
|
depth: i + 1,
|
|
1370
1370
|
isItemExpandable: n ? (e) => n(e) !== 0 : () => !1
|
|
1371
1371
|
}, s;
|
|
1372
|
-
if (r) s =
|
|
1372
|
+
if (r) s = xn(Y({}, o, { existingItemMetaLookup: a }));
|
|
1373
1373
|
else {
|
|
1374
|
-
let e = t ?? "__TREE_VIEW_ROOT_PARENT_ID__", { metaLookup: n, modelLookup: r, orderedChildrenIds: i, childrenIndexes: c } =
|
|
1374
|
+
let e = t ?? "__TREE_VIEW_ROOT_PARENT_ID__", { metaLookup: n, modelLookup: r, orderedChildrenIds: i, childrenIndexes: c } = bn(Y({}, o, { otherItemsMetaLookup: a }));
|
|
1375
1375
|
s = {
|
|
1376
1376
|
itemMetaLookup: n,
|
|
1377
1377
|
itemModelLookup: r,
|
|
@@ -1409,34 +1409,34 @@ var Sn = [], Z = {
|
|
|
1409
1409
|
handleItemClick = (e, t) => {
|
|
1410
1410
|
this.store.parameters.onItemClick?.(e, t);
|
|
1411
1411
|
};
|
|
1412
|
-
},
|
|
1412
|
+
}, Tn = Qt((e) => e.selectedItems, (e) => Array.isArray(e) ? e : e == null ? [] : [e]), En = Qt(Tn, (e) => {
|
|
1413
1413
|
let t = /* @__PURE__ */ new Map();
|
|
1414
1414
|
return e.forEach((e) => {
|
|
1415
1415
|
t.set(e, !0);
|
|
1416
1416
|
}), t;
|
|
1417
|
-
}),
|
|
1418
|
-
if (
|
|
1417
|
+
}), Dn = (e, t) => e.itemMetaLookup[t]?.selectable ?? !0, On = (e, t) => En(e).has(t), kn = (e, t) => !e.disableSelection && !Z.isItemDisabled(e, t) && Dn(e, t), An = (e) => e.selectionPropagation, jn = (e, t) => {
|
|
1418
|
+
if (On(e, t)) return "selected";
|
|
1419
1419
|
if (Z.itemOrderedChildrenIds(e, t).length === 0) return "unselected";
|
|
1420
1420
|
let n = !1, r = !1, i = (a) => {
|
|
1421
|
-
a !== t &&
|
|
1421
|
+
a !== t && kn(e, a) && (On(e, a) ? n = !0 : r = !0), Z.itemOrderedChildrenIds(e, a).forEach(i);
|
|
1422
1422
|
};
|
|
1423
|
-
return i(t),
|
|
1423
|
+
return i(t), An(e).parents ? n && r ? "indeterminate" : n && !r ? "selected" : "unselected" : n ? "indeterminate" : "unselected";
|
|
1424
1424
|
}, Q = {
|
|
1425
1425
|
selectedItemsRaw: (e) => e.selectedItems,
|
|
1426
|
-
selectedItems:
|
|
1427
|
-
selectedItemsMap:
|
|
1426
|
+
selectedItems: Tn,
|
|
1427
|
+
selectedItemsMap: En,
|
|
1428
1428
|
enabled: (e) => !e.disableSelection,
|
|
1429
1429
|
isMultiSelectEnabled: (e) => e.multiSelect,
|
|
1430
1430
|
isCheckboxSelectionEnabled: (e) => e.checkboxSelection,
|
|
1431
|
-
propagationRules:
|
|
1432
|
-
isItemSelected:
|
|
1433
|
-
itemSelectionStatus:
|
|
1434
|
-
isItemIndeterminate: (e, t) =>
|
|
1435
|
-
isFeatureEnabledForItem: (e, t) => !e.disableSelection &&
|
|
1436
|
-
canItemBeSelected:
|
|
1437
|
-
isItemSelectable:
|
|
1438
|
-
},
|
|
1439
|
-
let { itemId: t } = e, { store: n } =
|
|
1431
|
+
propagationRules: An,
|
|
1432
|
+
isItemSelected: On,
|
|
1433
|
+
itemSelectionStatus: jn,
|
|
1434
|
+
isItemIndeterminate: (e, t) => jn(e, t) === "indeterminate",
|
|
1435
|
+
isFeatureEnabledForItem: (e, t) => !e.disableSelection && Dn(e, t),
|
|
1436
|
+
canItemBeSelected: kn,
|
|
1437
|
+
isItemSelectable: Dn
|
|
1438
|
+
}, Mn = ({ props: e }) => {
|
|
1439
|
+
let { itemId: t } = e, { store: n } = Vt(), r = X(n, Q.isCheckboxSelectionEnabled), i = X(n, Q.isFeatureEnabledForItem, t), a = X(n, Q.canItemBeSelected, t), o = X(n, Z.isItemDisabled, t), s = X(n, Q.isItemSelectable, t), c = X(n, Q.itemSelectionStatus, t), l = X(n, Q.isItemSelected, t), u = o || !s;
|
|
1440
1440
|
return { propsEnhancers: {
|
|
1441
1441
|
root: () => {
|
|
1442
1442
|
let e;
|
|
@@ -1459,15 +1459,15 @@ var Sn = [], Z = {
|
|
|
1459
1459
|
indeterminate: c === "indeterminate"
|
|
1460
1460
|
})
|
|
1461
1461
|
} };
|
|
1462
|
-
},
|
|
1462
|
+
}, Nn = Qt((e) => e.expandedItems, (e) => {
|
|
1463
1463
|
let t = /* @__PURE__ */ new Map();
|
|
1464
1464
|
return e.forEach((e) => {
|
|
1465
1465
|
t.set(e, !0);
|
|
1466
1466
|
}), t;
|
|
1467
1467
|
}), $ = {
|
|
1468
1468
|
expandedItemsRaw: (e) => e.expandedItems,
|
|
1469
|
-
expandedItemsMap:
|
|
1470
|
-
flatList:
|
|
1469
|
+
expandedItemsMap: Nn,
|
|
1470
|
+
flatList: Qt(Z.itemOrderedChildrenIdsLookup, Nn, (e, t) => {
|
|
1471
1471
|
function n(r) {
|
|
1472
1472
|
if (!t.has(r)) return [r];
|
|
1473
1473
|
let i = [r], a = e[r] || [];
|
|
@@ -1477,24 +1477,24 @@ var Sn = [], Z = {
|
|
|
1477
1477
|
return (e.__TREE_VIEW_ROOT_PARENT_ID__ ?? []).flatMap(n);
|
|
1478
1478
|
}),
|
|
1479
1479
|
triggerSlot: (e) => e.expansionTrigger,
|
|
1480
|
-
isItemExpanded: (e, t) =>
|
|
1480
|
+
isItemExpanded: (e, t) => Nn(e).has(t),
|
|
1481
1481
|
isItemExpandable: (e, t) => Z.itemMeta(e, t)?.expandable ?? !1
|
|
1482
|
-
},
|
|
1482
|
+
}, Pn = (e, t) => {
|
|
1483
1483
|
let n = t.length - 1;
|
|
1484
1484
|
for (; n >= 0 && !Z.canItemBeFocused(e, t[n]);) --n;
|
|
1485
1485
|
if (n !== -1) return t[n];
|
|
1486
|
-
},
|
|
1486
|
+
}, Fn = (e, t) => {
|
|
1487
1487
|
let n = Z.itemMeta(e, t);
|
|
1488
1488
|
if (!n) return null;
|
|
1489
1489
|
let r = Z.itemOrderedChildrenIds(e, n.parentId), i = Z.itemIndex(e, t);
|
|
1490
1490
|
if (i === 0) return n.parentId;
|
|
1491
1491
|
let a = i - 1;
|
|
1492
1492
|
for (; !Z.canItemBeFocused(e, r[a]) && a >= 0;) --a;
|
|
1493
|
-
if (a === -1) return n.parentId == null ? null :
|
|
1494
|
-
let o = r[a], s =
|
|
1495
|
-
for (; $.isItemExpanded(e, o) && s != null;) o = s, s =
|
|
1493
|
+
if (a === -1) return n.parentId == null ? null : Fn(e, n.parentId);
|
|
1494
|
+
let o = r[a], s = Pn(e, Z.itemOrderedChildrenIds(e, o));
|
|
1495
|
+
for (; $.isItemExpanded(e, o) && s != null;) o = s, s = Pn(e, Z.itemOrderedChildrenIds(e, o));
|
|
1496
1496
|
return o;
|
|
1497
|
-
},
|
|
1497
|
+
}, In = (e, t) => {
|
|
1498
1498
|
if ($.isItemExpanded(e, t)) {
|
|
1499
1499
|
let n = Z.itemOrderedChildrenIds(e, t).find((t) => Z.canItemBeFocused(e, t));
|
|
1500
1500
|
if (n != null) return n;
|
|
@@ -1510,15 +1510,15 @@ var Sn = [], Z = {
|
|
|
1510
1510
|
n = Z.itemMeta(e, n.parentId);
|
|
1511
1511
|
}
|
|
1512
1512
|
return null;
|
|
1513
|
-
},
|
|
1513
|
+
}, Ln = (e) => {
|
|
1514
1514
|
let t = null;
|
|
1515
1515
|
for (; t == null || $.isItemExpanded(e, t);) {
|
|
1516
|
-
let n =
|
|
1516
|
+
let n = Pn(e, Z.itemOrderedChildrenIds(e, t));
|
|
1517
1517
|
if (n == null) return t;
|
|
1518
1518
|
t = n;
|
|
1519
1519
|
}
|
|
1520
1520
|
return t;
|
|
1521
|
-
},
|
|
1521
|
+
}, Rn = (e) => Z.itemOrderedChildrenIds(e, null).find((t) => Z.canItemBeFocused(e, t)), zn = (e, t, n) => {
|
|
1522
1522
|
if (t === n) return [t, n];
|
|
1523
1523
|
let r = Z.itemMeta(e, t), i = Z.itemMeta(e, n);
|
|
1524
1524
|
if (!r || !i) return [t, n];
|
|
@@ -1527,7 +1527,7 @@ var Sn = [], Z = {
|
|
|
1527
1527
|
for (; !u && !l;) d && (a.push(s), l = o.indexOf(s) !== -1, d = s !== null, !l && d && (s = Z.itemParentId(e, s))), f && !l && (o.push(c), u = a.indexOf(c) !== -1, f = c !== null, !u && f && (c = Z.itemParentId(e, c)));
|
|
1528
1528
|
let p = l ? s : c, m = Z.itemOrderedChildrenIds(e, p), h = a[a.indexOf(p) - 1], g = o[o.indexOf(p) - 1];
|
|
1529
1529
|
return m.indexOf(h) < m.indexOf(g) ? [t, n] : [n, t];
|
|
1530
|
-
},
|
|
1530
|
+
}, Bn = (e, t, n) => {
|
|
1531
1531
|
let r = (t) => {
|
|
1532
1532
|
if ($.isItemExpandable(e, t) && $.isItemExpanded(e, t)) return Z.itemOrderedChildrenIds(e, t)[0];
|
|
1533
1533
|
let n = Z.itemMeta(e, t);
|
|
@@ -1536,30 +1536,30 @@ var Sn = [], Z = {
|
|
|
1536
1536
|
if (r < t.length - 1) return t[r + 1];
|
|
1537
1537
|
n = n.parentId ? Z.itemMeta(e, n.parentId) : null;
|
|
1538
1538
|
}
|
|
1539
|
-
throw Error(
|
|
1540
|
-
}, [i, a] =
|
|
1539
|
+
throw Error(zt(191));
|
|
1540
|
+
}, [i, a] = zn(e, t, n), o = [i], s = i;
|
|
1541
1541
|
for (; s !== a;) s = r(s), Z.isItemDisabled(e, s) || o.push(s);
|
|
1542
1542
|
return o;
|
|
1543
|
-
},
|
|
1544
|
-
let t =
|
|
1545
|
-
for (; t != null;) n.push(t), t =
|
|
1543
|
+
}, Vn = (e) => {
|
|
1544
|
+
let t = Rn(e), n = [];
|
|
1545
|
+
for (; t != null;) n.push(t), t = In(e, t);
|
|
1546
1546
|
return n;
|
|
1547
|
-
},
|
|
1547
|
+
}, Hn = (e, t) => t !== e.closest("*[role=\"treeitem\"]"), Un = class {
|
|
1548
1548
|
lastSelectedItem = null;
|
|
1549
1549
|
lastSelectedRange = {};
|
|
1550
1550
|
constructor(e) {
|
|
1551
|
-
this.store = e, e.itemPluginManager.register(
|
|
1551
|
+
this.store = e, e.itemPluginManager.register(Mn, null);
|
|
1552
1552
|
}
|
|
1553
1553
|
setSelectedItems = (e, t, n) => {
|
|
1554
|
-
let { selectionPropagation: r =
|
|
1555
|
-
if (c = l && (r.descendants || r.parents) ?
|
|
1554
|
+
let { selectionPropagation: r = It, selectedItems: i, onItemSelectionToggle: a, onSelectedItemsChange: o } = this.store.parameters, s = Q.selectedItemsRaw(this.store.state), c, l = Q.isMultiSelectEnabled(this.store.state);
|
|
1555
|
+
if (c = l && (r.descendants || r.parents) ? Wn({
|
|
1556
1556
|
store: this.store,
|
|
1557
1557
|
selectionPropagation: r,
|
|
1558
1558
|
newModel: t,
|
|
1559
1559
|
oldModel: s,
|
|
1560
1560
|
additionalItemsToPropagate: n
|
|
1561
1561
|
}) : t, i === void 0 && this.store.set("selectedItems", c), a) if (l) {
|
|
1562
|
-
let t =
|
|
1562
|
+
let t = Gn({
|
|
1563
1563
|
newModel: c,
|
|
1564
1564
|
oldModel: s
|
|
1565
1565
|
});
|
|
@@ -1575,8 +1575,8 @@ var Sn = [], Z = {
|
|
|
1575
1575
|
if (!Q.isMultiSelectEnabled(this.store.state)) return;
|
|
1576
1576
|
let r = Q.selectedItems(this.store.state).slice();
|
|
1577
1577
|
Object.keys(this.lastSelectedRange).length > 0 && (r = r.filter((e) => !this.lastSelectedRange[e]));
|
|
1578
|
-
let i =
|
|
1579
|
-
r = r.concat(o), this.setSelectedItems(e, r), this.lastSelectedRange =
|
|
1578
|
+
let i = Kn(r), a = Bn(this.store.state, t, n).filter((e) => Q.isItemSelectable(this.store.state, e)), o = a.filter((e) => !i[e]);
|
|
1579
|
+
r = r.concat(o), this.setSelectedItems(e, r), this.lastSelectedRange = Kn(a);
|
|
1580
1580
|
};
|
|
1581
1581
|
getItemSelection = (e) => Q.itemSelectionStatus(this.store.state, e);
|
|
1582
1582
|
buildPublicAPI = () => ({
|
|
@@ -1584,7 +1584,7 @@ var Sn = [], Z = {
|
|
|
1584
1584
|
setItemSelection: this.setItemSelection
|
|
1585
1585
|
});
|
|
1586
1586
|
propagateSelectionToNewItems = (e, t) => {
|
|
1587
|
-
let { selectionPropagation: n =
|
|
1587
|
+
let { selectionPropagation: n = It } = this.store.parameters;
|
|
1588
1588
|
if (e == null || t.length === 0 || !n.descendants || !Q.isMultiSelectEnabled(this.store.state) || !Q.isItemSelected(this.store.state, e)) return;
|
|
1589
1589
|
let r = Q.selectedItems(this.store.state).concat(t);
|
|
1590
1590
|
this.setSelectedItems(null, r, t);
|
|
@@ -1600,20 +1600,20 @@ var Sn = [], Z = {
|
|
|
1600
1600
|
};
|
|
1601
1601
|
selectAllNavigableItems = (e) => {
|
|
1602
1602
|
if (!Q.isMultiSelectEnabled(this.store.state)) return;
|
|
1603
|
-
let t =
|
|
1604
|
-
this.setSelectedItems(e, t), this.lastSelectedRange =
|
|
1603
|
+
let t = Vn(this.store.state);
|
|
1604
|
+
this.setSelectedItems(e, t), this.lastSelectedRange = Kn(t);
|
|
1605
1605
|
};
|
|
1606
1606
|
expandSelectionRange = (e, t) => {
|
|
1607
1607
|
if (this.lastSelectedItem != null) {
|
|
1608
|
-
let [n, r] =
|
|
1608
|
+
let [n, r] = zn(this.store.state, t, this.lastSelectedItem);
|
|
1609
1609
|
this.selectRange(e, [n, r]);
|
|
1610
1610
|
}
|
|
1611
1611
|
};
|
|
1612
1612
|
selectRangeFromStartToItem = (e, t) => {
|
|
1613
|
-
this.selectRange(e, [
|
|
1613
|
+
this.selectRange(e, [Rn(this.store.state), t]);
|
|
1614
1614
|
};
|
|
1615
1615
|
selectRangeFromItemToEnd = (e, t) => {
|
|
1616
|
-
this.selectRange(e, [t,
|
|
1616
|
+
this.selectRange(e, [t, Ln(this.store.state)]);
|
|
1617
1617
|
};
|
|
1618
1618
|
selectItemFromArrowNavigation = (e, t, n) => {
|
|
1619
1619
|
if (!Q.isMultiSelectEnabled(this.store.state)) return;
|
|
@@ -1624,9 +1624,9 @@ var Sn = [], Z = {
|
|
|
1624
1624
|
}) : (this.lastSelectedRange[t] || (this.lastSelectedRange = {}), this.lastSelectedRange[n] ? (r = r.filter((e) => e !== t), delete this.lastSelectedRange[t]) : (Q.isItemSelected(this.store.state, n) || r.push(n), this.lastSelectedRange[n] = !0)), this.setSelectedItems(e, r);
|
|
1625
1625
|
};
|
|
1626
1626
|
};
|
|
1627
|
-
function
|
|
1627
|
+
function Wn({ store: e, selectionPropagation: t, newModel: n, oldModel: r, additionalItemsToPropagate: i }) {
|
|
1628
1628
|
if (!t.descendants && !t.parents) return n;
|
|
1629
|
-
let a = !1, o =
|
|
1629
|
+
let a = !1, o = Kn(n), s = Gn({
|
|
1630
1630
|
newModel: n,
|
|
1631
1631
|
oldModel: r
|
|
1632
1632
|
});
|
|
@@ -1659,7 +1659,7 @@ function Un({ store: e, selectionPropagation: t, newModel: n, oldModel: r, addit
|
|
|
1659
1659
|
}
|
|
1660
1660
|
}), a ? Object.keys(o) : n;
|
|
1661
1661
|
}
|
|
1662
|
-
function
|
|
1662
|
+
function Gn({ oldModel: e, newModel: t }) {
|
|
1663
1663
|
let n = /* @__PURE__ */ new Map();
|
|
1664
1664
|
t.forEach((e) => {
|
|
1665
1665
|
n.set(e, !0);
|
|
@@ -1672,14 +1672,14 @@ function Wn({ oldModel: e, newModel: t }) {
|
|
|
1672
1672
|
removed: e.filter((e) => !n.has(e))
|
|
1673
1673
|
};
|
|
1674
1674
|
}
|
|
1675
|
-
function
|
|
1675
|
+
function Kn(e) {
|
|
1676
1676
|
let t = {};
|
|
1677
1677
|
return e.forEach((e) => {
|
|
1678
1678
|
t[e] = !0;
|
|
1679
1679
|
}), t;
|
|
1680
1680
|
}
|
|
1681
|
-
function
|
|
1682
|
-
let r = X(e,
|
|
1681
|
+
function qn(e, t, n) {
|
|
1682
|
+
let r = X(e, _n.treeId), i = X(e, Z.itemChildrenIndentation), a = X(e, Q.isMultiSelectEnabled);
|
|
1683
1683
|
return (o) => Y({
|
|
1684
1684
|
ref: n,
|
|
1685
1685
|
role: "tree",
|
|
@@ -1695,15 +1695,15 @@ function Kn(e, t, n) {
|
|
|
1695
1695
|
}
|
|
1696
1696
|
});
|
|
1697
1697
|
}
|
|
1698
|
-
function
|
|
1698
|
+
function Jn(e) {
|
|
1699
1699
|
return e.replace(/["\\]/g, "\\$&");
|
|
1700
1700
|
}
|
|
1701
|
-
var
|
|
1702
|
-
function
|
|
1703
|
-
let { children: t, itemId: n = null, idAttribute: r } = e, { store: i, rootRef: a } =
|
|
1701
|
+
var Yn = /*#__PURE__*/ K.createContext(null);
|
|
1702
|
+
function Xn(e) {
|
|
1703
|
+
let { children: t, itemId: n = null, idAttribute: r } = e, { store: i, rootRef: a } = Vt(), o = K.useRef(/* @__PURE__ */ new Map()), [, s] = K.useReducer((e) => e + 1, 0);
|
|
1704
1704
|
K.useEffect(() => {
|
|
1705
1705
|
if (!a.current) return;
|
|
1706
|
-
let e = Z.itemOrderedChildrenIds(i.state, n ?? null) ?? [], t =
|
|
1706
|
+
let e = Z.itemOrderedChildrenIds(i.state, n ?? null) ?? [], t = Jn(r ?? a.current.id);
|
|
1707
1707
|
if (n != null) {
|
|
1708
1708
|
let e = a.current.querySelector(`*[id="${t}"][role="treeitem"]`);
|
|
1709
1709
|
if (e && e.getAttribute("aria-expanded") === "false") return;
|
|
@@ -1720,44 +1720,44 @@ function Yn(e) {
|
|
|
1720
1720
|
},
|
|
1721
1721
|
parentId: n
|
|
1722
1722
|
}), [n]);
|
|
1723
|
-
return /*#__PURE__*/ (0, q.jsx)(
|
|
1723
|
+
return /*#__PURE__*/ (0, q.jsx)(Yn.Provider, {
|
|
1724
1724
|
value: c,
|
|
1725
1725
|
children: t
|
|
1726
1726
|
});
|
|
1727
1727
|
}
|
|
1728
|
-
var
|
|
1729
|
-
function
|
|
1730
|
-
return
|
|
1728
|
+
var Zn = /*#__PURE__*/ K.createContext(() => -1), Qn = typeof Symbol.dispose == "symbol" ? Symbol.dispose : Symbol.for("Symbol.dispose"), $n = typeof SuppressedError == "function" ? SuppressedError : void 0;
|
|
1729
|
+
function er(e, t) {
|
|
1730
|
+
return $n ? new $n(e, t) : Object.assign(/* @__PURE__ */ Error("An error was suppressed during disposal."), {
|
|
1731
1731
|
name: "SuppressedError",
|
|
1732
1732
|
error: e,
|
|
1733
1733
|
suppressed: t
|
|
1734
1734
|
});
|
|
1735
1735
|
}
|
|
1736
|
-
function
|
|
1736
|
+
function tr(e) {
|
|
1737
1737
|
if (e) throw ReferenceError("MUI X: The disposable stack is disposed.");
|
|
1738
1738
|
}
|
|
1739
|
-
var
|
|
1739
|
+
var nr = class e {
|
|
1740
1740
|
stack = [];
|
|
1741
1741
|
isDisposed = !1;
|
|
1742
1742
|
get disposed() {
|
|
1743
1743
|
return this.isDisposed;
|
|
1744
1744
|
}
|
|
1745
1745
|
use(e) {
|
|
1746
|
-
if (
|
|
1747
|
-
let t = e[
|
|
1746
|
+
if (tr(this.isDisposed), e != null) {
|
|
1747
|
+
let t = e[Qn];
|
|
1748
1748
|
if (typeof t != "function") throw TypeError("MUI X: The value is not disposable.");
|
|
1749
1749
|
this.stack.push(() => t.call(e));
|
|
1750
1750
|
}
|
|
1751
1751
|
return e;
|
|
1752
1752
|
}
|
|
1753
1753
|
adopt(e, t) {
|
|
1754
|
-
return
|
|
1754
|
+
return tr(this.isDisposed), this.stack.push(() => t(e)), e;
|
|
1755
1755
|
}
|
|
1756
1756
|
defer(e) {
|
|
1757
|
-
|
|
1757
|
+
tr(this.isDisposed), this.stack.push(e);
|
|
1758
1758
|
}
|
|
1759
1759
|
move() {
|
|
1760
|
-
|
|
1760
|
+
tr(this.isDisposed);
|
|
1761
1761
|
let t = new e();
|
|
1762
1762
|
return t.stack = this.stack, this.stack = [], this.isDisposed = !0, t;
|
|
1763
1763
|
}
|
|
@@ -1768,35 +1768,35 @@ var tr = class e {
|
|
|
1768
1768
|
for (let n = this.stack.length - 1; n >= 0; --n) try {
|
|
1769
1769
|
this.stack[n]();
|
|
1770
1770
|
} catch (n) {
|
|
1771
|
-
t = e ?
|
|
1771
|
+
t = e ? er(n, t) : n, e = !0;
|
|
1772
1772
|
}
|
|
1773
1773
|
if (this.stack = [], e) throw t;
|
|
1774
1774
|
}
|
|
1775
|
-
[
|
|
1775
|
+
[Qn]() {
|
|
1776
1776
|
this.dispose();
|
|
1777
1777
|
}
|
|
1778
|
-
},
|
|
1778
|
+
}, rr = globalThis.DisposableStack ?? nr;
|
|
1779
1779
|
globalThis.AsyncDisposableStack;
|
|
1780
|
-
var
|
|
1781
|
-
|
|
1782
|
-
var
|
|
1783
|
-
function
|
|
1784
|
-
let t = K.useRef(
|
|
1785
|
-
if (t.current ===
|
|
1780
|
+
var ir = pn;
|
|
1781
|
+
ir.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE ?? ir.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;
|
|
1782
|
+
var ar = Symbol("useDisposable.mount"), or = Symbol();
|
|
1783
|
+
function sr(e) {
|
|
1784
|
+
let t = K.useRef(or);
|
|
1785
|
+
if (t.current === or) {
|
|
1786
1786
|
let n = e(), r = () => {
|
|
1787
|
-
n[
|
|
1787
|
+
n[Qn](), t.current = or;
|
|
1788
1788
|
};
|
|
1789
|
-
n[
|
|
1789
|
+
n[ar] = () => r, t.current = n;
|
|
1790
1790
|
}
|
|
1791
|
-
return
|
|
1791
|
+
return hn(t.current[ar]), t.current;
|
|
1792
1792
|
}
|
|
1793
|
-
var
|
|
1794
|
-
function
|
|
1795
|
-
let n =
|
|
1793
|
+
var cr = sr;
|
|
1794
|
+
function lr(e, t) {
|
|
1795
|
+
let n = p(), r = E(), i = cr(() => new e(Y({}, t, {
|
|
1796
1796
|
isRtl: n,
|
|
1797
1797
|
defaultId: r
|
|
1798
1798
|
})));
|
|
1799
|
-
return
|
|
1799
|
+
return mn(() => i.updateStateFromParameters(Y({}, t, {
|
|
1800
1800
|
isRtl: n,
|
|
1801
1801
|
defaultId: r
|
|
1802
1802
|
})), [
|
|
@@ -1804,9 +1804,9 @@ function cr(e, t) {
|
|
|
1804
1804
|
n,
|
|
1805
1805
|
r,
|
|
1806
1806
|
t
|
|
1807
|
-
]),
|
|
1807
|
+
]), hn(i.mountEffect), i;
|
|
1808
1808
|
}
|
|
1809
|
-
var
|
|
1809
|
+
var ur = class {
|
|
1810
1810
|
maxListeners = 20;
|
|
1811
1811
|
warnOnce = !1;
|
|
1812
1812
|
events = {};
|
|
@@ -1842,36 +1842,36 @@ var lr = class {
|
|
|
1842
1842
|
n.removeListener(e, r), t.apply(n, i);
|
|
1843
1843
|
});
|
|
1844
1844
|
}
|
|
1845
|
-
},
|
|
1846
|
-
function
|
|
1845
|
+
}, dr = ({ isItemEditable: e, expansionTrigger: t }) => t || (e ? "iconContainer" : "content");
|
|
1846
|
+
function fr(e) {
|
|
1847
1847
|
return {
|
|
1848
1848
|
disabledItemsFocusable: e.disabledItemsFocusable ?? !1,
|
|
1849
1849
|
itemChildrenIndentation: e.itemChildrenIndentation ?? "12px",
|
|
1850
1850
|
providedTreeId: e.id,
|
|
1851
|
-
expansionTrigger:
|
|
1851
|
+
expansionTrigger: dr({
|
|
1852
1852
|
isItemEditable: e.isItemEditable,
|
|
1853
1853
|
expansionTrigger: e.expansionTrigger
|
|
1854
1854
|
}),
|
|
1855
1855
|
disableSelection: e.disableSelection ?? !1,
|
|
1856
1856
|
multiSelect: e.multiSelect ?? !1,
|
|
1857
1857
|
checkboxSelection: e.checkboxSelection ?? !1,
|
|
1858
|
-
selectionPropagation: e.selectionPropagation ??
|
|
1858
|
+
selectionPropagation: e.selectionPropagation ?? It,
|
|
1859
1859
|
itemHeight: e.itemHeight ?? null
|
|
1860
1860
|
};
|
|
1861
1861
|
}
|
|
1862
|
-
function
|
|
1862
|
+
function pr(e, t, n) {
|
|
1863
1863
|
return e === void 0 ? t === void 0 ? n : t : e;
|
|
1864
1864
|
}
|
|
1865
|
-
function
|
|
1865
|
+
function mr(e) {
|
|
1866
1866
|
return Y({
|
|
1867
1867
|
treeId: e.defaultId,
|
|
1868
1868
|
focusedItemId: null
|
|
1869
|
-
},
|
|
1870
|
-
expandedItems:
|
|
1871
|
-
selectedItems:
|
|
1869
|
+
}, fr(e), wn.buildItemsStateIfNeeded(e), {
|
|
1870
|
+
expandedItems: pr(e.expandedItems, e.defaultExpandedItems, []),
|
|
1871
|
+
selectedItems: pr(e.selectedItems, e.defaultSelectedItems, e.multiSelect ? Ft : null)
|
|
1872
1872
|
});
|
|
1873
1873
|
}
|
|
1874
|
-
var
|
|
1874
|
+
var hr = class {
|
|
1875
1875
|
timeoutIds = /* @__PURE__ */ new Map();
|
|
1876
1876
|
intervalIds = /* @__PURE__ */ new Map();
|
|
1877
1877
|
startTimeout = (e, t, n) => {
|
|
@@ -1897,7 +1897,7 @@ var mr = class {
|
|
|
1897
1897
|
clearAll = () => {
|
|
1898
1898
|
this.timeoutIds.forEach(clearTimeout), this.timeoutIds.clear(), this.intervalIds.forEach(clearInterval), this.intervalIds.clear();
|
|
1899
1899
|
};
|
|
1900
|
-
},
|
|
1900
|
+
}, gr = class {
|
|
1901
1901
|
constructor(e) {
|
|
1902
1902
|
this.store = e;
|
|
1903
1903
|
}
|
|
@@ -1940,26 +1940,26 @@ var mr = class {
|
|
|
1940
1940
|
for (let n of e) t[n] = Y({}, t[n], { expandable: !0 });
|
|
1941
1941
|
this.store.set("itemMetaLookup", t);
|
|
1942
1942
|
};
|
|
1943
|
-
},
|
|
1943
|
+
}, _r = {
|
|
1944
1944
|
isItemEditable: (e, t) => {
|
|
1945
1945
|
let n = e.isItemEditable, r = Z.itemModel(e, t);
|
|
1946
1946
|
return !r || n == null ? !1 : typeof n == "boolean" ? n : n(r);
|
|
1947
1947
|
},
|
|
1948
1948
|
isItemBeingEdited: (e, t) => t != null && e.editedItemId === t,
|
|
1949
1949
|
isAnyItemBeingEdited: (e) => !!e.editedItemId
|
|
1950
|
-
},
|
|
1950
|
+
}, vr = 500, yr = class {
|
|
1951
1951
|
typeaheadQuery = "";
|
|
1952
1952
|
constructor(e) {
|
|
1953
|
-
this.store = e, this.labelMap =
|
|
1954
|
-
this.store.shouldIgnoreItemsStateUpdate() || (this.labelMap =
|
|
1953
|
+
this.store = e, this.labelMap = xr(Z.itemMetaLookup(this.store.state)), this.store.registerStoreEffect(Z.itemMetaLookup, (e, t) => {
|
|
1954
|
+
this.store.shouldIgnoreItemsStateUpdate() || (this.labelMap = xr(t));
|
|
1955
1955
|
});
|
|
1956
1956
|
}
|
|
1957
1957
|
canToggleItemSelection = (e) => Q.canItemBeSelected(this.store.state, e);
|
|
1958
1958
|
canToggleItemExpansion = (e) => !Z.isItemDisabled(this.store.state, e) && $.isItemExpandable(this.store.state, e);
|
|
1959
1959
|
getFirstItemMatchingTypeaheadQuery = (e, t) => {
|
|
1960
1960
|
let n = (e) => {
|
|
1961
|
-
let t =
|
|
1962
|
-
return t === null ?
|
|
1961
|
+
let t = In(this.store.state, e);
|
|
1962
|
+
return t === null ? Rn(this.store.state) : t;
|
|
1963
1963
|
}, r = (t) => {
|
|
1964
1964
|
let r = null, i = {}, a = t.length > 1 ? e : n(e);
|
|
1965
1965
|
for (; r == null && !i[a];) this.labelMap[a]?.startsWith(t) ? r = a : (i[a] = !0, a = n(a));
|
|
@@ -1973,7 +1973,7 @@ var mr = class {
|
|
|
1973
1973
|
this.labelMap = e(this.labelMap);
|
|
1974
1974
|
};
|
|
1975
1975
|
handleItemKeyDown = async (e, t) => {
|
|
1976
|
-
if (e.defaultMuiPrevented || e.altKey ||
|
|
1976
|
+
if (e.defaultMuiPrevented || e.altKey || Hn(e.target, e.currentTarget)) return;
|
|
1977
1977
|
let n = e.ctrlKey || e.metaKey, r = e.key, i = Q.isMultiSelectEnabled(this.store.state);
|
|
1978
1978
|
switch (!0) {
|
|
1979
1979
|
case r === " " && this.canToggleItemSelection(t):
|
|
@@ -1985,7 +1985,7 @@ var mr = class {
|
|
|
1985
1985
|
});
|
|
1986
1986
|
break;
|
|
1987
1987
|
case r === "Enter":
|
|
1988
|
-
this.store.labelEditing?.setEditedItem &&
|
|
1988
|
+
this.store.labelEditing?.setEditedItem && _r.isItemEditable(this.store.state, t) && !_r.isItemBeingEdited(this.store.state, t) ? this.store.labelEditing.setEditedItem(t) : this.canToggleItemExpansion(t) ? (this.store.expansion.setItemExpansion({
|
|
1989
1989
|
event: e,
|
|
1990
1990
|
itemId: t
|
|
1991
1991
|
}), e.preventDefault()) : this.canToggleItemSelection(t) && (i ? (e.preventDefault(), this.store.selection.setItemSelection({
|
|
@@ -1998,19 +1998,19 @@ var mr = class {
|
|
|
1998
1998
|
}), e.preventDefault()));
|
|
1999
1999
|
break;
|
|
2000
2000
|
case r === "ArrowDown": {
|
|
2001
|
-
let n =
|
|
2001
|
+
let n = In(this.store.state, t);
|
|
2002
2002
|
n && (e.preventDefault(), this.store.focus.focusItem(e, n), i && e.shiftKey && this.canToggleItemSelection(n) && this.store.selection.selectItemFromArrowNavigation(e, t, n));
|
|
2003
2003
|
break;
|
|
2004
2004
|
}
|
|
2005
2005
|
case r === "ArrowUp": {
|
|
2006
|
-
let n =
|
|
2006
|
+
let n = Fn(this.store.state, t);
|
|
2007
2007
|
n && (e.preventDefault(), this.store.focus.focusItem(e, n), i && e.shiftKey && this.canToggleItemSelection(n) && this.store.selection.selectItemFromArrowNavigation(e, t, n));
|
|
2008
2008
|
break;
|
|
2009
2009
|
}
|
|
2010
2010
|
case r === "ArrowRight" && !this.store.parameters.isRtl || r === "ArrowLeft" && this.store.parameters.isRtl:
|
|
2011
2011
|
if (n) return;
|
|
2012
2012
|
if ($.isItemExpanded(this.store.state, t)) {
|
|
2013
|
-
let n =
|
|
2013
|
+
let n = In(this.store.state, t);
|
|
2014
2014
|
n && (this.store.focus.focusItem(e, n), e.preventDefault());
|
|
2015
2015
|
} else this.canToggleItemExpansion(t) && (this.store.expansion.setItemExpansion({
|
|
2016
2016
|
event: e,
|
|
@@ -2029,10 +2029,10 @@ var mr = class {
|
|
|
2029
2029
|
}
|
|
2030
2030
|
break;
|
|
2031
2031
|
case r === "Home":
|
|
2032
|
-
this.canToggleItemSelection(t) && i && n && e.shiftKey ? this.store.selection.selectRangeFromStartToItem(e, t) : this.store.focus.focusItem(e,
|
|
2032
|
+
this.canToggleItemSelection(t) && i && n && e.shiftKey ? this.store.selection.selectRangeFromStartToItem(e, t) : this.store.focus.focusItem(e, Rn(this.store.state)), e.preventDefault();
|
|
2033
2033
|
break;
|
|
2034
2034
|
case r === "End":
|
|
2035
|
-
this.canToggleItemSelection(t) && i && n && e.shiftKey ? this.store.selection.selectRangeFromItemToEnd(e, t) : this.store.focus.focusItem(e,
|
|
2035
|
+
this.canToggleItemSelection(t) && i && n && e.shiftKey ? this.store.selection.selectRangeFromItemToEnd(e, t) : this.store.focus.focusItem(e, Ln(this.store.state)), e.preventDefault();
|
|
2036
2036
|
break;
|
|
2037
2037
|
case r === "*":
|
|
2038
2038
|
this.store.expansion.expandAllSiblings(e, t), e.preventDefault();
|
|
@@ -2040,10 +2040,10 @@ var mr = class {
|
|
|
2040
2040
|
case String.fromCharCode(e.keyCode) === "A" && n && i && Q.enabled(this.store.state):
|
|
2041
2041
|
this.store.selection.selectAllNavigableItems(e), e.preventDefault();
|
|
2042
2042
|
break;
|
|
2043
|
-
case !n && !e.shiftKey &&
|
|
2043
|
+
case !n && !e.shiftKey && br(r): {
|
|
2044
2044
|
this.store.timeoutManager.clearTimeout("typeahead");
|
|
2045
2045
|
let n = this.getFirstItemMatchingTypeaheadQuery(t, r);
|
|
2046
|
-
n == null ? this.typeaheadQuery = "" : (this.store.focus.focusItem(e, n), e.preventDefault()), this.store.timeoutManager.startTimeout("typeahead",
|
|
2046
|
+
n == null ? this.typeaheadQuery = "" : (this.store.focus.focusItem(e, n), e.preventDefault()), this.store.timeoutManager.startTimeout("typeahead", vr, () => {
|
|
2047
2047
|
this.typeaheadQuery = "";
|
|
2048
2048
|
});
|
|
2049
2049
|
break;
|
|
@@ -2051,25 +2051,25 @@ var mr = class {
|
|
|
2051
2051
|
}
|
|
2052
2052
|
};
|
|
2053
2053
|
};
|
|
2054
|
-
function
|
|
2054
|
+
function br(e) {
|
|
2055
2055
|
return !!e && e.length === 1 && !!e.match(/\S/);
|
|
2056
2056
|
}
|
|
2057
|
-
function
|
|
2057
|
+
function xr(e) {
|
|
2058
2058
|
let t = {};
|
|
2059
2059
|
return Object.values(e).forEach((e) => {
|
|
2060
2060
|
t[e.id] = e.label.toLowerCase();
|
|
2061
2061
|
}), t;
|
|
2062
2062
|
}
|
|
2063
|
-
var
|
|
2064
|
-
if (!r &&
|
|
2063
|
+
var Sr = Qt(Q.selectedItems, $.expandedItemsMap, Z.itemMetaLookup, Z.disabledItemFocusable, (e) => Z.itemOrderedChildrenIds(e, null), (e, t, n, r, i) => e.find((e) => {
|
|
2064
|
+
if (!r && yn(n, e)) return !1;
|
|
2065
2065
|
let i = n[e];
|
|
2066
2066
|
return i && (i.parentId == null || t.has(i.parentId));
|
|
2067
|
-
}) ?? i.find((e) => r || !
|
|
2068
|
-
defaultFocusableItemId:
|
|
2069
|
-
isItemTheDefaultFocusableItem: (e, t) =>
|
|
2067
|
+
}) ?? i.find((e) => r || !yn(n, e)) ?? null), Cr = {
|
|
2068
|
+
defaultFocusableItemId: Sr,
|
|
2069
|
+
isItemTheDefaultFocusableItem: (e, t) => Sr(e) === t,
|
|
2070
2070
|
focusedItemId: (e) => e.focusedItemId,
|
|
2071
2071
|
isItemFocused: (e, t) => e.focusedItemId === t
|
|
2072
|
-
},
|
|
2072
|
+
}, wr = class {
|
|
2073
2073
|
constructor(e) {
|
|
2074
2074
|
this.store = e;
|
|
2075
2075
|
let t = e.state;
|
|
@@ -2078,17 +2078,17 @@ var xr = Zt(Q.selectedItems, $.expandedItemsMap, Z.itemMetaLookup, Z.disabledIte
|
|
|
2078
2078
|
t = e;
|
|
2079
2079
|
return;
|
|
2080
2080
|
}
|
|
2081
|
-
let n =
|
|
2081
|
+
let n = Cr.focusedItemId(e);
|
|
2082
2082
|
if (n == null || Z.itemMeta(e, n)) {
|
|
2083
2083
|
t = e;
|
|
2084
2084
|
return;
|
|
2085
2085
|
}
|
|
2086
|
-
let r = (t) => t == null || !Z.itemMeta(e, t) ? null : t, i = r(
|
|
2086
|
+
let r = (t) => t == null || !Z.itemMeta(e, t) ? null : t, i = r(In(t, n)) ?? r(Fn(t, n)) ?? Rn(e);
|
|
2087
2087
|
i == null ? this.setFocusedItemId(null) : this.applyItemFocus(null, i), t = e;
|
|
2088
2088
|
}));
|
|
2089
2089
|
}
|
|
2090
2090
|
setFocusedItemId = (e) => {
|
|
2091
|
-
|
|
2091
|
+
Cr.focusedItemId(this.store.state) !== e && this.store.set("focusedItemId", e);
|
|
2092
2092
|
};
|
|
2093
2093
|
applyItemFocus = (e, t) => {
|
|
2094
2094
|
this.store.items.getItemDOMElement(t)?.focus(), this.setFocusedItemId(t), this.store.parameters.onItemFocus?.(e, t);
|
|
@@ -2099,7 +2099,7 @@ var xr = Zt(Q.selectedItems, $.expandedItemsMap, Z.itemMetaLookup, Z.disabledIte
|
|
|
2099
2099
|
n && (n.parentId == null || $.isItemExpanded(this.store.state, n.parentId)) && this.applyItemFocus(e, t);
|
|
2100
2100
|
};
|
|
2101
2101
|
removeFocusedItem = () => {
|
|
2102
|
-
let e =
|
|
2102
|
+
let e = Cr.focusedItemId(this.store.state);
|
|
2103
2103
|
if (e != null) {
|
|
2104
2104
|
if (Z.itemMeta(this.store.state, e)) {
|
|
2105
2105
|
let t = this.store.items.getItemDOMElement(e);
|
|
@@ -2110,13 +2110,13 @@ var xr = Zt(Q.selectedItems, $.expandedItemsMap, Z.itemMetaLookup, Z.disabledIte
|
|
|
2110
2110
|
};
|
|
2111
2111
|
handleRootFocus = (e) => {
|
|
2112
2112
|
if (e.defaultMuiPrevented) return;
|
|
2113
|
-
let t =
|
|
2113
|
+
let t = Cr.defaultFocusableItemId(this.store.state);
|
|
2114
2114
|
e.target === e.currentTarget && t != null && this.applyItemFocus(e, t);
|
|
2115
2115
|
};
|
|
2116
2116
|
handleRootBlur = (e) => {
|
|
2117
2117
|
e.defaultMuiPrevented || this.setFocusedItemId(null);
|
|
2118
2118
|
};
|
|
2119
|
-
},
|
|
2119
|
+
}, Tr = class {
|
|
2120
2120
|
itemPlugins = [];
|
|
2121
2121
|
itemWrappers = [];
|
|
2122
2122
|
register = (e, t) => {
|
|
@@ -2124,15 +2124,15 @@ var xr = Zt(Q.selectedItems, $.expandedItemsMap, Z.itemMetaLookup, Z.disabledIte
|
|
|
2124
2124
|
};
|
|
2125
2125
|
listPlugins = () => this.itemPlugins;
|
|
2126
2126
|
listWrappers = () => this.itemWrappers;
|
|
2127
|
-
},
|
|
2127
|
+
}, Er = class extends fn {
|
|
2128
2128
|
initialParameters = null;
|
|
2129
|
-
disposables = new
|
|
2130
|
-
eventManager = this.disposables.adopt(new
|
|
2131
|
-
timeoutManager = this.disposables.adopt(new
|
|
2132
|
-
itemPluginManager = new
|
|
2129
|
+
disposables = new rr();
|
|
2130
|
+
eventManager = this.disposables.adopt(new ur(), (e) => e.removeAllListeners());
|
|
2131
|
+
timeoutManager = this.disposables.adopt(new hr(), (e) => e.clearAll());
|
|
2132
|
+
itemPluginManager = new Tr();
|
|
2133
2133
|
constructor(e, t, n) {
|
|
2134
|
-
let r =
|
|
2135
|
-
super(i), this.parameters = e, this.instanceName = t, this.mapper = n, this.items = new
|
|
2134
|
+
let r = mr(e), i = n.getInitialState(r, e);
|
|
2135
|
+
super(i), this.parameters = e, this.instanceName = t, this.mapper = n, this.items = new wn(this), this.focus = new wr(this), this.expansion = new gr(this), this.selection = new Un(this), this.keyboardNavigation = new yr(this);
|
|
2136
2136
|
}
|
|
2137
2137
|
buildPublicAPI() {
|
|
2138
2138
|
return Y({}, this.items.buildPublicAPI(), this.focus.buildPublicAPI(), this.expansion.buildPublicAPI(), this.selection.buildPublicAPI());
|
|
@@ -2140,13 +2140,13 @@ var xr = Zt(Q.selectedItems, $.expandedItemsMap, Z.itemMetaLookup, Z.disabledIte
|
|
|
2140
2140
|
updateStateFromParameters(e) {
|
|
2141
2141
|
let t = (t, n, r) => {
|
|
2142
2142
|
e[n] !== void 0 && (t[n] = e[n]);
|
|
2143
|
-
}, n =
|
|
2144
|
-
t(n, "expandedItems", "defaultExpandedItems"), t(n, "selectedItems", "defaultSelectedItems"), this.state.treeId !== e.defaultId && (n.treeId = e.defaultId), !this.mapper.shouldIgnoreItemsStateUpdate(e) &&
|
|
2143
|
+
}, n = fr(e);
|
|
2144
|
+
t(n, "expandedItems", "defaultExpandedItems"), t(n, "selectedItems", "defaultSelectedItems"), this.state.treeId !== e.defaultId && (n.treeId = e.defaultId), !this.mapper.shouldIgnoreItemsStateUpdate(e) && wn.shouldRebuildItemsState(e, this.parameters) && Object.assign(n, wn.buildItemsStateIfNeeded(e));
|
|
2145
2145
|
let r = this.mapper.updateStateFromParameters(n, e, t);
|
|
2146
2146
|
this.update(r), this.parameters = e;
|
|
2147
2147
|
}
|
|
2148
2148
|
mountEffect = () => {};
|
|
2149
|
-
[
|
|
2149
|
+
[Qn]() {
|
|
2150
2150
|
if (!this.disposables.disposed) try {
|
|
2151
2151
|
this.disposables.dispose();
|
|
2152
2152
|
} catch {}
|
|
@@ -2160,23 +2160,23 @@ var xr = Zt(Q.selectedItems, $.expandedItemsMap, Z.itemMetaLookup, Z.disabledIte
|
|
|
2160
2160
|
}));
|
|
2161
2161
|
};
|
|
2162
2162
|
publishEvent = (e, t, n) => {
|
|
2163
|
-
|
|
2163
|
+
Dr(n) && n.isPropagationStopped() || this.eventManager.emit(e, t, n);
|
|
2164
2164
|
};
|
|
2165
2165
|
subscribeEvent = (e, t) => {
|
|
2166
2166
|
this.eventManager.on(e, t);
|
|
2167
2167
|
};
|
|
2168
2168
|
};
|
|
2169
|
-
function
|
|
2169
|
+
function Dr(e) {
|
|
2170
2170
|
return e?.isPropagationStopped !== void 0;
|
|
2171
2171
|
}
|
|
2172
|
-
var
|
|
2172
|
+
var Or = {
|
|
2173
2173
|
isEmpty: (e) => e.lazyLoadedItems == null || Object.keys(e.lazyLoadedItems.loading).length === 0 && Object.keys(e.lazyLoadedItems.errors).length === 0,
|
|
2174
2174
|
isItemLoading: (e, t) => e.lazyLoadedItems?.loading[t ?? "__TREE_VIEW_ROOT_PARENT_ID__"] != null,
|
|
2175
2175
|
itemLoadingChildrenCount: (e, t) => e.lazyLoadedItems?.loading[t ?? "__TREE_VIEW_ROOT_PARENT_ID__"] ?? -1,
|
|
2176
2176
|
itemHasError: (e, t) => !!e.lazyLoadedItems?.errors[t ?? "__TREE_VIEW_ROOT_PARENT_ID__"],
|
|
2177
2177
|
itemError: (e, t) => e.lazyLoadedItems?.errors[t ?? "__TREE_VIEW_ROOT_PARENT_ID__"]
|
|
2178
|
-
},
|
|
2179
|
-
let { store: n, publicAPI: r } =
|
|
2178
|
+
}, kr = (e) => Array.isArray(e) ? e.length > 0 && e.some(kr) : !!e, Ar = ({ itemId: e, children: t }) => {
|
|
2179
|
+
let { store: n, publicAPI: r } = Vt(), i = X(n, $.isItemExpandable, e), a = X(n, Or.isItemLoading, e), o = X(n, Or.itemHasError, e), s = kr(t) || i, c = X(n, $.isItemExpanded, e), l = X(n, Cr.isItemFocused, e), u = X(n, Q.isItemSelected, e), d = X(n, Q.isItemIndeterminate, e), f = X(n, Z.isItemDisabled, e), p = X(n, _r.isItemBeingEdited, e), m = {
|
|
2180
2180
|
expandable: s,
|
|
2181
2181
|
expanded: c,
|
|
2182
2182
|
focused: l,
|
|
@@ -2184,7 +2184,7 @@ var Dr = {
|
|
|
2184
2184
|
indeterminate: d,
|
|
2185
2185
|
disabled: f,
|
|
2186
2186
|
editing: p,
|
|
2187
|
-
editable: X(n,
|
|
2187
|
+
editable: X(n, _r.isItemEditable, e),
|
|
2188
2188
|
loading: a,
|
|
2189
2189
|
error: o
|
|
2190
2190
|
}, h = (t) => {
|
|
@@ -2223,20 +2223,20 @@ var Dr = {
|
|
|
2223
2223
|
handleCheckboxSelection: _,
|
|
2224
2224
|
toggleItemEditing: v,
|
|
2225
2225
|
handleSaveItemLabel: (t, r) => {
|
|
2226
|
-
n.labelEditing &&
|
|
2226
|
+
n.labelEditing && _r.isItemBeingEdited(n.state, e) && (n.labelEditing.updateItemLabel(e, r), v(), n.focus.focusItem(t, e));
|
|
2227
2227
|
},
|
|
2228
2228
|
handleCancelItemLabelEditing: (t) => {
|
|
2229
|
-
n.labelEditing &&
|
|
2229
|
+
n.labelEditing && _r.isItemBeingEdited(n.state, e) && (v(), n.focus.focusItem(t, e));
|
|
2230
2230
|
}
|
|
2231
2231
|
},
|
|
2232
2232
|
status: m,
|
|
2233
2233
|
publicAPI: r
|
|
2234
2234
|
};
|
|
2235
|
-
},
|
|
2236
|
-
let { store: r } =
|
|
2237
|
-
if (u == null) throw Error(
|
|
2238
|
-
let { registerChild: d, unregisterChild: f, parentId: p } = u, m =
|
|
2239
|
-
return
|
|
2235
|
+
}, jr = ({ props: e, rootRef: t, contentRef: n }) => {
|
|
2236
|
+
let { store: r } = Vt(), { children: i, disabled: a = !1, disableSelection: o = !1, label: s, itemId: c, id: l } = e, u = K.useContext(Yn);
|
|
2237
|
+
if (u == null) throw Error(zt(196));
|
|
2238
|
+
let { registerChild: d, unregisterChild: f, parentId: p } = u, m = kr(i), h = K.useRef(null), g = kt(h, n), _ = X(r, _n.treeItemIdAttribute, c, l), v = K.useRef(!0), y = Ot(Symbol);
|
|
2239
|
+
return mn(() => (d(_, c), () => {
|
|
2240
2240
|
f(_), f(_);
|
|
2241
2241
|
}), [
|
|
2242
2242
|
r,
|
|
@@ -2244,9 +2244,9 @@ var Dr = {
|
|
|
2244
2244
|
f,
|
|
2245
2245
|
_,
|
|
2246
2246
|
c
|
|
2247
|
-
]),
|
|
2247
|
+
]), mn(() => (v.current = !0, () => {
|
|
2248
2248
|
v.current = !1;
|
|
2249
|
-
}), []),
|
|
2249
|
+
}), []), mn(() => {
|
|
2250
2250
|
let e = r.jsxItems.upsertJSXItem({
|
|
2251
2251
|
id: c,
|
|
2252
2252
|
idAttribute: l,
|
|
@@ -2277,24 +2277,24 @@ var Dr = {
|
|
|
2277
2277
|
contentRef: g,
|
|
2278
2278
|
rootRef: t
|
|
2279
2279
|
};
|
|
2280
|
-
},
|
|
2281
|
-
let r = K.useContext(
|
|
2282
|
-
return /*#__PURE__*/ (0, q.jsx)(
|
|
2280
|
+
}, Mr = ({ children: e, itemId: t, idAttribute: n }) => {
|
|
2281
|
+
let r = K.useContext(Zn);
|
|
2282
|
+
return /*#__PURE__*/ (0, q.jsx)(Xn, {
|
|
2283
2283
|
itemId: t,
|
|
2284
2284
|
idAttribute: n,
|
|
2285
|
-
children: /*#__PURE__*/ (0, q.jsx)(
|
|
2285
|
+
children: /*#__PURE__*/ (0, q.jsx)(Zn.Provider, {
|
|
2286
2286
|
value: r + 1,
|
|
2287
2287
|
children: e
|
|
2288
2288
|
})
|
|
2289
2289
|
});
|
|
2290
|
-
},
|
|
2290
|
+
}, Nr = class {
|
|
2291
2291
|
itemOwners = /* @__PURE__ */ new Map();
|
|
2292
2292
|
constructor(e) {
|
|
2293
|
-
this.store = e, e.itemPluginManager.register(
|
|
2293
|
+
this.store = e, e.itemPluginManager.register(jr, Mr);
|
|
2294
2294
|
}
|
|
2295
2295
|
upsertJSXItem = (e, t) => {
|
|
2296
2296
|
let n = this.itemOwners.get(e.id);
|
|
2297
|
-
if (n != null && n !== t) throw Error(
|
|
2297
|
+
if (n != null && n !== t) throw Error(zt(195, e.id));
|
|
2298
2298
|
this.itemOwners.set(e.id, t);
|
|
2299
2299
|
let r = Z.itemMeta(this.store.state, e.id);
|
|
2300
2300
|
if (r != null) {
|
|
@@ -2330,28 +2330,28 @@ var Dr = {
|
|
|
2330
2330
|
let n = e ?? "__TREE_VIEW_ROOT_PARENT_ID__";
|
|
2331
2331
|
this.store.update({
|
|
2332
2332
|
itemOrderedChildrenIdsLookup: Y({}, this.store.state.itemOrderedChildrenIdsLookup, { [n]: t }),
|
|
2333
|
-
itemChildrenIndexesLookup: Y({}, this.store.state.itemChildrenIndexesLookup, { [n]:
|
|
2333
|
+
itemChildrenIndexesLookup: Y({}, this.store.state.itemChildrenIndexesLookup, { [n]: vn(t) })
|
|
2334
2334
|
}), e !== null && Q.isMultiSelectEnabled(this.store.state) && Q.propagationRules(this.store.state).descendants && Q.isItemSelected(this.store.state, e) && this.store.selection.setItemSelection({
|
|
2335
2335
|
itemId: e,
|
|
2336
2336
|
shouldBeSelected: !0,
|
|
2337
2337
|
keepExistingSelection: !0
|
|
2338
2338
|
});
|
|
2339
2339
|
};
|
|
2340
|
-
},
|
|
2340
|
+
}, Pr = {
|
|
2341
2341
|
getInitialState: (e) => e,
|
|
2342
2342
|
updateStateFromParameters: (e) => e,
|
|
2343
2343
|
shouldIgnoreItemsStateUpdate: () => !0
|
|
2344
|
-
},
|
|
2345
|
-
jsxItems = new
|
|
2344
|
+
}, Fr = class extends Er {
|
|
2345
|
+
jsxItems = new Nr(this);
|
|
2346
2346
|
constructor(e) {
|
|
2347
|
-
super(Y({}, e, { items:
|
|
2347
|
+
super(Y({}, e, { items: Ft }), "SimpleTreeView", Pr);
|
|
2348
2348
|
}
|
|
2349
2349
|
updateStateFromParameters(e) {
|
|
2350
|
-
super.updateStateFromParameters(Y({}, e, { items:
|
|
2350
|
+
super.updateStateFromParameters(Y({}, e, { items: Ft }));
|
|
2351
2351
|
}
|
|
2352
|
-
},
|
|
2352
|
+
}, Ir = Nt("MuiSimpleTreeView"), Lr = (e) => {
|
|
2353
2353
|
let { classes: t } = e;
|
|
2354
|
-
return K.useMemo(() =>
|
|
2354
|
+
return K.useMemo(() => je({
|
|
2355
2355
|
root: ["root"],
|
|
2356
2356
|
item: ["item"],
|
|
2357
2357
|
itemContent: ["itemContent"],
|
|
@@ -2359,8 +2359,8 @@ var Dr = {
|
|
|
2359
2359
|
itemIconContainer: ["itemIconContainer"],
|
|
2360
2360
|
itemLabel: ["itemLabel"],
|
|
2361
2361
|
itemCheckbox: ["itemCheckbox"]
|
|
2362
|
-
},
|
|
2363
|
-
},
|
|
2362
|
+
}, Pt, t), [t]);
|
|
2363
|
+
}, Rr = V("ul", {
|
|
2364
2364
|
name: "MuiSimpleTreeView",
|
|
2365
2365
|
slot: "Root"
|
|
2366
2366
|
})({
|
|
@@ -2369,38 +2369,38 @@ var Dr = {
|
|
|
2369
2369
|
listStyle: "none",
|
|
2370
2370
|
outline: 0,
|
|
2371
2371
|
position: "relative"
|
|
2372
|
-
}),
|
|
2373
|
-
let n =
|
|
2372
|
+
}), zr = /*#__PURE__*/ K.forwardRef(function(e, t) {
|
|
2373
|
+
let n = Ir({
|
|
2374
2374
|
props: e,
|
|
2375
2375
|
name: "MuiSimpleTreeView"
|
|
2376
|
-
}), { slots: r, slotProps: i, apiRef: a, parameters: o, forwardedProps: s } =
|
|
2376
|
+
}), { slots: r, slotProps: i, apiRef: a, parameters: o, forwardedProps: s } = Yt(n), c = lr(Fr, o), l = K.useRef(null), u = qn(c, s, kt(t, l)), d = Lr(n), f = r?.root ?? Rr, p = W({
|
|
2377
2377
|
elementType: f,
|
|
2378
2378
|
externalSlotProps: i?.root,
|
|
2379
2379
|
className: d.root,
|
|
2380
2380
|
getSlotProps: u,
|
|
2381
2381
|
ownerState: n
|
|
2382
2382
|
});
|
|
2383
|
-
return /*#__PURE__*/ (0, q.jsx)(
|
|
2383
|
+
return /*#__PURE__*/ (0, q.jsx)(Kt, {
|
|
2384
2384
|
store: c,
|
|
2385
2385
|
classes: d,
|
|
2386
2386
|
slots: r,
|
|
2387
2387
|
slotProps: i,
|
|
2388
2388
|
apiRef: a,
|
|
2389
2389
|
rootRef: l,
|
|
2390
|
-
children: /*#__PURE__*/ (0, q.jsx)(
|
|
2390
|
+
children: /*#__PURE__*/ (0, q.jsx)(Xn, {
|
|
2391
2391
|
itemId: null,
|
|
2392
2392
|
idAttribute: null,
|
|
2393
|
-
children: /*#__PURE__*/ (0, q.jsx)(
|
|
2393
|
+
children: /*#__PURE__*/ (0, q.jsx)(Zn.Provider, {
|
|
2394
2394
|
value: 0,
|
|
2395
2395
|
children: /*#__PURE__*/ (0, q.jsx)(f, Y({}, p))
|
|
2396
2396
|
})
|
|
2397
2397
|
})
|
|
2398
2398
|
});
|
|
2399
|
-
}),
|
|
2400
|
-
let { runItemPlugins: t, publicAPI: n, store: r } =
|
|
2399
|
+
}), Br = (e, t, n) => typeof n == "function" ? n(e, t) : n, Vr = (e) => {
|
|
2400
|
+
let { runItemPlugins: t, publicAPI: n, store: r } = Vt(), i = K.useContext(Zn), a = X(r, Br, e.itemId, i), { id: o, itemId: s, label: c, children: l, rootRef: u } = e, { rootRef: d, contentRef: f, propsEnhancers: p } = t(e), { interactions: m, status: h } = Ar({
|
|
2401
2401
|
itemId: s,
|
|
2402
2402
|
children: l
|
|
2403
|
-
}), g = K.useRef(null), _ = K.useRef(null), v =
|
|
2403
|
+
}), g = K.useRef(null), _ = K.useRef(null), v = kt(u, d, g), y = kt(f, _), b = K.useRef(null), x = X(r, Q.isCheckboxSelectionEnabled), S = X(r, _n.treeItemIdAttribute, s, o), C = X(r, Cr.isItemTheDefaultFocusableItem, s), w = X(r, Z.itemHeight), T = {
|
|
2404
2404
|
rootRefObject: g,
|
|
2405
2405
|
contentRefObject: _,
|
|
2406
2406
|
interactions: m
|
|
@@ -2409,7 +2409,7 @@ var Dr = {
|
|
|
2409
2409
|
}, D = (e) => (t) => {
|
|
2410
2410
|
if (e.onBlur?.(t), t.defaultMuiPrevented) return;
|
|
2411
2411
|
let n = r.items.getItemDOMElement(s);
|
|
2412
|
-
h.editing || t.relatedTarget &&
|
|
2412
|
+
h.editing || t.relatedTarget && Hn(t.relatedTarget, n) && (t.target && t.target?.dataset?.element === "labelInput" && Hn(t.target, n) || t.relatedTarget?.dataset?.element === "labelInput") || r.focus.removeFocusedItem();
|
|
2413
2413
|
}, O = (e) => (t) => {
|
|
2414
2414
|
e.onKeyDown?.(t), !(t.defaultMuiPrevented || t.target?.dataset?.element === "labelInput") && r.keyboardNavigation.handleItemKeyDown(t, s);
|
|
2415
2415
|
}, k = (e) => (t) => {
|
|
@@ -2499,10 +2499,10 @@ var Dr = {
|
|
|
2499
2499
|
publicAPI: n
|
|
2500
2500
|
};
|
|
2501
2501
|
};
|
|
2502
|
-
function
|
|
2503
|
-
return
|
|
2502
|
+
function Hr(e) {
|
|
2503
|
+
return Pe("MuiTreeItem", e);
|
|
2504
2504
|
}
|
|
2505
|
-
|
|
2505
|
+
Te("MuiTreeItem", [
|
|
2506
2506
|
"root",
|
|
2507
2507
|
"content",
|
|
2508
2508
|
"groupTransition",
|
|
@@ -2514,29 +2514,29 @@ we("MuiTreeItem", [
|
|
|
2514
2514
|
"errorIcon",
|
|
2515
2515
|
"loadingIcon"
|
|
2516
2516
|
]);
|
|
2517
|
-
var
|
|
2518
|
-
function
|
|
2517
|
+
var Ur = tt(/*#__PURE__*/ (0, q.jsx)("path", { d: "M10 6 8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z" }), "TreeViewExpandIcon"), Wr = tt(/*#__PURE__*/ (0, q.jsx)("path", { d: "M16.59 8.59 12 13.17 7.41 8.59 6 10l6 6 6-6z" }), "TreeViewCollapseIcon"), Gr = ["ownerState"];
|
|
2518
|
+
function Kr(e, t, n) {
|
|
2519
2519
|
return e === void 0 ? t === void 0 ? n : t : e;
|
|
2520
2520
|
}
|
|
2521
|
-
function
|
|
2522
|
-
let { slots: t, slotProps: n, status: r } = e, { slots: i, slotProps: a } =
|
|
2523
|
-
collapseIcon:
|
|
2524
|
-
expandIcon:
|
|
2525
|
-
endIcon:
|
|
2521
|
+
function qr(e) {
|
|
2522
|
+
let { slots: t, slotProps: n, status: r } = e, { slots: i, slotProps: a } = Ut(), o = {
|
|
2523
|
+
collapseIcon: Kr(t?.collapseIcon, i.collapseIcon, Wr),
|
|
2524
|
+
expandIcon: Kr(t?.expandIcon, i.expandIcon, Ur),
|
|
2525
|
+
endIcon: Kr(t?.endIcon, i.endIcon),
|
|
2526
2526
|
icon: t?.icon
|
|
2527
2527
|
}, s;
|
|
2528
2528
|
s = o?.icon ? "icon" : r.expandable ? r.expanded ? "collapseIcon" : "expandIcon" : "endIcon";
|
|
2529
|
-
let c = o[s], l =
|
|
2529
|
+
let c = o[s], l = qt(W({
|
|
2530
2530
|
elementType: c,
|
|
2531
|
-
externalSlotProps: (e) => Y({},
|
|
2531
|
+
externalSlotProps: (e) => Y({}, Fe(a[s], e), Fe(n?.[s], e)),
|
|
2532
2532
|
ownerState: {}
|
|
2533
|
-
}),
|
|
2533
|
+
}), Gr);
|
|
2534
2534
|
return c ? /*#__PURE__*/ (0, q.jsx)(c, Y({}, l)) : null;
|
|
2535
2535
|
}
|
|
2536
|
-
var
|
|
2536
|
+
var Jr = V("div", {
|
|
2537
2537
|
name: "MuiTreeItemDragAndDropOverlay",
|
|
2538
2538
|
slot: "Root",
|
|
2539
|
-
shouldForwardProp: (e) =>
|
|
2539
|
+
shouldForwardProp: (e) => Oe(e) && e !== "action"
|
|
2540
2540
|
})(({ theme: e }) => ({
|
|
2541
2541
|
position: "absolute",
|
|
2542
2542
|
left: 0,
|
|
@@ -2577,11 +2577,11 @@ var qr = H("div", {
|
|
|
2577
2577
|
}
|
|
2578
2578
|
]
|
|
2579
2579
|
}));
|
|
2580
|
-
function Jr(e) {
|
|
2581
|
-
return e.action == null ? null : /*#__PURE__*/ (0, q.jsx)(qr, Y({}, e));
|
|
2582
|
-
}
|
|
2583
2580
|
function Yr(e) {
|
|
2584
|
-
|
|
2581
|
+
return e.action == null ? null : /*#__PURE__*/ (0, q.jsx)(Jr, Y({}, e));
|
|
2582
|
+
}
|
|
2583
|
+
function Xr(e) {
|
|
2584
|
+
let { children: t, itemId: n, id: r } = e, { wrapItem: i, store: a } = Vt(), o = X(a, _n.treeItemIdAttribute, n, r);
|
|
2585
2585
|
return /*#__PURE__*/ (0, q.jsx)(K.Fragment, { children: i({
|
|
2586
2586
|
children: t,
|
|
2587
2587
|
itemId: n,
|
|
@@ -2589,7 +2589,7 @@ function Yr(e) {
|
|
|
2589
2589
|
idAttribute: o
|
|
2590
2590
|
}) });
|
|
2591
2591
|
}
|
|
2592
|
-
var
|
|
2592
|
+
var Zr = V("input", {
|
|
2593
2593
|
name: "MuiTreeItem",
|
|
2594
2594
|
slot: "LabelInput"
|
|
2595
2595
|
})(({ theme: e }) => Y({}, e.typography.body1, {
|
|
@@ -2600,7 +2600,7 @@ var Xr = H("input", {
|
|
|
2600
2600
|
padding: "0 2px",
|
|
2601
2601
|
boxSizing: "border-box",
|
|
2602
2602
|
"&:focus": { outline: `1px solid ${(e.vars || e).palette.primary.main}` }
|
|
2603
|
-
})),
|
|
2603
|
+
})), Qr = ["visible"], $r = [
|
|
2604
2604
|
"id",
|
|
2605
2605
|
"itemId",
|
|
2606
2606
|
"label",
|
|
@@ -2610,7 +2610,7 @@ var Xr = H("input", {
|
|
|
2610
2610
|
"slots",
|
|
2611
2611
|
"slotProps",
|
|
2612
2612
|
"classes"
|
|
2613
|
-
],
|
|
2613
|
+
], ei = Nt("MuiTreeItem"), ti = V("li", {
|
|
2614
2614
|
name: "MuiTreeItem",
|
|
2615
2615
|
slot: "Root"
|
|
2616
2616
|
})({
|
|
@@ -2618,10 +2618,10 @@ var Xr = H("input", {
|
|
|
2618
2618
|
margin: 0,
|
|
2619
2619
|
padding: 0,
|
|
2620
2620
|
outline: 0
|
|
2621
|
-
}),
|
|
2621
|
+
}), ni = V("div", {
|
|
2622
2622
|
name: "MuiTreeItem",
|
|
2623
2623
|
slot: "Content",
|
|
2624
|
-
shouldForwardProp: (e) =>
|
|
2624
|
+
shouldForwardProp: (e) => Oe(e) && e !== "status"
|
|
2625
2625
|
})(({ theme: e }) => ({
|
|
2626
2626
|
padding: e.spacing(.5, 1),
|
|
2627
2627
|
paddingLeft: `calc(${e.spacing(1)} + var(--TreeView-itemChildrenIndentation) * var(--TreeView-itemDepth))`,
|
|
@@ -2653,10 +2653,10 @@ var Xr = H("input", {
|
|
|
2653
2653
|
}
|
|
2654
2654
|
},
|
|
2655
2655
|
"&[data-selected][data-focused]": { backgroundColor: e.alpha((e.vars || e).palette.primary.main, `${(e.vars || e).palette.action.selectedOpacity} + ${(e.vars || e).palette.action.focusOpacity}`) }
|
|
2656
|
-
})),
|
|
2656
|
+
})), ri = V("div", {
|
|
2657
2657
|
name: "MuiTreeItem",
|
|
2658
2658
|
slot: "Label",
|
|
2659
|
-
shouldForwardProp: (e) =>
|
|
2659
|
+
shouldForwardProp: (e) => Oe(e) && e !== "editable"
|
|
2660
2660
|
})(({ theme: e }) => Y({
|
|
2661
2661
|
width: "100%",
|
|
2662
2662
|
boxSizing: "border-box",
|
|
@@ -2666,7 +2666,7 @@ var Xr = H("input", {
|
|
|
2666
2666
|
}, e.typography.body1, { variants: [{
|
|
2667
2667
|
props: ({ editable: e }) => e,
|
|
2668
2668
|
style: { paddingLeft: "2px" }
|
|
2669
|
-
}] })),
|
|
2669
|
+
}] })), ii = V("div", {
|
|
2670
2670
|
name: "MuiTreeItem",
|
|
2671
2671
|
slot: "IconContainer"
|
|
2672
2672
|
})({
|
|
@@ -2677,14 +2677,14 @@ var Xr = H("input", {
|
|
|
2677
2677
|
position: "relative",
|
|
2678
2678
|
cursor: "inherit",
|
|
2679
2679
|
"& svg": { fontSize: 18 }
|
|
2680
|
-
}),
|
|
2680
|
+
}), ai = V(ct, {
|
|
2681
2681
|
name: "MuiTreeItem",
|
|
2682
2682
|
slot: "GroupTransition",
|
|
2683
2683
|
overridesResolver: (e, t) => t.groupTransition
|
|
2684
2684
|
})({
|
|
2685
2685
|
margin: 0,
|
|
2686
2686
|
padding: 0
|
|
2687
|
-
}),
|
|
2687
|
+
}), oi = V("div", {
|
|
2688
2688
|
name: "MuiTreeItem",
|
|
2689
2689
|
slot: "ErrorIcon"
|
|
2690
2690
|
})({
|
|
@@ -2694,18 +2694,18 @@ var Xr = H("input", {
|
|
|
2694
2694
|
height: 7,
|
|
2695
2695
|
borderRadius: "50%",
|
|
2696
2696
|
backgroundColor: "red"
|
|
2697
|
-
}),
|
|
2697
|
+
}), si = V(We, {
|
|
2698
2698
|
name: "MuiTreeItem",
|
|
2699
2699
|
slot: "LoadingIcon"
|
|
2700
|
-
})({ color: "text.primary" }),
|
|
2701
|
-
let { visible: n } = e, r =
|
|
2702
|
-
return n ? /*#__PURE__*/ (0, q.jsx)(
|
|
2700
|
+
})({ color: "text.primary" }), ci = V(/*#__PURE__*/ K.forwardRef((e, t) => {
|
|
2701
|
+
let { visible: n } = e, r = qt(e, Qr);
|
|
2702
|
+
return n ? /*#__PURE__*/ (0, q.jsx)(St, Y({}, r, { ref: t })) : null;
|
|
2703
2703
|
}), {
|
|
2704
2704
|
name: "MuiTreeItem",
|
|
2705
2705
|
slot: "Checkbox"
|
|
2706
|
-
})({ padding: 0 }),
|
|
2707
|
-
let { classes: t } =
|
|
2708
|
-
return
|
|
2706
|
+
})({ padding: 0 }), li = (e) => {
|
|
2707
|
+
let { classes: t } = Ut();
|
|
2708
|
+
return je({
|
|
2709
2709
|
root: ["root"],
|
|
2710
2710
|
content: ["content"],
|
|
2711
2711
|
iconContainer: ["iconContainer"],
|
|
@@ -2716,30 +2716,30 @@ var Xr = H("input", {
|
|
|
2716
2716
|
dragAndDropOverlay: ["dragAndDropOverlay"],
|
|
2717
2717
|
errorIcon: ["errorIcon"],
|
|
2718
2718
|
loadingIcon: ["loadingIcon"]
|
|
2719
|
-
},
|
|
2720
|
-
root:
|
|
2721
|
-
content:
|
|
2722
|
-
iconContainer:
|
|
2723
|
-
checkbox:
|
|
2724
|
-
label:
|
|
2725
|
-
groupTransition:
|
|
2726
|
-
labelInput:
|
|
2727
|
-
dragAndDropOverlay:
|
|
2728
|
-
errorIcon:
|
|
2729
|
-
loadingIcon:
|
|
2719
|
+
}, Hr, Y({}, e, {
|
|
2720
|
+
root: M(e?.root, t.root),
|
|
2721
|
+
content: M(e?.content, t.itemContent),
|
|
2722
|
+
iconContainer: M(e?.iconContainer, t.itemIconContainer),
|
|
2723
|
+
checkbox: M(e?.checkbox, t.itemCheckbox),
|
|
2724
|
+
label: M(e?.label, t.itemLabel),
|
|
2725
|
+
groupTransition: M(e?.groupTransition, t.itemGroupTransition),
|
|
2726
|
+
labelInput: M(e?.labelInput, t.itemLabelInput),
|
|
2727
|
+
dragAndDropOverlay: M(e?.dragAndDropOverlay, t.itemDragAndDropOverlay),
|
|
2728
|
+
errorIcon: M(e?.errorIcon, t.itemErrorIcon),
|
|
2729
|
+
loadingIcon: M(e?.loadingIcon, t.itemLoadingIcon)
|
|
2730
2730
|
}));
|
|
2731
|
-
},
|
|
2732
|
-
let n =
|
|
2731
|
+
}, ui = /*#__PURE__*/ K.forwardRef(function(e, t) {
|
|
2732
|
+
let n = ei({
|
|
2733
2733
|
props: e,
|
|
2734
2734
|
name: "MuiTreeItem"
|
|
2735
|
-
}), { id: r, itemId: i, label: a, disabled: o, disableSelection: s, children: c, slots: l = {}, slotProps: u = {}, classes: d } = n, f =
|
|
2735
|
+
}), { id: r, itemId: i, label: a, disabled: o, disableSelection: s, children: c, slots: l = {}, slotProps: u = {}, classes: d } = n, f = qt(n, $r), { getContextProviderProps: p, getRootProps: m, getContentProps: h, getIconContainerProps: g, getCheckboxProps: _, getLabelProps: v, getGroupTransitionProps: y, getLabelInputProps: b, getDragAndDropOverlayProps: x, getErrorContainerProps: S, getLoadingContainerProps: C, status: w } = Vr({
|
|
2736
2736
|
id: r,
|
|
2737
2737
|
itemId: i,
|
|
2738
2738
|
children: c,
|
|
2739
2739
|
label: a,
|
|
2740
2740
|
disabled: o,
|
|
2741
2741
|
disableSelection: s
|
|
2742
|
-
}), T =
|
|
2742
|
+
}), T = li(d), E = l.root ?? ti, D = W({
|
|
2743
2743
|
elementType: E,
|
|
2744
2744
|
getSlotProps: m,
|
|
2745
2745
|
externalForwardedProps: f,
|
|
@@ -2747,25 +2747,25 @@ var Xr = H("input", {
|
|
|
2747
2747
|
additionalProps: { ref: t },
|
|
2748
2748
|
ownerState: {},
|
|
2749
2749
|
className: T.root
|
|
2750
|
-
}), O = l.content ??
|
|
2750
|
+
}), O = l.content ?? ni, k = W({
|
|
2751
2751
|
elementType: O,
|
|
2752
2752
|
getSlotProps: h,
|
|
2753
2753
|
externalSlotProps: u.content,
|
|
2754
2754
|
ownerState: {},
|
|
2755
2755
|
className: T.content
|
|
2756
|
-
}), A = l.iconContainer ??
|
|
2756
|
+
}), A = l.iconContainer ?? ii, j = W({
|
|
2757
2757
|
elementType: A,
|
|
2758
2758
|
getSlotProps: g,
|
|
2759
2759
|
externalSlotProps: u.iconContainer,
|
|
2760
2760
|
ownerState: {},
|
|
2761
2761
|
className: T.iconContainer
|
|
2762
|
-
}), M = l.label ??
|
|
2762
|
+
}), M = l.label ?? ri, N = W({
|
|
2763
2763
|
elementType: M,
|
|
2764
2764
|
getSlotProps: v,
|
|
2765
2765
|
externalSlotProps: u.label,
|
|
2766
2766
|
ownerState: {},
|
|
2767
2767
|
className: T.label
|
|
2768
|
-
}), P = l.checkbox ??
|
|
2768
|
+
}), P = l.checkbox ?? ci, F = W({
|
|
2769
2769
|
elementType: P,
|
|
2770
2770
|
getSlotProps: _,
|
|
2771
2771
|
externalSlotProps: u.checkbox,
|
|
@@ -2777,45 +2777,45 @@ var Xr = H("input", {
|
|
|
2777
2777
|
externalSlotProps: u.groupTransition,
|
|
2778
2778
|
ownerState: {},
|
|
2779
2779
|
className: T.groupTransition
|
|
2780
|
-
}), R = l.labelInput ??
|
|
2780
|
+
}), R = l.labelInput ?? Zr, ee = W({
|
|
2781
2781
|
elementType: R,
|
|
2782
2782
|
getSlotProps: b,
|
|
2783
2783
|
externalSlotProps: u.labelInput,
|
|
2784
2784
|
ownerState: {},
|
|
2785
2785
|
className: T.labelInput
|
|
2786
|
-
}),
|
|
2787
|
-
elementType:
|
|
2786
|
+
}), te = l.dragAndDropOverlay ?? Yr, z = W({
|
|
2787
|
+
elementType: te,
|
|
2788
2788
|
getSlotProps: x,
|
|
2789
2789
|
externalSlotProps: u.dragAndDropOverlay,
|
|
2790
2790
|
ownerState: {},
|
|
2791
2791
|
className: T.dragAndDropOverlay
|
|
2792
|
-
}), ne = l.errorIcon ??
|
|
2792
|
+
}), ne = l.errorIcon ?? oi, re = W({
|
|
2793
2793
|
elementType: ne,
|
|
2794
2794
|
getSlotProps: S,
|
|
2795
2795
|
externalSlotProps: u.errorIcon,
|
|
2796
2796
|
ownerState: {},
|
|
2797
2797
|
className: T.errorIcon
|
|
2798
|
-
}),
|
|
2799
|
-
elementType:
|
|
2798
|
+
}), ie = l.loadingIcon ?? si, B = W({
|
|
2799
|
+
elementType: ie,
|
|
2800
2800
|
getSlotProps: C,
|
|
2801
2801
|
externalSlotProps: u.loadingIcon,
|
|
2802
2802
|
ownerState: {},
|
|
2803
2803
|
className: T.loadingIcon
|
|
2804
2804
|
});
|
|
2805
|
-
return /*#__PURE__*/ (0, q.jsx)(
|
|
2806
|
-
/*#__PURE__*/ (0, q.jsxs)(A, Y({}, j, { children: [w.error && /*#__PURE__*/ (0, q.jsx)(ne, Y({}, re)), w.loading ? /*#__PURE__*/ (0, q.jsx)(
|
|
2805
|
+
return /*#__PURE__*/ (0, q.jsx)(Xr, Y({}, p(), { children: /*#__PURE__*/ (0, q.jsxs)(E, Y({}, D, { children: [/*#__PURE__*/ (0, q.jsxs)(O, Y({}, k, { children: [
|
|
2806
|
+
/*#__PURE__*/ (0, q.jsxs)(A, Y({}, j, { children: [w.error && /*#__PURE__*/ (0, q.jsx)(ne, Y({}, re)), w.loading ? /*#__PURE__*/ (0, q.jsx)(ie, Y({}, B)) : /*#__PURE__*/ (0, q.jsx)(qr, {
|
|
2807
2807
|
status: w,
|
|
2808
2808
|
slots: l,
|
|
2809
2809
|
slotProps: u
|
|
2810
2810
|
})] })),
|
|
2811
2811
|
/*#__PURE__*/ (0, q.jsx)(P, Y({}, F)),
|
|
2812
2812
|
w.editing ? /*#__PURE__*/ (0, q.jsx)(R, Y({}, ee)) : /*#__PURE__*/ (0, q.jsx)(M, Y({}, N)),
|
|
2813
|
-
/*#__PURE__*/ (0, q.jsx)(
|
|
2814
|
-
] })), c && /*#__PURE__*/ (0, q.jsx)(
|
|
2815
|
-
}),
|
|
2813
|
+
/*#__PURE__*/ (0, q.jsx)(te, Y({}, z))
|
|
2814
|
+
] })), c && /*#__PURE__*/ (0, q.jsx)(ai, Y({ as: I }, L))] })) }));
|
|
2815
|
+
}), di = "5px", fi = (e) => ({ "& > .MuiTreeItem-content": {
|
|
2816
2816
|
backgroundColor: `${e} !important`,
|
|
2817
|
-
borderRadius:
|
|
2818
|
-
} }),
|
|
2817
|
+
borderRadius: di
|
|
2818
|
+
} }), pi = (e, t) => ({
|
|
2819
2819
|
width: "100%",
|
|
2820
2820
|
minWidth: 0,
|
|
2821
2821
|
"& .MuiTreeItem-groupTransition": {
|
|
@@ -2829,11 +2829,11 @@ var Xr = H("input", {
|
|
|
2829
2829
|
},
|
|
2830
2830
|
"& .MuiTreeItem-content:hover": {
|
|
2831
2831
|
backgroundColor: `${e} !important`,
|
|
2832
|
-
borderRadius:
|
|
2832
|
+
borderRadius: di
|
|
2833
2833
|
},
|
|
2834
2834
|
"& .MuiTreeItem-content:hover .MuiTreeItem-iconContainer:has(svg)": {
|
|
2835
2835
|
backgroundColor: e,
|
|
2836
|
-
borderRadius:
|
|
2836
|
+
borderRadius: di
|
|
2837
2837
|
},
|
|
2838
2838
|
...t && {
|
|
2839
2839
|
[G.sm]: { "& .MuiTreeItem-iconContainer": {
|
|
@@ -2851,14 +2851,14 @@ var Xr = H("input", {
|
|
|
2851
2851
|
}
|
|
2852
2852
|
} }
|
|
2853
2853
|
}
|
|
2854
|
-
}),
|
|
2854
|
+
}), mi = (e, t, n) => {
|
|
2855
2855
|
let r = n[t] ?? [];
|
|
2856
2856
|
return [...e].sort(([, e], [, t]) => {
|
|
2857
2857
|
let n = Number(r.includes(t.value)) - Number(r.includes(e.value)), i = Number(e.disabled) - Number(t.disabled);
|
|
2858
2858
|
return n || i;
|
|
2859
2859
|
});
|
|
2860
|
-
},
|
|
2861
|
-
let [
|
|
2860
|
+
}, hi = ({ filterValues: e, filterDimensionsCount: t, searchTerm: n, isLoading: r = !1, isPreview: i, isFieldLocked: o, hoverColor: s, filterFontSize: l, filterFontColor: u, vSpec: d, dimensionSelectionMethods: f, selectionMode: p }) => {
|
|
2861
|
+
let [m, h] = (0, K.useState)([]), g = j(f.map(({ field: e, fieldKey: t }) => e ?? { fieldKey: t })), _ = d.dimensions.filter((e) => e.role === a.FILTER_DIMENSION), v = d.dimensions.find((e) => e.role === a.FILTER_IMAGE) ?? (d.dimensions.every((e) => !e.role) ? d.dimensions[1] : void 0), y = e.reduce((e, t) => typeof t.measure1 == "number" ? e === null ? t.measure1 : Math.max(e, t.measure1) : e, null), S = (0, K.useMemo)(() => {
|
|
2862
2862
|
let t = /* @__PURE__ */ new Map();
|
|
2863
2863
|
return e.forEach(({ dimension: e, childDimension: n, dimensionValues: r, disabled: i, image: a, measure1: o, measure2: s }) => {
|
|
2864
2864
|
let c = r ?? [e, ...n === void 0 ? [] : [n]], l = c.length;
|
|
@@ -2875,66 +2875,66 @@ var Xr = H("input", {
|
|
|
2875
2875
|
}
|
|
2876
2876
|
d && (o != null || s != null) && (d.measure1 = o, d.measure2 = s), d && a && (d.image = a);
|
|
2877
2877
|
}), Array.from(t.entries());
|
|
2878
|
-
}, [e]),
|
|
2878
|
+
}, [e]), C = (0, K.useMemo)(() => {
|
|
2879
2879
|
let e = /* @__PURE__ */ new Map(), t = (e) => `tree-${encodeURIComponent(JSON.stringify(e))}`, n = (r, i) => {
|
|
2880
2880
|
let a = t(i);
|
|
2881
2881
|
e.set(a, r), Array.from(r.children.entries()).forEach(([e, t]) => {
|
|
2882
2882
|
n(t, [...i, e]);
|
|
2883
2883
|
});
|
|
2884
2884
|
};
|
|
2885
|
-
return
|
|
2886
|
-
}, [
|
|
2885
|
+
return S.forEach(([e, t]) => n(t, [e])), e;
|
|
2886
|
+
}, [S]);
|
|
2887
2887
|
(0, K.useEffect)(() => {
|
|
2888
|
-
!n || r ||
|
|
2888
|
+
!n || r || h(Array.from(C.entries()).filter(([, e]) => e.children.size > 0).map(([e]) => e));
|
|
2889
2889
|
}, [
|
|
2890
2890
|
r,
|
|
2891
2891
|
n,
|
|
2892
|
-
|
|
2892
|
+
C
|
|
2893
2893
|
]), (0, K.useEffect)(() => {
|
|
2894
|
-
n ||
|
|
2894
|
+
n || h([]);
|
|
2895
2895
|
}, [n]);
|
|
2896
|
-
let
|
|
2897
|
-
|
|
2898
|
-
},
|
|
2899
|
-
if (p ===
|
|
2900
|
-
let n =
|
|
2896
|
+
let w = (e, t) => {
|
|
2897
|
+
h(t);
|
|
2898
|
+
}, T = f.map((e) => e?.state.pending ?? e?.state.applied ?? []), E = f.map((e) => e?.state.applied ?? []), D = (e, n, r, i = T) => {
|
|
2899
|
+
if (p === c.AllLevels && r.some((e, t) => {
|
|
2900
|
+
let n = i[t] ?? [];
|
|
2901
2901
|
return (f[t]?.operators.pending ?? f[t]?.operators.applied) !== J.FilterOperator.NotInList && n.length > 0 && !n.includes(e.value);
|
|
2902
2902
|
})) return "none";
|
|
2903
|
-
if (n === t - 1) return
|
|
2904
|
-
let
|
|
2905
|
-
return
|
|
2906
|
-
},
|
|
2907
|
-
let n =
|
|
2903
|
+
if (n === t - 1) return i[n]?.includes(e.value) ? "full" : "none";
|
|
2904
|
+
let a = Array.from(e.children.values()).map((t) => D(t, n + 1, [...r, e], i));
|
|
2905
|
+
return a.length > 0 && a.every((e) => e === "full") ? "full" : a.some((e) => e !== "none") ? "partial" : "none";
|
|
2906
|
+
}, O = (e) => e.some((e, t) => {
|
|
2907
|
+
let n = E[t] ?? [];
|
|
2908
2908
|
return f[t]?.operators.applied !== J.FilterOperator.NotInList && n.length > 0 && !n.includes(e.value);
|
|
2909
|
-
}),
|
|
2910
|
-
let m = `tree-${encodeURIComponent(JSON.stringify(
|
|
2909
|
+
}), k = (e, r, a, u) => {
|
|
2910
|
+
let m = `tree-${encodeURIComponent(JSON.stringify(a))}`, h = r < t - 1 && !!_[r]?.expandOnly, b = mi(Array.from(e.children.entries()), r + 1, E), x = b.length > 0, C = O(u), w = D(e, r, u), A = w !== "full", j = p === c.AllLevels, M = /* @__PURE__ */ new Map(), N = (e, t) => {
|
|
2911
2911
|
let n = M.get(t) ?? /* @__PURE__ */ new Set();
|
|
2912
2912
|
n.add(e), M.set(t, n);
|
|
2913
2913
|
};
|
|
2914
2914
|
j && A && u.forEach((e, t) => {
|
|
2915
|
-
|
|
2915
|
+
_[t]?.expandOnly || N(e.value, t);
|
|
2916
2916
|
});
|
|
2917
2917
|
let P = (e, n) => {
|
|
2918
2918
|
if (e.disabled) return !1;
|
|
2919
2919
|
let r = n === t - 1, i = !r && Array.from(e.children.values()).map((e) => P(e, n + 1)).some(Boolean);
|
|
2920
|
-
return !r && !i ? !1 : ((r || j && !
|
|
2921
|
-
}, F = P(e, r), I = A && Array.from(M).some(([e, t]) =>
|
|
2922
|
-
return /* @__PURE__ */ (0, q.jsx)(
|
|
2920
|
+
return !r && !i ? !1 : ((r || j && !_[n]?.expandOnly) && N(e.value, n), !0);
|
|
2921
|
+
}, F = P(e, r), I = A && Array.from(M).some(([e, t]) => g[e] && t.size > 1), L = !F || e.disabled || C || o || !!i || I, R = (!F || e.disabled || C) && !x || o || !!i;
|
|
2922
|
+
return /* @__PURE__ */ (0, q.jsx)(ui, {
|
|
2923
2923
|
itemId: m,
|
|
2924
2924
|
disabled: R,
|
|
2925
|
-
sx:
|
|
2925
|
+
sx: w === "full" ? fi(s) : {},
|
|
2926
2926
|
"data-testid": `${e.label}-tree-item`,
|
|
2927
|
-
label: /* @__PURE__ */ (0, q.jsx)(
|
|
2928
|
-
selected:
|
|
2927
|
+
label: /* @__PURE__ */ (0, q.jsx)(Se, {
|
|
2928
|
+
selected: w === "full",
|
|
2929
2929
|
applied: !1,
|
|
2930
2930
|
disabled: L,
|
|
2931
2931
|
hoverColor: s,
|
|
2932
2932
|
onSelect: h ? void 0 : (e) => {
|
|
2933
2933
|
if (e.stopPropagation(), !L) {
|
|
2934
2934
|
if (j && !A) {
|
|
2935
|
-
let e =
|
|
2935
|
+
let e = T.map((e, t) => g[t] ? e : e.filter((e) => !M.get(t)?.has(e))), n = /* @__PURE__ */ new Map(), r = (i, a, o) => {
|
|
2936
2936
|
if (a === t - 1) {
|
|
2937
|
-
|
|
2937
|
+
D(i, a, o, e) === "full" && o.forEach((e, t) => {
|
|
2938
2938
|
let r = n.get(t) ?? /* @__PURE__ */ new Set();
|
|
2939
2939
|
r.add(e.value), n.set(t, r);
|
|
2940
2940
|
});
|
|
@@ -2942,13 +2942,13 @@ var Xr = H("input", {
|
|
|
2942
2942
|
}
|
|
2943
2943
|
i.children.forEach((e) => r(e, a + 1, [...o, i]));
|
|
2944
2944
|
};
|
|
2945
|
-
|
|
2946
|
-
!
|
|
2945
|
+
S.forEach(([, e]) => r(e, 0, [])), u.forEach((e, t) => {
|
|
2946
|
+
!_[t]?.expandOnly && !n.get(t)?.has(e.value) && N(e.value, t);
|
|
2947
2947
|
});
|
|
2948
2948
|
}
|
|
2949
2949
|
M.forEach((e, t) => {
|
|
2950
|
-
if (!A &&
|
|
2951
|
-
let n =
|
|
2950
|
+
if (!A && g[t]) return;
|
|
2951
|
+
let n = T[t] ?? [], r = Array.from(e).filter((e) => n.includes(e) !== A);
|
|
2952
2952
|
r.length && f[t]?.onClickValues(r, {
|
|
2953
2953
|
on: A,
|
|
2954
2954
|
off: !A
|
|
@@ -2959,60 +2959,60 @@ var Xr = H("input", {
|
|
|
2959
2959
|
showProgressBar: d.filterSettings?.showProgressBar,
|
|
2960
2960
|
showCheckbox: !h,
|
|
2961
2961
|
showSelectionIcon: !h,
|
|
2962
|
-
checkboxState:
|
|
2962
|
+
checkboxState: w,
|
|
2963
2963
|
dimensionValue: e.value,
|
|
2964
|
-
dimensionFormatter:
|
|
2964
|
+
dimensionFormatter: _[r]?.formatter,
|
|
2965
2965
|
measure1Value: e.measure1,
|
|
2966
2966
|
measure1Label: d.measures[0]?.filterValueLabel,
|
|
2967
2967
|
measure1Formatter: d.measures[0]?.formatter,
|
|
2968
2968
|
measure2Value: e.measure2,
|
|
2969
2969
|
measure2Label: d.measures[1]?.filterValueLabel,
|
|
2970
2970
|
measure2Formatter: d.measures[1]?.formatter,
|
|
2971
|
-
maxValue:
|
|
2971
|
+
maxValue: y,
|
|
2972
2972
|
imageValue: e.image,
|
|
2973
|
-
imageFit:
|
|
2973
|
+
imageFit: v?.imageFit,
|
|
2974
2974
|
searchTerm: n,
|
|
2975
2975
|
fontStyle: d.filterSettings?.fontStyle,
|
|
2976
2976
|
fontSize: l,
|
|
2977
2977
|
progressBarColor: d.filterSettings?.filterStyle?.progressBarColor,
|
|
2978
2978
|
responsive: d?.filterSettings?.responsive
|
|
2979
2979
|
}),
|
|
2980
|
-
children:
|
|
2980
|
+
children: b.map(([t, n]) => k(n, r + 1, [...a, t], [...u, e]))
|
|
2981
2981
|
}, m);
|
|
2982
2982
|
};
|
|
2983
|
-
return /* @__PURE__ */ (0, q.jsx)(
|
|
2983
|
+
return /* @__PURE__ */ (0, q.jsx)(zr, {
|
|
2984
2984
|
"aria-label": "Filter values",
|
|
2985
2985
|
itemChildrenIndentation: 0,
|
|
2986
2986
|
slots: {
|
|
2987
|
-
collapseIcon: () => /* @__PURE__ */ (0, q.jsx)(
|
|
2987
|
+
collapseIcon: () => /* @__PURE__ */ (0, q.jsx)(x, {
|
|
2988
2988
|
size: l,
|
|
2989
2989
|
fill: u,
|
|
2990
2990
|
"data-testid": "collapse-icon"
|
|
2991
2991
|
}),
|
|
2992
|
-
expandIcon: () => /* @__PURE__ */ (0, q.jsx)(
|
|
2992
|
+
expandIcon: () => /* @__PURE__ */ (0, q.jsx)(b, {
|
|
2993
2993
|
size: l,
|
|
2994
2994
|
fill: u,
|
|
2995
2995
|
"data-testid": "expand-icon"
|
|
2996
2996
|
})
|
|
2997
2997
|
},
|
|
2998
|
-
sx:
|
|
2999
|
-
expandedItems:
|
|
2998
|
+
sx: pi(s, d?.filterSettings?.responsive),
|
|
2999
|
+
expandedItems: m,
|
|
3000
3000
|
selectedItems: null,
|
|
3001
|
-
onExpandedItemsChange:
|
|
3002
|
-
children:
|
|
3001
|
+
onExpandedItemsChange: w,
|
|
3002
|
+
children: mi(S, 0, E).map(([e, t]) => k(t, 0, [e], []))
|
|
3003
3003
|
});
|
|
3004
|
-
},
|
|
3005
|
-
borderBottom: `1px solid ${
|
|
3004
|
+
}, gi = {
|
|
3005
|
+
borderBottom: `1px solid ${i.grey5}`,
|
|
3006
3006
|
margin: "0 12px",
|
|
3007
3007
|
width: "calc(100% - 24px)"
|
|
3008
|
-
},
|
|
3008
|
+
}, _i = {
|
|
3009
3009
|
flexGrow: 1,
|
|
3010
3010
|
borderRadius: 0,
|
|
3011
3011
|
height: 28,
|
|
3012
3012
|
boxShadow: "0 3px 6px rgba(0, 0, 0, 0.2)",
|
|
3013
3013
|
clipPath: "inset(0 0 -10px 0)",
|
|
3014
3014
|
transform: "translateY(-3px)"
|
|
3015
|
-
},
|
|
3015
|
+
}, vi = {
|
|
3016
3016
|
position: "absolute",
|
|
3017
3017
|
inset: 0,
|
|
3018
3018
|
display: "flex",
|
|
@@ -3020,159 +3020,159 @@ var Xr = H("input", {
|
|
|
3020
3020
|
alignItems: "flex-end",
|
|
3021
3021
|
pointerEvents: "auto",
|
|
3022
3022
|
zIndex: 2
|
|
3023
|
-
},
|
|
3024
|
-
let
|
|
3023
|
+
}, yi = ({ vSpec: e, vTheme: r, filterValues: o, isPreview: s = !1, loadMoreData: c, searchTerm: u, setSearchTerm: p, allValuesLoaded: m, isSearching: g = !1, isApplyingFilters: _ = !1 }) => {
|
|
3024
|
+
let v = r ?? d, y = D(), [b, x] = (0, K.useState)(u), S = !!e.filterSettings?.defaultNotState, C = e.filterSettings?.selectionMode ?? n.selectionMode, [w, T] = (0, K.useState)(S), [E, k] = pe(e), A = (0, K.useMemo)(() => (0, wt.default)((e) => p(e), 300), [p]), j = o.reduce((e, t) => (t.disabled || e.push(t.dimension), e), []), M = e.dimensions.filter((e) => e.role === a.FILTER_DIMENSION), N = M[0] ?? e.dimensions[0], P = M.length > 1, R = s ? [] : M.length > 0 ? M.map((e, t) => ({
|
|
3025
3025
|
dataItem: e.dataItem,
|
|
3026
3026
|
dateLevel: e.dateLevel ?? void 0,
|
|
3027
3027
|
datePart: e.datePart ?? void 0,
|
|
3028
|
-
values:
|
|
3028
|
+
values: o.map((e) => e.dimensionValues ? e.dimensionValues[t] : [e.dimension, e.childDimension][t]).filter((e) => e !== void 0)
|
|
3029
3029
|
})) : [{
|
|
3030
|
-
dataItem:
|
|
3031
|
-
dateLevel:
|
|
3032
|
-
datePart:
|
|
3033
|
-
values:
|
|
3034
|
-
}], { hasImage:
|
|
3030
|
+
dataItem: N?.dataItem,
|
|
3031
|
+
dateLevel: N?.dateLevel ?? void 0,
|
|
3032
|
+
datePart: N?.datePart ?? void 0,
|
|
3033
|
+
values: j
|
|
3034
|
+
}], { hasImage: ee, hasMeasure: te, searchEnabled: z, quickSelection: ne } = Ct(e), re = e.filterSettings?.filterStyle, { backgroundColor: ie, ...B } = re ?? {}, se = re && {
|
|
3035
3035
|
...B,
|
|
3036
|
-
..."backgroundColor" in
|
|
3037
|
-
},
|
|
3038
|
-
...
|
|
3039
|
-
"--background-color":
|
|
3040
|
-
})["--background-color-hover"] ??
|
|
3041
|
-
disabled:
|
|
3042
|
-
state:
|
|
3036
|
+
..."backgroundColor" in re ? { backgroundColor: ie ?? void 0 } : {}
|
|
3037
|
+
}, ce = e.filterSettings?.filterStyle?.backgroundColor ?? t.backgroundColor, ue = e.filterSettings?.fontStyle?.fontSize ?? t.fontSize, me = l(v, e.filterSettings?.fontStyle?.fontColor), he = oe({
|
|
3038
|
+
...ae,
|
|
3039
|
+
"--background-color": ce
|
|
3040
|
+
})["--background-color-hover"] ?? i.grey3, ve = O(R, {
|
|
3041
|
+
disabled: s,
|
|
3042
|
+
state: ne ? J.SelectionState.APPLIED : void 0,
|
|
3043
3043
|
defaultOperator: w ? J.FilterOperator.NotInList : J.FilterOperator.InList,
|
|
3044
|
-
commitHistory:
|
|
3045
|
-
}), { onClear:
|
|
3044
|
+
commitHistory: ne
|
|
3045
|
+
}), { onClear: Se, onClick: Ce, onDeselectAll: we, onSelectExcluded: Te, onNotOperatorChange: Ee, onSelectAll: De, field: V, state: H, operators: Oe } = ve[0] ?? F, { isFieldLocked: ke = !1, toggleFieldLock: Ae } = L(V ?? void 0), je = H.pending ?? H.applied ?? [], Me = I(V ? [V] : []);
|
|
3046
3046
|
(0, K.useEffect)(() => {
|
|
3047
|
-
let e =
|
|
3047
|
+
let e = Oe.pending ?? Oe.applied;
|
|
3048
3048
|
if (e) {
|
|
3049
3049
|
T(e === J.FilterOperator.NotInList);
|
|
3050
3050
|
return;
|
|
3051
3051
|
}
|
|
3052
3052
|
T(S);
|
|
3053
|
-
}, [S,
|
|
3054
|
-
let
|
|
3055
|
-
T((e) => !e),
|
|
3056
|
-
}, [T,
|
|
3057
|
-
function
|
|
3058
|
-
|
|
3053
|
+
}, [S, Oe]);
|
|
3054
|
+
let Ne = (0, K.useCallback)(() => {
|
|
3055
|
+
T((e) => !e), Ee();
|
|
3056
|
+
}, [T, Ee]);
|
|
3057
|
+
function Pe() {
|
|
3058
|
+
m ? De() : y.daedalus.emitEvent(J.AstratoEvents.SHOW_GLOBAL_NOTIFICATION, {
|
|
3059
3059
|
type: "warn",
|
|
3060
3060
|
message: "Cannot select values, because not all of them are loaded!"
|
|
3061
3061
|
});
|
|
3062
3062
|
}
|
|
3063
|
-
let
|
|
3063
|
+
let Fe = ke || _ && !P || g, U = (0, K.useRef)(null);
|
|
3064
3064
|
(0, K.useEffect)(() => {
|
|
3065
|
-
U.current?.toggleAttribute("inert",
|
|
3066
|
-
}, [
|
|
3067
|
-
let
|
|
3068
|
-
|
|
3069
|
-
|
|
3070
|
-
|
|
3071
|
-
|
|
3065
|
+
U.current?.toggleAttribute("inert", Fe);
|
|
3066
|
+
}, [Fe]);
|
|
3067
|
+
let Ie = (0, K.useMemo)(() => ke ? o.filter((e) => (H.pending ?? H.applied ?? []).includes(e.dimension)) : o, [
|
|
3068
|
+
o,
|
|
3069
|
+
ke,
|
|
3070
|
+
H.pending,
|
|
3071
|
+
H.applied
|
|
3072
3072
|
]);
|
|
3073
3073
|
return /* @__PURE__ */ (0, q.jsx)("div", {
|
|
3074
3074
|
style: {
|
|
3075
3075
|
position: "relative",
|
|
3076
3076
|
height: "100%"
|
|
3077
3077
|
},
|
|
3078
|
-
children: /* @__PURE__ */ (0, q.jsx)(
|
|
3078
|
+
children: /* @__PURE__ */ (0, q.jsx)(xe, {
|
|
3079
3079
|
blurBackground: !0,
|
|
3080
|
-
filterStyle:
|
|
3081
|
-
fontSize: e.filterSettings?.fontStyle?.fontSize ??
|
|
3082
|
-
children: /* @__PURE__ */ (0, q.jsxs)(
|
|
3083
|
-
value: {
|
|
3084
|
-
appliedOperator:
|
|
3085
|
-
pendingOperator:
|
|
3086
|
-
},
|
|
3080
|
+
filterStyle: se,
|
|
3081
|
+
fontSize: e.filterSettings?.fontStyle?.fontSize ?? t.fontSize,
|
|
3082
|
+
children: /* @__PURE__ */ (0, q.jsxs)(fe.Provider, {
|
|
3083
|
+
value: f({
|
|
3084
|
+
appliedOperator: Oe.applied,
|
|
3085
|
+
pendingOperator: Oe.pending
|
|
3086
|
+
}),
|
|
3087
3087
|
children: [
|
|
3088
|
-
/* @__PURE__ */ (0, q.jsx)(
|
|
3089
|
-
measureTitle:
|
|
3090
|
-
dimensionTitle:
|
|
3091
|
-
searchEnabled: z && !
|
|
3092
|
-
searchTerm:
|
|
3088
|
+
/* @__PURE__ */ (0, q.jsx)(ye, {
|
|
3089
|
+
measureTitle: k ?? "",
|
|
3090
|
+
dimensionTitle: E,
|
|
3091
|
+
searchEnabled: z && !s,
|
|
3092
|
+
searchTerm: b,
|
|
3093
3093
|
onSearchChange: (e) => {
|
|
3094
|
-
x(e),
|
|
3094
|
+
x(e), A(e);
|
|
3095
3095
|
},
|
|
3096
|
-
onApplySearched:
|
|
3096
|
+
onApplySearched: Pe,
|
|
3097
3097
|
fontStyle: e.filterSettings?.fontStyle ?? {},
|
|
3098
|
-
vTheme:
|
|
3098
|
+
vTheme: v,
|
|
3099
3099
|
isNotEnabled: w,
|
|
3100
3100
|
responsive: e?.filterSettings?.responsive,
|
|
3101
|
-
isLocked:
|
|
3102
|
-
children:
|
|
3103
|
-
isPreview:
|
|
3101
|
+
isLocked: ke,
|
|
3102
|
+
children: ne ? null : /* @__PURE__ */ (0, q.jsx)(Et, {
|
|
3103
|
+
isPreview: s,
|
|
3104
3104
|
responsive: e?.filterSettings?.responsive,
|
|
3105
|
-
areSelectedValues:
|
|
3106
|
-
arePendingValues: !!
|
|
3107
|
-
onClear:
|
|
3108
|
-
onDeselectAll:
|
|
3109
|
-
onSelectExcluded:
|
|
3110
|
-
onSelectAll:
|
|
3111
|
-
toggleNotOperator:
|
|
3112
|
-
onLockClick:
|
|
3105
|
+
areSelectedValues: je.length > 0,
|
|
3106
|
+
arePendingValues: !!H.pending,
|
|
3107
|
+
onClear: Se,
|
|
3108
|
+
onDeselectAll: we,
|
|
3109
|
+
onSelectExcluded: Te,
|
|
3110
|
+
onSelectAll: De,
|
|
3111
|
+
toggleNotOperator: Ne,
|
|
3112
|
+
onLockClick: Ae,
|
|
3113
3113
|
isNotEnabled: w,
|
|
3114
|
-
isSingleSelectField:
|
|
3114
|
+
isSingleSelectField: Me
|
|
3115
3115
|
})
|
|
3116
3116
|
}),
|
|
3117
|
-
|
|
3117
|
+
g ? /* @__PURE__ */ (0, q.jsx)(le, { loading: !0 }) : /* @__PURE__ */ (0, q.jsx)("div", { style: gi }),
|
|
3118
3118
|
/* @__PURE__ */ (0, q.jsx)("div", {
|
|
3119
3119
|
ref: U,
|
|
3120
3120
|
style: {
|
|
3121
3121
|
height: "100%",
|
|
3122
|
-
opacity:
|
|
3123
|
-
pointerEvents:
|
|
3122
|
+
opacity: Fe ? .5 : 1,
|
|
3123
|
+
pointerEvents: Fe ? "none" : void 0,
|
|
3124
3124
|
transition: "opacity 0.15s ease"
|
|
3125
3125
|
},
|
|
3126
|
-
children: /* @__PURE__ */ (0, q.jsxs)(
|
|
3127
|
-
loadMoreData:
|
|
3126
|
+
children: /* @__PURE__ */ (0, q.jsxs)(_e, {
|
|
3127
|
+
loadMoreData: c,
|
|
3128
3128
|
responsive: e?.filterSettings?.responsive,
|
|
3129
|
-
children: [
|
|
3129
|
+
children: [m && Ie.length === 0 && !g && !_ ? /* @__PURE__ */ (0, q.jsx)(de, {
|
|
3130
3130
|
responsive: e?.filterSettings?.responsive,
|
|
3131
3131
|
applied: !1,
|
|
3132
3132
|
disabled: !1,
|
|
3133
3133
|
selected: !1,
|
|
3134
|
-
hoverColor:
|
|
3134
|
+
hoverColor: he,
|
|
3135
3135
|
fontStyle: e.filterSettings?.fontStyle,
|
|
3136
3136
|
dimensionValue: "No results to display."
|
|
3137
|
-
}) : null,
|
|
3138
|
-
filterValues:
|
|
3139
|
-
filterDimensionsCount:
|
|
3140
|
-
searchTerm:
|
|
3141
|
-
isLoading:
|
|
3142
|
-
isPreview:
|
|
3143
|
-
isFieldLocked:
|
|
3144
|
-
hoverColor:
|
|
3145
|
-
filterFontSize:
|
|
3146
|
-
filterFontColor:
|
|
3137
|
+
}) : null, P ? /* @__PURE__ */ (0, q.jsx)(hi, {
|
|
3138
|
+
filterValues: Ie,
|
|
3139
|
+
filterDimensionsCount: M.length,
|
|
3140
|
+
searchTerm: u,
|
|
3141
|
+
isLoading: g || _,
|
|
3142
|
+
isPreview: s,
|
|
3143
|
+
isFieldLocked: ke,
|
|
3144
|
+
hoverColor: he,
|
|
3145
|
+
filterFontSize: ue,
|
|
3146
|
+
filterFontColor: me,
|
|
3147
3147
|
vSpec: e,
|
|
3148
|
-
dimensionSelectionMethods:
|
|
3148
|
+
dimensionSelectionMethods: ve,
|
|
3149
3149
|
selectionMode: C
|
|
3150
|
-
}) :
|
|
3150
|
+
}) : ee || te ? /* @__PURE__ */ (0, q.jsx)(ge, {
|
|
3151
3151
|
vSpec: e,
|
|
3152
|
-
filterValues:
|
|
3153
|
-
hoverColor:
|
|
3154
|
-
onItemClick:
|
|
3155
|
-
selectedValues:
|
|
3156
|
-
appliedValues:
|
|
3157
|
-
searchTerm:
|
|
3158
|
-
}) : /* @__PURE__ */ (0, q.jsx)(
|
|
3152
|
+
filterValues: Ie,
|
|
3153
|
+
hoverColor: he,
|
|
3154
|
+
onItemClick: Ce,
|
|
3155
|
+
selectedValues: je,
|
|
3156
|
+
appliedValues: H.applied ?? [],
|
|
3157
|
+
searchTerm: u
|
|
3158
|
+
}) : /* @__PURE__ */ (0, q.jsx)(be, {
|
|
3159
3159
|
vSpec: e,
|
|
3160
|
-
filterValues:
|
|
3161
|
-
hoverColor:
|
|
3162
|
-
onItemClick:
|
|
3163
|
-
selectedValues:
|
|
3164
|
-
appliedValues:
|
|
3165
|
-
searchTerm:
|
|
3160
|
+
filterValues: Ie,
|
|
3161
|
+
hoverColor: he,
|
|
3162
|
+
onItemClick: Ce,
|
|
3163
|
+
selectedValues: je,
|
|
3164
|
+
appliedValues: H.applied ?? [],
|
|
3165
|
+
searchTerm: u
|
|
3166
3166
|
})]
|
|
3167
3167
|
})
|
|
3168
3168
|
}),
|
|
3169
|
-
|
|
3170
|
-
style:
|
|
3171
|
-
children: /* @__PURE__ */ (0, q.jsx)(
|
|
3169
|
+
ke && /* @__PURE__ */ (0, q.jsx)("div", {
|
|
3170
|
+
style: vi,
|
|
3171
|
+
children: /* @__PURE__ */ (0, q.jsx)(qe, {
|
|
3172
3172
|
color: "secondary",
|
|
3173
|
-
style:
|
|
3174
|
-
onClick: () =>
|
|
3175
|
-
children: /* @__PURE__ */ (0, q.jsxs)(q.Fragment, { children: [/* @__PURE__ */ (0, q.jsx)(
|
|
3173
|
+
style: _i,
|
|
3174
|
+
onClick: () => Ae(),
|
|
3175
|
+
children: /* @__PURE__ */ (0, q.jsxs)(q.Fragment, { children: [/* @__PURE__ */ (0, q.jsx)(h, { fill: "white" }), "Unlock"] })
|
|
3176
3176
|
})
|
|
3177
3177
|
})
|
|
3178
3178
|
]
|
|
@@ -3180,8 +3180,8 @@ var Xr = H("input", {
|
|
|
3180
3180
|
})
|
|
3181
3181
|
});
|
|
3182
3182
|
};
|
|
3183
|
-
function
|
|
3184
|
-
let { quickSelection: t, isPreview: n, areSelectedValues: r, state: i, responsive: a, isSingleSelectField: o = !1, onClear: s, onDeselectAll: c, onSelectAll: l, onSelectExcluded: u, onNotOperatorChange: d, onLockClick: f } = e, [p, m] = (0, K.useState)(!1), h =
|
|
3183
|
+
function bi(e) {
|
|
3184
|
+
let { quickSelection: t, isPreview: n, areSelectedValues: r, state: i, responsive: a, isSingleSelectField: o = !1, onClear: s, onDeselectAll: c, onSelectAll: l, onSelectExcluded: u, onNotOperatorChange: d, onLockClick: f } = e, [p, m] = (0, K.useState)(!1), h = Tt({ responsive: a }), { appliedOperator: _, pendingOperator: v } = (0, K.useContext)(fe), b = _ ?? v ?? J.FilterOperator.InList, x = D().daedalus.getWorkbookProperties()?.isLockUnlockFieldsEnabled ?? !1;
|
|
3185
3185
|
if (t) return null;
|
|
3186
3186
|
let S = [{
|
|
3187
3187
|
disabled: n || !i.pending,
|
|
@@ -3226,12 +3226,12 @@ function yi(e) {
|
|
|
3226
3226
|
type: "option",
|
|
3227
3227
|
icon: { right: /* @__PURE__ */ (0, q.jsx)(y, {}) },
|
|
3228
3228
|
onClick: f
|
|
3229
|
-
}), /* @__PURE__ */ (0, q.jsx)(
|
|
3229
|
+
}), /* @__PURE__ */ (0, q.jsx)(ze, {
|
|
3230
3230
|
open: p,
|
|
3231
3231
|
placement: "bottom-end",
|
|
3232
3232
|
title: /* @__PURE__ */ (0, q.jsx)(z, {
|
|
3233
3233
|
onClickAway: () => m(!1),
|
|
3234
|
-
children: /* @__PURE__ */ (0, q.jsx)(
|
|
3234
|
+
children: /* @__PURE__ */ (0, q.jsx)(ie, {
|
|
3235
3235
|
appearance: "legacy",
|
|
3236
3236
|
onClose: () => m(!1),
|
|
3237
3237
|
options: S,
|
|
@@ -3242,14 +3242,14 @@ function yi(e) {
|
|
|
3242
3242
|
children: /* @__PURE__ */ (0, q.jsx)(B, {
|
|
3243
3243
|
onClick: () => m(!p),
|
|
3244
3244
|
className: h.menuTrigger,
|
|
3245
|
-
children: /* @__PURE__ */ (0, q.jsx)(
|
|
3245
|
+
children: /* @__PURE__ */ (0, q.jsx)(g, {
|
|
3246
3246
|
fill: "currentColor",
|
|
3247
3247
|
size: 20
|
|
3248
3248
|
})
|
|
3249
3249
|
})
|
|
3250
3250
|
});
|
|
3251
3251
|
}
|
|
3252
|
-
var
|
|
3252
|
+
var xi = C({
|
|
3253
3253
|
searchWrapper: (e) => ({
|
|
3254
3254
|
alignItems: "center",
|
|
3255
3255
|
display: "flex",
|
|
@@ -3272,8 +3272,8 @@ var bi = S({
|
|
|
3272
3272
|
margin: 0,
|
|
3273
3273
|
backgroundColor: "transparent"
|
|
3274
3274
|
},
|
|
3275
|
-
...
|
|
3276
|
-
...
|
|
3275
|
+
...Ci("bottom", e),
|
|
3276
|
+
...Ci("top", e)
|
|
3277
3277
|
}),
|
|
3278
3278
|
unlockButtonStyles: {
|
|
3279
3279
|
width: "100%",
|
|
@@ -3283,24 +3283,24 @@ var bi = S({
|
|
|
3283
3283
|
transform: "translateY(-3px)"
|
|
3284
3284
|
}
|
|
3285
3285
|
});
|
|
3286
|
-
function
|
|
3287
|
-
let { children:
|
|
3286
|
+
function Si(e) {
|
|
3287
|
+
let { children: n, isOpen: r, setIsOpen: a, isPreview: o, vSpec: s, vTheme: c, onSearchChange: l, setLocalSearch: u, allValuesLoaded: d, onSelectAll: f, localSearch: p, searchTerm: m, loadMoreData: g, headerElement: _, filterValues: v, hierarchicalMode: y, filterDimensionsCount: b, dimensionSelectionMethods: x, selectionMode: S, onNotOperatorChange: C, onClick: w, onDeselectAll: T, onClear: E, onSelectExcluded: O, state: k, onLockClick: A, isLocked: j, isSingleSelectField: M = !1, isSearching: N = !1, isApplyingFilters: P = !1 } = e, F = D(), I = xi(s?.filterSettings?.responsive), L = P || N, R = (0, K.useRef)(null);
|
|
3288
3288
|
(0, K.useEffect)(() => {
|
|
3289
3289
|
R.current?.toggleAttribute("inert", L);
|
|
3290
3290
|
}, [L]);
|
|
3291
|
-
let { quickSelection: ee, hasMeasure: te, hasImage: ne, searchEnabled: re } =
|
|
3292
|
-
if (
|
|
3293
|
-
let { backgroundColor: e, ...t } =
|
|
3294
|
-
|
|
3291
|
+
let { quickSelection: ee, hasMeasure: te, hasImage: ne, searchEnabled: re } = Ct(s), ie = k.pending ?? k.applied ?? [], B = s.filterSettings?.filterStyle, ce;
|
|
3292
|
+
if (B) {
|
|
3293
|
+
let { backgroundColor: e, ...t } = B;
|
|
3294
|
+
ce = {
|
|
3295
3295
|
...t,
|
|
3296
|
-
..."backgroundColor" in
|
|
3296
|
+
..."backgroundColor" in B ? { backgroundColor: e ?? void 0 } : {}
|
|
3297
3297
|
};
|
|
3298
3298
|
}
|
|
3299
|
-
let
|
|
3300
|
-
...
|
|
3301
|
-
"--background-color":
|
|
3302
|
-
})["--background-color-hover"] ??
|
|
3303
|
-
function
|
|
3299
|
+
let ue = s.filterSettings?.filterStyle?.borderRadius ?? t.borderRadius, fe = s.filterSettings?.fontStyle?.fontColor ?? c?.fonts?.general?.color ?? i.mainDarkNavy, pe = s.filterSettings?.filterStyle?.backgroundColor ?? t.backgroundColor, he = oe({
|
|
3300
|
+
...ae,
|
|
3301
|
+
"--background-color": pe
|
|
3302
|
+
})["--background-color-hover"] ?? i.grey3;
|
|
3303
|
+
function ye(e) {
|
|
3304
3304
|
switch (e.key) {
|
|
3305
3305
|
case "Enter":
|
|
3306
3306
|
d ? f() : F.daedalus.emitEvent(J.AstratoEvents.SHOW_GLOBAL_NOTIFICATION, {
|
|
@@ -3313,10 +3313,10 @@ function xi(e) {
|
|
|
3313
3313
|
break;
|
|
3314
3314
|
}
|
|
3315
3315
|
}
|
|
3316
|
-
return /* @__PURE__ */ (0, q.jsx)(
|
|
3316
|
+
return /* @__PURE__ */ (0, q.jsx)(ze, {
|
|
3317
3317
|
placement: "bottom-start",
|
|
3318
3318
|
arrow: !1,
|
|
3319
|
-
open:
|
|
3319
|
+
open: r,
|
|
3320
3320
|
classes: { popper: I.tooltip },
|
|
3321
3321
|
slotProps: { popper: { anchorEl: _?.current?.firstElementChild } },
|
|
3322
3322
|
title: /* @__PURE__ */ (0, q.jsx)(z, {
|
|
@@ -3325,53 +3325,53 @@ function xi(e) {
|
|
|
3325
3325
|
style: {
|
|
3326
3326
|
minWidth: _.current?.clientWidth,
|
|
3327
3327
|
maxWidth: "80vw",
|
|
3328
|
-
fontSize: s.filterSettings?.fontStyle?.fontSize ??
|
|
3328
|
+
fontSize: s.filterSettings?.fontStyle?.fontSize ?? t.fontSize
|
|
3329
3329
|
},
|
|
3330
|
-
children:
|
|
3330
|
+
children: r && /* @__PURE__ */ (0, q.jsxs)("div", {
|
|
3331
3331
|
style: { position: "relative" },
|
|
3332
3332
|
children: [/* @__PURE__ */ (0, q.jsx)("div", {
|
|
3333
3333
|
style: {
|
|
3334
3334
|
filter: j ? "brightness(0.93)" : void 0,
|
|
3335
3335
|
pointerEvents: j ? "none" : void 0
|
|
3336
3336
|
},
|
|
3337
|
-
children: /* @__PURE__ */ (0, q.jsxs)(
|
|
3338
|
-
filterStyle:
|
|
3337
|
+
children: /* @__PURE__ */ (0, q.jsxs)(ve, {
|
|
3338
|
+
filterStyle: ce,
|
|
3339
3339
|
isLocked: j,
|
|
3340
3340
|
children: [
|
|
3341
3341
|
re && !o && /* @__PURE__ */ (0, q.jsxs)("div", {
|
|
3342
3342
|
className: I.searchWrapper,
|
|
3343
3343
|
style: { color: fe },
|
|
3344
|
-
children: [/* @__PURE__ */ (0, q.jsx)(
|
|
3344
|
+
children: [/* @__PURE__ */ (0, q.jsx)(se, {
|
|
3345
3345
|
className: I.searchWrapperSearch,
|
|
3346
3346
|
"data-testid": "filter-search-input",
|
|
3347
3347
|
onChange: (e) => {
|
|
3348
3348
|
l(e.target.value);
|
|
3349
3349
|
},
|
|
3350
3350
|
autoFocus: !j,
|
|
3351
|
-
onPaste:
|
|
3352
|
-
onKeyDown:
|
|
3351
|
+
onPaste: me(l),
|
|
3352
|
+
onKeyDown: ye,
|
|
3353
3353
|
style: {
|
|
3354
3354
|
color: fe,
|
|
3355
3355
|
borderColor: fe
|
|
3356
3356
|
},
|
|
3357
3357
|
value: p,
|
|
3358
3358
|
responsive: s?.filterSettings?.responsive
|
|
3359
|
-
}), /* @__PURE__ */ (0, q.jsx)(
|
|
3359
|
+
}), /* @__PURE__ */ (0, q.jsx)(bi, {
|
|
3360
3360
|
responsive: s?.filterSettings?.responsive,
|
|
3361
3361
|
isPreview: o,
|
|
3362
3362
|
quickSelection: ee,
|
|
3363
|
-
areSelectedValues: !!
|
|
3363
|
+
areSelectedValues: !!ie.length,
|
|
3364
3364
|
state: k,
|
|
3365
|
-
onClear:
|
|
3366
|
-
onDeselectAll:
|
|
3365
|
+
onClear: E,
|
|
3366
|
+
onDeselectAll: T,
|
|
3367
3367
|
onSelectAll: f,
|
|
3368
3368
|
onSelectExcluded: O,
|
|
3369
|
-
onNotOperatorChange:
|
|
3369
|
+
onNotOperatorChange: C,
|
|
3370
3370
|
onLockClick: A,
|
|
3371
3371
|
isSingleSelectField: M
|
|
3372
3372
|
})]
|
|
3373
3373
|
}),
|
|
3374
|
-
/* @__PURE__ */ (0, q.jsx)(
|
|
3374
|
+
/* @__PURE__ */ (0, q.jsx)(le, { loading: N }),
|
|
3375
3375
|
/* @__PURE__ */ (0, q.jsx)("div", {
|
|
3376
3376
|
ref: R,
|
|
3377
3377
|
style: {
|
|
@@ -3379,46 +3379,46 @@ function xi(e) {
|
|
|
3379
3379
|
pointerEvents: L ? "none" : void 0,
|
|
3380
3380
|
transition: "opacity 0.15s ease"
|
|
3381
3381
|
},
|
|
3382
|
-
children: /* @__PURE__ */ (0, q.jsxs)(
|
|
3383
|
-
loadMoreData:
|
|
3382
|
+
children: /* @__PURE__ */ (0, q.jsxs)(_e, {
|
|
3383
|
+
loadMoreData: g,
|
|
3384
3384
|
isDropdown: !0,
|
|
3385
3385
|
hasSearch: re,
|
|
3386
3386
|
responsive: s?.filterSettings?.responsive,
|
|
3387
|
-
children: [d && v.length === 0 && !N && !P ? /* @__PURE__ */ (0, q.jsx)(
|
|
3387
|
+
children: [d && v.length === 0 && !N && !P ? /* @__PURE__ */ (0, q.jsx)(de, {
|
|
3388
3388
|
applied: !1,
|
|
3389
3389
|
disabled: !1,
|
|
3390
3390
|
selected: !1,
|
|
3391
|
-
hoverColor:
|
|
3391
|
+
hoverColor: he,
|
|
3392
3392
|
fontStyle: s.filterSettings?.fontStyle,
|
|
3393
3393
|
dimensionValue: "No results to display.",
|
|
3394
3394
|
responsive: s?.filterSettings?.responsive
|
|
3395
|
-
}) : null, y ? /* @__PURE__ */ (0, q.jsx)(
|
|
3395
|
+
}) : null, y ? /* @__PURE__ */ (0, q.jsx)(hi, {
|
|
3396
3396
|
filterValues: v,
|
|
3397
|
-
filterDimensionsCount:
|
|
3397
|
+
filterDimensionsCount: b,
|
|
3398
3398
|
searchTerm: m,
|
|
3399
3399
|
isLoading: N || P,
|
|
3400
3400
|
isPreview: o,
|
|
3401
3401
|
isFieldLocked: j,
|
|
3402
|
-
hoverColor:
|
|
3403
|
-
filterFontSize: s.filterSettings?.fontStyle?.fontSize ??
|
|
3402
|
+
hoverColor: he,
|
|
3403
|
+
filterFontSize: s.filterSettings?.fontStyle?.fontSize ?? t.fontSize,
|
|
3404
3404
|
filterFontColor: fe,
|
|
3405
3405
|
vSpec: s,
|
|
3406
|
-
dimensionSelectionMethods:
|
|
3407
|
-
selectionMode:
|
|
3408
|
-
}) : ne || te ? /* @__PURE__ */ (0, q.jsx)(
|
|
3406
|
+
dimensionSelectionMethods: x,
|
|
3407
|
+
selectionMode: S
|
|
3408
|
+
}) : ne || te ? /* @__PURE__ */ (0, q.jsx)(ge, {
|
|
3409
3409
|
vSpec: s,
|
|
3410
3410
|
filterValues: v,
|
|
3411
|
-
hoverColor:
|
|
3412
|
-
onItemClick:
|
|
3413
|
-
selectedValues:
|
|
3411
|
+
hoverColor: he,
|
|
3412
|
+
onItemClick: w,
|
|
3413
|
+
selectedValues: ie,
|
|
3414
3414
|
appliedValues: k.applied ?? [],
|
|
3415
3415
|
searchTerm: m
|
|
3416
|
-
}) : /* @__PURE__ */ (0, q.jsx)(
|
|
3416
|
+
}) : /* @__PURE__ */ (0, q.jsx)(be, {
|
|
3417
3417
|
vSpec: s,
|
|
3418
3418
|
filterValues: v,
|
|
3419
|
-
hoverColor:
|
|
3420
|
-
onItemClick:
|
|
3421
|
-
selectedValues:
|
|
3419
|
+
hoverColor: he,
|
|
3420
|
+
onItemClick: w,
|
|
3421
|
+
selectedValues: ie,
|
|
3422
3422
|
appliedValues: k.applied ?? [],
|
|
3423
3423
|
searchTerm: m
|
|
3424
3424
|
})]
|
|
@@ -3426,20 +3426,20 @@ function xi(e) {
|
|
|
3426
3426
|
})
|
|
3427
3427
|
]
|
|
3428
3428
|
})
|
|
3429
|
-
}), j && /* @__PURE__ */ (0, q.jsx)(
|
|
3429
|
+
}), j && /* @__PURE__ */ (0, q.jsx)(qe, {
|
|
3430
3430
|
color: "secondary",
|
|
3431
|
-
style: { borderRadius: `0 0 ${
|
|
3431
|
+
style: { borderRadius: `0 0 ${ue}px ${ue}px` },
|
|
3432
3432
|
className: I.unlockButtonStyles,
|
|
3433
3433
|
onClick: A,
|
|
3434
|
-
children: /* @__PURE__ */ (0, q.jsxs)(q.Fragment, { children: [/* @__PURE__ */ (0, q.jsx)(
|
|
3434
|
+
children: /* @__PURE__ */ (0, q.jsxs)(q.Fragment, { children: [/* @__PURE__ */ (0, q.jsx)(h, { fill: "white" }), "Unlock"] })
|
|
3435
3435
|
})]
|
|
3436
3436
|
})
|
|
3437
3437
|
})
|
|
3438
3438
|
}),
|
|
3439
|
-
children:
|
|
3439
|
+
children: n
|
|
3440
3440
|
});
|
|
3441
3441
|
}
|
|
3442
|
-
function
|
|
3442
|
+
function Ci(e, t) {
|
|
3443
3443
|
let n = e === "top" ? "marginBottom" : "marginTop";
|
|
3444
3444
|
return { [`&[data-popper-placement*="${e}"]`]: { "& .MuiTooltip-tooltip": {
|
|
3445
3445
|
[n]: 8,
|
|
@@ -3450,90 +3450,90 @@ function Si(e, t) {
|
|
|
3450
3450
|
}
|
|
3451
3451
|
} } };
|
|
3452
3452
|
}
|
|
3453
|
-
var
|
|
3453
|
+
var wi = {
|
|
3454
3454
|
backgroundColor: "transparent",
|
|
3455
3455
|
borderEnabled: !1
|
|
3456
|
-
},
|
|
3457
|
-
let
|
|
3458
|
-
if (
|
|
3459
|
-
let { backgroundColor: e, ...t } =
|
|
3456
|
+
}, Ti = ({ vSpec: e, filterValues: r, isPreview: i = !1, vTheme: o, loadMoreData: s, searchTerm: c, setSearchTerm: l, allValuesLoaded: u, isSearching: d = !1, isApplyingFilters: p = !1 }) => {
|
|
3457
|
+
let m = (0, K.useRef)(null), [h, g] = (0, K.useState)(!1), [_, v] = (0, K.useState)(c), y = e.dimensions[0]?.formatter, b = e.dimensions.filter((e) => e.role === a.FILTER_DIMENSION), x = b.length > 1, S = r.map((e) => e.dimension), [C, w] = pe(e), { quickSelection: T } = Ct(e), E = e.filterSettings?.filterStyle, D;
|
|
3458
|
+
if (E) {
|
|
3459
|
+
let { backgroundColor: e, ...t } = E;
|
|
3460
3460
|
D = {
|
|
3461
3461
|
...t,
|
|
3462
|
-
..."backgroundColor" in
|
|
3462
|
+
..."backgroundColor" in E ? { backgroundColor: e ?? void 0 } : {}
|
|
3463
3463
|
};
|
|
3464
3464
|
}
|
|
3465
|
-
let
|
|
3465
|
+
let k = e.filterSettings?.defaultNotState ? J.FilterOperator.NotInList : J.FilterOperator.InList, A = O(i ? [] : x ? b.map((e, t) => ({
|
|
3466
3466
|
dataItem: e.dataItem,
|
|
3467
3467
|
dateLevel: e.dateLevel ?? void 0,
|
|
3468
3468
|
datePart: e.datePart ?? void 0,
|
|
3469
|
-
values:
|
|
3469
|
+
values: r.map((e) => e.dimensionValues ? e.dimensionValues[t] : [e.dimension, e.childDimension][t]).filter((e) => e !== void 0)
|
|
3470
3470
|
})) : [{
|
|
3471
3471
|
dataItem: e.dimensions[0]?.dataItem,
|
|
3472
3472
|
dateLevel: e.dimensions[0]?.dateLevel ?? void 0,
|
|
3473
3473
|
datePart: e.dimensions[0]?.datePart ?? void 0,
|
|
3474
|
-
values:
|
|
3474
|
+
values: S
|
|
3475
3475
|
}], {
|
|
3476
|
-
disabled:
|
|
3477
|
-
state:
|
|
3478
|
-
defaultOperator:
|
|
3479
|
-
commitHistory:
|
|
3480
|
-
}),
|
|
3481
|
-
|
|
3482
|
-
},
|
|
3483
|
-
|
|
3476
|
+
disabled: i,
|
|
3477
|
+
state: T ? J.SelectionState.APPLIED : void 0,
|
|
3478
|
+
defaultOperator: k,
|
|
3479
|
+
commitHistory: T
|
|
3480
|
+
}), j = (0, K.useMemo)(() => (0, wt.default)((e) => l(e), 300), [l]), { onClear: M, onClick: N, onDeselectAll: P, onSelectExcluded: R, onSelectAll: ee, onNotOperatorChange: te, state: z, operators: ne, field: re } = A[0] ?? F, ie = z.pending ?? z.applied ?? [], { isFieldLocked: B = !1, toggleFieldLock: ae } = L(re ?? void 0), oe = I(re ? [re] : []), se = (e) => {
|
|
3481
|
+
v(e), j(e);
|
|
3482
|
+
}, ce = (0, K.useMemo)(() => B ? r.filter((e) => (z.pending ?? z.applied ?? []).includes(e.dimension)) : r, [
|
|
3483
|
+
r,
|
|
3484
3484
|
B,
|
|
3485
3485
|
z.pending,
|
|
3486
3486
|
z.applied
|
|
3487
3487
|
]);
|
|
3488
|
-
return /* @__PURE__ */ (0, q.jsx)(
|
|
3488
|
+
return /* @__PURE__ */ (0, q.jsx)(xe, {
|
|
3489
3489
|
noBorder: !0,
|
|
3490
|
-
filterStyle:
|
|
3491
|
-
fontSize: e.filterSettings?.fontStyle?.fontSize ??
|
|
3492
|
-
children: /* @__PURE__ */ (0, q.jsx)(
|
|
3493
|
-
value: {
|
|
3494
|
-
appliedOperator:
|
|
3495
|
-
pendingOperator:
|
|
3496
|
-
},
|
|
3497
|
-
children: /* @__PURE__ */ (0, q.jsx)(
|
|
3498
|
-
isOpen:
|
|
3499
|
-
isPreview:
|
|
3490
|
+
filterStyle: wi,
|
|
3491
|
+
fontSize: e.filterSettings?.fontStyle?.fontSize ?? t.fontSize,
|
|
3492
|
+
children: /* @__PURE__ */ (0, q.jsx)(fe.Provider, {
|
|
3493
|
+
value: f({
|
|
3494
|
+
appliedOperator: ne.applied,
|
|
3495
|
+
pendingOperator: ne.pending
|
|
3496
|
+
}),
|
|
3497
|
+
children: /* @__PURE__ */ (0, q.jsx)(Si, {
|
|
3498
|
+
isOpen: h,
|
|
3499
|
+
isPreview: i,
|
|
3500
3500
|
vSpec: e,
|
|
3501
|
-
vTheme:
|
|
3502
|
-
allValuesLoaded:
|
|
3503
|
-
localSearch:
|
|
3504
|
-
searchTerm:
|
|
3505
|
-
headerElement:
|
|
3506
|
-
setIsOpen:
|
|
3507
|
-
onSearchChange:
|
|
3508
|
-
setLocalSearch:
|
|
3509
|
-
loadMoreData:
|
|
3510
|
-
filterValues:
|
|
3511
|
-
hierarchicalMode:
|
|
3512
|
-
filterDimensionsCount:
|
|
3513
|
-
dimensionSelectionMethods:
|
|
3514
|
-
selectionMode: e.filterSettings?.selectionMode ??
|
|
3515
|
-
onNotOperatorChange:
|
|
3516
|
-
onClick:
|
|
3517
|
-
onDeselectAll:
|
|
3518
|
-
onSelectAll:
|
|
3519
|
-
onClear:
|
|
3520
|
-
onSelectExcluded:
|
|
3501
|
+
vTheme: o,
|
|
3502
|
+
allValuesLoaded: u,
|
|
3503
|
+
localSearch: _,
|
|
3504
|
+
searchTerm: c,
|
|
3505
|
+
headerElement: m,
|
|
3506
|
+
setIsOpen: g,
|
|
3507
|
+
onSearchChange: se,
|
|
3508
|
+
setLocalSearch: v,
|
|
3509
|
+
loadMoreData: s,
|
|
3510
|
+
filterValues: ce,
|
|
3511
|
+
hierarchicalMode: x,
|
|
3512
|
+
filterDimensionsCount: b.length,
|
|
3513
|
+
dimensionSelectionMethods: A,
|
|
3514
|
+
selectionMode: e.filterSettings?.selectionMode ?? n.selectionMode,
|
|
3515
|
+
onNotOperatorChange: te,
|
|
3516
|
+
onClick: N,
|
|
3517
|
+
onDeselectAll: P,
|
|
3518
|
+
onSelectAll: ee,
|
|
3519
|
+
onClear: M,
|
|
3520
|
+
onSelectExcluded: R,
|
|
3521
3521
|
state: z,
|
|
3522
|
-
onLockClick:
|
|
3522
|
+
onLockClick: ae,
|
|
3523
3523
|
isLocked: B,
|
|
3524
|
-
isSingleSelectField:
|
|
3524
|
+
isSingleSelectField: oe,
|
|
3525
3525
|
isSearching: d,
|
|
3526
|
-
isApplyingFilters:
|
|
3526
|
+
isApplyingFilters: p,
|
|
3527
3527
|
children: /* @__PURE__ */ (0, q.jsx)("div", {
|
|
3528
|
-
ref:
|
|
3528
|
+
ref: m,
|
|
3529
3529
|
style: { height: "100%" },
|
|
3530
|
-
children: /* @__PURE__ */ (0, q.jsx)(
|
|
3531
|
-
measureTitle:
|
|
3532
|
-
dimensionTitle:
|
|
3533
|
-
isOpen:
|
|
3534
|
-
onToggle: () =>
|
|
3535
|
-
dimensionFormatter:
|
|
3536
|
-
selectedValues:
|
|
3530
|
+
children: /* @__PURE__ */ (0, q.jsx)(he, {
|
|
3531
|
+
measureTitle: w ?? "",
|
|
3532
|
+
dimensionTitle: C,
|
|
3533
|
+
isOpen: h,
|
|
3534
|
+
onToggle: () => g(!h),
|
|
3535
|
+
dimensionFormatter: y,
|
|
3536
|
+
selectedValues: ie,
|
|
3537
3537
|
fontStyle: e.filterSettings?.fontStyle ?? {},
|
|
3538
3538
|
filterStyle: D,
|
|
3539
3539
|
responsive: e?.filterSettings?.responsive,
|
|
@@ -3543,7 +3543,7 @@ var Ci = {
|
|
|
3543
3543
|
})
|
|
3544
3544
|
})
|
|
3545
3545
|
});
|
|
3546
|
-
},
|
|
3546
|
+
}, Ei = [
|
|
3547
3547
|
{ value: "Value 1" },
|
|
3548
3548
|
{ value: "Value 2" },
|
|
3549
3549
|
{ value: "Value 3" },
|
|
@@ -3555,13 +3555,13 @@ var Ci = {
|
|
|
3555
3555
|
{ value: "Value 9" },
|
|
3556
3556
|
{ value: "Value 10" },
|
|
3557
3557
|
{ value: "Value 11" }
|
|
3558
|
-
],
|
|
3559
|
-
let
|
|
3558
|
+
], Di = ({ vSpec: e, vTheme: t }) => {
|
|
3559
|
+
let n = Ei.map((e) => ({ dimension: e.value })), i = {
|
|
3560
3560
|
...e,
|
|
3561
3561
|
dimensions: [{
|
|
3562
3562
|
dataItem: {
|
|
3563
3563
|
internalKey: "filter-preview",
|
|
3564
|
-
uniqueSignature:
|
|
3564
|
+
uniqueSignature: r(),
|
|
3565
3565
|
schema: "excel",
|
|
3566
3566
|
view: "pokemon",
|
|
3567
3567
|
name: "city",
|
|
@@ -3572,67 +3572,67 @@ var Ci = {
|
|
|
3572
3572
|
}],
|
|
3573
3573
|
measures: []
|
|
3574
3574
|
};
|
|
3575
|
-
return e.filterSettings?.mode ===
|
|
3575
|
+
return e.filterSettings?.mode === u.Dropdown ? /* @__PURE__ */ (0, q.jsx)(Ti, {
|
|
3576
3576
|
allValuesLoaded: !0,
|
|
3577
3577
|
vSpec: i,
|
|
3578
|
-
vTheme:
|
|
3579
|
-
filterValues:
|
|
3578
|
+
vTheme: t,
|
|
3579
|
+
filterValues: n,
|
|
3580
3580
|
isPreview: !0,
|
|
3581
3581
|
searchTerm: "",
|
|
3582
3582
|
setSearchTerm: () => null,
|
|
3583
3583
|
loadMoreData: () => void 0
|
|
3584
|
-
}) : /* @__PURE__ */ (0, q.jsx)(
|
|
3584
|
+
}) : /* @__PURE__ */ (0, q.jsx)(yi, {
|
|
3585
3585
|
allValuesLoaded: !0,
|
|
3586
3586
|
vSpec: i,
|
|
3587
|
-
vTheme:
|
|
3588
|
-
filterValues:
|
|
3587
|
+
vTheme: t,
|
|
3588
|
+
filterValues: n,
|
|
3589
3589
|
isPreview: !0,
|
|
3590
3590
|
searchTerm: "",
|
|
3591
3591
|
setSearchTerm: () => null,
|
|
3592
3592
|
loadMoreData: () => void 0
|
|
3593
3593
|
});
|
|
3594
|
-
},
|
|
3595
|
-
let d =
|
|
3594
|
+
}, Oi = N(({ vSpec: e, filterValues: t = [], vTheme: n, loadMoreData: r, searchTerm: i, setSearchTerm: a, allValuesLoaded: s, isSearching: c = !1, isApplyingFilters: l = !1 }) => {
|
|
3595
|
+
let d = A();
|
|
3596
3596
|
if ((0, K.useEffect)(() => {
|
|
3597
3597
|
e?.dimensions?.length < 2 && d();
|
|
3598
|
-
}, [e]), !e?.dimensions?.length && e?.dimensions !== void 0) return /* @__PURE__ */ (0, q.jsx)(
|
|
3598
|
+
}, [e]), !e?.dimensions?.length && e?.dimensions !== void 0) return /* @__PURE__ */ (0, q.jsx)(Di, {
|
|
3599
3599
|
vSpec: {
|
|
3600
3600
|
...e,
|
|
3601
3601
|
filterSettings: {
|
|
3602
3602
|
...e.filterSettings,
|
|
3603
|
-
mode: e.filterSettings?.mode ??
|
|
3604
|
-
source: e.filterSettings?.source ??
|
|
3603
|
+
mode: e.filterSettings?.mode ?? u.Listbox,
|
|
3604
|
+
source: e.filterSettings?.source ?? o.Engine,
|
|
3605
3605
|
fontStyle: e.filterSettings?.fontStyle ?? {}
|
|
3606
3606
|
}
|
|
3607
3607
|
},
|
|
3608
|
-
vTheme:
|
|
3608
|
+
vTheme: n
|
|
3609
3609
|
});
|
|
3610
3610
|
if (e?.dimensions === void 0 || !e?.filterSettings?.mode || !e?.filterSettings?.source) return null;
|
|
3611
3611
|
switch (e.filterSettings.mode) {
|
|
3612
|
-
case
|
|
3613
|
-
case
|
|
3612
|
+
case u.Image: return null;
|
|
3613
|
+
case u.Dropdown: return /* @__PURE__ */ (0, q.jsx)(Ti, {
|
|
3614
3614
|
allValuesLoaded: s,
|
|
3615
3615
|
vSpec: e,
|
|
3616
|
-
vTheme:
|
|
3617
|
-
filterValues:
|
|
3618
|
-
loadMoreData:
|
|
3619
|
-
searchTerm:
|
|
3620
|
-
setSearchTerm:
|
|
3616
|
+
vTheme: n,
|
|
3617
|
+
filterValues: t,
|
|
3618
|
+
loadMoreData: r,
|
|
3619
|
+
searchTerm: i,
|
|
3620
|
+
setSearchTerm: a,
|
|
3621
3621
|
isSearching: c,
|
|
3622
|
-
isApplyingFilters:
|
|
3622
|
+
isApplyingFilters: l
|
|
3623
3623
|
});
|
|
3624
|
-
case
|
|
3625
|
-
default: return /* @__PURE__ */ (0, q.jsx)(
|
|
3624
|
+
case u.Listbox:
|
|
3625
|
+
default: return /* @__PURE__ */ (0, q.jsx)(yi, {
|
|
3626
3626
|
allValuesLoaded: s,
|
|
3627
3627
|
vSpec: e,
|
|
3628
|
-
vTheme:
|
|
3629
|
-
filterValues:
|
|
3630
|
-
loadMoreData:
|
|
3631
|
-
searchTerm:
|
|
3632
|
-
setSearchTerm:
|
|
3628
|
+
vTheme: n,
|
|
3629
|
+
filterValues: t,
|
|
3630
|
+
loadMoreData: r,
|
|
3631
|
+
searchTerm: i,
|
|
3632
|
+
setSearchTerm: a,
|
|
3633
3633
|
isSearching: c,
|
|
3634
|
-
isApplyingFilters:
|
|
3634
|
+
isApplyingFilters: l
|
|
3635
3635
|
});
|
|
3636
3636
|
}
|
|
3637
3637
|
});
|
|
3638
|
-
export {
|
|
3638
|
+
export { Oi as Filter };
|