@astrato-io/visualizations 0.6.5 → 0.7.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +32 -2
- package/THIRD_PARTY_NOTICES.md +2 -229
- package/VISUALIZATION_DEFINITIONS.md +68 -114
- package/chunks/Button-BrGKp9Nm.js +110 -0
- package/chunks/DefaultPropsProvider-BsfB7QTn.js +257 -0
- package/chunks/FieldTypeIcon-Drs6hSJF.js +22 -0
- package/chunks/{LinearProgress-B1FeWaen.js → LinearProgress-VtfFx2vJ.js} +55 -55
- package/chunks/MenuOption-ByRqhRdX.js +3934 -0
- package/chunks/Title-CO5dP1ma.js +1691 -0
- package/chunks/ToggleButton-KOBAimC1.js +112 -0
- package/chunks/{app-filter-bar.compiler-BGJ7HAbr.js → app-filter-bar.compiler-TwVTeoj5.js} +10 -10
- package/chunks/{bar.compiler-CT0ZbQKc.js → bar.compiler-DuQg8EUb.js} +84 -84
- package/chunks/builder-DEDvNq1k.js +201 -0
- package/chunks/{color-settings-ZIvgNTq1.js → color-rules-CN7TcGrC.js} +2 -6
- package/chunks/color-settings-3VRlf_Vw.js +6 -0
- package/chunks/colorManipulator-D8Pjy1pf.js +45 -0
- package/chunks/coloring-CncX_JRX.js +278 -0
- package/chunks/{definitions-D3OVqmXl.js → definitions-BPJQTx16.js} +490 -382
- package/chunks/{escobar-eDjtGpkC.js → escobar-DRhRMYRE.js} +6067 -4742
- package/chunks/event-bus-CrLB-Y8z.js +3 -0
- package/chunks/extend-preset-CUFNpmPe.js +4398 -0
- package/chunks/{filter.compiler-DBsyRBJt.js → filter.compiler-w27dlv0C.js} +12 -12
- package/chunks/{filtering-tqjAyJH5.js → filtering-cc7WqWpg.js} +391 -310
- package/chunks/{handlers-VTBfIZYZ.js → handlers-TOT-7INo.js} +3241 -3442
- package/chunks/icon-picker-styles-CoJmwTRi.js +2246 -0
- package/chunks/isEqual-B8loyPsC.js +12 -0
- package/chunks/label-format-type-weq1XfcX.js +8 -0
- package/chunks/{line.compiler-CzdM5Ld0.js → line.compiler-Ct1WhN2p.js} +27 -27
- package/chunks/logger-DpQtYQnX.js +1163 -0
- package/chunks/lookup-BWllin0q.js +36 -0
- package/chunks/{metadata-BGElBy5Z.js → metadata-WABZrt7Y.js} +1 -1
- package/chunks/{number.compiler-G-R7y16P.js → number.compiler-D8TPly-4.js} +13 -13
- package/chunks/{operations-CTNUX6Sy.js → operations-Dh4v1Ovt.js} +9314 -9283
- package/chunks/{range-CiwTbMig.js → range-Bi-7zT0k.js} +2 -2
- package/chunks/registry-KervaxqJ.js +31 -0
- package/chunks/render-wrappers-OEmtaM8g.js +2 -0
- package/chunks/{registry-CsQQzukD.js → requirements-PAoRaJyb.js} +304 -336
- package/chunks/responsive.styles-DSiOGD7u.js +82 -0
- package/chunks/{shared-CBvcC5YV.js → shared-Bn4N5QcZ.js} +424 -424
- package/chunks/src-77e3mC7i.js +391 -0
- package/chunks/standalone-B55oyW6c.js +689 -0
- package/chunks/{standalone-C3gg736V.js → standalone-BDhPQtzQ.js} +375 -341
- package/chunks/{standalone-BMIbT1b2.js → standalone-BGkmozIb.js} +992 -837
- package/chunks/standalone-BMTCb10X.js +179 -0
- package/chunks/standalone-BXKRE_Se.js +468 -0
- package/chunks/standalone-Bes8srx1.js +354 -0
- package/chunks/standalone-BjZp0QMe.js +2 -0
- package/chunks/{standalone-JuLF-OoH.js → standalone-BlMIwpEe.js} +634 -519
- package/chunks/{standalone-C_rYnZ0N.js → standalone-C8ZAEutO.js} +43 -42
- package/chunks/standalone-C8qAelL4.js +2 -0
- package/chunks/standalone-CJvIXsQE.js +743 -0
- package/chunks/standalone-CLmGb7nn2.js +355 -0
- package/chunks/standalone-CM5XcAN5.js +52327 -0
- package/chunks/standalone-CXNP6-xD.js +420 -0
- package/chunks/{standalone-vzBY6q0I2.js → standalone-D5Q5ngsD.js} +57 -55
- package/chunks/standalone-DLlyRIE6.js +287 -0
- package/chunks/standalone-DMcI1afI.js +396 -0
- package/chunks/{standalone-DC-aUgXC.js → standalone-DN4S1MjT.js} +1111 -1092
- package/chunks/standalone-DT0wKji7.js +6 -0
- package/chunks/{standalone-0M4HlmDW2.js → standalone-DVTJwsTY.js} +1109 -1035
- package/chunks/standalone-DW6NT205.js +518 -0
- package/chunks/standalone-DYQIQH4c.js +2095 -0
- package/chunks/standalone-D__XCp-h.js +1003 -0
- package/chunks/standalone-XTgSsTAa.js +354 -0
- package/chunks/{standalone-v1oxfU20.js → standalone-XuGksArp.js} +20 -20
- package/chunks/{standalone-BtSHCp2U2.js → standalone-we5D5MIn.js} +173 -168
- package/chunks/{table.compiler-tb914oj3.js → table.compiler-DMeeHxb6.js} +29 -29
- package/chunks/useFieldName-Cjn9KCVp.js +7 -0
- package/chunks/useSlotProps-DLbQp4lc.js +166 -0
- package/chunks/{utils-Bg7K-t6K.js → utils-vdmi_2PK.js} +6271 -7804
- package/chunks/{view-Bn83C8d9.js → view-BuwQugKb.js} +2717 -3504
- package/chunks/{isEqual-BDxAhUo8.js → visualization-filters-Cc4KU-l-.js} +1887 -1946
- package/chunks/web-components-DqClFkgO.js +1185 -0
- package/chunks/with-html-element-D0uY2zjI.js +7328 -0
- package/definitions.js +2 -2
- package/docs/operations/astrato-app-filter-bar.md +1 -1
- package/docs/operations/bar.md +31 -14
- package/docs/operations/combo.md +1 -1
- package/docs/operations/date-picker.md +3 -3
- package/docs/operations/distribution-gauge.md +13 -13
- package/docs/operations/dot.md +13 -13
- package/docs/operations/filter.md +1 -1
- package/docs/operations/gauge.md +13 -13
- package/docs/operations/heatMap.md +13 -13
- package/docs/operations/histogram.md +1 -1
- package/docs/operations/iframe.md +1 -1
- package/docs/operations/image.md +1 -1
- package/docs/operations/index.md +3 -3
- package/docs/operations/line.md +7 -7
- package/docs/operations/number.md +1 -1
- package/docs/operations/pie.md +13 -13
- package/docs/operations/radar.md +7 -7
- package/docs/operations/sankey.md +13 -13
- package/docs/operations/scatter.md +13 -13
- 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 +18 -1
- package/docs/operations/tree.md +51 -37
- package/docs/operations/treemap.md +63 -49
- package/docs/operations/waterfall.md +1 -1
- package/docs/operations/word-cloud.md +13 -13
- package/getters.js +7 -7
- package/index.js +3 -1183
- package/metadata.js +18 -18
- package/operations.js +13 -13
- package/package.json +106 -55
- package/render.js +10 -0
- package/src/charts/bar.d.ts +1 -0
- package/src/charts/combo.d.ts +1 -0
- package/src/charts/dot.d.ts +1 -0
- package/src/charts/gauge-distribution.d.ts +1 -0
- package/src/charts/gauge.d.ts +1 -0
- package/src/charts/heat-map.d.ts +1 -0
- package/src/charts/histogram.d.ts +1 -0
- package/src/charts/line.d.ts +1 -0
- package/src/charts/pie.d.ts +1 -0
- package/src/charts/radar.d.ts +1 -0
- package/src/charts/sankey.d.ts +1 -0
- package/src/charts/scatter.d.ts +1 -0
- package/src/charts/table.d.ts +1 -0
- package/src/charts/tree.d.ts +1 -0
- package/src/charts/treemap.d.ts +1 -0
- package/src/charts/waterfall.d.ts +1 -0
- package/src/charts/word-cloud.d.ts +1 -0
- package/src/definitions/index.d.ts +1 -1
- package/src/definitions/model/definitions/descriptors/descriptor-metadata.d.ts +53 -30
- package/src/definitions/model/definitions/index.d.ts +1 -1
- package/src/definitions/model/definitions/schema-registry.d.ts +2 -2
- package/src/definitions/model/definitions/schemas/object.schema.d.ts +2 -2
- package/src/definitions/model/definitions/types/compilation.types.d.ts +10 -0
- package/src/definitions/model/definitions/types/index.d.ts +1 -1
- package/src/getters/index.d.ts +3 -3
- package/src/index.d.ts +1 -1
- package/src/objects/app-filter-bar.d.ts +1 -0
- package/src/objects/date-picker.d.ts +1 -0
- package/src/objects/filter.d.ts +1 -0
- package/src/objects/iframe.d.ts +1 -0
- package/src/objects/image.d.ts +1 -0
- package/src/objects/number.d.ts +1 -0
- package/src/objects/shape.d.ts +1 -0
- package/src/objects/slider.d.ts +1 -0
- package/src/objects/text.d.ts +1 -0
- package/src/operations/index.d.ts +3 -3
- package/src/registry/create-visualization-registry.d.ts +5 -0
- package/src/render/index.d.ts +34 -0
- package/src/runtime/index.d.ts +2 -2
- package/src/types.d.ts +9 -4
- package/src/web-components/index.d.ts +3 -3
- package/chunks/ClickAwayListener-BbeNMAvj.js +0 -52
- package/chunks/builder-B6dWSIdD.js +0 -12289
- package/chunks/coloring-B1XAfg6b.js +0 -664
- package/chunks/events-WZut5Ow6.js +0 -4
- package/chunks/grouping-type-On4s9Thj.js +0 -3
- package/chunks/requirements-DYjZCFyf.js +0 -6
- package/chunks/standalone-0ashe9w1.js +0 -411
- package/chunks/standalone-B7jax8wa.js +0 -339
- package/chunks/standalone-BK0VYU-l.js +0 -463
- package/chunks/standalone-BZV5vOwA.js +0 -6
- package/chunks/standalone-BhDrWj4p.js +0 -1980
- package/chunks/standalone-BvaKdky9.js +0 -344
- package/chunks/standalone-BwtM31-f.js +0 -2
- package/chunks/standalone-CC1VUjO32.js +0 -299
- package/chunks/standalone-CoLrAxRV.js +0 -13198
- package/chunks/standalone-DCtRoTWg.js +0 -675
- package/chunks/standalone-DUDFTBqL.js +0 -833
- package/chunks/standalone-DhZkX9Td.js +0 -2
- package/chunks/standalone-DtLElfuM.js +0 -512
- package/chunks/standalone-G9Q4Uczu.js +0 -726
- package/chunks/standalone-_DeX21JJ.js +0 -383
- package/chunks/standalone-gFhKZh8m.js +0 -179
- package/chunks/standalone-tDNy-SFH.js +0 -281
- package/chunks/ui-DQWtv2iM.js +0 -63551
- package/chunks/useFieldName-BvdcoJRl.js +0 -7
|
@@ -1,52 +1,133 @@
|
|
|
1
|
-
import { o as e } from "./rolldown-runtime-DleVn1XH.js";
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
|
|
7
|
-
|
|
1
|
+
import { o as e, t } from "./rolldown-runtime-DleVn1XH.js";
|
|
2
|
+
import { Cr as n, D as r, Ei as i, Fi as a, Hi as o, Hn as s, Pi as c, St as l, _t as u, ar as d, da as f, hn as p, un as m, uo as h, ut as g, vt as _, zi as v } from "./visualization-filters-Cc4KU-l-.js";
|
|
3
|
+
import { $r as y, An as b, Ei as x, G as S, Qr as C, Si as w, Ti as T, W as E, Yr as D, d as O, fn as k, it as A, qr as j, ri as M, tr as N, ur as P, ut as ee, wi as te } from "./utils-vdmi_2PK.js";
|
|
4
|
+
import { s as ne } from "./logger-DpQtYQnX.js";
|
|
5
|
+
import { r as F, s as I, u as re } from "./MenuOption-ByRqhRdX.js";
|
|
6
|
+
import { t as ie } from "./LinearProgress-VtfFx2vJ.js";
|
|
7
|
+
import { d as L, f as R, l as z, u as B } from "./responsive.styles-DSiOGD7u.js";
|
|
8
|
+
var V = (e, t, n) => Math.ceil(t) + Math.ceil(n) >= Math.floor(e) && n > 0;
|
|
9
|
+
function ae(e) {
|
|
8
10
|
let { theme: t, name: n, props: r } = e;
|
|
9
|
-
return !t || !t.components || !t.components[n] || !t.components[n].defaultProps ? r :
|
|
11
|
+
return !t || !t.components || !t.components[n] || !t.components[n].defaultProps ? r : A(t.components[n].defaultProps, r);
|
|
10
12
|
}
|
|
11
|
-
function
|
|
12
|
-
let i =
|
|
13
|
-
return r && (i = i[r] || i),
|
|
13
|
+
function oe({ props: e, name: t, defaultTheme: n, themeId: r }) {
|
|
14
|
+
let i = ee(n);
|
|
15
|
+
return r && (i = i[r] || i), ae({
|
|
14
16
|
theme: i,
|
|
15
17
|
name: t,
|
|
16
18
|
props: e
|
|
17
19
|
});
|
|
18
20
|
}
|
|
19
|
-
var
|
|
20
|
-
|
|
21
|
+
var se = /* @__PURE__ */ t(((e, t) => {
|
|
22
|
+
var n = r(), i = u();
|
|
23
|
+
function a(e, t) {
|
|
24
|
+
return e && n(e, t, i);
|
|
25
|
+
}
|
|
26
|
+
t.exports = a;
|
|
27
|
+
})), ce = /* @__PURE__ */ t(((e, t) => {
|
|
28
|
+
var n = _();
|
|
29
|
+
function r(e, t) {
|
|
30
|
+
return function(r, i) {
|
|
31
|
+
if (r == null) return r;
|
|
32
|
+
if (!n(r)) return e(r, i);
|
|
33
|
+
for (var a = r.length, o = t ? a : -1, s = Object(r); (t ? o-- : ++o < a) && i(s[o], o, s) !== !1;);
|
|
34
|
+
return r;
|
|
35
|
+
};
|
|
36
|
+
}
|
|
37
|
+
t.exports = r;
|
|
38
|
+
})), le = /* @__PURE__ */ t(((e, t) => {
|
|
39
|
+
var n = se();
|
|
40
|
+
t.exports = ce()(n);
|
|
41
|
+
})), H = ne(), U = /* @__PURE__ */ e(x()), W = M(), ue = ({ r: e, g: t, b: n, a: r }) => `rgba(${e},${t},${n},${r ?? 1})`, de = (e) => {
|
|
42
|
+
let [t, n, r, i] = e.replace("rgba(", "").replace("rgb(", "").replace(")", "").replaceAll(" ", "").split(",").map((e) => +e);
|
|
43
|
+
return {
|
|
44
|
+
r: t,
|
|
45
|
+
g: n,
|
|
46
|
+
b: r,
|
|
47
|
+
a: i ?? 1
|
|
48
|
+
};
|
|
49
|
+
}, G = (e, t = !0) => /^#([0-9a-f]{3}){1,2}$/i.test(String(e)) || t && /^#([0-9a-f]{4}){1,2}$/i.test(String(e)), K = (e = "") => e.length < 7 ? e.split("").map((e) => e === "#" ? e : e + e).join("") : e, fe = (e) => {
|
|
50
|
+
let t = K(e);
|
|
51
|
+
return {
|
|
52
|
+
r: parseInt(t.slice(1, 3), 16),
|
|
53
|
+
g: parseInt(t.slice(3, 5), 16),
|
|
54
|
+
b: parseInt(t.slice(5, 7), 16),
|
|
55
|
+
a: pe(t)
|
|
56
|
+
};
|
|
57
|
+
}, pe = (e) => {
|
|
58
|
+
if (!e) return 1;
|
|
59
|
+
if (typeof e == "string") {
|
|
60
|
+
if (G(e)) {
|
|
61
|
+
let t = K(e);
|
|
62
|
+
return t.length === 7 ? 1 : Math.round(parseInt(t.slice(-2), 16) / 255 * 100) / 100;
|
|
63
|
+
}
|
|
64
|
+
let [, , , t] = e.substring(5, e.length - 1).replaceAll(" ", "").split(",");
|
|
65
|
+
return Number(t) || 1;
|
|
66
|
+
}
|
|
67
|
+
return e.a ?? 1;
|
|
68
|
+
}, me = /* @__PURE__ */ t(((e, t) => {
|
|
69
|
+
function n(e, t, n, r) {
|
|
70
|
+
for (var i = -1, a = e == null ? 0 : e.length; ++i < a;) {
|
|
71
|
+
var o = e[i];
|
|
72
|
+
t(r, o, n(o), e);
|
|
73
|
+
}
|
|
74
|
+
return r;
|
|
75
|
+
}
|
|
76
|
+
t.exports = n;
|
|
77
|
+
})), he = /* @__PURE__ */ t(((e, t) => {
|
|
78
|
+
var n = le();
|
|
79
|
+
function r(e, t, r, i) {
|
|
80
|
+
return n(e, function(e, n, a) {
|
|
81
|
+
t(i, e, r(e), a);
|
|
82
|
+
}), i;
|
|
83
|
+
}
|
|
84
|
+
t.exports = r;
|
|
85
|
+
})), ge = /* @__PURE__ */ t(((e, t) => {
|
|
86
|
+
var n = me(), r = he(), i = g(), a = l();
|
|
87
|
+
function o(e, t) {
|
|
88
|
+
return function(o, s) {
|
|
89
|
+
var c = a(o) ? n : r, l = t ? t() : {};
|
|
90
|
+
return c(o, e, i(s, 2), l);
|
|
91
|
+
};
|
|
92
|
+
}
|
|
93
|
+
t.exports = o;
|
|
94
|
+
})), _e = /* @__PURE__ */ t(((e, t) => {
|
|
95
|
+
t.exports = ge()(function(e, t, n) {
|
|
96
|
+
e[+!n].push(t);
|
|
97
|
+
}, function() {
|
|
98
|
+
return [[], []];
|
|
99
|
+
});
|
|
100
|
+
})), q = (e, t) => t && !d(t) ? String(k(t, e)) : e === !0 ? "True" : e === !1 ? "False" : e === null ? "-" : String(e), ve = /* @__PURE__ */ e(_e()), ye = (e, t) => {
|
|
101
|
+
let [n, r] = (0, ve.default)(e, (e) => t.indexOf(e.dimension) !== -1);
|
|
21
102
|
return [n, r];
|
|
22
|
-
},
|
|
23
|
-
let t = e?.dimensions.filter((e) => e.role ===
|
|
24
|
-
return [(t?.length ? t : e?.dimensions.slice(0, 1) ?? []).map(
|
|
103
|
+
}, be = (e) => {
|
|
104
|
+
let t = e?.dimensions.filter((e) => e.role === f.FILTER_DIMENSION);
|
|
105
|
+
return [(t?.length ? t : e?.dimensions.slice(0, 1) ?? []).map(xe).join(" - ") || "Sample", e?.measures[0] && e?.filterSettings?.showMeasureLabel ? ` | ${xe(e?.measures[0])}` : null];
|
|
25
106
|
};
|
|
26
|
-
function
|
|
27
|
-
return
|
|
107
|
+
function xe(e) {
|
|
108
|
+
return p(e) || e.label || e.dataItem?.name || "";
|
|
28
109
|
}
|
|
29
|
-
var
|
|
110
|
+
var Se = (e) => async (t) => {
|
|
30
111
|
t.preventDefault(), t.stopPropagation(), e((t.clipboardData.getData("Text") || await navigator.clipboard.readText()).replaceAll("\r\n", " ").replaceAll("\r", " ").replaceAll("\n", " "));
|
|
31
|
-
},
|
|
112
|
+
}, Ce = (e) => {
|
|
32
113
|
if (!e.length) return [];
|
|
33
114
|
if (e.length === 1) return [e[0], e[0]];
|
|
34
115
|
let t = Infinity, n = -Infinity;
|
|
35
116
|
return e.forEach((e) => {
|
|
36
117
|
t > e && (t = e), n < e && (n = e);
|
|
37
118
|
}), [t, n];
|
|
38
|
-
},
|
|
39
|
-
let n = e.selection.getActiveSelection(
|
|
119
|
+
}, we = n("getToRangeSelectionHandler", "#cbacba"), Te = (e, t) => async () => {
|
|
120
|
+
let n = e.selection.getActiveSelection(H.FilterType.VALUE), r = structuredClone(n), i = r.applied.find((e) => e.field.name === t.name && e.field.view === t.view);
|
|
40
121
|
if (i ||= r.pending.find((e) => e.field.name === t.name && e.field.view === t.view), !i) {
|
|
41
|
-
let n =
|
|
122
|
+
let n = H.FilterOperator.Between;
|
|
42
123
|
r.pending.push({
|
|
43
124
|
operator: n,
|
|
44
|
-
field:
|
|
125
|
+
field: w(e.engine, t),
|
|
45
126
|
values: []
|
|
46
127
|
}), e.selection.setNewSelectionState(r);
|
|
47
128
|
return;
|
|
48
129
|
}
|
|
49
|
-
if (i.operator = i.operator ===
|
|
130
|
+
if (i.operator = i.operator === H.FilterOperator.InList ? H.FilterOperator.Between : H.FilterOperator.NotBetween, (i.values ?? []).length === 0) {
|
|
50
131
|
e.selection.declineSelection(i), e.selection.removeSelection(i);
|
|
51
132
|
let n = {
|
|
52
133
|
dimensions: [],
|
|
@@ -61,49 +142,49 @@ var H = (e) => async (t) => {
|
|
|
61
142
|
}]
|
|
62
143
|
}, a = e.engine;
|
|
63
144
|
if (!a) {
|
|
64
|
-
|
|
145
|
+
we.error("There is no data engine available");
|
|
65
146
|
return;
|
|
66
147
|
}
|
|
67
148
|
let { data: o } = await a.getData(n), s = typeof o[0][0] == "number" ? o[0][0] : null, c = typeof o[0][1] == "number" ? o[0][1] : null;
|
|
68
149
|
if (s === null || c === null) {
|
|
69
|
-
|
|
150
|
+
we.error("There is something wrong with the min/max data");
|
|
70
151
|
return;
|
|
71
152
|
}
|
|
72
|
-
return i.values = [s, c], e.selection.setNewSelectionState(r,
|
|
153
|
+
return i.values = [s, c], e.selection.setNewSelectionState(r, H.FilterType.VALUE), i.operator;
|
|
73
154
|
}
|
|
74
|
-
return i.values =
|
|
75
|
-
},
|
|
76
|
-
let a = n ??
|
|
155
|
+
return i.values = Ce(i.values), e.selection.setNewSelectionState(r, H.FilterType.VALUE), i.operator;
|
|
156
|
+
}, J = n("getToValueSelectionHandler", "#cbacba"), Ee = m(s()), De = (e, t, n, r, i) => async () => {
|
|
157
|
+
let a = n ?? Ee, o = e.selection.getActiveSelection(H.FilterType.VALUE), s = structuredClone(o), c = s.pending.find((e) => e.field.name === t.name && e.field.view === t.view);
|
|
77
158
|
if (c ||= s.applied.find((e) => e.field.name === t.name && e.field.view === t.view), !c) {
|
|
78
|
-
|
|
159
|
+
J.warn("There was no selection connected to clicked field!", JSON.stringify(t));
|
|
79
160
|
return;
|
|
80
161
|
}
|
|
81
|
-
if (r) return c.operator =
|
|
82
|
-
if ([
|
|
83
|
-
if ([
|
|
162
|
+
if (r) return c.operator = H.FilterOperator.InList, c.values = [], delete c.dynamicDateRange, delete c.dynamicDateCalcRange, e.selection.setNewSelectionState(s, H.FilterType.VALUE), c.operator;
|
|
163
|
+
if ([H.FilterOperator.InList, H.FilterOperator.NotInList].includes(c.operator)) return c.operator;
|
|
164
|
+
if ([H.FilterOperator.Like, H.FilterOperator.NotLike].includes(c.operator)) {
|
|
84
165
|
let n = c.values;
|
|
85
|
-
if (c.operator = c.operator ===
|
|
166
|
+
if (c.operator = c.operator === H.FilterOperator.Like ? H.FilterOperator.InList : H.FilterOperator.NotInList, n?.length) {
|
|
86
167
|
let r = {
|
|
87
168
|
dimensions: [{ fieldKey: t.key }],
|
|
88
169
|
limit: a + 1,
|
|
89
170
|
measures: [],
|
|
90
171
|
filters: [{
|
|
91
172
|
fieldKey: t.key,
|
|
92
|
-
operator:
|
|
173
|
+
operator: H.FilterOperator.Like,
|
|
93
174
|
values: n
|
|
94
175
|
}]
|
|
95
176
|
}, o = e.engine;
|
|
96
177
|
if (!o) {
|
|
97
|
-
|
|
178
|
+
J.error("There is no data engine available");
|
|
98
179
|
return;
|
|
99
180
|
}
|
|
100
181
|
let { data: l, meta: u } = await o.getData(r);
|
|
101
|
-
if (u.rows >= a + 1) return c.values = [], e.selection.setNewSelectionState(s,
|
|
182
|
+
if (u.rows >= a + 1) return c.values = [], e.selection.setNewSelectionState(s, H.FilterType.VALUE), i?.(c.operator, String(n[0] ?? "")), c.operator;
|
|
102
183
|
c.values = Object.values(l).flat();
|
|
103
184
|
}
|
|
104
|
-
return e.selection.setNewSelectionState(s,
|
|
185
|
+
return e.selection.setNewSelectionState(s, H.FilterType.VALUE), c.operator;
|
|
105
186
|
}
|
|
106
|
-
c.operator = c.operator ===
|
|
187
|
+
c.operator = c.operator === H.FilterOperator.Between ? H.FilterOperator.InList : H.FilterOperator.NotInList;
|
|
107
188
|
let l = {
|
|
108
189
|
dimensions: [{ fieldKey: t.key }],
|
|
109
190
|
limit: a,
|
|
@@ -112,48 +193,48 @@ var H = (e) => async (t) => {
|
|
|
112
193
|
};
|
|
113
194
|
c.values && (l.filters?.push({
|
|
114
195
|
fieldKey: t.key,
|
|
115
|
-
operator:
|
|
196
|
+
operator: H.FilterOperator.Between,
|
|
116
197
|
values: c.values
|
|
117
198
|
}), l.limit = a + 1);
|
|
118
199
|
let u = e.engine;
|
|
119
200
|
if (!u) {
|
|
120
|
-
|
|
201
|
+
J.error("There is no data engine available");
|
|
121
202
|
return;
|
|
122
203
|
}
|
|
123
204
|
let { data: d, meta: f } = await u.getData(l);
|
|
124
|
-
return f.rows >= a + 1 ? (e.daedalus.emitEvent(
|
|
205
|
+
return f.rows >= a + 1 ? (e.daedalus.emitEvent(H.AstratoEvents.SHOW_GLOBAL_NOTIFICATION, {
|
|
125
206
|
type: "warn",
|
|
126
207
|
message: "Cannot change the selection type, because too many values would have to be selected!"
|
|
127
|
-
}), c.operator) : (c.values = Object.values(d).flat(), e.selection.setNewSelectionState(s,
|
|
128
|
-
},
|
|
129
|
-
let r = e.selection.getActiveSelection(
|
|
208
|
+
}), c.operator) : (c.values = Object.values(d).flat(), e.selection.setNewSelectionState(s, H.FilterType.VALUE), c.operator);
|
|
209
|
+
}, Oe = (e, t) => (n) => {
|
|
210
|
+
let r = e.selection.getActiveSelection(H.FilterType.VALUE), i = structuredClone(r), a = n?.trim() ? [n.trim()] : [""], o = i.applied.find((e) => e.field.name === t.name && e.field.view === t.view);
|
|
130
211
|
if (o ||= i.pending.find((e) => e.field.name === t.name && e.field.view === t.view), !o) {
|
|
131
|
-
let n =
|
|
212
|
+
let n = H.FilterOperator.Like;
|
|
132
213
|
return i.pending.push({
|
|
133
214
|
operator: n,
|
|
134
|
-
field:
|
|
215
|
+
field: w(e.engine, t),
|
|
135
216
|
values: a
|
|
136
217
|
}), e.selection.setNewSelectionState(i), n;
|
|
137
218
|
}
|
|
138
|
-
return o.operator ===
|
|
139
|
-
},
|
|
140
|
-
fontFamily:
|
|
219
|
+
return o.operator === H.FilterOperator.InList ? (o.operator = H.FilterOperator.Like, o.values = a) : o.operator === H.FilterOperator.NotInList ? (o.operator = H.FilterOperator.NotLike, o.values = a) : (o.operator = o.operator === H.FilterOperator.NotLike ? H.FilterOperator.NotLike : H.FilterOperator.Like, o.values = a.length ? a : o.values), e.selection.setNewSelectionState(i, H.FilterType.VALUE), o.operator;
|
|
220
|
+
}, Y = (e, t) => ({
|
|
221
|
+
fontFamily: a(t, e?.fontFamily) ?? void 0,
|
|
141
222
|
fontStyle: e?.italic ? "italic" : "normal",
|
|
142
223
|
fontWeight: e?.bold ? "bold" : "normal",
|
|
143
224
|
textDecoration: `${e?.underlined ? "underline" : ""} ${e?.strikethrough ? "line-through" : ""}`,
|
|
144
|
-
color:
|
|
145
|
-
}),
|
|
146
|
-
let { backgroundColor: n, borderColor: r, borderEnabled:
|
|
147
|
-
...
|
|
225
|
+
color: c(t, e?.fontColor)
|
|
226
|
+
}), ke = (e) => e === h.Line ? "solid" : "dashed", X = (e, t) => {
|
|
227
|
+
let { backgroundColor: n, borderColor: r, borderEnabled: a, borderRadius: o, borderStyle: s, borderWidth: c } = {
|
|
228
|
+
...i,
|
|
148
229
|
...e
|
|
149
230
|
}, l = "0px";
|
|
150
|
-
return
|
|
231
|
+
return a && (l = `${o}px`, t && (l = `${o}px ${o}px 0 0`)), {
|
|
151
232
|
backgroundColor: n,
|
|
152
|
-
border:
|
|
233
|
+
border: a ? `${c}px ${ke(s)} ${r}` : "none",
|
|
153
234
|
borderRadius: l
|
|
154
235
|
};
|
|
155
236
|
};
|
|
156
|
-
function
|
|
237
|
+
function Ae(e) {
|
|
157
238
|
return {
|
|
158
239
|
boxSizing: "border-box",
|
|
159
240
|
alignItems: "center",
|
|
@@ -167,21 +248,21 @@ function J(e) {
|
|
|
167
248
|
flexShrink: 0,
|
|
168
249
|
backgroundColor: o.mainBrightPink,
|
|
169
250
|
color: o.white,
|
|
170
|
-
...
|
|
171
|
-
...
|
|
251
|
+
...T.bold11,
|
|
252
|
+
...T.overflowEllipsis,
|
|
172
253
|
"&:hover": { borderColor: o.grey2 },
|
|
173
254
|
...e && {
|
|
174
|
-
[
|
|
255
|
+
[R.md]: {
|
|
175
256
|
height: 20,
|
|
176
257
|
padding: "2px 6px",
|
|
177
|
-
...
|
|
258
|
+
...T.bold10
|
|
178
259
|
},
|
|
179
|
-
[
|
|
260
|
+
[R.sm]: {
|
|
180
261
|
height: 16,
|
|
181
262
|
padding: "1px 4px",
|
|
182
|
-
...
|
|
263
|
+
...T.normal10
|
|
183
264
|
},
|
|
184
|
-
[
|
|
265
|
+
[R.xs]: {
|
|
185
266
|
height: 12,
|
|
186
267
|
padding: "0px 4px",
|
|
187
268
|
fontSize: 8,
|
|
@@ -190,46 +271,46 @@ function J(e) {
|
|
|
190
271
|
}
|
|
191
272
|
};
|
|
192
273
|
}
|
|
193
|
-
var
|
|
194
|
-
|
|
195
|
-
return
|
|
274
|
+
var Z = (0, U.createContext)({});
|
|
275
|
+
U.forwardRef(function(e, t) {
|
|
276
|
+
return U.createElement("img", {
|
|
196
277
|
...e,
|
|
197
278
|
ref: t,
|
|
198
279
|
src: "data:image/svg+xml,%3Csvg%20width%3D%2232%22%20height%3D%2232%22%20viewBox%3D%220%200%2032%2032%22%20fill%3D%22none%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%0A%3Cpath%20d%3D%22M28.2534%2028.2533L27.2134%2027.2133L24.0001%2024L17.8801%2017.88L4.78677%204.78666L3.74677%203.74666C3.22677%203.22666%202.38677%203.22666%201.86677%203.74666C1.33344%204.26666%201.33344%205.10666%201.85344%205.62666L4.0001%207.77333V25.3333C4.0001%2026.8%205.2001%2028%206.66677%2028H24.2268L26.3734%2030.1467C26.8934%2030.6667%2027.7334%2030.6667%2028.2534%2030.1467C28.7734%2029.6267%2028.7734%2028.7733%2028.2534%2028.2533ZM8.02677%2024C7.46677%2024%207.1601%2023.36%207.50677%2022.92L10.8268%2018.6533C11.0934%2018.32%2011.6001%2018.3067%2011.8668%2018.64L14.6668%2022.0133L16.2268%2020L20.2268%2024H8.02677ZM28.0001%2024.2267L7.77344%203.99999H25.3334C26.8001%203.99999%2028.0001%205.19999%2028.0001%206.66666V24.2267Z%22%20fill%3D%22%23BDBDBD%22%2F%3E%0A%3C%2Fsvg%3E%0A"
|
|
199
280
|
});
|
|
200
281
|
});
|
|
201
|
-
var
|
|
282
|
+
var je = (e, t) => typeof e == "number" && typeof t == "number" ? e / t : 0, Me = (e, t, n, r, i, a) => {
|
|
202
283
|
let o = "";
|
|
203
284
|
if (e) {
|
|
204
285
|
t && (o += `${t}: `);
|
|
205
|
-
let r =
|
|
286
|
+
let r = q(e, n);
|
|
206
287
|
o += r;
|
|
207
288
|
}
|
|
208
289
|
if (r) {
|
|
209
290
|
e && (o += " | "), i && (o += `${i}: `);
|
|
210
|
-
let t =
|
|
291
|
+
let t = q(r, a);
|
|
211
292
|
o += t;
|
|
212
293
|
}
|
|
213
294
|
return o;
|
|
214
|
-
},
|
|
295
|
+
}, Ne = E({ iconContainer: {
|
|
215
296
|
width: 16,
|
|
216
297
|
flexShrink: 0
|
|
217
|
-
} }),
|
|
218
|
-
let a =
|
|
219
|
-
return /* @__PURE__ */ (0,
|
|
298
|
+
} }), Pe = ({ disabled: e, isApplied: t, isSelected: n, isNot: r, fontColor: i }) => {
|
|
299
|
+
let a = Ne(), s = i ?? (t ? o.mainDarkNavy : void 0);
|
|
300
|
+
return /* @__PURE__ */ (0, W.jsxs)("div", {
|
|
220
301
|
className: a.iconContainer,
|
|
221
302
|
style: { opacity: e ? .25 : void 0 },
|
|
222
|
-
children: [n && r ? /* @__PURE__ */ (0,
|
|
303
|
+
children: [n && r ? /* @__PURE__ */ (0, W.jsx)(j, { fill: o.mainBrightPink }) : null, n && !r ? /* @__PURE__ */ (0, W.jsx)(y, { fill: s }) : null]
|
|
223
304
|
});
|
|
224
|
-
},
|
|
225
|
-
let { r: t, g: n, b: r, a: i } =
|
|
226
|
-
return
|
|
305
|
+
}, Fe = (e) => {
|
|
306
|
+
let { r: t, g: n, b: r, a: i } = G(e) ? fe(e) : de(e), a = (i ?? 1) * .6;
|
|
307
|
+
return ue({
|
|
227
308
|
r: t,
|
|
228
309
|
g: n,
|
|
229
310
|
b: r,
|
|
230
311
|
a: a < 0 ? 0 : a
|
|
231
312
|
});
|
|
232
|
-
},
|
|
313
|
+
}, Ie = E({
|
|
233
314
|
progressBar: {
|
|
234
315
|
height: "100%",
|
|
235
316
|
borderRadius: "4px",
|
|
@@ -253,8 +334,8 @@ var _e = (e, t) => typeof e == "number" && typeof t == "number" ? e / t : 0, ve
|
|
|
253
334
|
}
|
|
254
335
|
},
|
|
255
336
|
label: ({ responsive: e, fontSize: t }) => ({
|
|
256
|
-
...
|
|
257
|
-
...
|
|
337
|
+
...T.normal11,
|
|
338
|
+
...T.overflowEllipsis,
|
|
258
339
|
color: "inherit",
|
|
259
340
|
marginRight: "5px",
|
|
260
341
|
height: "100%",
|
|
@@ -265,14 +346,14 @@ var _e = (e, t) => typeof e == "number" && typeof t == "number" ? e / t : 0, ve
|
|
|
265
346
|
fontSize: `${t}px`,
|
|
266
347
|
lineHeight: 1.2,
|
|
267
348
|
...e && {
|
|
268
|
-
[
|
|
269
|
-
[
|
|
270
|
-
[
|
|
271
|
-
fontSize: `min(${t *
|
|
349
|
+
[R.md]: { fontSize: `min(${t * z.md}px, 14px)` },
|
|
350
|
+
[R.sm]: { fontSize: `min(${t * z.sm}px, 12px)` },
|
|
351
|
+
[R.xs]: {
|
|
352
|
+
fontSize: `min(${t * z.xs}px, 10px)`,
|
|
272
353
|
fontWeight: "normal !important"
|
|
273
354
|
}
|
|
274
355
|
}
|
|
275
|
-
} :
|
|
356
|
+
} : B(e)
|
|
276
357
|
}),
|
|
277
358
|
dimensionLabel: {
|
|
278
359
|
paddingLeft: 4,
|
|
@@ -284,54 +365,54 @@ var _e = (e, t) => typeof e == "number" && typeof t == "number" ? e / t : 0, ve
|
|
|
284
365
|
flexShrink: 1
|
|
285
366
|
},
|
|
286
367
|
rowDisabled: { color: o.grey3 }
|
|
287
|
-
}),
|
|
288
|
-
let
|
|
289
|
-
responsive:
|
|
290
|
-
fontSize:
|
|
291
|
-
}),
|
|
292
|
-
...
|
|
293
|
-
...
|
|
294
|
-
strikethrough:
|
|
295
|
-
},
|
|
296
|
-
...
|
|
297
|
-
textAlign:
|
|
298
|
-
justifyContent:
|
|
368
|
+
}), Le = ({ dimensionDisplayValue: e, measuresLabel: t, showLabelProgress: n, isSelected: r, isApplied: i, strikethrough: a, disabled: s, searchTerm: c, barWidth: l, fontStyle: u, progressColor: d = o.lightBlue, textAlign: f, responsive: p, fontSize: m }) => {
|
|
369
|
+
let h = Ie({
|
|
370
|
+
responsive: p,
|
|
371
|
+
fontSize: m
|
|
372
|
+
}), g = S()?.astrato ?? v, _ = {
|
|
373
|
+
...Y({
|
|
374
|
+
...u,
|
|
375
|
+
strikethrough: u?.strikethrough || a
|
|
376
|
+
}, g),
|
|
377
|
+
...f ? {
|
|
378
|
+
textAlign: f,
|
|
379
|
+
justifyContent: f === "right" ? "flex-end" : f === "center" ? "center" : "flex-start"
|
|
299
380
|
} : {}
|
|
300
|
-
},
|
|
301
|
-
return /* @__PURE__ */ (0,
|
|
302
|
-
className:
|
|
303
|
-
[
|
|
304
|
-
[
|
|
381
|
+
}, y = r || i ? d : Fe(d);
|
|
382
|
+
return /* @__PURE__ */ (0, W.jsxs)("div", {
|
|
383
|
+
className: b({
|
|
384
|
+
[h.labelsContainer]: !0,
|
|
385
|
+
[h.progressBarSelectedOrApplied]: r || i
|
|
305
386
|
}),
|
|
306
387
|
children: [
|
|
307
|
-
n && /* @__PURE__ */ (0,
|
|
388
|
+
n && /* @__PURE__ */ (0, W.jsx)("div", {
|
|
308
389
|
style: {
|
|
309
|
-
width: `${
|
|
310
|
-
backgroundColor:
|
|
390
|
+
width: `${l * 100}%`,
|
|
391
|
+
backgroundColor: y
|
|
311
392
|
},
|
|
312
|
-
className:
|
|
313
|
-
[
|
|
314
|
-
[
|
|
393
|
+
className: b({
|
|
394
|
+
[h.progressBar]: !0,
|
|
395
|
+
[h.rowDisabled]: s
|
|
315
396
|
}),
|
|
316
397
|
"data-testid": "item-list-label-progress"
|
|
317
398
|
}),
|
|
318
|
-
/* @__PURE__ */ (0,
|
|
319
|
-
style:
|
|
320
|
-
className:
|
|
399
|
+
/* @__PURE__ */ (0, W.jsx)("span", {
|
|
400
|
+
style: _,
|
|
401
|
+
className: b(h.label, h.dimensionLabel),
|
|
321
402
|
title: e,
|
|
322
|
-
children: /* @__PURE__ */ (0,
|
|
323
|
-
phrase:
|
|
403
|
+
children: /* @__PURE__ */ (0, W.jsx)(F, {
|
|
404
|
+
phrase: c ?? "",
|
|
324
405
|
children: e ?? ""
|
|
325
406
|
})
|
|
326
407
|
}),
|
|
327
|
-
/* @__PURE__ */ (0,
|
|
328
|
-
style:
|
|
329
|
-
className:
|
|
408
|
+
/* @__PURE__ */ (0, W.jsx)("span", {
|
|
409
|
+
style: _,
|
|
410
|
+
className: b(h.label, h.measuresLabel),
|
|
330
411
|
children: t
|
|
331
412
|
})
|
|
332
413
|
]
|
|
333
414
|
});
|
|
334
|
-
},
|
|
415
|
+
}, Re = E({
|
|
335
416
|
rowWrapper: (e) => ({
|
|
336
417
|
cursor: "pointer",
|
|
337
418
|
userSelect: "none",
|
|
@@ -343,15 +424,15 @@ var _e = (e, t) => typeof e == "number" && typeof t == "number" ? e / t : 0, ve
|
|
|
343
424
|
borderRadius: 6,
|
|
344
425
|
paddingRight: 8,
|
|
345
426
|
...e && {
|
|
346
|
-
[
|
|
427
|
+
[R.md]: {
|
|
347
428
|
height: "24px",
|
|
348
429
|
paddingRight: 6
|
|
349
430
|
},
|
|
350
|
-
[
|
|
431
|
+
[R.sm]: {
|
|
351
432
|
height: "16px",
|
|
352
433
|
paddingRight: 4
|
|
353
434
|
},
|
|
354
|
-
[
|
|
435
|
+
[R.xs]: {
|
|
355
436
|
height: "12px",
|
|
356
437
|
paddingRight: 2
|
|
357
438
|
}
|
|
@@ -363,21 +444,21 @@ var _e = (e, t) => typeof e == "number" && typeof t == "number" ? e / t : 0, ve
|
|
|
363
444
|
flexShrink: 0,
|
|
364
445
|
marginRight: 6,
|
|
365
446
|
...e && {
|
|
366
|
-
[
|
|
447
|
+
[R.md]: {
|
|
367
448
|
"& input[type=\"checkbox\"], & svg": {
|
|
368
449
|
width: "14px !important",
|
|
369
450
|
height: "14px !important"
|
|
370
451
|
},
|
|
371
452
|
"& > div, & > div > div": { height: "14px" }
|
|
372
453
|
},
|
|
373
|
-
[
|
|
454
|
+
[R.sm]: {
|
|
374
455
|
"& input[type=\"checkbox\"], & svg": {
|
|
375
456
|
width: "11px !important",
|
|
376
457
|
height: "11px !important"
|
|
377
458
|
},
|
|
378
459
|
"& > div, & > div > div": { height: "11px" }
|
|
379
460
|
},
|
|
380
|
-
[
|
|
461
|
+
[R.xs]: {
|
|
381
462
|
"& input[type=\"checkbox\"], & svg": {
|
|
382
463
|
width: "10px !important",
|
|
383
464
|
height: "10px !important"
|
|
@@ -393,16 +474,16 @@ var _e = (e, t) => typeof e == "number" && typeof t == "number" ? e / t : 0, ve
|
|
|
393
474
|
"& > div > span": { color: `${o.mainDarkNavy} !important` }
|
|
394
475
|
},
|
|
395
476
|
rowDisabled: { "& span": { color: `${o.grey3} !important` } }
|
|
396
|
-
}), Q = ({ selected: e, applied: t, disabled: n, hoverColor: r, onSelect: i, showProgressBar: a, showCheckbox: s, showSelectionIcon: c = !0, checkboxState: l = "none", fontSize: u, searchTerm: d, doneRenderingCallback: f, dimensionValue: p, dimensionFormatter:
|
|
397
|
-
let O =
|
|
398
|
-
return (0,
|
|
477
|
+
}), Q = ({ selected: e, applied: t, disabled: n, hoverColor: r, onSelect: i, showProgressBar: a, showCheckbox: s, showSelectionIcon: c = !0, checkboxState: l = "none", fontSize: u, searchTerm: d, doneRenderingCallback: f, dimensionValue: p, dimensionFormatter: m, imageValue: h, measure1Value: g, measure1Label: _, measure1Formatter: v, measure2Value: y, measure2Label: x, measure2Formatter: S, maxValue: C, imageFit: w, fontStyle: T, progressBarColor: E, responsive: D }) => {
|
|
478
|
+
let O = Re(D), k = (0, U.useContext)(Z), A = (k.pendingOperator ?? k.appliedOperator) === H.FilterOperator.NotInList, j = !!h, M = a && g !== void 0 && !y, N = q(p, m), P = Me(g, _, v, y, x, S);
|
|
479
|
+
return (0, U.useEffect)(() => {
|
|
399
480
|
j || f?.();
|
|
400
|
-
}, []), /* @__PURE__ */ (0,
|
|
481
|
+
}, []), /* @__PURE__ */ (0, W.jsxs)("div", {
|
|
401
482
|
tabIndex: 0,
|
|
402
483
|
role: "button",
|
|
403
484
|
onClick: i,
|
|
404
485
|
"data-testid": `big-list-item-dimension-${p}`,
|
|
405
|
-
className:
|
|
486
|
+
className: b({
|
|
406
487
|
[O.rowWrapper]: !0,
|
|
407
488
|
[O.rowHover]: !M,
|
|
408
489
|
[O.rowSelected]: !M && e,
|
|
@@ -411,21 +492,21 @@ var _e = (e, t) => typeof e == "number" && typeof t == "number" ? e / t : 0, ve
|
|
|
411
492
|
}),
|
|
412
493
|
style: { "--filter-hover-color": r ?? o.grey5 },
|
|
413
494
|
children: [
|
|
414
|
-
s ? /* @__PURE__ */ (0,
|
|
495
|
+
s ? /* @__PURE__ */ (0, W.jsx)("div", {
|
|
415
496
|
"aria-hidden": !0,
|
|
416
497
|
style: { pointerEvents: "none" },
|
|
417
498
|
className: O.checkboxWrapper,
|
|
418
|
-
children: /* @__PURE__ */ (0,
|
|
499
|
+
children: /* @__PURE__ */ (0, W.jsx)(I, {
|
|
419
500
|
value: l,
|
|
420
501
|
onChange: () => void 0,
|
|
421
502
|
testId: `dimension-${p}-checkbox`
|
|
422
503
|
})
|
|
423
504
|
}) : null,
|
|
424
|
-
j && /* @__PURE__ */ (0,
|
|
505
|
+
j && /* @__PURE__ */ (0, W.jsx)("img", {
|
|
425
506
|
alt: "",
|
|
426
507
|
width: 32,
|
|
427
508
|
height: 32,
|
|
428
|
-
src:
|
|
509
|
+
src: h,
|
|
429
510
|
onError: (e) => {
|
|
430
511
|
e.currentTarget.src = "data:image/svg+xml,%3Csvg%20width%3D%2232%22%20height%3D%2232%22%20viewBox%3D%220%200%2032%2032%22%20fill%3D%22none%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%0A%3Cpath%20d%3D%22M28.2534%2028.2533L27.2134%2027.2133L24.0001%2024L17.8801%2017.88L4.78677%204.78666L3.74677%203.74666C3.22677%203.22666%202.38677%203.22666%201.86677%203.74666C1.33344%204.26666%201.33344%205.10666%201.85344%205.62666L4.0001%207.77333V25.3333C4.0001%2026.8%205.2001%2028%206.66677%2028H24.2268L26.3734%2030.1467C26.8934%2030.6667%2027.7334%2030.6667%2028.2534%2030.1467C28.7734%2029.6267%2028.7734%2028.7733%2028.2534%2028.2533ZM8.02677%2024C7.46677%2024%207.1601%2023.36%207.50677%2022.92L10.8268%2018.6533C11.0934%2018.32%2011.6001%2018.3067%2011.8668%2018.64L14.6668%2022.0133L16.2268%2020L20.2268%2024H8.02677ZM28.0001%2024.2267L7.77344%203.99999H25.3334C26.8001%203.99999%2028.0001%205.19999%2028.0001%206.66666V24.2267Z%22%20fill%3D%22%23BDBDBD%22%2F%3E%0A%3C%2Fsvg%3E%0A", f?.();
|
|
431
512
|
},
|
|
@@ -438,7 +519,7 @@ var _e = (e, t) => typeof e == "number" && typeof t == "number" ? e / t : 0, ve
|
|
|
438
519
|
onLoad: f,
|
|
439
520
|
loading: "lazy"
|
|
440
521
|
}),
|
|
441
|
-
/* @__PURE__ */ (0,
|
|
522
|
+
/* @__PURE__ */ (0, W.jsx)(Le, {
|
|
442
523
|
dimensionDisplayValue: N,
|
|
443
524
|
measuresLabel: P,
|
|
444
525
|
showLabelProgress: M,
|
|
@@ -448,12 +529,12 @@ var _e = (e, t) => typeof e == "number" && typeof t == "number" ? e / t : 0, ve
|
|
|
448
529
|
strikethrough: A && t && e,
|
|
449
530
|
disabled: n,
|
|
450
531
|
searchTerm: d,
|
|
451
|
-
barWidth:
|
|
532
|
+
barWidth: je(g, C),
|
|
452
533
|
fontStyle: T,
|
|
453
534
|
responsive: D,
|
|
454
535
|
fontSize: u
|
|
455
536
|
}),
|
|
456
|
-
!s && c ? /* @__PURE__ */ (0,
|
|
537
|
+
!s && c ? /* @__PURE__ */ (0, W.jsx)(Pe, {
|
|
457
538
|
disabled: n,
|
|
458
539
|
isApplied: t,
|
|
459
540
|
isSelected: e,
|
|
@@ -462,21 +543,21 @@ var _e = (e, t) => typeof e == "number" && typeof t == "number" ? e / t : 0, ve
|
|
|
462
543
|
}) : null
|
|
463
544
|
]
|
|
464
545
|
});
|
|
465
|
-
},
|
|
466
|
-
let t = [...e].sort((e, t) =>
|
|
546
|
+
}, ze = (e) => {
|
|
547
|
+
let t = [...e].sort((e, t) => Be(e?.measure1 ?? void 0, t?.measure1 ?? void 0)), n = t.length > 0 ? t[0] : null;
|
|
467
548
|
return typeof n?.measure1 == "number" ? n : null;
|
|
468
|
-
},
|
|
549
|
+
}, Be = (e, t) => {
|
|
469
550
|
if (e && t) {
|
|
470
551
|
if (e < t) return 1;
|
|
471
552
|
if (e > t) return -1;
|
|
472
553
|
} else if (e && !t) return -1;
|
|
473
554
|
return 0;
|
|
474
|
-
},
|
|
475
|
-
let s = (0,
|
|
555
|
+
}, Ve = ({ filterValues: e, onItemClick: t, selectedValues: n, appliedValues: r, searchTerm: i, vSpec: a, hoverColor: o }) => {
|
|
556
|
+
let s = (0, U.useRef)(e.length), c = O(), l = () => {
|
|
476
557
|
--s.current, s.current === 0 && c();
|
|
477
558
|
};
|
|
478
559
|
if (!a?.dimensions[0]?.dataItem) return null;
|
|
479
|
-
let u = a.dimensions[0]?.formatter, d = a.dimensions[1]?.imageFit, f = a.measures[0]?.formatter, p = a.measures[1]?.formatter, [m, h] =
|
|
560
|
+
let u = a.dimensions[0]?.formatter, d = a.dimensions[1]?.imageFit, f = a.measures[0]?.formatter, p = a.measures[1]?.formatter, [m, h] = ye(e, r), g = (e, r) => {
|
|
480
561
|
switch (!0) {
|
|
481
562
|
case n.includes(e.dimension):
|
|
482
563
|
t(e.dimension);
|
|
@@ -484,8 +565,8 @@ var _e = (e, t) => typeof e == "number" && typeof t == "number" ? e / t : 0, ve
|
|
|
484
565
|
case e.disabled: break;
|
|
485
566
|
default: t(e.dimension, { shift: r.shiftKey ? [...m, ...h].reduce((e, t) => (t.disabled || e.push(t.dimension), e), []) : null });
|
|
486
567
|
}
|
|
487
|
-
}, _ =
|
|
488
|
-
return /* @__PURE__ */ (0,
|
|
568
|
+
}, _ = ze(e), v = s.current > 0 ? l : void 0;
|
|
569
|
+
return /* @__PURE__ */ (0, W.jsxs)(W.Fragment, { children: [m.map((e) => /* @__PURE__ */ (0, W.jsx)(Q, {
|
|
489
570
|
searchTerm: i,
|
|
490
571
|
disabled: !!e.disabled,
|
|
491
572
|
onSelect: (t) => g(e, t),
|
|
@@ -508,7 +589,7 @@ var _e = (e, t) => typeof e == "number" && typeof t == "number" ? e / t : 0, ve
|
|
|
508
589
|
fontStyle: a.filterSettings?.fontStyle,
|
|
509
590
|
progressBarColor: a.filterSettings?.filterStyle?.progressBarColor,
|
|
510
591
|
responsive: a.filterSettings?.responsive
|
|
511
|
-
}, String(e.dimension))), h.map((e) => /* @__PURE__ */ (0,
|
|
592
|
+
}, String(e.dimension))), h.map((e) => /* @__PURE__ */ (0, W.jsx)(Q, {
|
|
512
593
|
searchTerm: i,
|
|
513
594
|
disabled: !!e.disabled,
|
|
514
595
|
onSelect: (t) => g(e, t),
|
|
@@ -532,7 +613,7 @@ var _e = (e, t) => typeof e == "number" && typeof t == "number" ? e / t : 0, ve
|
|
|
532
613
|
progressBarColor: a.filterSettings?.filterStyle?.progressBarColor,
|
|
533
614
|
responsive: a.filterSettings?.responsive
|
|
534
615
|
}, String(e.dimension)))] });
|
|
535
|
-
},
|
|
616
|
+
}, He = E({
|
|
536
617
|
rowWrapper: (e) => ({
|
|
537
618
|
userSelect: "none",
|
|
538
619
|
display: "flex",
|
|
@@ -544,12 +625,12 @@ var _e = (e, t) => typeof e == "number" && typeof t == "number" ? e / t : 0, ve
|
|
|
544
625
|
padding: 4,
|
|
545
626
|
borderRadius: 5,
|
|
546
627
|
...e && {
|
|
547
|
-
[
|
|
548
|
-
[
|
|
628
|
+
[R.md]: { height: 24 },
|
|
629
|
+
[R.sm]: {
|
|
549
630
|
height: 20,
|
|
550
631
|
padding: "2px 4px"
|
|
551
632
|
},
|
|
552
|
-
[
|
|
633
|
+
[R.xs]: {
|
|
553
634
|
height: 16,
|
|
554
635
|
padding: "1px 4px"
|
|
555
636
|
}
|
|
@@ -557,7 +638,7 @@ var _e = (e, t) => typeof e == "number" && typeof t == "number" ? e / t : 0, ve
|
|
|
557
638
|
"& > span": {
|
|
558
639
|
flexShrink: 0,
|
|
559
640
|
maxWidth: "100%",
|
|
560
|
-
...
|
|
641
|
+
...T.overflowEllipsis
|
|
561
642
|
}
|
|
562
643
|
}),
|
|
563
644
|
rowWrapperClickable: {
|
|
@@ -577,28 +658,28 @@ var _e = (e, t) => typeof e == "number" && typeof t == "number" ? e / t : 0, ve
|
|
|
577
658
|
}
|
|
578
659
|
},
|
|
579
660
|
rowDisabled: { "& span": { color: `${o.grey3} !important` } },
|
|
580
|
-
label: (e) => ({ ...
|
|
581
|
-
}), $ = ({ selected: e, applied: t, disabled: n, hoverColor: r, dimensionValue: i, dimensionFormatter:
|
|
582
|
-
let
|
|
583
|
-
...
|
|
661
|
+
label: (e) => ({ ...B(e) })
|
|
662
|
+
}), $ = ({ selected: e, applied: t, disabled: n, hoverColor: r, dimensionValue: i, dimensionFormatter: a, searchTerm: s, onSelect: c, fontStyle: l, responsive: u, showCheckbox: d, showSelectionIcon: f = !0, checkboxState: p = "none", alignContentStart: m, fontSize: h }) => {
|
|
663
|
+
let g = He(u), _ = S()?.astrato ?? v, y = q(i, a), x = (0, U.useContext)(Z), C = (x.pendingOperator ?? x.appliedOperator) === H.FilterOperator.NotInList, w = C && t && e, T = Y({
|
|
664
|
+
...l,
|
|
584
665
|
strikethrough: w
|
|
585
|
-
},
|
|
586
|
-
return /* @__PURE__ */ (0,
|
|
666
|
+
}, _);
|
|
667
|
+
return /* @__PURE__ */ (0, W.jsxs)("div", {
|
|
587
668
|
tabIndex: 0,
|
|
588
669
|
role: "button",
|
|
589
|
-
onClick:
|
|
670
|
+
onClick: c,
|
|
590
671
|
"data-testid": `small-list-item-dimension-${i}`,
|
|
591
|
-
className:
|
|
592
|
-
[
|
|
593
|
-
[
|
|
594
|
-
[
|
|
595
|
-
[
|
|
596
|
-
[
|
|
597
|
-
[
|
|
672
|
+
className: b({
|
|
673
|
+
[g.rowWrapper]: !0,
|
|
674
|
+
[g.rowWrapperClickable]: !!c,
|
|
675
|
+
[g.rowWrapperStartAligned]: m,
|
|
676
|
+
[g.rowSelected]: e,
|
|
677
|
+
[g.rowApplied]: t && !e,
|
|
678
|
+
[g.rowDisabled]: n
|
|
598
679
|
}),
|
|
599
680
|
style: { "--filter-hover-color": r ?? o.grey5 },
|
|
600
681
|
children: [
|
|
601
|
-
|
|
682
|
+
d ? /* @__PURE__ */ (0, W.jsx)("div", {
|
|
602
683
|
"aria-hidden": !0,
|
|
603
684
|
style: {
|
|
604
685
|
display: "flex",
|
|
@@ -607,38 +688,38 @@ var _e = (e, t) => typeof e == "number" && typeof t == "number" ? e / t : 0, ve
|
|
|
607
688
|
marginRight: 6,
|
|
608
689
|
pointerEvents: "none"
|
|
609
690
|
},
|
|
610
|
-
children: /* @__PURE__ */ (0,
|
|
611
|
-
value:
|
|
691
|
+
children: /* @__PURE__ */ (0, W.jsx)(I, {
|
|
692
|
+
value: p,
|
|
612
693
|
onChange: () => void 0
|
|
613
694
|
})
|
|
614
695
|
}) : null,
|
|
615
|
-
/* @__PURE__ */ (0,
|
|
616
|
-
className:
|
|
696
|
+
/* @__PURE__ */ (0, W.jsx)("span", {
|
|
697
|
+
className: g.label,
|
|
617
698
|
style: {
|
|
618
699
|
...T,
|
|
619
|
-
...
|
|
620
|
-
fontSize:
|
|
700
|
+
...h ? {
|
|
701
|
+
fontSize: h,
|
|
621
702
|
lineHeight: "14px"
|
|
622
703
|
} : {}
|
|
623
704
|
},
|
|
624
|
-
children: /* @__PURE__ */ (0,
|
|
625
|
-
phrase:
|
|
626
|
-
children:
|
|
705
|
+
children: /* @__PURE__ */ (0, W.jsx)(F, {
|
|
706
|
+
phrase: s ?? "",
|
|
707
|
+
children: y ?? ""
|
|
627
708
|
})
|
|
628
709
|
}),
|
|
629
|
-
|
|
710
|
+
d ? null : /* @__PURE__ */ (0, W.jsx)(Pe, {
|
|
630
711
|
disabled: n,
|
|
631
712
|
isApplied: t,
|
|
632
|
-
isSelected:
|
|
713
|
+
isSelected: f && e,
|
|
633
714
|
isNot: C,
|
|
634
|
-
fontColor:
|
|
715
|
+
fontColor: l?.fontColor ?? void 0
|
|
635
716
|
})
|
|
636
717
|
]
|
|
637
718
|
});
|
|
638
|
-
},
|
|
719
|
+
}, Ue = ({ filterValues: e, onItemClick: t, selectedValues: n, appliedValues: r, searchTerm: i, vSpec: a, hoverColor: o }) => {
|
|
639
720
|
let s = a.dimensions[0]?.formatter;
|
|
640
721
|
if (!a?.dimensions[0]?.dataItem) return null;
|
|
641
|
-
let [c, l] =
|
|
722
|
+
let [c, l] = ye(e, r), u = (e, r) => {
|
|
642
723
|
switch (!0) {
|
|
643
724
|
case n.includes(e.dimension):
|
|
644
725
|
t(e.dimension);
|
|
@@ -647,7 +728,7 @@ var _e = (e, t) => typeof e == "number" && typeof t == "number" ? e / t : 0, ve
|
|
|
647
728
|
default: t(e.dimension, { shift: r.shiftKey ? [...c, ...l].reduce((e, t) => (t.disabled || e.push(t.dimension), e), []) : null });
|
|
648
729
|
}
|
|
649
730
|
};
|
|
650
|
-
return /* @__PURE__ */ (0,
|
|
731
|
+
return /* @__PURE__ */ (0, W.jsxs)(W.Fragment, { children: [c.map((e) => /* @__PURE__ */ (0, W.jsx)($, {
|
|
651
732
|
searchTerm: i,
|
|
652
733
|
disabled: !!e.disabled,
|
|
653
734
|
dimensionValue: e.dimension,
|
|
@@ -658,7 +739,7 @@ var _e = (e, t) => typeof e == "number" && typeof t == "number" ? e / t : 0, ve
|
|
|
658
739
|
hoverColor: o,
|
|
659
740
|
fontStyle: a.filterSettings?.fontStyle,
|
|
660
741
|
responsive: a.filterSettings?.responsive
|
|
661
|
-
}, `applied-${e.dimension}`)), l.map((e) => /* @__PURE__ */ (0,
|
|
742
|
+
}, `applied-${e.dimension}`)), l.map((e) => /* @__PURE__ */ (0, W.jsx)($, {
|
|
662
743
|
searchTerm: i,
|
|
663
744
|
disabled: !!e.disabled,
|
|
664
745
|
dimensionValue: e.dimension,
|
|
@@ -670,28 +751,28 @@ var _e = (e, t) => typeof e == "number" && typeof t == "number" ? e / t : 0, ve
|
|
|
670
751
|
fontStyle: a.filterSettings?.fontStyle,
|
|
671
752
|
responsive: a.filterSettings?.responsive
|
|
672
753
|
}, `not-applied-${e.dimension}`))] });
|
|
673
|
-
},
|
|
754
|
+
}, We = E({ dropdownContainer: {
|
|
674
755
|
overflow: "hidden",
|
|
675
756
|
backdropFilter: "blur(1.25px)",
|
|
676
757
|
zIndex: 1500
|
|
677
|
-
} }),
|
|
678
|
-
let r =
|
|
679
|
-
return /* @__PURE__ */ (0,
|
|
758
|
+
} }), Ge = ({ children: e, filterStyle: t, isLocked: n }) => {
|
|
759
|
+
let r = We(), i = X(t, n);
|
|
760
|
+
return /* @__PURE__ */ (0, W.jsx)("div", {
|
|
680
761
|
className: r.dropdownContainer,
|
|
681
762
|
style: i,
|
|
682
763
|
children: e
|
|
683
764
|
});
|
|
684
|
-
},
|
|
765
|
+
}, Ke = E({ root: {
|
|
685
766
|
background: o.grey5,
|
|
686
767
|
height: 2,
|
|
687
768
|
"& .MuiLinearProgress-bar": { background: o.mainDarkNavy }
|
|
688
|
-
} }),
|
|
689
|
-
let t =
|
|
690
|
-
return e ? /* @__PURE__ */ (0,
|
|
769
|
+
} }), qe = ({ loading: e }) => {
|
|
770
|
+
let t = Ke();
|
|
771
|
+
return e ? /* @__PURE__ */ (0, W.jsx)(ie, {
|
|
691
772
|
className: t.root,
|
|
692
773
|
"data-testid": "filter-search-progress"
|
|
693
774
|
}) : null;
|
|
694
|
-
},
|
|
775
|
+
}, Je = E({
|
|
695
776
|
dropdownButton: (e) => ({
|
|
696
777
|
cursor: "pointer",
|
|
697
778
|
display: "flex",
|
|
@@ -706,16 +787,16 @@ var _e = (e, t) => typeof e == "number" && typeof t == "number" ? e / t : 0, ve
|
|
|
706
787
|
outline: "none"
|
|
707
788
|
},
|
|
708
789
|
...e && {
|
|
709
|
-
[
|
|
710
|
-
[
|
|
790
|
+
[R.lg]: { height: "min(28px, 100%)" },
|
|
791
|
+
[R.md]: {
|
|
711
792
|
padding: "0 4px",
|
|
712
793
|
height: "min(24px, 100%)"
|
|
713
794
|
},
|
|
714
|
-
[
|
|
795
|
+
[R.sm]: {
|
|
715
796
|
padding: "0 2px",
|
|
716
797
|
height: "min(20px, 100%)"
|
|
717
798
|
},
|
|
718
|
-
[
|
|
799
|
+
[R.xs]: {
|
|
719
800
|
padding: 0,
|
|
720
801
|
height: "min(16px, 100%)"
|
|
721
802
|
}
|
|
@@ -732,17 +813,17 @@ var _e = (e, t) => typeof e == "number" && typeof t == "number" ? e / t : 0, ve
|
|
|
732
813
|
fontWeight: "bold !important",
|
|
733
814
|
flexShrink: 1,
|
|
734
815
|
minWidth: 0,
|
|
735
|
-
...
|
|
736
|
-
...
|
|
816
|
+
...T.overflowEllipsis,
|
|
817
|
+
...B(e)
|
|
737
818
|
}),
|
|
738
819
|
measureTitle: {
|
|
739
|
-
...
|
|
820
|
+
...T.overflowEllipsis,
|
|
740
821
|
minWidth: 0,
|
|
741
822
|
flexShrink: 1,
|
|
742
823
|
whiteSpaceCollapse: "preserve"
|
|
743
824
|
},
|
|
744
825
|
valuesLabel: {
|
|
745
|
-
...
|
|
826
|
+
...T.overflowEllipsis,
|
|
746
827
|
paddingLeft: 4,
|
|
747
828
|
fontWeight: "bold !important",
|
|
748
829
|
minWidth: 0,
|
|
@@ -753,71 +834,71 @@ var _e = (e, t) => typeof e == "number" && typeof t == "number" ? e / t : 0, ve
|
|
|
753
834
|
flexDirection: "row",
|
|
754
835
|
alignItems: "center",
|
|
755
836
|
boxSizing: "border-box",
|
|
756
|
-
...e &&
|
|
837
|
+
...e && L
|
|
757
838
|
}),
|
|
758
|
-
notPart: (e) => ({ ...
|
|
759
|
-
}),
|
|
760
|
-
let
|
|
761
|
-
button:
|
|
762
|
-
label:
|
|
763
|
-
},
|
|
764
|
-
return /* @__PURE__ */ (0,
|
|
839
|
+
notPart: (e) => ({ ...Ae(e) })
|
|
840
|
+
}), Ye = ({ dimensionTitle: e, measureTitle: t, isOpen: n, onToggle: r, dimensionFormatter: i, selectedValues: a = [], fontStyle: o, filterStyle: s, responsive: c, isLocked: l }) => {
|
|
841
|
+
let u = S()?.astrato ?? v, d = Je(c), f = (0, U.useContext)(Z), p = (f.pendingOperator ?? f.appliedOperator) === H.FilterOperator.NotInList, m = {
|
|
842
|
+
button: X(s),
|
|
843
|
+
label: Y(o, u)
|
|
844
|
+
}, h = m.label.color, g = (e) => String(typeof e == "boolean" ? e : i ? k(i, e) : e), _ = [...a].sort().slice(0, 15).map(g).join(", "), y = a.length > 0;
|
|
845
|
+
return /* @__PURE__ */ (0, W.jsxs)("div", {
|
|
765
846
|
role: "button",
|
|
766
847
|
tabIndex: 0,
|
|
767
848
|
"data-testid": "filter-header-dropdown",
|
|
768
|
-
className:
|
|
849
|
+
className: d.dropdownButton,
|
|
769
850
|
onClick: (e) => {
|
|
770
851
|
e.currentTarget.blur(), r?.();
|
|
771
852
|
},
|
|
772
853
|
onKeyUp: (e) => {
|
|
773
854
|
(e.key === "Enter" || e.key === " ") && (e.stopPropagation(), e.preventDefault(), r?.());
|
|
774
855
|
},
|
|
775
|
-
style:
|
|
776
|
-
children: [/* @__PURE__ */ (0,
|
|
777
|
-
className:
|
|
778
|
-
style: { color:
|
|
856
|
+
style: m.button,
|
|
857
|
+
children: [/* @__PURE__ */ (0, W.jsxs)("div", {
|
|
858
|
+
className: d.headerTitlesContainer,
|
|
859
|
+
style: { color: h },
|
|
779
860
|
children: [
|
|
780
|
-
|
|
861
|
+
l && /* @__PURE__ */ (0, W.jsx)(P, {
|
|
781
862
|
fill: "currentColor",
|
|
782
863
|
style: { marginRight: 8 }
|
|
783
864
|
}),
|
|
784
|
-
|
|
785
|
-
className:
|
|
865
|
+
p && /* @__PURE__ */ (0, W.jsx)("div", {
|
|
866
|
+
className: d.notPart,
|
|
786
867
|
children: "NOT"
|
|
787
868
|
}),
|
|
788
|
-
/* @__PURE__ */ (0,
|
|
789
|
-
className:
|
|
790
|
-
style:
|
|
869
|
+
/* @__PURE__ */ (0, W.jsx)("div", {
|
|
870
|
+
className: d.title,
|
|
871
|
+
style: m.label,
|
|
791
872
|
children: e
|
|
792
873
|
}),
|
|
793
|
-
/* @__PURE__ */ (0,
|
|
794
|
-
className:
|
|
874
|
+
/* @__PURE__ */ (0, W.jsxs)("div", {
|
|
875
|
+
className: d.title,
|
|
795
876
|
style: {
|
|
796
|
-
...
|
|
877
|
+
...m.label,
|
|
797
878
|
display: "flex"
|
|
798
879
|
},
|
|
799
|
-
children: [/* @__PURE__ */ (0,
|
|
800
|
-
className:
|
|
880
|
+
children: [/* @__PURE__ */ (0, W.jsx)("span", {
|
|
881
|
+
className: d.measureTitle,
|
|
801
882
|
children: t
|
|
802
|
-
}),
|
|
803
|
-
className:
|
|
804
|
-
children: [" ",
|
|
883
|
+
}), y && /* @__PURE__ */ (0, W.jsxs)("div", {
|
|
884
|
+
className: d.valuesLabel,
|
|
885
|
+
children: [" ", _]
|
|
805
886
|
})]
|
|
806
887
|
})
|
|
807
888
|
]
|
|
808
|
-
}), /* @__PURE__ */ (0,
|
|
809
|
-
className:
|
|
810
|
-
style: { color:
|
|
811
|
-
children: n ? /* @__PURE__ */ (0,
|
|
889
|
+
}), /* @__PURE__ */ (0, W.jsx)("div", {
|
|
890
|
+
className: d.expandIcon,
|
|
891
|
+
style: { color: h },
|
|
892
|
+
children: n ? /* @__PURE__ */ (0, W.jsx)(D, {
|
|
812
893
|
size: 24,
|
|
813
894
|
fill: "currentColor"
|
|
814
|
-
}) : /* @__PURE__ */ (0,
|
|
895
|
+
}) : /* @__PURE__ */ (0, W.jsx)(C, {
|
|
815
896
|
size: 24,
|
|
816
897
|
fill: "currentColor"
|
|
817
898
|
})
|
|
818
899
|
})]
|
|
819
900
|
});
|
|
820
|
-
},
|
|
901
|
+
}, Xe = E({
|
|
821
902
|
headerListbox: (e) => ({
|
|
822
903
|
height: 36,
|
|
823
904
|
margin: "0 12px 8px",
|
|
@@ -825,15 +906,15 @@ var _e = (e, t) => typeof e == "number" && typeof t == "number" ? e / t : 0, ve
|
|
|
825
906
|
alignItems: "center",
|
|
826
907
|
boxSizing: "border-box",
|
|
827
908
|
...e && {
|
|
828
|
-
[
|
|
909
|
+
[R.md]: {
|
|
829
910
|
height: 32,
|
|
830
911
|
margin: "0 12px 6px"
|
|
831
912
|
},
|
|
832
|
-
[
|
|
913
|
+
[R.sm]: {
|
|
833
914
|
height: 28,
|
|
834
915
|
margin: "0 12px 4px"
|
|
835
916
|
},
|
|
836
|
-
[
|
|
917
|
+
[R.xs]: {
|
|
837
918
|
height: 24,
|
|
838
919
|
margin: "0 12px"
|
|
839
920
|
}
|
|
@@ -850,12 +931,12 @@ var _e = (e, t) => typeof e == "number" && typeof t == "number" ? e / t : 0, ve
|
|
|
850
931
|
alignItems: "center"
|
|
851
932
|
},
|
|
852
933
|
title: (e) => ({
|
|
853
|
-
...
|
|
934
|
+
...T.overflowEllipsis,
|
|
854
935
|
fontWeight: "bold !important",
|
|
855
|
-
...
|
|
936
|
+
...B(e)
|
|
856
937
|
}),
|
|
857
938
|
iconButton: (e) => ({
|
|
858
|
-
...e &&
|
|
939
|
+
...e && L,
|
|
859
940
|
cursor: "pointer",
|
|
860
941
|
display: "inline-flex",
|
|
861
942
|
alignItems: "center",
|
|
@@ -872,19 +953,19 @@ var _e = (e, t) => typeof e == "number" && typeof t == "number" ? e / t : 0, ve
|
|
|
872
953
|
"&:hover": { boxShadow: "inset 0 0 0 1px currentColor" },
|
|
873
954
|
"&:focus": { outline: "none" },
|
|
874
955
|
...e && {
|
|
875
|
-
[
|
|
956
|
+
[R.md]: {
|
|
876
957
|
minWidth: 20,
|
|
877
958
|
width: 20,
|
|
878
959
|
height: 20,
|
|
879
960
|
borderRadius: 5
|
|
880
961
|
},
|
|
881
|
-
[
|
|
962
|
+
[R.sm]: {
|
|
882
963
|
minWidth: 16,
|
|
883
964
|
width: 16,
|
|
884
965
|
height: 16,
|
|
885
966
|
borderRadius: 4
|
|
886
967
|
},
|
|
887
|
-
[
|
|
968
|
+
[R.xs]: {
|
|
888
969
|
minWidth: 12,
|
|
889
970
|
width: 12,
|
|
890
971
|
height: 12,
|
|
@@ -892,79 +973,79 @@ var _e = (e, t) => typeof e == "number" && typeof t == "number" ? e / t : 0, ve
|
|
|
892
973
|
}
|
|
893
974
|
}
|
|
894
975
|
}),
|
|
895
|
-
notPart: (e) => ({ ...
|
|
896
|
-
}),
|
|
897
|
-
let
|
|
898
|
-
(0,
|
|
899
|
-
!r && i &&
|
|
976
|
+
notPart: (e) => ({ ...Ae(e) })
|
|
977
|
+
}), Ze = ({ children: e, dimensionTitle: t, measureTitle: n, searchEnabled: r, searchTerm: i, onSearchChange: a, onApplySearched: o, fontStyle: s, vTheme: c = v, isNotEnabled: l, responsive: u, isLocked: d }) => {
|
|
978
|
+
let f = Xe(u), p = Y(s, c), m = p.color, [h, g] = (0, U.useState)(!1);
|
|
979
|
+
(0, U.useEffect)(() => {
|
|
980
|
+
!r && i && a("");
|
|
900
981
|
}, [r]);
|
|
901
|
-
let
|
|
902
|
-
r &&
|
|
982
|
+
let _ = () => {
|
|
983
|
+
r && g(!0);
|
|
903
984
|
}, y = () => {
|
|
904
|
-
|
|
985
|
+
a(""), g(!1);
|
|
905
986
|
}, b = () => {
|
|
906
|
-
|
|
987
|
+
o();
|
|
907
988
|
};
|
|
908
|
-
return r ? /* @__PURE__ */ (0,
|
|
989
|
+
return r ? /* @__PURE__ */ (0, W.jsx)("div", {
|
|
909
990
|
"data-testid": "filter-header-title",
|
|
910
|
-
className:
|
|
911
|
-
style: { color:
|
|
912
|
-
children:
|
|
913
|
-
responsive:
|
|
991
|
+
className: f.headerListbox,
|
|
992
|
+
style: { color: m },
|
|
993
|
+
children: h ? /* @__PURE__ */ (0, W.jsxs)(W.Fragment, { children: [/* @__PURE__ */ (0, W.jsx)(re, {
|
|
994
|
+
responsive: u,
|
|
914
995
|
autoFocus: !0,
|
|
915
|
-
className:
|
|
996
|
+
className: f.headerListboxSearch,
|
|
916
997
|
"data-testid": "filter-search-input",
|
|
917
998
|
onChange: (e) => {
|
|
918
|
-
|
|
999
|
+
a(e.target.value);
|
|
919
1000
|
},
|
|
920
1001
|
style: {
|
|
921
|
-
color:
|
|
922
|
-
borderColor:
|
|
1002
|
+
color: m,
|
|
1003
|
+
borderColor: m
|
|
923
1004
|
},
|
|
924
|
-
onPaste:
|
|
1005
|
+
onPaste: Se(a),
|
|
925
1006
|
onKeyDown: (e) => {
|
|
926
1007
|
switch (e.key) {
|
|
927
1008
|
case "Enter":
|
|
928
1009
|
b();
|
|
929
1010
|
break;
|
|
930
1011
|
case "Escape":
|
|
931
|
-
y(),
|
|
1012
|
+
y(), a("");
|
|
932
1013
|
break;
|
|
933
1014
|
}
|
|
934
1015
|
},
|
|
935
1016
|
value: i
|
|
936
|
-
}), e] }) : /* @__PURE__ */ (0,
|
|
937
|
-
/* @__PURE__ */ (0,
|
|
1017
|
+
}), e] }) : /* @__PURE__ */ (0, W.jsxs)(W.Fragment, { children: [
|
|
1018
|
+
/* @__PURE__ */ (0, W.jsx)("button", {
|
|
938
1019
|
"data-testid": "filter-header-show-search-button",
|
|
939
|
-
onClick:
|
|
940
|
-
className:
|
|
1020
|
+
onClick: _,
|
|
1021
|
+
className: f.iconButton,
|
|
941
1022
|
style: { marginRight: 8 },
|
|
942
|
-
children: /* @__PURE__ */ (0,
|
|
1023
|
+
children: /* @__PURE__ */ (0, W.jsx)(N, {
|
|
943
1024
|
fill: "currentColor",
|
|
944
1025
|
size: 20
|
|
945
1026
|
})
|
|
946
1027
|
}),
|
|
947
|
-
|
|
1028
|
+
d && /* @__PURE__ */ (0, W.jsx)(P, {
|
|
948
1029
|
fill: "currentColor",
|
|
949
1030
|
style: { marginRight: 8 }
|
|
950
1031
|
}),
|
|
951
|
-
/* @__PURE__ */ (0,
|
|
952
|
-
onClick:
|
|
953
|
-
className:
|
|
1032
|
+
/* @__PURE__ */ (0, W.jsxs)("div", {
|
|
1033
|
+
onClick: _,
|
|
1034
|
+
className: f.headerTitlesContainer,
|
|
954
1035
|
children: [
|
|
955
|
-
|
|
956
|
-
className:
|
|
1036
|
+
l && /* @__PURE__ */ (0, W.jsx)("div", {
|
|
1037
|
+
className: f.notPart,
|
|
957
1038
|
children: "NOT"
|
|
958
1039
|
}),
|
|
959
|
-
/* @__PURE__ */ (0,
|
|
960
|
-
className:
|
|
961
|
-
style:
|
|
1040
|
+
/* @__PURE__ */ (0, W.jsx)("span", {
|
|
1041
|
+
className: f.title,
|
|
1042
|
+
style: p,
|
|
962
1043
|
children: t
|
|
963
1044
|
}),
|
|
964
|
-
/* @__PURE__ */ (0,
|
|
965
|
-
className:
|
|
1045
|
+
/* @__PURE__ */ (0, W.jsx)("span", {
|
|
1046
|
+
className: f.title,
|
|
966
1047
|
style: {
|
|
967
|
-
...
|
|
1048
|
+
...p,
|
|
968
1049
|
whiteSpaceCollapse: "preserve"
|
|
969
1050
|
},
|
|
970
1051
|
children: n
|
|
@@ -973,26 +1054,26 @@ var _e = (e, t) => typeof e == "number" && typeof t == "number" ? e / t : 0, ve
|
|
|
973
1054
|
}),
|
|
974
1055
|
e
|
|
975
1056
|
] })
|
|
976
|
-
}) : /* @__PURE__ */ (0,
|
|
1057
|
+
}) : /* @__PURE__ */ (0, W.jsxs)("div", {
|
|
977
1058
|
"data-testid": "filter-header-title",
|
|
978
|
-
className:
|
|
979
|
-
style: { color:
|
|
980
|
-
children: [/* @__PURE__ */ (0,
|
|
981
|
-
className:
|
|
1059
|
+
className: f.headerListbox,
|
|
1060
|
+
style: { color: m },
|
|
1061
|
+
children: [/* @__PURE__ */ (0, W.jsxs)("div", {
|
|
1062
|
+
className: f.headerTitlesContainer,
|
|
982
1063
|
children: [
|
|
983
|
-
|
|
984
|
-
className:
|
|
1064
|
+
l && /* @__PURE__ */ (0, W.jsx)("div", {
|
|
1065
|
+
className: f.notPart,
|
|
985
1066
|
children: "NOT"
|
|
986
1067
|
}),
|
|
987
|
-
/* @__PURE__ */ (0,
|
|
988
|
-
className:
|
|
989
|
-
style:
|
|
1068
|
+
/* @__PURE__ */ (0, W.jsx)("span", {
|
|
1069
|
+
className: f.title,
|
|
1070
|
+
style: p,
|
|
990
1071
|
children: t
|
|
991
1072
|
}),
|
|
992
|
-
/* @__PURE__ */ (0,
|
|
993
|
-
className:
|
|
1073
|
+
/* @__PURE__ */ (0, W.jsx)("span", {
|
|
1074
|
+
className: f.title,
|
|
994
1075
|
style: {
|
|
995
|
-
...
|
|
1076
|
+
...p,
|
|
996
1077
|
whiteSpaceCollapse: "preserve"
|
|
997
1078
|
},
|
|
998
1079
|
children: n
|
|
@@ -1000,40 +1081,40 @@ var _e = (e, t) => typeof e == "number" && typeof t == "number" ? e / t : 0, ve
|
|
|
1000
1081
|
]
|
|
1001
1082
|
}), e]
|
|
1002
1083
|
});
|
|
1003
|
-
},
|
|
1084
|
+
}, Qe = E({
|
|
1004
1085
|
container: ({ responsive: e, isDropdown: t }) => ({
|
|
1005
1086
|
margin: 0,
|
|
1006
1087
|
padding: 0,
|
|
1007
1088
|
...!t && {
|
|
1008
1089
|
height: "calc(100% - 44px)",
|
|
1009
1090
|
...e && {
|
|
1010
|
-
[
|
|
1011
|
-
[
|
|
1091
|
+
[R.sm]: { height: "calc(100% - 36px)" },
|
|
1092
|
+
[R.xs]: { height: "calc(100% - 32px)" }
|
|
1012
1093
|
}
|
|
1013
1094
|
}
|
|
1014
1095
|
}),
|
|
1015
1096
|
scrollContainer: ({ responsive: e }) => ({
|
|
1016
|
-
...
|
|
1097
|
+
...te.propertiesPanel,
|
|
1017
1098
|
padding: "0 12px",
|
|
1018
1099
|
...e && {
|
|
1019
|
-
[
|
|
1020
|
-
[
|
|
1021
|
-
[
|
|
1100
|
+
[R.md]: { padding: "0 8px" },
|
|
1101
|
+
[R.sm]: { padding: "0 6px" },
|
|
1102
|
+
[R.xs]: { padding: "0 4px" }
|
|
1022
1103
|
}
|
|
1023
1104
|
})
|
|
1024
|
-
}),
|
|
1025
|
-
let a =
|
|
1105
|
+
}), $e = ({ children: e, loadMoreData: t, isDropdown: n = !1, hasSearch: r = !1, responsive: i }) => {
|
|
1106
|
+
let a = Qe({
|
|
1026
1107
|
responsive: i,
|
|
1027
1108
|
isDropdown: n
|
|
1028
1109
|
});
|
|
1029
|
-
return /* @__PURE__ */ (0,
|
|
1110
|
+
return /* @__PURE__ */ (0, W.jsx)("div", {
|
|
1030
1111
|
className: a.container,
|
|
1031
1112
|
"data-testid": "list-container",
|
|
1032
1113
|
style: {
|
|
1033
1114
|
paddingTop: n && !r ? 8 : void 0,
|
|
1034
1115
|
paddingBottom: n ? 8 : void 0
|
|
1035
1116
|
},
|
|
1036
|
-
children: /* @__PURE__ */ (0,
|
|
1117
|
+
children: /* @__PURE__ */ (0, W.jsx)("div", {
|
|
1037
1118
|
className: a.scrollContainer,
|
|
1038
1119
|
style: {
|
|
1039
1120
|
height: n ? void 0 : "100%",
|
|
@@ -1041,12 +1122,12 @@ var _e = (e, t) => typeof e == "number" && typeof t == "number" ? e / t : 0, ve
|
|
|
1041
1122
|
},
|
|
1042
1123
|
onScroll: (e) => {
|
|
1043
1124
|
let { scrollHeight: n, clientHeight: r, scrollTop: i } = e.currentTarget;
|
|
1044
|
-
|
|
1125
|
+
V(n, r, i) && t();
|
|
1045
1126
|
},
|
|
1046
1127
|
children: e
|
|
1047
1128
|
})
|
|
1048
1129
|
});
|
|
1049
|
-
},
|
|
1130
|
+
}, et = E({
|
|
1050
1131
|
mainFilterContainer: {
|
|
1051
1132
|
width: "100%",
|
|
1052
1133
|
height: "100%",
|
|
@@ -1054,10 +1135,10 @@ var _e = (e, t) => typeof e == "number" && typeof t == "number" ? e / t : 0, ve
|
|
|
1054
1135
|
},
|
|
1055
1136
|
blurBackground: { backdropFilter: "blur(1.25px)" },
|
|
1056
1137
|
noBorder: { border: "none !important" }
|
|
1057
|
-
}),
|
|
1058
|
-
let a =
|
|
1059
|
-
return /* @__PURE__ */ (0,
|
|
1060
|
-
className:
|
|
1138
|
+
}), tt = ({ children: e, noBorder: t, blurBackground: n, filterStyle: r, fontSize: i }) => {
|
|
1139
|
+
let a = et(), o = X(r);
|
|
1140
|
+
return /* @__PURE__ */ (0, W.jsx)("div", {
|
|
1141
|
+
className: b({
|
|
1061
1142
|
[a.mainFilterContainer]: !0,
|
|
1062
1143
|
[a.noBorder]: t,
|
|
1063
1144
|
[a.blurBackground]: n
|
|
@@ -1069,4 +1150,4 @@ var _e = (e, t) => typeof e == "number" && typeof t == "number" ? e / t : 0, ve
|
|
|
1069
1150
|
children: e
|
|
1070
1151
|
});
|
|
1071
1152
|
};
|
|
1072
|
-
export {
|
|
1153
|
+
export { oe as _, qe as a, $ as c, Z as d, Oe as f, be as g, Se as h, Ye as i, Ve as l, Te as m, $e as n, Ge as o, De as p, Ze as r, Ue as s, tt as t, Q as u, V as v };
|