@devtable/dashboard 6.36.0 → 6.37.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
CHANGED
|
@@ -35,9 +35,9 @@ import * as $t from "echarts/core";
|
|
|
35
35
|
import { GridComponent as Lr, VisualMapComponent as Um, LegendComponent as Vr, TooltipComponent as Fr, DataZoomComponent as ni, MarkLineComponent as Ll, MarkAreaComponent as jd } from "echarts/components";
|
|
36
36
|
import { CanvasRenderer as Jn } from "echarts/renderers";
|
|
37
37
|
import er from "echarts-for-react/lib/core";
|
|
38
|
+
import Gt from "numbro";
|
|
38
39
|
import { BoxplotChart as Ym, BarChart as Vl, LineChart as Fl, ScatterChart as zl, PieChart as Xm, RadarChart as Qm, SunburstChart as Zm } from "echarts/charts";
|
|
39
40
|
import { quantile as _i } from "d3-array";
|
|
40
|
-
import Gt from "numbro";
|
|
41
41
|
import { transform as jl } from "echarts-stat";
|
|
42
42
|
import { useForm as Hd } from "@mantine/form";
|
|
43
43
|
import * as dr from "d3-regression";
|
|
@@ -13512,7 +13512,7 @@ const ST = (e) => {
|
|
|
13512
13512
|
getColor: ua(["#fff7f1", "darkorange", "#b60000"]),
|
|
13513
13513
|
name: "orange",
|
|
13514
13514
|
category: "sequential"
|
|
13515
|
-
}, vg = "@devtable/dashboard", Ss = "6.
|
|
13515
|
+
}, vg = "@devtable/dashboard", Ss = "6.37.0", yg = "Apache-2.0", bg = {
|
|
13516
13516
|
access: "public",
|
|
13517
13517
|
registry: "https://registry.npmjs.org/"
|
|
13518
13518
|
}, Sg = [
|
|
@@ -14088,106 +14088,13 @@ const LT = {
|
|
|
14088
14088
|
viewRender: IT,
|
|
14089
14089
|
configRender: AT,
|
|
14090
14090
|
createConfig: () => ws
|
|
14091
|
-
},
|
|
14092
|
-
const [n, r] = Ue([]);
|
|
14093
|
-
return Me(() => e.watchTriggerSnapshotList(
|
|
14094
|
-
(o) => r(o.filter((i) => i.schemaRef === t))
|
|
14095
|
-
), []), n;
|
|
14096
|
-
}, yo = ({
|
|
14097
|
-
vizManager: e,
|
|
14098
|
-
instance: t
|
|
14099
|
-
}) => Rn(
|
|
14100
|
-
() => new Xs(t, e.resolveComponent(t.type), ha),
|
|
14101
|
-
[t, e]
|
|
14102
|
-
), ed = "__TRIGGERS";
|
|
14103
|
-
class VT {
|
|
14104
|
-
constructor(t, n) {
|
|
14105
|
-
he(this, "attachments");
|
|
14106
|
-
this.instance = t, this.component = n;
|
|
14107
|
-
const r = async (o) => {
|
|
14108
|
-
const { id: i, schemaRef: a } = await o.getItem(null);
|
|
14109
|
-
return {
|
|
14110
|
-
id: i,
|
|
14111
|
-
schemaRef: a,
|
|
14112
|
-
triggerData: new Xr(o, "data")
|
|
14113
|
-
};
|
|
14114
|
-
};
|
|
14115
|
-
this.attachments = new bs(t, ed, r);
|
|
14116
|
-
}
|
|
14117
|
-
watchTriggerSnapshotList(t) {
|
|
14118
|
-
return this.instance.instanceData.watchItem(
|
|
14119
|
-
ed,
|
|
14120
|
-
(n) => {
|
|
14121
|
-
const r = xd(n).map(
|
|
14122
|
-
(o) => ({
|
|
14123
|
-
id: dt(o, "id"),
|
|
14124
|
-
schemaRef: dt(o, "schemaRef"),
|
|
14125
|
-
config: Ui(dt(o, "data.config"))
|
|
14126
|
-
})
|
|
14127
|
-
);
|
|
14128
|
-
t(r);
|
|
14129
|
-
},
|
|
14130
|
-
{ fireImmediately: !0 }
|
|
14131
|
-
);
|
|
14132
|
-
}
|
|
14133
|
-
async createOrGetTrigger(t, n, r = { recreate: !1 }) {
|
|
14134
|
-
var s;
|
|
14135
|
-
if (!this.getTriggerSchemaList().some((c) => c.id === n.id))
|
|
14136
|
-
throw new Error(`Trigger schema '${n.id}' is not defined in component '${this.component.name}'`);
|
|
14137
|
-
const i = await this.attachments.getInstance(t);
|
|
14138
|
-
return !i || r.recreate || i.schemaRef !== n.id ? await this.attachments.create(t, {
|
|
14139
|
-
id: t,
|
|
14140
|
-
schemaRef: n.id,
|
|
14141
|
-
data: ((s = n == null ? void 0 : n.createDefaultConfig) == null ? void 0 : s.call(n)) || {}
|
|
14142
|
-
}) : i;
|
|
14143
|
-
}
|
|
14144
|
-
async getTriggerList() {
|
|
14145
|
-
return await this.attachments.list();
|
|
14146
|
-
}
|
|
14147
|
-
getTriggerSchemaList() {
|
|
14148
|
-
return this.component.triggers || [];
|
|
14149
|
-
}
|
|
14150
|
-
async removeTrigger(t) {
|
|
14151
|
-
await this.attachments.remove(t);
|
|
14152
|
-
}
|
|
14153
|
-
async retrieveTrigger(t) {
|
|
14154
|
-
return await this.attachments.getInstance(t);
|
|
14155
|
-
}
|
|
14156
|
-
async getMigrationTasks() {
|
|
14157
|
-
const n = (await this.getTriggerList()).map(async (r) => {
|
|
14158
|
-
const o = this.getTriggerSchemaList().find((s) => s.id === r.schemaRef), i = o == null ? void 0 : o.migrator, a = {
|
|
14159
|
-
configData: r.triggerData
|
|
14160
|
-
};
|
|
14161
|
-
return i && await i.needMigration(a) ? () => i.migrate(a) : null;
|
|
14162
|
-
});
|
|
14163
|
-
return Promise.all(n).then((r) => r.filter((o) => o));
|
|
14164
|
-
}
|
|
14165
|
-
async needMigration() {
|
|
14166
|
-
return (await this.getMigrationTasks()).length > 0;
|
|
14167
|
-
}
|
|
14168
|
-
async runMigration() {
|
|
14169
|
-
const t = await this.getMigrationTasks();
|
|
14170
|
-
await Promise.all(t.map((n) => n()));
|
|
14171
|
-
}
|
|
14172
|
-
}
|
|
14173
|
-
const Go = Mn(function({
|
|
14174
|
-
value: t,
|
|
14175
|
-
onChange: n,
|
|
14176
|
-
...r
|
|
14177
|
-
}, o) {
|
|
14178
|
-
return /* @__PURE__ */ l(ce, {
|
|
14179
|
-
ref: o,
|
|
14180
|
-
value: t,
|
|
14181
|
-
onChange: n,
|
|
14182
|
-
...r
|
|
14183
|
-
});
|
|
14184
|
-
}), Fn = {
|
|
14091
|
+
}, Fn = {
|
|
14185
14092
|
mantissa: 0,
|
|
14186
14093
|
output: "number",
|
|
14187
14094
|
trimMantissa: !1,
|
|
14188
14095
|
average: !1
|
|
14189
14096
|
};
|
|
14190
|
-
function
|
|
14097
|
+
function VT({
|
|
14191
14098
|
value: e,
|
|
14192
14099
|
onChange: t
|
|
14193
14100
|
}, n) {
|
|
@@ -14317,7 +14224,159 @@ function FT({
|
|
|
14317
14224
|
})]
|
|
14318
14225
|
});
|
|
14319
14226
|
}
|
|
14320
|
-
const zr = j.forwardRef(
|
|
14227
|
+
const zr = j.forwardRef(VT), jr = {
|
|
14228
|
+
enabled: !1,
|
|
14229
|
+
func_content: ["function label(value, index) {", " // your code goes here", " // return value", "}"].join(`
|
|
14230
|
+
`)
|
|
14231
|
+
}, kg = {
|
|
14232
|
+
id: "builtin:echarts:click-echart:series",
|
|
14233
|
+
displayName: "Click Chart Series",
|
|
14234
|
+
nameRender: zT,
|
|
14235
|
+
configRender: FT,
|
|
14236
|
+
payload: [{
|
|
14237
|
+
name: "type",
|
|
14238
|
+
description: "Always 'click'",
|
|
14239
|
+
valueType: "string"
|
|
14240
|
+
}, {
|
|
14241
|
+
name: "seriesType",
|
|
14242
|
+
description: "'boxplot'",
|
|
14243
|
+
valueType: "string"
|
|
14244
|
+
}, {
|
|
14245
|
+
name: "name",
|
|
14246
|
+
description: "Name of the series clicked",
|
|
14247
|
+
valueType: "string"
|
|
14248
|
+
}, {
|
|
14249
|
+
name: "color",
|
|
14250
|
+
description: "Color",
|
|
14251
|
+
valueType: "string"
|
|
14252
|
+
}, {
|
|
14253
|
+
name: "value",
|
|
14254
|
+
description: "Record of 'name', 'min', 'q1', 'median', 'q3', 'max'",
|
|
14255
|
+
valueType: "object"
|
|
14256
|
+
}, {
|
|
14257
|
+
name: "rowData",
|
|
14258
|
+
description: "Data of the row",
|
|
14259
|
+
valueType: "object"
|
|
14260
|
+
}]
|
|
14261
|
+
};
|
|
14262
|
+
function FT(e) {
|
|
14263
|
+
return /* @__PURE__ */ l(Ae, {});
|
|
14264
|
+
}
|
|
14265
|
+
function zT(e) {
|
|
14266
|
+
return /* @__PURE__ */ l(z, {
|
|
14267
|
+
children: "Click chart's series"
|
|
14268
|
+
});
|
|
14269
|
+
}
|
|
14270
|
+
const xs = {
|
|
14271
|
+
x_axis: {
|
|
14272
|
+
name: "X Axis",
|
|
14273
|
+
data_key: "",
|
|
14274
|
+
axisLabel: {
|
|
14275
|
+
rotate: 0,
|
|
14276
|
+
formatter: { ...jr }
|
|
14277
|
+
}
|
|
14278
|
+
},
|
|
14279
|
+
y_axis: {
|
|
14280
|
+
name: "Y Axis",
|
|
14281
|
+
data_key: "value",
|
|
14282
|
+
label_formatter: Fn
|
|
14283
|
+
},
|
|
14284
|
+
color: "#228be6",
|
|
14285
|
+
reference_lines: []
|
|
14286
|
+
}, vo = (e, t) => {
|
|
14287
|
+
const [n, r] = Ue([]);
|
|
14288
|
+
return Me(() => e.watchTriggerSnapshotList(
|
|
14289
|
+
(o) => r(o.filter((i) => i.schemaRef === t))
|
|
14290
|
+
), []), n;
|
|
14291
|
+
}, yo = ({
|
|
14292
|
+
vizManager: e,
|
|
14293
|
+
instance: t
|
|
14294
|
+
}) => Rn(
|
|
14295
|
+
() => new Xs(t, e.resolveComponent(t.type), ha),
|
|
14296
|
+
[t, e]
|
|
14297
|
+
), ed = "__TRIGGERS";
|
|
14298
|
+
class jT {
|
|
14299
|
+
constructor(t, n) {
|
|
14300
|
+
he(this, "attachments");
|
|
14301
|
+
this.instance = t, this.component = n;
|
|
14302
|
+
const r = async (o) => {
|
|
14303
|
+
const { id: i, schemaRef: a } = await o.getItem(null);
|
|
14304
|
+
return {
|
|
14305
|
+
id: i,
|
|
14306
|
+
schemaRef: a,
|
|
14307
|
+
triggerData: new Xr(o, "data")
|
|
14308
|
+
};
|
|
14309
|
+
};
|
|
14310
|
+
this.attachments = new bs(t, ed, r);
|
|
14311
|
+
}
|
|
14312
|
+
watchTriggerSnapshotList(t) {
|
|
14313
|
+
return this.instance.instanceData.watchItem(
|
|
14314
|
+
ed,
|
|
14315
|
+
(n) => {
|
|
14316
|
+
const r = xd(n).map(
|
|
14317
|
+
(o) => ({
|
|
14318
|
+
id: dt(o, "id"),
|
|
14319
|
+
schemaRef: dt(o, "schemaRef"),
|
|
14320
|
+
config: Ui(dt(o, "data.config"))
|
|
14321
|
+
})
|
|
14322
|
+
);
|
|
14323
|
+
t(r);
|
|
14324
|
+
},
|
|
14325
|
+
{ fireImmediately: !0 }
|
|
14326
|
+
);
|
|
14327
|
+
}
|
|
14328
|
+
async createOrGetTrigger(t, n, r = { recreate: !1 }) {
|
|
14329
|
+
var s;
|
|
14330
|
+
if (!this.getTriggerSchemaList().some((c) => c.id === n.id))
|
|
14331
|
+
throw new Error(`Trigger schema '${n.id}' is not defined in component '${this.component.name}'`);
|
|
14332
|
+
const i = await this.attachments.getInstance(t);
|
|
14333
|
+
return !i || r.recreate || i.schemaRef !== n.id ? await this.attachments.create(t, {
|
|
14334
|
+
id: t,
|
|
14335
|
+
schemaRef: n.id,
|
|
14336
|
+
data: ((s = n == null ? void 0 : n.createDefaultConfig) == null ? void 0 : s.call(n)) || {}
|
|
14337
|
+
}) : i;
|
|
14338
|
+
}
|
|
14339
|
+
async getTriggerList() {
|
|
14340
|
+
return await this.attachments.list();
|
|
14341
|
+
}
|
|
14342
|
+
getTriggerSchemaList() {
|
|
14343
|
+
return this.component.triggers || [];
|
|
14344
|
+
}
|
|
14345
|
+
async removeTrigger(t) {
|
|
14346
|
+
await this.attachments.remove(t);
|
|
14347
|
+
}
|
|
14348
|
+
async retrieveTrigger(t) {
|
|
14349
|
+
return await this.attachments.getInstance(t);
|
|
14350
|
+
}
|
|
14351
|
+
async getMigrationTasks() {
|
|
14352
|
+
const n = (await this.getTriggerList()).map(async (r) => {
|
|
14353
|
+
const o = this.getTriggerSchemaList().find((s) => s.id === r.schemaRef), i = o == null ? void 0 : o.migrator, a = {
|
|
14354
|
+
configData: r.triggerData
|
|
14355
|
+
};
|
|
14356
|
+
return i && await i.needMigration(a) ? () => i.migrate(a) : null;
|
|
14357
|
+
});
|
|
14358
|
+
return Promise.all(n).then((r) => r.filter((o) => o));
|
|
14359
|
+
}
|
|
14360
|
+
async needMigration() {
|
|
14361
|
+
return (await this.getMigrationTasks()).length > 0;
|
|
14362
|
+
}
|
|
14363
|
+
async runMigration() {
|
|
14364
|
+
const t = await this.getMigrationTasks();
|
|
14365
|
+
await Promise.all(t.map((n) => n()));
|
|
14366
|
+
}
|
|
14367
|
+
}
|
|
14368
|
+
const Go = Mn(function({
|
|
14369
|
+
value: t,
|
|
14370
|
+
onChange: n,
|
|
14371
|
+
...r
|
|
14372
|
+
}, o) {
|
|
14373
|
+
return /* @__PURE__ */ l(ce, {
|
|
14374
|
+
ref: o,
|
|
14375
|
+
value: t,
|
|
14376
|
+
onChange: n,
|
|
14377
|
+
...r
|
|
14378
|
+
});
|
|
14379
|
+
}), HT = [{
|
|
14321
14380
|
label: "None",
|
|
14322
14381
|
value: "none"
|
|
14323
14382
|
}, {
|
|
@@ -14339,7 +14398,7 @@ const zr = j.forwardRef(FT), zT = [{
|
|
|
14339
14398
|
label: "Quantile(99%, 95%, ...)",
|
|
14340
14399
|
value: "quantile"
|
|
14341
14400
|
}];
|
|
14342
|
-
function
|
|
14401
|
+
function KT({
|
|
14343
14402
|
label: e,
|
|
14344
14403
|
value: t,
|
|
14345
14404
|
onChange: n
|
|
@@ -14375,7 +14434,7 @@ function jT({
|
|
|
14375
14434
|
children: [/* @__PURE__ */ l(Ee, {
|
|
14376
14435
|
ref: r,
|
|
14377
14436
|
label: e,
|
|
14378
|
-
data:
|
|
14437
|
+
data: HT,
|
|
14379
14438
|
value: t.type,
|
|
14380
14439
|
onChange: o
|
|
14381
14440
|
}), t.type === "quantile" && /* @__PURE__ */ l(nn, {
|
|
@@ -14389,8 +14448,8 @@ function jT({
|
|
|
14389
14448
|
})]
|
|
14390
14449
|
});
|
|
14391
14450
|
}
|
|
14392
|
-
const
|
|
14393
|
-
function
|
|
14451
|
+
const Mg = j.forwardRef(KT);
|
|
14452
|
+
function BT({
|
|
14394
14453
|
label: e,
|
|
14395
14454
|
value: t,
|
|
14396
14455
|
onChange: n
|
|
@@ -14446,8 +14505,8 @@ function HT({
|
|
|
14446
14505
|
})]
|
|
14447
14506
|
});
|
|
14448
14507
|
}
|
|
14449
|
-
const
|
|
14450
|
-
function
|
|
14508
|
+
const GT = j.forwardRef(BT);
|
|
14509
|
+
function WT({
|
|
14451
14510
|
value: e,
|
|
14452
14511
|
onChange: t
|
|
14453
14512
|
}, n) {
|
|
@@ -14497,7 +14556,7 @@ function BT({
|
|
|
14497
14556
|
})]
|
|
14498
14557
|
});
|
|
14499
14558
|
}
|
|
14500
|
-
const zn = j.forwardRef(
|
|
14559
|
+
const zn = j.forwardRef(WT), bi = [{
|
|
14501
14560
|
label: "initial",
|
|
14502
14561
|
value: 0
|
|
14503
14562
|
}, {
|
|
@@ -14513,7 +14572,7 @@ const zn = j.forwardRef(BT), bi = [{
|
|
|
14513
14572
|
label: "bold",
|
|
14514
14573
|
value: 100
|
|
14515
14574
|
}];
|
|
14516
|
-
function
|
|
14575
|
+
function qT({
|
|
14517
14576
|
label: e,
|
|
14518
14577
|
value: t,
|
|
14519
14578
|
onChange: n
|
|
@@ -14542,8 +14601,8 @@ function GT({
|
|
|
14542
14601
|
})]
|
|
14543
14602
|
});
|
|
14544
14603
|
}
|
|
14545
|
-
const
|
|
14546
|
-
function
|
|
14604
|
+
const Dg = j.forwardRef(qT);
|
|
14605
|
+
function UT({
|
|
14547
14606
|
label: e,
|
|
14548
14607
|
value: t,
|
|
14549
14608
|
onChange: n,
|
|
@@ -14601,7 +14660,7 @@ function WT({
|
|
|
14601
14660
|
})]
|
|
14602
14661
|
});
|
|
14603
14662
|
}
|
|
14604
|
-
const
|
|
14663
|
+
const YT = j.forwardRef(UT), Pg = j.forwardRef(function({
|
|
14605
14664
|
value: t,
|
|
14606
14665
|
onChange: n
|
|
14607
14666
|
}, r) {
|
|
@@ -14633,7 +14692,7 @@ const qT = j.forwardRef(WT), Dg = j.forwardRef(function({
|
|
|
14633
14692
|
maxWidth: "100%"
|
|
14634
14693
|
}
|
|
14635
14694
|
},
|
|
14636
|
-
children: /* @__PURE__ */ l(
|
|
14695
|
+
children: /* @__PURE__ */ l(Dg, {
|
|
14637
14696
|
label: "Font Weight",
|
|
14638
14697
|
value: t.weight,
|
|
14639
14698
|
onChange: (a) => i("weight", a)
|
|
@@ -14658,12 +14717,12 @@ const qT = j.forwardRef(WT), Dg = j.forwardRef(function({
|
|
|
14658
14717
|
value: t.color.staticColor,
|
|
14659
14718
|
onChange: (a) => i("color.staticColor", a)
|
|
14660
14719
|
}), o === "continuous" && /* @__PURE__ */ v(Ae, {
|
|
14661
|
-
children: [/* @__PURE__ */ l(
|
|
14720
|
+
children: [/* @__PURE__ */ l(YT, {
|
|
14662
14721
|
label: "Value Range",
|
|
14663
14722
|
value: t.color.valueRange,
|
|
14664
14723
|
type: "number",
|
|
14665
14724
|
onChange: (a) => i("color.valueRange", a)
|
|
14666
|
-
}), /* @__PURE__ */ l(
|
|
14725
|
+
}), /* @__PURE__ */ l(GT, {
|
|
14667
14726
|
label: "Color Range",
|
|
14668
14727
|
value: t.color.colorRange,
|
|
14669
14728
|
onChange: (a) => i("color.colorRange", a)
|
|
@@ -14709,7 +14768,7 @@ j.forwardRef(function({
|
|
|
14709
14768
|
value: t.data_field,
|
|
14710
14769
|
onChange: (s) => a("data_field", s)
|
|
14711
14770
|
})]
|
|
14712
|
-
}), /* @__PURE__ */ l(
|
|
14771
|
+
}), /* @__PURE__ */ l(Mg, {
|
|
14713
14772
|
label: "Aggregation",
|
|
14714
14773
|
value: t.aggregation,
|
|
14715
14774
|
onChange: (s) => a("aggregation", s)
|
|
@@ -14720,30 +14779,30 @@ j.forwardRef(function({
|
|
|
14720
14779
|
}), /* @__PURE__ */ l(zr, {
|
|
14721
14780
|
value: t.formatter,
|
|
14722
14781
|
onChange: (s) => a("formatter", s)
|
|
14723
|
-
}), o && /* @__PURE__ */ l(
|
|
14782
|
+
}), o && /* @__PURE__ */ l(Pg, {
|
|
14724
14783
|
value: t,
|
|
14725
14784
|
onChange: n
|
|
14726
14785
|
})]
|
|
14727
14786
|
});
|
|
14728
14787
|
});
|
|
14729
|
-
function
|
|
14788
|
+
function XT(e) {
|
|
14730
14789
|
const t = Array.from(e).sort((r, o) => r - o), n = Math.floor(t.length / 2);
|
|
14731
14790
|
return t.length % 2 === 0 ? (t[n - 1] + t[n]) / 2 : t[n];
|
|
14732
14791
|
}
|
|
14733
|
-
function
|
|
14792
|
+
function QT(e, t) {
|
|
14734
14793
|
const n = e[t], r = Number(n);
|
|
14735
14794
|
return isFinite(r) ? r : 0;
|
|
14736
14795
|
}
|
|
14737
|
-
function
|
|
14796
|
+
function Cs(e, t, n) {
|
|
14738
14797
|
var o, i, a, s;
|
|
14739
|
-
const r = e.map((c) =>
|
|
14798
|
+
const r = e.map((c) => QT(c, t));
|
|
14740
14799
|
switch (n.type) {
|
|
14741
14800
|
case "sum":
|
|
14742
14801
|
return Le.sum(r);
|
|
14743
14802
|
case "mean":
|
|
14744
14803
|
return Le.mean(r);
|
|
14745
14804
|
case "median":
|
|
14746
|
-
return
|
|
14805
|
+
return XT(r);
|
|
14747
14806
|
case "max":
|
|
14748
14807
|
return (o = Le.max(r)) != null ? o : 0;
|
|
14749
14808
|
case "min":
|
|
@@ -14754,19 +14813,19 @@ function xs(e, t, n) {
|
|
|
14754
14813
|
return (s = e[0]) == null ? void 0 : s[t];
|
|
14755
14814
|
}
|
|
14756
14815
|
}
|
|
14757
|
-
var
|
|
14816
|
+
var Ig = function() {
|
|
14758
14817
|
}, Wo = function() {
|
|
14759
14818
|
};
|
|
14760
|
-
process.env.NODE_ENV !== "production" && (
|
|
14819
|
+
process.env.NODE_ENV !== "production" && (Ig = function(e, t) {
|
|
14761
14820
|
!e && typeof console < "u" && console.warn(t);
|
|
14762
14821
|
}, Wo = function(e, t) {
|
|
14763
14822
|
if (!e)
|
|
14764
14823
|
throw new Error(t);
|
|
14765
14824
|
});
|
|
14766
|
-
const
|
|
14825
|
+
const ZT = (e, t, n) => Math.min(Math.max(n, e), t), $g = (e, t, n) => {
|
|
14767
14826
|
const r = t - e;
|
|
14768
14827
|
return r === 0 ? 1 : (n - e) / r;
|
|
14769
|
-
},
|
|
14828
|
+
}, _s = (e, t, n) => -n * e + n * t + e, Ag = (e, t) => (n) => Math.max(Math.min(n, t), e), $o = (e) => e % 1 ? Number(e.toFixed(5)) : e, Ki = /(-)?([\d]*\.?[\d])+/g, ml = /(#[0-9a-f]{6}|#[0-9a-f]{3}|#(?:[0-9a-f]{2}){2,4}|(rgb|hsl)a?\((-?[\d\.]+%?[,\s]+){2,3}\s*\/*\s*[\d\.]+%?\))/gi, JT = /^(#[0-9a-f]{3}|#(?:[0-9a-f]{2}){2,4}|(rgb|hsl)a?\((-?[\d\.]+%?[,\s]+){2,3}\s*\/*\s*[\d\.]+%?\))$/i;
|
|
14770
14829
|
function si(e) {
|
|
14771
14830
|
return typeof e == "string";
|
|
14772
14831
|
}
|
|
@@ -14774,15 +14833,15 @@ const da = {
|
|
|
14774
14833
|
test: (e) => typeof e == "number",
|
|
14775
14834
|
parse: parseFloat,
|
|
14776
14835
|
transform: (e) => e
|
|
14777
|
-
},
|
|
14836
|
+
}, Ng = Object.assign(Object.assign({}, da), { transform: Ag(0, 1) });
|
|
14778
14837
|
Object.assign(Object.assign({}, da), { default: 1 });
|
|
14779
|
-
const
|
|
14838
|
+
const ek = (e) => ({
|
|
14780
14839
|
test: (t) => si(t) && t.endsWith(e) && t.split(" ").length === 1,
|
|
14781
14840
|
parse: parseFloat,
|
|
14782
14841
|
transform: (t) => `${t}${e}`
|
|
14783
|
-
}), Ao =
|
|
14842
|
+
}), Ao = ek("%");
|
|
14784
14843
|
Object.assign(Object.assign({}, Ao), { parse: (e) => Ao.parse(e) / 100, transform: (e) => Ao.transform(e * 100) });
|
|
14785
|
-
const
|
|
14844
|
+
const Es = (e, t) => (n) => Boolean(si(n) && JT.test(n) && n.startsWith(e) || t && Object.prototype.hasOwnProperty.call(n, t)), Lg = (e, t, n) => (r) => {
|
|
14786
14845
|
if (!si(r))
|
|
14787
14846
|
return r;
|
|
14788
14847
|
const [o, i, a, s] = r.match(Ki);
|
|
@@ -14793,15 +14852,15 @@ const _s = (e, t) => (n) => Boolean(si(n) && QT.test(n) && n.startsWith(e) || t
|
|
|
14793
14852
|
alpha: s !== void 0 ? parseFloat(s) : 1
|
|
14794
14853
|
};
|
|
14795
14854
|
}, Mr = {
|
|
14796
|
-
test:
|
|
14797
|
-
parse:
|
|
14798
|
-
transform: ({ hue: e, saturation: t, lightness: n, alpha: r = 1 }) => "hsla(" + Math.round(e) + ", " + Ao.transform($o(t)) + ", " + Ao.transform($o(n)) + ", " + $o(
|
|
14799
|
-
},
|
|
14800
|
-
test:
|
|
14801
|
-
parse:
|
|
14802
|
-
transform: ({ red: e, green: t, blue: n, alpha: r = 1 }) => "rgba(" + Da.transform(e) + ", " + Da.transform(t) + ", " + Da.transform(n) + ", " + $o(
|
|
14855
|
+
test: Es("hsl", "hue"),
|
|
14856
|
+
parse: Lg("hue", "saturation", "lightness"),
|
|
14857
|
+
transform: ({ hue: e, saturation: t, lightness: n, alpha: r = 1 }) => "hsla(" + Math.round(e) + ", " + Ao.transform($o(t)) + ", " + Ao.transform($o(n)) + ", " + $o(Ng.transform(r)) + ")"
|
|
14858
|
+
}, tk = Ag(0, 255), Da = Object.assign(Object.assign({}, da), { transform: (e) => Math.round(tk(e)) }), fr = {
|
|
14859
|
+
test: Es("rgb", "red"),
|
|
14860
|
+
parse: Lg("red", "green", "blue"),
|
|
14861
|
+
transform: ({ red: e, green: t, blue: n, alpha: r = 1 }) => "rgba(" + Da.transform(e) + ", " + Da.transform(t) + ", " + Da.transform(n) + ", " + $o(Ng.transform(r)) + ")"
|
|
14803
14862
|
};
|
|
14804
|
-
function
|
|
14863
|
+
function nk(e) {
|
|
14805
14864
|
let t = "", n = "", r = "", o = "";
|
|
14806
14865
|
return e.length > 5 ? (t = e.substr(1, 2), n = e.substr(3, 2), r = e.substr(5, 2), o = e.substr(7, 2)) : (t = e.substr(1, 1), n = e.substr(2, 1), r = e.substr(3, 1), o = e.substr(4, 1), t += t, n += n, r += r, o += o), {
|
|
14807
14866
|
red: parseInt(t, 16),
|
|
@@ -14811,45 +14870,45 @@ function ek(e) {
|
|
|
14811
14870
|
};
|
|
14812
14871
|
}
|
|
14813
14872
|
const vl = {
|
|
14814
|
-
test:
|
|
14815
|
-
parse:
|
|
14873
|
+
test: Es("#"),
|
|
14874
|
+
parse: nk,
|
|
14816
14875
|
transform: fr.transform
|
|
14817
14876
|
}, fa = {
|
|
14818
14877
|
test: (e) => fr.test(e) || vl.test(e) || Mr.test(e),
|
|
14819
14878
|
parse: (e) => fr.test(e) ? fr.parse(e) : Mr.test(e) ? Mr.parse(e) : vl.parse(e),
|
|
14820
14879
|
transform: (e) => si(e) ? e : e.hasOwnProperty("red") ? fr.transform(e) : Mr.transform(e)
|
|
14821
|
-
},
|
|
14822
|
-
function
|
|
14880
|
+
}, Vg = "${c}", Fg = "${n}";
|
|
14881
|
+
function rk(e) {
|
|
14823
14882
|
var t, n, r, o;
|
|
14824
14883
|
return isNaN(e) && si(e) && ((n = (t = e.match(Ki)) === null || t === void 0 ? void 0 : t.length) !== null && n !== void 0 ? n : 0) + ((o = (r = e.match(ml)) === null || r === void 0 ? void 0 : r.length) !== null && o !== void 0 ? o : 0) > 0;
|
|
14825
14884
|
}
|
|
14826
|
-
function
|
|
14885
|
+
function zg(e) {
|
|
14827
14886
|
typeof e == "number" && (e = `${e}`);
|
|
14828
14887
|
const t = [];
|
|
14829
14888
|
let n = 0;
|
|
14830
14889
|
const r = e.match(ml);
|
|
14831
|
-
r && (n = r.length, e = e.replace(ml,
|
|
14890
|
+
r && (n = r.length, e = e.replace(ml, Vg), t.push(...r.map(fa.parse)));
|
|
14832
14891
|
const o = e.match(Ki);
|
|
14833
|
-
return o && (e = e.replace(Ki,
|
|
14834
|
-
}
|
|
14835
|
-
function zg(e) {
|
|
14836
|
-
return Fg(e).values;
|
|
14892
|
+
return o && (e = e.replace(Ki, Fg), t.push(...o.map(da.parse))), { values: t, numColors: n, tokenised: e };
|
|
14837
14893
|
}
|
|
14838
14894
|
function jg(e) {
|
|
14839
|
-
|
|
14895
|
+
return zg(e).values;
|
|
14896
|
+
}
|
|
14897
|
+
function Hg(e) {
|
|
14898
|
+
const { values: t, numColors: n, tokenised: r } = zg(e), o = t.length;
|
|
14840
14899
|
return (i) => {
|
|
14841
14900
|
let a = r;
|
|
14842
14901
|
for (let s = 0; s < o; s++)
|
|
14843
|
-
a = a.replace(s < n ?
|
|
14902
|
+
a = a.replace(s < n ? Vg : Fg, s < n ? fa.transform(i[s]) : $o(i[s]));
|
|
14844
14903
|
return a;
|
|
14845
14904
|
};
|
|
14846
14905
|
}
|
|
14847
|
-
const
|
|
14848
|
-
function
|
|
14849
|
-
const t =
|
|
14850
|
-
return
|
|
14906
|
+
const ok = (e) => typeof e == "number" ? 0 : e;
|
|
14907
|
+
function ik(e) {
|
|
14908
|
+
const t = jg(e);
|
|
14909
|
+
return Hg(e)(t.map(ok));
|
|
14851
14910
|
}
|
|
14852
|
-
const
|
|
14911
|
+
const Kg = { test: rk, parse: jg, createTransformer: Hg, getAnimatableNone: ik };
|
|
14853
14912
|
function Pa(e, t, n) {
|
|
14854
14913
|
return n < 0 && (n += 1), n > 1 && (n -= 1), n < 1 / 6 ? e + (t - e) * 6 * n : n < 1 / 2 ? t : n < 2 / 3 ? e + (t - e) * (2 / 3 - n) * 6 : e;
|
|
14855
14914
|
}
|
|
@@ -14869,10 +14928,10 @@ function td({ hue: e, saturation: t, lightness: n, alpha: r }) {
|
|
|
14869
14928
|
alpha: r
|
|
14870
14929
|
};
|
|
14871
14930
|
}
|
|
14872
|
-
const
|
|
14931
|
+
const ak = (e, t, n) => {
|
|
14873
14932
|
const r = e * e, o = t * t;
|
|
14874
14933
|
return Math.sqrt(Math.max(0, n * (o - r) + r));
|
|
14875
|
-
},
|
|
14934
|
+
}, lk = [vl, fr, Mr], nd = (e) => lk.find((t) => t.test(e)), rd = (e) => `'${e}' is not an animatable color. Use the equivalent color code instead.`, Bg = (e, t) => {
|
|
14876
14935
|
let n = nd(e), r = nd(t);
|
|
14877
14936
|
Wo(!!n, rd(e)), Wo(!!r, rd(t));
|
|
14878
14937
|
let o = n.parse(e), i = r.parse(t);
|
|
@@ -14880,24 +14939,24 @@ const ok = (e, t, n) => {
|
|
|
14880
14939
|
const a = Object.assign({}, o);
|
|
14881
14940
|
return (s) => {
|
|
14882
14941
|
for (const c in a)
|
|
14883
|
-
c !== "alpha" && (a[c] =
|
|
14884
|
-
return a.alpha =
|
|
14942
|
+
c !== "alpha" && (a[c] = ak(o[c], i[c], s));
|
|
14943
|
+
return a.alpha = _s(o.alpha, i.alpha, s), n.transform(a);
|
|
14885
14944
|
};
|
|
14886
|
-
},
|
|
14887
|
-
function
|
|
14888
|
-
return
|
|
14945
|
+
}, sk = (e) => typeof e == "number", ck = (e, t) => (n) => t(e(n)), Gg = (...e) => e.reduce(ck);
|
|
14946
|
+
function Wg(e, t) {
|
|
14947
|
+
return sk(e) ? (n) => _s(e, t, n) : fa.test(e) ? Bg(e, t) : Ug(e, t);
|
|
14889
14948
|
}
|
|
14890
|
-
const
|
|
14891
|
-
const n = [...e], r = n.length, o = e.map((i, a) =>
|
|
14949
|
+
const qg = (e, t) => {
|
|
14950
|
+
const n = [...e], r = n.length, o = e.map((i, a) => Wg(i, t[a]));
|
|
14892
14951
|
return (i) => {
|
|
14893
14952
|
for (let a = 0; a < r; a++)
|
|
14894
14953
|
n[a] = o[a](i);
|
|
14895
14954
|
return n;
|
|
14896
14955
|
};
|
|
14897
|
-
},
|
|
14956
|
+
}, uk = (e, t) => {
|
|
14898
14957
|
const n = Object.assign(Object.assign({}, e), t), r = {};
|
|
14899
14958
|
for (const o in n)
|
|
14900
|
-
e[o] !== void 0 && t[o] !== void 0 && (r[o] =
|
|
14959
|
+
e[o] !== void 0 && t[o] !== void 0 && (r[o] = Wg(e[o], t[o]));
|
|
14901
14960
|
return (o) => {
|
|
14902
14961
|
for (const i in r)
|
|
14903
14962
|
n[i] = r[i](o);
|
|
@@ -14905,42 +14964,42 @@ const Wg = (e, t) => {
|
|
|
14905
14964
|
};
|
|
14906
14965
|
};
|
|
14907
14966
|
function od(e) {
|
|
14908
|
-
const t =
|
|
14967
|
+
const t = Kg.parse(e), n = t.length;
|
|
14909
14968
|
let r = 0, o = 0, i = 0;
|
|
14910
14969
|
for (let a = 0; a < n; a++)
|
|
14911
14970
|
r || typeof t[a] == "number" ? r++ : t[a].hue !== void 0 ? i++ : o++;
|
|
14912
14971
|
return { parsed: t, numNumbers: r, numRGB: o, numHSL: i };
|
|
14913
14972
|
}
|
|
14914
|
-
const
|
|
14915
|
-
const n =
|
|
14916
|
-
return r.numHSL === o.numHSL && r.numRGB === o.numRGB && r.numNumbers >= o.numNumbers ?
|
|
14917
|
-
},
|
|
14918
|
-
function
|
|
14973
|
+
const Ug = (e, t) => {
|
|
14974
|
+
const n = Kg.createTransformer(t), r = od(e), o = od(t);
|
|
14975
|
+
return r.numHSL === o.numHSL && r.numRGB === o.numRGB && r.numNumbers >= o.numNumbers ? Gg(qg(r.parsed, o.parsed), n) : (Ig(!0, `Complex values '${e}' and '${t}' too different to mix. Ensure all colors are of the same type, and that each contains the same quantity of number and color values. Falling back to instant transition.`), (a) => `${a > 0 ? t : e}`);
|
|
14976
|
+
}, dk = (e, t) => (n) => _s(e, t, n);
|
|
14977
|
+
function fk(e) {
|
|
14919
14978
|
if (typeof e == "number")
|
|
14920
|
-
return
|
|
14979
|
+
return dk;
|
|
14921
14980
|
if (typeof e == "string")
|
|
14922
|
-
return fa.test(e) ?
|
|
14981
|
+
return fa.test(e) ? Bg : Ug;
|
|
14923
14982
|
if (Array.isArray(e))
|
|
14924
|
-
return
|
|
14983
|
+
return qg;
|
|
14925
14984
|
if (typeof e == "object")
|
|
14926
|
-
return
|
|
14985
|
+
return uk;
|
|
14927
14986
|
}
|
|
14928
|
-
function
|
|
14929
|
-
const r = [], o = n ||
|
|
14987
|
+
function pk(e, t, n) {
|
|
14988
|
+
const r = [], o = n || fk(e[0]), i = e.length - 1;
|
|
14930
14989
|
for (let a = 0; a < i; a++) {
|
|
14931
14990
|
let s = o(e[a], e[a + 1]);
|
|
14932
14991
|
if (t) {
|
|
14933
14992
|
const c = Array.isArray(t) ? t[a] : t;
|
|
14934
|
-
s =
|
|
14993
|
+
s = Gg(c, s);
|
|
14935
14994
|
}
|
|
14936
14995
|
r.push(s);
|
|
14937
14996
|
}
|
|
14938
14997
|
return r;
|
|
14939
14998
|
}
|
|
14940
|
-
function
|
|
14941
|
-
return (r) => n(
|
|
14999
|
+
function gk([e, t], [n]) {
|
|
15000
|
+
return (r) => n($g(e, t, r));
|
|
14942
15001
|
}
|
|
14943
|
-
function
|
|
15002
|
+
function hk(e, t) {
|
|
14944
15003
|
const n = e.length, r = n - 1;
|
|
14945
15004
|
return (o) => {
|
|
14946
15005
|
let i = 0, a = !1;
|
|
@@ -14950,88 +15009,88 @@ function pk(e, t) {
|
|
|
14950
15009
|
;
|
|
14951
15010
|
i = c - 1;
|
|
14952
15011
|
}
|
|
14953
|
-
const s =
|
|
15012
|
+
const s = $g(e[i], e[i + 1], o);
|
|
14954
15013
|
return t[i](s);
|
|
14955
15014
|
};
|
|
14956
15015
|
}
|
|
14957
|
-
function
|
|
15016
|
+
function Os(e, t, { clamp: n = !0, ease: r, mixer: o } = {}) {
|
|
14958
15017
|
const i = e.length;
|
|
14959
15018
|
Wo(i === t.length, "Both input and output ranges must be the same length"), Wo(!r || !Array.isArray(r) || r.length === i - 1, "Array of easing functions must be of length `input.length - 1`, as it applies to the transitions **between** the defined values."), e[0] > e[i - 1] && (e = [].concat(e), t = [].concat(t), e.reverse(), t.reverse());
|
|
14960
|
-
const a =
|
|
14961
|
-
return n ? (c) => s(
|
|
15019
|
+
const a = pk(t, r, o), s = i === 2 ? gk(e, a) : hk(e, a);
|
|
15020
|
+
return n ? (c) => s(ZT(e[0], e[i - 1], c)) : s;
|
|
14962
15021
|
}
|
|
14963
|
-
class
|
|
15022
|
+
class mk {
|
|
14964
15023
|
constructor({ valueRange: t, colorRange: n }) {
|
|
14965
15024
|
he(this, "mapper");
|
|
14966
|
-
this.mapper =
|
|
15025
|
+
this.mapper = Os(t, n);
|
|
14967
15026
|
}
|
|
14968
15027
|
getColor(t) {
|
|
14969
15028
|
return this.mapper(t);
|
|
14970
15029
|
}
|
|
14971
15030
|
}
|
|
14972
|
-
function
|
|
15031
|
+
function vk(e) {
|
|
14973
15032
|
return e === null ? "null" : e === void 0 ? "undefined" : Array.isArray(e) ? `Array(${e.length})` : e.toString();
|
|
14974
15033
|
}
|
|
14975
|
-
function
|
|
14976
|
-
return
|
|
15034
|
+
function Rs({ data_field: e, aggregation: t }, n) {
|
|
15035
|
+
return Cs(n, e, t);
|
|
14977
15036
|
}
|
|
14978
15037
|
function ci({ formatter: e }, t) {
|
|
14979
|
-
return ["string", "number"].includes(typeof t) ? Gt(t).format(e) :
|
|
15038
|
+
return ["string", "number"].includes(typeof t) ? Gt(t).format(e) : vk(t);
|
|
14980
15039
|
}
|
|
14981
|
-
function
|
|
15040
|
+
function yk(e, t) {
|
|
14982
15041
|
if (e.type === "static")
|
|
14983
15042
|
return e.staticColor;
|
|
14984
15043
|
if (e.type === "continuous")
|
|
14985
15044
|
try {
|
|
14986
|
-
return new
|
|
15045
|
+
return new mk(e).getColor(t);
|
|
14987
15046
|
} catch {
|
|
14988
15047
|
return "black";
|
|
14989
15048
|
}
|
|
14990
15049
|
return "black";
|
|
14991
15050
|
}
|
|
14992
|
-
function
|
|
15051
|
+
function Yg(e, t) {
|
|
14993
15052
|
const {
|
|
14994
15053
|
color: n,
|
|
14995
15054
|
data_field: r,
|
|
14996
15055
|
aggregation: o,
|
|
14997
15056
|
size: i,
|
|
14998
15057
|
weight: a
|
|
14999
|
-
} = e, s =
|
|
15058
|
+
} = e, s = Cs(t, r, o), c = ci(e, s);
|
|
15000
15059
|
return /* @__PURE__ */ l(z, {
|
|
15001
15060
|
sx: {
|
|
15002
15061
|
fontSize: i,
|
|
15003
15062
|
display: "inline"
|
|
15004
15063
|
},
|
|
15005
|
-
color:
|
|
15064
|
+
color: yk(n, s),
|
|
15006
15065
|
weight: a,
|
|
15007
15066
|
children: c
|
|
15008
15067
|
});
|
|
15009
15068
|
}
|
|
15010
|
-
function
|
|
15069
|
+
function bk(e, t) {
|
|
15011
15070
|
const n = {};
|
|
15012
15071
|
return e.forEach((r) => {
|
|
15013
15072
|
const o = r.name;
|
|
15014
|
-
n[o] =
|
|
15073
|
+
n[o] = Yg(r, t);
|
|
15015
15074
|
}), n;
|
|
15016
15075
|
}
|
|
15017
|
-
function
|
|
15076
|
+
function Sk(e) {
|
|
15018
15077
|
return e.split(" ").map((t, n) => /* @__PURE__ */ v(j.Fragment, {
|
|
15019
15078
|
children: [t, "\xA0"]
|
|
15020
15079
|
}, n));
|
|
15021
15080
|
}
|
|
15022
|
-
function
|
|
15081
|
+
function wk(e) {
|
|
15023
15082
|
const n = e.replaceAll("<br />", "<br/>").replaceAll(`
|
|
15024
15083
|
`, "<br/>").split("<br/>");
|
|
15025
15084
|
return n.map((o, i) => {
|
|
15026
|
-
const a = [
|
|
15085
|
+
const a = [Sk(o)];
|
|
15027
15086
|
return i !== n.length - 1 && a.push(/* @__PURE__ */ l("br", {})), a;
|
|
15028
15087
|
}).flat().filter((o) => o !== void 0);
|
|
15029
15088
|
}
|
|
15030
15089
|
function Ia(e) {
|
|
15031
|
-
return
|
|
15090
|
+
return wk(e);
|
|
15032
15091
|
}
|
|
15033
15092
|
function qo(e, t, n) {
|
|
15034
|
-
const r =
|
|
15093
|
+
const r = bk(t, n), o = /^\{(.+)\}(.*)$/;
|
|
15035
15094
|
return e.split("$").map((i) => {
|
|
15036
15095
|
var u;
|
|
15037
15096
|
const a = o.exec(i);
|
|
@@ -15046,15 +15105,15 @@ function qo(e, t, n) {
|
|
|
15046
15105
|
});
|
|
15047
15106
|
});
|
|
15048
15107
|
}
|
|
15049
|
-
function
|
|
15108
|
+
function xk(e, t) {
|
|
15050
15109
|
const n = {};
|
|
15051
15110
|
return e.forEach((r) => {
|
|
15052
|
-
const { name: o, data_field: i, aggregation: a } = r, s =
|
|
15111
|
+
const { name: o, data_field: i, aggregation: a } = r, s = Cs(t, i, a);
|
|
15053
15112
|
n[o] = ci(r, s);
|
|
15054
15113
|
}), n;
|
|
15055
15114
|
}
|
|
15056
|
-
function
|
|
15057
|
-
const r =
|
|
15115
|
+
function Ts(e, t, n) {
|
|
15116
|
+
const r = xk(t, n), o = /^\{(.+)\}(.*)$/;
|
|
15058
15117
|
return e.split("$").map((i) => {
|
|
15059
15118
|
var u;
|
|
15060
15119
|
const a = o.exec(i);
|
|
@@ -15079,7 +15138,7 @@ function pa({ enabled: e, func_content: t }) {
|
|
|
15079
15138
|
};
|
|
15080
15139
|
}
|
|
15081
15140
|
const yl = ["max", "q3", "median", "q1", "min"];
|
|
15082
|
-
function
|
|
15141
|
+
function Ck({ config: e }) {
|
|
15083
15142
|
return {
|
|
15084
15143
|
show: !0,
|
|
15085
15144
|
bottom: 0,
|
|
@@ -15103,7 +15162,7 @@ function wk({ config: e }) {
|
|
|
15103
15162
|
]
|
|
15104
15163
|
};
|
|
15105
15164
|
}
|
|
15106
|
-
function
|
|
15165
|
+
function _k(e) {
|
|
15107
15166
|
return `
|
|
15108
15167
|
<table>
|
|
15109
15168
|
<thead>
|
|
@@ -15118,10 +15177,10 @@ function xk(e) {
|
|
|
15118
15177
|
</table>
|
|
15119
15178
|
`;
|
|
15120
15179
|
}
|
|
15121
|
-
const
|
|
15180
|
+
const Ek = (e) => (t) => {
|
|
15122
15181
|
const { componentSubType: n, value: r } = t;
|
|
15123
15182
|
if (n === "scatter")
|
|
15124
|
-
return
|
|
15183
|
+
return _k(r);
|
|
15125
15184
|
const o = yl.map((a) => `
|
|
15126
15185
|
<tr>
|
|
15127
15186
|
<th style="text-align: left;">${Le.capitalize(a)}</th>
|
|
@@ -15142,14 +15201,14 @@ const Ck = (e) => (t) => {
|
|
|
15142
15201
|
</table>
|
|
15143
15202
|
`;
|
|
15144
15203
|
};
|
|
15145
|
-
function
|
|
15204
|
+
function Ok({ config: e }) {
|
|
15146
15205
|
return {
|
|
15147
15206
|
trigger: "item",
|
|
15148
15207
|
confine: !0,
|
|
15149
|
-
formatter:
|
|
15208
|
+
formatter: Ek(e)
|
|
15150
15209
|
};
|
|
15151
15210
|
}
|
|
15152
|
-
function
|
|
15211
|
+
function Rk(e, t) {
|
|
15153
15212
|
return Object.entries(e).map(([r, o]) => {
|
|
15154
15213
|
var m, b, y, w;
|
|
15155
15214
|
const i = o.map((S) => S[t]).sort((S, O) => S - O), a = (m = _i(i, 0.25)) != null ? m : 0, s = (b = _i(i, 0.5)) != null ? b : 0, c = (y = _i(i, 0.75)) != null ? y : 0, u = c - a, d = a - 1.5 * u, f = c + 1.5 * u, p = Math.max(i[0], d), g = Math.min((w = Le.last(i)) != null ? w : 0, f), h = i.filter((S) => S < p || S > g).map((S) => [r, S]);
|
|
@@ -15164,9 +15223,9 @@ function Ek(e, t) {
|
|
|
15164
15223
|
};
|
|
15165
15224
|
});
|
|
15166
15225
|
}
|
|
15167
|
-
function
|
|
15226
|
+
function Tk(e, t, n) {
|
|
15168
15227
|
const r = t.reduce((o, i) => {
|
|
15169
|
-
const a =
|
|
15228
|
+
const a = Rs(i, n);
|
|
15170
15229
|
return o[i.name] = ci(i, a), o;
|
|
15171
15230
|
}, {});
|
|
15172
15231
|
return e.map((o) => ({
|
|
@@ -15184,15 +15243,15 @@ function Ok(e, t, n) {
|
|
|
15184
15243
|
symbol: ["none", "none"],
|
|
15185
15244
|
label: {
|
|
15186
15245
|
formatter: function() {
|
|
15187
|
-
return
|
|
15246
|
+
return Ts(o.template, t, n);
|
|
15188
15247
|
},
|
|
15189
15248
|
position: "insideEndTop"
|
|
15190
15249
|
}
|
|
15191
15250
|
}
|
|
15192
15251
|
}));
|
|
15193
15252
|
}
|
|
15194
|
-
function
|
|
15195
|
-
const { x_axis: r, y_axis: o, color: i, reference_lines: a } = e, s = Le.groupBy(t, r.data_key), c =
|
|
15253
|
+
function kk({ config: e, data: t, variables: n }) {
|
|
15254
|
+
const { x_axis: r, y_axis: o, color: i, reference_lines: a } = e, s = Le.groupBy(t, r.data_key), c = Rk(s, o.data_key), u = c.map((d) => d.outliers).flat();
|
|
15196
15255
|
return {
|
|
15197
15256
|
dataset: [
|
|
15198
15257
|
{
|
|
@@ -15202,8 +15261,8 @@ function Rk({ config: e, data: t, variables: n }) {
|
|
|
15202
15261
|
source: u
|
|
15203
15262
|
}
|
|
15204
15263
|
],
|
|
15205
|
-
legend:
|
|
15206
|
-
tooltip:
|
|
15264
|
+
legend: Ck({ config: e }),
|
|
15265
|
+
tooltip: Ok({ config: e }),
|
|
15207
15266
|
xAxis: [
|
|
15208
15267
|
{
|
|
15209
15268
|
type: "category",
|
|
@@ -15264,70 +15323,10 @@ function Rk({ config: e, data: t, variables: n }) {
|
|
|
15264
15323
|
},
|
|
15265
15324
|
datasetIndex: 1
|
|
15266
15325
|
},
|
|
15267
|
-
...
|
|
15326
|
+
...Tk(a, n, t)
|
|
15268
15327
|
]
|
|
15269
15328
|
};
|
|
15270
15329
|
}
|
|
15271
|
-
const Yg = {
|
|
15272
|
-
id: "builtin:echarts:click-echart:series",
|
|
15273
|
-
displayName: "Click Chart Series",
|
|
15274
|
-
nameRender: kk,
|
|
15275
|
-
configRender: Tk,
|
|
15276
|
-
payload: [{
|
|
15277
|
-
name: "type",
|
|
15278
|
-
description: "Always 'click'",
|
|
15279
|
-
valueType: "string"
|
|
15280
|
-
}, {
|
|
15281
|
-
name: "seriesType",
|
|
15282
|
-
description: "'boxplot'",
|
|
15283
|
-
valueType: "string"
|
|
15284
|
-
}, {
|
|
15285
|
-
name: "name",
|
|
15286
|
-
description: "Name of the series clicked",
|
|
15287
|
-
valueType: "string"
|
|
15288
|
-
}, {
|
|
15289
|
-
name: "color",
|
|
15290
|
-
description: "Color",
|
|
15291
|
-
valueType: "string"
|
|
15292
|
-
}, {
|
|
15293
|
-
name: "value",
|
|
15294
|
-
description: "Record of 'name', 'min', 'q1', 'median', 'q3', 'max'",
|
|
15295
|
-
valueType: "object"
|
|
15296
|
-
}, {
|
|
15297
|
-
name: "rowData",
|
|
15298
|
-
description: "Data of the row",
|
|
15299
|
-
valueType: "object"
|
|
15300
|
-
}]
|
|
15301
|
-
};
|
|
15302
|
-
function Tk(e) {
|
|
15303
|
-
return /* @__PURE__ */ l(Ae, {});
|
|
15304
|
-
}
|
|
15305
|
-
function kk(e) {
|
|
15306
|
-
return /* @__PURE__ */ l(z, {
|
|
15307
|
-
children: "Click chart's series"
|
|
15308
|
-
});
|
|
15309
|
-
}
|
|
15310
|
-
const jr = {
|
|
15311
|
-
enabled: !1,
|
|
15312
|
-
func_content: ["function label(value, index) {", " // your code goes here", " // return value", "}"].join(`
|
|
15313
|
-
`)
|
|
15314
|
-
}, Ts = {
|
|
15315
|
-
x_axis: {
|
|
15316
|
-
name: "X Axis",
|
|
15317
|
-
data_key: "",
|
|
15318
|
-
axisLabel: {
|
|
15319
|
-
rotate: 0,
|
|
15320
|
-
formatter: { ...jr }
|
|
15321
|
-
}
|
|
15322
|
-
},
|
|
15323
|
-
y_axis: {
|
|
15324
|
-
name: "Y Axis",
|
|
15325
|
-
data_key: "value",
|
|
15326
|
-
label_formatter: Fn
|
|
15327
|
-
},
|
|
15328
|
-
color: "#228be6",
|
|
15329
|
-
reference_lines: []
|
|
15330
|
-
};
|
|
15331
15330
|
$t.use([ni, Ym, Ll, Lr, Vr, Fr, Jn]);
|
|
15332
15331
|
function Mk({
|
|
15333
15332
|
context: e,
|
|
@@ -15340,10 +15339,10 @@ function Mk({
|
|
|
15340
15339
|
} = e, o = e.data, {
|
|
15341
15340
|
width: i,
|
|
15342
15341
|
height: a
|
|
15343
|
-
} = e.viewport, s = jt({}, n,
|
|
15342
|
+
} = e.viewport, s = jt({}, n, xs), c = yo({
|
|
15344
15343
|
vizManager: e.vizManager,
|
|
15345
15344
|
instance: t
|
|
15346
|
-
}), u = vo(c.triggerManager,
|
|
15345
|
+
}), u = vo(c.triggerManager, kg.id), d = fe(() => Le.keyBy(o, s.x_axis.data_key), [o, s.x_axis.data_key]), f = (g) => {
|
|
15347
15346
|
const h = Le.get(d, g.name, {
|
|
15348
15347
|
error: "rowData is not found"
|
|
15349
15348
|
});
|
|
@@ -15353,7 +15352,7 @@ function Mk({
|
|
|
15353
15352
|
rowData: h
|
|
15354
15353
|
});
|
|
15355
15354
|
});
|
|
15356
|
-
}, p = fe(() =>
|
|
15355
|
+
}, p = fe(() => kk({
|
|
15357
15356
|
config: s,
|
|
15358
15357
|
data: o,
|
|
15359
15358
|
variables: r
|
|
@@ -15734,7 +15733,7 @@ function Nk({
|
|
|
15734
15733
|
set: n
|
|
15735
15734
|
} = rt(e.instanceData, "config"), r = e.data, {
|
|
15736
15735
|
variables: o
|
|
15737
|
-
} = e, i = fe(() => jt({}, t,
|
|
15736
|
+
} = e, i = fe(() => jt({}, t, xs), [t]), {
|
|
15738
15737
|
control: a,
|
|
15739
15738
|
handleSubmit: s,
|
|
15740
15739
|
watch: c,
|
|
@@ -15894,6 +15893,8 @@ class zk extends tn {
|
|
|
15894
15893
|
return (o.variables || []).forEach((a) => {
|
|
15895
15894
|
r.variables.find((s) => s.name === a.name) || r.addVariable(a);
|
|
15896
15895
|
}), {
|
|
15896
|
+
...n,
|
|
15897
|
+
version: 2,
|
|
15897
15898
|
config: Lk(o)
|
|
15898
15899
|
};
|
|
15899
15900
|
}), this.version(3, (n) => {
|
|
@@ -15901,6 +15902,7 @@ class zk extends tn {
|
|
|
15901
15902
|
config: r
|
|
15902
15903
|
} = n;
|
|
15903
15904
|
return {
|
|
15905
|
+
...n,
|
|
15904
15906
|
version: 3,
|
|
15905
15907
|
config: Vk(r)
|
|
15906
15908
|
};
|
|
@@ -15909,6 +15911,7 @@ class zk extends tn {
|
|
|
15909
15911
|
config: r
|
|
15910
15912
|
} = n;
|
|
15911
15913
|
return {
|
|
15914
|
+
...n,
|
|
15912
15915
|
version: 4,
|
|
15913
15916
|
config: Fk(r)
|
|
15914
15917
|
};
|
|
@@ -15921,8 +15924,8 @@ const jk = {
|
|
|
15921
15924
|
name: "boxplot",
|
|
15922
15925
|
viewRender: Mk,
|
|
15923
15926
|
configRender: Nk,
|
|
15924
|
-
createConfig: () =>
|
|
15925
|
-
triggers: [
|
|
15927
|
+
createConfig: () => xs,
|
|
15928
|
+
triggers: [kg]
|
|
15926
15929
|
}, Xg = {
|
|
15927
15930
|
id: "builtin:button:click-button",
|
|
15928
15931
|
displayName: "Click Button",
|
|
@@ -16148,24 +16151,28 @@ function Jk({
|
|
|
16148
16151
|
class eM extends tn {
|
|
16149
16152
|
constructor() {
|
|
16150
16153
|
super(...arguments);
|
|
16151
|
-
he(this, "VERSION",
|
|
16154
|
+
he(this, "VERSION", 2);
|
|
16152
16155
|
}
|
|
16153
16156
|
configVersions() {
|
|
16154
16157
|
this.version(1, (n) => ({
|
|
16155
16158
|
version: 1,
|
|
16156
16159
|
config: n
|
|
16157
|
-
})), this.version(2, ({
|
|
16158
|
-
|
|
16159
|
-
|
|
16160
|
-
|
|
16161
|
-
|
|
16162
|
-
|
|
16163
|
-
|
|
16164
|
-
...
|
|
16165
|
-
|
|
16166
|
-
|
|
16167
|
-
|
|
16168
|
-
|
|
16160
|
+
})), this.version(2, (n) => {
|
|
16161
|
+
const {
|
|
16162
|
+
horizontal_align: r = "left",
|
|
16163
|
+
vertical_align: o = "center",
|
|
16164
|
+
...i
|
|
16165
|
+
} = n.config;
|
|
16166
|
+
return {
|
|
16167
|
+
...n,
|
|
16168
|
+
version: 2,
|
|
16169
|
+
config: {
|
|
16170
|
+
...i,
|
|
16171
|
+
horizontal_align: r,
|
|
16172
|
+
vertical_align: o
|
|
16173
|
+
}
|
|
16174
|
+
};
|
|
16175
|
+
});
|
|
16169
16176
|
}
|
|
16170
16177
|
}
|
|
16171
16178
|
const tM = {
|
|
@@ -16283,7 +16290,7 @@ function lM({ type: e, ...t }, n, r, o) {
|
|
|
16283
16290
|
try {
|
|
16284
16291
|
return new Function(`return ${i}`)()(
|
|
16285
16292
|
{ rowData: u, params: c, variables: o },
|
|
16286
|
-
{ lodash: Le, interpolate:
|
|
16293
|
+
{ lodash: Le, interpolate: Os }
|
|
16287
16294
|
);
|
|
16288
16295
|
} catch (d) {
|
|
16289
16296
|
return console.error(`[getEchartsSymbolSize] failed parsing custom function, error: ${d.message}`), 10;
|
|
@@ -16313,7 +16320,7 @@ function sM(e, t, n, r) {
|
|
|
16313
16320
|
symbol: ["none", "none"],
|
|
16314
16321
|
label: {
|
|
16315
16322
|
formatter: function() {
|
|
16316
|
-
return
|
|
16323
|
+
return Ts(o.template, t, r);
|
|
16317
16324
|
},
|
|
16318
16325
|
position: s
|
|
16319
16326
|
}
|
|
@@ -16447,7 +16454,7 @@ function gM(e) {
|
|
|
16447
16454
|
function hM(e, t) {
|
|
16448
16455
|
const n = {};
|
|
16449
16456
|
return t.map((r) => {
|
|
16450
|
-
const o =
|
|
16457
|
+
const o = Rs(r, e);
|
|
16451
16458
|
n[r.name] = ci(r, o);
|
|
16452
16459
|
}), n;
|
|
16453
16460
|
}
|
|
@@ -18695,12 +18702,16 @@ class cD extends tn {
|
|
|
18695
18702
|
}), (dt(o, "stats.variables") || []).forEach((s) => {
|
|
18696
18703
|
r.variables.find((c) => c.name === s.name) || r.addVariable(s);
|
|
18697
18704
|
}), {
|
|
18705
|
+
...n,
|
|
18706
|
+
version: 2,
|
|
18698
18707
|
config: aD(o)
|
|
18699
18708
|
};
|
|
18700
18709
|
}), this.version(3, (n) => ({
|
|
18710
|
+
...n,
|
|
18701
18711
|
version: 3,
|
|
18702
18712
|
config: lD(n.config)
|
|
18703
18713
|
})), this.version(4, (n) => ({
|
|
18714
|
+
...n,
|
|
18704
18715
|
version: 4,
|
|
18705
18716
|
config: sD(n.config)
|
|
18706
18717
|
}));
|
|
@@ -19499,15 +19510,19 @@ class ND extends tn {
|
|
|
19499
19510
|
version: 1,
|
|
19500
19511
|
config: n
|
|
19501
19512
|
})), this.version(2, (n) => ({
|
|
19513
|
+
...n,
|
|
19502
19514
|
version: 2,
|
|
19503
19515
|
config: PD(n.config)
|
|
19504
19516
|
})), this.version(3, (n) => ({
|
|
19517
|
+
...n,
|
|
19505
19518
|
version: 3,
|
|
19506
19519
|
config: ID(n.config)
|
|
19507
19520
|
})), this.version(4, (n) => ({
|
|
19521
|
+
...n,
|
|
19508
19522
|
version: 4,
|
|
19509
19523
|
config: $D(n.config)
|
|
19510
19524
|
})), this.version(5, (n) => ({
|
|
19525
|
+
...n,
|
|
19511
19526
|
version: 5,
|
|
19512
19527
|
config: AD(n.config)
|
|
19513
19528
|
}));
|
|
@@ -20872,11 +20887,11 @@ class yP extends tn {
|
|
|
20872
20887
|
he(this, "VERSION", 2);
|
|
20873
20888
|
}
|
|
20874
20889
|
configVersions() {
|
|
20875
|
-
this.version(1, (n) => ({ config: hP(n) })), this.version(2, (n, { panelModel: r }) => {
|
|
20890
|
+
this.version(1, (n) => ({ version: 1, config: hP(n) })), this.version(2, (n, { panelModel: r }) => {
|
|
20876
20891
|
const { config: o } = n;
|
|
20877
20892
|
return (o.variables || []).forEach((a) => {
|
|
20878
20893
|
r.variables.find((s) => s.name === a.name) || r.addVariable(vP(a));
|
|
20879
|
-
}), { config: mP(o) };
|
|
20894
|
+
}), { ...n, version: 2, config: mP(o) };
|
|
20880
20895
|
});
|
|
20881
20896
|
}
|
|
20882
20897
|
}
|
|
@@ -24281,8 +24296,9 @@ class e$ extends tn {
|
|
|
24281
24296
|
version: 1,
|
|
24282
24297
|
config: n
|
|
24283
24298
|
})), this.version(2, (n) => {
|
|
24284
|
-
const { columns: r, ...o } = n;
|
|
24299
|
+
const { columns: r, ...o } = n.config;
|
|
24285
24300
|
return {
|
|
24301
|
+
...n,
|
|
24286
24302
|
version: 2,
|
|
24287
24303
|
config: {
|
|
24288
24304
|
...o,
|
|
@@ -24366,12 +24382,25 @@ const r$ = ({ conf: e, data: t }) => async () => {
|
|
|
24366
24382
|
goal: "",
|
|
24367
24383
|
question: ""
|
|
24368
24384
|
}, vh = {
|
|
24385
|
+
height: "100%",
|
|
24386
|
+
overflowY: "scroll",
|
|
24369
24387
|
ul: {
|
|
24370
24388
|
paddingLeft: "2em",
|
|
24371
24389
|
margin: "6px 0 0"
|
|
24372
24390
|
},
|
|
24373
24391
|
p: {
|
|
24374
24392
|
margin: 0
|
|
24393
|
+
},
|
|
24394
|
+
a: {
|
|
24395
|
+
WebkitTapHighlightColor: "transparent",
|
|
24396
|
+
color: "rgb(34, 139, 230)",
|
|
24397
|
+
textDecoration: "none",
|
|
24398
|
+
"&:hover": {
|
|
24399
|
+
textDecoration: "underline"
|
|
24400
|
+
},
|
|
24401
|
+
"&:active, &:hover": {
|
|
24402
|
+
outlineWidth: 0
|
|
24403
|
+
}
|
|
24375
24404
|
}
|
|
24376
24405
|
}, pd = ({
|
|
24377
24406
|
message: e
|
|
@@ -24442,6 +24471,7 @@ function i$({
|
|
|
24442
24471
|
height: o
|
|
24443
24472
|
}) : !a || !Array.isArray(a.replies) || a.replies.length === 0 ? null : /* @__PURE__ */ l(ke, {
|
|
24444
24473
|
sx: vh,
|
|
24474
|
+
"data-enable-scrollbar": !0,
|
|
24445
24475
|
children: a.replies.map((d, f) => /* @__PURE__ */ l("div", {
|
|
24446
24476
|
dangerouslySetInnerHTML: {
|
|
24447
24477
|
__html: d.interpretation.html
|
|
@@ -24585,7 +24615,7 @@ function u$({ type: e, ...t }, n, r, o) {
|
|
|
24585
24615
|
try {
|
|
24586
24616
|
return new Function(`return ${i}`)()(
|
|
24587
24617
|
{ rowData: u, params: c, variables: o },
|
|
24588
|
-
{ lodash: Le, interpolate:
|
|
24618
|
+
{ lodash: Le, interpolate: Os }
|
|
24589
24619
|
);
|
|
24590
24620
|
} catch (d) {
|
|
24591
24621
|
return console.error(`[getEchartsSymbolSize] failed parsing custom function, error: ${d.message}`), 10;
|
|
@@ -24610,7 +24640,7 @@ function d$(e, t, n, r) {
|
|
|
24610
24640
|
symbol: ["none", "none"],
|
|
24611
24641
|
label: {
|
|
24612
24642
|
formatter: function() {
|
|
24613
|
-
return
|
|
24643
|
+
return Ts(o.template, t, r);
|
|
24614
24644
|
},
|
|
24615
24645
|
position: s
|
|
24616
24646
|
}
|
|
@@ -24811,7 +24841,7 @@ const w$ = {
|
|
|
24811
24841
|
};
|
|
24812
24842
|
function x$(e, t, n) {
|
|
24813
24843
|
const r = n.reduce((u, d) => {
|
|
24814
|
-
const f =
|
|
24844
|
+
const f = Rs(d, t);
|
|
24815
24845
|
return u[d.name] = ci(d, f), u;
|
|
24816
24846
|
}, {}), o = e.y_axes.reduce(
|
|
24817
24847
|
(u, { label_formatter: d }, f) => (u[f] = function(g) {
|
|
@@ -26218,8 +26248,9 @@ class J$ extends tn {
|
|
|
26218
26248
|
metrics: []
|
|
26219
26249
|
},
|
|
26220
26250
|
...o
|
|
26221
|
-
} = n;
|
|
26251
|
+
} = n.config;
|
|
26222
26252
|
return {
|
|
26253
|
+
...n,
|
|
26223
26254
|
version: 2,
|
|
26224
26255
|
config: {
|
|
26225
26256
|
...o,
|
|
@@ -26227,8 +26258,9 @@ class J$ extends tn {
|
|
|
26227
26258
|
}
|
|
26228
26259
|
};
|
|
26229
26260
|
}), this.version(3, (n) => ({
|
|
26261
|
+
...n,
|
|
26230
26262
|
version: 3,
|
|
26231
|
-
config: Z$(n)
|
|
26263
|
+
config: Z$(n.config)
|
|
26232
26264
|
}));
|
|
26233
26265
|
}
|
|
26234
26266
|
}
|
|
@@ -26483,7 +26515,7 @@ function iA({
|
|
|
26483
26515
|
control: i,
|
|
26484
26516
|
render: ({
|
|
26485
26517
|
field: p
|
|
26486
|
-
}) => /* @__PURE__ */ l(
|
|
26518
|
+
}) => /* @__PURE__ */ l(Dg, {
|
|
26487
26519
|
label: "Font Weight",
|
|
26488
26520
|
...p
|
|
26489
26521
|
})
|
|
@@ -26892,7 +26924,7 @@ class Xs {
|
|
|
26892
26924
|
he(this, "operationManager");
|
|
26893
26925
|
he(this, "triggerManager");
|
|
26894
26926
|
he(this, "attachments");
|
|
26895
|
-
this.operationManager = new OA(t, r), this.triggerManager = new
|
|
26927
|
+
this.operationManager = new OA(t, r), this.triggerManager = new jT(t, n);
|
|
26896
26928
|
const o = async (i) => {
|
|
26897
26929
|
const { id: a, triggerRef: s, operationRef: c } = await i.getItem(null);
|
|
26898
26930
|
return {
|
|
@@ -27754,7 +27786,7 @@ const eN = j.forwardRef(function({
|
|
|
27754
27786
|
value: t.data_field,
|
|
27755
27787
|
onChange: (s) => a("data_field", s)
|
|
27756
27788
|
})]
|
|
27757
|
-
}), /* @__PURE__ */ l(
|
|
27789
|
+
}), /* @__PURE__ */ l(Mg, {
|
|
27758
27790
|
label: "Aggregation",
|
|
27759
27791
|
value: t.aggregation,
|
|
27760
27792
|
onChange: (s) => a("aggregation", s)
|
|
@@ -27765,7 +27797,7 @@ const eN = j.forwardRef(function({
|
|
|
27765
27797
|
}), /* @__PURE__ */ l(zr, {
|
|
27766
27798
|
value: t.formatter,
|
|
27767
27799
|
onChange: (s) => a("formatter", s)
|
|
27768
|
-
}), o && /* @__PURE__ */ l(
|
|
27800
|
+
}), o && /* @__PURE__ */ l(Pg, {
|
|
27769
27801
|
value: t,
|
|
27770
27802
|
onChange: n
|
|
27771
27803
|
})]
|
|
@@ -27824,7 +27856,7 @@ const eN = j.forwardRef(function({
|
|
|
27824
27856
|
children: /* @__PURE__ */ l(kl, {
|
|
27825
27857
|
withBorder: !0,
|
|
27826
27858
|
p: "md",
|
|
27827
|
-
children:
|
|
27859
|
+
children: Yg(e, t)
|
|
27828
27860
|
})
|
|
27829
27861
|
}), oN = Q(rN), iN = (e) => {
|
|
27830
27862
|
const t = Rn(() => QA(e.variable), [e.variable]), {
|