@devtable/dashboard 4.15.0 → 4.16.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/dist/dashboard.es.js +219 -177
- package/dist/dashboard.umd.js +10 -10
- package/dist/plugins/viz-components/cartesian/type.d.ts +2 -0
- package/package.json +1 -1
package/dist/dashboard.es.js
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
var Ai = Object.defineProperty;
|
|
2
2
|
var Mi = (t, e, n) => e in t ? Ai(t, e, { enumerable: !0, configurable: !0, writable: !0, value: n }) : t[e] = n;
|
|
3
3
|
var O = (t, e, n) => (Mi(t, typeof e != "symbol" ? e + "" : e, n), n);
|
|
4
|
-
import { Box as $, Text as v, Button as F, Checkbox as He, MultiSelect as hn, Select as q, TextInput as k, Group as g, Stack as w, ActionIcon as z, LoadingOverlay as Vt, Table as zt, Tabs as V, Textarea as pn, AppShell as mn, Modal as
|
|
4
|
+
import { Box as $, Text as v, Button as F, Checkbox as He, MultiSelect as hn, Select as q, TextInput as k, Group as g, Stack as w, ActionIcon as z, LoadingOverlay as Vt, Table as zt, Tabs as V, Textarea as pn, AppShell as mn, Modal as we, Divider as U, SimpleGrid as Li, NumberInput as Ce, Menu as ue, Tooltip as qi, Paper as $i, Code as hr, Switch as Fe, useMantineTheme as Ni, ColorInput as Bi, ColorSwatch as pr, Slider as Vr, createStyles as fn, Popover as Zt, Accordion as A, SegmentedControl as ji, JsonInput as Gi } from "@mantine/core";
|
|
5
5
|
import { useModals as Wi, ModalsProvider as zr } from "@mantine/modals";
|
|
6
|
-
import { useRequest as Et, useBoolean as mt, useCreation as
|
|
6
|
+
import { useRequest as Et, useBoolean as mt, useCreation as Pe, useAsyncEffect as ft, useLatest as mr } from "ahooks";
|
|
7
7
|
import { observer as D } from "mobx-react-lite";
|
|
8
8
|
import x, { forwardRef as gn, useMemo as M, useState as de, createElement as Ot, useEffect as Z, useCallback as Rt, useRef as Qi, useContext as Me, createContext as Yi } from "react";
|
|
9
|
-
import B, { omit as Ft, get as ae, values as Er, unset as Ui, isObject as Or, set as Fr, orderBy as Hi, last as Xi, noop as Ji, defaults as ne, isEqual as
|
|
10
|
-
import { useForm as
|
|
9
|
+
import B, { omit as Ft, get as ae, values as Er, unset as Ui, isObject as Or, set as Fr, orderBy as Hi, last as Xi, noop as Ji, defaults as ne, isEqual as De, defaultsDeep as Ge, findLastIndex as Ki, isEmpty as Pr, isNumber as Zi, isString as Ar, range as eo, cloneDeep as Mr, maxBy as Lr, merge as qr, minBy as to, groupBy as no, template as $r, cloneDeepWith as ro, throttle as ao } from "lodash";
|
|
10
|
+
import { useForm as ke, Controller as S, useFieldArray as Se } from "react-hook-form";
|
|
11
11
|
import { DateRangePicker as io } from "@mantine/dates";
|
|
12
12
|
import { Calendar as oo, Refresh as Nr, DeviceFloppy as ee, Trash as K, PlaylistAdd as Je, Recycle as Br, Settings as jr, Filter as so, Database as lo, Share as co, Download as Gr, Code as uo, InfoCircle as ho, ArrowRight as en, ArrowsMaximize as po, Copy as mo, ArrowLeft as fo, ArrowsMove as go, ChevronDownRight as bo } from "tabler-icons-react";
|
|
13
13
|
import vo from "axios";
|
|
@@ -31,7 +31,7 @@ import { CanvasRenderer as $e } from "echarts/renderers";
|
|
|
31
31
|
import "echarts-gl";
|
|
32
32
|
import { GridComponent as Ke, VisualMapComponent as Oo, LegendComponent as Ze, TooltipComponent as et, DataZoomComponent as At, MarkLineComponent as Fo } from "echarts/components";
|
|
33
33
|
import { transform as Zr } from "echarts-stat";
|
|
34
|
-
import * as
|
|
34
|
+
import * as ze from "d3-regression";
|
|
35
35
|
import Po from "stickybits";
|
|
36
36
|
import ea, { WidthProvider as ta } from "react-grid-layout";
|
|
37
37
|
import Ao from "jszip";
|
|
@@ -171,13 +171,13 @@ function qo() {
|
|
|
171
171
|
}
|
|
172
172
|
return null;
|
|
173
173
|
}
|
|
174
|
-
var ce = Object.assign,
|
|
174
|
+
var ce = Object.assign, Ve = 0, Gn, Wn, Qn, Yn, Un, Hn, Xn;
|
|
175
175
|
function Jn() {
|
|
176
176
|
}
|
|
177
177
|
Jn.__reactDisabledLog = !0;
|
|
178
178
|
function di() {
|
|
179
179
|
{
|
|
180
|
-
if (
|
|
180
|
+
if (Ve === 0) {
|
|
181
181
|
Gn = console.log, Wn = console.info, Qn = console.warn, Yn = console.error, Un = console.group, Hn = console.groupCollapsed, Xn = console.groupEnd;
|
|
182
182
|
var d = {
|
|
183
183
|
configurable: !0,
|
|
@@ -195,12 +195,12 @@ function qo() {
|
|
|
195
195
|
groupEnd: d
|
|
196
196
|
});
|
|
197
197
|
}
|
|
198
|
-
|
|
198
|
+
Ve++;
|
|
199
199
|
}
|
|
200
200
|
}
|
|
201
201
|
function hi() {
|
|
202
202
|
{
|
|
203
|
-
if (
|
|
203
|
+
if (Ve--, Ve === 0) {
|
|
204
204
|
var d = {
|
|
205
205
|
configurable: !0,
|
|
206
206
|
enumerable: !0,
|
|
@@ -230,7 +230,7 @@ function qo() {
|
|
|
230
230
|
})
|
|
231
231
|
});
|
|
232
232
|
}
|
|
233
|
-
|
|
233
|
+
Ve < 0 && W("disabledDepth fell below zero. This is a bug in React. Please file an issue.");
|
|
234
234
|
}
|
|
235
235
|
}
|
|
236
236
|
var Wt = Q.ReactCurrentDispatcher, Qt;
|
|
@@ -278,29 +278,29 @@ function qo() {
|
|
|
278
278
|
}), typeof Reflect == "object" && Reflect.construct) {
|
|
279
279
|
try {
|
|
280
280
|
Reflect.construct(L, []);
|
|
281
|
-
} catch (
|
|
282
|
-
T =
|
|
281
|
+
} catch (Ie) {
|
|
282
|
+
T = Ie;
|
|
283
283
|
}
|
|
284
284
|
Reflect.construct(d, [], L);
|
|
285
285
|
} else {
|
|
286
286
|
try {
|
|
287
287
|
L.call();
|
|
288
|
-
} catch (
|
|
289
|
-
T =
|
|
288
|
+
} catch (Ie) {
|
|
289
|
+
T = Ie;
|
|
290
290
|
}
|
|
291
291
|
d.call(L.prototype);
|
|
292
292
|
}
|
|
293
293
|
} else {
|
|
294
294
|
try {
|
|
295
295
|
throw Error();
|
|
296
|
-
} catch (
|
|
297
|
-
T =
|
|
296
|
+
} catch (Ie) {
|
|
297
|
+
T = Ie;
|
|
298
298
|
}
|
|
299
299
|
d();
|
|
300
300
|
}
|
|
301
|
-
} catch (
|
|
302
|
-
if (
|
|
303
|
-
for (var P =
|
|
301
|
+
} catch (Ie) {
|
|
302
|
+
if (Ie && T && typeof Ie.stack == "string") {
|
|
303
|
+
for (var P = Ie.stack.split(`
|
|
304
304
|
`), ie = T.stack.split(`
|
|
305
305
|
`), X = P.length - 1, J = ie.length - 1; X >= 1 && J >= 0 && P[X] !== ie[J]; )
|
|
306
306
|
J--;
|
|
@@ -940,7 +940,7 @@ const sa = x.forwardRef(function({
|
|
|
940
940
|
const n = te(), {
|
|
941
941
|
control: a,
|
|
942
942
|
handleSubmit: i
|
|
943
|
-
} =
|
|
943
|
+
} = ke({
|
|
944
944
|
defaultValues: n.filters.values
|
|
945
945
|
}), o = n.filters.visibleInView(e.id);
|
|
946
946
|
return o.length === 0 ? null : /* @__PURE__ */ r("form", {
|
|
@@ -984,7 +984,7 @@ const sa = x.forwardRef(function({
|
|
|
984
984
|
freezeLayout: B.noop,
|
|
985
985
|
inEditMode: !1,
|
|
986
986
|
inUseMode: !0
|
|
987
|
-
},
|
|
987
|
+
}, _e = x.createContext(Uo), ca = x.createContext({
|
|
988
988
|
panel: null,
|
|
989
989
|
data: [],
|
|
990
990
|
loading: !1
|
|
@@ -1587,10 +1587,10 @@ const os = D(function({
|
|
|
1587
1587
|
}) {
|
|
1588
1588
|
const {
|
|
1589
1589
|
freezeLayout: a
|
|
1590
|
-
} = x.useContext(
|
|
1590
|
+
} = x.useContext(_e);
|
|
1591
1591
|
return x.useEffect(() => {
|
|
1592
1592
|
a(e);
|
|
1593
|
-
}, [e]), /* @__PURE__ */ r(
|
|
1593
|
+
}, [e]), /* @__PURE__ */ r(we, {
|
|
1594
1594
|
size: "96vw",
|
|
1595
1595
|
overflow: "inside",
|
|
1596
1596
|
opened: e,
|
|
@@ -2075,7 +2075,7 @@ const ds = D(function({
|
|
|
2075
2075
|
sx: {
|
|
2076
2076
|
maxWidth: "30em"
|
|
2077
2077
|
},
|
|
2078
|
-
children: [/* @__PURE__ */ r(
|
|
2078
|
+
children: [/* @__PURE__ */ r(Ce, {
|
|
2079
2079
|
label: "Placement Order",
|
|
2080
2080
|
required: !0,
|
|
2081
2081
|
value: e.order,
|
|
@@ -2239,10 +2239,10 @@ const ys = D(function() {
|
|
|
2239
2239
|
}) {
|
|
2240
2240
|
const {
|
|
2241
2241
|
freezeLayout: a
|
|
2242
|
-
} = x.useContext(
|
|
2242
|
+
} = x.useContext(_e);
|
|
2243
2243
|
return x.useEffect(() => {
|
|
2244
2244
|
a(e);
|
|
2245
|
-
}, [e]), /* @__PURE__ */ r(
|
|
2245
|
+
}, [e]), /* @__PURE__ */ r(we, {
|
|
2246
2246
|
size: "96vw",
|
|
2247
2247
|
overflow: "inside",
|
|
2248
2248
|
opened: e,
|
|
@@ -2256,10 +2256,10 @@ const ys = D(function() {
|
|
|
2256
2256
|
children: /* @__PURE__ */ r(ys, {})
|
|
2257
2257
|
});
|
|
2258
2258
|
});
|
|
2259
|
-
var Cs = /* @__PURE__ */ ((t) => (t.Use = "use", t.Edit = "edit", t))(Cs || {}),
|
|
2259
|
+
var Cs = /* @__PURE__ */ ((t) => (t.Use = "use", t.Edit = "edit", t))(Cs || {}), Re = /* @__PURE__ */ ((t) => (t.Division = "div", t.Modal = "modal", t))(Re || {}), ws = /* @__PURE__ */ ((t) => (t.Select = "select", t.MultiSelect = "multi-select", t.TextInput = "text-input", t.Checkbox = "checkbox", t.DateRange = "date-range", t))(ws || {});
|
|
2260
2260
|
const Ss = D(() => {
|
|
2261
2261
|
const e = te().views.VIE;
|
|
2262
|
-
return !e || e.type !==
|
|
2262
|
+
return !e || e.type !== Re.Division ? null : /* @__PURE__ */ c(w, {
|
|
2263
2263
|
children: [/* @__PURE__ */ r(U, {
|
|
2264
2264
|
mt: 8,
|
|
2265
2265
|
mb: 0,
|
|
@@ -2274,7 +2274,7 @@ const Ss = D(() => {
|
|
|
2274
2274
|
});
|
|
2275
2275
|
}), _s = D(() => {
|
|
2276
2276
|
const e = te().views.VIE;
|
|
2277
|
-
return !e || e.type !==
|
|
2277
|
+
return !e || e.type !== Re.Modal ? null : /* @__PURE__ */ c(w, {
|
|
2278
2278
|
children: [/* @__PURE__ */ r(U, {
|
|
2279
2279
|
mt: 8,
|
|
2280
2280
|
label: "Modal settings",
|
|
@@ -2298,10 +2298,10 @@ const Ss = D(() => {
|
|
|
2298
2298
|
children: [/* @__PURE__ */ r(Ss, {}), /* @__PURE__ */ r(_s, {})]
|
|
2299
2299
|
})), Ds = [{
|
|
2300
2300
|
label: "Division",
|
|
2301
|
-
value:
|
|
2301
|
+
value: Re.Division
|
|
2302
2302
|
}, {
|
|
2303
2303
|
label: "Modal",
|
|
2304
|
-
value:
|
|
2304
|
+
value: Re.Modal
|
|
2305
2305
|
}], Rs = D(() => {
|
|
2306
2306
|
const e = te().views.VIE;
|
|
2307
2307
|
return e ? /* @__PURE__ */ c(w, {
|
|
@@ -2328,10 +2328,10 @@ const Ss = D(() => {
|
|
|
2328
2328
|
var i;
|
|
2329
2329
|
const n = te(), {
|
|
2330
2330
|
freezeLayout: a
|
|
2331
|
-
} = x.useContext(
|
|
2331
|
+
} = x.useContext(_e);
|
|
2332
2332
|
return x.useEffect(() => {
|
|
2333
2333
|
a(t);
|
|
2334
|
-
}, [t]), /* @__PURE__ */ r(
|
|
2334
|
+
}, [t]), /* @__PURE__ */ r(we, {
|
|
2335
2335
|
size: "500px",
|
|
2336
2336
|
overflow: "inside",
|
|
2337
2337
|
opened: t,
|
|
@@ -2482,12 +2482,12 @@ function Es({
|
|
|
2482
2482
|
}) {
|
|
2483
2483
|
const {
|
|
2484
2484
|
freezeLayout: a
|
|
2485
|
-
} = x.useContext(
|
|
2485
|
+
} = x.useContext(_e);
|
|
2486
2486
|
x.useEffect(() => {
|
|
2487
2487
|
a(t);
|
|
2488
2488
|
}, [t]);
|
|
2489
2489
|
const i = x.useMemo(() => JSON.stringify(n(), null, 2), [t]);
|
|
2490
|
-
return /* @__PURE__ */ r(
|
|
2490
|
+
return /* @__PURE__ */ r(we, {
|
|
2491
2491
|
size: "96vw",
|
|
2492
2492
|
overflow: "inside",
|
|
2493
2493
|
opened: t,
|
|
@@ -2525,7 +2525,7 @@ const va = D(function({
|
|
|
2525
2525
|
}, o = n.views.changed || n.sqlSnippets.changed || n.queries.changed || n.filters.changed, {
|
|
2526
2526
|
inEditMode: s,
|
|
2527
2527
|
inUseMode: l
|
|
2528
|
-
} = x.useContext(
|
|
2528
|
+
} = x.useContext(_e), [u, p] = x.useState(!1), h = () => p(!0), f = () => p(!1), [m, y] = x.useState(!1), I = () => y(!0), R = () => y(!1), [E, Q] = x.useState(!1), W = () => Q(!0), be = () => Q(!1);
|
|
2529
2529
|
return /* @__PURE__ */ c(g, {
|
|
2530
2530
|
position: "apart",
|
|
2531
2531
|
pt: 0,
|
|
@@ -2622,13 +2622,13 @@ const va = D(function({
|
|
|
2622
2622
|
function ya() {
|
|
2623
2623
|
const {
|
|
2624
2624
|
freezeLayout: t
|
|
2625
|
-
} = x.useContext(
|
|
2625
|
+
} = x.useContext(_e), [e, n] = x.useState(!1), {
|
|
2626
2626
|
panel: a
|
|
2627
2627
|
} = he();
|
|
2628
2628
|
return x.useEffect(() => {
|
|
2629
2629
|
t(e);
|
|
2630
2630
|
}, [e]), !a.description || a.description === "<p><br></p>" ? null : /* @__PURE__ */ c(Y, {
|
|
2631
|
-
children: [/* @__PURE__ */ r(
|
|
2631
|
+
children: [/* @__PURE__ */ r(we, {
|
|
2632
2632
|
opened: e,
|
|
2633
2633
|
onClose: () => n(!1),
|
|
2634
2634
|
title: a.title,
|
|
@@ -2768,14 +2768,14 @@ const Ls = D((t) => {
|
|
|
2768
2768
|
operationId: o,
|
|
2769
2769
|
instance: s,
|
|
2770
2770
|
variables: l
|
|
2771
|
-
} = t, u =
|
|
2771
|
+
} = t, u = Pe(() => new Os(i, s), [i, s]);
|
|
2772
2772
|
return ft(async () => {
|
|
2773
2773
|
await u.configOperation(o, l);
|
|
2774
2774
|
}, [o, u]), Fs(u) ? /* @__PURE__ */ c(Y, {
|
|
2775
2775
|
children: [/* @__PURE__ */ r(Ps, {
|
|
2776
2776
|
model: u,
|
|
2777
2777
|
onClick: n
|
|
2778
|
-
}), /* @__PURE__ */ r(
|
|
2778
|
+
}), /* @__PURE__ */ r(we, {
|
|
2779
2779
|
opened: e,
|
|
2780
2780
|
onClose: a,
|
|
2781
2781
|
title: "Operation Settings",
|
|
@@ -2821,7 +2821,7 @@ function $s(t) {
|
|
|
2821
2821
|
return !!t.triggerId && !!t.triggerSchema;
|
|
2822
2822
|
}
|
|
2823
2823
|
function Ns(t, e) {
|
|
2824
|
-
return
|
|
2824
|
+
return Pe(() => new qs(t, e), [t, e]);
|
|
2825
2825
|
}
|
|
2826
2826
|
const Bs = D(({
|
|
2827
2827
|
model: t,
|
|
@@ -2868,7 +2868,7 @@ const Bs = D(({
|
|
|
2868
2868
|
setFalse: a
|
|
2869
2869
|
}] = mt(!1), i = t.model;
|
|
2870
2870
|
return /* @__PURE__ */ c(Y, {
|
|
2871
|
-
children: [/* @__PURE__ */ r(
|
|
2871
|
+
children: [/* @__PURE__ */ r(we, {
|
|
2872
2872
|
opened: e,
|
|
2873
2873
|
onClose: a,
|
|
2874
2874
|
title: "Setup Trigger",
|
|
@@ -3285,11 +3285,11 @@ function sl({
|
|
|
3285
3285
|
handleSubmit: o,
|
|
3286
3286
|
watch: s,
|
|
3287
3287
|
getValues: l
|
|
3288
|
-
} =
|
|
3288
|
+
} = ke({
|
|
3289
3289
|
defaultValues: a
|
|
3290
3290
|
});
|
|
3291
3291
|
s("content");
|
|
3292
|
-
const u = l(), p = M(() => !
|
|
3292
|
+
const u = l(), p = M(() => !De(u, e), [u, e]), h = _a(e == null ? void 0 : e.content);
|
|
3293
3293
|
return /* @__PURE__ */ r(w, {
|
|
3294
3294
|
mt: "md",
|
|
3295
3295
|
spacing: "xs",
|
|
@@ -3479,7 +3479,7 @@ function hl({
|
|
|
3479
3479
|
sx: {
|
|
3480
3480
|
flexGrow: 1
|
|
3481
3481
|
}
|
|
3482
|
-
}), /* @__PURE__ */ r(
|
|
3482
|
+
}), /* @__PURE__ */ r(Fe, {
|
|
3483
3483
|
label: /* @__PURE__ */ c(w, {
|
|
3484
3484
|
spacing: 0,
|
|
3485
3485
|
children: [/* @__PURE__ */ r(v, {
|
|
@@ -3510,7 +3510,7 @@ function hl({
|
|
|
3510
3510
|
})]
|
|
3511
3511
|
}), /* @__PURE__ */ c(g, {
|
|
3512
3512
|
grow: !0,
|
|
3513
|
-
children: [/* @__PURE__ */ r(
|
|
3513
|
+
children: [/* @__PURE__ */ r(Ce, {
|
|
3514
3514
|
label: "Mantissa",
|
|
3515
3515
|
defaultValue: 0,
|
|
3516
3516
|
min: 0,
|
|
@@ -3518,7 +3518,7 @@ function hl({
|
|
|
3518
3518
|
max: 4,
|
|
3519
3519
|
value: t.mantissa,
|
|
3520
3520
|
onChange: i
|
|
3521
|
-
}), /* @__PURE__ */ r(
|
|
3521
|
+
}), /* @__PURE__ */ r(Fe, {
|
|
3522
3522
|
label: "Trim mantissa",
|
|
3523
3523
|
checked: t.trimMantissa,
|
|
3524
3524
|
onChange: o,
|
|
@@ -3640,7 +3640,7 @@ function ml({
|
|
|
3640
3640
|
data: pl,
|
|
3641
3641
|
value: e.type,
|
|
3642
3642
|
onChange: i
|
|
3643
|
-
}), e.type === "quantile" && /* @__PURE__ */ r(
|
|
3643
|
+
}), e.type === "quantile" && /* @__PURE__ */ r(Ce, {
|
|
3644
3644
|
label: "p",
|
|
3645
3645
|
value: e.config.p,
|
|
3646
3646
|
onChange: o,
|
|
@@ -3749,7 +3749,7 @@ function yl({
|
|
|
3749
3749
|
}, n) {
|
|
3750
3750
|
const {
|
|
3751
3751
|
colorManager: a
|
|
3752
|
-
} = Me(
|
|
3752
|
+
} = Me(Te), i = x.useMemo(() => a.getStaticColors().map((l) => ({
|
|
3753
3753
|
label: l.name,
|
|
3754
3754
|
group: l.category,
|
|
3755
3755
|
value: l.value
|
|
@@ -3793,7 +3793,7 @@ function yl({
|
|
|
3793
3793
|
})]
|
|
3794
3794
|
});
|
|
3795
3795
|
}
|
|
3796
|
-
const
|
|
3796
|
+
const Ae = x.forwardRef(yl), It = [{
|
|
3797
3797
|
label: "initial",
|
|
3798
3798
|
value: 0
|
|
3799
3799
|
}, {
|
|
@@ -3947,7 +3947,7 @@ const Sl = x.forwardRef(wl), _l = x.forwardRef(function({
|
|
|
3947
3947
|
}],
|
|
3948
3948
|
value: e.color.type,
|
|
3949
3949
|
onChange: (s) => o("color.type", s)
|
|
3950
|
-
}), i === "static" && /* @__PURE__ */ r(
|
|
3950
|
+
}), i === "static" && /* @__PURE__ */ r(Ae, {
|
|
3951
3951
|
value: e.color.staticColor,
|
|
3952
3952
|
onChange: (s) => o("color.staticColor", s)
|
|
3953
3953
|
}), i === "continuous" && /* @__PURE__ */ c(Y, {
|
|
@@ -4083,7 +4083,7 @@ const Vn = (t, e) => (n) => Boolean(bt(n) && Rl.test(n) && n.startsWith(t) || e
|
|
|
4083
4083
|
test: Vn("hsl", "hue"),
|
|
4084
4084
|
parse: Ta("hue", "saturation", "lightness"),
|
|
4085
4085
|
transform: ({ hue: t, saturation: e, lightness: n, alpha: a = 1 }) => "hsla(" + Math.round(t) + ", " + dt.transform(ut(e)) + ", " + dt.transform(ut(n)) + ", " + ut(ka.transform(a)) + ")"
|
|
4086
|
-
}, Tl = Ra(0, 255), tn = Object.assign(Object.assign({}, Nt), { transform: (t) => Math.round(Tl(t)) }),
|
|
4086
|
+
}, Tl = Ra(0, 255), tn = Object.assign(Object.assign({}, Nt), { transform: (t) => Math.round(Tl(t)) }), Ee = {
|
|
4087
4087
|
test: Vn("rgb", "red"),
|
|
4088
4088
|
parse: Ta("red", "green", "blue"),
|
|
4089
4089
|
transform: ({ red: t, green: e, blue: n, alpha: a = 1 }) => "rgba(" + tn.transform(t) + ", " + tn.transform(e) + ", " + tn.transform(n) + ", " + ut(ka.transform(a)) + ")"
|
|
@@ -4100,11 +4100,11 @@ function Vl(t) {
|
|
|
4100
4100
|
const ln = {
|
|
4101
4101
|
test: Vn("#"),
|
|
4102
4102
|
parse: Vl,
|
|
4103
|
-
transform:
|
|
4103
|
+
transform: Ee.transform
|
|
4104
4104
|
}, Bt = {
|
|
4105
|
-
test: (t) =>
|
|
4106
|
-
parse: (t) =>
|
|
4107
|
-
transform: (t) => bt(t) ? t : t.hasOwnProperty("red") ?
|
|
4105
|
+
test: (t) => Ee.test(t) || ln.test(t) || Ne.test(t),
|
|
4106
|
+
parse: (t) => Ee.test(t) ? Ee.parse(t) : Ne.test(t) ? Ne.parse(t) : ln.parse(t),
|
|
4107
|
+
transform: (t) => bt(t) ? t : t.hasOwnProperty("red") ? Ee.transform(t) : Ne.transform(t)
|
|
4108
4108
|
}, Va = "${c}", za = "${n}";
|
|
4109
4109
|
function zl(t) {
|
|
4110
4110
|
var e, n, a, i;
|
|
@@ -4159,11 +4159,11 @@ function xr({ hue: t, saturation: e, lightness: n, alpha: a }) {
|
|
|
4159
4159
|
const Fl = (t, e, n) => {
|
|
4160
4160
|
const a = t * t, i = e * e;
|
|
4161
4161
|
return Math.sqrt(Math.max(0, n * (i - a) + a));
|
|
4162
|
-
}, Pl = [ln,
|
|
4162
|
+
}, Pl = [ln, Ee, Ne], Cr = (t) => Pl.find((e) => e.test(t)), wr = (t) => `'${t}' is not an animatable color. Use the equivalent color code instead.`, Aa = (t, e) => {
|
|
4163
4163
|
let n = Cr(t), a = Cr(e);
|
|
4164
4164
|
pt(!!n, wr(t)), pt(!!a, wr(e));
|
|
4165
4165
|
let i = n.parse(t), o = a.parse(e);
|
|
4166
|
-
n === Ne && (i = xr(i), n =
|
|
4166
|
+
n === Ne && (i = xr(i), n = Ee), a === Ne && (o = xr(o), a = Ee);
|
|
4167
4167
|
const s = Object.assign({}, i);
|
|
4168
4168
|
return (l) => {
|
|
4169
4169
|
for (const u in s)
|
|
@@ -4406,7 +4406,7 @@ function ec({
|
|
|
4406
4406
|
fields: a,
|
|
4407
4407
|
append: i,
|
|
4408
4408
|
remove: o
|
|
4409
|
-
} =
|
|
4409
|
+
} = Se({
|
|
4410
4410
|
control: t,
|
|
4411
4411
|
name: "variables"
|
|
4412
4412
|
}), s = e("variables"), l = a.map((p, h) => ({
|
|
@@ -4452,7 +4452,7 @@ function tc({
|
|
|
4452
4452
|
watch: l,
|
|
4453
4453
|
getValues: u,
|
|
4454
4454
|
reset: p
|
|
4455
|
-
} =
|
|
4455
|
+
} = ke({
|
|
4456
4456
|
defaultValues: i
|
|
4457
4457
|
});
|
|
4458
4458
|
x.useEffect(() => {
|
|
@@ -4524,7 +4524,7 @@ const nc = {
|
|
|
4524
4524
|
viewRender: Kl,
|
|
4525
4525
|
configRender: tc
|
|
4526
4526
|
};
|
|
4527
|
-
var
|
|
4527
|
+
var Oe = /* @__PURE__ */ ((t) => (t.string = "string", t.number = "number", t.eloc = "eloc", t.percentage = "percentage", t))(Oe || {});
|
|
4528
4528
|
const Tt = {
|
|
4529
4529
|
columns: [],
|
|
4530
4530
|
fontSize: "1rem",
|
|
@@ -4537,7 +4537,7 @@ const Tt = {
|
|
|
4537
4537
|
}, rc = ({
|
|
4538
4538
|
vizManager: t,
|
|
4539
4539
|
instance: e
|
|
4540
|
-
}) =>
|
|
4540
|
+
}) => Pe(
|
|
4541
4541
|
() => new Xa(e, t.resolveComponent(e.type), Nn),
|
|
4542
4542
|
[e, t]
|
|
4543
4543
|
), ac = (t, e) => {
|
|
@@ -4793,19 +4793,19 @@ function Ic(t) {
|
|
|
4793
4793
|
}
|
|
4794
4794
|
function Dc(t) {
|
|
4795
4795
|
switch (t.type) {
|
|
4796
|
-
case
|
|
4796
|
+
case Oe.string:
|
|
4797
4797
|
return /* @__PURE__ */ r(wc, {
|
|
4798
4798
|
...t
|
|
4799
4799
|
});
|
|
4800
|
-
case
|
|
4800
|
+
case Oe.eloc:
|
|
4801
4801
|
return /* @__PURE__ */ r(Sc, {
|
|
4802
4802
|
...t
|
|
4803
4803
|
});
|
|
4804
|
-
case
|
|
4804
|
+
case Oe.number:
|
|
4805
4805
|
return /* @__PURE__ */ r(_c, {
|
|
4806
4806
|
...t
|
|
4807
4807
|
});
|
|
4808
|
-
case
|
|
4808
|
+
case Oe.percentage:
|
|
4809
4809
|
return /* @__PURE__ */ r(Ic, {
|
|
4810
4810
|
...t
|
|
4811
4811
|
});
|
|
@@ -4814,7 +4814,7 @@ function Dc(t) {
|
|
|
4814
4814
|
const Rc = (t) => {
|
|
4815
4815
|
const e = rc(t), n = ac(e.triggerManager, zn.id), {
|
|
4816
4816
|
colorManager: a
|
|
4817
|
-
} = Me(
|
|
4817
|
+
} = Me(Te);
|
|
4818
4818
|
return Rt((i) => new Tc(t.getColIndex, i, n, e, a), [n, e, t.getColIndex]);
|
|
4819
4819
|
};
|
|
4820
4820
|
function kc({
|
|
@@ -4837,16 +4837,16 @@ function kc({
|
|
|
4837
4837
|
} = vc(), f = x.useMemo(() => s ? Object.keys(n[0]).map((se) => ({
|
|
4838
4838
|
label: se,
|
|
4839
4839
|
value_field: se,
|
|
4840
|
-
value_type:
|
|
4840
|
+
value_type: Oe.string
|
|
4841
4841
|
})) : l, [s, l, n]), m = Rc({
|
|
4842
4842
|
getColIndex: Rt((se) => f.indexOf(se.column.columnDef.meta), [f]),
|
|
4843
4843
|
vizManager: t.vizManager,
|
|
4844
4844
|
instance: e
|
|
4845
4845
|
}), y = M(() => {
|
|
4846
4846
|
const se = _o(), ve = f.map((ce) => se.accessor(ce.value_field, {
|
|
4847
|
-
cell: (
|
|
4848
|
-
tableCellContext: m(
|
|
4849
|
-
value:
|
|
4847
|
+
cell: (Ve) => /* @__PURE__ */ r(Dc, {
|
|
4848
|
+
tableCellContext: m(Ve.cell),
|
|
4849
|
+
value: Ve.getValue(),
|
|
4850
4850
|
type: ce.value_type
|
|
4851
4851
|
}),
|
|
4852
4852
|
header: ce.label,
|
|
@@ -5085,7 +5085,7 @@ function Ec(t) {
|
|
|
5085
5085
|
})
|
|
5086
5086
|
}), /* @__PURE__ */ r(Zt.Dropdown, {
|
|
5087
5087
|
children: /* @__PURE__ */ c(w, {
|
|
5088
|
-
children: [/* @__PURE__ */ r(
|
|
5088
|
+
children: [/* @__PURE__ */ r(Ce, {
|
|
5089
5089
|
size: "xs",
|
|
5090
5090
|
label: "Map a value to this color",
|
|
5091
5091
|
value: s,
|
|
@@ -5134,7 +5134,7 @@ const Oc = D(({
|
|
|
5134
5134
|
}, a))
|
|
5135
5135
|
});
|
|
5136
5136
|
}), Fc = D(function(e) {
|
|
5137
|
-
const n =
|
|
5137
|
+
const n = Pe(() => new zc(), []);
|
|
5138
5138
|
return Z(() => {
|
|
5139
5139
|
n.fromProps(e);
|
|
5140
5140
|
}), n.interpolation == null ? null : /* @__PURE__ */ r(Oc, {
|
|
@@ -5176,7 +5176,7 @@ const Oc = D(({
|
|
|
5176
5176
|
variant: "outline",
|
|
5177
5177
|
onClick: p,
|
|
5178
5178
|
children: l == null ? void 0 : l.displayName
|
|
5179
|
-
}), /* @__PURE__ */ r(
|
|
5179
|
+
}), /* @__PURE__ */ r(we, {
|
|
5180
5180
|
size: 508,
|
|
5181
5181
|
title: "Setup color interpolation",
|
|
5182
5182
|
opened: u,
|
|
@@ -5229,7 +5229,7 @@ function qc(t, e) {
|
|
|
5229
5229
|
const $c = (t) => {
|
|
5230
5230
|
const {
|
|
5231
5231
|
colorManager: e
|
|
5232
|
-
} = Me(
|
|
5232
|
+
} = Me(Te), [n, a] = de(Qa(t.value)), [i, o] = de(Lc(e, t.value)), s = mr(i), [l, u] = de(qc(e, t.value)), p = mr(l);
|
|
5233
5233
|
return /* @__PURE__ */ c(g, {
|
|
5234
5234
|
align: "end",
|
|
5235
5235
|
children: [/* @__PURE__ */ r(q, {
|
|
@@ -5240,7 +5240,7 @@ const $c = (t) => {
|
|
|
5240
5240
|
a(y || "none"), y === "static" ? (I = t.onChange) == null || I.call(t, s.current) : y === "none" || !y ? (R = t.onChange) == null || R.call(t, "none") : (E = t.onChange) == null || E.call(t, p.current);
|
|
5241
5241
|
},
|
|
5242
5242
|
data: Ac
|
|
5243
|
-
}), n === "static" && /* @__PURE__ */ r(
|
|
5243
|
+
}), n === "static" && /* @__PURE__ */ r(Ae, {
|
|
5244
5244
|
value: i,
|
|
5245
5245
|
onChange: (y) => {
|
|
5246
5246
|
var I;
|
|
@@ -5255,7 +5255,7 @@ const $c = (t) => {
|
|
|
5255
5255
|
}
|
|
5256
5256
|
})]
|
|
5257
5257
|
});
|
|
5258
|
-
}, Nc = Object.values(
|
|
5258
|
+
}, Nc = Object.values(Oe).map((t) => ({
|
|
5259
5259
|
label: t,
|
|
5260
5260
|
value: t
|
|
5261
5261
|
}));
|
|
@@ -5289,7 +5289,7 @@ function jc({
|
|
|
5289
5289
|
const i = t.data || [], o = () => a.insertListItem("columns", {
|
|
5290
5290
|
label: ge(),
|
|
5291
5291
|
value_field: "value",
|
|
5292
|
-
value_type:
|
|
5292
|
+
value_type: Oe.string
|
|
5293
5293
|
});
|
|
5294
5294
|
return /* @__PURE__ */ r(w, {
|
|
5295
5295
|
mt: "md",
|
|
@@ -5380,12 +5380,12 @@ function jc({
|
|
|
5380
5380
|
}), /* @__PURE__ */ c(g, {
|
|
5381
5381
|
position: "apart",
|
|
5382
5382
|
grow: !0,
|
|
5383
|
-
children: [/* @__PURE__ */ r(
|
|
5383
|
+
children: [/* @__PURE__ */ r(Fe, {
|
|
5384
5384
|
label: "Striped",
|
|
5385
5385
|
...a.getInputProps("striped", {
|
|
5386
5386
|
type: "checkbox"
|
|
5387
5387
|
})
|
|
5388
|
-
}), /* @__PURE__ */ r(
|
|
5388
|
+
}), /* @__PURE__ */ r(Fe, {
|
|
5389
5389
|
label: "Highlight on hover",
|
|
5390
5390
|
...a.getInputProps("highlightOnHover", {
|
|
5391
5391
|
type: "checkbox"
|
|
@@ -5402,7 +5402,7 @@ function jc({
|
|
|
5402
5402
|
border: "1px solid #eee",
|
|
5403
5403
|
borderRadius: "5px"
|
|
5404
5404
|
},
|
|
5405
|
-
children: [/* @__PURE__ */ r(
|
|
5405
|
+
children: [/* @__PURE__ */ r(Fe, {
|
|
5406
5406
|
label: "Use Original Data Columns",
|
|
5407
5407
|
...a.getInputProps("use_raw_columns", {
|
|
5408
5408
|
type: "checkbox"
|
|
@@ -5900,7 +5900,7 @@ function nu({
|
|
|
5900
5900
|
control: o,
|
|
5901
5901
|
handleSubmit: s,
|
|
5902
5902
|
reset: l
|
|
5903
|
-
} =
|
|
5903
|
+
} = ke({
|
|
5904
5904
|
defaultValues: i
|
|
5905
5905
|
});
|
|
5906
5906
|
return Z(() => {
|
|
@@ -6254,7 +6254,7 @@ function lu({
|
|
|
6254
6254
|
fields: n,
|
|
6255
6255
|
append: a,
|
|
6256
6256
|
remove: i
|
|
6257
|
-
} =
|
|
6257
|
+
} = Se({
|
|
6258
6258
|
control: t,
|
|
6259
6259
|
name: "reference_lines"
|
|
6260
6260
|
}), o = e("reference_lines"), s = n.map((h, f) => ({
|
|
@@ -6333,7 +6333,7 @@ function uu({
|
|
|
6333
6333
|
fields: a,
|
|
6334
6334
|
append: i,
|
|
6335
6335
|
remove: o
|
|
6336
|
-
} =
|
|
6336
|
+
} = Se({
|
|
6337
6337
|
control: t,
|
|
6338
6338
|
name: "variables"
|
|
6339
6339
|
}), s = e("variables"), l = a.map((p, h) => ({
|
|
@@ -6368,13 +6368,13 @@ function du({
|
|
|
6368
6368
|
watch: l,
|
|
6369
6369
|
getValues: u,
|
|
6370
6370
|
reset: p
|
|
6371
|
-
} =
|
|
6371
|
+
} = ke({
|
|
6372
6372
|
defaultValues: i
|
|
6373
6373
|
});
|
|
6374
6374
|
Z(() => {
|
|
6375
6375
|
p(i);
|
|
6376
6376
|
}, [i]), l(["x_axis", "y_axis", "reference_lines", "color"]);
|
|
6377
|
-
const h = u(), f = M(() => !
|
|
6377
|
+
const h = u(), f = M(() => !De(h, e), [h, e]);
|
|
6378
6378
|
return /* @__PURE__ */ r(w, {
|
|
6379
6379
|
mt: "md",
|
|
6380
6380
|
spacing: "xs",
|
|
@@ -6484,7 +6484,7 @@ function du({
|
|
|
6484
6484
|
control: o,
|
|
6485
6485
|
render: ({
|
|
6486
6486
|
field: m
|
|
6487
|
-
}) => /* @__PURE__ */ r(
|
|
6487
|
+
}) => /* @__PURE__ */ r(Ae, {
|
|
6488
6488
|
...m
|
|
6489
6489
|
})
|
|
6490
6490
|
})]
|
|
@@ -6937,7 +6937,7 @@ function ku({
|
|
|
6937
6937
|
fields: n,
|
|
6938
6938
|
append: a,
|
|
6939
6939
|
remove: i
|
|
6940
|
-
} =
|
|
6940
|
+
} = Se({
|
|
6941
6941
|
control: t,
|
|
6942
6942
|
name: "reference_lines"
|
|
6943
6943
|
}), o = e("reference_lines"), s = n.map((h, f) => ({
|
|
@@ -7087,7 +7087,7 @@ function zu({
|
|
|
7087
7087
|
control: t,
|
|
7088
7088
|
render: ({
|
|
7089
7089
|
field: l
|
|
7090
|
-
}) => /* @__PURE__ */ r(
|
|
7090
|
+
}) => /* @__PURE__ */ r(Ce, {
|
|
7091
7091
|
label: "Order",
|
|
7092
7092
|
sx: {
|
|
7093
7093
|
flex: 1
|
|
@@ -7100,19 +7100,36 @@ function zu({
|
|
|
7100
7100
|
variant: "dashed",
|
|
7101
7101
|
label: "Line Style",
|
|
7102
7102
|
labelPosition: "center"
|
|
7103
|
-
}), /* @__PURE__ */
|
|
7104
|
-
|
|
7105
|
-
|
|
7106
|
-
|
|
7107
|
-
|
|
7108
|
-
|
|
7109
|
-
|
|
7110
|
-
|
|
7111
|
-
|
|
7112
|
-
|
|
7113
|
-
|
|
7114
|
-
|
|
7115
|
-
|
|
7103
|
+
}), /* @__PURE__ */ c(g, {
|
|
7104
|
+
grow: !0,
|
|
7105
|
+
children: [/* @__PURE__ */ r(S, {
|
|
7106
|
+
name: `regressions.${n}.plot.lineStyle.type`,
|
|
7107
|
+
control: t,
|
|
7108
|
+
render: ({
|
|
7109
|
+
field: l
|
|
7110
|
+
}) => /* @__PURE__ */ r(q, {
|
|
7111
|
+
label: "Line Type",
|
|
7112
|
+
data: Vu,
|
|
7113
|
+
sx: {
|
|
7114
|
+
flexGrow: 1
|
|
7115
|
+
},
|
|
7116
|
+
...l
|
|
7117
|
+
})
|
|
7118
|
+
}), /* @__PURE__ */ r(S, {
|
|
7119
|
+
name: `regressions.${n}.plot.lineStyle.width`,
|
|
7120
|
+
control: t,
|
|
7121
|
+
render: ({
|
|
7122
|
+
field: l
|
|
7123
|
+
}) => /* @__PURE__ */ r(Ce, {
|
|
7124
|
+
label: "Line Width",
|
|
7125
|
+
min: 1,
|
|
7126
|
+
max: 10,
|
|
7127
|
+
sx: {
|
|
7128
|
+
flexGrow: 1
|
|
7129
|
+
},
|
|
7130
|
+
...l
|
|
7131
|
+
})
|
|
7132
|
+
})]
|
|
7116
7133
|
}), /* @__PURE__ */ c(w, {
|
|
7117
7134
|
spacing: 4,
|
|
7118
7135
|
children: [/* @__PURE__ */ r(v, {
|
|
@@ -7123,7 +7140,7 @@ function zu({
|
|
|
7123
7140
|
control: t,
|
|
7124
7141
|
render: ({
|
|
7125
7142
|
field: l
|
|
7126
|
-
}) => /* @__PURE__ */ r(
|
|
7143
|
+
}) => /* @__PURE__ */ r(Ae, {
|
|
7127
7144
|
...l
|
|
7128
7145
|
})
|
|
7129
7146
|
})]
|
|
@@ -7151,7 +7168,7 @@ function Eu({
|
|
|
7151
7168
|
fields: a,
|
|
7152
7169
|
append: i,
|
|
7153
7170
|
remove: o
|
|
7154
|
-
} =
|
|
7171
|
+
} = Se({
|
|
7155
7172
|
control: t,
|
|
7156
7173
|
name: "regressions"
|
|
7157
7174
|
}), s = e("regressions"), l = a.map((f, m) => ({
|
|
@@ -7178,7 +7195,8 @@ function Eu({
|
|
|
7178
7195
|
yAxisIndex: 0,
|
|
7179
7196
|
color: "#666666",
|
|
7180
7197
|
lineStyle: {
|
|
7181
|
-
type: "solid"
|
|
7198
|
+
type: "solid",
|
|
7199
|
+
width: 1
|
|
7182
7200
|
}
|
|
7183
7201
|
}
|
|
7184
7202
|
});
|
|
@@ -7190,7 +7208,7 @@ function Eu({
|
|
|
7190
7208
|
remove: o,
|
|
7191
7209
|
yAxisOptions: p,
|
|
7192
7210
|
data: n
|
|
7193
|
-
})), /* @__PURE__ */ r(g, {
|
|
7211
|
+
}, m)), /* @__PURE__ */ r(g, {
|
|
7194
7212
|
position: "center",
|
|
7195
7213
|
mt: "xs",
|
|
7196
7214
|
children: /* @__PURE__ */ r(F, {
|
|
@@ -7289,19 +7307,36 @@ function Mu({
|
|
|
7289
7307
|
variant: "dashed",
|
|
7290
7308
|
label: "Line Settings",
|
|
7291
7309
|
labelPosition: "center"
|
|
7292
|
-
}), /* @__PURE__ */
|
|
7293
|
-
|
|
7294
|
-
|
|
7295
|
-
|
|
7296
|
-
|
|
7297
|
-
|
|
7298
|
-
|
|
7299
|
-
|
|
7300
|
-
|
|
7301
|
-
|
|
7302
|
-
|
|
7303
|
-
|
|
7304
|
-
|
|
7310
|
+
}), /* @__PURE__ */ c(g, {
|
|
7311
|
+
grow: !0,
|
|
7312
|
+
children: [/* @__PURE__ */ r(S, {
|
|
7313
|
+
name: `series.${e}.lineStyle.type`,
|
|
7314
|
+
control: t,
|
|
7315
|
+
render: ({
|
|
7316
|
+
field: n
|
|
7317
|
+
}) => /* @__PURE__ */ r(q, {
|
|
7318
|
+
label: "Line Type",
|
|
7319
|
+
data: Au,
|
|
7320
|
+
sx: {
|
|
7321
|
+
flexGrow: 1
|
|
7322
|
+
},
|
|
7323
|
+
...n
|
|
7324
|
+
})
|
|
7325
|
+
}), /* @__PURE__ */ r(S, {
|
|
7326
|
+
name: `series.${e}.lineStyle.width`,
|
|
7327
|
+
control: t,
|
|
7328
|
+
render: ({
|
|
7329
|
+
field: n
|
|
7330
|
+
}) => /* @__PURE__ */ r(Ce, {
|
|
7331
|
+
label: "Line Width",
|
|
7332
|
+
min: 1,
|
|
7333
|
+
max: 10,
|
|
7334
|
+
sx: {
|
|
7335
|
+
flexGrow: 1
|
|
7336
|
+
},
|
|
7337
|
+
...n
|
|
7338
|
+
})
|
|
7339
|
+
})]
|
|
7305
7340
|
}), /* @__PURE__ */ c(g, {
|
|
7306
7341
|
grow: !0,
|
|
7307
7342
|
align: "center",
|
|
@@ -7333,7 +7368,7 @@ function Mu({
|
|
|
7333
7368
|
sx: {
|
|
7334
7369
|
flexGrow: 1
|
|
7335
7370
|
},
|
|
7336
|
-
children: /* @__PURE__ */ r(
|
|
7371
|
+
children: /* @__PURE__ */ r(Fe, {
|
|
7337
7372
|
label: "Smooth Line",
|
|
7338
7373
|
checked: n.value,
|
|
7339
7374
|
onChange: (a) => n.onChange(a.currentTarget.checked)
|
|
@@ -7572,7 +7607,7 @@ function Nu({
|
|
|
7572
7607
|
control: t,
|
|
7573
7608
|
render: ({
|
|
7574
7609
|
field: l
|
|
7575
|
-
}) => /* @__PURE__ */ r(
|
|
7610
|
+
}) => /* @__PURE__ */ r(Ae, {
|
|
7576
7611
|
...l
|
|
7577
7612
|
})
|
|
7578
7613
|
})]
|
|
@@ -7600,7 +7635,7 @@ function Bu({
|
|
|
7600
7635
|
fields: a,
|
|
7601
7636
|
append: i,
|
|
7602
7637
|
remove: o
|
|
7603
|
-
} =
|
|
7638
|
+
} = Se({
|
|
7604
7639
|
control: t,
|
|
7605
7640
|
name: "series"
|
|
7606
7641
|
}), s = e("series"), l = a.map((f, m) => ({
|
|
@@ -7621,7 +7656,8 @@ function Bu({
|
|
|
7621
7656
|
barWidth: "10",
|
|
7622
7657
|
barGap: "0%",
|
|
7623
7658
|
lineStyle: {
|
|
7624
|
-
type: "solid"
|
|
7659
|
+
type: "solid",
|
|
7660
|
+
width: 1
|
|
7625
7661
|
}
|
|
7626
7662
|
}), p = e("y_axes"), h = x.useMemo(() => p.map(({
|
|
7627
7663
|
name: f
|
|
@@ -7695,7 +7731,7 @@ function Gu({
|
|
|
7695
7731
|
fields: a,
|
|
7696
7732
|
append: i,
|
|
7697
7733
|
remove: o
|
|
7698
|
-
} =
|
|
7734
|
+
} = Se({
|
|
7699
7735
|
control: t,
|
|
7700
7736
|
name: "stats.variables"
|
|
7701
7737
|
});
|
|
@@ -7798,7 +7834,7 @@ function Qu({
|
|
|
7798
7834
|
fields: a,
|
|
7799
7835
|
append: i,
|
|
7800
7836
|
remove: o
|
|
7801
|
-
} =
|
|
7837
|
+
} = Se({
|
|
7802
7838
|
control: t,
|
|
7803
7839
|
name: "variables"
|
|
7804
7840
|
}), s = e("variables"), l = a.map((p, h) => ({
|
|
@@ -7867,7 +7903,7 @@ function Yu({
|
|
|
7867
7903
|
control: e,
|
|
7868
7904
|
render: ({
|
|
7869
7905
|
field: a
|
|
7870
|
-
}) => /* @__PURE__ */ r(
|
|
7906
|
+
}) => /* @__PURE__ */ r(Ce, {
|
|
7871
7907
|
label: "Rotate",
|
|
7872
7908
|
hideControls: !0,
|
|
7873
7909
|
min: -90,
|
|
@@ -8019,7 +8055,7 @@ function Ju({
|
|
|
8019
8055
|
fields: n,
|
|
8020
8056
|
append: a,
|
|
8021
8057
|
remove: i
|
|
8022
|
-
} =
|
|
8058
|
+
} = Se({
|
|
8023
8059
|
control: t,
|
|
8024
8060
|
name: "y_axes"
|
|
8025
8061
|
}), o = e("y_axes"), s = n.map((u, p) => ({
|
|
@@ -8061,7 +8097,8 @@ function Ku(t) {
|
|
|
8061
8097
|
step: I = !1,
|
|
8062
8098
|
group_by_key: R = "",
|
|
8063
8099
|
lineStyle: E = {
|
|
8064
|
-
type: "solid"
|
|
8100
|
+
type: "solid",
|
|
8101
|
+
width: 1
|
|
8065
8102
|
}
|
|
8066
8103
|
}) {
|
|
8067
8104
|
return {
|
|
@@ -8112,7 +8149,7 @@ function td({
|
|
|
8112
8149
|
set: n
|
|
8113
8150
|
} = G(t.instanceData, "config"), a = t.data, i = M(() => Ge({}, e, An), [e]), o = M(() => ed(i), [i]);
|
|
8114
8151
|
Z(() => {
|
|
8115
|
-
!
|
|
8152
|
+
!De(i, o) && (console.log("config malformed, resetting to defaults", i, o), n(o));
|
|
8116
8153
|
}, [i, o]);
|
|
8117
8154
|
const {
|
|
8118
8155
|
control: s,
|
|
@@ -8120,13 +8157,13 @@ function td({
|
|
|
8120
8157
|
watch: u,
|
|
8121
8158
|
getValues: p,
|
|
8122
8159
|
reset: h
|
|
8123
|
-
} =
|
|
8160
|
+
} = ke({
|
|
8124
8161
|
defaultValues: o
|
|
8125
8162
|
});
|
|
8126
8163
|
Z(() => {
|
|
8127
8164
|
h(o);
|
|
8128
8165
|
}, [o]);
|
|
8129
|
-
const f = p(), m = M(() => !
|
|
8166
|
+
const f = p(), m = M(() => !De(f, i), [f, i]);
|
|
8130
8167
|
return /* @__PURE__ */ r(w, {
|
|
8131
8168
|
mt: "md",
|
|
8132
8169
|
spacing: "xs",
|
|
@@ -8471,7 +8508,7 @@ function cd({
|
|
|
8471
8508
|
control: t,
|
|
8472
8509
|
render: ({
|
|
8473
8510
|
field: i
|
|
8474
|
-
}) => /* @__PURE__ */ r(
|
|
8511
|
+
}) => /* @__PURE__ */ r(Ce, {
|
|
8475
8512
|
label: "Max",
|
|
8476
8513
|
hideControls: !0,
|
|
8477
8514
|
required: !0,
|
|
@@ -8521,7 +8558,7 @@ function ud({
|
|
|
8521
8558
|
fields: a,
|
|
8522
8559
|
append: i,
|
|
8523
8560
|
remove: o
|
|
8524
|
-
} =
|
|
8561
|
+
} = Se({
|
|
8525
8562
|
control: t,
|
|
8526
8563
|
name: "dimensions"
|
|
8527
8564
|
}), s = e("dimensions"), l = a.map((p, h) => ({
|
|
@@ -8579,7 +8616,7 @@ function hd({
|
|
|
8579
8616
|
series_name_key: s
|
|
8580
8617
|
}), [o, s]);
|
|
8581
8618
|
Z(() => {
|
|
8582
|
-
!
|
|
8619
|
+
!De(i, l) && a(l);
|
|
8583
8620
|
}, [i, l]);
|
|
8584
8621
|
const {
|
|
8585
8622
|
control: u,
|
|
@@ -8587,13 +8624,13 @@ function hd({
|
|
|
8587
8624
|
watch: h,
|
|
8588
8625
|
getValues: f,
|
|
8589
8626
|
reset: m
|
|
8590
|
-
} =
|
|
8627
|
+
} = ke({
|
|
8591
8628
|
defaultValues: l
|
|
8592
8629
|
});
|
|
8593
8630
|
Z(() => {
|
|
8594
|
-
|
|
8631
|
+
De(f(), l) || m(l);
|
|
8595
8632
|
}, [i]), h(["series_name_key"]);
|
|
8596
|
-
const y = f(), I = M(() => !
|
|
8633
|
+
const y = f(), I = M(() => !De(y, i), [y, i]);
|
|
8597
8634
|
return /* @__PURE__ */ r(w, {
|
|
8598
8635
|
mt: "md",
|
|
8599
8636
|
spacing: "xs",
|
|
@@ -8667,13 +8704,13 @@ const md = {
|
|
|
8667
8704
|
function fd(t, e) {
|
|
8668
8705
|
switch (t.config.method) {
|
|
8669
8706
|
case "linear":
|
|
8670
|
-
return [...
|
|
8707
|
+
return [...ze.regressionLinear()(e)];
|
|
8671
8708
|
case "exponential":
|
|
8672
|
-
return [...
|
|
8709
|
+
return [...ze.regressionExp()(e)];
|
|
8673
8710
|
case "logarithmic":
|
|
8674
|
-
return [...
|
|
8711
|
+
return [...ze.regressionLog()(e)];
|
|
8675
8712
|
case "polynomial":
|
|
8676
|
-
return [...
|
|
8713
|
+
return [...ze.regressionPoly().order(t.config.order)(e)];
|
|
8677
8714
|
default:
|
|
8678
8715
|
return [];
|
|
8679
8716
|
}
|
|
@@ -8758,7 +8795,7 @@ function yd(t, e) {
|
|
|
8758
8795
|
y_axis: i
|
|
8759
8796
|
} = e, o = t.map((s) => [s[a.data_key], s[n.y_axis_data_key]]);
|
|
8760
8797
|
if (n.transform.config.method === "linear") {
|
|
8761
|
-
const s =
|
|
8798
|
+
const s = ze.regressionLinear()(o), {
|
|
8762
8799
|
a: l,
|
|
8763
8800
|
b: u,
|
|
8764
8801
|
rSquared: p
|
|
@@ -8797,7 +8834,7 @@ function yd(t, e) {
|
|
|
8797
8834
|
a: s,
|
|
8798
8835
|
b: l,
|
|
8799
8836
|
rSquared: u
|
|
8800
|
-
} =
|
|
8837
|
+
} = ze.regressionExp()(o);
|
|
8801
8838
|
return {
|
|
8802
8839
|
expression: /* @__PURE__ */ c(g, {
|
|
8803
8840
|
position: "center",
|
|
@@ -8841,7 +8878,7 @@ function yd(t, e) {
|
|
|
8841
8878
|
a: s,
|
|
8842
8879
|
b: l,
|
|
8843
8880
|
rSquared: u
|
|
8844
|
-
} =
|
|
8881
|
+
} = ze.regressionLog()(o);
|
|
8845
8882
|
return {
|
|
8846
8883
|
expression: /* @__PURE__ */ c(g, {
|
|
8847
8884
|
position: "center",
|
|
@@ -8881,7 +8918,7 @@ function yd(t, e) {
|
|
|
8881
8918
|
};
|
|
8882
8919
|
}
|
|
8883
8920
|
if (n.transform.config.method === "polynomial") {
|
|
8884
|
-
const s =
|
|
8921
|
+
const s = ze.regressionPoly().order(n.transform.config.order)(o), {
|
|
8885
8922
|
rSquared: l
|
|
8886
8923
|
} = s;
|
|
8887
8924
|
return console.log(s), {
|
|
@@ -8917,7 +8954,8 @@ const Ln = {
|
|
|
8917
8954
|
yAxisIndex: 0,
|
|
8918
8955
|
color: "#228be6",
|
|
8919
8956
|
lineStyle: {
|
|
8920
|
-
type: "solid"
|
|
8957
|
+
type: "solid",
|
|
8958
|
+
width: 1
|
|
8921
8959
|
}
|
|
8922
8960
|
},
|
|
8923
8961
|
name: "regression",
|
|
@@ -9084,7 +9122,7 @@ function wd({
|
|
|
9084
9122
|
control: t,
|
|
9085
9123
|
render: ({
|
|
9086
9124
|
field: i
|
|
9087
|
-
}) => /* @__PURE__ */ r(
|
|
9125
|
+
}) => /* @__PURE__ */ r(Ce, {
|
|
9088
9126
|
label: "Order",
|
|
9089
9127
|
sx: {
|
|
9090
9128
|
flex: 1
|
|
@@ -9102,7 +9140,7 @@ function wd({
|
|
|
9102
9140
|
control: t,
|
|
9103
9141
|
render: ({
|
|
9104
9142
|
field: i
|
|
9105
|
-
}) => /* @__PURE__ */ r(
|
|
9143
|
+
}) => /* @__PURE__ */ r(Ae, {
|
|
9106
9144
|
...i
|
|
9107
9145
|
})
|
|
9108
9146
|
})]
|
|
@@ -9121,13 +9159,13 @@ function Sd({
|
|
|
9121
9159
|
watch: l,
|
|
9122
9160
|
getValues: u,
|
|
9123
9161
|
reset: p
|
|
9124
|
-
} =
|
|
9162
|
+
} = ke({
|
|
9125
9163
|
defaultValues: i
|
|
9126
9164
|
});
|
|
9127
9165
|
Z(() => {
|
|
9128
9166
|
p(i);
|
|
9129
9167
|
}, [i]), l(["x_axis", "y_axis", "regression"]);
|
|
9130
|
-
const h = u(), f = M(() => !
|
|
9168
|
+
const h = u(), f = M(() => !De(h, e), [h, e]);
|
|
9131
9169
|
return /* @__PURE__ */ r(w, {
|
|
9132
9170
|
mt: "md",
|
|
9133
9171
|
spacing: "xs",
|
|
@@ -9364,6 +9402,10 @@ function kd({
|
|
|
9364
9402
|
itemStyle: {
|
|
9365
9403
|
color: u.color
|
|
9366
9404
|
},
|
|
9405
|
+
symbolSize: 2,
|
|
9406
|
+
lineStyle: {
|
|
9407
|
+
width: 1
|
|
9408
|
+
},
|
|
9367
9409
|
label: {
|
|
9368
9410
|
show: !0,
|
|
9369
9411
|
position: "top",
|
|
@@ -9394,13 +9436,13 @@ function Td({
|
|
|
9394
9436
|
watch: l,
|
|
9395
9437
|
getValues: u,
|
|
9396
9438
|
reset: p
|
|
9397
|
-
} =
|
|
9439
|
+
} = ke({
|
|
9398
9440
|
defaultValues: i
|
|
9399
9441
|
});
|
|
9400
9442
|
Z(() => {
|
|
9401
9443
|
p(i);
|
|
9402
9444
|
}, [i]), l(["x_axis", "data_key", "bar", "line"]);
|
|
9403
|
-
const h = u(), f = M(() => !
|
|
9445
|
+
const h = u(), f = M(() => !De(h, e), [h, e]);
|
|
9404
9446
|
return /* @__PURE__ */ r(w, {
|
|
9405
9447
|
mt: "md",
|
|
9406
9448
|
spacing: "xs",
|
|
@@ -9499,7 +9541,7 @@ function Td({
|
|
|
9499
9541
|
control: o,
|
|
9500
9542
|
render: ({
|
|
9501
9543
|
field: m
|
|
9502
|
-
}) => /* @__PURE__ */ r(
|
|
9544
|
+
}) => /* @__PURE__ */ r(Ae, {
|
|
9503
9545
|
...m
|
|
9504
9546
|
})
|
|
9505
9547
|
})]
|
|
@@ -9533,7 +9575,7 @@ function Td({
|
|
|
9533
9575
|
control: o,
|
|
9534
9576
|
render: ({
|
|
9535
9577
|
field: m
|
|
9536
|
-
}) => /* @__PURE__ */ r(
|
|
9578
|
+
}) => /* @__PURE__ */ r(Ae, {
|
|
9537
9579
|
...m
|
|
9538
9580
|
})
|
|
9539
9581
|
})]
|
|
@@ -9626,7 +9668,7 @@ const zd = {
|
|
|
9626
9668
|
vizManager: t,
|
|
9627
9669
|
colorManager: e
|
|
9628
9670
|
};
|
|
9629
|
-
},
|
|
9671
|
+
}, Te = Yi(Ha());
|
|
9630
9672
|
try {
|
|
9631
9673
|
lt.install(Ua);
|
|
9632
9674
|
} catch {
|
|
@@ -9674,7 +9716,7 @@ function Pd(t) {
|
|
|
9674
9716
|
value: e.urlTemplate,
|
|
9675
9717
|
onChange: s,
|
|
9676
9718
|
onBlur: i
|
|
9677
|
-
}), /* @__PURE__ */ r(
|
|
9719
|
+
}), /* @__PURE__ */ r(Fe, {
|
|
9678
9720
|
label: "Open in new Tab",
|
|
9679
9721
|
checked: e.openInNewTab,
|
|
9680
9722
|
onChange: (l) => o(l.currentTarget.checked)
|
|
@@ -9960,7 +10002,7 @@ const Qd = D(({
|
|
|
9960
10002
|
data: e
|
|
9961
10003
|
} = he(), n = t.viz, {
|
|
9962
10004
|
vizManager: a
|
|
9963
|
-
} = Me(
|
|
10005
|
+
} = Me(Te), i = t.json, o = Pe(() => a.getOrCreateInstance(i), [a, n.type]), s = Pe(() => new Xa(o, a.resolveComponent(n.type), Nn), [o, n.type]);
|
|
9964
10006
|
return Z(() => o.instanceData.watchItem(
|
|
9965
10007
|
null,
|
|
9966
10008
|
ao((l) => {
|
|
@@ -10025,7 +10067,7 @@ const Qd = D(({
|
|
|
10025
10067
|
style: e
|
|
10026
10068
|
} = t;
|
|
10027
10069
|
return /* @__PURE__ */ r(Y, {
|
|
10028
|
-
children: /* @__PURE__ */ r(
|
|
10070
|
+
children: /* @__PURE__ */ r(Fe, {
|
|
10029
10071
|
label: "Border",
|
|
10030
10072
|
checked: e.border.enabled,
|
|
10031
10073
|
onChange: (n) => e.border.setEnabled(n.currentTarget.checked)
|
|
@@ -10192,7 +10234,7 @@ const th = D(function() {
|
|
|
10192
10234
|
});
|
|
10193
10235
|
});
|
|
10194
10236
|
function Ja(t, e, n) {
|
|
10195
|
-
const a =
|
|
10237
|
+
const a = Pe(() => /* @__PURE__ */ new Set(), []), i = t.resolveComponent(e.type), [o, s] = de(!1);
|
|
10196
10238
|
return ft(async () => {
|
|
10197
10239
|
if (await i.migrator.needMigration(e) && !a.has(e.id))
|
|
10198
10240
|
try {
|
|
@@ -10246,7 +10288,7 @@ function rh(t) {
|
|
|
10246
10288
|
function ah(t, e) {
|
|
10247
10289
|
const {
|
|
10248
10290
|
vizManager: n
|
|
10249
|
-
} = Me(
|
|
10291
|
+
} = Me(Te), {
|
|
10250
10292
|
panel: {
|
|
10251
10293
|
viz: a,
|
|
10252
10294
|
title: i,
|
|
@@ -10338,7 +10380,7 @@ const dn = [];
|
|
|
10338
10380
|
function sh() {
|
|
10339
10381
|
const {
|
|
10340
10382
|
vizManager: t
|
|
10341
|
-
} = Me(
|
|
10383
|
+
} = Me(Te);
|
|
10342
10384
|
return M(() => t.availableVizList.map((e) => ({
|
|
10343
10385
|
value: e.name,
|
|
10344
10386
|
label: e.displayName
|
|
@@ -10367,7 +10409,7 @@ function ch() {
|
|
|
10367
10409
|
}
|
|
10368
10410
|
} = he(), {
|
|
10369
10411
|
vizManager: h
|
|
10370
|
-
} = Me(
|
|
10412
|
+
} = Me(Te), f = {
|
|
10371
10413
|
title: n,
|
|
10372
10414
|
description: i,
|
|
10373
10415
|
viz: e,
|
|
@@ -10399,7 +10441,7 @@ function uh() {
|
|
|
10399
10441
|
}
|
|
10400
10442
|
} = he(), [n, a] = Wr(e.type), i = e.type !== n, {
|
|
10401
10443
|
vizManager: o
|
|
10402
|
-
} = Me(
|
|
10444
|
+
} = Me(Te), s = x.useCallback(() => {
|
|
10403
10445
|
if (!i)
|
|
10404
10446
|
return;
|
|
10405
10447
|
const y = lh(o, n);
|
|
@@ -10473,7 +10515,7 @@ const hh = D(function({
|
|
|
10473
10515
|
}) {
|
|
10474
10516
|
const {
|
|
10475
10517
|
freezeLayout: a
|
|
10476
|
-
} = x.useContext(
|
|
10518
|
+
} = x.useContext(_e), [i, o] = de("Visualization"), {
|
|
10477
10519
|
panel: s,
|
|
10478
10520
|
loading: l
|
|
10479
10521
|
} = he(), {
|
|
@@ -10482,7 +10524,7 @@ const hh = D(function({
|
|
|
10482
10524
|
} = s;
|
|
10483
10525
|
return x.useEffect(() => {
|
|
10484
10526
|
a(e);
|
|
10485
|
-
}, [e]), /* @__PURE__ */ r(
|
|
10527
|
+
}, [e]), /* @__PURE__ */ r(we, {
|
|
10486
10528
|
size: "96vw",
|
|
10487
10529
|
overflow: "inside",
|
|
10488
10530
|
opened: e,
|
|
@@ -10561,7 +10603,7 @@ const hh = D(function({
|
|
|
10561
10603
|
queryID: p
|
|
10562
10604
|
} = l, {
|
|
10563
10605
|
inEditMode: h
|
|
10564
|
-
} = x.useContext(
|
|
10606
|
+
} = x.useContext(_e), f = () => e.queries.refetchDataByQueryID(p), {
|
|
10565
10607
|
viewPanelInFullScreen: m,
|
|
10566
10608
|
inFullScreen: y
|
|
10567
10609
|
} = x.useContext(Cn), I = () => {
|
|
@@ -10892,7 +10934,7 @@ const vh = x.forwardRef(({
|
|
|
10892
10934
|
})), Ih = D(({
|
|
10893
10935
|
children: t,
|
|
10894
10936
|
view: e
|
|
10895
|
-
}) => /* @__PURE__ */ r(
|
|
10937
|
+
}) => /* @__PURE__ */ r(we, {
|
|
10896
10938
|
size: e.config.width,
|
|
10897
10939
|
overflow: "inside",
|
|
10898
10940
|
opened: !0,
|
|
@@ -10929,12 +10971,12 @@ const vh = x.forwardRef(({
|
|
|
10929
10971
|
children: e
|
|
10930
10972
|
}) => {
|
|
10931
10973
|
switch (t.type) {
|
|
10932
|
-
case
|
|
10974
|
+
case Re.Modal:
|
|
10933
10975
|
return /* @__PURE__ */ r(Ih, {
|
|
10934
10976
|
view: t,
|
|
10935
10977
|
children: e
|
|
10936
10978
|
});
|
|
10937
|
-
case
|
|
10979
|
+
case Re.Division:
|
|
10938
10980
|
default:
|
|
10939
10981
|
return /* @__PURE__ */ r(_h, {
|
|
10940
10982
|
children: e
|
|
@@ -11726,7 +11768,7 @@ const li = b.model("QueryModel", {
|
|
|
11726
11768
|
t.name = e;
|
|
11727
11769
|
},
|
|
11728
11770
|
setType(e) {
|
|
11729
|
-
t.type !== e && (e ===
|
|
11771
|
+
t.type !== e && (e === Re.Modal ? t.config = {
|
|
11730
11772
|
width: "600px",
|
|
11731
11773
|
height: "400px"
|
|
11732
11774
|
} : t.config = {}, t.type = e);
|
|
@@ -11823,7 +11865,7 @@ const li = b.model("QueryModel", {
|
|
|
11823
11865
|
})).actions((t) => ({
|
|
11824
11866
|
addARandomNewView() {
|
|
11825
11867
|
const e = ge();
|
|
11826
|
-
t.addANewView(e,
|
|
11868
|
+
t.addANewView(e, Re.Division, {}), t.setIDOfVIE(e);
|
|
11827
11869
|
},
|
|
11828
11870
|
removeVIE() {
|
|
11829
11871
|
t.current.length !== 1 && (t.removeByID(t.idOfVIE), t.setIDOfVIE(t.current[0].id));
|
|
@@ -11927,11 +11969,11 @@ const Vp = D(function({
|
|
|
11927
11969
|
}
|
|
11928
11970
|
};
|
|
11929
11971
|
await a(I);
|
|
11930
|
-
}, h =
|
|
11972
|
+
}, h = Pe(Ha, []);
|
|
11931
11973
|
return /* @__PURE__ */ r(zr, {
|
|
11932
11974
|
children: /* @__PURE__ */ r(ra, {
|
|
11933
11975
|
value: u,
|
|
11934
|
-
children: /* @__PURE__ */ r(
|
|
11976
|
+
children: /* @__PURE__ */ r(_e.Provider, {
|
|
11935
11977
|
value: {
|
|
11936
11978
|
layoutFrozen: s,
|
|
11937
11979
|
freezeLayout: l,
|
|
@@ -11943,7 +11985,7 @@ const Vp = D(function({
|
|
|
11943
11985
|
sx: {
|
|
11944
11986
|
position: "relative"
|
|
11945
11987
|
},
|
|
11946
|
-
children: /* @__PURE__ */ r(
|
|
11988
|
+
children: /* @__PURE__ */ r(Te.Provider, {
|
|
11947
11989
|
value: h,
|
|
11948
11990
|
children: u.views.visibleViews.map((f) => /* @__PURE__ */ r(Rh, {
|
|
11949
11991
|
view: f,
|
|
@@ -11968,7 +12010,7 @@ function zp({
|
|
|
11968
12010
|
}, [t]), /* @__PURE__ */ r(zr, {
|
|
11969
12011
|
children: /* @__PURE__ */ r(ra, {
|
|
11970
12012
|
value: i,
|
|
11971
|
-
children: /* @__PURE__ */ r(
|
|
12013
|
+
children: /* @__PURE__ */ r(_e.Provider, {
|
|
11972
12014
|
value: {
|
|
11973
12015
|
layoutFrozen: !0,
|
|
11974
12016
|
freezeLayout: B.noop,
|
|
@@ -11990,10 +12032,10 @@ export {
|
|
|
11990
12032
|
Vp as Dashboard,
|
|
11991
12033
|
ws as DashboardFilterType,
|
|
11992
12034
|
Cs as DashboardMode,
|
|
11993
|
-
|
|
12035
|
+
Re as EViewComponentType,
|
|
11994
12036
|
Rr as FilterModel,
|
|
11995
12037
|
Fh as FiltersModel,
|
|
11996
|
-
|
|
12038
|
+
_e as LayoutStateContext,
|
|
11997
12039
|
Rh as MainDashboardView,
|
|
11998
12040
|
ra as ModelContextProvider,
|
|
11999
12041
|
Bn as Panel,
|