@astrato-io/visualizations 0.10.1 → 0.12.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/CHANGELOG.md +30 -1
- package/README.md +148 -5
- package/THIRD_PARTY_NOTICES.md +494 -0
- package/VISUALIZATION_DEFINITIONS.md +9 -146
- package/chunks/{Button-Dn3rJrYf.js → Button-CQdoKSXX.js} +3 -3
- package/chunks/{CircularProgress-BFeu06Yb.js → CircularProgress-DpT1lwWw.js} +20 -20
- package/chunks/FieldTypeIcon-Cg4F9Q5D.js +22 -0
- package/chunks/{LinearProgress-ClO6GUjN.js → LinearProgress-B7S0Q26A.js} +14 -14
- package/chunks/{MenuOption-Czc34u4q.js → MenuOption-DpKFJxmo.js} +167 -167
- package/chunks/{Title-BgYnaVTR.js → Title-m5damhc0.js} +37 -37
- package/chunks/{_createAggregator-BMu9uRax.js → _createAggregator-BA8_iU9q.js} +17 -17
- package/chunks/{app-filter-bar.compiler-CVir0wkl.js → app-filter-bar.compiler--T4Qz3Wu.js} +8 -8
- package/chunks/{bar-layout-C_UgRlVl.js → bar-layout-OFhxn2Go.js} +2 -2
- package/chunks/{bar.compiler-DYuFdi9J.js → bar.compiler-hWZBYYvV.js} +71 -69
- package/chunks/{builder-C-TKA-My.js → builder-7w_bgV_h.js} +106 -55
- package/chunks/{coloring-BtnPiQ_o.js → coloring-Cd6p0GQJ.js} +93 -88
- package/chunks/{createSimplePaletteValueFilter--zrZxRV9.js → createSimplePaletteValueFilter-CiJT8s1s.js} +169 -169
- package/chunks/defaults-CMFqXvaJ.js +3 -0
- package/chunks/{definitions-CT304NDn.js → definitions-DTauTjIX.js} +399 -398
- package/chunks/{escobar-CvEV2ES1.js → escobar-CMvphKSK.js} +4949 -4879
- package/chunks/{extend-preset-D9-JP92b.js → extend-preset-BpXttHFk.js} +449 -450
- package/chunks/{filter.compiler-CXeZznks.js → filter.compiler-DOGFweJz.js} +10 -10
- package/chunks/{filtering-8_bFv-jb.js → filtering-NOnDcGbo.js} +241 -241
- package/chunks/handlers-CyYFSfhM.js +15393 -0
- package/chunks/{icon-picker-styles-BXiJ1SZS.js → icon-picker-styles-DuSERhBU.js} +8 -8
- package/chunks/{isEqual-D8Ay63xR.js → isEqual-4f8yUUtC.js} +1 -1
- package/chunks/{isFocusVisible-Bu8gGZu5.js → isFocusVisible-Czm70MGc.js} +9 -9
- package/chunks/line.compiler-B-4H55_T.js +203 -0
- package/chunks/linear-Bq_r9l5S.js +264 -0
- package/chunks/{logger-DdZpR7xZ.js → logger-Cioob-QV.js} +74 -73
- package/chunks/{lookup-BWllin0q.js → lookup-B3tWH2hX.js} +1 -0
- package/chunks/{map.compiler-Q_Y1Pvat.js → map.compiler-Cv5V6EhF.js} +40 -40
- package/chunks/measure-axis-label-format-COy8U_dd.js +27 -0
- package/chunks/measure-format-default-B_kuGSzi.js +26 -0
- package/chunks/{metadata-BQm_TXI1.js → metadata-dGSe5UWy.js} +5 -5
- package/chunks/number.compiler-D7nMcEMv.js +57 -0
- package/chunks/{operations-DKQWuLL7.js → operations-CgfehCad.js} +11397 -11114
- package/chunks/{range-BdhzvYQ_.js → range-Dmwp9kVB.js} +2 -2
- package/chunks/{react-dom-BGP4tbXV.js → react-dom-CfuL-m78.js} +82 -82
- package/chunks/{render-wrappers-BZpyDnJy.js → render-wrappers--g-zPFBW.js} +1 -1
- package/chunks/{requirements-e8Fe96ag.js → requirements-DHayNJ2C.js} +245 -221
- package/chunks/{shared-C_2F90xq.js → shared-DoEN9nNM.js} +505 -494
- package/chunks/standalone-B3hRGgYi.js +773 -0
- package/chunks/{standalone-BkbiH-o8.js → standalone-BPNXgFft.js} +498 -759
- package/chunks/standalone-BPTT8XEu.js +424 -0
- package/chunks/standalone-BgAeHROc.js +2 -0
- package/chunks/{standalone-BE_ONgiG.js → standalone-BkQxag7M.js} +102 -102
- package/chunks/{standalone-Cc98Pdr6.js → standalone-Bxa3x6dg.js} +872 -872
- package/chunks/standalone-C0If-V6O.js +773 -0
- package/chunks/standalone-C1TOyflX.js +287 -0
- package/chunks/{standalone-CY_kjarf.js → standalone-CE5PwJN0.js} +18 -18
- package/chunks/{standalone-B8ZSqauS.js → standalone-CG7IFN6n.js} +120 -120
- package/chunks/{standalone-wOWRCpdn.js → standalone-CKlgGu80.js} +49 -49
- package/chunks/standalone-CNf-oA2U.js +355 -0
- package/chunks/{standalone-BDrXVxlP.js → standalone-CXPdWFlw.js} +14 -14
- package/chunks/{standalone-z0o52o5t.js → standalone-Cf0_5tbu.js} +5567 -5568
- package/chunks/{standalone-Cl0TSfqC.js → standalone-DMi4-Vp3.js} +122 -122
- package/chunks/{standalone-DNh9NcMa.js → standalone-DTEX67C8.js} +154 -154
- package/chunks/{standalone-DHRalbVO.js → standalone-DU46-kYv.js} +279 -279
- package/chunks/standalone-Dbn3jSH6.js +690 -0
- package/chunks/{standalone-CsoMmE9T.js → standalone-DdcAL_k_.js} +839 -843
- package/chunks/standalone-DwCIA0UG.js +1057 -0
- package/chunks/standalone-Dz13tl3P.js +357 -0
- package/chunks/standalone-H9GFzFk_.js +8377 -0
- package/chunks/{standalone-CaTxAydz.js → standalone-MduR0qre.js} +2227 -1000
- package/chunks/standalone-ejTz66P3.js +2 -0
- package/chunks/{standalone-DflyWtuR.js → standalone-keB-0wK3.js} +216 -216
- package/chunks/{standalone-BTY3w_JA.js → standalone-nnkuQd0K.js} +28 -28
- package/chunks/standalone-vGGR6Vcn.js +6 -0
- package/chunks/{table.compiler-COaHE9VD.js → table.compiler-mS4UvhLT.js} +31 -31
- package/chunks/theme-MYp6Rj1J.js +232 -0
- package/chunks/{useFieldName-CdnCWzhd.js → useFieldName-AdSak4Ch.js} +1 -1
- package/chunks/{utils-DganVptf.js → utils-CUKgR7it.js} +4216 -4070
- package/chunks/{view-Bzlros43.js → view-BeYwpcVD.js} +1561 -1561
- package/chunks/{visualization-filters-D7i6oh1Z.js → visualization-filters-B9qik5_K.js} +2683 -2342
- package/chunks/{with-html-element-CiIhFEa5.js → with-html-element-1GSeLT59.js} +3712 -3682
- package/definitions.js +2 -2
- package/docs/operations/astrato-app-filter-bar.md +1 -1
- package/docs/operations/bar.md +144 -32
- package/docs/operations/combo.md +79 -17
- package/docs/operations/date-picker.md +4 -4
- package/docs/operations/distribution-gauge.md +18 -16
- package/docs/operations/dot.md +107 -24
- package/docs/operations/filter.md +10 -8
- package/docs/operations/gauge.md +20 -18
- package/docs/operations/heatMap.md +73 -21
- package/docs/operations/histogram.md +45 -12
- package/docs/operations/iframe.md +1 -1
- package/docs/operations/image.md +1 -1
- package/docs/operations/index.md +12 -11
- package/docs/operations/line.md +86 -24
- package/docs/operations/map.md +5274 -0
- package/docs/operations/number.md +10 -9
- package/docs/operations/pie.md +23 -21
- package/docs/operations/radar.md +13 -11
- package/docs/operations/sankey.md +19 -17
- package/docs/operations/scatter.md +111 -28
- package/docs/operations/shape.md +5 -5
- package/docs/operations/simpleTextObject.md +4 -4
- package/docs/operations/slider.md +1 -1
- package/docs/operations/table.md +27 -25
- package/docs/operations/tree.md +5 -3
- package/docs/operations/treemap.md +70 -18
- package/docs/operations/waterfall.md +40 -7
- package/docs/operations/word-cloud.md +69 -17
- package/getters.js +3 -3
- package/index.js +585 -612
- package/metadata.js +2 -2
- package/operations.js +25 -18
- package/package.json +74 -70
- package/src/definitions/index.d.ts +1 -7
- package/src/definitions/model/definitions/descriptors/descriptor-metadata.d.ts +3 -48
- package/src/definitions/model/definitions/schema-registry.d.ts +15 -14
- package/src/definitions/model/definitions/schemas/bar.schema.d.ts +3 -3
- package/src/definitions/model/definitions/schemas/broad-chart.schema.d.ts +2 -2
- package/src/definitions/model/definitions/schemas/common.schema.d.ts +19 -6
- package/src/definitions/model/definitions/schemas/index.d.ts +1 -1
- package/src/definitions/model/definitions/schemas/line.schema.d.ts +4 -3
- package/src/definitions/model/definitions/schemas/number.schema.d.ts +1 -1
- package/src/definitions/model/definitions/schemas/table.schema.d.ts +14 -14
- package/src/index.d.ts +1 -1
- package/src/operations/index.d.ts +11 -1
- package/src/types.d.ts +166 -1
- package/src/visualization-catalog.d.ts +3 -0
- package/styles.css +1 -1
- package/chunks/FieldTypeIcon-DrMoGpHJ.js +0 -22
- package/chunks/color-rules-DYJL4fIW.js +0 -15
- package/chunks/color-settings-DJFoFTip.js +0 -5
- package/chunks/defaults-Dtk7fg3C.js +0 -3
- package/chunks/handlers-C6CZ0XJA.js +0 -15399
- package/chunks/line.compiler-DmHpmQCC.js +0 -198
- package/chunks/number.compiler-DQdg6zTy.js +0 -53
- package/chunks/standalone-4MsKiqs0.js +0 -355
- package/chunks/standalone-B794g9pE.js +0 -1012
- package/chunks/standalone-BA2YXyJS.js +0 -422
- package/chunks/standalone-BgumbdaJ2.js +0 -357
- package/chunks/standalone-Blh4qejk.js +0 -689
- package/chunks/standalone-CXY4FpF7.js +0 -773
- package/chunks/standalone-DH0xTEes.js +0 -2
- package/chunks/standalone-DcnHjNnC.js +0 -2
- package/chunks/standalone-DrHdGkY7.js +0 -762
- package/chunks/standalone-c_rROMtx.js +0 -287
- package/chunks/standalone-drcFLeN6.js +0 -6
|
@@ -1,52 +1,52 @@
|
|
|
1
1
|
import { o as e } from "./rolldown-runtime-DleVn1XH.js";
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import { n as re } from "./isEqual-
|
|
6
|
-
import { s as ie } from "./logger-
|
|
7
|
-
import { $ as ae,
|
|
8
|
-
import { S as
|
|
9
|
-
import { _ as
|
|
10
|
-
import { d as
|
|
11
|
-
import { d as
|
|
12
|
-
import "./coloring-
|
|
13
|
-
import { s as
|
|
14
|
-
import { f as
|
|
15
|
-
import {
|
|
16
|
-
import { a as
|
|
17
|
-
import { a as
|
|
18
|
-
import { r as
|
|
19
|
-
var
|
|
2
|
+
import { Si as t, Ua as n, bi as r, di as i, gc as a, hl as o, ho as s, io as c, mn as l, qc as u, ro as d, xc as f, yi as p } from "./visualization-filters-B9qik5_K.js";
|
|
3
|
+
import { B as m, M as h, Mt as g, N as _, Ur as v, Yt as y, at as b, c as x, d as S, fi as C, it as w, o as T, rt as E, sr as ee, tn as te, wn as D } from "./utils-CUKgR7it.js";
|
|
4
|
+
import { Li as ne } from "./handlers-CyYFSfhM.js";
|
|
5
|
+
import { n as re } from "./isEqual-4f8yUUtC.js";
|
|
6
|
+
import { s as ie } from "./logger-Cioob-QV.js";
|
|
7
|
+
import { $ as ae, Q as oe, V as se, a as ce, at as le, cn as ue, ct as de, dn as fe, ft as O, h as pe, ht as me, mn as k, ot as he, pt as A, rt as ge, tt as _e, ut as ve } from "./escobar-CMvphKSK.js";
|
|
8
|
+
import { S as ye, T as be, _ as xe, z as Se } from "./MenuOption-DpKFJxmo.js";
|
|
9
|
+
import { _ as Ce, m as we, v as Te } from "./react-dom-CfuL-m78.js";
|
|
10
|
+
import { d as Ee, t as De, u as Oe } from "./isFocusVisible-Czm70MGc.js";
|
|
11
|
+
import { d as ke, m as Ae, u as je } from "./Title-m5damhc0.js";
|
|
12
|
+
import "./coloring-Cd6p0GQJ.js";
|
|
13
|
+
import { s as Me, t as Ne } from "./src-77e3mC7i.js";
|
|
14
|
+
import { f as Pe, r as Fe, t as Ie, u as Le, y as Re } from "./src-D9XogOrc.js";
|
|
15
|
+
import { r as ze } from "./builder-7w_bgV_h.js";
|
|
16
|
+
import { a as Be, c as Ve, d as He, i as Ue, l as We, n as Ge, o as Ke, r as qe, s as Je, t as Ye, u as Xe } from "./createSimplePaletteValueFilter-CiJT8s1s.js";
|
|
17
|
+
import { a as Ze, i as Qe, r as $e, t as et } from "./accessors-DemrDevR.js";
|
|
18
|
+
import { r as tt, t as nt } from "./src-BOS6SqkZ.js";
|
|
19
|
+
var j = v(), rt = ({ fillColor: e = n.grey2 }) => /* @__PURE__ */ (0, j.jsx)("svg", {
|
|
20
20
|
width: "16",
|
|
21
21
|
height: "16",
|
|
22
22
|
viewBox: "0 0 24 24",
|
|
23
23
|
fill: "none",
|
|
24
24
|
xmlns: "http://www.w3.org/2000/svg",
|
|
25
|
-
children: /* @__PURE__ */ (0,
|
|
25
|
+
children: /* @__PURE__ */ (0, j.jsx)("path", {
|
|
26
26
|
d: "M3 17.46V20.5C3 20.78 3.22 21 3.5 21H6.54C6.67 21 6.8 20.95 6.89 20.85L17.81 9.94L14.06 6.19L3.15 17.1C3.05 17.2 3 17.32 3 17.46ZM20.71 7.04C21.1 6.65 21.1 6.02 20.71 5.63L18.37 3.29C17.98 2.9 17.35 2.9 16.96 3.29L15.13 5.12L18.88 8.87L20.71 7.04Z",
|
|
27
27
|
fill: e
|
|
28
28
|
})
|
|
29
|
-
}),
|
|
30
|
-
function
|
|
29
|
+
}), M = /* @__PURE__ */ e(C(), 1);
|
|
30
|
+
function it(e) {
|
|
31
31
|
return Object.keys(e).length === 0;
|
|
32
32
|
}
|
|
33
|
-
function
|
|
34
|
-
let t =
|
|
35
|
-
return !t ||
|
|
33
|
+
function at(e = null) {
|
|
34
|
+
let t = M.useContext(He);
|
|
35
|
+
return !t || it(t) ? e : t;
|
|
36
36
|
}
|
|
37
|
-
var
|
|
38
|
-
function
|
|
39
|
-
return
|
|
37
|
+
var ot = Ve();
|
|
38
|
+
function st(e = ot) {
|
|
39
|
+
return at(e);
|
|
40
40
|
}
|
|
41
|
-
function
|
|
42
|
-
let e =
|
|
41
|
+
function ct() {
|
|
42
|
+
let e = st(Ke);
|
|
43
43
|
return e.$$material || e;
|
|
44
44
|
}
|
|
45
|
-
var
|
|
46
|
-
function
|
|
47
|
-
return
|
|
45
|
+
var lt = Ee;
|
|
46
|
+
function ut(e) {
|
|
47
|
+
return Te("MuiToggleButton", e);
|
|
48
48
|
}
|
|
49
|
-
var
|
|
49
|
+
var dt = Ce("MuiToggleButton", [
|
|
50
50
|
"root",
|
|
51
51
|
"disabled",
|
|
52
52
|
"selected",
|
|
@@ -57,13 +57,13 @@ var ut = Se("MuiToggleButton", [
|
|
|
57
57
|
"sizeMedium",
|
|
58
58
|
"sizeLarge",
|
|
59
59
|
"fullWidth"
|
|
60
|
-
]),
|
|
61
|
-
function
|
|
62
|
-
let [t, n] =
|
|
60
|
+
]), N = Oe, ft = "(prefers-reduced-motion: reduce)", pt = 0, mt = "0ms", ht = () => {}, gt = () => !1, _t = () => !0, vt = () => ht;
|
|
61
|
+
function yt(e) {
|
|
62
|
+
let [t, n] = M.useState(() => ({
|
|
63
63
|
enabled: e,
|
|
64
64
|
matches: e ? null : !1
|
|
65
65
|
})), r = t.matches;
|
|
66
|
-
return t.enabled !== e && (r = null, e || (r = !1)),
|
|
66
|
+
return t.enabled !== e && (r = null, e || (r = !1)), E(() => {
|
|
67
67
|
let r = (t) => {
|
|
68
68
|
n((n) => n.enabled === e && n.matches === t ? n : {
|
|
69
69
|
enabled: e,
|
|
@@ -78,7 +78,7 @@ function vt(e) {
|
|
|
78
78
|
r(!1);
|
|
79
79
|
return;
|
|
80
80
|
}
|
|
81
|
-
let i = window.matchMedia(
|
|
81
|
+
let i = window.matchMedia(ft), a = () => {
|
|
82
82
|
r(i.matches);
|
|
83
83
|
};
|
|
84
84
|
return a(), i.addEventListener("change", a), () => {
|
|
@@ -86,33 +86,33 @@ function vt(e) {
|
|
|
86
86
|
};
|
|
87
87
|
}, [e, t.enabled]), r;
|
|
88
88
|
}
|
|
89
|
-
var
|
|
90
|
-
function
|
|
91
|
-
let t = e ?
|
|
92
|
-
if (!e || typeof window > "u" || typeof window.matchMedia != "function") return [
|
|
93
|
-
let t = window.matchMedia(
|
|
89
|
+
var bt = { ...M }.useSyncExternalStore;
|
|
90
|
+
function xt(e) {
|
|
91
|
+
let t = e ? _t : gt, [n, r] = M.useMemo(() => {
|
|
92
|
+
if (!e || typeof window > "u" || typeof window.matchMedia != "function") return [gt, vt];
|
|
93
|
+
let t = window.matchMedia(ft);
|
|
94
94
|
return [() => t.matches, (e) => (t.addEventListener("change", e), () => {
|
|
95
95
|
t.removeEventListener("change", e);
|
|
96
96
|
})];
|
|
97
97
|
}, [e]);
|
|
98
|
-
return
|
|
98
|
+
return bt(r, n, t);
|
|
99
99
|
}
|
|
100
|
-
var
|
|
101
|
-
function
|
|
102
|
-
let n =
|
|
103
|
-
return
|
|
100
|
+
var St = bt === void 0 ? yt : xt;
|
|
101
|
+
function Ct(e, t) {
|
|
102
|
+
let n = St(!t && e === "system"), r = !t && (e === "always" || e === "system" && n !== !1);
|
|
103
|
+
return M.useMemo(() => ({
|
|
104
104
|
shouldReduceMotion: r,
|
|
105
105
|
getTransitionTiming(e) {
|
|
106
106
|
return r ? {
|
|
107
|
-
duration:
|
|
108
|
-
delay:
|
|
107
|
+
duration: pt,
|
|
108
|
+
delay: mt
|
|
109
109
|
} : e;
|
|
110
110
|
}
|
|
111
111
|
}), [r]);
|
|
112
112
|
}
|
|
113
|
-
function
|
|
113
|
+
function wt(e) {
|
|
114
114
|
let { focusableWhenDisabled: t, disabled: n, composite: r = !1, tabIndex: i = 0, isNativeButton: a } = e, o = r && t !== !1, s = r && t === !1;
|
|
115
|
-
return
|
|
115
|
+
return M.useMemo(() => {
|
|
116
116
|
let e = { onKeyDown(e) {
|
|
117
117
|
n && t && e.key !== "Tab" && e.preventDefault();
|
|
118
118
|
} };
|
|
@@ -127,17 +127,17 @@ function Ct(e) {
|
|
|
127
127
|
i
|
|
128
128
|
]);
|
|
129
129
|
}
|
|
130
|
-
var
|
|
131
|
-
function
|
|
132
|
-
let { nativeButton: t, nativeButtonProp: n, internalNativeButton: r = t, allowInferredHostMismatch: i = !1, disabled: a, type: o, hasFormAction: s = !1, tabIndex: c = 0, focusableWhenDisabled: l, stopEventPropagation: u = !1, onBeforeKeyDown: d, onBeforeKeyUp: f } = e, p =
|
|
130
|
+
var Tt = {};
|
|
131
|
+
function Et(e) {
|
|
132
|
+
let { nativeButton: t, nativeButtonProp: n, internalNativeButton: r = t, allowInferredHostMismatch: i = !1, disabled: a, type: o, hasFormAction: s = !1, tabIndex: c = 0, focusableWhenDisabled: l, stopEventPropagation: u = !1, onBeforeKeyDown: d, onBeforeKeyUp: f } = e, p = M.useRef(null), m = l === !0, h = wt({
|
|
133
133
|
focusableWhenDisabled: m,
|
|
134
134
|
disabled: a,
|
|
135
135
|
isNativeButton: t,
|
|
136
136
|
tabIndex: c
|
|
137
|
-
}), g =
|
|
137
|
+
}), g = M.useCallback(() => {
|
|
138
138
|
let e = p.current;
|
|
139
139
|
return e == null ? t : e.tagName === "BUTTON" || !!(e.tagName === "A" && e.href);
|
|
140
|
-
}, [t]), _ =
|
|
140
|
+
}, [t]), _ = M.useMemo(() => {
|
|
141
141
|
let e = m ? {} : { tabIndex: a ? -1 : c };
|
|
142
142
|
return t ? (e.type = o === void 0 && !s ? "button" : o, m || (e.disabled = a)) : (e.role = "button", !m && a && (e["aria-disabled"] = a)), m ? {
|
|
143
143
|
...e,
|
|
@@ -153,7 +153,7 @@ function Tt(e) {
|
|
|
153
153
|
o
|
|
154
154
|
]);
|
|
155
155
|
return {
|
|
156
|
-
getButtonProps:
|
|
156
|
+
getButtonProps: M.useCallback((e = Tt) => {
|
|
157
157
|
let { onClick: t, onKeyDown: n, onKeyUp: r, ...i } = e, o = (e) => {
|
|
158
158
|
if (u && e.stopPropagation(), a) {
|
|
159
159
|
e.preventDefault();
|
|
@@ -191,7 +191,7 @@ function Tt(e) {
|
|
|
191
191
|
rootRef: p
|
|
192
192
|
};
|
|
193
193
|
}
|
|
194
|
-
var
|
|
194
|
+
var Dt = class e {
|
|
195
195
|
ref = { current: null };
|
|
196
196
|
shouldMount = !1;
|
|
197
197
|
mounted = null;
|
|
@@ -201,11 +201,11 @@ var Et = class e {
|
|
|
201
201
|
return new e();
|
|
202
202
|
}
|
|
203
203
|
static use() {
|
|
204
|
-
let t =
|
|
205
|
-
return t.shouldMount = n, t.setShouldMount = r,
|
|
204
|
+
let t = Ae(e.create).current, [n, r] = M.useState(!1);
|
|
205
|
+
return t.shouldMount = n, t.setShouldMount = r, M.useEffect(t.mountEffect, [n]), t;
|
|
206
206
|
}
|
|
207
207
|
mount() {
|
|
208
|
-
return this.mounted || (this.mounted =
|
|
208
|
+
return this.mounted || (this.mounted = kt(), this.shouldMount = !0, this.setShouldMount(this.shouldMount)), this.mounted;
|
|
209
209
|
}
|
|
210
210
|
mountEffect = () => {
|
|
211
211
|
this.shouldMount && !this.didMount && (this.ref.current !== null && (this.didMount = !0), this.mounted.resolve());
|
|
@@ -220,25 +220,25 @@ var Et = class e {
|
|
|
220
220
|
this.mount().then(() => this.ref.current?.pulsate(...e));
|
|
221
221
|
}
|
|
222
222
|
};
|
|
223
|
-
function Dt() {
|
|
224
|
-
return Et.use();
|
|
225
|
-
}
|
|
226
223
|
function Ot() {
|
|
224
|
+
return Dt.use();
|
|
225
|
+
}
|
|
226
|
+
function kt() {
|
|
227
227
|
let e, t, n = new Promise((n, r) => {
|
|
228
228
|
e = n, t = r;
|
|
229
229
|
});
|
|
230
230
|
return n.resolve = e, n.reject = t, n;
|
|
231
231
|
}
|
|
232
|
-
function
|
|
233
|
-
let { className: t, classes: n, pulsate: r = !1, rippleX: i, rippleY: a, rippleSize: o, in: s, onExited: c, timeout: l } = e, [u, d] =
|
|
232
|
+
function At(e) {
|
|
233
|
+
let { className: t, classes: n, pulsate: r = !1, rippleX: i, rippleY: a, rippleSize: o, in: s, onExited: c, timeout: l } = e, [u, d] = M.useState(!1), f = je(), p = M.useRef(!1), m = M.useRef(c);
|
|
234
234
|
m.current = c;
|
|
235
|
-
let h = c != null, g =
|
|
235
|
+
let h = c != null, g = b(t, n.ripple, n.rippleVisible, r && n.ripplePulsate), _ = {
|
|
236
236
|
width: o,
|
|
237
237
|
height: o,
|
|
238
238
|
top: -(o / 2) + a,
|
|
239
239
|
left: -(o / 2) + i
|
|
240
|
-
}, v =
|
|
241
|
-
return !s && !u && d(!0),
|
|
240
|
+
}, v = b(n.child, u && n.childLeaving, r && n.childPulsate);
|
|
241
|
+
return !s && !u && d(!0), M.useEffect(() => {
|
|
242
242
|
!s && h ? p.current || (p.current = !0, f.start(l, () => {
|
|
243
243
|
p.current = !1, m.current?.();
|
|
244
244
|
})) : (p.current = !1, f.clear());
|
|
@@ -247,13 +247,13 @@ function kt(e) {
|
|
|
247
247
|
h,
|
|
248
248
|
s,
|
|
249
249
|
l
|
|
250
|
-
]), /*#__PURE__*/ (0,
|
|
250
|
+
]), /*#__PURE__*/ (0, j.jsx)("span", {
|
|
251
251
|
className: g,
|
|
252
252
|
style: _,
|
|
253
|
-
children: /*#__PURE__*/ (0,
|
|
253
|
+
children: /*#__PURE__*/ (0, j.jsx)("span", { className: v })
|
|
254
254
|
});
|
|
255
255
|
}
|
|
256
|
-
var
|
|
256
|
+
var P = Ce("MuiTouchRipple", [
|
|
257
257
|
"root",
|
|
258
258
|
"ripple",
|
|
259
259
|
"rippleVisible",
|
|
@@ -261,8 +261,8 @@ var F = Se("MuiTouchRipple", [
|
|
|
261
261
|
"child",
|
|
262
262
|
"childLeaving",
|
|
263
263
|
"childPulsate"
|
|
264
|
-
]),
|
|
265
|
-
function
|
|
264
|
+
]), jt = 550, Mt = {}, Nt = [], Pt = () => {};
|
|
265
|
+
function Ft(e, t) {
|
|
266
266
|
let n = new Set(t), r = /* @__PURE__ */ new Map(), i = [];
|
|
267
267
|
for (let t of e) n.has(t) ? i.length > 0 && (r.set(t, i), i = []) : i.push(t);
|
|
268
268
|
let a = [];
|
|
@@ -272,7 +272,7 @@ function Pt(e, t) {
|
|
|
272
272
|
}
|
|
273
273
|
return a.push(...i), a;
|
|
274
274
|
}
|
|
275
|
-
function
|
|
275
|
+
function It({ event: e, element: t, center: n }) {
|
|
276
276
|
let r = t ? t.getBoundingClientRect() : {
|
|
277
277
|
width: 0,
|
|
278
278
|
height: 0,
|
|
@@ -296,7 +296,7 @@ function Ft({ event: e, element: t, center: n }) {
|
|
|
296
296
|
rippleSize: o
|
|
297
297
|
};
|
|
298
298
|
}
|
|
299
|
-
var
|
|
299
|
+
var Lt = Xe`
|
|
300
300
|
0% {
|
|
301
301
|
transform: scale(0);
|
|
302
302
|
opacity: 0.1;
|
|
@@ -306,7 +306,7 @@ var It = Ye`
|
|
|
306
306
|
transform: scale(1);
|
|
307
307
|
opacity: 0.3;
|
|
308
308
|
}
|
|
309
|
-
`,
|
|
309
|
+
`, Rt = Xe`
|
|
310
310
|
0% {
|
|
311
311
|
opacity: 1;
|
|
312
312
|
}
|
|
@@ -314,7 +314,7 @@ var It = Ye`
|
|
|
314
314
|
100% {
|
|
315
315
|
opacity: 0;
|
|
316
316
|
}
|
|
317
|
-
`,
|
|
317
|
+
`, zt = Xe`
|
|
318
318
|
0% {
|
|
319
319
|
transform: scale(1);
|
|
320
320
|
}
|
|
@@ -327,40 +327,40 @@ var It = Ye`
|
|
|
327
327
|
transform: scale(1);
|
|
328
328
|
}
|
|
329
329
|
`;
|
|
330
|
-
function
|
|
330
|
+
function Bt(e) {
|
|
331
331
|
if (e.motion.reducedMotion === "always") return null;
|
|
332
|
-
let t =
|
|
333
|
-
&.${
|
|
334
|
-
animation-name: ${
|
|
335
|
-
animation-duration: ${
|
|
332
|
+
let t = We`
|
|
333
|
+
&.${P.rippleVisible} {
|
|
334
|
+
animation-name: ${Lt};
|
|
335
|
+
animation-duration: ${jt}ms;
|
|
336
336
|
animation-timing-function: ${e.transitions.easing.easeInOut};
|
|
337
337
|
}
|
|
338
338
|
|
|
339
|
-
&.${
|
|
339
|
+
&.${P.ripplePulsate} {
|
|
340
340
|
animation-duration: ${e.transitions.duration.shorter}ms;
|
|
341
341
|
}
|
|
342
342
|
|
|
343
|
-
& .${
|
|
344
|
-
animation-name: ${
|
|
345
|
-
animation-duration: ${
|
|
343
|
+
& .${P.childLeaving} {
|
|
344
|
+
animation-name: ${Rt};
|
|
345
|
+
animation-duration: ${jt}ms;
|
|
346
346
|
animation-timing-function: ${e.transitions.easing.easeInOut};
|
|
347
347
|
}
|
|
348
348
|
|
|
349
|
-
& .${
|
|
350
|
-
animation-name: ${
|
|
349
|
+
& .${P.childPulsate} {
|
|
350
|
+
animation-name: ${zt};
|
|
351
351
|
animation-duration: 2500ms;
|
|
352
352
|
animation-timing-function: ${e.transitions.easing.easeInOut};
|
|
353
353
|
animation-iteration-count: infinite;
|
|
354
354
|
animation-delay: 200ms;
|
|
355
355
|
}
|
|
356
356
|
`;
|
|
357
|
-
return e.motion.reducedMotion === "system" ?
|
|
357
|
+
return e.motion.reducedMotion === "system" ? We`
|
|
358
358
|
@media (prefers-reduced-motion: no-preference) {
|
|
359
359
|
${t}
|
|
360
360
|
}
|
|
361
361
|
` : t;
|
|
362
362
|
}
|
|
363
|
-
var
|
|
363
|
+
var Vt = Be("span", {
|
|
364
364
|
name: "MuiTouchRipple",
|
|
365
365
|
slot: "Root"
|
|
366
366
|
})({
|
|
@@ -373,14 +373,14 @@ var Bt = ze("span", {
|
|
|
373
373
|
bottom: 0,
|
|
374
374
|
left: 0,
|
|
375
375
|
borderRadius: "inherit"
|
|
376
|
-
}),
|
|
376
|
+
}), Ht = Be(At, {
|
|
377
377
|
name: "MuiTouchRipple",
|
|
378
378
|
slot: "Ripple"
|
|
379
379
|
})`
|
|
380
380
|
opacity: 0;
|
|
381
381
|
position: absolute;
|
|
382
382
|
|
|
383
|
-
&.${
|
|
383
|
+
&.${P.rippleVisible} {
|
|
384
384
|
opacity: 0.3;
|
|
385
385
|
transform: scale(1);
|
|
386
386
|
}
|
|
@@ -393,7 +393,7 @@ var Bt = ze("span", {
|
|
|
393
393
|
* it relies on this static 'opacity: 0' to disappear on blur instead of
|
|
394
394
|
* lingering until removal.
|
|
395
395
|
*/
|
|
396
|
-
& .${
|
|
396
|
+
& .${P.child} {
|
|
397
397
|
opacity: 1;
|
|
398
398
|
display: block;
|
|
399
399
|
width: 100%;
|
|
@@ -402,40 +402,40 @@ var Bt = ze("span", {
|
|
|
402
402
|
background-color: currentColor;
|
|
403
403
|
}
|
|
404
404
|
|
|
405
|
-
& .${
|
|
405
|
+
& .${P.childLeaving} {
|
|
406
406
|
opacity: 0;
|
|
407
407
|
}
|
|
408
408
|
|
|
409
|
-
& .${
|
|
409
|
+
& .${P.childPulsate} {
|
|
410
410
|
position: absolute;
|
|
411
411
|
/* @noflip */
|
|
412
412
|
left: 0px;
|
|
413
413
|
top: 0;
|
|
414
414
|
}
|
|
415
415
|
|
|
416
|
-
${({ theme: e }) =>
|
|
417
|
-
`,
|
|
418
|
-
let n =
|
|
416
|
+
${({ theme: e }) => Bt(e)}
|
|
417
|
+
`, Ut = /*#__PURE__*/ M.forwardRef(function(e, t) {
|
|
418
|
+
let n = qe({
|
|
419
419
|
props: e,
|
|
420
420
|
name: "MuiTouchRipple"
|
|
421
|
-
}), r =
|
|
422
|
-
items:
|
|
423
|
-
order:
|
|
424
|
-
}), u = c.items, d =
|
|
425
|
-
|
|
421
|
+
}), r = Ct(ct().motion.reducedMotion, !1), { center: i = !1, classes: a = Mt, className: o, ...s } = n, [c, l] = M.useState({
|
|
422
|
+
items: Nt,
|
|
423
|
+
order: Nt
|
|
424
|
+
}), u = c.items, d = M.useRef(0), f = M.useRef(null), p = M.useRef(!1);
|
|
425
|
+
ke(() => (p.current = !0, () => {
|
|
426
426
|
p.current = !1;
|
|
427
|
-
})),
|
|
427
|
+
})), M.useEffect(() => {
|
|
428
428
|
f.current &&= (f.current(), null);
|
|
429
429
|
}, [u]);
|
|
430
|
-
let m =
|
|
430
|
+
let m = M.useRef(!1), h = je(), g = M.useRef(null), _ = M.useRef(null), v = N((e) => {
|
|
431
431
|
p.current && l((t) => {
|
|
432
432
|
let n = t.items.filter((t) => t.key !== e);
|
|
433
433
|
return {
|
|
434
434
|
items: n,
|
|
435
|
-
order:
|
|
435
|
+
order: Ft(t.order.filter((t) => t !== e), n.filter((e) => !e.exiting).map((e) => e.key))
|
|
436
436
|
};
|
|
437
437
|
});
|
|
438
|
-
}), y =
|
|
438
|
+
}), y = N((e) => {
|
|
439
439
|
let { pulsate: t, rippleX: n, rippleY: r, rippleSize: i, cb: a } = e, o = d.current;
|
|
440
440
|
d.current += 1, l((e) => {
|
|
441
441
|
let a = [...e.items, {
|
|
@@ -448,17 +448,17 @@ var Bt = ze("span", {
|
|
|
448
448
|
}];
|
|
449
449
|
return {
|
|
450
450
|
items: a,
|
|
451
|
-
order:
|
|
451
|
+
order: Ft(e.order, a.filter((e) => !e.exiting).map((e) => e.key))
|
|
452
452
|
};
|
|
453
453
|
}), f.current = a;
|
|
454
|
-
}),
|
|
454
|
+
}), x = N((e = Mt, t = Mt, n = Pt) => {
|
|
455
455
|
let { pulsate: r = !1, center: a = i || t.pulsate, fakeElement: o = !1 } = t;
|
|
456
456
|
if (e?.type === "mousedown" && m.current) {
|
|
457
457
|
m.current = !1;
|
|
458
458
|
return;
|
|
459
459
|
}
|
|
460
460
|
e?.type === "touchstart" && (m.current = !0);
|
|
461
|
-
let { rippleX: s, rippleY: c, rippleSize: l } =
|
|
461
|
+
let { rippleX: s, rippleY: c, rippleSize: l } = It({
|
|
462
462
|
event: e,
|
|
463
463
|
element: o ? null : _.current,
|
|
464
464
|
center: a
|
|
@@ -480,9 +480,9 @@ var Bt = ze("span", {
|
|
|
480
480
|
rippleSize: l,
|
|
481
481
|
cb: n
|
|
482
482
|
});
|
|
483
|
-
}), S =
|
|
484
|
-
|
|
485
|
-
}), C =
|
|
483
|
+
}), S = N(() => {
|
|
484
|
+
x(Mt, { pulsate: !0 });
|
|
485
|
+
}), C = N((e, t) => {
|
|
486
486
|
if (h.clear(), e?.type === "touchend" && g.current) {
|
|
487
487
|
g.current(), g.current = null, h.start(0, () => {
|
|
488
488
|
C(e, t);
|
|
@@ -498,34 +498,34 @@ var Bt = ze("span", {
|
|
|
498
498
|
exiting: !0
|
|
499
499
|
}, {
|
|
500
500
|
items: n,
|
|
501
|
-
order:
|
|
501
|
+
order: Ft(e.order, n.filter((e) => !e.exiting).map((e) => e.key))
|
|
502
502
|
};
|
|
503
503
|
}), f.current = t;
|
|
504
504
|
});
|
|
505
|
-
|
|
505
|
+
M.useImperativeHandle(t, () => ({
|
|
506
506
|
pulsate: S,
|
|
507
|
-
start:
|
|
507
|
+
start: x,
|
|
508
508
|
stop: C
|
|
509
509
|
}), [
|
|
510
510
|
S,
|
|
511
|
-
|
|
511
|
+
x,
|
|
512
512
|
C
|
|
513
513
|
]);
|
|
514
514
|
let w = new Map(u.map((e) => [e.key, e])), T = c.order.map((e) => w.get(e)).filter(Boolean);
|
|
515
|
-
return /*#__PURE__*/ (0,
|
|
516
|
-
className:
|
|
515
|
+
return /*#__PURE__*/ (0, j.jsx)(Vt, {
|
|
516
|
+
className: b(P.root, a.root, o),
|
|
517
517
|
ref: _,
|
|
518
518
|
...s,
|
|
519
|
-
children: T.map((e) => /*#__PURE__*/ (0,
|
|
519
|
+
children: T.map((e) => /*#__PURE__*/ (0, j.jsx)(Ht, {
|
|
520
520
|
classes: {
|
|
521
|
-
ripple:
|
|
522
|
-
rippleVisible:
|
|
523
|
-
ripplePulsate:
|
|
524
|
-
child:
|
|
525
|
-
childLeaving:
|
|
526
|
-
childPulsate:
|
|
521
|
+
ripple: b(a.ripple, P.ripple),
|
|
522
|
+
rippleVisible: b(a.rippleVisible, P.rippleVisible),
|
|
523
|
+
ripplePulsate: b(a.ripplePulsate, P.ripplePulsate),
|
|
524
|
+
child: b(a.child, P.child),
|
|
525
|
+
childLeaving: b(a.childLeaving, P.childLeaving),
|
|
526
|
+
childPulsate: b(a.childPulsate, P.childPulsate)
|
|
527
527
|
},
|
|
528
|
-
timeout: r.shouldReduceMotion ? 0 :
|
|
528
|
+
timeout: r.shouldReduceMotion ? 0 : jt,
|
|
529
529
|
pulsate: e.pulsate,
|
|
530
530
|
rippleX: e.rippleX,
|
|
531
531
|
rippleY: e.rippleY,
|
|
@@ -535,24 +535,24 @@ var Bt = ze("span", {
|
|
|
535
535
|
}, e.key))
|
|
536
536
|
});
|
|
537
537
|
});
|
|
538
|
-
function
|
|
539
|
-
return
|
|
538
|
+
function Wt(e) {
|
|
539
|
+
return Te("MuiButtonBase", e);
|
|
540
540
|
}
|
|
541
|
-
var
|
|
541
|
+
var Gt = Ce("MuiButtonBase", [
|
|
542
542
|
"root",
|
|
543
543
|
"disabled",
|
|
544
544
|
"focusVisible"
|
|
545
|
-
]),
|
|
546
|
-
let { disabled: t, focusVisible: n, focusVisibleClassName: r, suppressFocusVisible: i, classes: a } = e, o =
|
|
545
|
+
]), Kt = (e) => {
|
|
546
|
+
let { disabled: t, focusVisible: n, focusVisibleClassName: r, suppressFocusVisible: i, classes: a } = e, o = we({ root: [
|
|
547
547
|
"root",
|
|
548
548
|
t && "disabled",
|
|
549
549
|
n && !i && "focusVisible"
|
|
550
|
-
] },
|
|
550
|
+
] }, Wt, a);
|
|
551
551
|
return n && !i && r && (o.root += ` ${r}`), o;
|
|
552
|
-
},
|
|
552
|
+
}, qt = Be("button", {
|
|
553
553
|
name: "MuiButtonBase",
|
|
554
554
|
slot: "Root"
|
|
555
|
-
})(
|
|
555
|
+
})(Ue(({ theme: e }) => ({
|
|
556
556
|
display: "inline-flex",
|
|
557
557
|
alignItems: "center",
|
|
558
558
|
justifyContent: "center",
|
|
@@ -573,7 +573,7 @@ var Wt = Se("MuiButtonBase", [
|
|
|
573
573
|
textDecoration: "none",
|
|
574
574
|
color: "inherit",
|
|
575
575
|
"&::-moz-focus-inner": { borderStyle: "none" },
|
|
576
|
-
[`&.${
|
|
576
|
+
[`&.${Gt.disabled}`]: {
|
|
577
577
|
pointerEvents: "none",
|
|
578
578
|
cursor: "default"
|
|
579
579
|
},
|
|
@@ -581,27 +581,27 @@ var Wt = Se("MuiButtonBase", [
|
|
|
581
581
|
variants: [{
|
|
582
582
|
props: { internalDisabledThemeFocusVisible: !1 },
|
|
583
583
|
style: e.focusVisible && {
|
|
584
|
-
...
|
|
585
|
-
[`&.${
|
|
584
|
+
...Je,
|
|
585
|
+
[`&.${Gt.focusVisible}`]: e.focusVisible
|
|
586
586
|
}
|
|
587
587
|
}]
|
|
588
|
-
}))),
|
|
589
|
-
let n =
|
|
588
|
+
}))), Jt = /*#__PURE__*/ M.forwardRef(function(e, t) {
|
|
589
|
+
let n = qe({
|
|
590
590
|
props: e,
|
|
591
591
|
name: "MuiButtonBase"
|
|
592
|
-
}), { action: r, centerRipple: i = !1, children: a, className: o, component: s = "button", disabled: c = !1, disableRipple: l = !1, disableTouchRipple: u = !1, focusRipple: d = !1, focusVisibleClassName: f, focusableWhenDisabled: p, suppressFocusVisible: m = !1, internalNativeButton: h, internalDisabledThemeFocusVisible: g = !1, LinkComponent: _ = "a", nativeButton: v, onBlur: y, onClick:
|
|
592
|
+
}), { action: r, centerRipple: i = !1, children: a, className: o, component: s = "button", disabled: c = !1, disableRipple: l = !1, disableTouchRipple: u = !1, focusRipple: d = !1, focusVisibleClassName: f, focusableWhenDisabled: p, suppressFocusVisible: m = !1, internalNativeButton: h, internalDisabledThemeFocusVisible: g = !1, LinkComponent: _ = "a", nativeButton: v, onBlur: y, onClick: x, onContextMenu: S, onDragLeave: C, onFocus: w, onFocusVisible: T, onKeyDown: E, onKeyUp: ee, onMouseDown: te, onMouseLeave: D, onMouseUp: ne, onTouchEnd: re, onTouchMove: ie, onTouchStart: ae, tabIndex: oe = 0, TouchRippleProps: se, touchRippleRef: ce, type: le, ...ue } = n, de = !!(ue.href || ue.to), fe = !!ue.formAction, O = s;
|
|
593
593
|
O === "button" && de && (O = _);
|
|
594
|
-
let pe = typeof O == "string" ? O === "button" : h ?? !1, me = v ?? pe, k =
|
|
595
|
-
(c || m) && A &&
|
|
596
|
-
let
|
|
594
|
+
let pe = typeof O == "string" ? O === "button" : h ?? !1, me = v ?? pe, k = Ot(), he = lt(k.ref, ce), [A, ge] = M.useState(!1);
|
|
595
|
+
(c || m) && A && ge(!1);
|
|
596
|
+
let _e = N((e) => {
|
|
597
597
|
d && !e.repeat && A && e.key === " " && k.stop(e, () => {
|
|
598
598
|
k.start(e);
|
|
599
599
|
});
|
|
600
|
-
}),
|
|
600
|
+
}), ve = N((e) => {
|
|
601
601
|
d && e.key === " " && A && !e.defaultPrevented && k.stop(e, () => {
|
|
602
602
|
k.pulsate(e);
|
|
603
603
|
});
|
|
604
|
-
}), { getButtonProps:
|
|
604
|
+
}), { getButtonProps: ye, rootRef: be } = Et({
|
|
605
605
|
nativeButton: me,
|
|
606
606
|
nativeButtonProp: v,
|
|
607
607
|
internalNativeButton: pe,
|
|
@@ -610,18 +610,18 @@ var Wt = Se("MuiButtonBase", [
|
|
|
610
610
|
type: le,
|
|
611
611
|
hasFormAction: fe,
|
|
612
612
|
tabIndex: oe,
|
|
613
|
-
onBeforeKeyDown:
|
|
614
|
-
onBeforeKeyUp:
|
|
615
|
-
}), { onClick:
|
|
616
|
-
onClick:
|
|
613
|
+
onBeforeKeyDown: _e,
|
|
614
|
+
onBeforeKeyUp: ve
|
|
615
|
+
}), { onClick: xe, onKeyDown: Se, onKeyUp: Ce, ...we } = ye({
|
|
616
|
+
onClick: x,
|
|
617
617
|
onKeyDown: E,
|
|
618
618
|
onKeyUp: ee
|
|
619
619
|
});
|
|
620
|
-
|
|
621
|
-
|
|
622
|
-
} }), [
|
|
623
|
-
let
|
|
624
|
-
|
|
620
|
+
M.useImperativeHandle(r, () => ({ focusVisible: () => {
|
|
621
|
+
ge(!0), be.current.focus();
|
|
622
|
+
} }), [be]);
|
|
623
|
+
let Te = k.shouldMount && !l && !c;
|
|
624
|
+
M.useEffect(() => {
|
|
625
625
|
A && d && !l && k.pulsate();
|
|
626
626
|
}, [
|
|
627
627
|
l,
|
|
@@ -629,15 +629,15 @@ var Wt = Se("MuiButtonBase", [
|
|
|
629
629
|
A,
|
|
630
630
|
k
|
|
631
631
|
]);
|
|
632
|
-
let
|
|
632
|
+
let Ee = F(k, "start", te, u), Oe = F(k, "stop", S, u), ke = F(k, "stop", C, u), Ae = F(k, "stop", ne, u), je = F(k, "stop", (e) => {
|
|
633
633
|
A && e.preventDefault(), D && D(e);
|
|
634
|
-
}, u),
|
|
635
|
-
|
|
636
|
-
}, !1),
|
|
637
|
-
|
|
638
|
-
}),
|
|
639
|
-
de && (
|
|
640
|
-
let
|
|
634
|
+
}, u), Me = F(k, "start", ae, u), Ne = F(k, "stop", re, u), Pe = F(k, "stop", ie, u), Fe = F(k, "stop", (e) => {
|
|
635
|
+
De(e.target) || ge(!1), y && y(e);
|
|
636
|
+
}, !1), Ie = N((e) => {
|
|
637
|
+
be.current ||= e.currentTarget, !m && De(e.target) && (ge(!0), T && T(e)), w && w(e);
|
|
638
|
+
}), Le = {};
|
|
639
|
+
de && (Le.tabIndex = c ? -1 : oe, c && (Le["aria-disabled"] = c), Le.type = le);
|
|
640
|
+
let Re = lt(t, be), ze = {
|
|
641
641
|
...n,
|
|
642
642
|
centerRipple: i,
|
|
643
643
|
component: s,
|
|
@@ -649,77 +649,77 @@ var Wt = Se("MuiButtonBase", [
|
|
|
649
649
|
tabIndex: oe,
|
|
650
650
|
focusVisible: A,
|
|
651
651
|
internalDisabledThemeFocusVisible: g
|
|
652
|
-
},
|
|
653
|
-
return /*#__PURE__*/ (0,
|
|
652
|
+
}, Be = Kt(ze);
|
|
653
|
+
return /*#__PURE__*/ (0, j.jsxs)(qt, {
|
|
654
654
|
as: O,
|
|
655
|
-
className:
|
|
656
|
-
ownerState:
|
|
657
|
-
onBlur:
|
|
658
|
-
onClick:
|
|
659
|
-
onContextMenu:
|
|
660
|
-
onFocus:
|
|
661
|
-
onKeyDown:
|
|
662
|
-
onKeyUp:
|
|
663
|
-
onMouseDown:
|
|
664
|
-
onMouseLeave:
|
|
665
|
-
onMouseUp:
|
|
666
|
-
onDragLeave:
|
|
667
|
-
onTouchEnd:
|
|
668
|
-
onTouchMove:
|
|
669
|
-
onTouchStart:
|
|
670
|
-
ref:
|
|
671
|
-
...de ?
|
|
655
|
+
className: b(Be.root, o),
|
|
656
|
+
ownerState: ze,
|
|
657
|
+
onBlur: Fe,
|
|
658
|
+
onClick: xe,
|
|
659
|
+
onContextMenu: Oe,
|
|
660
|
+
onFocus: Ie,
|
|
661
|
+
onKeyDown: Se,
|
|
662
|
+
onKeyUp: Ce,
|
|
663
|
+
onMouseDown: Ee,
|
|
664
|
+
onMouseLeave: je,
|
|
665
|
+
onMouseUp: Ae,
|
|
666
|
+
onDragLeave: ke,
|
|
667
|
+
onTouchEnd: Ne,
|
|
668
|
+
onTouchMove: Pe,
|
|
669
|
+
onTouchStart: Me,
|
|
670
|
+
ref: Re,
|
|
671
|
+
...de ? Le : we,
|
|
672
672
|
...ue,
|
|
673
|
-
children: [a,
|
|
673
|
+
children: [a, Te ? /*#__PURE__*/ (0, j.jsx)(Ut, {
|
|
674
674
|
ref: he,
|
|
675
675
|
center: i,
|
|
676
676
|
...se
|
|
677
677
|
}) : null]
|
|
678
678
|
});
|
|
679
679
|
});
|
|
680
|
-
function
|
|
681
|
-
return
|
|
680
|
+
function F(e, t, n, r = !1) {
|
|
681
|
+
return N((i) => (n && n(i), r || e[t](i), !0));
|
|
682
682
|
}
|
|
683
|
-
var
|
|
684
|
-
function
|
|
683
|
+
var Yt = /*#__PURE__*/ M.createContext({}), Xt = /*#__PURE__*/ M.createContext(void 0);
|
|
684
|
+
function Zt(e, t) {
|
|
685
685
|
return t === void 0 || e === void 0 ? !1 : Array.isArray(t) ? t.includes(e) : e === t;
|
|
686
686
|
}
|
|
687
|
-
function
|
|
688
|
-
let { children: n, disabled: r = !1, selected: i = !1, value: a } = e, o =
|
|
687
|
+
function Qt(e, t) {
|
|
688
|
+
let { children: n, disabled: r = !1, selected: i = !1, value: a } = e, o = be(), s = ye({
|
|
689
689
|
id: a,
|
|
690
690
|
ref: t,
|
|
691
691
|
disabled: r,
|
|
692
692
|
selected: i
|
|
693
693
|
}), c = o.getItemMap().size === 0 && i ? 0 : s.tabIndex;
|
|
694
|
-
return /*#__PURE__*/
|
|
694
|
+
return /*#__PURE__*/ M.cloneElement(M.Children.only(n), {
|
|
695
695
|
...s,
|
|
696
696
|
tabIndex: n.props.tabIndex ?? c
|
|
697
697
|
});
|
|
698
698
|
}
|
|
699
|
-
var
|
|
699
|
+
var $t = /*#__PURE__*/ M.forwardRef(Qt), en = (e) => {
|
|
700
700
|
let { classes: t, fullWidth: n, selected: r, disabled: i, size: a, color: o } = e;
|
|
701
|
-
return
|
|
701
|
+
return we({ root: [
|
|
702
702
|
"root",
|
|
703
703
|
r && "selected",
|
|
704
704
|
i && "disabled",
|
|
705
705
|
n && "fullWidth",
|
|
706
|
-
`size${
|
|
706
|
+
`size${Ge(a)}`,
|
|
707
707
|
o
|
|
708
|
-
] },
|
|
709
|
-
},
|
|
708
|
+
] }, ut, t);
|
|
709
|
+
}, tn = Be(Jt, {
|
|
710
710
|
name: "MuiToggleButton",
|
|
711
711
|
slot: "Root",
|
|
712
712
|
overridesResolver: (e, t) => {
|
|
713
713
|
let { ownerState: n } = e;
|
|
714
|
-
return [t.root, t[`size${
|
|
714
|
+
return [t.root, t[`size${Ge(n.size)}`]];
|
|
715
715
|
}
|
|
716
|
-
})(
|
|
716
|
+
})(Ue(({ theme: e }) => ({
|
|
717
717
|
...e.typography.button,
|
|
718
718
|
borderRadius: (e.vars || e).shape.borderRadius,
|
|
719
719
|
padding: 11,
|
|
720
720
|
border: `1px solid ${(e.vars || e).palette.divider}`,
|
|
721
721
|
color: (e.vars || e).palette.action.active,
|
|
722
|
-
[`&.${
|
|
722
|
+
[`&.${dt.disabled}`]: {
|
|
723
723
|
color: (e.vars || e).palette.action.disabled,
|
|
724
724
|
border: `1px solid ${(e.vars || e).palette.action.disabledBackground}`
|
|
725
725
|
},
|
|
@@ -731,7 +731,7 @@ var Qt = /*#__PURE__*/ N.forwardRef(Zt), $t = (e) => {
|
|
|
731
731
|
variants: [
|
|
732
732
|
{
|
|
733
733
|
props: { color: "standard" },
|
|
734
|
-
style: { [`&.${
|
|
734
|
+
style: { [`&.${dt.selected}`]: {
|
|
735
735
|
color: (e.vars || e).palette.text.primary,
|
|
736
736
|
backgroundColor: e.alpha((e.vars || e).palette.text.primary, (e.vars || e).palette.action.selectedOpacity),
|
|
737
737
|
"&:hover": {
|
|
@@ -740,9 +740,9 @@ var Qt = /*#__PURE__*/ N.forwardRef(Zt), $t = (e) => {
|
|
|
740
740
|
}
|
|
741
741
|
} }
|
|
742
742
|
},
|
|
743
|
-
...Object.entries(e.palette).filter(
|
|
743
|
+
...Object.entries(e.palette).filter(Ye()).map(([t]) => ({
|
|
744
744
|
props: { color: t },
|
|
745
|
-
style: { [`&.${
|
|
745
|
+
style: { [`&.${dt.selected}`]: {
|
|
746
746
|
color: (e.vars || e).palette[t].main,
|
|
747
747
|
backgroundColor: e.alpha((e.vars || e).palette[t].main, (e.vars || e).palette.action.selectedOpacity),
|
|
748
748
|
"&:hover": {
|
|
@@ -770,11 +770,11 @@ var Qt = /*#__PURE__*/ N.forwardRef(Zt), $t = (e) => {
|
|
|
770
770
|
}
|
|
771
771
|
}
|
|
772
772
|
]
|
|
773
|
-
}))),
|
|
774
|
-
let { value: n, isRovingTabIndex: r, ...i } =
|
|
775
|
-
props:
|
|
773
|
+
}))), nn = /*#__PURE__*/ M.forwardRef(function(e, t) {
|
|
774
|
+
let { value: n, isRovingTabIndex: r, ...i } = M.useContext(Yt), a = M.useContext(Xt), o = qe({
|
|
775
|
+
props: w({
|
|
776
776
|
...i,
|
|
777
|
-
selected:
|
|
777
|
+
selected: Zt(e.value, n)
|
|
778
778
|
}, e),
|
|
779
779
|
name: "MuiToggleButton"
|
|
780
780
|
}), { children: s, className: c, color: l = "standard", disabled: u = !1, disableFocusRipple: d = !1, fullWidth: f = !1, onChange: p, onClick: m, selected: h, size: g = "medium", value: _, ...v } = o, y = {
|
|
@@ -784,10 +784,10 @@ var Qt = /*#__PURE__*/ N.forwardRef(Zt), $t = (e) => {
|
|
|
784
784
|
disableFocusRipple: d,
|
|
785
785
|
fullWidth: f,
|
|
786
786
|
size: g
|
|
787
|
-
},
|
|
787
|
+
}, x = en(y), S = (e) => {
|
|
788
788
|
m && (m(e, _), e.defaultPrevented) || p && p(e, _);
|
|
789
|
-
}, C = a || "",
|
|
790
|
-
className:
|
|
789
|
+
}, C = a || "", T = /*#__PURE__*/ (0, j.jsx)(tn, {
|
|
790
|
+
className: b(i.className, x.root, c, C),
|
|
791
791
|
internalNativeButton: !0,
|
|
792
792
|
disabled: u,
|
|
793
793
|
focusRipple: !d,
|
|
@@ -800,25 +800,25 @@ var Qt = /*#__PURE__*/ N.forwardRef(Zt), $t = (e) => {
|
|
|
800
800
|
...v,
|
|
801
801
|
children: s
|
|
802
802
|
});
|
|
803
|
-
return r ? /*#__PURE__*/ (0,
|
|
803
|
+
return r ? /*#__PURE__*/ (0, j.jsx)($t, {
|
|
804
804
|
disabled: u,
|
|
805
805
|
selected: h,
|
|
806
806
|
ref: t,
|
|
807
807
|
value: _,
|
|
808
|
-
children:
|
|
809
|
-
}) :
|
|
810
|
-
}),
|
|
811
|
-
let
|
|
812
|
-
...
|
|
813
|
-
...
|
|
808
|
+
children: T
|
|
809
|
+
}) : T;
|
|
810
|
+
}), rn = ({ vTheme: e, vSpec: i, id: a, layout: o }) => {
|
|
811
|
+
let s = e?.fonts?.general.fontFamily ?? "Roboto", c = {
|
|
812
|
+
...p,
|
|
813
|
+
...i.treeChartSettings?.nodeLayout?.border
|
|
814
814
|
};
|
|
815
|
-
|
|
816
|
-
let
|
|
817
|
-
...
|
|
818
|
-
...
|
|
819
|
-
},
|
|
815
|
+
c.enabled === !1 && (c.borderWidth = 0);
|
|
816
|
+
let l = {
|
|
817
|
+
...r,
|
|
818
|
+
...i.treeChartSettings?.nodeLayout.hoverStyle
|
|
819
|
+
}, u = i.treeChartSettings?.nodeLayout?.backgroundColor ?? t.backgroundColor, d = new xe(u).isLight() ? n.grey1 : n.grey5;
|
|
820
820
|
return `
|
|
821
|
-
#${
|
|
821
|
+
#${a} {
|
|
822
822
|
&[data-mode="view"] .tree-toolbar {
|
|
823
823
|
display: none;
|
|
824
824
|
}
|
|
@@ -826,19 +826,19 @@ var Qt = /*#__PURE__*/ N.forwardRef(Zt), $t = (e) => {
|
|
|
826
826
|
display: flex;
|
|
827
827
|
}
|
|
828
828
|
|
|
829
|
-
--link-color: ${
|
|
829
|
+
--link-color: ${n.grey3};
|
|
830
830
|
|
|
831
|
-
--border-color: ${
|
|
832
|
-
--border-width: ${
|
|
833
|
-
--border-color-edit: ${
|
|
834
|
-
--border-radius: ${
|
|
835
|
-
--border-color-selected: ${
|
|
831
|
+
--border-color: ${c.borderColor};
|
|
832
|
+
--border-width: ${c.borderWidth}px;
|
|
833
|
+
--border-color-edit: ${n.secondaryPurple};
|
|
834
|
+
--border-radius: ${c.borderRadius}px;
|
|
835
|
+
--border-color-selected: ${n.grey2};
|
|
836
836
|
|
|
837
|
-
--border-hover-width: ${
|
|
838
|
-
--border-hover-color: ${
|
|
837
|
+
--border-hover-width: ${l.borderWidth}px;
|
|
838
|
+
--border-hover-color: ${l.borderColor || c.borderColor};
|
|
839
839
|
|
|
840
|
-
--node-background: ${
|
|
841
|
-
--node-background-highlight: ${
|
|
840
|
+
--node-background: ${u};
|
|
841
|
+
--node-background-highlight: ${n.grey2};
|
|
842
842
|
--font-color: ${d};
|
|
843
843
|
|
|
844
844
|
.links-wrapper path {
|
|
@@ -865,14 +865,14 @@ var Qt = /*#__PURE__*/ N.forwardRef(Zt), $t = (e) => {
|
|
|
865
865
|
|
|
866
866
|
.button-content {
|
|
867
867
|
border:1px solid var(--border-color);
|
|
868
|
-
border-radius: ${Math.ceil(
|
|
868
|
+
border-radius: ${Math.ceil(c.borderRadius / 2)}px;
|
|
869
869
|
padding:1px 3px;
|
|
870
870
|
font-size:9px;
|
|
871
871
|
margin:auto auto;
|
|
872
872
|
background-color: var(--node-background);
|
|
873
873
|
}
|
|
874
874
|
&:hover .button-content {
|
|
875
|
-
background-color: ${
|
|
875
|
+
background-color: ${n.grey5};
|
|
876
876
|
}
|
|
877
877
|
}
|
|
878
878
|
|
|
@@ -890,7 +890,7 @@ var Qt = /*#__PURE__*/ N.forwardRef(Zt), $t = (e) => {
|
|
|
890
890
|
.node-content {
|
|
891
891
|
color: var(--font-color);
|
|
892
892
|
font-size: 12px;
|
|
893
|
-
font-family: ${
|
|
893
|
+
font-family: ${s}, sans-serif;
|
|
894
894
|
width: 100%;
|
|
895
895
|
height: 100%;
|
|
896
896
|
border: var(--border-width) solid var(--border-color);
|
|
@@ -928,7 +928,7 @@ var Qt = /*#__PURE__*/ N.forwardRef(Zt), $t = (e) => {
|
|
|
928
928
|
}
|
|
929
929
|
|
|
930
930
|
.dragging-active .drop-target .node-content::after {
|
|
931
|
-
background-color: ${
|
|
931
|
+
background-color: ${n.feedbackBlue};
|
|
932
932
|
opacity: 1;
|
|
933
933
|
}
|
|
934
934
|
|
|
@@ -947,7 +947,7 @@ var Qt = /*#__PURE__*/ N.forwardRef(Zt), $t = (e) => {
|
|
|
947
947
|
width: 100%;
|
|
948
948
|
height: 100%;
|
|
949
949
|
border-radius: var(--border-radius);
|
|
950
|
-
background-color: ${
|
|
950
|
+
background-color: ${n.grey2};
|
|
951
951
|
opacity: 0.2;
|
|
952
952
|
}
|
|
953
953
|
.node-excluded .node-foreign-object-div {
|
|
@@ -955,27 +955,27 @@ var Qt = /*#__PURE__*/ N.forwardRef(Zt), $t = (e) => {
|
|
|
955
955
|
}
|
|
956
956
|
}
|
|
957
957
|
|
|
958
|
-
${
|
|
959
|
-
},
|
|
960
|
-
function
|
|
958
|
+
${o.getCSS(a, i)}`;
|
|
959
|
+
}, an = { depth: -1 }, on = {}, sn = {};
|
|
960
|
+
function cn(e) {
|
|
961
961
|
return e.id;
|
|
962
962
|
}
|
|
963
|
-
function
|
|
963
|
+
function ln(e) {
|
|
964
964
|
return e.parentId;
|
|
965
965
|
}
|
|
966
|
-
function
|
|
967
|
-
var e =
|
|
966
|
+
function un() {
|
|
967
|
+
var e = cn, t = ln, n;
|
|
968
968
|
function r(r) {
|
|
969
969
|
var i = Array.from(r), a = e, o = t, s, c, l, u, d, f, p, m, h = /* @__PURE__ */ new Map();
|
|
970
970
|
if (n != null) {
|
|
971
|
-
let e = i.map((e, t) =>
|
|
972
|
-
for (let n of t) s.has(n) || (s.add(n), e.push(n), t.push(
|
|
971
|
+
let e = i.map((e, t) => dn(n(e, t, r))), t = e.map(fn), s = new Set(e).add("");
|
|
972
|
+
for (let n of t) s.has(n) || (s.add(n), e.push(n), t.push(fn(n)), i.push(sn));
|
|
973
973
|
a = (t, n) => e[n], o = (e, n) => t[n];
|
|
974
974
|
}
|
|
975
|
-
for (l = 0, s = i.length; l < s; ++l) c = i[l], f = i[l] = new
|
|
975
|
+
for (l = 0, s = i.length; l < s; ++l) c = i[l], f = i[l] = new $e(c), (p = a(c, l, r)) != null && (p += "") && (m = f.id = p, h.set(m, h.has(m) ? on : f)), (p = o(c, l, r)) != null && (p += "") && (f.parent = p);
|
|
976
976
|
for (l = 0; l < s; ++l) if (f = i[l], p = f.parent) {
|
|
977
977
|
if (d = h.get(p), !d) throw Error("missing: " + p);
|
|
978
|
-
if (d ===
|
|
978
|
+
if (d === on) throw Error("ambiguous: " + p);
|
|
979
979
|
d.children ? d.children.push(f) : d.children = [f], f.parent = d;
|
|
980
980
|
} else {
|
|
981
981
|
if (u) throw Error("multiple roots");
|
|
@@ -983,34 +983,34 @@ function ln() {
|
|
|
983
983
|
}
|
|
984
984
|
if (!u) throw Error("no root");
|
|
985
985
|
if (n != null) {
|
|
986
|
-
for (; u.data ===
|
|
987
|
-
for (let e = i.length - 1; e >= 0 && (f = i[e], f.data ===
|
|
986
|
+
for (; u.data === sn && u.children.length === 1;) u = u.children[0], --s;
|
|
987
|
+
for (let e = i.length - 1; e >= 0 && (f = i[e], f.data === sn); --e) f.data = null;
|
|
988
988
|
}
|
|
989
|
-
if (u.parent =
|
|
989
|
+
if (u.parent = an, u.eachBefore(function(e) {
|
|
990
990
|
e.depth = e.parent.depth + 1, --s;
|
|
991
|
-
}).eachBefore(
|
|
991
|
+
}).eachBefore(Qe), u.parent = null, s > 0) throw Error("cycle");
|
|
992
992
|
return u;
|
|
993
993
|
}
|
|
994
994
|
return r.id = function(t) {
|
|
995
|
-
return arguments.length ? (e =
|
|
995
|
+
return arguments.length ? (e = et(t), r) : e;
|
|
996
996
|
}, r.parentId = function(e) {
|
|
997
|
-
return arguments.length ? (t =
|
|
997
|
+
return arguments.length ? (t = et(e), r) : t;
|
|
998
998
|
}, r.path = function(e) {
|
|
999
|
-
return arguments.length ? (n =
|
|
999
|
+
return arguments.length ? (n = et(e), r) : n;
|
|
1000
1000
|
}, r;
|
|
1001
1001
|
}
|
|
1002
|
-
function
|
|
1002
|
+
function dn(e) {
|
|
1003
1003
|
e = `${e}`;
|
|
1004
1004
|
let t = e.length;
|
|
1005
|
-
return
|
|
1005
|
+
return pn(e, t - 1) && !pn(e, t - 2) && (e = e.slice(0, -1)), e[0] === "/" ? e : `/${e}`;
|
|
1006
1006
|
}
|
|
1007
|
-
function
|
|
1007
|
+
function fn(e) {
|
|
1008
1008
|
let t = e.length;
|
|
1009
1009
|
if (t < 2) return "";
|
|
1010
|
-
for (; --t > 1 && !
|
|
1010
|
+
for (; --t > 1 && !pn(e, t););
|
|
1011
1011
|
return e.slice(0, t);
|
|
1012
1012
|
}
|
|
1013
|
-
function
|
|
1013
|
+
function pn(e, t) {
|
|
1014
1014
|
if (e[t] === "/") {
|
|
1015
1015
|
let n = 0;
|
|
1016
1016
|
for (; t > 0 && e[--t] === "\\";) ++n;
|
|
@@ -1018,39 +1018,39 @@ function fn(e, t) {
|
|
|
1018
1018
|
}
|
|
1019
1019
|
return !1;
|
|
1020
1020
|
}
|
|
1021
|
-
function
|
|
1021
|
+
function mn(e, t) {
|
|
1022
1022
|
return e.parent === t.parent ? 1 : 2;
|
|
1023
1023
|
}
|
|
1024
|
-
function
|
|
1024
|
+
function hn(e) {
|
|
1025
1025
|
var t = e.children;
|
|
1026
1026
|
return t ? t[0] : e.t;
|
|
1027
1027
|
}
|
|
1028
|
-
function
|
|
1028
|
+
function gn(e) {
|
|
1029
1029
|
var t = e.children;
|
|
1030
1030
|
return t ? t[t.length - 1] : e.t;
|
|
1031
1031
|
}
|
|
1032
|
-
function
|
|
1032
|
+
function _n(e, t, n) {
|
|
1033
1033
|
var r = n / (t.i - e.i);
|
|
1034
1034
|
t.c -= r, t.s += n, e.c += r, t.z += n, t.m += n;
|
|
1035
1035
|
}
|
|
1036
|
-
function
|
|
1036
|
+
function vn(e) {
|
|
1037
1037
|
for (var t = 0, n = 0, r = e.children, i = r.length, a; --i >= 0;) a = r[i], a.z += t, a.m += t, t += a.s + (n += a.c);
|
|
1038
1038
|
}
|
|
1039
|
-
function
|
|
1039
|
+
function yn(e, t, n) {
|
|
1040
1040
|
return e.a.parent === t.parent ? e.a : n;
|
|
1041
1041
|
}
|
|
1042
|
-
function
|
|
1042
|
+
function bn(e, t) {
|
|
1043
1043
|
this._ = e, this.parent = null, this.children = null, this.A = null, this.a = this, this.z = 0, this.m = 0, this.c = 0, this.s = 0, this.t = null, this.i = t;
|
|
1044
1044
|
}
|
|
1045
|
-
|
|
1046
|
-
function
|
|
1047
|
-
for (var t = new
|
|
1048
|
-
return (t.parent = new
|
|
1045
|
+
bn.prototype = Object.create($e.prototype);
|
|
1046
|
+
function xn(e) {
|
|
1047
|
+
for (var t = new bn(e, 0), n, r = [t], i, a, o, s; n = r.pop();) if (a = n._.children) for (n.children = Array(s = a.length), o = s - 1; o >= 0; --o) r.push(i = n.children[o] = new bn(a[o], o)), i.parent = n;
|
|
1048
|
+
return (t.parent = new bn(null, 0)).children = [t], t;
|
|
1049
1049
|
}
|
|
1050
|
-
function
|
|
1051
|
-
var e =
|
|
1050
|
+
function Sn() {
|
|
1051
|
+
var e = mn, t = 1, n = 1, r = null;
|
|
1052
1052
|
function i(i) {
|
|
1053
|
-
var s =
|
|
1053
|
+
var s = xn(i);
|
|
1054
1054
|
if (s.eachAfter(a), s.parent.m = -s.z, s.eachBefore(o), r) i.eachBefore(c);
|
|
1055
1055
|
else {
|
|
1056
1056
|
var l = i, u = i, d = i;
|
|
@@ -1067,7 +1067,7 @@ function xn() {
|
|
|
1067
1067
|
function a(t) {
|
|
1068
1068
|
var n = t.children, r = t.parent.children, i = t.i ? r[t.i - 1] : null;
|
|
1069
1069
|
if (n) {
|
|
1070
|
-
|
|
1070
|
+
vn(t);
|
|
1071
1071
|
var a = (n[0].z + n[n.length - 1].z) / 2;
|
|
1072
1072
|
i ? (t.z = i.z + e(t._, i._), t.m = t.z - a) : t.z = a;
|
|
1073
1073
|
} else i && (t.z = i.z + e(t._, i._));
|
|
@@ -1078,8 +1078,8 @@ function xn() {
|
|
|
1078
1078
|
}
|
|
1079
1079
|
function s(t, n, r) {
|
|
1080
1080
|
if (n) {
|
|
1081
|
-
for (var i = t, a = t, o = n, s = i.parent.children[0], c = i.m, l = a.m, u = o.m, d = s.m, f; o =
|
|
1082
|
-
o && !
|
|
1081
|
+
for (var i = t, a = t, o = n, s = i.parent.children[0], c = i.m, l = a.m, u = o.m, d = s.m, f; o = gn(o), i = hn(i), o && i;) s = hn(s), a = gn(a), a.a = t, f = o.z + u - i.z - c + e(o._, i._), f > 0 && (_n(yn(o, t, r), t, f), c += f, l += f), u += o.m, c += i.m, d += s.m, l += a.m;
|
|
1082
|
+
o && !gn(a) && (a.t = o, a.m += u - l), i && !hn(s) && (s.t = i, s.m += c - d, r = t);
|
|
1083
1083
|
}
|
|
1084
1084
|
return r;
|
|
1085
1085
|
}
|
|
@@ -1094,14 +1094,14 @@ function xn() {
|
|
|
1094
1094
|
return arguments.length ? (r = !0, t = +e[0], n = +e[1], i) : r ? [t, n] : null;
|
|
1095
1095
|
}, i;
|
|
1096
1096
|
}
|
|
1097
|
-
var
|
|
1097
|
+
var I = "__root__", Cn = "__total__", wn = (e) => `__dimension__${JSON.stringify(e)}`, Tn = (e, t) => {
|
|
1098
1098
|
let n = e[t];
|
|
1099
1099
|
return n == null ? ["nil"] : [
|
|
1100
1100
|
"value",
|
|
1101
1101
|
typeof n,
|
|
1102
1102
|
n
|
|
1103
1103
|
];
|
|
1104
|
-
},
|
|
1104
|
+
}, En = (e, t) => {
|
|
1105
1105
|
if (t?.indicator !== "custom") return;
|
|
1106
1106
|
let n = t?.indicatorThreshold;
|
|
1107
1107
|
if (!n || e == null) return {
|
|
@@ -1127,66 +1127,66 @@ var L = "__root__", Sn = "__total__", Cn = (e) => `__dimension__${JSON.stringify
|
|
|
1127
1127
|
color: null,
|
|
1128
1128
|
icon: void 0
|
|
1129
1129
|
};
|
|
1130
|
-
},
|
|
1131
|
-
let
|
|
1132
|
-
return e.slots?.forEach((
|
|
1133
|
-
if (
|
|
1134
|
-
let
|
|
1135
|
-
enabled:
|
|
1130
|
+
}, Dn = (e, t, n, r) => {
|
|
1131
|
+
let i = {};
|
|
1132
|
+
return e.slots?.forEach((n) => {
|
|
1133
|
+
if (n.key === "main") return;
|
|
1134
|
+
let a = {
|
|
1135
|
+
enabled: n.enabled === !0,
|
|
1136
1136
|
label: "-",
|
|
1137
1137
|
value: null,
|
|
1138
|
-
indicator:
|
|
1138
|
+
indicator: n.indicator ?? null
|
|
1139
1139
|
};
|
|
1140
|
-
if (
|
|
1141
|
-
let
|
|
1142
|
-
if (
|
|
1143
|
-
let s =
|
|
1140
|
+
if (a.enabled) {
|
|
1141
|
+
let i = e.formatter;
|
|
1142
|
+
if (n.source === "field") {
|
|
1143
|
+
let s = r?.find((t) => t.parentId === e.dataItem.uniqueSignature && t.role === `tree-${n.key}`);
|
|
1144
1144
|
if (s) {
|
|
1145
|
-
let e =
|
|
1146
|
-
s.formatter && (
|
|
1145
|
+
let e = o(s.dataItem);
|
|
1146
|
+
s.formatter && (i = s.formatter), e && (a.value = t?.[e], a.label = a.value === null ? "-" : y(i?.format, a.value) ?? "-");
|
|
1147
1147
|
}
|
|
1148
|
-
} else
|
|
1149
|
-
|
|
1148
|
+
} else n.source === "variable" && (a.value = n.propertyValue, a.label = a.value === null ? "-" : y(i?.format, a.value) ?? "-");
|
|
1149
|
+
a.customIndicator = En(a.value, n);
|
|
1150
1150
|
}
|
|
1151
|
-
|
|
1152
|
-
}),
|
|
1153
|
-
},
|
|
1151
|
+
i[n.key] = { ...a };
|
|
1152
|
+
}), i;
|
|
1153
|
+
}, On = (e, t, n, r = !1) => {
|
|
1154
1154
|
if (n === 0 || e.data.id === "__total__") return !0;
|
|
1155
1155
|
let i = t ?? 2;
|
|
1156
1156
|
return e.depth - +!!r < i;
|
|
1157
|
-
},
|
|
1158
|
-
let
|
|
1159
|
-
id:
|
|
1157
|
+
}, kn = (e, t, n) => {
|
|
1158
|
+
let r = [{
|
|
1159
|
+
id: I,
|
|
1160
1160
|
parentId: null,
|
|
1161
1161
|
disabled: !1
|
|
1162
|
-
}],
|
|
1162
|
+
}], a = /* @__PURE__ */ new Set();
|
|
1163
1163
|
e.measures.forEach((e) => {
|
|
1164
|
-
|
|
1164
|
+
a.add(e.dataItem.uniqueSignature);
|
|
1165
1165
|
});
|
|
1166
|
-
let s = e.measures.filter((e) =>
|
|
1166
|
+
let s = e.measures.filter((e) => i(e));
|
|
1167
1167
|
e.measures.forEach((e) => {
|
|
1168
|
-
let t = e.dataItem.uniqueSignature, n = e.parentId &&
|
|
1169
|
-
|
|
1168
|
+
let t = e.dataItem.uniqueSignature, n = e.parentId && a.has(e.parentId) ? e.parentId : I;
|
|
1169
|
+
r.push({
|
|
1170
1170
|
id: t,
|
|
1171
1171
|
parentId: n,
|
|
1172
|
-
disabled: !
|
|
1172
|
+
disabled: !i(e)
|
|
1173
1173
|
});
|
|
1174
1174
|
});
|
|
1175
|
-
let c =
|
|
1175
|
+
let c = un().id((e) => e.id).parentId((e) => e.parentId)(r), u = [];
|
|
1176
1176
|
c.descendants().forEach((e) => {
|
|
1177
1177
|
if (e.data.disabled) return;
|
|
1178
1178
|
let t = e.ancestors().slice(1).find((e) => !e.data.disabled);
|
|
1179
|
-
t ?
|
|
1179
|
+
t ? u.push({
|
|
1180
1180
|
id: e.data.id,
|
|
1181
1181
|
parentId: t.data.id
|
|
1182
|
-
}) :
|
|
1182
|
+
}) : u.push({
|
|
1183
1183
|
id: e.data.id,
|
|
1184
1184
|
parentId: null
|
|
1185
1185
|
});
|
|
1186
1186
|
});
|
|
1187
|
-
let
|
|
1188
|
-
if (
|
|
1189
|
-
id:
|
|
1187
|
+
let d = u.flatMap((n) => {
|
|
1188
|
+
if (n.id === "__root__") return [{
|
|
1189
|
+
id: n.id,
|
|
1190
1190
|
parentId: null,
|
|
1191
1191
|
label: "Dummy Root",
|
|
1192
1192
|
value: {
|
|
@@ -1194,127 +1194,127 @@ var L = "__root__", Sn = "__total__", Cn = (e) => `__dimension__${JSON.stringify
|
|
|
1194
1194
|
value: null
|
|
1195
1195
|
}
|
|
1196
1196
|
}];
|
|
1197
|
-
let
|
|
1198
|
-
if (!
|
|
1199
|
-
let
|
|
1197
|
+
let r = s.find((e) => e.dataItem.uniqueSignature === n.id);
|
|
1198
|
+
if (!r) return [];
|
|
1199
|
+
let i = o(r.dataItem), a = t[0].items?.[0], c = r ? Dn(r, a, s, e.supportingMeasures) : {}, u = a?.[i], d = r?.slots?.find((e) => e.key === "main");
|
|
1200
1200
|
return [{
|
|
1201
|
-
id:
|
|
1202
|
-
parentId:
|
|
1203
|
-
label:
|
|
1201
|
+
id: n.id,
|
|
1202
|
+
parentId: n.parentId,
|
|
1203
|
+
label: l(r),
|
|
1204
1204
|
value: {
|
|
1205
|
-
label:
|
|
1206
|
-
value:
|
|
1205
|
+
label: y(r.formatter?.format, t[0].items?.[0]?.[i]) ?? "-",
|
|
1206
|
+
value: u
|
|
1207
1207
|
},
|
|
1208
|
-
indicator:
|
|
1209
|
-
customIndicator:
|
|
1208
|
+
indicator: d?.indicator ?? null,
|
|
1209
|
+
customIndicator: En(u, d),
|
|
1210
1210
|
brush: {
|
|
1211
|
-
key: [
|
|
1212
|
-
value:
|
|
1211
|
+
key: [fe.sourceKey, fe.field].join("/"),
|
|
1212
|
+
value: ue(r)
|
|
1213
1213
|
},
|
|
1214
1214
|
...c
|
|
1215
1215
|
}];
|
|
1216
|
-
}),
|
|
1217
|
-
return
|
|
1216
|
+
}), f = un().id((e) => e.id).parentId((e) => e.parentId)(d), p = s.map((e) => e.dataItem.uniqueSignature);
|
|
1217
|
+
return f.sort((e, t) => p.indexOf(e.data.id) - p.indexOf(t.data.id)), f.descendants().forEach((e) => {
|
|
1218
1218
|
let t = !1;
|
|
1219
|
-
t = e.data.id in
|
|
1220
|
-
}),
|
|
1221
|
-
},
|
|
1219
|
+
t = e.data.id in n ? n[e.data.id] === !1 : e.data.expanded?.enabled ? e.data.expanded.value === !1 : !1, t && (e._children = e.children, e.children = void 0);
|
|
1220
|
+
}), f;
|
|
1221
|
+
}, An = (e, t, n) => {
|
|
1222
1222
|
if (t.itemsNotAffectedByFiltering?.pattern?.length && e.staticFilters.ignoreGlobalFilters && e.staticFilters.showGlobalFiltersEffect) {
|
|
1223
1223
|
let e = [0, ...t.itemsNotAffectedByFiltering.pattern.map((e) => n[e]).filter((e) => e !== null)].join("-");
|
|
1224
1224
|
return !t.itemsNotAffectedByFiltering.itemsMap?.[e];
|
|
1225
1225
|
}
|
|
1226
1226
|
return !1;
|
|
1227
|
-
},
|
|
1228
|
-
let { id: o, parentId: s, prop: c, measureProp: l, dataItemIdx: u, engineKey: d } = a, f = n?.slots?.find((e) => e.key === "main"), p = i && n ?
|
|
1227
|
+
}, jn = (e, t, n, r, i, a) => {
|
|
1228
|
+
let { id: o, parentId: s, prop: c, measureProp: l, dataItemIdx: u, engineKey: d } = a, f = n?.slots?.find((e) => e.key === "main"), p = i && n ? Dn(n, r, [n], e.supportingMeasures) : {};
|
|
1229
1229
|
return {
|
|
1230
1230
|
id: o,
|
|
1231
1231
|
parentId: s,
|
|
1232
1232
|
label: String(r[c]),
|
|
1233
1233
|
row: +u,
|
|
1234
1234
|
value: i && n && l ? {
|
|
1235
|
-
label:
|
|
1235
|
+
label: y(n.formatter?.format, r[l]) ?? "-",
|
|
1236
1236
|
value: r[l]
|
|
1237
1237
|
} : null,
|
|
1238
1238
|
indicator: f?.indicator ?? null,
|
|
1239
|
-
customIndicator:
|
|
1239
|
+
customIndicator: En(l ? r[l] : null, f),
|
|
1240
1240
|
brush: {
|
|
1241
1241
|
key: d,
|
|
1242
1242
|
value: r[c]
|
|
1243
1243
|
},
|
|
1244
|
-
_excluded:
|
|
1244
|
+
_excluded: An(e, t, r),
|
|
1245
1245
|
...p
|
|
1246
1246
|
};
|
|
1247
1247
|
};
|
|
1248
|
-
function
|
|
1249
|
-
let
|
|
1250
|
-
|
|
1251
|
-
let n =
|
|
1252
|
-
if (!
|
|
1253
|
-
|
|
1248
|
+
function Mn(e, t, n) {
|
|
1249
|
+
let r = t[0], s = e.dimensions.filter((e) => i(e)), c = {}, l = s.map((t) => [o(t.dataItem), a(e.referencedData, t.dataItem.internalKey) ?? o(t.dataItem)]), u = e.measures.filter((e) => i(e))[0], d = u ? o(u.dataItem) : null, f = e.totals?.enabled ?? !1, p = u?.slots?.find((e) => e.key === "main"), m, h, g = /* @__PURE__ */ new Set(), _ = r.groupings, v = _ ? Object.keys(_) : void 0;
|
|
1250
|
+
_ && v && v.forEach((t) => {
|
|
1251
|
+
let n = _[t], i = r.items[+t], a = l.filter(([e]) => n[e] === 0);
|
|
1252
|
+
if (!a.length) {
|
|
1253
|
+
m = d ? i[d] : void 0, h = i;
|
|
1254
1254
|
return;
|
|
1255
1255
|
}
|
|
1256
|
-
let [
|
|
1257
|
-
|
|
1256
|
+
let [o, s] = a.length ? a[a.length - 1] : ["", ""], p = wn(a.map((e) => Tn(i, e[0]))), v = a.slice(0, -1), y = v.length ? wn(v.map((e) => Tn(i, e[0]))) : f ? Cn : I;
|
|
1257
|
+
a.length < l.length && g.add(p), c[p] || (c[p] = jn(e, r, u, i, !!u, {
|
|
1258
1258
|
engineKey: s,
|
|
1259
1259
|
id: p,
|
|
1260
1260
|
parentId: y,
|
|
1261
1261
|
measureProp: d,
|
|
1262
|
-
prop:
|
|
1262
|
+
prop: o,
|
|
1263
1263
|
dataItemIdx: +t
|
|
1264
1264
|
}));
|
|
1265
|
-
}),
|
|
1266
|
-
|
|
1267
|
-
if (t[
|
|
1268
|
-
console.warn(`Dimension property ${
|
|
1265
|
+
}), r.items.forEach((t, n) => {
|
|
1266
|
+
v?.includes(String(n)) || l.forEach(([i, a], o, s) => {
|
|
1267
|
+
if (t[i] === void 0) {
|
|
1268
|
+
console.warn(`Dimension property ${i} is missing in data item at index ${n}, skipping this dimension for this item`);
|
|
1269
1269
|
return;
|
|
1270
1270
|
}
|
|
1271
|
-
let l =
|
|
1272
|
-
c[l] || (c[l] =
|
|
1273
|
-
engineKey:
|
|
1271
|
+
let l = wn(s.slice(0, o + 1).map((e) => Tn(t, e[0]))), p = o === 0 ? f ? Cn : I : wn(s.slice(0, o).map((e) => Tn(t, e[0])));
|
|
1272
|
+
c[l] || (c[l] = jn(e, r, u, t, o === s.length - 1 && !!u, {
|
|
1273
|
+
engineKey: a,
|
|
1274
1274
|
dataItemIdx: n,
|
|
1275
1275
|
id: l,
|
|
1276
1276
|
parentId: p,
|
|
1277
1277
|
measureProp: d,
|
|
1278
|
-
prop:
|
|
1278
|
+
prop: i
|
|
1279
1279
|
}));
|
|
1280
1280
|
});
|
|
1281
1281
|
});
|
|
1282
|
-
let b =
|
|
1282
|
+
let b = m ?? Object.values(c).reduce((e, t) => e + (g.has(t.id) ? 0 : t.value?.value ?? 0), 0), x = h ?? r.totals, S = Object.values(c);
|
|
1283
1283
|
f && S.unshift({
|
|
1284
|
-
id:
|
|
1285
|
-
parentId:
|
|
1284
|
+
id: Cn,
|
|
1285
|
+
parentId: I,
|
|
1286
1286
|
label: "Total",
|
|
1287
1287
|
row: -1,
|
|
1288
1288
|
value: u ? {
|
|
1289
|
-
label:
|
|
1289
|
+
label: y(u.formatter?.format, b) ?? "-",
|
|
1290
1290
|
value: b
|
|
1291
1291
|
} : null,
|
|
1292
1292
|
indicator: p?.indicator ?? null,
|
|
1293
|
-
customIndicator:
|
|
1294
|
-
...u ?
|
|
1293
|
+
customIndicator: En(b, p),
|
|
1294
|
+
...u ? Dn(u, x, [u], e.supportingMeasures) : {}
|
|
1295
1295
|
}), S.unshift({
|
|
1296
|
-
id:
|
|
1296
|
+
id: I,
|
|
1297
1297
|
parentId: null,
|
|
1298
1298
|
label: "Dummy Root",
|
|
1299
1299
|
row: -1,
|
|
1300
1300
|
value: null
|
|
1301
1301
|
});
|
|
1302
|
-
let C =
|
|
1302
|
+
let C = un().id((e) => e.id).parentId((e) => e.parentId)(S);
|
|
1303
1303
|
return C.sort((e, t) => (e.data.row ?? 0) - (t.data.row ?? 0)), C.descendants().forEach((t) => {
|
|
1304
1304
|
if (t.data.id === "__total__") return;
|
|
1305
|
-
let
|
|
1306
|
-
|
|
1305
|
+
let r = !1;
|
|
1306
|
+
r = t.data.id in n ? n[t.data.id] === !1 : !On(t, e.treeChartSettings?.initialExpandedLevels, s.length, f), r && (t._children = t.children, t.children = void 0);
|
|
1307
1307
|
}), C;
|
|
1308
1308
|
}
|
|
1309
|
-
var
|
|
1310
|
-
let r = e.dimensions.filter(
|
|
1311
|
-
return (0,
|
|
1309
|
+
var Nn = ({ vSpec: e, data: t, nodeExpandState: n }) => {
|
|
1310
|
+
let r = e.dimensions.filter(i).length, [a, o] = (0, M.useState)(null);
|
|
1311
|
+
return (0, M.useEffect)(() => {
|
|
1312
1312
|
if (r > 0) {
|
|
1313
|
-
let r =
|
|
1313
|
+
let r = Mn(e, t, n.current);
|
|
1314
1314
|
o(r);
|
|
1315
1315
|
return;
|
|
1316
1316
|
}
|
|
1317
|
-
let i =
|
|
1317
|
+
let i = kn(e, t, n.current);
|
|
1318
1318
|
o(i);
|
|
1319
1319
|
}, [
|
|
1320
1320
|
t,
|
|
@@ -1323,118 +1323,118 @@ var Mn = ({ vSpec: e, data: t, nodeExpandState: n }) => {
|
|
|
1323
1323
|
e.supportingMeasures,
|
|
1324
1324
|
e.treeChartSettings?.nodeExpandState,
|
|
1325
1325
|
e.totals?.enabled
|
|
1326
|
-
]),
|
|
1327
|
-
},
|
|
1326
|
+
]), a;
|
|
1327
|
+
}, Pn = {
|
|
1328
1328
|
svg: "http://www.w3.org/2000/svg",
|
|
1329
1329
|
xhtml: "http://www.w3.org/1999/xhtml",
|
|
1330
1330
|
xlink: "http://www.w3.org/1999/xlink",
|
|
1331
1331
|
xml: "http://www.w3.org/XML/1998/namespace",
|
|
1332
1332
|
xmlns: "http://www.w3.org/2000/xmlns/"
|
|
1333
1333
|
};
|
|
1334
|
-
function
|
|
1334
|
+
function Fn(e) {
|
|
1335
1335
|
var t = e += "", n = t.indexOf(":");
|
|
1336
|
-
return n >= 0 && (t = e.slice(0, n)) !== "xmlns" && (e = e.slice(n + 1)),
|
|
1337
|
-
space:
|
|
1336
|
+
return n >= 0 && (t = e.slice(0, n)) !== "xmlns" && (e = e.slice(n + 1)), Pn.hasOwnProperty(t) ? {
|
|
1337
|
+
space: Pn[t],
|
|
1338
1338
|
local: e
|
|
1339
1339
|
} : e;
|
|
1340
1340
|
}
|
|
1341
|
-
function
|
|
1341
|
+
function In(e) {
|
|
1342
1342
|
return function() {
|
|
1343
1343
|
var t = this.ownerDocument, n = this.namespaceURI;
|
|
1344
1344
|
return n === "http://www.w3.org/1999/xhtml" && t.documentElement.namespaceURI === "http://www.w3.org/1999/xhtml" ? t.createElement(e) : t.createElementNS(n, e);
|
|
1345
1345
|
};
|
|
1346
1346
|
}
|
|
1347
|
-
function
|
|
1347
|
+
function Ln(e) {
|
|
1348
1348
|
return function() {
|
|
1349
1349
|
return this.ownerDocument.createElementNS(e.space, e.local);
|
|
1350
1350
|
};
|
|
1351
1351
|
}
|
|
1352
|
-
function
|
|
1353
|
-
var t =
|
|
1354
|
-
return (t.local ?
|
|
1352
|
+
function Rn(e) {
|
|
1353
|
+
var t = Fn(e);
|
|
1354
|
+
return (t.local ? Ln : In)(t);
|
|
1355
1355
|
}
|
|
1356
|
-
function
|
|
1357
|
-
function
|
|
1358
|
-
return e == null ?
|
|
1356
|
+
function zn() {}
|
|
1357
|
+
function Bn(e) {
|
|
1358
|
+
return e == null ? zn : function() {
|
|
1359
1359
|
return this.querySelector(e);
|
|
1360
1360
|
};
|
|
1361
1361
|
}
|
|
1362
|
-
function
|
|
1363
|
-
typeof e != "function" && (e =
|
|
1362
|
+
function Vn(e) {
|
|
1363
|
+
typeof e != "function" && (e = Bn(e));
|
|
1364
1364
|
for (var t = this._groups, n = t.length, r = Array(n), i = 0; i < n; ++i) for (var a = t[i], o = a.length, s = r[i] = Array(o), c, l, u = 0; u < o; ++u) (c = a[u]) && (l = e.call(c, c.__data__, u, a)) && ("__data__" in c && (l.__data__ = c.__data__), s[u] = l);
|
|
1365
|
-
return new
|
|
1365
|
+
return new R(r, this._parents);
|
|
1366
1366
|
}
|
|
1367
|
-
function
|
|
1367
|
+
function Hn(e) {
|
|
1368
1368
|
return e == null ? [] : Array.isArray(e) ? e : Array.from(e);
|
|
1369
1369
|
}
|
|
1370
|
-
function
|
|
1370
|
+
function Un() {
|
|
1371
1371
|
return [];
|
|
1372
1372
|
}
|
|
1373
|
-
function
|
|
1374
|
-
return e == null ?
|
|
1373
|
+
function Wn(e) {
|
|
1374
|
+
return e == null ? Un : function() {
|
|
1375
1375
|
return this.querySelectorAll(e);
|
|
1376
1376
|
};
|
|
1377
1377
|
}
|
|
1378
|
-
function
|
|
1378
|
+
function Gn(e) {
|
|
1379
1379
|
return function() {
|
|
1380
|
-
return
|
|
1380
|
+
return Hn(e.apply(this, arguments));
|
|
1381
1381
|
};
|
|
1382
1382
|
}
|
|
1383
|
-
function
|
|
1384
|
-
e = typeof e == "function" ?
|
|
1383
|
+
function Kn(e) {
|
|
1384
|
+
e = typeof e == "function" ? Gn(e) : Wn(e);
|
|
1385
1385
|
for (var t = this._groups, n = t.length, r = [], i = [], a = 0; a < n; ++a) for (var o = t[a], s = o.length, c, l = 0; l < s; ++l) (c = o[l]) && (r.push(e.call(c, c.__data__, l, o)), i.push(c));
|
|
1386
|
-
return new
|
|
1386
|
+
return new R(r, i);
|
|
1387
1387
|
}
|
|
1388
|
-
function
|
|
1388
|
+
function qn(e) {
|
|
1389
1389
|
return function() {
|
|
1390
1390
|
return this.matches(e);
|
|
1391
1391
|
};
|
|
1392
1392
|
}
|
|
1393
|
-
function
|
|
1393
|
+
function Jn(e) {
|
|
1394
1394
|
return function(t) {
|
|
1395
1395
|
return t.matches(e);
|
|
1396
1396
|
};
|
|
1397
1397
|
}
|
|
1398
|
-
var
|
|
1399
|
-
function
|
|
1398
|
+
var Yn = Array.prototype.find;
|
|
1399
|
+
function Xn(e) {
|
|
1400
1400
|
return function() {
|
|
1401
|
-
return
|
|
1401
|
+
return Yn.call(this.children, e);
|
|
1402
1402
|
};
|
|
1403
1403
|
}
|
|
1404
|
-
function
|
|
1404
|
+
function Zn() {
|
|
1405
1405
|
return this.firstElementChild;
|
|
1406
1406
|
}
|
|
1407
|
-
function
|
|
1408
|
-
return this.select(e == null ?
|
|
1407
|
+
function Qn(e) {
|
|
1408
|
+
return this.select(e == null ? Zn : Xn(typeof e == "function" ? e : Jn(e)));
|
|
1409
1409
|
}
|
|
1410
|
-
var
|
|
1411
|
-
function
|
|
1410
|
+
var $n = Array.prototype.filter;
|
|
1411
|
+
function er() {
|
|
1412
1412
|
return Array.from(this.children);
|
|
1413
1413
|
}
|
|
1414
|
-
function
|
|
1414
|
+
function tr(e) {
|
|
1415
1415
|
return function() {
|
|
1416
|
-
return
|
|
1416
|
+
return $n.call(this.children, e);
|
|
1417
1417
|
};
|
|
1418
1418
|
}
|
|
1419
|
-
function tr(e) {
|
|
1420
|
-
return this.selectAll(e == null ? $n : er(typeof e == "function" ? e : qn(e)));
|
|
1421
|
-
}
|
|
1422
1419
|
function nr(e) {
|
|
1423
|
-
typeof e
|
|
1424
|
-
for (var t = this._groups, n = t.length, r = Array(n), i = 0; i < n; ++i) for (var a = t[i], o = a.length, s = r[i] = [], c, l = 0; l < o; ++l) (c = a[l]) && e.call(c, c.__data__, l, a) && s.push(c);
|
|
1425
|
-
return new z(r, this._parents);
|
|
1420
|
+
return this.selectAll(e == null ? er : tr(typeof e == "function" ? e : Jn(e)));
|
|
1426
1421
|
}
|
|
1427
1422
|
function rr(e) {
|
|
1423
|
+
typeof e != "function" && (e = qn(e));
|
|
1424
|
+
for (var t = this._groups, n = t.length, r = Array(n), i = 0; i < n; ++i) for (var a = t[i], o = a.length, s = r[i] = [], c, l = 0; l < o; ++l) (c = a[l]) && e.call(c, c.__data__, l, a) && s.push(c);
|
|
1425
|
+
return new R(r, this._parents);
|
|
1426
|
+
}
|
|
1427
|
+
function ir(e) {
|
|
1428
1428
|
return Array(e.length);
|
|
1429
1429
|
}
|
|
1430
|
-
function
|
|
1431
|
-
return new
|
|
1430
|
+
function ar() {
|
|
1431
|
+
return new R(this._enter || this._groups.map(ir), this._parents);
|
|
1432
1432
|
}
|
|
1433
|
-
function
|
|
1433
|
+
function or(e, t) {
|
|
1434
1434
|
this.ownerDocument = e.ownerDocument, this.namespaceURI = e.namespaceURI, this._next = null, this._parent = e, this.__data__ = t;
|
|
1435
1435
|
}
|
|
1436
|
-
|
|
1437
|
-
constructor:
|
|
1436
|
+
or.prototype = {
|
|
1437
|
+
constructor: or,
|
|
1438
1438
|
appendChild: function(e) {
|
|
1439
1439
|
return this._parent.insertBefore(e, this._next);
|
|
1440
1440
|
},
|
|
@@ -1448,59 +1448,59 @@ ar.prototype = {
|
|
|
1448
1448
|
return this._parent.querySelectorAll(e);
|
|
1449
1449
|
}
|
|
1450
1450
|
};
|
|
1451
|
-
function
|
|
1451
|
+
function sr(e) {
|
|
1452
1452
|
return function() {
|
|
1453
1453
|
return e;
|
|
1454
1454
|
};
|
|
1455
1455
|
}
|
|
1456
|
-
function
|
|
1457
|
-
for (var o = 0, s, c = t.length, l = a.length; o < l; ++o) (s = t[o]) ? (s.__data__ = a[o], r[o] = s) : n[o] = new
|
|
1456
|
+
function cr(e, t, n, r, i, a) {
|
|
1457
|
+
for (var o = 0, s, c = t.length, l = a.length; o < l; ++o) (s = t[o]) ? (s.__data__ = a[o], r[o] = s) : n[o] = new or(e, a[o]);
|
|
1458
1458
|
for (; o < c; ++o) (s = t[o]) && (i[o] = s);
|
|
1459
1459
|
}
|
|
1460
|
-
function
|
|
1460
|
+
function lr(e, t, n, r, i, a, o) {
|
|
1461
1461
|
var s, c, l = /* @__PURE__ */ new Map(), u = t.length, d = a.length, f = Array(u), p;
|
|
1462
1462
|
for (s = 0; s < u; ++s) (c = t[s]) && (f[s] = p = o.call(c, c.__data__, s, t) + "", l.has(p) ? i[s] = c : l.set(p, c));
|
|
1463
|
-
for (s = 0; s < d; ++s) p = o.call(e, a[s], s, a) + "", (c = l.get(p)) ? (r[s] = c, c.__data__ = a[s], l.delete(p)) : n[s] = new
|
|
1463
|
+
for (s = 0; s < d; ++s) p = o.call(e, a[s], s, a) + "", (c = l.get(p)) ? (r[s] = c, c.__data__ = a[s], l.delete(p)) : n[s] = new or(e, a[s]);
|
|
1464
1464
|
for (s = 0; s < u; ++s) (c = t[s]) && l.get(f[s]) === c && (i[s] = c);
|
|
1465
1465
|
}
|
|
1466
|
-
function
|
|
1466
|
+
function ur(e) {
|
|
1467
1467
|
return e.__data__;
|
|
1468
1468
|
}
|
|
1469
|
-
function
|
|
1470
|
-
if (!arguments.length) return Array.from(this,
|
|
1471
|
-
var n = t ?
|
|
1472
|
-
typeof e != "function" && (e =
|
|
1469
|
+
function dr(e, t) {
|
|
1470
|
+
if (!arguments.length) return Array.from(this, ur);
|
|
1471
|
+
var n = t ? lr : cr, r = this._parents, i = this._groups;
|
|
1472
|
+
typeof e != "function" && (e = sr(e));
|
|
1473
1473
|
for (var a = i.length, o = Array(a), s = Array(a), c = Array(a), l = 0; l < a; ++l) {
|
|
1474
|
-
var u = r[l], d = i[l], f = d.length, p =
|
|
1474
|
+
var u = r[l], d = i[l], f = d.length, p = fr(e.call(u, u && u.__data__, l, r)), m = p.length, h = s[l] = Array(m), g = o[l] = Array(m);
|
|
1475
1475
|
n(u, d, h, g, c[l] = Array(f), p, t);
|
|
1476
1476
|
for (var _ = 0, v = 0, y, b; _ < m; ++_) if (y = h[_]) {
|
|
1477
1477
|
for (_ >= v && (v = _ + 1); !(b = g[v]) && ++v < m;);
|
|
1478
1478
|
y._next = b || null;
|
|
1479
1479
|
}
|
|
1480
1480
|
}
|
|
1481
|
-
return o = new
|
|
1481
|
+
return o = new R(o, r), o._enter = s, o._exit = c, o;
|
|
1482
1482
|
}
|
|
1483
|
-
function
|
|
1483
|
+
function fr(e) {
|
|
1484
1484
|
return typeof e == "object" && "length" in e ? e : Array.from(e);
|
|
1485
1485
|
}
|
|
1486
|
-
function
|
|
1487
|
-
return new
|
|
1486
|
+
function pr() {
|
|
1487
|
+
return new R(this._exit || this._groups.map(ir), this._parents);
|
|
1488
1488
|
}
|
|
1489
|
-
function
|
|
1489
|
+
function mr(e, t, n) {
|
|
1490
1490
|
var r = this.enter(), i = this, a = this.exit();
|
|
1491
1491
|
return typeof e == "function" ? (r = e(r), r &&= r.selection()) : r = r.append(e + ""), t != null && (i = t(i), i &&= i.selection()), n == null ? a.remove() : n(a), r && i ? r.merge(i).order() : i;
|
|
1492
1492
|
}
|
|
1493
|
-
function
|
|
1493
|
+
function hr(e) {
|
|
1494
1494
|
for (var t = e.selection ? e.selection() : e, n = this._groups, r = t._groups, i = n.length, a = r.length, o = Math.min(i, a), s = Array(i), c = 0; c < o; ++c) for (var l = n[c], u = r[c], d = l.length, f = s[c] = Array(d), p, m = 0; m < d; ++m) (p = l[m] || u[m]) && (f[m] = p);
|
|
1495
1495
|
for (; c < i; ++c) s[c] = n[c];
|
|
1496
|
-
return new
|
|
1496
|
+
return new R(s, this._parents);
|
|
1497
1497
|
}
|
|
1498
|
-
function
|
|
1498
|
+
function gr() {
|
|
1499
1499
|
for (var e = this._groups, t = -1, n = e.length; ++t < n;) for (var r = e[t], i = r.length - 1, a = r[i], o; --i >= 0;) (o = r[i]) && (a && o.compareDocumentPosition(a) ^ 4 && a.parentNode.insertBefore(o, a), a = o);
|
|
1500
1500
|
return this;
|
|
1501
1501
|
}
|
|
1502
|
-
function
|
|
1503
|
-
e ||=
|
|
1502
|
+
function _r(e) {
|
|
1503
|
+
e ||= vr;
|
|
1504
1504
|
function t(t, n) {
|
|
1505
1505
|
return t && n ? e(t.__data__, n.__data__) : !t - !n;
|
|
1506
1506
|
}
|
|
@@ -1508,131 +1508,131 @@ function gr(e) {
|
|
|
1508
1508
|
for (var o = n[a], s = o.length, c = i[a] = Array(s), l, u = 0; u < s; ++u) (l = o[u]) && (c[u] = l);
|
|
1509
1509
|
c.sort(t);
|
|
1510
1510
|
}
|
|
1511
|
-
return new
|
|
1511
|
+
return new R(i, this._parents).order();
|
|
1512
1512
|
}
|
|
1513
|
-
function
|
|
1513
|
+
function vr(e, t) {
|
|
1514
1514
|
return e < t ? -1 : e > t ? 1 : e >= t ? 0 : NaN;
|
|
1515
1515
|
}
|
|
1516
|
-
function
|
|
1516
|
+
function yr() {
|
|
1517
1517
|
var e = arguments[0];
|
|
1518
1518
|
return arguments[0] = this, e.apply(null, arguments), this;
|
|
1519
1519
|
}
|
|
1520
|
-
function
|
|
1520
|
+
function br() {
|
|
1521
1521
|
return Array.from(this);
|
|
1522
1522
|
}
|
|
1523
|
-
function
|
|
1523
|
+
function xr() {
|
|
1524
1524
|
for (var e = this._groups, t = 0, n = e.length; t < n; ++t) for (var r = e[t], i = 0, a = r.length; i < a; ++i) {
|
|
1525
1525
|
var o = r[i];
|
|
1526
1526
|
if (o) return o;
|
|
1527
1527
|
}
|
|
1528
1528
|
return null;
|
|
1529
1529
|
}
|
|
1530
|
-
function
|
|
1530
|
+
function Sr() {
|
|
1531
1531
|
let e = 0;
|
|
1532
1532
|
for (let t of this) ++e;
|
|
1533
1533
|
return e;
|
|
1534
1534
|
}
|
|
1535
|
-
function
|
|
1535
|
+
function Cr() {
|
|
1536
1536
|
return !this.node();
|
|
1537
1537
|
}
|
|
1538
|
-
function
|
|
1538
|
+
function wr(e) {
|
|
1539
1539
|
for (var t = this._groups, n = 0, r = t.length; n < r; ++n) for (var i = t[n], a = 0, o = i.length, s; a < o; ++a) (s = i[a]) && e.call(s, s.__data__, a, i);
|
|
1540
1540
|
return this;
|
|
1541
1541
|
}
|
|
1542
|
-
function
|
|
1542
|
+
function Tr(e) {
|
|
1543
1543
|
return function() {
|
|
1544
1544
|
this.removeAttribute(e);
|
|
1545
1545
|
};
|
|
1546
1546
|
}
|
|
1547
|
-
function
|
|
1547
|
+
function Er(e) {
|
|
1548
1548
|
return function() {
|
|
1549
1549
|
this.removeAttributeNS(e.space, e.local);
|
|
1550
1550
|
};
|
|
1551
1551
|
}
|
|
1552
|
-
function
|
|
1552
|
+
function Dr(e, t) {
|
|
1553
1553
|
return function() {
|
|
1554
1554
|
this.setAttribute(e, t);
|
|
1555
1555
|
};
|
|
1556
1556
|
}
|
|
1557
|
-
function
|
|
1557
|
+
function Or(e, t) {
|
|
1558
1558
|
return function() {
|
|
1559
1559
|
this.setAttributeNS(e.space, e.local, t);
|
|
1560
1560
|
};
|
|
1561
1561
|
}
|
|
1562
|
-
function
|
|
1562
|
+
function kr(e, t) {
|
|
1563
1563
|
return function() {
|
|
1564
1564
|
var n = t.apply(this, arguments);
|
|
1565
1565
|
n == null ? this.removeAttribute(e) : this.setAttribute(e, n);
|
|
1566
1566
|
};
|
|
1567
1567
|
}
|
|
1568
|
-
function
|
|
1568
|
+
function Ar(e, t) {
|
|
1569
1569
|
return function() {
|
|
1570
1570
|
var n = t.apply(this, arguments);
|
|
1571
1571
|
n == null ? this.removeAttributeNS(e.space, e.local) : this.setAttributeNS(e.space, e.local, n);
|
|
1572
1572
|
};
|
|
1573
1573
|
}
|
|
1574
|
-
function
|
|
1575
|
-
var n =
|
|
1574
|
+
function jr(e, t) {
|
|
1575
|
+
var n = Fn(e);
|
|
1576
1576
|
if (arguments.length < 2) {
|
|
1577
1577
|
var r = this.node();
|
|
1578
1578
|
return n.local ? r.getAttributeNS(n.space, n.local) : r.getAttribute(n);
|
|
1579
1579
|
}
|
|
1580
|
-
return this.each((t == null ? n.local ?
|
|
1580
|
+
return this.each((t == null ? n.local ? Er : Tr : typeof t == "function" ? n.local ? Ar : kr : n.local ? Or : Dr)(n, t));
|
|
1581
1581
|
}
|
|
1582
|
-
function
|
|
1582
|
+
function Mr(e) {
|
|
1583
1583
|
return e.ownerDocument && e.ownerDocument.defaultView || e.document && e || e.defaultView;
|
|
1584
1584
|
}
|
|
1585
|
-
function
|
|
1585
|
+
function Nr(e) {
|
|
1586
1586
|
return function() {
|
|
1587
1587
|
this.style.removeProperty(e);
|
|
1588
1588
|
};
|
|
1589
1589
|
}
|
|
1590
|
-
function
|
|
1590
|
+
function Pr(e, t, n) {
|
|
1591
1591
|
return function() {
|
|
1592
1592
|
this.style.setProperty(e, t, n);
|
|
1593
1593
|
};
|
|
1594
1594
|
}
|
|
1595
|
-
function
|
|
1595
|
+
function Fr(e, t, n) {
|
|
1596
1596
|
return function() {
|
|
1597
1597
|
var r = t.apply(this, arguments);
|
|
1598
1598
|
r == null ? this.style.removeProperty(e) : this.style.setProperty(e, r, n);
|
|
1599
1599
|
};
|
|
1600
1600
|
}
|
|
1601
|
-
function
|
|
1602
|
-
return arguments.length > 1 ? this.each((t == null ?
|
|
1601
|
+
function Ir(e, t, n) {
|
|
1602
|
+
return arguments.length > 1 ? this.each((t == null ? Nr : typeof t == "function" ? Fr : Pr)(e, t, n ?? "")) : L(this.node(), e);
|
|
1603
1603
|
}
|
|
1604
|
-
function
|
|
1605
|
-
return e.style.getPropertyValue(t) ||
|
|
1604
|
+
function L(e, t) {
|
|
1605
|
+
return e.style.getPropertyValue(t) || Mr(e).getComputedStyle(e, null).getPropertyValue(t);
|
|
1606
1606
|
}
|
|
1607
|
-
function
|
|
1607
|
+
function Lr(e) {
|
|
1608
1608
|
return function() {
|
|
1609
1609
|
delete this[e];
|
|
1610
1610
|
};
|
|
1611
1611
|
}
|
|
1612
|
-
function
|
|
1612
|
+
function Rr(e, t) {
|
|
1613
1613
|
return function() {
|
|
1614
1614
|
this[e] = t;
|
|
1615
1615
|
};
|
|
1616
1616
|
}
|
|
1617
|
-
function
|
|
1617
|
+
function zr(e, t) {
|
|
1618
1618
|
return function() {
|
|
1619
1619
|
var n = t.apply(this, arguments);
|
|
1620
1620
|
n == null ? delete this[e] : this[e] = n;
|
|
1621
1621
|
};
|
|
1622
1622
|
}
|
|
1623
|
-
function
|
|
1624
|
-
return arguments.length > 1 ? this.each((t == null ?
|
|
1625
|
-
}
|
|
1626
|
-
function Br(e) {
|
|
1627
|
-
return e.trim().split(/^|\s+/);
|
|
1623
|
+
function Br(e, t) {
|
|
1624
|
+
return arguments.length > 1 ? this.each((t == null ? Lr : typeof t == "function" ? zr : Rr)(e, t)) : this.node()[e];
|
|
1628
1625
|
}
|
|
1629
1626
|
function Vr(e) {
|
|
1630
|
-
return e.
|
|
1627
|
+
return e.trim().split(/^|\s+/);
|
|
1631
1628
|
}
|
|
1632
1629
|
function Hr(e) {
|
|
1633
|
-
|
|
1630
|
+
return e.classList || new Ur(e);
|
|
1634
1631
|
}
|
|
1635
|
-
|
|
1632
|
+
function Ur(e) {
|
|
1633
|
+
this._node = e, this._names = Vr(e.getAttribute("class") || "");
|
|
1634
|
+
}
|
|
1635
|
+
Ur.prototype = {
|
|
1636
1636
|
add: function(e) {
|
|
1637
1637
|
this._names.indexOf(e) < 0 && (this._names.push(e), this._node.setAttribute("class", this._names.join(" ")));
|
|
1638
1638
|
},
|
|
@@ -1644,123 +1644,123 @@ Hr.prototype = {
|
|
|
1644
1644
|
return this._names.indexOf(e) >= 0;
|
|
1645
1645
|
}
|
|
1646
1646
|
};
|
|
1647
|
-
function Ur(e, t) {
|
|
1648
|
-
for (var n = Vr(e), r = -1, i = t.length; ++r < i;) n.add(t[r]);
|
|
1649
|
-
}
|
|
1650
1647
|
function Wr(e, t) {
|
|
1651
|
-
for (var n =
|
|
1648
|
+
for (var n = Hr(e), r = -1, i = t.length; ++r < i;) n.add(t[r]);
|
|
1652
1649
|
}
|
|
1653
|
-
function Gr(e) {
|
|
1654
|
-
|
|
1655
|
-
Ur(this, e);
|
|
1656
|
-
};
|
|
1650
|
+
function Gr(e, t) {
|
|
1651
|
+
for (var n = Hr(e), r = -1, i = t.length; ++r < i;) n.remove(t[r]);
|
|
1657
1652
|
}
|
|
1658
1653
|
function Kr(e) {
|
|
1659
1654
|
return function() {
|
|
1660
1655
|
Wr(this, e);
|
|
1661
1656
|
};
|
|
1662
1657
|
}
|
|
1663
|
-
function qr(e
|
|
1658
|
+
function qr(e) {
|
|
1664
1659
|
return function() {
|
|
1665
|
-
(
|
|
1660
|
+
Gr(this, e);
|
|
1666
1661
|
};
|
|
1667
1662
|
}
|
|
1668
1663
|
function Jr(e, t) {
|
|
1669
|
-
|
|
1664
|
+
return function() {
|
|
1665
|
+
(t.apply(this, arguments) ? Wr : Gr)(this, e);
|
|
1666
|
+
};
|
|
1667
|
+
}
|
|
1668
|
+
function Yr(e, t) {
|
|
1669
|
+
var n = Vr(e + "");
|
|
1670
1670
|
if (arguments.length < 2) {
|
|
1671
|
-
for (var r =
|
|
1671
|
+
for (var r = Hr(this.node()), i = -1, a = n.length; ++i < a;) if (!r.contains(n[i])) return !1;
|
|
1672
1672
|
return !0;
|
|
1673
1673
|
}
|
|
1674
|
-
return this.each((typeof t == "function" ?
|
|
1674
|
+
return this.each((typeof t == "function" ? Jr : t ? Kr : qr)(n, t));
|
|
1675
1675
|
}
|
|
1676
|
-
function
|
|
1676
|
+
function Xr() {
|
|
1677
1677
|
this.textContent = "";
|
|
1678
1678
|
}
|
|
1679
|
-
function
|
|
1679
|
+
function Zr(e) {
|
|
1680
1680
|
return function() {
|
|
1681
1681
|
this.textContent = e;
|
|
1682
1682
|
};
|
|
1683
1683
|
}
|
|
1684
|
-
function
|
|
1684
|
+
function Qr(e) {
|
|
1685
1685
|
return function() {
|
|
1686
1686
|
var t = e.apply(this, arguments);
|
|
1687
1687
|
this.textContent = t ?? "";
|
|
1688
1688
|
};
|
|
1689
1689
|
}
|
|
1690
|
-
function
|
|
1691
|
-
return arguments.length ? this.each(e == null ?
|
|
1690
|
+
function $r(e) {
|
|
1691
|
+
return arguments.length ? this.each(e == null ? Xr : (typeof e == "function" ? Qr : Zr)(e)) : this.node().textContent;
|
|
1692
1692
|
}
|
|
1693
|
-
function
|
|
1693
|
+
function ei() {
|
|
1694
1694
|
this.innerHTML = "";
|
|
1695
1695
|
}
|
|
1696
|
-
function
|
|
1696
|
+
function ti(e) {
|
|
1697
1697
|
return function() {
|
|
1698
1698
|
this.innerHTML = e;
|
|
1699
1699
|
};
|
|
1700
1700
|
}
|
|
1701
|
-
function
|
|
1701
|
+
function ni(e) {
|
|
1702
1702
|
return function() {
|
|
1703
1703
|
var t = e.apply(this, arguments);
|
|
1704
1704
|
this.innerHTML = t ?? "";
|
|
1705
1705
|
};
|
|
1706
1706
|
}
|
|
1707
|
-
function
|
|
1708
|
-
return arguments.length ? this.each(e == null ?
|
|
1709
|
-
}
|
|
1710
|
-
function ri() {
|
|
1711
|
-
this.nextSibling && this.parentNode.appendChild(this);
|
|
1707
|
+
function ri(e) {
|
|
1708
|
+
return arguments.length ? this.each(e == null ? ei : (typeof e == "function" ? ni : ti)(e)) : this.node().innerHTML;
|
|
1712
1709
|
}
|
|
1713
1710
|
function ii() {
|
|
1714
|
-
|
|
1711
|
+
this.nextSibling && this.parentNode.appendChild(this);
|
|
1715
1712
|
}
|
|
1716
1713
|
function ai() {
|
|
1717
|
-
|
|
1714
|
+
return this.each(ii);
|
|
1718
1715
|
}
|
|
1719
1716
|
function oi() {
|
|
1720
|
-
|
|
1717
|
+
this.previousSibling && this.parentNode.insertBefore(this, this.parentNode.firstChild);
|
|
1718
|
+
}
|
|
1719
|
+
function si() {
|
|
1720
|
+
return this.each(oi);
|
|
1721
1721
|
}
|
|
1722
|
-
function
|
|
1723
|
-
var t = typeof e == "function" ? e :
|
|
1722
|
+
function ci(e) {
|
|
1723
|
+
var t = typeof e == "function" ? e : Rn(e);
|
|
1724
1724
|
return this.select(function() {
|
|
1725
1725
|
return this.appendChild(t.apply(this, arguments));
|
|
1726
1726
|
});
|
|
1727
1727
|
}
|
|
1728
|
-
function
|
|
1728
|
+
function li() {
|
|
1729
1729
|
return null;
|
|
1730
1730
|
}
|
|
1731
|
-
function
|
|
1732
|
-
var n = typeof e == "function" ? e :
|
|
1731
|
+
function ui(e, t) {
|
|
1732
|
+
var n = typeof e == "function" ? e : Rn(e), r = t == null ? li : typeof t == "function" ? t : Bn(t);
|
|
1733
1733
|
return this.select(function() {
|
|
1734
1734
|
return this.insertBefore(n.apply(this, arguments), r.apply(this, arguments) || null);
|
|
1735
1735
|
});
|
|
1736
1736
|
}
|
|
1737
|
-
function
|
|
1737
|
+
function di() {
|
|
1738
1738
|
var e = this.parentNode;
|
|
1739
1739
|
e && e.removeChild(this);
|
|
1740
1740
|
}
|
|
1741
|
-
function di() {
|
|
1742
|
-
return this.each(ui);
|
|
1743
|
-
}
|
|
1744
1741
|
function fi() {
|
|
1742
|
+
return this.each(di);
|
|
1743
|
+
}
|
|
1744
|
+
function pi() {
|
|
1745
1745
|
var e = this.cloneNode(!1), t = this.parentNode;
|
|
1746
1746
|
return t ? t.insertBefore(e, this.nextSibling) : e;
|
|
1747
1747
|
}
|
|
1748
|
-
function
|
|
1748
|
+
function mi() {
|
|
1749
1749
|
var e = this.cloneNode(!0), t = this.parentNode;
|
|
1750
1750
|
return t ? t.insertBefore(e, this.nextSibling) : e;
|
|
1751
1751
|
}
|
|
1752
|
-
function mi(e) {
|
|
1753
|
-
return this.select(e ? pi : fi);
|
|
1754
|
-
}
|
|
1755
1752
|
function hi(e) {
|
|
1756
|
-
return
|
|
1753
|
+
return this.select(e ? mi : pi);
|
|
1757
1754
|
}
|
|
1758
1755
|
function gi(e) {
|
|
1756
|
+
return arguments.length ? this.property("__data__", e) : this.node().__data__;
|
|
1757
|
+
}
|
|
1758
|
+
function _i(e) {
|
|
1759
1759
|
return function(t) {
|
|
1760
1760
|
e.call(this, t, this.__data__);
|
|
1761
1761
|
};
|
|
1762
1762
|
}
|
|
1763
|
-
function
|
|
1763
|
+
function vi(e) {
|
|
1764
1764
|
return e.trim().split(/^|\s+/).map(function(e) {
|
|
1765
1765
|
var t = "", n = e.indexOf(".");
|
|
1766
1766
|
return n >= 0 && (t = e.slice(n + 1), e = e.slice(0, n)), {
|
|
@@ -1769,7 +1769,7 @@ function _i(e) {
|
|
|
1769
1769
|
};
|
|
1770
1770
|
});
|
|
1771
1771
|
}
|
|
1772
|
-
function
|
|
1772
|
+
function yi(e) {
|
|
1773
1773
|
return function() {
|
|
1774
1774
|
var t = this.__on;
|
|
1775
1775
|
if (t) {
|
|
@@ -1778,9 +1778,9 @@ function vi(e) {
|
|
|
1778
1778
|
}
|
|
1779
1779
|
};
|
|
1780
1780
|
}
|
|
1781
|
-
function
|
|
1781
|
+
function bi(e, t, n) {
|
|
1782
1782
|
return function() {
|
|
1783
|
-
var r = this.__on, i, a =
|
|
1783
|
+
var r = this.__on, i, a = _i(t);
|
|
1784
1784
|
if (r) {
|
|
1785
1785
|
for (var o = 0, s = r.length; o < s; ++o) if ((i = r[o]).type === e.type && i.name === e.name) {
|
|
1786
1786
|
this.removeEventListener(i.type, i.listener, i.options), this.addEventListener(i.type, i.listener = a, i.options = n), i.value = t;
|
|
@@ -1796,8 +1796,8 @@ function yi(e, t, n) {
|
|
|
1796
1796
|
}, r ? r.push(i) : this.__on = [i];
|
|
1797
1797
|
};
|
|
1798
1798
|
}
|
|
1799
|
-
function
|
|
1800
|
-
var r =
|
|
1799
|
+
function xi(e, t, n) {
|
|
1800
|
+
var r = vi(e + ""), i, a = r.length, o;
|
|
1801
1801
|
if (arguments.length < 2) {
|
|
1802
1802
|
var s = this.node().__on;
|
|
1803
1803
|
if (s) {
|
|
@@ -1805,87 +1805,87 @@ function bi(e, t, n) {
|
|
|
1805
1805
|
}
|
|
1806
1806
|
return;
|
|
1807
1807
|
}
|
|
1808
|
-
for (s = t ?
|
|
1808
|
+
for (s = t ? bi : yi, i = 0; i < a; ++i) this.each(s(r[i], t, n));
|
|
1809
1809
|
return this;
|
|
1810
1810
|
}
|
|
1811
|
-
function
|
|
1812
|
-
var r =
|
|
1811
|
+
function Si(e, t, n) {
|
|
1812
|
+
var r = Mr(e), i = r.CustomEvent;
|
|
1813
1813
|
typeof i == "function" ? i = new i(t, n) : (i = r.document.createEvent("Event"), n ? (i.initEvent(t, n.bubbles, n.cancelable), i.detail = n.detail) : i.initEvent(t, !1, !1)), e.dispatchEvent(i);
|
|
1814
1814
|
}
|
|
1815
|
-
function
|
|
1815
|
+
function Ci(e, t) {
|
|
1816
1816
|
return function() {
|
|
1817
|
-
return
|
|
1817
|
+
return Si(this, e, t);
|
|
1818
1818
|
};
|
|
1819
1819
|
}
|
|
1820
|
-
function
|
|
1820
|
+
function wi(e, t) {
|
|
1821
1821
|
return function() {
|
|
1822
|
-
return
|
|
1822
|
+
return Si(this, e, t.apply(this, arguments));
|
|
1823
1823
|
};
|
|
1824
1824
|
}
|
|
1825
|
-
function
|
|
1826
|
-
return this.each((typeof t == "function" ?
|
|
1825
|
+
function Ti(e, t) {
|
|
1826
|
+
return this.each((typeof t == "function" ? wi : Ci)(e, t));
|
|
1827
1827
|
}
|
|
1828
|
-
function*
|
|
1828
|
+
function* Ei() {
|
|
1829
1829
|
for (var e = this._groups, t = 0, n = e.length; t < n; ++t) for (var r = e[t], i = 0, a = r.length, o; i < a; ++i) (o = r[i]) && (yield o);
|
|
1830
1830
|
}
|
|
1831
|
-
var
|
|
1832
|
-
function
|
|
1831
|
+
var Di = [null];
|
|
1832
|
+
function R(e, t) {
|
|
1833
1833
|
this._groups = e, this._parents = t;
|
|
1834
1834
|
}
|
|
1835
|
-
function
|
|
1836
|
-
return new
|
|
1835
|
+
function z() {
|
|
1836
|
+
return new R([[document.documentElement]], Di);
|
|
1837
1837
|
}
|
|
1838
|
-
function
|
|
1838
|
+
function Oi() {
|
|
1839
1839
|
return this;
|
|
1840
1840
|
}
|
|
1841
|
-
|
|
1842
|
-
constructor:
|
|
1843
|
-
select:
|
|
1844
|
-
selectAll:
|
|
1845
|
-
selectChild:
|
|
1846
|
-
selectChildren:
|
|
1847
|
-
filter:
|
|
1848
|
-
data:
|
|
1849
|
-
enter:
|
|
1850
|
-
exit:
|
|
1851
|
-
join:
|
|
1852
|
-
merge:
|
|
1853
|
-
selection:
|
|
1854
|
-
order:
|
|
1855
|
-
sort:
|
|
1856
|
-
call:
|
|
1857
|
-
nodes:
|
|
1858
|
-
node:
|
|
1859
|
-
size:
|
|
1860
|
-
empty:
|
|
1861
|
-
each:
|
|
1862
|
-
attr:
|
|
1863
|
-
style:
|
|
1864
|
-
property:
|
|
1865
|
-
classed:
|
|
1866
|
-
text:
|
|
1867
|
-
html:
|
|
1868
|
-
raise:
|
|
1869
|
-
lower:
|
|
1870
|
-
append:
|
|
1871
|
-
insert:
|
|
1872
|
-
remove:
|
|
1873
|
-
clone:
|
|
1874
|
-
datum:
|
|
1875
|
-
on:
|
|
1876
|
-
dispatch:
|
|
1877
|
-
[Symbol.iterator]:
|
|
1841
|
+
R.prototype = z.prototype = {
|
|
1842
|
+
constructor: R,
|
|
1843
|
+
select: Vn,
|
|
1844
|
+
selectAll: Kn,
|
|
1845
|
+
selectChild: Qn,
|
|
1846
|
+
selectChildren: nr,
|
|
1847
|
+
filter: rr,
|
|
1848
|
+
data: dr,
|
|
1849
|
+
enter: ar,
|
|
1850
|
+
exit: pr,
|
|
1851
|
+
join: mr,
|
|
1852
|
+
merge: hr,
|
|
1853
|
+
selection: Oi,
|
|
1854
|
+
order: gr,
|
|
1855
|
+
sort: _r,
|
|
1856
|
+
call: yr,
|
|
1857
|
+
nodes: br,
|
|
1858
|
+
node: xr,
|
|
1859
|
+
size: Sr,
|
|
1860
|
+
empty: Cr,
|
|
1861
|
+
each: wr,
|
|
1862
|
+
attr: jr,
|
|
1863
|
+
style: Ir,
|
|
1864
|
+
property: Br,
|
|
1865
|
+
classed: Yr,
|
|
1866
|
+
text: $r,
|
|
1867
|
+
html: ri,
|
|
1868
|
+
raise: ai,
|
|
1869
|
+
lower: si,
|
|
1870
|
+
append: ci,
|
|
1871
|
+
insert: ui,
|
|
1872
|
+
remove: fi,
|
|
1873
|
+
clone: hi,
|
|
1874
|
+
datum: gi,
|
|
1875
|
+
on: xi,
|
|
1876
|
+
dispatch: Ti,
|
|
1877
|
+
[Symbol.iterator]: Ei
|
|
1878
1878
|
};
|
|
1879
|
-
function
|
|
1880
|
-
return typeof e == "string" ? new
|
|
1879
|
+
function B(e) {
|
|
1880
|
+
return typeof e == "string" ? new R([[document.querySelector(e)]], [document.documentElement]) : new R([[e]], Di);
|
|
1881
1881
|
}
|
|
1882
|
-
function
|
|
1882
|
+
function ki(e) {
|
|
1883
1883
|
let t;
|
|
1884
1884
|
for (; t = e.sourceEvent;) e = t;
|
|
1885
1885
|
return e;
|
|
1886
1886
|
}
|
|
1887
|
-
function
|
|
1888
|
-
if (e =
|
|
1887
|
+
function V(e, t) {
|
|
1888
|
+
if (e = ki(e), t === void 0 && (t = e.currentTarget), t) {
|
|
1889
1889
|
var n = t.ownerSVGElement || t;
|
|
1890
1890
|
if (n.createSVGPoint) {
|
|
1891
1891
|
var r = n.createSVGPoint();
|
|
@@ -1898,94 +1898,94 @@ function H(e, t) {
|
|
|
1898
1898
|
}
|
|
1899
1899
|
return [e.pageX, e.pageY];
|
|
1900
1900
|
}
|
|
1901
|
-
function
|
|
1902
|
-
return typeof e == "string" ? new
|
|
1901
|
+
function Ai(e) {
|
|
1902
|
+
return typeof e == "string" ? new R([document.querySelectorAll(e)], [document.documentElement]) : new R([Hn(e)], Di);
|
|
1903
1903
|
}
|
|
1904
|
-
var
|
|
1905
|
-
let n = new
|
|
1906
|
-
return (new
|
|
1907
|
-
},
|
|
1904
|
+
var ji = /* @__PURE__ */ e(Se()), H = d[s.KPIChange], U = H.slots, Mi = "#577f56", Ni = "#9e4d53", Pi = (e) => typeof e == "number" && Number.isFinite(e), Fi = (e, t) => {
|
|
1905
|
+
let n = new ji.default(e);
|
|
1906
|
+
return (new ji.default(t).isLight() ? n.lighten(.5).alpha(.5) : n.darken(.5).alpha(.5)).rgb().string();
|
|
1907
|
+
}, Ii = (e, t) => {
|
|
1908
1908
|
if (!e.enabled) return "";
|
|
1909
|
-
let n =
|
|
1909
|
+
let n = Pi(e.value) ? e.value : null, r = n === null ? "" : n < 0 ? "negative" : "positive", i = "", a = "";
|
|
1910
1910
|
if (e.indicator === "inverse") r = r === "negative" ? "positive" : "negative";
|
|
1911
1911
|
else if (e.indicator === "none") r = "";
|
|
1912
1912
|
else if (e.indicator === "custom") {
|
|
1913
1913
|
r = "";
|
|
1914
|
-
let n = e.customIndicator?.color ?
|
|
1915
|
-
i = `color: ${e.customIndicator?.color ?? "inherit"}; background-color: ${n};`, e.customIndicator?.icon && (a = `<span class="footer-icon">${
|
|
1914
|
+
let n = e.customIndicator?.color ? Fi(e.customIndicator.color, t) : "inherit";
|
|
1915
|
+
i = `color: ${e.customIndicator?.color ?? "inherit"}; background-color: ${n};`, e.customIndicator?.icon && (a = `<span class="footer-icon">${D.sanitize(e.customIndicator.icon)}</span>`);
|
|
1916
1916
|
}
|
|
1917
|
-
return `<div class="footer ${r}" style="${i}"><span class="footer-label">${
|
|
1918
|
-
},
|
|
1917
|
+
return `<div class="footer ${r}" style="${i}"><span class="footer-label">${D.sanitize(e.label ?? "-")}</span>${a}</div>`;
|
|
1918
|
+
}, Li = (e, t) => {
|
|
1919
1919
|
if (!e.enabled) return "";
|
|
1920
|
-
let n = e.indicator, r =
|
|
1920
|
+
let n = e.indicator, r = Pi(e.value) ? e.value : null, i = r === null ? "neutral" : r < 0 ? "negative" : "positive", a = "", o = r === null ? "" : r < 0 ? "arrow_downward" : "arrow_upward";
|
|
1921
1921
|
if (n === "inverse") i = i === "negative" ? "positive" : "negative";
|
|
1922
1922
|
else if (n === "none") i = "", o = void 0;
|
|
1923
1923
|
else if (n === "custom") {
|
|
1924
1924
|
i = "";
|
|
1925
|
-
let n = e.customIndicator?.color ?
|
|
1925
|
+
let n = e.customIndicator?.color ? Fi(e.customIndicator.color, t) : "inherit";
|
|
1926
1926
|
a = `color: ${e.customIndicator?.color ?? "inherit"}; background-color: ${n};`, o = e.customIndicator?.icon;
|
|
1927
1927
|
}
|
|
1928
|
-
let s = o ? `<span class="pill-icon">${
|
|
1929
|
-
return `<div class="pill ${i}" style="${a}"><span class="pill-label">${
|
|
1930
|
-
},
|
|
1928
|
+
let s = o ? `<span class="pill-icon">${D.sanitize(o)}</span>` : "";
|
|
1929
|
+
return `<div class="pill ${i}" style="${a}"><span class="pill-label">${D.sanitize(e.label ?? "-")}</span>${s}</div>`;
|
|
1930
|
+
}, Ri = (e, t) => {
|
|
1931
1931
|
let n = e.value ?? {
|
|
1932
1932
|
label: "-",
|
|
1933
1933
|
value: null,
|
|
1934
1934
|
enabled: !1
|
|
1935
1935
|
}, r = "", i = "";
|
|
1936
|
-
return e.indicator === "custom" && (e.customIndicator?.color && (r = `color: ${e.customIndicator.color};`), e.customIndicator?.icon && (i = `<span class="value-icon">${
|
|
1937
|
-
},
|
|
1938
|
-
let
|
|
1936
|
+
return e.indicator === "custom" && (e.customIndicator?.color && (r = `color: ${e.customIndicator.color};`), e.customIndicator?.icon && (i = `<span class="value-icon">${D.sanitize(e.customIndicator.icon)}</span>`)), `<div class="value ${t ? "value-space" : ""}" style="${r}"><span class="value-label">${D.sanitize(n.label)}</span>${i}</div>`;
|
|
1937
|
+
}, zi = (e, t) => {
|
|
1938
|
+
let n = e.data.diff ?? c.diff.defaults, r = e.data.change ?? c.change.defaults, i = t.config.nodeDefaultBackground ?? "#ffffff", a = Ri(e.data, !r.enabled), o = Ii(n, i), s = Li(r, i), l = [];
|
|
1939
1939
|
return e.data._upToTheRootHighlighted && l.push("node-highlight"), `
|
|
1940
1940
|
<div class="node-content layout-a ${l.join(" ")}">
|
|
1941
|
-
<div class="label">${
|
|
1941
|
+
<div class="label">${D.sanitize(e.data.label)}</div>
|
|
1942
1942
|
<div class="flex-row">
|
|
1943
|
-
${
|
|
1944
|
-
${
|
|
1943
|
+
${a}
|
|
1944
|
+
${s}
|
|
1945
1945
|
</div>
|
|
1946
|
-
${
|
|
1946
|
+
${o}
|
|
1947
1947
|
|
|
1948
1948
|
</div>
|
|
1949
1949
|
`;
|
|
1950
|
-
},
|
|
1950
|
+
}, Bi = ({ node: e, config: t }) => e.data?.id === "__root__" ? null : `<div class="button-content"> ${{
|
|
1951
1951
|
left: (e) => e ? "◀" : "▶",
|
|
1952
1952
|
bottom: (e) => e ? "▼" : "▲",
|
|
1953
1953
|
right: (e) => e ? "▶" : "◀",
|
|
1954
1954
|
top: (e) => e ? "▲" : "▼"
|
|
1955
1955
|
}[t.layout](e.children)} </div>`;
|
|
1956
|
-
function
|
|
1956
|
+
function Vi(e) {
|
|
1957
1957
|
if (e.data._upToTheRootHighlighted) {
|
|
1958
|
-
|
|
1958
|
+
B(this).style("stroke-width", "var(--border-hover-width)").style("stroke", "var(--border-hover-color)");
|
|
1959
1959
|
return;
|
|
1960
1960
|
}
|
|
1961
1961
|
if (!e.data.diff?.enabled) {
|
|
1962
|
-
|
|
1962
|
+
B(this).style("stroke-width", null).style("stroke", null);
|
|
1963
1963
|
return;
|
|
1964
1964
|
}
|
|
1965
|
-
let
|
|
1966
|
-
|
|
1967
|
-
let l =
|
|
1968
|
-
|
|
1965
|
+
let t = (Pi(e.data.diff?.value) ? e.data.diff.value : null) ?? (Pi(c.diff.defaults.value) ? c.diff.defaults.value : 0), n = e.parent?.children?.flatMap((t) => t.id === e.id || !t.data.diff?.enabled || !Pi(t.data.diff?.value) ? [] : [Math.abs(t.data.diff.value)]) ?? [], r = n.length ? Math.max(...n) : 0, i = Math.abs(t) > r, a = t < 0, o = a ? Ni : Mi, s = e.data.diff?.indicator;
|
|
1966
|
+
s === "inverse" ? o = a ? Mi : Ni : s === "none" ? o = "var(--link-color)" : s === "custom" && (o = e.data.diff?.customIndicator?.color ?? "var(--link-color)");
|
|
1967
|
+
let l = i ? 2 : 1;
|
|
1968
|
+
B(this).style("stroke", o).style("stroke-width", l);
|
|
1969
1969
|
}
|
|
1970
|
-
var
|
|
1970
|
+
var Hi = (e, t) => {
|
|
1971
1971
|
let n = {
|
|
1972
|
-
...
|
|
1972
|
+
...H.labelStyle,
|
|
1973
1973
|
...t.treeChartSettings.nodeLayout?.labelStyle,
|
|
1974
|
-
fontSize: t.treeChartSettings.nodeLayout?.labelStyle?.fontSize ??
|
|
1974
|
+
fontSize: t.treeChartSettings.nodeLayout?.labelStyle?.fontSize ?? H.labelStyle?.fontSize
|
|
1975
1975
|
}, r = {
|
|
1976
|
-
...
|
|
1976
|
+
...H.valueStyle,
|
|
1977
1977
|
...t.treeChartSettings.nodeLayout?.valueStyle,
|
|
1978
|
-
fontSize: t.treeChartSettings.nodeLayout?.valueStyle?.fontSize ??
|
|
1978
|
+
fontSize: t.treeChartSettings.nodeLayout?.valueStyle?.fontSize ?? H.valueStyle?.fontSize
|
|
1979
1979
|
}, i = {
|
|
1980
|
-
...
|
|
1981
|
-
...
|
|
1980
|
+
...U.change?.styling,
|
|
1981
|
+
...U.change?.styling?.fontStyle,
|
|
1982
1982
|
...t.treeChartSettings.nodeLayout?.slots?.change,
|
|
1983
|
-
fontSize: t.treeChartSettings.nodeLayout?.slots?.change?.fontSize ??
|
|
1983
|
+
fontSize: t.treeChartSettings.nodeLayout?.slots?.change?.fontSize ?? U.change?.styling?.fontSize
|
|
1984
1984
|
}, a = {
|
|
1985
|
-
...
|
|
1986
|
-
...
|
|
1985
|
+
...U.diff?.styling,
|
|
1986
|
+
...U.diff?.styling?.fontStyle,
|
|
1987
1987
|
...t.treeChartSettings.nodeLayout?.slots?.diff,
|
|
1988
|
-
fontSize: t.treeChartSettings.nodeLayout?.slots?.diff?.fontSize ??
|
|
1988
|
+
fontSize: t.treeChartSettings.nodeLayout?.slots?.diff?.fontSize ?? U.diff?.styling?.fontSize
|
|
1989
1989
|
};
|
|
1990
1990
|
return `
|
|
1991
1991
|
#${e} {
|
|
@@ -2113,68 +2113,68 @@ var Vi = (e, t) => {
|
|
|
2113
2113
|
}
|
|
2114
2114
|
|
|
2115
2115
|
.positive {
|
|
2116
|
-
color: ${
|
|
2116
|
+
color: ${Mi};
|
|
2117
2117
|
background-color: #e4fae8;
|
|
2118
2118
|
}
|
|
2119
2119
|
|
|
2120
2120
|
.negative {
|
|
2121
|
-
color: ${
|
|
2121
|
+
color: ${Ni};
|
|
2122
2122
|
background-color: #fcecec;
|
|
2123
2123
|
}
|
|
2124
2124
|
}
|
|
2125
2125
|
}`;
|
|
2126
|
-
},
|
|
2126
|
+
}, Ui = {
|
|
2127
2127
|
name: "KPI Change",
|
|
2128
|
-
...
|
|
2129
|
-
getNodeContent:
|
|
2130
|
-
getButtonContent:
|
|
2131
|
-
linkUpdate:
|
|
2132
|
-
getCSS:
|
|
2128
|
+
...H,
|
|
2129
|
+
getNodeContent: zi,
|
|
2130
|
+
getButtonContent: Bi,
|
|
2131
|
+
linkUpdate: Vi,
|
|
2132
|
+
getCSS: Hi,
|
|
2133
2133
|
width: 180,
|
|
2134
2134
|
sizes: (e) => {
|
|
2135
2135
|
let t = {
|
|
2136
|
-
...
|
|
2137
|
-
...
|
|
2136
|
+
...U.diff?.styling,
|
|
2137
|
+
...U.diff?.styling?.fontStyle,
|
|
2138
2138
|
...e.treeChartSettings.nodeLayout?.slots?.diff,
|
|
2139
|
-
fontSize: e.treeChartSettings.nodeLayout?.slots?.diff?.fontSize ??
|
|
2139
|
+
fontSize: e.treeChartSettings.nodeLayout?.slots?.diff?.fontSize ?? U.diff?.styling?.fontSize
|
|
2140
2140
|
}, n = {
|
|
2141
|
-
...
|
|
2141
|
+
...H.labelStyle,
|
|
2142
2142
|
...e.treeChartSettings.nodeLayout?.labelStyle,
|
|
2143
|
-
fontSize: e.treeChartSettings.nodeLayout?.labelStyle?.fontSize ??
|
|
2143
|
+
fontSize: e.treeChartSettings.nodeLayout?.labelStyle?.fontSize ?? H.labelStyle?.fontSize
|
|
2144
2144
|
}, r = {
|
|
2145
|
-
...
|
|
2145
|
+
...H.valueStyle,
|
|
2146
2146
|
...e.treeChartSettings.nodeLayout?.valueStyle,
|
|
2147
|
-
fontSize: e.treeChartSettings.nodeLayout?.valueStyle?.fontSize ??
|
|
2147
|
+
fontSize: e.treeChartSettings.nodeLayout?.valueStyle?.fontSize ?? H.valueStyle?.fontSize
|
|
2148
2148
|
};
|
|
2149
2149
|
return {
|
|
2150
|
-
label: Math.ceil(
|
|
2151
|
-
value: Math.ceil(
|
|
2152
|
-
diff: Math.ceil(
|
|
2150
|
+
label: Math.ceil(k(n.fontSize)) + 8,
|
|
2151
|
+
value: Math.ceil(k(r.fontSize)) + 8,
|
|
2152
|
+
diff: Math.ceil(k(t.fontSize)) + 16
|
|
2153
2153
|
};
|
|
2154
2154
|
},
|
|
2155
|
-
height: (e,
|
|
2156
|
-
let
|
|
2157
|
-
return
|
|
2155
|
+
height: (e, t) => {
|
|
2156
|
+
let n = 20;
|
|
2157
|
+
return n += t?.label ?? 0, n += t?.value ?? 0, (e.data.diff ?? c.diff.defaults)?.enabled && (n += t?.diff ?? 0), n;
|
|
2158
2158
|
}
|
|
2159
|
-
},
|
|
2159
|
+
}, W = d[s.Basic], Wi = (e) => {
|
|
2160
2160
|
if (e.id === "__root__") return null;
|
|
2161
2161
|
let t = "", n = "";
|
|
2162
|
-
e.data.indicator === "custom" && (e.data.customIndicator?.color && (t = `color: ${e.data.customIndicator.color};`), e.data.customIndicator?.icon && (n = `<span class="value-icon">${
|
|
2163
|
-
let r = e.data.value ? `<div class="value" style="${t}"><span class="value-label">${
|
|
2162
|
+
e.data.indicator === "custom" && (e.data.customIndicator?.color && (t = `color: ${e.data.customIndicator.color};`), e.data.customIndicator?.icon && (n = `<span class="value-icon">${D.sanitize(e.data.customIndicator.icon)}</span>`));
|
|
2163
|
+
let r = e.data.value ? `<div class="value" style="${t}"><span class="value-label">${D.sanitize(e.data.value.label)}</span>${n}</div>` : "", i = [];
|
|
2164
2164
|
return e.data._upToTheRootHighlighted && i.push("node-highlight"), `
|
|
2165
2165
|
<div class="node-content layout-b ${i.join(" ")}">
|
|
2166
|
-
<div class="label">${
|
|
2166
|
+
<div class="label">${D.sanitize(e.data.label)}</div>
|
|
2167
2167
|
${r}
|
|
2168
2168
|
</div>`;
|
|
2169
|
-
},
|
|
2169
|
+
}, Gi = (e, t) => {
|
|
2170
2170
|
let n = {
|
|
2171
|
-
...
|
|
2171
|
+
...W.labelStyle,
|
|
2172
2172
|
...t.treeChartSettings.nodeLayout?.labelStyle,
|
|
2173
|
-
fontSize: t.treeChartSettings.nodeLayout?.labelStyle?.fontSize ??
|
|
2173
|
+
fontSize: t.treeChartSettings.nodeLayout?.labelStyle?.fontSize ?? W.labelStyle?.fontSize
|
|
2174
2174
|
}, r = {
|
|
2175
|
-
...
|
|
2175
|
+
...W.valueStyle,
|
|
2176
2176
|
...t.treeChartSettings.nodeLayout?.valueStyle,
|
|
2177
|
-
fontSize: t.treeChartSettings.nodeLayout?.valueStyle?.fontSize ??
|
|
2177
|
+
fontSize: t.treeChartSettings.nodeLayout?.valueStyle?.fontSize ?? W.valueStyle?.fontSize
|
|
2178
2178
|
};
|
|
2179
2179
|
return `
|
|
2180
2180
|
#${e} {
|
|
@@ -2218,56 +2218,56 @@ var Vi = (e, t) => {
|
|
|
2218
2218
|
}
|
|
2219
2219
|
}
|
|
2220
2220
|
}`;
|
|
2221
|
-
},
|
|
2221
|
+
}, Ki = {
|
|
2222
2222
|
name: "Basic",
|
|
2223
|
-
...
|
|
2224
|
-
getNodeContent:
|
|
2225
|
-
getCSS:
|
|
2223
|
+
...W,
|
|
2224
|
+
getNodeContent: Wi,
|
|
2225
|
+
getCSS: Gi,
|
|
2226
2226
|
width: 140,
|
|
2227
2227
|
sizes: (e) => {
|
|
2228
2228
|
let t = {
|
|
2229
|
-
...
|
|
2229
|
+
...W.labelStyle,
|
|
2230
2230
|
...e.treeChartSettings.nodeLayout?.labelStyle,
|
|
2231
|
-
fontSize: e.treeChartSettings.nodeLayout?.labelStyle?.fontSize ??
|
|
2231
|
+
fontSize: e.treeChartSettings.nodeLayout?.labelStyle?.fontSize ?? W.labelStyle?.fontSize
|
|
2232
2232
|
}, n = {
|
|
2233
|
-
...
|
|
2233
|
+
...W.valueStyle,
|
|
2234
2234
|
...e.treeChartSettings.nodeLayout?.valueStyle,
|
|
2235
|
-
fontSize: e.treeChartSettings.nodeLayout?.valueStyle?.fontSize ??
|
|
2235
|
+
fontSize: e.treeChartSettings.nodeLayout?.valueStyle?.fontSize ?? W.valueStyle?.fontSize
|
|
2236
2236
|
};
|
|
2237
2237
|
return {
|
|
2238
|
-
label:
|
|
2239
|
-
value:
|
|
2238
|
+
label: k(t.fontSize) + 8,
|
|
2239
|
+
value: k(n.fontSize) + 8
|
|
2240
2240
|
};
|
|
2241
2241
|
},
|
|
2242
2242
|
height: (e, t) => {
|
|
2243
2243
|
let n = 8 + (t?.label ?? 0);
|
|
2244
2244
|
return e.data.value && (n += 8 + (t?.value ?? 0)), n;
|
|
2245
2245
|
}
|
|
2246
|
-
},
|
|
2247
|
-
[
|
|
2248
|
-
[
|
|
2249
|
-
},
|
|
2246
|
+
}, qi = {
|
|
2247
|
+
[s.KPIChange]: Ui,
|
|
2248
|
+
[s.Basic]: Ki
|
|
2249
|
+
}, Ji = { passive: !1 }, Yi = {
|
|
2250
2250
|
capture: !0,
|
|
2251
2251
|
passive: !1
|
|
2252
2252
|
};
|
|
2253
|
-
function
|
|
2253
|
+
function Xi(e) {
|
|
2254
2254
|
e.stopImmediatePropagation();
|
|
2255
2255
|
}
|
|
2256
|
-
function
|
|
2256
|
+
function G(e) {
|
|
2257
2257
|
e.preventDefault(), e.stopImmediatePropagation();
|
|
2258
2258
|
}
|
|
2259
|
-
function
|
|
2260
|
-
var t = e.document.documentElement, n =
|
|
2261
|
-
"onselectstart" in t ? n.on("selectstart.drag",
|
|
2259
|
+
function Zi(e) {
|
|
2260
|
+
var t = e.document.documentElement, n = B(e).on("dragstart.drag", G, Yi);
|
|
2261
|
+
"onselectstart" in t ? n.on("selectstart.drag", G, Yi) : (t.__noselect = t.style.MozUserSelect, t.style.MozUserSelect = "none");
|
|
2262
2262
|
}
|
|
2263
|
-
function
|
|
2264
|
-
var n = e.document.documentElement, r =
|
|
2265
|
-
t && (r.on("click.drag",
|
|
2263
|
+
function Qi(e, t) {
|
|
2264
|
+
var n = e.document.documentElement, r = B(e).on("dragstart.drag", null);
|
|
2265
|
+
t && (r.on("click.drag", G, Yi), setTimeout(function() {
|
|
2266
2266
|
r.on("click.drag", null);
|
|
2267
2267
|
}, 0)), "onselectstart" in n ? r.on("selectstart.drag", null) : (n.style.MozUserSelect = n.__noselect, delete n.__noselect);
|
|
2268
2268
|
}
|
|
2269
|
-
var
|
|
2270
|
-
function
|
|
2269
|
+
var $i = (e) => () => e;
|
|
2270
|
+
function ea(e, { sourceEvent: t, subject: n, target: r, identifier: i, active: a, x: o, y: s, dx: c, dy: l, dispatch: u }) {
|
|
2271
2271
|
Object.defineProperties(this, {
|
|
2272
2272
|
type: {
|
|
2273
2273
|
value: e,
|
|
@@ -2322,65 +2322,65 @@ function $i(e, { sourceEvent: t, subject: n, target: r, identifier: i, active: a
|
|
|
2322
2322
|
_: { value: u }
|
|
2323
2323
|
});
|
|
2324
2324
|
}
|
|
2325
|
-
|
|
2325
|
+
ea.prototype.on = function() {
|
|
2326
2326
|
var e = this._.on.apply(this._, arguments);
|
|
2327
2327
|
return e === this._ ? this : e;
|
|
2328
|
-
},
|
|
2329
|
-
function
|
|
2328
|
+
}, nt();
|
|
2329
|
+
function ta(e) {
|
|
2330
2330
|
return !e.ctrlKey && !e.button;
|
|
2331
2331
|
}
|
|
2332
|
-
function
|
|
2332
|
+
function na() {
|
|
2333
2333
|
return this.parentNode;
|
|
2334
2334
|
}
|
|
2335
|
-
function
|
|
2335
|
+
function ra(e, t) {
|
|
2336
2336
|
return t ?? {
|
|
2337
2337
|
x: e.x,
|
|
2338
2338
|
y: e.y
|
|
2339
2339
|
};
|
|
2340
2340
|
}
|
|
2341
|
-
function
|
|
2341
|
+
function ia() {
|
|
2342
2342
|
return navigator.maxTouchPoints || "ontouchstart" in this;
|
|
2343
2343
|
}
|
|
2344
|
-
function
|
|
2345
|
-
var e =
|
|
2344
|
+
function aa() {
|
|
2345
|
+
var e = ta, t = na, n = ra, r = ia, i = {}, a = tt("start", "drag", "end"), o = 0, s, c, l, u, d = 0;
|
|
2346
2346
|
function f(e) {
|
|
2347
|
-
e.on("mousedown.drag", p).filter(r).on("touchstart.drag", g).on("touchmove.drag", _,
|
|
2347
|
+
e.on("mousedown.drag", p).filter(r).on("touchstart.drag", g).on("touchmove.drag", _, Ji).on("touchend.drag touchcancel.drag", v).style("touch-action", "none").style("-webkit-tap-highlight-color", "rgba(0,0,0,0)");
|
|
2348
2348
|
}
|
|
2349
2349
|
function p(n, r) {
|
|
2350
2350
|
if (!(u || !e.call(this, n, r))) {
|
|
2351
2351
|
var i = y(this, t.call(this, n, r), n, r, "mouse");
|
|
2352
|
-
i && (
|
|
2352
|
+
i && (B(n.view).on("mousemove.drag", m, Yi).on("mouseup.drag", h, Yi), Zi(n.view), Xi(n), l = !1, s = n.clientX, c = n.clientY, i("start", n));
|
|
2353
2353
|
}
|
|
2354
2354
|
}
|
|
2355
2355
|
function m(e) {
|
|
2356
|
-
if (
|
|
2356
|
+
if (G(e), !l) {
|
|
2357
2357
|
var t = e.clientX - s, n = e.clientY - c;
|
|
2358
2358
|
l = t * t + n * n > d;
|
|
2359
2359
|
}
|
|
2360
2360
|
i.mouse("drag", e);
|
|
2361
2361
|
}
|
|
2362
2362
|
function h(e) {
|
|
2363
|
-
|
|
2363
|
+
B(e.view).on("mousemove.drag mouseup.drag", null), Qi(e.view, l), G(e), i.mouse("end", e);
|
|
2364
2364
|
}
|
|
2365
2365
|
function g(n, r) {
|
|
2366
2366
|
if (e.call(this, n, r)) {
|
|
2367
2367
|
var i = n.changedTouches, a = t.call(this, n, r), o = i.length, s, c;
|
|
2368
|
-
for (s = 0; s < o; ++s) (c = y(this, a, n, r, i[s].identifier, i[s])) && (
|
|
2368
|
+
for (s = 0; s < o; ++s) (c = y(this, a, n, r, i[s].identifier, i[s])) && (Xi(n), c("start", n, i[s]));
|
|
2369
2369
|
}
|
|
2370
2370
|
}
|
|
2371
2371
|
function _(e) {
|
|
2372
2372
|
var t = e.changedTouches, n = t.length, r, a;
|
|
2373
|
-
for (r = 0; r < n; ++r) (a = i[t[r].identifier]) && (
|
|
2373
|
+
for (r = 0; r < n; ++r) (a = i[t[r].identifier]) && (G(e), a("drag", e, t[r]));
|
|
2374
2374
|
}
|
|
2375
2375
|
function v(e) {
|
|
2376
2376
|
var t = e.changedTouches, n = t.length, r, a;
|
|
2377
2377
|
for (u && clearTimeout(u), u = setTimeout(function() {
|
|
2378
2378
|
u = null;
|
|
2379
|
-
}, 500), r = 0; r < n; ++r) (a = i[t[r].identifier]) && (
|
|
2379
|
+
}, 500), r = 0; r < n; ++r) (a = i[t[r].identifier]) && (Xi(e), a("end", e, t[r]));
|
|
2380
2380
|
}
|
|
2381
2381
|
function y(e, t, r, s, c, l) {
|
|
2382
|
-
var u = a.copy(), d =
|
|
2383
|
-
if ((h = n.call(e, new
|
|
2382
|
+
var u = a.copy(), d = V(l || r, t), p, m, h;
|
|
2383
|
+
if ((h = n.call(e, new ea("beforestart", {
|
|
2384
2384
|
sourceEvent: r,
|
|
2385
2385
|
target: f,
|
|
2386
2386
|
identifier: c,
|
|
@@ -2398,10 +2398,10 @@ function ia() {
|
|
|
2398
2398
|
break;
|
|
2399
2399
|
case "end": delete i[c], --o;
|
|
2400
2400
|
case "drag":
|
|
2401
|
-
d =
|
|
2401
|
+
d = V(l || a, t), _ = o;
|
|
2402
2402
|
break;
|
|
2403
2403
|
}
|
|
2404
|
-
u.call(r, e, new
|
|
2404
|
+
u.call(r, e, new ea(r, {
|
|
2405
2405
|
sourceEvent: a,
|
|
2406
2406
|
subject: h,
|
|
2407
2407
|
target: f,
|
|
@@ -2416,13 +2416,13 @@ function ia() {
|
|
|
2416
2416
|
};
|
|
2417
2417
|
}
|
|
2418
2418
|
return f.filter = function(t) {
|
|
2419
|
-
return arguments.length ? (e = typeof t == "function" ? t :
|
|
2419
|
+
return arguments.length ? (e = typeof t == "function" ? t : $i(!!t), f) : e;
|
|
2420
2420
|
}, f.container = function(e) {
|
|
2421
|
-
return arguments.length ? (t = typeof e == "function" ? e :
|
|
2421
|
+
return arguments.length ? (t = typeof e == "function" ? e : $i(e), f) : t;
|
|
2422
2422
|
}, f.subject = function(e) {
|
|
2423
|
-
return arguments.length ? (n = typeof e == "function" ? e :
|
|
2423
|
+
return arguments.length ? (n = typeof e == "function" ? e : $i(e), f) : n;
|
|
2424
2424
|
}, f.touchable = function(e) {
|
|
2425
|
-
return arguments.length ? (r = typeof e == "function" ? e :
|
|
2425
|
+
return arguments.length ? (r = typeof e == "function" ? e : $i(!!e), f) : r;
|
|
2426
2426
|
}, f.on = function() {
|
|
2427
2427
|
var e = a.on.apply(a, arguments);
|
|
2428
2428
|
return e === a ? f : e;
|
|
@@ -2430,14 +2430,14 @@ function ia() {
|
|
|
2430
2430
|
return arguments.length ? (d = (e = +e) * e, f) : Math.sqrt(d);
|
|
2431
2431
|
}, f;
|
|
2432
2432
|
}
|
|
2433
|
-
var
|
|
2433
|
+
var K = 0, oa = 0, sa = 0, ca = 1e3, la, ua, da = 0, q = 0, fa = 0, pa = typeof performance == "object" && performance.now ? performance : Date, ma = typeof window == "object" && window.requestAnimationFrame ? window.requestAnimationFrame.bind(window) : function(e) {
|
|
2434
2434
|
setTimeout(e, 17);
|
|
2435
2435
|
};
|
|
2436
2436
|
function ha() {
|
|
2437
|
-
return
|
|
2437
|
+
return q ||= (ma(ga), pa.now() + fa);
|
|
2438
2438
|
}
|
|
2439
2439
|
function ga() {
|
|
2440
|
-
|
|
2440
|
+
q = 0;
|
|
2441
2441
|
}
|
|
2442
2442
|
function _a() {
|
|
2443
2443
|
this._call = this._time = this._next = null;
|
|
@@ -2446,7 +2446,7 @@ _a.prototype = va.prototype = {
|
|
|
2446
2446
|
constructor: _a,
|
|
2447
2447
|
restart: function(e, t, n) {
|
|
2448
2448
|
if (typeof e != "function") throw TypeError("callback is not a function");
|
|
2449
|
-
n = (n == null ? ha() : +n) + (t == null ? 0 : +t), !this._next &&
|
|
2449
|
+
n = (n == null ? ha() : +n) + (t == null ? 0 : +t), !this._next && ua !== this && (ua ? ua._next = this : la = this, ua = this), this._call = e, this._time = n, Ca();
|
|
2450
2450
|
},
|
|
2451
2451
|
stop: function() {
|
|
2452
2452
|
this._call && (this._call = null, this._time = Infinity, Ca());
|
|
@@ -2457,28 +2457,28 @@ function va(e, t, n) {
|
|
|
2457
2457
|
return r.restart(e, t, n), r;
|
|
2458
2458
|
}
|
|
2459
2459
|
function ya() {
|
|
2460
|
-
ha(), ++
|
|
2461
|
-
for (var e =
|
|
2462
|
-
--
|
|
2460
|
+
ha(), ++K;
|
|
2461
|
+
for (var e = la, t; e;) (t = q - e._time) >= 0 && e._call.call(void 0, t), e = e._next;
|
|
2462
|
+
--K;
|
|
2463
2463
|
}
|
|
2464
2464
|
function ba() {
|
|
2465
|
-
|
|
2465
|
+
q = (da = pa.now()) + fa, K = oa = 0;
|
|
2466
2466
|
try {
|
|
2467
2467
|
ya();
|
|
2468
2468
|
} finally {
|
|
2469
|
-
|
|
2469
|
+
K = 0, Sa(), q = 0;
|
|
2470
2470
|
}
|
|
2471
2471
|
}
|
|
2472
2472
|
function xa() {
|
|
2473
|
-
var e = pa.now(), t = e -
|
|
2474
|
-
t >
|
|
2473
|
+
var e = pa.now(), t = e - da;
|
|
2474
|
+
t > ca && (fa -= t, da = e);
|
|
2475
2475
|
}
|
|
2476
2476
|
function Sa() {
|
|
2477
|
-
for (var e, t =
|
|
2478
|
-
|
|
2477
|
+
for (var e, t = la, n, r = Infinity; t;) t._call ? (r > t._time && (r = t._time), e = t, t = t._next) : (n = t._next, t._next = null, t = e ? e._next = n : la = n);
|
|
2478
|
+
ua = e, Ca(r);
|
|
2479
2479
|
}
|
|
2480
2480
|
function Ca(e) {
|
|
2481
|
-
|
|
2481
|
+
K || (oa &&= clearTimeout(oa), e - q > 24 ? (e < Infinity && (oa = setTimeout(ba, e - pa.now() - fa)), sa &&= clearInterval(sa)) : (sa ||= (da = pa.now(), setInterval(xa, ca)), K = 1, ma(ba)));
|
|
2482
2482
|
}
|
|
2483
2483
|
function wa(e, t, n) {
|
|
2484
2484
|
var r = new _a();
|
|
@@ -2486,8 +2486,8 @@ function wa(e, t, n) {
|
|
|
2486
2486
|
r.stop(), e(n + t);
|
|
2487
2487
|
}, t, n), r;
|
|
2488
2488
|
}
|
|
2489
|
-
|
|
2490
|
-
var Ta =
|
|
2489
|
+
Ne(), _e(), nt();
|
|
2490
|
+
var Ta = tt("start", "end", "cancel", "interrupt"), Ea = [];
|
|
2491
2491
|
function Da(e, t, n, r, i, a) {
|
|
2492
2492
|
var o = e.__transition;
|
|
2493
2493
|
if (!o) e.__transition = {};
|
|
@@ -2620,9 +2620,9 @@ function Fa(e, t, n) {
|
|
|
2620
2620
|
}
|
|
2621
2621
|
function Ia(e, t) {
|
|
2622
2622
|
var n;
|
|
2623
|
-
return (typeof t == "number" ?
|
|
2623
|
+
return (typeof t == "number" ? ve : t instanceof Me ? O : (n = Me(t)) ? (t = n, O) : de)(e, t);
|
|
2624
2624
|
}
|
|
2625
|
-
|
|
2625
|
+
_e();
|
|
2626
2626
|
function La(e) {
|
|
2627
2627
|
return function() {
|
|
2628
2628
|
this.removeAttribute(e);
|
|
@@ -2662,7 +2662,7 @@ function Ha(e, t, n) {
|
|
|
2662
2662
|
};
|
|
2663
2663
|
}
|
|
2664
2664
|
function Ua(e, t) {
|
|
2665
|
-
var n =
|
|
2665
|
+
var n = Fn(e), r = n === "transform" ? he : Ia;
|
|
2666
2666
|
return this.attrTween(e, typeof t == "function" ? (n.local ? Ha : Va)(n, r, Fa(this, "attr." + e, t)) : t == null ? (n.local ? Ra : La)(n) : (n.local ? Ba : za)(n, r, t));
|
|
2667
2667
|
}
|
|
2668
2668
|
function Wa(e, t) {
|
|
@@ -2696,7 +2696,7 @@ function Ja(e, t) {
|
|
|
2696
2696
|
if (arguments.length < 2) return (n = this.tween(n)) && n._value;
|
|
2697
2697
|
if (t == null) return this.tween(n, null);
|
|
2698
2698
|
if (typeof t != "function") throw Error();
|
|
2699
|
-
var r =
|
|
2699
|
+
var r = Fn(e);
|
|
2700
2700
|
return this.tween(n, (r.local ? Ka : qa)(r, t));
|
|
2701
2701
|
}
|
|
2702
2702
|
function Ya(e, t) {
|
|
@@ -2749,7 +2749,7 @@ function io(e) {
|
|
|
2749
2749
|
return this.each(ro(this._id, e));
|
|
2750
2750
|
}
|
|
2751
2751
|
function ao(e) {
|
|
2752
|
-
typeof e != "function" && (e =
|
|
2752
|
+
typeof e != "function" && (e = qn(e));
|
|
2753
2753
|
for (var t = this._groups, n = t.length, r = Array(n), i = 0; i < n; ++i) for (var a = t[i], o = a.length, s = r[i] = [], c, l = 0; l < o; ++l) (c = a[l]) && e.call(c, c.__data__, l, a) && s.push(c);
|
|
2754
2754
|
return new X(r, this._parents, this._name, this._id);
|
|
2755
2755
|
}
|
|
@@ -2788,28 +2788,28 @@ function fo() {
|
|
|
2788
2788
|
}
|
|
2789
2789
|
function po(e) {
|
|
2790
2790
|
var t = this._name, n = this._id;
|
|
2791
|
-
typeof e != "function" && (e =
|
|
2791
|
+
typeof e != "function" && (e = Bn(e));
|
|
2792
2792
|
for (var r = this._groups, i = r.length, a = Array(i), o = 0; o < i; ++o) for (var s = r[o], c = s.length, l = a[o] = Array(c), u, d, f = 0; f < c; ++f) (u = s[f]) && (d = e.call(u, u.__data__, f, s)) && ("__data__" in u && (d.__data__ = u.__data__), l[f] = d, Da(l[f], t, n, f, l, Y(u, n)));
|
|
2793
2793
|
return new X(a, this._parents, t, n);
|
|
2794
2794
|
}
|
|
2795
2795
|
function mo(e) {
|
|
2796
2796
|
var t = this._name, n = this._id;
|
|
2797
|
-
typeof e != "function" && (e =
|
|
2797
|
+
typeof e != "function" && (e = Wn(e));
|
|
2798
2798
|
for (var r = this._groups, i = r.length, a = [], o = [], s = 0; s < i; ++s) for (var c = r[s], l = c.length, u, d = 0; d < l; ++d) if (u = c[d]) {
|
|
2799
2799
|
for (var f = e.call(u, u.__data__, d, c), p, m = Y(u, n), h = 0, g = f.length; h < g; ++h) (p = f[h]) && Da(p, t, n, h, f, m);
|
|
2800
2800
|
a.push(f), o.push(u);
|
|
2801
2801
|
}
|
|
2802
2802
|
return new X(a, o, t, n);
|
|
2803
2803
|
}
|
|
2804
|
-
var ho =
|
|
2804
|
+
var ho = z.prototype.constructor;
|
|
2805
2805
|
function go() {
|
|
2806
2806
|
return new ho(this._groups, this._parents);
|
|
2807
2807
|
}
|
|
2808
|
-
|
|
2808
|
+
_e();
|
|
2809
2809
|
function _o(e, t) {
|
|
2810
2810
|
var n, r, i;
|
|
2811
2811
|
return function() {
|
|
2812
|
-
var a =
|
|
2812
|
+
var a = L(this, e), o = (this.style.removeProperty(e), L(this, e));
|
|
2813
2813
|
return a === o ? null : a === n && o === r ? i : i = t(n = a, r = o);
|
|
2814
2814
|
};
|
|
2815
2815
|
}
|
|
@@ -2821,15 +2821,15 @@ function vo(e) {
|
|
|
2821
2821
|
function yo(e, t, n) {
|
|
2822
2822
|
var r, i = n + "", a;
|
|
2823
2823
|
return function() {
|
|
2824
|
-
var o =
|
|
2824
|
+
var o = L(this, e);
|
|
2825
2825
|
return o === i ? null : o === r ? a : a = t(r = o, n);
|
|
2826
2826
|
};
|
|
2827
2827
|
}
|
|
2828
2828
|
function bo(e, t, n) {
|
|
2829
2829
|
var r, i, a;
|
|
2830
2830
|
return function() {
|
|
2831
|
-
var o =
|
|
2832
|
-
return s ?? (c = s = (this.style.removeProperty(e),
|
|
2831
|
+
var o = L(this, e), s = n(this), c = s + "";
|
|
2832
|
+
return s ?? (c = s = (this.style.removeProperty(e), L(this, e))), o === c ? null : o === r && c === i ? a : (i = c, a = t(r = o, s));
|
|
2833
2833
|
};
|
|
2834
2834
|
}
|
|
2835
2835
|
function xo(e, t) {
|
|
@@ -2840,7 +2840,7 @@ function xo(e, t) {
|
|
|
2840
2840
|
};
|
|
2841
2841
|
}
|
|
2842
2842
|
function So(e, t, n) {
|
|
2843
|
-
var r = (e += "") == "transform" ?
|
|
2843
|
+
var r = (e += "") == "transform" ? le : Ia;
|
|
2844
2844
|
return t == null ? this.styleTween(e, _o(e, r)).on("end.style." + e, vo(e)) : typeof t == "function" ? this.styleTween(e, bo(e, r, Fa(this, "style." + e, t))).each(xo(this._id, e)) : this.styleTween(e, yo(e, r, t), n).on("end.style." + e, null);
|
|
2845
2845
|
}
|
|
2846
2846
|
function Co(e, t, n) {
|
|
@@ -2926,12 +2926,12 @@ function X(e, t, n, r) {
|
|
|
2926
2926
|
this._groups = e, this._parents = t, this._name = n, this._id = r;
|
|
2927
2927
|
}
|
|
2928
2928
|
function Fo(e) {
|
|
2929
|
-
return
|
|
2929
|
+
return z().transition(e);
|
|
2930
2930
|
}
|
|
2931
2931
|
function Io() {
|
|
2932
2932
|
return ++Po;
|
|
2933
2933
|
}
|
|
2934
|
-
var Z =
|
|
2934
|
+
var Z = z.prototype;
|
|
2935
2935
|
X.prototype = Fo.prototype = {
|
|
2936
2936
|
constructor: X,
|
|
2937
2937
|
select: po,
|
|
@@ -2963,12 +2963,12 @@ X.prototype = Fo.prototype = {
|
|
|
2963
2963
|
easeVarying: io,
|
|
2964
2964
|
end: No,
|
|
2965
2965
|
[Symbol.iterator]: Z[Symbol.iterator]
|
|
2966
|
-
},
|
|
2966
|
+
}, oe();
|
|
2967
2967
|
var Lo = {
|
|
2968
2968
|
time: null,
|
|
2969
2969
|
delay: 0,
|
|
2970
2970
|
duration: 250,
|
|
2971
|
-
ease:
|
|
2971
|
+
ease: ae
|
|
2972
2972
|
};
|
|
2973
2973
|
function Ro(e, t) {
|
|
2974
2974
|
for (var n; !(n = e.__transition) || !(n = n[t]);) if (!(e = e.parentNode)) throw Error(`transition ${t} not found`);
|
|
@@ -2980,7 +2980,7 @@ function zo(e) {
|
|
|
2980
2980
|
for (var r = this._groups, i = r.length, a = 0; a < i; ++a) for (var o = r[a], s = o.length, c, l = 0; l < s; ++l) (c = o[l]) && Da(c, e, t, l, o, n || Ro(c, t));
|
|
2981
2981
|
return new X(r, this._parents, e, t);
|
|
2982
2982
|
}
|
|
2983
|
-
|
|
2983
|
+
z.prototype.interrupt = ja, z.prototype.transition = zo;
|
|
2984
2984
|
var Bo = (e) => () => e;
|
|
2985
2985
|
function Vo(e, { sourceEvent: t, target: n, transform: r, dispatch: i }) {
|
|
2986
2986
|
Object.defineProperties(this, {
|
|
@@ -3058,7 +3058,7 @@ function Wo(e) {
|
|
|
3058
3058
|
function Go(e) {
|
|
3059
3059
|
e.preventDefault(), e.stopImmediatePropagation();
|
|
3060
3060
|
}
|
|
3061
|
-
|
|
3061
|
+
nt(), _e();
|
|
3062
3062
|
function Ko(e) {
|
|
3063
3063
|
return (!e.ctrlKey || e.type === "wheel") && !e.button;
|
|
3064
3064
|
}
|
|
@@ -3080,7 +3080,7 @@ function Zo(e, t, n) {
|
|
|
3080
3080
|
return e.translate(i > r ? (r + i) / 2 : Math.min(0, r) || Math.max(0, i), o > a ? (a + o) / 2 : Math.min(0, a) || Math.max(0, o));
|
|
3081
3081
|
}
|
|
3082
3082
|
function Qo() {
|
|
3083
|
-
var e = Ko, t = qo, n = Zo, r = Yo, i = Xo, a = [0, Infinity], o = [[-Infinity, -Infinity], [Infinity, Infinity]], s = 250, c =
|
|
3083
|
+
var e = Ko, t = qo, n = Zo, r = Yo, i = Xo, a = [0, Infinity], o = [[-Infinity, -Infinity], [Infinity, Infinity]], s = 250, c = ge, l = tt("start", "zoom", "end"), u, d, f, p = 500, m = 150, h = 0, g = 10;
|
|
3084
3084
|
function _(e) {
|
|
3085
3085
|
e.property("__zoom", Jo).on("wheel.zoom", w, { passive: !1 }).on("mousedown.zoom", T).on("dblclick.zoom", E).filter(i).on("touchstart.zoom", ee).on("touchmove.zoom", te).on("touchend.zoom touchcancel.zoom", D).style("-webkit-tap-highlight-color", "rgba(0,0,0,0)");
|
|
3086
3086
|
}
|
|
@@ -3155,7 +3155,7 @@ function Qo() {
|
|
|
3155
3155
|
return --this.active === 0 && (delete this.that.__zooming, this.emit("end")), this;
|
|
3156
3156
|
},
|
|
3157
3157
|
emit: function(e) {
|
|
3158
|
-
var t =
|
|
3158
|
+
var t = B(this.that).datum();
|
|
3159
3159
|
l.call(e, this.that, new Vo(e, {
|
|
3160
3160
|
sourceEvent: this.sourceEvent,
|
|
3161
3161
|
target: _,
|
|
@@ -3167,7 +3167,7 @@ function Qo() {
|
|
|
3167
3167
|
};
|
|
3168
3168
|
function w(t, ...i) {
|
|
3169
3169
|
if (!e.apply(this, arguments)) return;
|
|
3170
|
-
var s = S(this, i).event(t), c = this.__zoom, l = Math.max(a[0], Math.min(a[1], c.k * 2 ** r.apply(this, arguments))), u =
|
|
3170
|
+
var s = S(this, i).event(t), c = this.__zoom, l = Math.max(a[0], Math.min(a[1], c.k * 2 ** r.apply(this, arguments))), u = V(t);
|
|
3171
3171
|
if (s.wheel) (s.mouse[0][0] !== u[0] || s.mouse[0][1] !== u[1]) && (s.mouse[1] = c.invert(s.mouse[0] = u)), clearTimeout(s.wheel);
|
|
3172
3172
|
else if (c.k === l) return;
|
|
3173
3173
|
else s.mouse = [u, c.invert(u)], Aa(this), s.start();
|
|
@@ -3178,29 +3178,29 @@ function Qo() {
|
|
|
3178
3178
|
}
|
|
3179
3179
|
function T(t, ...r) {
|
|
3180
3180
|
if (f || !e.apply(this, arguments)) return;
|
|
3181
|
-
var i = t.currentTarget, a = S(this, r, !0).event(t), s =
|
|
3182
|
-
|
|
3181
|
+
var i = t.currentTarget, a = S(this, r, !0).event(t), s = B(t.view).on("mousemove.zoom", d, !0).on("mouseup.zoom", p, !0), c = V(t, i), l = t.clientX, u = t.clientY;
|
|
3182
|
+
Zi(t.view), Wo(t), a.mouse = [c, this.__zoom.invert(c)], Aa(this), a.start();
|
|
3183
3183
|
function d(e) {
|
|
3184
3184
|
if (Go(e), !a.moved) {
|
|
3185
3185
|
var t = e.clientX - l, r = e.clientY - u;
|
|
3186
3186
|
a.moved = t * t + r * r > h;
|
|
3187
3187
|
}
|
|
3188
|
-
a.event(e).zoom("mouse", n(y(a.that.__zoom, a.mouse[0] =
|
|
3188
|
+
a.event(e).zoom("mouse", n(y(a.that.__zoom, a.mouse[0] = V(e, i), a.mouse[1]), a.extent, o));
|
|
3189
3189
|
}
|
|
3190
3190
|
function p(e) {
|
|
3191
|
-
s.on("mousemove.zoom mouseup.zoom", null),
|
|
3191
|
+
s.on("mousemove.zoom mouseup.zoom", null), Qi(e.view, a.moved), Go(e), a.event(e).end();
|
|
3192
3192
|
}
|
|
3193
3193
|
}
|
|
3194
3194
|
function E(r, ...i) {
|
|
3195
3195
|
if (e.apply(this, arguments)) {
|
|
3196
|
-
var a = this.__zoom, c =
|
|
3197
|
-
Go(r), s > 0 ?
|
|
3196
|
+
var a = this.__zoom, c = V(r.changedTouches ? r.changedTouches[0] : r, this), l = a.invert(c), u = a.k * (r.shiftKey ? .5 : 2), d = n(y(v(a, u), c, l), t.apply(this, i), o);
|
|
3197
|
+
Go(r), s > 0 ? B(this).transition().duration(s).call(x, d, c, r) : B(this).call(_.transform, d, c, r);
|
|
3198
3198
|
}
|
|
3199
3199
|
}
|
|
3200
3200
|
function ee(t, ...n) {
|
|
3201
3201
|
if (e.apply(this, arguments)) {
|
|
3202
3202
|
var r = t.touches, i = r.length, a = S(this, n, t.changedTouches.length === i).event(t), o, s, c, l;
|
|
3203
|
-
for (Wo(t), s = 0; s < i; ++s) c = r[s], l =
|
|
3203
|
+
for (Wo(t), s = 0; s < i; ++s) c = r[s], l = V(c, this), l = [
|
|
3204
3204
|
l,
|
|
3205
3205
|
this.__zoom.invert(l),
|
|
3206
3206
|
c.identifier
|
|
@@ -3213,7 +3213,7 @@ function Qo() {
|
|
|
3213
3213
|
function te(e, ...t) {
|
|
3214
3214
|
if (this.__zooming) {
|
|
3215
3215
|
var r = S(this, t).event(e), i = e.changedTouches, a = i.length, s, c, l, u;
|
|
3216
|
-
for (Go(e), s = 0; s < a; ++s) c = i[s], l =
|
|
3216
|
+
for (Go(e), s = 0; s < a; ++s) c = i[s], l = V(c, this), r.touch0 && r.touch0[2] === c.identifier ? r.touch0[0] = l : r.touch1 && r.touch1[2] === c.identifier && (r.touch1[0] = l);
|
|
3217
3217
|
if (c = r.that.__zoom, r.touch1) {
|
|
3218
3218
|
var d = r.touch0[0], f = r.touch0[1], p = r.touch1[0], m = r.touch1[1], h = (h = p[0] - d[0]) * h + (h = p[1] - d[1]) * h, g = (g = m[0] - f[0]) * g + (g = m[1] - f[1]) * g;
|
|
3219
3219
|
c = v(c, Math.sqrt(h / g)), l = [(d[0] + p[0]) / 2, (d[1] + p[1]) / 2], u = [(f[0] + m[0]) / 2, (f[1] + m[1]) / 2];
|
|
@@ -3229,8 +3229,8 @@ function Qo() {
|
|
|
3229
3229
|
f = null;
|
|
3230
3230
|
}, p), a = 0; a < i; ++a) o = r[a], n.touch0 && n.touch0[2] === o.identifier ? delete n.touch0 : n.touch1 && n.touch1[2] === o.identifier && delete n.touch1;
|
|
3231
3231
|
if (n.touch1 && !n.touch0 && (n.touch0 = n.touch1, delete n.touch1), n.touch0) n.touch0[1] = this.__zoom.invert(n.touch0[0]);
|
|
3232
|
-
else if (n.end(), n.taps === 2 && (o =
|
|
3233
|
-
var s =
|
|
3232
|
+
else if (n.end(), n.taps === 2 && (o = V(o, this), Math.hypot(d[0] - o[0], d[1] - o[1]) < g)) {
|
|
3233
|
+
var s = B(this).on("dblclick.zoom");
|
|
3234
3234
|
s && s.apply(this, arguments);
|
|
3235
3235
|
}
|
|
3236
3236
|
}
|
|
@@ -3262,7 +3262,7 @@ function Qo() {
|
|
|
3262
3262
|
return arguments.length ? (g = +e, _) : g;
|
|
3263
3263
|
}, _;
|
|
3264
3264
|
}
|
|
3265
|
-
|
|
3265
|
+
A();
|
|
3266
3266
|
var $o = (e) => ({
|
|
3267
3267
|
left: {
|
|
3268
3268
|
nodeLeftX: () => 0,
|
|
@@ -3530,20 +3530,20 @@ var is = () => {
|
|
|
3530
3530
|
buttonContent: ns,
|
|
3531
3531
|
pagingButton: rs,
|
|
3532
3532
|
nodeUpdate: function() {
|
|
3533
|
-
|
|
3533
|
+
B(this).select(".node-rect").attr("stroke", null).attr("stroke-width", null);
|
|
3534
3534
|
},
|
|
3535
3535
|
nodeEnter: (e) => e,
|
|
3536
3536
|
nodeExit: (e) => e,
|
|
3537
3537
|
linkUpdate: function(e) {
|
|
3538
3538
|
if (e.data._upToTheRootHighlighted) {
|
|
3539
|
-
|
|
3539
|
+
B(this).style("stroke-width", "var(--border-hover-width)").style("stroke", "var(--border-hover-color)");
|
|
3540
3540
|
return;
|
|
3541
3541
|
}
|
|
3542
|
-
|
|
3542
|
+
B(this).style("stroke", null).style("stroke-width", null), e.data._upToTheRootHighlighted && B(this).raise();
|
|
3543
3543
|
},
|
|
3544
3544
|
hdiagonal: es,
|
|
3545
3545
|
diagonal: ts,
|
|
3546
|
-
linkGroupArc:
|
|
3546
|
+
linkGroupArc: me().x((e) => e.x).y((e) => e.y)
|
|
3547
3547
|
};
|
|
3548
3548
|
return e.layoutBindings = $o(e), e;
|
|
3549
3549
|
}, as = (e) => Math.min(1, 9 / e), os = (e, t, n, r) => {
|
|
@@ -3557,48 +3557,48 @@ var is = () => {
|
|
|
3557
3557
|
x: u / 2 - h * os(o, s, u / h, a?.x),
|
|
3558
3558
|
y: d / 2 - h * os(c, l, d / h, a?.y)
|
|
3559
3559
|
};
|
|
3560
|
-
}, cs = (e,
|
|
3561
|
-
let
|
|
3562
|
-
return
|
|
3563
|
-
let
|
|
3564
|
-
linkUpdate:
|
|
3565
|
-
getButtonContent:
|
|
3566
|
-
...
|
|
3567
|
-
},
|
|
3568
|
-
...
|
|
3560
|
+
}, cs = (e, n, i) => {
|
|
3561
|
+
let a = (0, M.useRef)(e.treeChartSettings?.transform), o = (0, M.useRef)(null);
|
|
3562
|
+
return o.current = (n) => {
|
|
3563
|
+
let a = is(), o = n.treeOptions, s = {
|
|
3564
|
+
linkUpdate: a.linkUpdate,
|
|
3565
|
+
getButtonContent: a.buttonContent,
|
|
3566
|
+
...qi[o.layoutPreset]
|
|
3567
|
+
}, c = s.sizes ? s.sizes(e) : {}, l = {
|
|
3568
|
+
...s.labelStyle,
|
|
3569
3569
|
...e.treeChartSettings?.nodeLayout?.labelStyle,
|
|
3570
|
-
fontSize: e.treeChartSettings?.nodeLayout?.labelStyle?.fontSize ??
|
|
3571
|
-
},
|
|
3572
|
-
...
|
|
3570
|
+
fontSize: e.treeChartSettings?.nodeLayout?.labelStyle?.fontSize ?? s.labelStyle?.fontSize
|
|
3571
|
+
}, u = {
|
|
3572
|
+
...p,
|
|
3573
3573
|
...e.treeChartSettings?.nodeLayout?.border
|
|
3574
3574
|
};
|
|
3575
|
-
|
|
3575
|
+
u.enabled === !1 && (u.borderWidth = 0);
|
|
3576
3576
|
let d = {
|
|
3577
|
-
...
|
|
3577
|
+
...r,
|
|
3578
3578
|
...e.treeChartSettings?.nodeLayout.hoverStyle
|
|
3579
|
-
},
|
|
3580
|
-
|
|
3581
|
-
top:
|
|
3582
|
-
right:
|
|
3583
|
-
bottom:
|
|
3584
|
-
left:
|
|
3585
|
-
}).gridEnabled(
|
|
3586
|
-
zoomToFit:
|
|
3587
|
-
transform:
|
|
3579
|
+
}, f = d.enabled ? d.borderWidth : 0;
|
|
3580
|
+
i.nodeWidth((e) => (o.nodeWidth ? o.nodeWidth : typeof s.width == "function" ? s.width(e) : s.width) + (u.borderWidth ?? 0) * 2).nodeHeight((e) => (e.id === "__root__" ? 0 : typeof s.height == "function" ? s.height(e, c) : s.height) + (u.borderWidth ?? 0) * 2).nodeDefaultBackground(e.treeChartSettings?.nodeLayout?.backgroundColor ?? t.backgroundColor).compact(o.compact).layout(o.directionOrigin).padding({
|
|
3581
|
+
top: f,
|
|
3582
|
+
right: f,
|
|
3583
|
+
bottom: f,
|
|
3584
|
+
left: f
|
|
3585
|
+
}).gridEnabled(o.gridLayoutEnabled).gridRows(o.gridLayoutRows).forceAutoFit(o.forceAutoFit).minFitScale(o.keepFitReadable ? as(k(l.fontSize)) : 0).setActiveNodeCentered(!o.forceAutoFit).duration(o.animate === !1 ? 0 : 400).root(n.root).linkUpdate(s.linkUpdate).buttonContent(s.getButtonContent).container(n.container).nodeContent((e) => s.getNodeContent(e, { config: i.getConfig() })).render({
|
|
3586
|
+
zoomToFit: n.zoomToFit ?? !1,
|
|
3587
|
+
transform: n.transform
|
|
3588
3588
|
});
|
|
3589
|
-
}, (0,
|
|
3590
|
-
!e || !
|
|
3589
|
+
}, (0, M.useCallback)((e, t) => {
|
|
3590
|
+
!e || !n.current || o.current?.({
|
|
3591
3591
|
root: e,
|
|
3592
|
-
container:
|
|
3593
|
-
treeOptions:
|
|
3592
|
+
container: n.current,
|
|
3593
|
+
treeOptions: t,
|
|
3594
3594
|
zoomToFit: !0,
|
|
3595
|
-
transform:
|
|
3595
|
+
transform: a.current ?? void 0
|
|
3596
3596
|
});
|
|
3597
3597
|
}, []);
|
|
3598
3598
|
}, ls = {
|
|
3599
3599
|
directionOrigin: "top",
|
|
3600
3600
|
compact: !1,
|
|
3601
|
-
layoutPreset:
|
|
3601
|
+
layoutPreset: s.Basic,
|
|
3602
3602
|
forceAutoFit: !1,
|
|
3603
3603
|
keepFitReadable: !0,
|
|
3604
3604
|
animate: !0,
|
|
@@ -3620,7 +3620,7 @@ var is = () => {
|
|
|
3620
3620
|
};
|
|
3621
3621
|
return {
|
|
3622
3622
|
treeSettings: i,
|
|
3623
|
-
layout:
|
|
3623
|
+
layout: qi[i.layoutPreset || s.Basic]
|
|
3624
3624
|
};
|
|
3625
3625
|
};
|
|
3626
3626
|
function ds(e) {
|
|
@@ -3734,7 +3734,7 @@ ks.prototype = ws.prototype = {
|
|
|
3734
3734
|
copy: Ts
|
|
3735
3735
|
};
|
|
3736
3736
|
var As = ie();
|
|
3737
|
-
|
|
3737
|
+
Ie();
|
|
3738
3738
|
var { version: js } = {
|
|
3739
3739
|
name: "d3-flextree",
|
|
3740
3740
|
version: "2.1.2",
|
|
@@ -4034,19 +4034,19 @@ var Ps = (e, t = 0) => (e.y = t, (e.children || []).reduce((t, n) => {
|
|
|
4034
4034
|
next: n
|
|
4035
4035
|
};
|
|
4036
4036
|
};
|
|
4037
|
-
|
|
4037
|
+
A();
|
|
4038
4038
|
var $ = {
|
|
4039
|
-
selection:
|
|
4040
|
-
select:
|
|
4041
|
-
max:
|
|
4042
|
-
min:
|
|
4043
|
-
sum:
|
|
4044
|
-
cumsum:
|
|
4045
|
-
tree:
|
|
4046
|
-
stratify:
|
|
4039
|
+
selection: z,
|
|
4040
|
+
select: B,
|
|
4041
|
+
max: Pe,
|
|
4042
|
+
min: Le,
|
|
4043
|
+
sum: Fe,
|
|
4044
|
+
cumsum: Re,
|
|
4045
|
+
tree: Sn,
|
|
4046
|
+
stratify: un,
|
|
4047
4047
|
zoom: Qo,
|
|
4048
4048
|
zoomIdentity: Ho,
|
|
4049
|
-
linkHorizontal:
|
|
4049
|
+
linkHorizontal: me,
|
|
4050
4050
|
flextree: Ns
|
|
4051
4051
|
}, Ks = class {
|
|
4052
4052
|
stateInternal = {
|
|
@@ -4131,7 +4131,7 @@ var $ = {
|
|
|
4131
4131
|
};
|
|
4132
4132
|
}
|
|
4133
4133
|
extendHierarchyNodePrototype() {
|
|
4134
|
-
|
|
4134
|
+
Ze.prototype.allDescendants || (Ze.prototype.allDescendants = function() {
|
|
4135
4135
|
let e = [];
|
|
4136
4136
|
this.each((t) => {
|
|
4137
4137
|
e.push(t);
|
|
@@ -4293,7 +4293,7 @@ var $ = {
|
|
|
4293
4293
|
}).remove();
|
|
4294
4294
|
let d = this, f = r.nodesWrapper.selectAll("g.node").data(o, ({ data: e }) => i.nodeId(e) ?? ""), p = f.enter().append("g").attr("data-brush", (e) => e.data.brush?.key ?? null).attr("class", "node").attr("transform", (n) => n == r.root ? `translate(${e},${t})` : `translate(${i.layoutBindings[i.layout].nodeJoinX(n.parent || n)},${i.layoutBindings[i.layout].nodeJoinY(n.parent || n)})`).classed("draggable droppable", !0).on("click.node", (e, t) => {
|
|
4295
4295
|
[...e.srcElement.classList].includes("node-button-foreign-object") || i.onNodeClick(t);
|
|
4296
|
-
}).call(
|
|
4296
|
+
}).call(aa().filter(function(e, t) {
|
|
4297
4297
|
return r.dragEnabled === !0 && t.depth > 0;
|
|
4298
4298
|
}).on("start", function(e, t) {
|
|
4299
4299
|
d.onDragStart(this, e, t);
|
|
@@ -4438,12 +4438,12 @@ var $ = {
|
|
|
4438
4438
|
let r = this.getChartState();
|
|
4439
4439
|
r.dragNode = n;
|
|
4440
4440
|
let i = t.subject.width / 2;
|
|
4441
|
-
r.dragStartX = t.x - i, r.dragStartY = t.y, r.isDragStarting = !0,
|
|
4441
|
+
r.dragStartX = t.x - i, r.dragStartY = t.y, r.isDragStarting = !0, B(e).classed("dragging", !0);
|
|
4442
4442
|
}
|
|
4443
4443
|
onDrag(e, t) {
|
|
4444
4444
|
let n = this.getChartState(), r = this.getConfig();
|
|
4445
4445
|
if (!n.dragNode) return;
|
|
4446
|
-
let i =
|
|
4446
|
+
let i = B(e);
|
|
4447
4447
|
if (n.isDragStarting) {
|
|
4448
4448
|
n.isDragStarting = !1, r.container.classList.add("dragging-active"), i.raise();
|
|
4449
4449
|
let e = t.subject.descendants(), a = [...e || [], t.subject], o = e.filter((e) => e.data.id !== t.subject.id);
|
|
@@ -4459,7 +4459,7 @@ var $ = {
|
|
|
4459
4459
|
bottom: t.y + t.subject.height,
|
|
4460
4460
|
midX: t.x + t.subject.width / 2,
|
|
4461
4461
|
midY: t.y + t.subject.height / 2
|
|
4462
|
-
}, o =
|
|
4462
|
+
}, o = Ai("g.node:not(.dragging)");
|
|
4463
4463
|
o.classed("drop-target", !1), o.filter(function(e) {
|
|
4464
4464
|
let t = {
|
|
4465
4465
|
left: e.x,
|
|
@@ -4474,7 +4474,7 @@ var $ = {
|
|
|
4474
4474
|
this.getConfig().container.classList.remove("dragging-active");
|
|
4475
4475
|
let n = this.getChartState();
|
|
4476
4476
|
if (n.dragNode) {
|
|
4477
|
-
if (
|
|
4477
|
+
if (B(e).classed("dragging", !1), !n.dropNode) {
|
|
4478
4478
|
this.render();
|
|
4479
4479
|
return;
|
|
4480
4480
|
}
|
|
@@ -4482,7 +4482,7 @@ var $ = {
|
|
|
4482
4482
|
this.render();
|
|
4483
4483
|
return;
|
|
4484
4484
|
}
|
|
4485
|
-
|
|
4485
|
+
B(e).remove(), n.dragNode.parent = n.dropNode, n.dragNode.parent && (n.dragNode.parent.children = n.dragNode.parent.children?.filter((e) => e.id !== n.dragNode?.id) || void 0), this.getConfig().onNodeParentChange?.(n.dragNode), n.dropNode = null, n.dragNode = null, this.render();
|
|
4486
4486
|
}
|
|
4487
4487
|
}
|
|
4488
4488
|
zoomed(e) {
|
|
@@ -4560,12 +4560,12 @@ var $ = {
|
|
|
4560
4560
|
let e = this.getChartState();
|
|
4561
4561
|
e.svg && (e.svg.selectAll("*").remove(), e.svg = null, e.chart = null);
|
|
4562
4562
|
}
|
|
4563
|
-
}, qs =
|
|
4563
|
+
}, qs = se(), Js = (e, t, n) => {
|
|
4564
4564
|
let r = String(n);
|
|
4565
4565
|
return Array.from(e.querySelectorAll(".node[data-brush][data-value]")).find((e) => e.getAttribute("data-brush") === t && e.getAttribute("data-value") === r);
|
|
4566
4566
|
}, Ys = (e, t, n) => {
|
|
4567
|
-
let r =
|
|
4568
|
-
t.data.brush && r.daedalus.emitEvent(
|
|
4567
|
+
let r = te(), i = (0, M.useCallback)((t) => {
|
|
4568
|
+
t.data.brush && r.daedalus.emitEvent(pe.Brush, {
|
|
4569
4569
|
data: {
|
|
4570
4570
|
action: qs.BrushEventAction.Hover,
|
|
4571
4571
|
data: [{
|
|
@@ -4575,8 +4575,8 @@ var $ = {
|
|
|
4575
4575
|
},
|
|
4576
4576
|
emitter: e
|
|
4577
4577
|
});
|
|
4578
|
-
}, [r, e]), a = (0,
|
|
4579
|
-
t.data.brush && r.daedalus.emitEvent(
|
|
4578
|
+
}, [r, e]), a = (0, M.useCallback)((t) => {
|
|
4579
|
+
t.data.brush && r.daedalus.emitEvent(pe.Brush, {
|
|
4580
4580
|
data: {
|
|
4581
4581
|
action: qs.BrushEventAction.Blur,
|
|
4582
4582
|
data: [{
|
|
@@ -4586,7 +4586,7 @@ var $ = {
|
|
|
4586
4586
|
},
|
|
4587
4587
|
emitter: e
|
|
4588
4588
|
});
|
|
4589
|
-
}, [r, e]), o = (0,
|
|
4589
|
+
}, [r, e]), o = (0, M.useRef)(void 0);
|
|
4590
4590
|
return o.current = (r) => {
|
|
4591
4591
|
if (r.emitter !== e && !(!t || !n.interactive)) switch (r.data.action) {
|
|
4592
4592
|
case qs.BrushEventAction.Hover:
|
|
@@ -4607,53 +4607,53 @@ var $ = {
|
|
|
4607
4607
|
t.querySelectorAll(".node.hovered").forEach((e) => e.classList.remove("hovered"));
|
|
4608
4608
|
break;
|
|
4609
4609
|
}
|
|
4610
|
-
},
|
|
4611
|
-
action:
|
|
4610
|
+
}, h({
|
|
4611
|
+
action: pe.Brush,
|
|
4612
4612
|
handler: ({ payload: e }) => e && o.current?.(e)
|
|
4613
4613
|
}, []), {
|
|
4614
4614
|
onTreeNodeHover: i,
|
|
4615
4615
|
onTreeNodeLeave: a
|
|
4616
4616
|
};
|
|
4617
4617
|
}, Xs = (e) => {
|
|
4618
|
-
let { variables: t, variablesFetched:
|
|
4618
|
+
let { variables: t, variablesFetched: n, updateVariable: r } = T();
|
|
4619
4619
|
return {
|
|
4620
|
-
variables: (0,
|
|
4621
|
-
let
|
|
4620
|
+
variables: (0, M.useMemo)(() => {
|
|
4621
|
+
let n = {};
|
|
4622
4622
|
return e.measures?.forEach((e) => {
|
|
4623
|
-
!e.slots || !
|
|
4624
|
-
let
|
|
4625
|
-
if (!
|
|
4626
|
-
let
|
|
4627
|
-
|
|
4628
|
-
id:
|
|
4623
|
+
!e.slots || !i(e) || Object.values(e.slots).filter((e) => e.enabled && e.source === "variable" && e.propertyValue?.type === "variable").forEach((r) => {
|
|
4624
|
+
let i = r.propertyValue.variableName;
|
|
4625
|
+
if (!i) return;
|
|
4626
|
+
let a = t.find((e) => e.name === i);
|
|
4627
|
+
n[i] || (n[i] = {
|
|
4628
|
+
id: a?.id ?? null,
|
|
4629
4629
|
measureId: []
|
|
4630
4630
|
});
|
|
4631
|
-
let s =
|
|
4632
|
-
|
|
4631
|
+
let s = o(e.dataItem);
|
|
4632
|
+
n[i].measureId.includes(s) || n[i].measureId.push(s);
|
|
4633
4633
|
});
|
|
4634
|
-
}),
|
|
4634
|
+
}), n;
|
|
4635
4635
|
}, [
|
|
4636
4636
|
e.measures,
|
|
4637
4637
|
t,
|
|
4638
|
-
|
|
4638
|
+
n
|
|
4639
4639
|
]),
|
|
4640
|
-
updateVariable:
|
|
4641
|
-
variablesFetched:
|
|
4640
|
+
updateVariable: r,
|
|
4641
|
+
variablesFetched: n
|
|
4642
4642
|
};
|
|
4643
4643
|
}, Zs = (e, t) => {
|
|
4644
|
-
let
|
|
4644
|
+
let n = e.dimensions.filter(i), r = n.map((e) => o(e.dataItem)), a = n.length, s = (0, M.useMemo)(() => x(n.map((e) => ({
|
|
4645
4645
|
dataItem: e.dataItem,
|
|
4646
4646
|
dateLevel: void 0,
|
|
4647
4647
|
datePart: void 0,
|
|
4648
4648
|
operator: As.FilterOperator.InList
|
|
4649
|
-
})), { ignoreApplied: !0 }), [
|
|
4650
|
-
if (!
|
|
4651
|
-
let { key: t, value: n } = e.data.brush, r = s.find((e) => e.fieldKey === t &&
|
|
4649
|
+
})), { ignoreApplied: !0 }), [r]), c = (0, M.useCallback)((e) => {
|
|
4650
|
+
if (!a || !s?.length || !e.data.brush) return;
|
|
4651
|
+
let { key: t, value: n } = e.data.brush, r = s.find((e) => e.fieldKey === t && ce(e.operators));
|
|
4652
4652
|
if (!r) return;
|
|
4653
4653
|
let i = (r.operators.pending ?? r.operators.applied ?? r.operators.initial) === As.FilterOperator.NotInList ? "off" : "on";
|
|
4654
4654
|
r.state.pending && r.state.pending.includes(n) && (i = i === "off" ? "on" : "off"), r.onClick(n, { [i]: !0 });
|
|
4655
|
-
}, [s,
|
|
4656
|
-
return (0,
|
|
4655
|
+
}, [s, r]);
|
|
4656
|
+
return (0, M.useEffect)(() => {
|
|
4657
4657
|
t && (t.querySelectorAll(".node.selected").forEach((e) => e.classList.remove("selected")), s.forEach(({ fieldKey: e, state: n }) => {
|
|
4658
4658
|
n.pending !== null && n.pending.forEach((n) => {
|
|
4659
4659
|
e && Js(t, e, n)?.classList.add("selected");
|
|
@@ -4668,41 +4668,41 @@ var $ = {
|
|
|
4668
4668
|
if (n === "nodeExpandState") return t;
|
|
4669
4669
|
}
|
|
4670
4670
|
});
|
|
4671
|
-
}, $s = 80, ec = (e, t,
|
|
4672
|
-
let
|
|
4671
|
+
}, $s = 80, ec = (e, t, n, r) => {
|
|
4672
|
+
let a = (0, M.useRef)(e.treeChartSettings?.nodeExpandState ?? {}), s = r.forceAutoFit, c = S(), l = Xs(c), u = _(), d = m(), f = te(), p = e.dimensions.filter(i), h = p.length, [g] = (0, M.useState)(e.treeChartSettings?.transform ?? null), [v, y] = (0, M.useState)(g ?? {
|
|
4673
4673
|
k: 1,
|
|
4674
4674
|
x: 0,
|
|
4675
4675
|
y: 0
|
|
4676
|
-
}),
|
|
4676
|
+
}), b = (0, M.useRef)(e.treeChartSettings?.transform), { onTreeNodeHover: x, onTreeNodeLeave: C } = Ys(n, t.current, r), { onTreeNodeClick: w } = Zs(e, t.current), T = (0, M.useRef)(new Ks()), E = (0, M.useRef)(null), ee = !e.treeChartSettings.gridLayout?.enabled && e.treeChartSettings?.nodeLayout?.hoverStyle?.enabled, D = (0, M.useCallback)(() => {
|
|
4677
4677
|
E.current &&= (clearTimeout(E.current), null);
|
|
4678
4678
|
}, []);
|
|
4679
4679
|
return T.current.onNodeHover((e) => {
|
|
4680
|
-
|
|
4680
|
+
r.interactive && x(e), ee && (D(), T.current.highlight(e));
|
|
4681
4681
|
}).onNodeLeave((e) => {
|
|
4682
|
-
|
|
4682
|
+
r.interactive && C(e), ee && (D(), E.current = setTimeout(() => {
|
|
4683
4683
|
T.current.highlight(null), E.current = null;
|
|
4684
4684
|
}, $s));
|
|
4685
4685
|
}).onNodeClick((e) => {
|
|
4686
|
-
if (!
|
|
4687
|
-
let t =
|
|
4688
|
-
|
|
4686
|
+
if (!r.interactive) return;
|
|
4687
|
+
let t = h > 0 ? e.data.id === "__total__" ? "total" : "dimension" : "measure", n = e.data.value?.value, i = t === "dimension" ? e.data.brush?.value : n;
|
|
4688
|
+
ze({
|
|
4689
4689
|
id: "onNodeClick",
|
|
4690
4690
|
nodeName: e.data.label,
|
|
4691
4691
|
nodeType: t,
|
|
4692
|
-
...
|
|
4692
|
+
...i == null ? {} : { nodeValue: i },
|
|
4693
4693
|
...n == null ? {} : { measureValue: n }
|
|
4694
4694
|
}, { vBackendAPI: f }), w(e);
|
|
4695
4695
|
}).onNodeParentChange((t) => {
|
|
4696
|
-
if (
|
|
4697
|
-
let
|
|
4698
|
-
|
|
4696
|
+
if (h > 0) return;
|
|
4697
|
+
let n = e.measures.find((e) => e.dataItem.uniqueSignature === t.data.id);
|
|
4698
|
+
n && ne(d, e.measures, o(n.dataItem), !t.parent || t.parent.data.id === "__root__" ? void 0 : t.parent.data.id);
|
|
4699
4699
|
}).onExpandOrCollapse((t) => {
|
|
4700
|
-
let n =
|
|
4701
|
-
r === n ? delete
|
|
4700
|
+
let n = On(t, e.treeChartSettings?.initialExpandedLevels, p.length, e.totals?.enabled ?? !1), r = !((t._children?.length ?? 0) > 0 && !t.children?.length);
|
|
4701
|
+
r === n ? delete a.current[t.data.id] : a.current[t.data.id] = r, Qs(u, { nodeExpandState: a.current }), !(h > 0) && Object.values(l.variables).filter((e) => e.measureId.includes(t.data.id)).forEach((e) => {
|
|
4702
4702
|
e.id && l.updateVariable(e.id, r, As.VariableType.boolean);
|
|
4703
4703
|
});
|
|
4704
4704
|
}).onUserZoom(() => {
|
|
4705
|
-
|
|
4705
|
+
b.current = null;
|
|
4706
4706
|
}).onZoomEnd((e) => {
|
|
4707
4707
|
if (s) return;
|
|
4708
4708
|
let t = {
|
|
@@ -4711,62 +4711,62 @@ var $ = {
|
|
|
4711
4711
|
y: e.transform.y
|
|
4712
4712
|
};
|
|
4713
4713
|
t.k === v.k && t.x === v.x && t.y === v.y || (y(t), Qs(u, {
|
|
4714
|
-
nodeExpandState:
|
|
4714
|
+
nodeExpandState: a.current,
|
|
4715
4715
|
transform: t
|
|
4716
4716
|
}));
|
|
4717
|
-
}), (0,
|
|
4718
|
-
e.treeChartSettings?.nodeExpandState && (
|
|
4719
|
-
}, [e.treeChartSettings?.nodeExpandState]), (0,
|
|
4720
|
-
c.treeChartSettings?.nodeExpandState || (
|
|
4721
|
-
}, [c.treeChartSettings?.initialExpandedLevels]), (0,
|
|
4722
|
-
|
|
4717
|
+
}), (0, M.useEffect)(() => () => D(), [D]), (0, M.useEffect)(() => {
|
|
4718
|
+
e.treeChartSettings?.nodeExpandState && (a.current = e.treeChartSettings.nodeExpandState ?? {});
|
|
4719
|
+
}, [e.treeChartSettings?.nodeExpandState]), (0, M.useEffect)(() => {
|
|
4720
|
+
c.treeChartSettings?.nodeExpandState || (a.current = {});
|
|
4721
|
+
}, [c.treeChartSettings?.initialExpandedLevels]), (0, M.useEffect)(() => {
|
|
4722
|
+
b.current = e.treeChartSettings?.transform, T.current && T.current.unsetUserTransform(), !(!e.treeChartSettings?.transform || !T.current) && T.current.applyTransform(e.treeChartSettings.transform);
|
|
4723
4723
|
}, [e.treeChartSettings?.transform]), {
|
|
4724
4724
|
chart: T.current,
|
|
4725
|
-
expandedState:
|
|
4725
|
+
expandedState: a
|
|
4726
4726
|
};
|
|
4727
4727
|
}, tc = ({ vSpec: e, vTheme: t, data: n, elementSize: r = {
|
|
4728
4728
|
width: 0,
|
|
4729
4729
|
height: 0
|
|
4730
|
-
}, vizProperties:
|
|
4731
|
-
let o =
|
|
4730
|
+
}, vizProperties: a }) => {
|
|
4731
|
+
let o = a?.isEditMode ?? !1, s = a?.isPrintMode ?? !1, c = e?.treeChartSettings?.gridLayout?.enabled, l = e.dimensions.filter(i).length, u = e.measures.filter(i), d = (0, M.useRef)("tree-" + f(10)), p = (0, M.useRef)(null), m = e.treeChartSettings?.forceAutoFit === !0, { layout: h, treeSettings: g } = us(e, a), { chart: _, expandedState: v } = ec(e, p, d.current, g), y = cs(e, p, _), b = Nn({
|
|
4732
4732
|
vSpec: e,
|
|
4733
4733
|
data: n,
|
|
4734
4734
|
nodeExpandState: v
|
|
4735
|
-
}), [x, S] = (0,
|
|
4736
|
-
(0,
|
|
4735
|
+
}), [x, S] = (0, M.useState)(!1);
|
|
4736
|
+
(0, M.useLayoutEffect)(() => (p.current && _.container(p.current).init(), () => {
|
|
4737
4737
|
_.destroy();
|
|
4738
|
-
}), [_]), (0,
|
|
4738
|
+
}), [_]), (0, M.useEffect)(() => {
|
|
4739
4739
|
x ? _.enableDrag() : _.disableDrag();
|
|
4740
|
-
}, [x]), (0,
|
|
4740
|
+
}, [x]), (0, M.useEffect)(() => {
|
|
4741
4741
|
!p.current || !_ || !r.width || !r.height || y(b, g);
|
|
4742
4742
|
}, [
|
|
4743
4743
|
r.width,
|
|
4744
4744
|
r.height,
|
|
4745
4745
|
y
|
|
4746
4746
|
]);
|
|
4747
|
-
let C = o &&
|
|
4748
|
-
(0,
|
|
4747
|
+
let C = o && l === 0 && !c;
|
|
4748
|
+
(0, M.useEffect)(() => {
|
|
4749
4749
|
p.current && y(b, g);
|
|
4750
4750
|
}, [
|
|
4751
4751
|
b,
|
|
4752
4752
|
JSON.stringify(g),
|
|
4753
4753
|
y
|
|
4754
4754
|
]);
|
|
4755
|
-
let w =
|
|
4755
|
+
let w = rn({
|
|
4756
4756
|
vTheme: t,
|
|
4757
4757
|
vSpec: e,
|
|
4758
|
-
id:
|
|
4758
|
+
id: d.current,
|
|
4759
4759
|
layout: h
|
|
4760
4760
|
});
|
|
4761
|
-
return /* @__PURE__ */ (0,
|
|
4761
|
+
return /* @__PURE__ */ (0, j.jsxs)("div", {
|
|
4762
4762
|
style: {
|
|
4763
4763
|
width: "100%",
|
|
4764
4764
|
height: "100%"
|
|
4765
4765
|
},
|
|
4766
|
-
id:
|
|
4766
|
+
id: d.current,
|
|
4767
4767
|
"data-mode": o ? "edit" : "view",
|
|
4768
4768
|
children: [
|
|
4769
|
-
!
|
|
4769
|
+
!s && /* @__PURE__ */ (0, j.jsxs)("div", {
|
|
4770
4770
|
className: "tree-toolbar",
|
|
4771
4771
|
style: {
|
|
4772
4772
|
position: "absolute",
|
|
@@ -4776,22 +4776,22 @@ var $ = {
|
|
|
4776
4776
|
top: 0,
|
|
4777
4777
|
gap: 10
|
|
4778
4778
|
},
|
|
4779
|
-
children: [C && /* @__PURE__ */ (0,
|
|
4779
|
+
children: [C && /* @__PURE__ */ (0, j.jsx)(nn, {
|
|
4780
4780
|
size: "small",
|
|
4781
4781
|
value: "organize",
|
|
4782
4782
|
selected: x,
|
|
4783
4783
|
onChange: () => S(!x),
|
|
4784
|
-
disabled:
|
|
4785
|
-
children: /* @__PURE__ */ (0,
|
|
4786
|
-
}), !m && /* @__PURE__ */ (0,
|
|
4784
|
+
disabled: u.length < 2,
|
|
4785
|
+
children: /* @__PURE__ */ (0, j.jsx)(rt, {})
|
|
4786
|
+
}), !m && /* @__PURE__ */ (0, j.jsx)(nn, {
|
|
4787
4787
|
value: "",
|
|
4788
4788
|
size: "small",
|
|
4789
4789
|
onClick: () => _?.fit(),
|
|
4790
|
-
children: /* @__PURE__ */ (0,
|
|
4790
|
+
children: /* @__PURE__ */ (0, j.jsx)(ee, {})
|
|
4791
4791
|
})]
|
|
4792
4792
|
}),
|
|
4793
|
-
/* @__PURE__ */ (0,
|
|
4794
|
-
/* @__PURE__ */ (0,
|
|
4793
|
+
/* @__PURE__ */ (0, j.jsx)("style", { children: w }),
|
|
4794
|
+
/* @__PURE__ */ (0, j.jsx)("div", {
|
|
4795
4795
|
style: {
|
|
4796
4796
|
width: "100%",
|
|
4797
4797
|
height: "100%"
|
|
@@ -4800,9 +4800,9 @@ var $ = {
|
|
|
4800
4800
|
})
|
|
4801
4801
|
]
|
|
4802
4802
|
});
|
|
4803
|
-
}, nc =
|
|
4803
|
+
}, nc = g((e) => {
|
|
4804
4804
|
let { vSpec: t, data: n } = e;
|
|
4805
|
-
return !t || !n || !
|
|
4805
|
+
return !t || !n || !u(t) ? null : /* @__PURE__ */ (0, j.jsx)(tc, {
|
|
4806
4806
|
...e,
|
|
4807
4807
|
vSpec: t,
|
|
4808
4808
|
data: n
|