@synnaxlabs/pluto 0.44.8 → 0.45.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/{Animated-fJsLX-Tt.js → Animated-B9bcEALW.js} +2 -2
- package/dist/Animated-EQN_Zecr.cjs +1 -0
- package/dist/{LinePlot-BIZ1E3Rb.js → LinePlot-82qQ7-BC.js} +890 -850
- package/dist/LinePlot-Do2q5AyX.cjs +53 -0
- package/dist/Toggle-BKrbt8lh.cjs +1 -0
- package/dist/{Toggle-BsP_WecR.js → Toggle-BNABJ5M2.js} +2 -2
- package/dist/{Video-CMuBiBcp.js → Video-B4UWip-3.js} +1 -1
- package/dist/{Video-CbaEeyGH.cjs → Video-CgaO8bTm.cjs} +1 -1
- package/dist/button.cjs +1 -1
- package/dist/button.js +1 -1
- package/dist/color.cjs +1 -1
- package/dist/color.js +1 -1
- package/dist/{css-BlHGoCgb.js → css-BUXMI9PB.js} +1082 -990
- package/dist/css-CmXY6iPo.cjs +8 -0
- package/dist/css.cjs +1 -1
- package/dist/css.js +2 -2
- package/dist/dialog.cjs +1 -1
- package/dist/dialog.js +1 -1
- package/dist/eraser-C1jjA5cv.cjs +63 -0
- package/dist/{eraser-BstNvEkO.js → eraser-DXDDmPgV.js} +3097 -2742
- package/dist/ether.cjs +1 -1
- package/dist/ether.js +9 -9
- package/dist/external-5DC2xiKR.cjs +1 -0
- package/dist/{external-CuYkHdQ-.js → external-65blLb4-.js} +2 -2
- package/dist/external-B8KPEzPt.cjs +1 -0
- package/dist/external-BEkAplsH.cjs +1 -0
- package/dist/external-BIykXq97.cjs +1 -0
- package/dist/{external-NISlPgIR.js → external-BKOEKFd7.js} +3 -3
- package/dist/{external-BWwSCjxj.js → external-BOvnkwzO.js} +4 -4
- package/dist/{external-CzyQFMzI.js → external-BSeWLcfY.js} +5 -4
- package/dist/external-Bqmws2bv.cjs +1 -0
- package/dist/external-CFsDBQGs.cjs +1 -0
- package/dist/{external-Poa7jfNM.js → external-CGX7u75x.js} +2 -2
- package/dist/external-CJKfUQ-9.cjs +1 -0
- package/dist/{external-BhMf86-b.js → external-CPW2TrSs.js} +43 -45
- package/dist/external-CijGOPm7.cjs +1 -0
- package/dist/external-DCQ725nK.cjs +1 -0
- package/dist/{external-DVsTr26y.js → external-DLo-151g.js} +13 -10
- package/dist/external-DTLy0px_.js +380 -0
- package/dist/external-DWfn7Yhk.cjs +1 -0
- package/dist/external-DcNW5o-8.cjs +1 -0
- package/dist/{external-B5vTtpm8.js → external-Gh_0tAJ0.js} +2 -2
- package/dist/external-J1Ji-Eku.js +92 -0
- package/dist/{external-YHSSoyM9.js → external-SQa3Pr0s.js} +3 -3
- package/dist/external-W69NXl-R.js +84 -0
- package/dist/{external-C1_CUNeZ.js → external-_ninRYLQ.js} +3 -3
- package/dist/{external-lcuUe52o.cjs → external-kaUzEm1U.cjs} +2 -2
- package/dist/external-mOr1FzAd.cjs +1 -0
- package/dist/flex.cjs +1 -1
- package/dist/flex.js +1 -1
- package/dist/{fontString-Cp4X6CqQ.cjs → fontString-4EFXWlQp.cjs} +1 -1
- package/dist/{fontString-Ca1-oixk.js → fontString-D_jEa-uI.js} +2 -2
- package/dist/header.cjs +1 -1
- package/dist/header.js +1 -1
- package/dist/index.cjs +7 -7
- package/dist/index.js +13247 -12503
- package/dist/input.cjs +1 -1
- package/dist/input.js +1 -1
- package/dist/list.cjs +1 -1
- package/dist/list.js +1 -1
- package/dist/main-2qH2bggR.cjs +92 -0
- package/dist/{Editable-MR16HLlJ.js → main-jKCzbrWn.js} +9355 -9184
- package/dist/menu.cjs +1 -1
- package/dist/menu.js +1 -1
- package/dist/pluto.css +1 -1
- package/dist/src/button/Button.d.ts +3 -2
- package/dist/src/button/Button.d.ts.map +1 -1
- package/dist/src/color/BaseSwatch.d.ts.map +1 -1
- package/dist/src/dialog/Frame.d.ts.map +1 -1
- package/dist/src/flex/Box.d.ts +4 -4
- package/dist/src/flux/core/store.d.ts +38 -27
- package/dist/src/flux/core/store.d.ts.map +1 -1
- package/dist/src/flux/form.d.ts.map +1 -1
- package/dist/src/flux/form.spec.d.ts.map +1 -1
- package/dist/src/flux/list.d.ts +3 -1
- package/dist/src/flux/list.d.ts.map +1 -1
- package/dist/src/flux/list.spec.d.ts.map +1 -1
- package/dist/src/flux/result.spec.d.ts.map +1 -1
- package/dist/src/flux/retrieve.spec.d.ts.map +1 -1
- package/dist/src/flux/update.d.ts +3 -5
- package/dist/src/flux/update.d.ts.map +1 -1
- package/dist/src/flux/update.spec.d.ts.map +1 -1
- package/dist/src/form/Context.d.ts +1 -0
- package/dist/src/form/Context.d.ts.map +1 -1
- package/dist/src/form/state.d.ts +5 -1
- package/dist/src/form/state.d.ts.map +1 -1
- package/dist/src/form/use.d.ts.map +1 -1
- package/dist/src/form/useField.d.ts +3 -2
- package/dist/src/form/useField.d.ts.map +1 -1
- package/dist/src/generic/Generic.d.ts.map +1 -1
- package/dist/src/group/queries.d.ts +4 -3
- package/dist/src/group/queries.d.ts.map +1 -1
- package/dist/src/hardware/task/queries.d.ts +2 -1
- package/dist/src/hardware/task/queries.d.ts.map +1 -1
- package/dist/src/header/Header.d.ts +2 -1
- package/dist/src/header/Header.d.ts.map +1 -1
- package/dist/src/hooks/index.d.ts +1 -0
- package/dist/src/hooks/index.d.ts.map +1 -1
- package/dist/src/hooks/useCursorDrag/useCursorDrag.d.ts.map +1 -1
- package/dist/src/hooks/useCursorDrag/useVirtualCursorDragWebKit.d.ts.map +1 -1
- package/dist/src/hooks/useCursorDrag/useVirtualCursorDragWebView.d.ts.map +1 -1
- package/dist/src/icon/Fitting.d.ts +2 -0
- package/dist/src/icon/Fitting.d.ts.map +1 -0
- package/dist/src/icon/LabJack.d.ts +3 -0
- package/dist/src/icon/LabJack.d.ts.map +1 -0
- package/dist/src/icon/NI.d.ts +2 -0
- package/dist/src/icon/NI.d.ts.map +1 -0
- package/dist/src/icon/OPC.d.ts +2 -0
- package/dist/src/icon/OPC.d.ts.map +1 -0
- package/dist/src/icon/Process.d.ts +2 -0
- package/dist/src/icon/Process.d.ts.map +1 -0
- package/dist/src/icon/Pump.d.ts +2 -0
- package/dist/src/icon/Pump.d.ts.map +1 -0
- package/dist/src/icon/Tank.d.ts +2 -0
- package/dist/src/icon/Tank.d.ts.map +1 -0
- package/dist/src/icon/Valve.d.ts +2 -0
- package/dist/src/icon/Valve.d.ts.map +1 -0
- package/dist/src/icon/external.d.ts +5 -0
- package/dist/src/icon/external.d.ts.map +1 -1
- package/dist/src/icon/registry.d.ts +8 -2
- package/dist/src/icon/registry.d.ts.map +1 -1
- package/dist/src/index.d.ts +2 -1
- package/dist/src/index.d.ts.map +1 -1
- package/dist/src/input/DateTime.d.ts.map +1 -1
- package/dist/src/input/HelpText.d.ts.map +1 -1
- package/dist/src/label/queries.d.ts +1 -1
- package/dist/src/label/queries.d.ts.map +1 -1
- package/dist/src/list/Frame.d.ts.map +1 -1
- package/dist/src/list/Items.d.ts +1 -1
- package/dist/src/list/Items.d.ts.map +1 -1
- package/dist/src/list/external.d.ts +1 -0
- package/dist/src/list/external.d.ts.map +1 -1
- package/dist/src/list/pager.spec.d.ts.map +1 -1
- package/dist/src/list/useCombinedData.d.ts +8 -0
- package/dist/src/list/useCombinedData.d.ts.map +1 -0
- package/dist/src/list/useCombinedData.spec.d.ts +2 -0
- package/dist/src/list/useCombinedData.spec.d.ts.map +1 -0
- package/dist/src/mosaic/use.d.ts.map +1 -1
- package/dist/src/ontology/queries.d.ts +2 -2
- package/dist/src/pluto/Pluto.d.ts +2 -0
- package/dist/src/pluto/Pluto.d.ts.map +1 -1
- package/dist/src/ranger/queries.d.ts +3 -2
- package/dist/src/ranger/queries.d.ts.map +1 -1
- package/dist/src/schematic/external.d.ts +3 -0
- package/dist/src/schematic/external.d.ts.map +1 -0
- package/dist/src/schematic/index.d.ts.map +1 -0
- package/dist/src/schematic/symbol/Custom.d.ts +15 -0
- package/dist/src/schematic/symbol/Custom.d.ts.map +1 -0
- package/dist/src/schematic/symbol/Custom.spec.d.ts +2 -0
- package/dist/src/schematic/symbol/Custom.spec.d.ts.map +1 -0
- package/dist/src/{vis/schematic → schematic/symbol}/Forms.d.ts +7 -5
- package/dist/src/schematic/symbol/Forms.d.ts.map +1 -0
- package/dist/src/schematic/symbol/Grid.d.ts.map +1 -0
- package/dist/src/{vis/schematic/primitives → schematic/symbol}/Primitives.d.ts +18 -7
- package/dist/src/schematic/symbol/Primitives.d.ts.map +1 -0
- package/dist/src/schematic/symbol/SelectOrientation.d.ts.map +1 -0
- package/dist/src/{vis/schematic → schematic/symbol}/Symbols.d.ts +18 -8
- package/dist/src/schematic/symbol/Symbols.d.ts.map +1 -0
- package/dist/src/schematic/symbol/external.d.ts +6 -0
- package/dist/src/schematic/symbol/external.d.ts.map +1 -0
- package/dist/src/schematic/symbol/extractRegions.d.ts +3 -0
- package/dist/src/schematic/symbol/extractRegions.d.ts.map +1 -0
- package/dist/src/schematic/symbol/extractRegions.spec.d.ts +2 -0
- package/dist/src/schematic/symbol/extractRegions.spec.d.ts.map +1 -0
- package/dist/src/schematic/symbol/index.d.ts +2 -0
- package/dist/src/schematic/symbol/index.d.ts.map +1 -0
- package/dist/src/schematic/symbol/queries.d.ts +179 -0
- package/dist/src/schematic/symbol/queries.d.ts.map +1 -0
- package/dist/src/schematic/symbol/queries.spec.d.ts +2 -0
- package/dist/src/schematic/symbol/queries.spec.d.ts.map +1 -0
- package/dist/src/{vis/schematic → schematic/symbol}/registry.d.ts +15 -6
- package/dist/src/schematic/symbol/registry.d.ts.map +1 -0
- package/dist/src/select/use.d.ts.map +1 -1
- package/dist/src/showcase/InputShowcase.d.ts +3 -0
- package/dist/src/showcase/InputShowcase.d.ts.map +1 -1
- package/dist/src/status/aether/aggregator.d.ts +2 -2
- package/dist/src/table/aether/Table.d.ts +4 -0
- package/dist/src/table/aether/Table.d.ts.map +1 -1
- package/dist/src/table/cells/Cells.d.ts +7 -1
- package/dist/src/table/cells/Cells.d.ts.map +1 -1
- package/dist/src/table/cells/registry.d.ts.map +1 -1
- package/dist/src/tabs/Selector.d.ts +3 -2
- package/dist/src/tabs/Selector.d.ts.map +1 -1
- package/dist/src/tabs/Tabs.d.ts +2 -2
- package/dist/src/tabs/Tabs.d.ts.map +1 -1
- package/dist/src/telem/aether/transformers.d.ts.map +1 -1
- package/dist/src/telem/client/streamer.d.ts.map +1 -1
- package/dist/src/telem/control/aether/chip.d.ts +2 -2
- package/dist/src/telem/control/aether/controller.d.ts +1 -1
- package/dist/src/telem/control/aether/indicator.d.ts +7 -7
- package/dist/src/telem/control/aether/legend.d.ts +2 -2
- package/dist/src/telem/control/aether/state.d.ts +1 -1
- package/dist/src/theming/Provider.d.ts +2 -1
- package/dist/src/theming/Provider.d.ts.map +1 -1
- package/dist/src/theming/aether/provider.d.ts +129 -129
- package/dist/src/theming/core/theme.d.ts +131 -131
- package/dist/src/tree/Tree.d.ts.map +1 -1
- package/dist/src/triggers/Text.d.ts.map +1 -1
- package/dist/src/triggers/hooks.d.ts.map +1 -1
- package/dist/src/triggers/triggers.d.ts +11 -11
- package/dist/src/vis/axis/axis.d.ts +2 -2
- package/dist/src/vis/diagram/aether/Diagram.d.ts +4 -0
- package/dist/src/vis/diagram/aether/Diagram.d.ts.map +1 -1
- package/dist/src/vis/line/Line.d.ts.map +1 -1
- package/dist/src/vis/line/aether/line.d.ts +1 -1
- package/dist/src/vis/line/aether/line.d.ts.map +1 -1
- package/dist/src/vis/lineplot/aether/XAxis.d.ts +4 -4
- package/dist/src/vis/lineplot/aether/YAxis.d.ts +4 -4
- package/dist/src/vis/lineplot/aether/axis.d.ts +2 -2
- package/dist/src/vis/lineplot/range/Annotation.d.ts.map +1 -1
- package/dist/src/vis/lineplot/range/aether/annotation.d.ts +4 -4
- package/dist/src/vis/lineplot/tooltip/aether/tooltip.d.ts +8 -8
- package/dist/src/vis/lineplot/useBoundQuerier.d.ts.map +1 -1
- package/dist/src/vis/log/aether/Log.d.ts +3 -3
- package/dist/src/vis/measure/aether/measure.d.ts +8 -8
- package/dist/src/vis/rule/aether/aether.d.ts +2 -2
- package/dist/src/vis/setpoint/aether/setpoint.d.ts +3 -3
- package/dist/src/vis/setpoint/aether/setpoint.d.ts.map +1 -1
- package/dist/src/vis/setpoint/use.d.ts +2 -2
- package/dist/src/vis/setpoint/use.d.ts.map +1 -1
- package/dist/src/vis/value/RedlineForm.d.ts.map +1 -1
- package/dist/src/vis/value/TelemForm.d.ts.map +1 -1
- package/dist/src/vis/value/aether/value.d.ts +23 -3
- package/dist/src/vis/value/aether/value.d.ts.map +1 -1
- package/dist/src/vis/value/use.d.ts +8 -2
- package/dist/src/vis/value/use.d.ts.map +1 -1
- package/dist/tabs.cjs +1 -1
- package/dist/tabs.js +1 -1
- package/dist/text.cjs +1 -1
- package/dist/text.js +2 -2
- package/dist/theming.cjs +1 -1
- package/dist/theming.js +2 -2
- package/dist/tree.cjs +1 -1
- package/dist/tree.js +1 -1
- package/dist/triggers.cjs +1 -1
- package/dist/triggers.js +1 -1
- package/dist/{units-D8blpqyN.js → units-BPvO622s.js} +3 -3
- package/dist/units-DkdMPsxa.cjs +1 -0
- package/dist/video.cjs +1 -1
- package/dist/video.js +1 -1
- package/package.json +8 -8
- package/dist/Animated-CyK_c82a.cjs +0 -1
- package/dist/Editable-B8pvBXQS.cjs +0 -92
- package/dist/LinePlot-DslwDvAo.cjs +0 -53
- package/dist/Toggle-Bqp97ujd.cjs +0 -1
- package/dist/css-CZ_XGkIB.cjs +0 -8
- package/dist/eraser-DiJNbabo.cjs +0 -63
- package/dist/external-0zUBjsWc.cjs +0 -1
- package/dist/external-1ebWGBIY.cjs +0 -1
- package/dist/external-B4A9qxs2.cjs +0 -1
- package/dist/external-BNagUgId.cjs +0 -1
- package/dist/external-Bbrq8Uh2.cjs +0 -1
- package/dist/external-BoI3SDJy.cjs +0 -1
- package/dist/external-CbHi1R5M.cjs +0 -1
- package/dist/external-Cd_bzIsx.cjs +0 -1
- package/dist/external-Cw9nrwGS.cjs +0 -1
- package/dist/external-D0FRmOeg.cjs +0 -1
- package/dist/external-D4Cbm19R.js +0 -69
- package/dist/external-DHgpDWNu.cjs +0 -1
- package/dist/external-DpjNdrhL.js +0 -374
- package/dist/external-H1IGckxo.cjs +0 -1
- package/dist/external-IBOALZ2N.js +0 -82
- package/dist/src/vis/schematic/Forms.d.ts.map +0 -1
- package/dist/src/vis/schematic/Grid.d.ts.map +0 -1
- package/dist/src/vis/schematic/SelectOrientation.d.ts.map +0 -1
- package/dist/src/vis/schematic/Symbols.d.ts.map +0 -1
- package/dist/src/vis/schematic/external.d.ts +0 -4
- package/dist/src/vis/schematic/external.d.ts.map +0 -1
- package/dist/src/vis/schematic/index.d.ts.map +0 -1
- package/dist/src/vis/schematic/primitives/Primitives.d.ts.map +0 -1
- package/dist/src/vis/schematic/primitives/index.d.ts +0 -2
- package/dist/src/vis/schematic/primitives/index.d.ts.map +0 -1
- package/dist/src/vis/schematic/registry.d.ts.map +0 -1
- package/dist/units-Cqxg-SBx.cjs +0 -1
- /package/dist/src/{vis/schematic → schematic}/index.d.ts +0 -0
- /package/dist/src/{vis/schematic → schematic/symbol}/Grid.d.ts +0 -0
- /package/dist/src/{vis/schematic → schematic/symbol}/SelectOrientation.d.ts +0 -0
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { r as
|
|
1
|
+
import { r as A, f as y, d as C, W as U, O as G, i as T, e as oa, x as Ve, g as $, h as la, j as ca, A as pt, w as Jn, a as Q, G as Er, l as Cr, k as es, m as ua, o as Mt, q as se, K as f, p as re, H as p, _ as Ms, R as kr, s as sn, c as Pr, S as ha, $ as da } from "./css-BUXMI9PB.js";
|
|
2
2
|
import we, { z as h } from "zod";
|
|
3
|
-
import { z as
|
|
4
|
-
import { f as
|
|
3
|
+
import { z as Xe, B as Ot, A as Dt, T as Ee, N as rn, v as an, D as Rr, E as fa, F as ae, H as on, I as Mr, J as pa, V as kn, K as ma, M as ue, Q as mt, U as q, W as ga, h as V, u as fe, X as ya, Y as Or, G as va, d as Os, Z as it, $ as ts, a0 as ns, a1 as ba, l as Dr, a2 as wa, a3 as xa, a4 as Sa } from "./eraser-DXDDmPgV.js";
|
|
4
|
+
import { f as rt } from "./fontString-D_jEa-uI.js";
|
|
5
5
|
import "react";
|
|
6
6
|
class Ta {
|
|
7
7
|
handlers;
|
|
@@ -43,14 +43,14 @@ class Ea {
|
|
|
43
43
|
this.handlers.forEach((t, s) => s(e));
|
|
44
44
|
}
|
|
45
45
|
}
|
|
46
|
-
const
|
|
46
|
+
const ss = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
47
47
|
__proto__: null,
|
|
48
48
|
BaseObserver: Ea,
|
|
49
49
|
Observer: Ta
|
|
50
|
-
}, Symbol.toStringTag, { value: "Module" })),
|
|
51
|
-
n.set(
|
|
52
|
-
},
|
|
53
|
-
class ye extends
|
|
50
|
+
}, Symbol.toStringTag, { value: "Module" })), rs = "pluto-vis-renderer", is = (n, e) => {
|
|
51
|
+
n.set(rs, e, !1);
|
|
52
|
+
}, as = (n) => n.get(rs), Ca = (n) => n.getOptional(rs), ge = (n, e) => as(n)(e);
|
|
53
|
+
class ye extends ss.Observer {
|
|
54
54
|
cleanup() {
|
|
55
55
|
}
|
|
56
56
|
}
|
|
@@ -70,7 +70,7 @@ class Rn extends ye {
|
|
|
70
70
|
set() {
|
|
71
71
|
}
|
|
72
72
|
}
|
|
73
|
-
const
|
|
73
|
+
const Lr = {
|
|
74
74
|
type: Rn.TYPE,
|
|
75
75
|
props: {},
|
|
76
76
|
variant: "sink",
|
|
@@ -82,61 +82,61 @@ class Mn extends ye {
|
|
|
82
82
|
return !1;
|
|
83
83
|
}
|
|
84
84
|
}
|
|
85
|
-
const
|
|
85
|
+
const os = {
|
|
86
86
|
type: Mn.TYPE,
|
|
87
87
|
props: {},
|
|
88
88
|
variant: "source",
|
|
89
89
|
valueType: "boolean"
|
|
90
90
|
};
|
|
91
|
-
class
|
|
91
|
+
class On extends ye {
|
|
92
92
|
static TYPE = "noop-numeric-source";
|
|
93
93
|
value() {
|
|
94
94
|
return 0;
|
|
95
95
|
}
|
|
96
96
|
}
|
|
97
|
-
const
|
|
98
|
-
type:
|
|
97
|
+
const _r = {
|
|
98
|
+
type: On.TYPE,
|
|
99
99
|
props: {},
|
|
100
100
|
variant: "source",
|
|
101
101
|
valueType: "number"
|
|
102
102
|
};
|
|
103
|
-
class
|
|
103
|
+
class Dn extends ye {
|
|
104
104
|
static TYPE = "noop-string-source";
|
|
105
105
|
value() {
|
|
106
106
|
return "";
|
|
107
107
|
}
|
|
108
108
|
}
|
|
109
109
|
const Yr = {
|
|
110
|
-
type:
|
|
110
|
+
type: Dn.TYPE,
|
|
111
111
|
props: {},
|
|
112
112
|
variant: "source",
|
|
113
113
|
valueType: "string"
|
|
114
114
|
};
|
|
115
|
-
class
|
|
115
|
+
class Ln extends ye {
|
|
116
116
|
static TYPE = "noop-status-source";
|
|
117
117
|
value() {
|
|
118
118
|
return {
|
|
119
119
|
key: "noop",
|
|
120
120
|
variant: "disabled",
|
|
121
121
|
message: "unknown",
|
|
122
|
-
time:
|
|
122
|
+
time: A.now()
|
|
123
123
|
};
|
|
124
124
|
}
|
|
125
125
|
}
|
|
126
|
-
const
|
|
127
|
-
type:
|
|
126
|
+
const ls = {
|
|
127
|
+
type: Ln.TYPE,
|
|
128
128
|
props: {},
|
|
129
129
|
variant: "source",
|
|
130
130
|
valueType: "status"
|
|
131
131
|
};
|
|
132
|
-
class
|
|
132
|
+
class _n extends ye {
|
|
133
133
|
static TYPE = "noop-color-source";
|
|
134
134
|
value() {
|
|
135
135
|
return y.ZERO;
|
|
136
136
|
}
|
|
137
137
|
}
|
|
138
138
|
const cn = {
|
|
139
|
-
type:
|
|
139
|
+
type: _n.TYPE,
|
|
140
140
|
props: {},
|
|
141
141
|
variant: "source",
|
|
142
142
|
valueType: "color"
|
|
@@ -156,10 +156,10 @@ const Ar = {
|
|
|
156
156
|
[Pn.TYPE]: Pn,
|
|
157
157
|
[Rn.TYPE]: Rn,
|
|
158
158
|
[Mn.TYPE]: Mn,
|
|
159
|
-
[Dn.TYPE]: Dn,
|
|
160
|
-
[_n.TYPE]: _n,
|
|
161
|
-
[Ln.TYPE]: Ln,
|
|
162
159
|
[On.TYPE]: On,
|
|
160
|
+
[Ln.TYPE]: Ln,
|
|
161
|
+
[_n.TYPE]: _n,
|
|
162
|
+
[Dn.TYPE]: Dn,
|
|
163
163
|
[Yn.TYPE]: Yn
|
|
164
164
|
};
|
|
165
165
|
class Nr {
|
|
@@ -169,24 +169,24 @@ class Nr {
|
|
|
169
169
|
return t == null ? null : new t();
|
|
170
170
|
}
|
|
171
171
|
}
|
|
172
|
-
const Pa = h.instanceof(ArrayBuffer),
|
|
172
|
+
const Pa = h.instanceof(ArrayBuffer), gt = h.object({
|
|
173
173
|
type: h.string(),
|
|
174
174
|
variant: h.enum(["source", "sink", "source-transformer", "sink-transformer"]),
|
|
175
175
|
valueType: h.string(),
|
|
176
176
|
props: h.any(),
|
|
177
177
|
transfer: h.array(Pa).optional()
|
|
178
|
-
}), ve =
|
|
178
|
+
}), ve = gt.extend({ variant: h.literal("source") }), un = gt.extend({ variant: h.literal("sink") }), Ir = gt.extend({
|
|
179
179
|
variant: h.literal("source-transformer")
|
|
180
|
-
}), Br =
|
|
180
|
+
}), Br = gt.extend({
|
|
181
181
|
variant: h.literal("sink-transformer")
|
|
182
|
-
}),
|
|
182
|
+
}), Lt = ve.extend({ valueType: h.literal("series") }), cs = ve.extend({
|
|
183
183
|
valueType: h.literal("boolean")
|
|
184
184
|
}), hn = un.extend({ valueType: h.literal("boolean") }), Ra = Br.extend({
|
|
185
185
|
valueType: h.literal("boolean")
|
|
186
186
|
}), Ma = Ir.extend({
|
|
187
187
|
valueType: h.literal("boolean")
|
|
188
|
-
}), Zr = ve.extend({ valueType: h.literal("number") }), Ur = un.extend({ valueType: h.literal("number") }),
|
|
189
|
-
let dn = class extends
|
|
188
|
+
}), Zr = ve.extend({ valueType: h.literal("number") }), Ur = un.extend({ valueType: h.literal("number") }), us = ve.extend({ valueType: h.literal("color") }), hs = ve.extend({ valueType: h.literal("status") }), $r = ve.extend({ valueType: h.literal("string") });
|
|
189
|
+
let dn = class extends ss.BaseObserver {
|
|
190
190
|
props_ = void 0;
|
|
191
191
|
uProps_ = void 0;
|
|
192
192
|
constructor(e) {
|
|
@@ -197,7 +197,7 @@ let dn = class extends ns.BaseObserver {
|
|
|
197
197
|
const e = this.schema.safeParse(this.uProps_);
|
|
198
198
|
if (e.success) this.props_ = e.data;
|
|
199
199
|
else
|
|
200
|
-
throw new
|
|
200
|
+
throw new Xe(
|
|
201
201
|
`[BaseTelem] - expected props to be valid, but found the following errors:
|
|
202
202
|
${e.error.message}`
|
|
203
203
|
);
|
|
@@ -215,7 +215,7 @@ class Ce extends X {
|
|
|
215
215
|
source_ = void 0;
|
|
216
216
|
get source() {
|
|
217
217
|
if (this.source_ == null)
|
|
218
|
-
throw new
|
|
218
|
+
throw new Xe(
|
|
219
219
|
"[UnarySourceTransformer] - expected source to exist, but none was found."
|
|
220
220
|
);
|
|
221
221
|
return this.source_;
|
|
@@ -235,7 +235,7 @@ class Ce extends X {
|
|
|
235
235
|
return !0;
|
|
236
236
|
}
|
|
237
237
|
}
|
|
238
|
-
class
|
|
238
|
+
class qr extends X {
|
|
239
239
|
sources = {};
|
|
240
240
|
value() {
|
|
241
241
|
const e = Object.fromEntries(
|
|
@@ -247,12 +247,12 @@ class Fr extends X {
|
|
|
247
247
|
this.sources = { ...this.sources, ...e };
|
|
248
248
|
}
|
|
249
249
|
}
|
|
250
|
-
class
|
|
250
|
+
class Fr extends dn {
|
|
251
251
|
sinks = {};
|
|
252
252
|
get sink() {
|
|
253
253
|
const [e] = Object.values(this.sinks);
|
|
254
254
|
if (e == null)
|
|
255
|
-
throw new
|
|
255
|
+
throw new Xe(
|
|
256
256
|
"[UnarySinkTransformer] - expected sink to exist, but none was found."
|
|
257
257
|
);
|
|
258
258
|
return e;
|
|
@@ -264,15 +264,15 @@ class qr extends dn {
|
|
|
264
264
|
this.sinks = { ...this.sinks, ...e };
|
|
265
265
|
}
|
|
266
266
|
}
|
|
267
|
-
const
|
|
267
|
+
const ds = h.object({
|
|
268
268
|
from: h.string(),
|
|
269
269
|
to: h.string()
|
|
270
|
-
}),
|
|
271
|
-
connections: h.array(
|
|
270
|
+
}), Hr = h.object({
|
|
271
|
+
connections: h.array(ds),
|
|
272
272
|
outlet: h.string(),
|
|
273
273
|
segments: h.record(h.string(), ve)
|
|
274
274
|
});
|
|
275
|
-
class
|
|
275
|
+
class fs {
|
|
276
276
|
type = "pipeline";
|
|
277
277
|
factory;
|
|
278
278
|
constructor(e) {
|
|
@@ -280,8 +280,8 @@ class ds {
|
|
|
280
280
|
}
|
|
281
281
|
create(e) {
|
|
282
282
|
switch (e.type) {
|
|
283
|
-
case
|
|
284
|
-
return new
|
|
283
|
+
case _t.TYPE:
|
|
284
|
+
return new _t(e.props, this.factory);
|
|
285
285
|
case Yt.TYPE:
|
|
286
286
|
return new Yt(e.props, this.factory);
|
|
287
287
|
default:
|
|
@@ -289,14 +289,14 @@ class ds {
|
|
|
289
289
|
}
|
|
290
290
|
}
|
|
291
291
|
}
|
|
292
|
-
class
|
|
292
|
+
class _t extends X {
|
|
293
293
|
static TYPE = "source-pipeline";
|
|
294
|
-
schema =
|
|
294
|
+
schema = Hr;
|
|
295
295
|
sources = {};
|
|
296
296
|
get outlet() {
|
|
297
297
|
const { outlet: e } = this.props, t = this.sources[e];
|
|
298
298
|
if (t == null)
|
|
299
|
-
throw new
|
|
299
|
+
throw new Xe(
|
|
300
300
|
`[SourcePipeline] - expected source to exist at outlet '${e}', but none was found.`
|
|
301
301
|
);
|
|
302
302
|
return t;
|
|
@@ -322,24 +322,24 @@ class Lt extends X {
|
|
|
322
322
|
Object.values(this.sources).forEach((e) => e.cleanup?.());
|
|
323
323
|
}
|
|
324
324
|
}
|
|
325
|
-
const
|
|
325
|
+
const Oa = (n, e) => ({
|
|
326
326
|
variant: "source",
|
|
327
327
|
props: e,
|
|
328
|
-
type:
|
|
328
|
+
type: _t.TYPE,
|
|
329
329
|
valueType: n
|
|
330
|
-
}),
|
|
331
|
-
connections: h.array(
|
|
330
|
+
}), jr = h.object({
|
|
331
|
+
connections: h.array(ds),
|
|
332
332
|
inlet: h.string(),
|
|
333
333
|
segments: h.record(h.string(), un)
|
|
334
334
|
});
|
|
335
335
|
class Yt extends fn {
|
|
336
336
|
static TYPE = "sink-pipeline";
|
|
337
|
-
schema =
|
|
337
|
+
schema = jr;
|
|
338
338
|
sinks = {};
|
|
339
339
|
get inlet() {
|
|
340
340
|
const { inlet: e } = this.props, t = this.sinks[e];
|
|
341
341
|
if (t == null)
|
|
342
|
-
throw new
|
|
342
|
+
throw new Xe(
|
|
343
343
|
`[SinkPipeline] - expected source to exist at inlet '${e}', but none was found.`
|
|
344
344
|
);
|
|
345
345
|
return t;
|
|
@@ -362,7 +362,7 @@ class Yt extends fn {
|
|
|
362
362
|
Object.values(this.sinks).forEach((e) => e.cleanup?.());
|
|
363
363
|
}
|
|
364
364
|
}
|
|
365
|
-
const
|
|
365
|
+
const Da = (n, e) => ({
|
|
366
366
|
variant: "sink",
|
|
367
367
|
props: e,
|
|
368
368
|
type: Yt.TYPE,
|
|
@@ -393,7 +393,7 @@ class At extends X {
|
|
|
393
393
|
this.removeStreamHandler?.(), this.valid = !1, this.leadingBuffer?.release(), this.leadingBuffer = null, this.removeStreamHandler = null;
|
|
394
394
|
}
|
|
395
395
|
value() {
|
|
396
|
-
return oa.isZero(this.props.channel)
|
|
396
|
+
return oa.isZero(this.props.channel) ? NaN : (this.valid || this.read(), this.leadingBuffer == null || this.leadingBuffer.length === 0 ? NaN : this.leadingBuffer.at(-1, !0));
|
|
397
397
|
}
|
|
398
398
|
async read() {
|
|
399
399
|
try {
|
|
@@ -406,20 +406,20 @@ class At extends X {
|
|
|
406
406
|
};
|
|
407
407
|
this.removeStreamHandler = await this.client.stream(t, [e.key]), this.notify();
|
|
408
408
|
} catch (e) {
|
|
409
|
-
this.valid = !1, this.onStatusChange?.(
|
|
409
|
+
this.valid = !1, this.onStatusChange?.(Ve.fromException(e, "failed to stream channel value"));
|
|
410
410
|
}
|
|
411
411
|
}
|
|
412
412
|
}
|
|
413
413
|
const Wr = async (n, e, t) => {
|
|
414
|
-
const s = await n.retrieveChannel(e), r =
|
|
414
|
+
const s = await n.retrieveChannel(e), r = Ot.isCalculated(s);
|
|
415
415
|
if (!t || s.isIndex)
|
|
416
416
|
return { key: s.key, dataType: s.dataType, virtual: s.virtual, isCalculated: r };
|
|
417
417
|
if (r) {
|
|
418
|
-
const i = await
|
|
418
|
+
const i = await Ot.resolveCalculatedIndex(
|
|
419
419
|
n.retrieveChannel.bind(n),
|
|
420
420
|
s
|
|
421
421
|
);
|
|
422
|
-
if (i == null) throw new
|
|
422
|
+
if (i == null) throw new Dt("Failed to resolve calculated index");
|
|
423
423
|
return {
|
|
424
424
|
key: (await n.retrieveChannel(i)).key,
|
|
425
425
|
dataType: $.TIMESTAMP,
|
|
@@ -428,9 +428,9 @@ const Wr = async (n, e, t) => {
|
|
|
428
428
|
};
|
|
429
429
|
}
|
|
430
430
|
if (s.virtual)
|
|
431
|
-
throw new
|
|
431
|
+
throw new Dt("cannot use virtual channels as a data source");
|
|
432
432
|
return { key: s.index, dataType: $.TIMESTAMP, virtual: !1, isCalculated: r };
|
|
433
|
-
},
|
|
433
|
+
}, La = h.object({
|
|
434
434
|
timeRange: G.z,
|
|
435
435
|
channel: h.number().or(h.string()),
|
|
436
436
|
useIndexOfChannel: h.boolean().optional().default(!1)
|
|
@@ -438,7 +438,7 @@ const Wr = async (n, e, t) => {
|
|
|
438
438
|
class Nt extends X {
|
|
439
439
|
static TYPE = "series-source";
|
|
440
440
|
client;
|
|
441
|
-
schema =
|
|
441
|
+
schema = La;
|
|
442
442
|
data = new U();
|
|
443
443
|
valid = !1;
|
|
444
444
|
channel = null;
|
|
@@ -470,15 +470,15 @@ class Nt extends X {
|
|
|
470
470
|
const r = await this.client.read(e, this.channel.key);
|
|
471
471
|
r.acquire(), this.data = r, this.notify();
|
|
472
472
|
} catch (e) {
|
|
473
|
-
this.valid = !1, this.onStatusChange?.(
|
|
473
|
+
this.valid = !1, this.onStatusChange?.(Ve.fromException(e, "failed to read channel data"));
|
|
474
474
|
}
|
|
475
475
|
}
|
|
476
476
|
}
|
|
477
|
-
const
|
|
477
|
+
const _a = h.object({
|
|
478
478
|
channel: h.number().or(h.string()),
|
|
479
479
|
useIndexOfChannel: h.boolean().optional().default(!1),
|
|
480
|
-
timeSpan:
|
|
481
|
-
keepFor:
|
|
480
|
+
timeSpan: T.z,
|
|
481
|
+
keepFor: T.z.optional()
|
|
482
482
|
});
|
|
483
483
|
class It extends X {
|
|
484
484
|
static TYPE = "dynamic-series-source";
|
|
@@ -489,8 +489,8 @@ class It extends X {
|
|
|
489
489
|
channel = null;
|
|
490
490
|
stopStreaming;
|
|
491
491
|
valid = !1;
|
|
492
|
-
schema =
|
|
493
|
-
constructor(e, t, s, r = () =>
|
|
492
|
+
schema = _a;
|
|
493
|
+
constructor(e, t, s, r = () => A.now()) {
|
|
494
494
|
super(t), this.client = e, this.now = r, this.onStatusChange = s?.onStatusChange;
|
|
495
495
|
}
|
|
496
496
|
value() {
|
|
@@ -524,7 +524,7 @@ class It extends X {
|
|
|
524
524
|
};
|
|
525
525
|
this.stopStreaming = await this.client.stream(i, [this.channel.key]), this.notify();
|
|
526
526
|
} catch (e) {
|
|
527
|
-
this.valid = !1, this.onStatusChange?.(
|
|
527
|
+
this.valid = !1, this.onStatusChange?.(Ve.fromException(e, "failed to stream channel data"));
|
|
528
528
|
}
|
|
529
529
|
}
|
|
530
530
|
gcOutOfRangeData() {
|
|
@@ -586,17 +586,17 @@ class Xr {
|
|
|
586
586
|
}
|
|
587
587
|
}
|
|
588
588
|
}
|
|
589
|
-
const
|
|
589
|
+
const ps = h.object({
|
|
590
590
|
data: h.array(la),
|
|
591
591
|
offsets: h.array(h.number()).optional().default([])
|
|
592
592
|
});
|
|
593
593
|
class An extends X {
|
|
594
594
|
data;
|
|
595
|
-
schema =
|
|
595
|
+
schema = ps;
|
|
596
596
|
static TYPE = "static-series";
|
|
597
597
|
constructor(e) {
|
|
598
598
|
super(e), this.data = this.props.data.map(
|
|
599
|
-
(t, s) => new
|
|
599
|
+
(t, s) => new pt({
|
|
600
600
|
data: t,
|
|
601
601
|
dataType: $.FLOAT32,
|
|
602
602
|
timeRange: G.ZERO,
|
|
@@ -608,7 +608,7 @@ class An extends X {
|
|
|
608
608
|
return [C.max(this.data.map((t) => t.bounds)), this.data];
|
|
609
609
|
}
|
|
610
610
|
}
|
|
611
|
-
const Gr =
|
|
611
|
+
const Gr = ps.extend({
|
|
612
612
|
rate: ca.z,
|
|
613
613
|
yOffset: h.number().optional().default(0),
|
|
614
614
|
scroll: h.number().optional().default(0),
|
|
@@ -623,7 +623,7 @@ class Bt extends X {
|
|
|
623
623
|
data;
|
|
624
624
|
constructor(e) {
|
|
625
625
|
super(e), this.position = this.props.startPosition, this.start(this.props.rate), this.data = this.props.data.map(
|
|
626
|
-
(t, s) => new
|
|
626
|
+
(t, s) => new pt({
|
|
627
627
|
data: t,
|
|
628
628
|
dataType: $.FLOAT32,
|
|
629
629
|
timeRange: G.ZERO,
|
|
@@ -695,7 +695,7 @@ const Ba = (n) => ({
|
|
|
695
695
|
props: n,
|
|
696
696
|
variant: "source",
|
|
697
697
|
valueType: "string"
|
|
698
|
-
}),
|
|
698
|
+
}), qa = (n) => ({
|
|
699
699
|
type: $t.TYPE,
|
|
700
700
|
props: n,
|
|
701
701
|
variant: "source",
|
|
@@ -705,6 +705,8 @@ class ei {
|
|
|
705
705
|
type = "transformer";
|
|
706
706
|
create(e) {
|
|
707
707
|
switch (e.type) {
|
|
708
|
+
case Ie.TYPE:
|
|
709
|
+
return new Ie(e.props);
|
|
708
710
|
case Be.TYPE:
|
|
709
711
|
return new Be(e.props);
|
|
710
712
|
case Ze.TYPE:
|
|
@@ -713,45 +715,43 @@ class ei {
|
|
|
713
715
|
return new Ue(e.props);
|
|
714
716
|
case $e.TYPE:
|
|
715
717
|
return new $e(e.props);
|
|
716
|
-
case
|
|
717
|
-
return new
|
|
718
|
-
case Ft.TYPE:
|
|
719
|
-
return new Ft(e.props);
|
|
718
|
+
case qt.TYPE:
|
|
719
|
+
return new qt(e.props);
|
|
720
720
|
case qe.TYPE:
|
|
721
721
|
return new qe(e.props);
|
|
722
|
-
case
|
|
723
|
-
return new
|
|
722
|
+
case Fe.TYPE:
|
|
723
|
+
return new Fe(e.props);
|
|
724
724
|
}
|
|
725
725
|
return null;
|
|
726
726
|
}
|
|
727
727
|
}
|
|
728
|
-
const
|
|
728
|
+
const Fa = h.object({
|
|
729
729
|
truthy: h.number().optional().default(1),
|
|
730
730
|
falsy: h.number().optional().default(0)
|
|
731
|
-
}),
|
|
731
|
+
}), Ha = (n) => ({
|
|
732
732
|
props: n,
|
|
733
|
-
type:
|
|
733
|
+
type: Ie.TYPE,
|
|
734
734
|
variant: "sink",
|
|
735
735
|
valueType: "boolean"
|
|
736
736
|
});
|
|
737
|
-
class
|
|
737
|
+
class Ie extends Fr {
|
|
738
738
|
static TYPE = "boolean-numeric-converter-sink";
|
|
739
|
-
static propsZ =
|
|
740
|
-
schema =
|
|
739
|
+
static propsZ = Fa;
|
|
740
|
+
schema = Ie.propsZ;
|
|
741
741
|
transform(...e) {
|
|
742
742
|
return e.map((t) => t ? this.props.truthy : this.props.falsy);
|
|
743
743
|
}
|
|
744
744
|
}
|
|
745
|
-
const ti = h.object({ trueBound: C.bounds }),
|
|
745
|
+
const ti = h.object({ trueBound: C.bounds }), ja = (n) => ({
|
|
746
746
|
props: n,
|
|
747
|
-
type:
|
|
747
|
+
type: Be.TYPE,
|
|
748
748
|
variant: "source",
|
|
749
749
|
valueType: "boolean"
|
|
750
750
|
});
|
|
751
|
-
class
|
|
751
|
+
class Be extends Ce {
|
|
752
752
|
static TYPE = "boolean-source";
|
|
753
753
|
static propsZ = ti;
|
|
754
|
-
schema =
|
|
754
|
+
schema = Be.propsZ;
|
|
755
755
|
curr = null;
|
|
756
756
|
shouldNotify(e) {
|
|
757
757
|
const t = C.contains(this.props.trueBound, e) !== this.curr;
|
|
@@ -762,33 +762,33 @@ class Ze extends Ce {
|
|
|
762
762
|
}
|
|
763
763
|
}
|
|
764
764
|
const ni = h.object({});
|
|
765
|
-
class
|
|
765
|
+
class Ze extends qr {
|
|
766
766
|
static TYPE = "mean";
|
|
767
767
|
static propsZ = ni;
|
|
768
|
-
schema =
|
|
768
|
+
schema = Ze.propsZ;
|
|
769
769
|
transform(e) {
|
|
770
770
|
return Object.values(e).reduce((t, s) => t + s, 0) / Object.keys(e).length;
|
|
771
771
|
}
|
|
772
772
|
}
|
|
773
773
|
const za = (n) => ({
|
|
774
774
|
props: n,
|
|
775
|
-
type:
|
|
775
|
+
type: Ze.TYPE,
|
|
776
776
|
variant: "source",
|
|
777
777
|
valueType: "boolean"
|
|
778
778
|
}), si = h.object({
|
|
779
|
-
trueVariant:
|
|
779
|
+
trueVariant: Ve.variantZ.optional().default("success")
|
|
780
780
|
});
|
|
781
|
-
class
|
|
781
|
+
class Ue extends Ce {
|
|
782
782
|
static TYPE = "boolean-status";
|
|
783
783
|
static propsZ = si;
|
|
784
|
-
schema =
|
|
784
|
+
schema = Ue.propsZ;
|
|
785
785
|
transform(e) {
|
|
786
786
|
return e.variant === this.props.trueVariant;
|
|
787
787
|
}
|
|
788
788
|
}
|
|
789
789
|
const Wa = (n) => ({
|
|
790
790
|
props: n,
|
|
791
|
-
type:
|
|
791
|
+
type: Ue.TYPE,
|
|
792
792
|
variant: "source",
|
|
793
793
|
valueType: "boolean"
|
|
794
794
|
}), ri = h.object({
|
|
@@ -797,30 +797,31 @@ const Wa = (n) => ({
|
|
|
797
797
|
suffix: h.string().optional().default(""),
|
|
798
798
|
notation: Jn.notationZ.optional().default("standard")
|
|
799
799
|
});
|
|
800
|
-
class
|
|
800
|
+
class $e extends Ce {
|
|
801
801
|
static TYPE = "stringify-number";
|
|
802
802
|
static propsZ = ri;
|
|
803
|
-
schema =
|
|
803
|
+
schema = $e.propsZ;
|
|
804
804
|
transform(e) {
|
|
805
|
+
if (isNaN(e)) return "";
|
|
805
806
|
const { precision: t, prefix: s, suffix: r, notation: i } = this.props;
|
|
806
807
|
return `${s}${Jn.stringifyNumber(e, t, i)}${r}`;
|
|
807
808
|
}
|
|
808
809
|
}
|
|
809
810
|
const Va = (n) => ({
|
|
810
811
|
props: n,
|
|
811
|
-
type:
|
|
812
|
+
type: $e.TYPE,
|
|
812
813
|
variant: "source",
|
|
813
814
|
valueType: "string"
|
|
814
815
|
}), ii = h.object({
|
|
815
816
|
windowSize: h.number().optional().default(5)
|
|
816
817
|
});
|
|
817
|
-
class
|
|
818
|
+
class qt extends Ce {
|
|
818
819
|
static TYPE = "rolling-average";
|
|
819
820
|
static propsZ = ni;
|
|
820
821
|
schema = ii;
|
|
821
822
|
values = [];
|
|
822
823
|
transform(e) {
|
|
823
|
-
return this.props.windowSize < 2 ? e : this.values.reduce((t, s) => t + s, 0) / this.values.length;
|
|
824
|
+
return this.props.windowSize < 2 || isNaN(e) ? e : this.values.reduce((t, s) => t + s, 0) / this.values.length;
|
|
824
825
|
}
|
|
825
826
|
shouldNotify(e) {
|
|
826
827
|
return this.props.windowSize < 2 ? !0 : (this.values.length > this.props.windowSize && (this.values = []), this.values.push(e), this.values.length === this.props.windowSize);
|
|
@@ -828,7 +829,7 @@ class Ft extends Ce {
|
|
|
828
829
|
}
|
|
829
830
|
const Xa = (n) => ({
|
|
830
831
|
props: n,
|
|
831
|
-
type:
|
|
832
|
+
type: qt.TYPE,
|
|
832
833
|
variant: "source",
|
|
833
834
|
valueType: "number"
|
|
834
835
|
}), ai = h.object({
|
|
@@ -850,26 +851,27 @@ const Ga = (n) => ({
|
|
|
850
851
|
}), oi = h.object({
|
|
851
852
|
scale: Q.transform
|
|
852
853
|
});
|
|
853
|
-
class
|
|
854
|
+
class Fe extends Ce {
|
|
854
855
|
static TYPE = "scale-number";
|
|
855
856
|
static propsZ = oi;
|
|
856
|
-
schema =
|
|
857
|
+
schema = Fe.propsZ;
|
|
857
858
|
transform(e) {
|
|
859
|
+
if (isNaN(e)) return e;
|
|
858
860
|
const { offset: t, scale: s } = this.props.scale;
|
|
859
861
|
return e * s + t;
|
|
860
862
|
}
|
|
861
863
|
}
|
|
862
864
|
const Ka = (n) => ({
|
|
863
865
|
props: n,
|
|
864
|
-
type:
|
|
866
|
+
type: Fe.TYPE,
|
|
865
867
|
variant: "source",
|
|
866
868
|
valueType: "number"
|
|
867
|
-
}),
|
|
868
|
-
mode:
|
|
869
|
+
}), ms = h.enum(["average", "decimate"]), Qa = h.object({
|
|
870
|
+
mode: ms,
|
|
869
871
|
windowSize: h.number().optional().default(5)
|
|
870
872
|
}), Ja = (n) => ({
|
|
871
873
|
props: n,
|
|
872
|
-
type:
|
|
874
|
+
type: at.TYPE,
|
|
873
875
|
variant: "source",
|
|
874
876
|
valueType: "number"
|
|
875
877
|
}), li = (n, e, t) => {
|
|
@@ -888,7 +890,7 @@ const Ka = (n) => ({
|
|
|
888
890
|
l !== void 0 && typeof l == "number" && (a += l, o++);
|
|
889
891
|
}
|
|
890
892
|
o > 0 && e.write(
|
|
891
|
-
new
|
|
893
|
+
new pt({
|
|
892
894
|
data: [a / o],
|
|
893
895
|
dataType: n.dataType
|
|
894
896
|
})
|
|
@@ -898,7 +900,7 @@ const Ka = (n) => ({
|
|
|
898
900
|
decimate: li,
|
|
899
901
|
average: eo
|
|
900
902
|
};
|
|
901
|
-
class
|
|
903
|
+
class at {
|
|
902
904
|
static TYPE = "series-downsampler";
|
|
903
905
|
_downsample = null;
|
|
904
906
|
cache = new U();
|
|
@@ -918,8 +920,8 @@ class ot {
|
|
|
918
920
|
let r = this.cache.series.at(s);
|
|
919
921
|
if (r == null) {
|
|
920
922
|
const i = Math.ceil(t.capacity / this.props.windowSize);
|
|
921
|
-
r =
|
|
922
|
-
key: t.key +
|
|
923
|
+
r = pt.alloc({
|
|
924
|
+
key: t.key + Er.create(),
|
|
923
925
|
dataType: t.dataType,
|
|
924
926
|
capacity: i,
|
|
925
927
|
alignment: t.alignment,
|
|
@@ -937,11 +939,11 @@ class ot {
|
|
|
937
939
|
}
|
|
938
940
|
const no = (n) => ({
|
|
939
941
|
props: n,
|
|
940
|
-
type:
|
|
942
|
+
type: at.TYPE,
|
|
941
943
|
variant: "source",
|
|
942
944
|
valueType: "series"
|
|
943
945
|
});
|
|
944
|
-
class
|
|
946
|
+
class gs {
|
|
945
947
|
factories;
|
|
946
948
|
type = "compound";
|
|
947
949
|
constructor(e) {
|
|
@@ -962,22 +964,22 @@ class ms {
|
|
|
962
964
|
}
|
|
963
965
|
}
|
|
964
966
|
const ci = (n) => {
|
|
965
|
-
const e = [new ei(), new Xr(), new Nr()], t = new
|
|
966
|
-
return n != null && t.add(new Vr(n)), t.add(new
|
|
967
|
+
const e = [new ei(), new Xr(), new Nr()], t = new gs(e);
|
|
968
|
+
return n != null && t.add(new Vr(n)), t.add(new fs(t)), t;
|
|
967
969
|
};
|
|
968
970
|
let ui = class hi {
|
|
969
971
|
factory;
|
|
970
972
|
key;
|
|
971
973
|
parent;
|
|
972
974
|
constructor(e, t) {
|
|
973
|
-
this.factory = e, this.key =
|
|
975
|
+
this.factory = e, this.key = Er.create(), this.parent = t;
|
|
974
976
|
}
|
|
975
977
|
child(e, t) {
|
|
976
|
-
const s = new
|
|
978
|
+
const s = new gs([
|
|
977
979
|
...this.factory.factories,
|
|
978
980
|
...an.toArray(e)
|
|
979
981
|
]);
|
|
980
|
-
return s.add(new
|
|
982
|
+
return s.add(new fs(s)), new hi(s, t);
|
|
981
983
|
}
|
|
982
984
|
create(e, t) {
|
|
983
985
|
const s = this.factory.create(e, t);
|
|
@@ -988,11 +990,11 @@ let ui = class hi {
|
|
|
988
990
|
return s;
|
|
989
991
|
}
|
|
990
992
|
};
|
|
991
|
-
const
|
|
993
|
+
const yt = "pluto-telem-context", pn = (n) => n.get(yt), di = (n, e) => n.set(yt, e), fi = (n, e, t) => {
|
|
992
994
|
const s = pn(n);
|
|
993
995
|
if (s != null && t != null && s.key === t?.parent?.key) return t;
|
|
994
996
|
const r = s.child(e, s);
|
|
995
|
-
return n.set(
|
|
997
|
+
return n.set(yt, r), r;
|
|
996
998
|
};
|
|
997
999
|
class pi {
|
|
998
1000
|
spec;
|
|
@@ -1016,7 +1018,7 @@ class Ds extends pi {
|
|
|
1016
1018
|
return this.wrapped.onChange(e);
|
|
1017
1019
|
}
|
|
1018
1020
|
}
|
|
1019
|
-
class
|
|
1021
|
+
class Ls extends pi {
|
|
1020
1022
|
set(...e) {
|
|
1021
1023
|
this.wrapped.set(...e);
|
|
1022
1024
|
}
|
|
@@ -1031,13 +1033,13 @@ const ee = (n, e, t, s) => {
|
|
|
1031
1033
|
t.cleanup?.();
|
|
1032
1034
|
}
|
|
1033
1035
|
return new Ds(r.create(e, s), r, e);
|
|
1034
|
-
},
|
|
1036
|
+
}, vt = (n, e, t, s) => {
|
|
1035
1037
|
const r = pn(n);
|
|
1036
|
-
if (t instanceof
|
|
1038
|
+
if (t instanceof Ls) {
|
|
1037
1039
|
if (!t.shouldUpdate(r, e)) return t;
|
|
1038
1040
|
t.cleanup?.();
|
|
1039
1041
|
}
|
|
1040
|
-
return new
|
|
1042
|
+
return new Ls(r.create(e, s), r, e);
|
|
1041
1043
|
}, so = h.object({
|
|
1042
1044
|
props: fa.nullable(),
|
|
1043
1045
|
state: Rr.connectivity.connectionStateZ.nullable()
|
|
@@ -1049,27 +1051,27 @@ let Nn = class gi extends ae {
|
|
|
1049
1051
|
static stateZ = so;
|
|
1050
1052
|
schema = gi.stateZ;
|
|
1051
1053
|
afterUpdate(e) {
|
|
1052
|
-
if (e.wasSetPreviously(
|
|
1054
|
+
if (e.wasSetPreviously(ys) || yn(e, mi), this.state.props == null) {
|
|
1053
1055
|
this.internal.client != null && (this.internal.client?.close(), this.internal.client = null), yn(e, this.internal);
|
|
1054
1056
|
return;
|
|
1055
1057
|
}
|
|
1056
1058
|
this.prevState.props != null && rn.equal(this.state.props, this.prevState.props) && this.internal.client != null || (this.internal.client = new Rr(this.state.props), yn(e, this.internal));
|
|
1057
1059
|
}
|
|
1058
1060
|
};
|
|
1059
|
-
const
|
|
1061
|
+
const ys = "pluto-client-context", yn = (n, e) => n.set(ys, e), Ge = (n) => n.get(ys)?.client ?? null, ro = {
|
|
1060
1062
|
[Nn.TYPE]: Nn
|
|
1061
1063
|
}, Zh = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
1062
1064
|
__proto__: null,
|
|
1063
1065
|
Provider: Nn,
|
|
1064
1066
|
REGISTRY: ro,
|
|
1065
1067
|
ZERO_CONTEXT_VALUE: mi,
|
|
1066
|
-
use:
|
|
1068
|
+
use: Ge
|
|
1067
1069
|
}, Symbol.toStringTag, { value: "Module" })), yi = (n, e) => n.dataType.isVariable || n.dataType.equals($.UINT8) ? n : (e == null && n.dataType.equals($.TIMESTAMP) && (e = BigInt(n.data[0])), n.convert($.FLOAT32, e)), io = (n) => n.isVariable || n.equals($.UINT8) ? n : $.FLOAT32, vi = () => ({
|
|
1068
1070
|
purgedSeries: 0,
|
|
1069
|
-
purgedBytes:
|
|
1071
|
+
purgedBytes: Cr.bytes(0)
|
|
1070
1072
|
}), bi = {
|
|
1071
1073
|
instrumentation: on.NOOP,
|
|
1072
|
-
staleEntryThreshold:
|
|
1074
|
+
staleEntryThreshold: T.seconds(20)
|
|
1073
1075
|
};
|
|
1074
1076
|
class ao {
|
|
1075
1077
|
data = [];
|
|
@@ -1107,7 +1109,7 @@ class ao {
|
|
|
1107
1109
|
*/
|
|
1108
1110
|
gc() {
|
|
1109
1111
|
const { staleEntryThreshold: e } = this.props, t = vi(), s = this.data.filter((r) => {
|
|
1110
|
-
const i = r.data.refCount > 0 ||
|
|
1112
|
+
const i = r.data.refCount > 0 || A.since(r.addedAt).lessThan(e);
|
|
1111
1113
|
return i || (t.purgedBytes = t.purgedBytes.add(r.data.byteCapacity)), i;
|
|
1112
1114
|
});
|
|
1113
1115
|
return t.purgedSeries = this.data.length - s.length, this.data = s, t;
|
|
@@ -1135,7 +1137,7 @@ class ao {
|
|
|
1135
1137
|
const { removeBefore: r, removeAfter: i, insertInto: a, deleteInBetween: o } = s;
|
|
1136
1138
|
e = e.slice(r, e.data.length - i), e.length !== 0 && this.data.splice(a, o, {
|
|
1137
1139
|
data: e,
|
|
1138
|
-
addedAt:
|
|
1140
|
+
addedAt: A.now()
|
|
1139
1141
|
});
|
|
1140
1142
|
}
|
|
1141
1143
|
checkIntegrity(e) {
|
|
@@ -1160,7 +1162,7 @@ class fo {
|
|
|
1160
1162
|
avgRate = 0;
|
|
1161
1163
|
timeOfLastWrite;
|
|
1162
1164
|
totalWrites = 0;
|
|
1163
|
-
now = () =>
|
|
1165
|
+
now = () => A.now();
|
|
1164
1166
|
/**
|
|
1165
1167
|
* @constructor
|
|
1166
1168
|
*
|
|
@@ -1197,10 +1199,10 @@ class fo {
|
|
|
1197
1199
|
allocate(e, t, s) {
|
|
1198
1200
|
this.counter++;
|
|
1199
1201
|
const r = this.props.dataType.isVariable, i = this.props.dataType.equals($.TIMESTAMP);
|
|
1200
|
-
return
|
|
1202
|
+
return pt.alloc({
|
|
1201
1203
|
capacity: r ? e * ho : e,
|
|
1202
1204
|
dataType: io(this.props.dataType),
|
|
1203
|
-
timeRange: s.range(
|
|
1205
|
+
timeRange: s.range(A.MAX),
|
|
1204
1206
|
sampleOffset: i ? s.valueOf() : 0,
|
|
1205
1207
|
glBufferUsage: "dynamic",
|
|
1206
1208
|
alignment: t,
|
|
@@ -1237,7 +1239,7 @@ class fo {
|
|
|
1237
1239
|
const { dynamicBufferSize: e } = this.props;
|
|
1238
1240
|
if (typeof e == "number") return e;
|
|
1239
1241
|
if (this.totalWrites < uo) return co;
|
|
1240
|
-
const t =
|
|
1242
|
+
const t = es.roundToNearestMagnitude(this.avgRate * e.seconds);
|
|
1241
1243
|
return Math.round(Math.max(Math.min(t, lo), oo));
|
|
1242
1244
|
}
|
|
1243
1245
|
/**
|
|
@@ -1286,7 +1288,7 @@ class po {
|
|
|
1286
1288
|
gc() {
|
|
1287
1289
|
return this.closed ? (this.ins.L.warn(
|
|
1288
1290
|
`Ignoring attempted garbage collection on a closed cache for channel ${this.channel.name}`
|
|
1289
|
-
), { purgedSeries: 0, purgedBytes:
|
|
1291
|
+
), { purgedSeries: 0, purgedBytes: Cr.bytes(0) }) : this.static.gc();
|
|
1290
1292
|
}
|
|
1291
1293
|
close() {
|
|
1292
1294
|
this.closed = !0, this.dynamic.close(), this.static.close();
|
|
@@ -1379,8 +1381,8 @@ class yo {
|
|
|
1379
1381
|
this.args = {
|
|
1380
1382
|
...e,
|
|
1381
1383
|
instrumentation: e.instrumentation ?? on.NOOP,
|
|
1382
|
-
batchDebounce: e.batchDebounce ??
|
|
1383
|
-
overlapThreshold: e.overlapThreshold ??
|
|
1384
|
+
batchDebounce: e.batchDebounce ?? T.milliseconds(50),
|
|
1385
|
+
overlapThreshold: e.overlapThreshold ?? T.milliseconds(5)
|
|
1384
1386
|
};
|
|
1385
1387
|
const t = this.args.batchDebounce.milliseconds;
|
|
1386
1388
|
this.debouncedRead = pa(() => void this.batchRead(), t);
|
|
@@ -1614,7 +1616,7 @@ class Eo {
|
|
|
1614
1616
|
this.props = {
|
|
1615
1617
|
instrumentation: on.NOOP,
|
|
1616
1618
|
...e,
|
|
1617
|
-
streamUpdateDelay: new
|
|
1619
|
+
streamUpdateDelay: new T(e.streamUpdateDelay ?? T.seconds(5))
|
|
1618
1620
|
};
|
|
1619
1621
|
}
|
|
1620
1622
|
/** Implements StreamClient. */
|
|
@@ -1658,7 +1660,10 @@ class Eo {
|
|
|
1658
1660
|
e.L.debug("streamer keys unchanged", { keys: s });
|
|
1659
1661
|
return;
|
|
1660
1662
|
}
|
|
1661
|
-
this.streamer == null && (e.L.info("creating new streamer", { keys: s }), this.streamer = await this.props.openStreamer(
|
|
1663
|
+
this.streamer == null && (e.L.info("creating new streamer", { keys: s }), this.streamer = await this.props.openStreamer({
|
|
1664
|
+
channels: s,
|
|
1665
|
+
useHighPerformanceCodec: !1
|
|
1666
|
+
}), this.streamerRunLoop = this.runStreamer(this.streamer)), e.L.debug("updating streamer", { prev: this.streamer.keys, next: s }), await this.streamer.update(s);
|
|
1662
1667
|
} catch (t) {
|
|
1663
1668
|
throw e.L.error("failed to update streamer", { error: t }), t;
|
|
1664
1669
|
}
|
|
@@ -1691,7 +1696,7 @@ class Eo {
|
|
|
1691
1696
|
class Co {
|
|
1692
1697
|
/** Implements ChannelClient. */
|
|
1693
1698
|
async retrieveChannel() {
|
|
1694
|
-
throw new
|
|
1699
|
+
throw new Dt("NoopClient does not support retrieving channels");
|
|
1695
1700
|
}
|
|
1696
1701
|
/** Implements ReadClient. */
|
|
1697
1702
|
async read() {
|
|
@@ -1745,15 +1750,15 @@ class ko {
|
|
|
1745
1750
|
}
|
|
1746
1751
|
}
|
|
1747
1752
|
const xi = h.object({});
|
|
1748
|
-
class
|
|
1753
|
+
class ot extends ae {
|
|
1749
1754
|
static TYPE = "telem.Provider";
|
|
1750
1755
|
static stateZ = xi;
|
|
1751
|
-
schema =
|
|
1756
|
+
schema = ot.stateZ;
|
|
1752
1757
|
prevCore = null;
|
|
1753
1758
|
client = null;
|
|
1754
1759
|
afterUpdate(e) {
|
|
1755
|
-
const { internal: t } = this, s =
|
|
1756
|
-
if (t.instrumentation =
|
|
1760
|
+
const { internal: t } = this, s = Ge(e), r = ue(e);
|
|
1761
|
+
if (t.instrumentation = mt(e, "telem").child("provider"), !(s !== this.prevCore || !e.wasSetPreviously(yt))) return;
|
|
1757
1762
|
this.prevCore = s, this.client != null && r(async () => {
|
|
1758
1763
|
if (this.client == null) throw new Error("no client to close");
|
|
1759
1764
|
await this.client.close();
|
|
@@ -1763,76 +1768,76 @@ class lt extends ae {
|
|
|
1763
1768
|
}
|
|
1764
1769
|
}
|
|
1765
1770
|
const Po = {
|
|
1766
|
-
[
|
|
1771
|
+
[ot.TYPE]: ot
|
|
1767
1772
|
}, Uh = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
1768
1773
|
__proto__: null,
|
|
1769
1774
|
AbstractSink: fn,
|
|
1770
1775
|
AbstractSource: X,
|
|
1771
1776
|
Base: dn,
|
|
1772
|
-
BaseProvider:
|
|
1773
|
-
BooleanStatus:
|
|
1774
|
-
CONTEXT_KEY:
|
|
1777
|
+
BaseProvider: ot,
|
|
1778
|
+
BooleanStatus: Ue,
|
|
1779
|
+
CONTEXT_KEY: yt,
|
|
1775
1780
|
ChannelData: Nt,
|
|
1776
1781
|
ColorGradient: qe,
|
|
1777
|
-
CompoundTelemFactory:
|
|
1782
|
+
CompoundTelemFactory: gs,
|
|
1778
1783
|
Context: ui,
|
|
1779
1784
|
FixedColorSource: $t,
|
|
1780
1785
|
FixedNumber: Zt,
|
|
1781
1786
|
FixedString: Ut,
|
|
1782
1787
|
IterativeSeries: Bt,
|
|
1783
|
-
Mean:
|
|
1784
|
-
MultiSourceTransformer:
|
|
1788
|
+
Mean: Ze,
|
|
1789
|
+
MultiSourceTransformer: qr,
|
|
1785
1790
|
NoopFactory: Nr,
|
|
1786
|
-
PipelineFactory:
|
|
1791
|
+
PipelineFactory: fs,
|
|
1787
1792
|
REGISTRY: Po,
|
|
1788
1793
|
RemoteFactory: Vr,
|
|
1789
|
-
RollingAverage:
|
|
1790
|
-
ScaleNumber:
|
|
1791
|
-
SeriesDownsampler:
|
|
1792
|
-
SetPoint:
|
|
1794
|
+
RollingAverage: qt,
|
|
1795
|
+
ScaleNumber: Fe,
|
|
1796
|
+
SeriesDownsampler: at,
|
|
1797
|
+
SetPoint: Ie,
|
|
1793
1798
|
SinkPipeline: Yt,
|
|
1794
|
-
SourcePipeline:
|
|
1799
|
+
SourcePipeline: _t,
|
|
1795
1800
|
StaticFactory: Xr,
|
|
1796
1801
|
StreamChannelData: It,
|
|
1797
1802
|
StreamChannelValue: At,
|
|
1798
|
-
StringifyNumber:
|
|
1803
|
+
StringifyNumber: $e,
|
|
1799
1804
|
TransformerFactory: ei,
|
|
1800
|
-
UnarySinkTransformer:
|
|
1805
|
+
UnarySinkTransformer: Fr,
|
|
1801
1806
|
UnarySourceTransformer: Ce,
|
|
1802
|
-
WithinBounds:
|
|
1807
|
+
WithinBounds: Be,
|
|
1803
1808
|
booleanSinkSpecZ: hn,
|
|
1804
1809
|
booleanSinkTransformerSpecZ: Ra,
|
|
1805
|
-
booleanSourceSpecZ:
|
|
1810
|
+
booleanSourceSpecZ: cs,
|
|
1806
1811
|
booleanSourceTransformerSpecZ: Ma,
|
|
1807
1812
|
booleanStatus: Wa,
|
|
1808
1813
|
booleanStatusProps: si,
|
|
1809
1814
|
channelData: Aa,
|
|
1810
1815
|
colorGradient: Ga,
|
|
1811
1816
|
colorGradientProps: ai,
|
|
1812
|
-
colorSourceSpecZ:
|
|
1813
|
-
connectionZ:
|
|
1817
|
+
colorSourceSpecZ: us,
|
|
1818
|
+
connectionZ: ds,
|
|
1814
1819
|
createFactory: ci,
|
|
1815
1820
|
downsampleMode: Ja,
|
|
1816
1821
|
downsampleModeProps: Qa,
|
|
1817
|
-
downsampleModeZ:
|
|
1822
|
+
downsampleModeZ: ms,
|
|
1818
1823
|
fixedArray: Ba,
|
|
1819
|
-
fixedColor:
|
|
1824
|
+
fixedColor: qa,
|
|
1820
1825
|
fixedColorSourcePropsZ: Jr,
|
|
1821
1826
|
fixedNumber: Ua,
|
|
1822
1827
|
fixedNumberPropsZ: Kr,
|
|
1823
|
-
fixedSeriesPropsZ:
|
|
1828
|
+
fixedSeriesPropsZ: ps,
|
|
1824
1829
|
fixedString: $a,
|
|
1825
1830
|
fixedStringPropsZ: Qr,
|
|
1826
1831
|
iterativeArray: Za,
|
|
1827
1832
|
iterativeSeriesPropsZ: Gr,
|
|
1828
1833
|
mean: za,
|
|
1829
1834
|
noopBooleanSinkSpec: ln,
|
|
1830
|
-
noopBooleanSourceSpec:
|
|
1835
|
+
noopBooleanSourceSpec: os,
|
|
1831
1836
|
noopColorSourceSpec: cn,
|
|
1832
|
-
noopNumericSinkSpec:
|
|
1833
|
-
noopNumericSourceSpec:
|
|
1837
|
+
noopNumericSinkSpec: Lr,
|
|
1838
|
+
noopNumericSourceSpec: _r,
|
|
1834
1839
|
noopSeriesSourceSpec: Ar,
|
|
1835
|
-
noopStatusSourceSpec:
|
|
1840
|
+
noopStatusSourceSpec: ls,
|
|
1836
1841
|
noopStringSourceSpec: Yr,
|
|
1837
1842
|
numberSinkSpecZ: Ur,
|
|
1838
1843
|
numberSourceSpecZ: Zr,
|
|
@@ -1842,19 +1847,19 @@ const Po = {
|
|
|
1842
1847
|
scaleNumber: Ka,
|
|
1843
1848
|
scaleNumberProps: oi,
|
|
1844
1849
|
seriesDownsampler: no,
|
|
1845
|
-
seriesSourceSpecZ:
|
|
1850
|
+
seriesSourceSpecZ: Lt,
|
|
1846
1851
|
setContext: di,
|
|
1847
|
-
setpoint:
|
|
1848
|
-
sinkPipeline:
|
|
1849
|
-
sinkPipelinePropsZ:
|
|
1852
|
+
setpoint: Ha,
|
|
1853
|
+
sinkPipeline: Da,
|
|
1854
|
+
sinkPipelinePropsZ: jr,
|
|
1850
1855
|
sinkSpecZ: un,
|
|
1851
1856
|
sinkTransformerSpecZ: Br,
|
|
1852
|
-
sourcePipeline:
|
|
1853
|
-
sourcePipelinePropsZ:
|
|
1857
|
+
sourcePipeline: Oa,
|
|
1858
|
+
sourcePipelinePropsZ: Hr,
|
|
1854
1859
|
sourceSpecZ: ve,
|
|
1855
1860
|
sourceTransformerSpecZ: Ir,
|
|
1856
|
-
specZ:
|
|
1857
|
-
statusSourceSpecZ:
|
|
1861
|
+
specZ: gt,
|
|
1862
|
+
statusSourceSpecZ: hs,
|
|
1858
1863
|
streamChannelData: Na,
|
|
1859
1864
|
streamChannelValue: Ia,
|
|
1860
1865
|
streamChannelValuePropsZ: zr,
|
|
@@ -1863,9 +1868,9 @@ const Po = {
|
|
|
1863
1868
|
stringifyNumberProps: ri,
|
|
1864
1869
|
useChildContext: fi,
|
|
1865
1870
|
useContext: pn,
|
|
1866
|
-
useSink:
|
|
1871
|
+
useSink: vt,
|
|
1867
1872
|
useSource: ee,
|
|
1868
|
-
withinBounds:
|
|
1873
|
+
withinBounds: ja,
|
|
1869
1874
|
withinBoundsProps: ti
|
|
1870
1875
|
}, Symbol.toStringTag, { value: "Module" })), Ro = we.object({
|
|
1871
1876
|
request: we.string(),
|
|
@@ -1874,7 +1879,7 @@ const Po = {
|
|
|
1874
1879
|
request: we.string(),
|
|
1875
1880
|
response: Ro
|
|
1876
1881
|
});
|
|
1877
|
-
class In extends
|
|
1882
|
+
class In extends q {
|
|
1878
1883
|
static TYPE = "Bounds";
|
|
1879
1884
|
schema = Mo;
|
|
1880
1885
|
afterUpdate(e) {
|
|
@@ -1897,7 +1902,7 @@ const Si = h.object({
|
|
|
1897
1902
|
loc: se.outer
|
|
1898
1903
|
});
|
|
1899
1904
|
h.record(h.string(), Si);
|
|
1900
|
-
const Le = (n, e) => Object.values(e).filter(({ loc: t }) => t === n).sort((t, s) => s.order - t.order),
|
|
1905
|
+
const Le = (n, e) => Object.values(e).filter(({ loc: t }) => t === n).sort((t, s) => s.order - t.order), Oo = (n, e, t) => {
|
|
1901
1906
|
const s = e[n];
|
|
1902
1907
|
if (s == null) return f.ZERO;
|
|
1903
1908
|
const r = se.construct(s.loc), i = Le(r, e), a = se.construct(re.swap(se.direction(r))), o = Le(a, e), c = i.findIndex(({ key: d }) => d === n), l = i.slice(0, c).reduce((d, { size: m }) => d + m, 0), u = o.reduce((d, { size: m }) => d + m, 0);
|
|
@@ -1914,7 +1919,7 @@ const Le = (n, e) => Object.values(e).filter(({ loc: t }) => t === n).sort((t, s
|
|
|
1914
1919
|
-l - s.size
|
|
1915
1920
|
]);
|
|
1916
1921
|
}
|
|
1917
|
-
},
|
|
1922
|
+
}, Do = (n, e) => {
|
|
1918
1923
|
const t = Le("left", n), s = Le("right", n), r = Le("top", n), i = Le("bottom", n), a = t.reduce((u, { size: d }) => u + d, 0), o = s.reduce((u, { size: d }) => u + d, 0), c = r.reduce((u, { size: d }) => u + d, 0), l = i.reduce((u, { size: d }) => u + d, 0);
|
|
1919
1924
|
return p.construct(
|
|
1920
1925
|
f.translate(p.topLeft(e), { x: a, y: c }),
|
|
@@ -1925,12 +1930,12 @@ const Le = (n, e) => Object.values(e).filter(({ loc: t }) => t === n).sort((t, s
|
|
|
1925
1930
|
function Rt(n, e) {
|
|
1926
1931
|
return n == null || e == null ? NaN : n < e ? -1 : n > e ? 1 : n >= e ? 0 : NaN;
|
|
1927
1932
|
}
|
|
1928
|
-
function
|
|
1933
|
+
function Lo(n, e) {
|
|
1929
1934
|
return n == null || e == null ? NaN : e < n ? -1 : e > n ? 1 : e >= n ? 0 : NaN;
|
|
1930
1935
|
}
|
|
1931
|
-
function
|
|
1936
|
+
function vs(n) {
|
|
1932
1937
|
let e, t, s;
|
|
1933
|
-
n.length !== 2 ? (e = Rt, t = (o, c) => Rt(n(o), c), s = (o, c) => n(o) - c) : (e = n === Rt || n ===
|
|
1938
|
+
n.length !== 2 ? (e = Rt, t = (o, c) => Rt(n(o), c), s = (o, c) => n(o) - c) : (e = n === Rt || n === Lo ? n : _o, t = n, s = n);
|
|
1934
1939
|
function r(o, c, l = 0, u = o.length) {
|
|
1935
1940
|
if (l < u) {
|
|
1936
1941
|
if (e(c, c) !== 0) return u;
|
|
@@ -1957,24 +1962,24 @@ function ys(n) {
|
|
|
1957
1962
|
}
|
|
1958
1963
|
return { left: r, center: a, right: i };
|
|
1959
1964
|
}
|
|
1960
|
-
function
|
|
1965
|
+
function _o() {
|
|
1961
1966
|
return 0;
|
|
1962
1967
|
}
|
|
1963
1968
|
function Yo(n) {
|
|
1964
1969
|
return n === null ? NaN : +n;
|
|
1965
1970
|
}
|
|
1966
|
-
const Ao =
|
|
1967
|
-
|
|
1971
|
+
const Ao = vs(Rt), No = Ao.right;
|
|
1972
|
+
vs(Yo).center;
|
|
1968
1973
|
const Io = Math.sqrt(50), Bo = Math.sqrt(10), Zo = Math.sqrt(2);
|
|
1969
|
-
function
|
|
1974
|
+
function Ft(n, e, t) {
|
|
1970
1975
|
const s = (e - n) / Math.max(0, t), r = Math.floor(Math.log10(s)), i = s / Math.pow(10, r), a = i >= Io ? 10 : i >= Bo ? 5 : i >= Zo ? 2 : 1;
|
|
1971
1976
|
let o, c, l;
|
|
1972
|
-
return r < 0 ? (l = Math.pow(10, -r) / a, o = Math.round(n * l), c = Math.round(e * l), o / l < n && ++o, c / l > e && --c, l = -l) : (l = Math.pow(10, r) * a, o = Math.round(n / l), c = Math.round(e / l), o * l < n && ++o, c * l > e && --c), c < o && 0.5 <= t && t < 2 ?
|
|
1977
|
+
return r < 0 ? (l = Math.pow(10, -r) / a, o = Math.round(n * l), c = Math.round(e * l), o / l < n && ++o, c / l > e && --c, l = -l) : (l = Math.pow(10, r) * a, o = Math.round(n / l), c = Math.round(e / l), o * l < n && ++o, c * l > e && --c), c < o && 0.5 <= t && t < 2 ? Ft(n, e, t * 2) : [o, c, l];
|
|
1973
1978
|
}
|
|
1974
1979
|
function Uo(n, e, t) {
|
|
1975
1980
|
if (e = +e, n = +n, t = +t, !(t > 0)) return [];
|
|
1976
1981
|
if (n === e) return [n];
|
|
1977
|
-
const s = e < n, [r, i, a] = s ?
|
|
1982
|
+
const s = e < n, [r, i, a] = s ? Ft(e, n, t) : Ft(n, e, t);
|
|
1978
1983
|
if (!(i >= r)) return [];
|
|
1979
1984
|
const o = i - r + 1, c = new Array(o);
|
|
1980
1985
|
if (s)
|
|
@@ -1985,7 +1990,7 @@ function Uo(n, e, t) {
|
|
|
1985
1990
|
return c;
|
|
1986
1991
|
}
|
|
1987
1992
|
function Bn(n, e, t) {
|
|
1988
|
-
return e = +e, n = +n, t = +t,
|
|
1993
|
+
return e = +e, n = +n, t = +t, Ft(n, e, t)[2];
|
|
1989
1994
|
}
|
|
1990
1995
|
function Zn(n, e, t) {
|
|
1991
1996
|
e = +e, n = +n, t = +t;
|
|
@@ -2005,7 +2010,7 @@ function Ti(n, e) {
|
|
|
2005
2010
|
}
|
|
2006
2011
|
return this;
|
|
2007
2012
|
}
|
|
2008
|
-
function
|
|
2013
|
+
function bs(n, e, t) {
|
|
2009
2014
|
n.prototype = e.prototype = t, t.constructor = n;
|
|
2010
2015
|
}
|
|
2011
2016
|
function Ei(n, e) {
|
|
@@ -2013,9 +2018,9 @@ function Ei(n, e) {
|
|
|
2013
2018
|
for (var s in e) t[s] = e[s];
|
|
2014
2019
|
return t;
|
|
2015
2020
|
}
|
|
2016
|
-
function
|
|
2021
|
+
function bt() {
|
|
2017
2022
|
}
|
|
2018
|
-
var
|
|
2023
|
+
var lt = 0.7, Ht = 1 / lt, Ae = "\\s*([+-]?\\d+)\\s*", ct = "\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*", ie = "\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*", $o = /^#([0-9a-f]{3,8})$/, qo = new RegExp(`^rgb\\(${Ae},${Ae},${Ae}\\)$`), Fo = new RegExp(`^rgb\\(${ie},${ie},${ie}\\)$`), Ho = new RegExp(`^rgba\\(${Ae},${Ae},${Ae},${ct}\\)$`), jo = new RegExp(`^rgba\\(${ie},${ie},${ie},${ct}\\)$`), zo = new RegExp(`^hsl\\(${ct},${ie},${ie}\\)$`), Wo = new RegExp(`^hsla\\(${ct},${ie},${ie},${ct}\\)$`), _s = {
|
|
2019
2024
|
aliceblue: 15792383,
|
|
2020
2025
|
antiquewhite: 16444375,
|
|
2021
2026
|
aqua: 65535,
|
|
@@ -2165,22 +2170,22 @@ var ct = 0.7, jt = 1 / ct, Ne = "\\s*([+-]?\\d+)\\s*", ut = "\\s*([+-]?(?:\\d*\\
|
|
|
2165
2170
|
yellow: 16776960,
|
|
2166
2171
|
yellowgreen: 10145074
|
|
2167
2172
|
};
|
|
2168
|
-
|
|
2173
|
+
bs(bt, ut, {
|
|
2169
2174
|
copy(n) {
|
|
2170
2175
|
return Object.assign(new this.constructor(), this, n);
|
|
2171
2176
|
},
|
|
2172
2177
|
displayable() {
|
|
2173
2178
|
return this.rgb().displayable();
|
|
2174
2179
|
},
|
|
2175
|
-
hex:
|
|
2180
|
+
hex: Ys,
|
|
2176
2181
|
// Deprecated! Use color.formatHex.
|
|
2177
|
-
formatHex:
|
|
2182
|
+
formatHex: Ys,
|
|
2178
2183
|
formatHex8: Vo,
|
|
2179
2184
|
formatHsl: Xo,
|
|
2180
|
-
formatRgb:
|
|
2181
|
-
toString:
|
|
2185
|
+
formatRgb: As,
|
|
2186
|
+
toString: As
|
|
2182
2187
|
});
|
|
2183
|
-
function
|
|
2188
|
+
function Ys() {
|
|
2184
2189
|
return this.rgb().formatHex();
|
|
2185
2190
|
}
|
|
2186
2191
|
function Vo() {
|
|
@@ -2189,62 +2194,62 @@ function Vo() {
|
|
|
2189
2194
|
function Xo() {
|
|
2190
2195
|
return Ci(this).formatHsl();
|
|
2191
2196
|
}
|
|
2192
|
-
function
|
|
2197
|
+
function As() {
|
|
2193
2198
|
return this.rgb().formatRgb();
|
|
2194
2199
|
}
|
|
2195
|
-
function
|
|
2200
|
+
function ut(n) {
|
|
2196
2201
|
var e, t;
|
|
2197
|
-
return n = (n + "").trim().toLowerCase(), (e = $o.exec(n)) ? (t = e[1].length, e = parseInt(e[1], 16), t === 6 ?
|
|
2202
|
+
return n = (n + "").trim().toLowerCase(), (e = $o.exec(n)) ? (t = e[1].length, e = parseInt(e[1], 16), t === 6 ? Ns(e) : t === 3 ? new j(e >> 8 & 15 | e >> 4 & 240, e >> 4 & 15 | e & 240, (e & 15) << 4 | e & 15, 1) : t === 8 ? Et(e >> 24 & 255, e >> 16 & 255, e >> 8 & 255, (e & 255) / 255) : t === 4 ? Et(e >> 12 & 15 | e >> 8 & 240, e >> 8 & 15 | e >> 4 & 240, e >> 4 & 15 | e & 240, ((e & 15) << 4 | e & 15) / 255) : null) : (e = qo.exec(n)) ? new j(e[1], e[2], e[3], 1) : (e = Fo.exec(n)) ? new j(e[1] * 255 / 100, e[2] * 255 / 100, e[3] * 255 / 100, 1) : (e = Ho.exec(n)) ? Et(e[1], e[2], e[3], e[4]) : (e = jo.exec(n)) ? Et(e[1] * 255 / 100, e[2] * 255 / 100, e[3] * 255 / 100, e[4]) : (e = zo.exec(n)) ? Zs(e[1], e[2] / 100, e[3] / 100, 1) : (e = Wo.exec(n)) ? Zs(e[1], e[2] / 100, e[3] / 100, e[4]) : _s.hasOwnProperty(n) ? Ns(_s[n]) : n === "transparent" ? new j(NaN, NaN, NaN, 0) : null;
|
|
2198
2203
|
}
|
|
2199
|
-
function
|
|
2200
|
-
return new
|
|
2204
|
+
function Ns(n) {
|
|
2205
|
+
return new j(n >> 16 & 255, n >> 8 & 255, n & 255, 1);
|
|
2201
2206
|
}
|
|
2202
2207
|
function Et(n, e, t, s) {
|
|
2203
|
-
return s <= 0 && (n = e = t = NaN), new
|
|
2208
|
+
return s <= 0 && (n = e = t = NaN), new j(n, e, t, s);
|
|
2204
2209
|
}
|
|
2205
2210
|
function Go(n) {
|
|
2206
|
-
return n instanceof
|
|
2211
|
+
return n instanceof bt || (n = ut(n)), n ? (n = n.rgb(), new j(n.r, n.g, n.b, n.opacity)) : new j();
|
|
2207
2212
|
}
|
|
2208
2213
|
function Un(n, e, t, s) {
|
|
2209
|
-
return arguments.length === 1 ? Go(n) : new
|
|
2214
|
+
return arguments.length === 1 ? Go(n) : new j(n, e, t, s ?? 1);
|
|
2210
2215
|
}
|
|
2211
|
-
function
|
|
2216
|
+
function j(n, e, t, s) {
|
|
2212
2217
|
this.r = +n, this.g = +e, this.b = +t, this.opacity = +s;
|
|
2213
2218
|
}
|
|
2214
|
-
|
|
2219
|
+
bs(j, Un, Ei(bt, {
|
|
2215
2220
|
brighter(n) {
|
|
2216
|
-
return n = n == null ?
|
|
2221
|
+
return n = n == null ? Ht : Math.pow(Ht, n), new j(this.r * n, this.g * n, this.b * n, this.opacity);
|
|
2217
2222
|
},
|
|
2218
2223
|
darker(n) {
|
|
2219
|
-
return n = n == null ?
|
|
2224
|
+
return n = n == null ? lt : Math.pow(lt, n), new j(this.r * n, this.g * n, this.b * n, this.opacity);
|
|
2220
2225
|
},
|
|
2221
2226
|
rgb() {
|
|
2222
2227
|
return this;
|
|
2223
2228
|
},
|
|
2224
2229
|
clamp() {
|
|
2225
|
-
return new
|
|
2230
|
+
return new j(Se(this.r), Se(this.g), Se(this.b), jt(this.opacity));
|
|
2226
2231
|
},
|
|
2227
2232
|
displayable() {
|
|
2228
2233
|
return -0.5 <= this.r && this.r < 255.5 && -0.5 <= this.g && this.g < 255.5 && -0.5 <= this.b && this.b < 255.5 && 0 <= this.opacity && this.opacity <= 1;
|
|
2229
2234
|
},
|
|
2230
|
-
hex:
|
|
2235
|
+
hex: Is,
|
|
2231
2236
|
// Deprecated! Use color.formatHex.
|
|
2232
|
-
formatHex:
|
|
2237
|
+
formatHex: Is,
|
|
2233
2238
|
formatHex8: Ko,
|
|
2234
|
-
formatRgb:
|
|
2235
|
-
toString:
|
|
2239
|
+
formatRgb: Bs,
|
|
2240
|
+
toString: Bs
|
|
2236
2241
|
}));
|
|
2237
|
-
function
|
|
2242
|
+
function Is() {
|
|
2238
2243
|
return `#${xe(this.r)}${xe(this.g)}${xe(this.b)}`;
|
|
2239
2244
|
}
|
|
2240
2245
|
function Ko() {
|
|
2241
2246
|
return `#${xe(this.r)}${xe(this.g)}${xe(this.b)}${xe((isNaN(this.opacity) ? 1 : this.opacity) * 255)}`;
|
|
2242
2247
|
}
|
|
2243
|
-
function
|
|
2244
|
-
const n =
|
|
2248
|
+
function Bs() {
|
|
2249
|
+
const n = jt(this.opacity);
|
|
2245
2250
|
return `${n === 1 ? "rgb(" : "rgba("}${Se(this.r)}, ${Se(this.g)}, ${Se(this.b)}${n === 1 ? ")" : `, ${n})`}`;
|
|
2246
2251
|
}
|
|
2247
|
-
function
|
|
2252
|
+
function jt(n) {
|
|
2248
2253
|
return isNaN(n) ? 1 : Math.max(0, Math.min(1, n));
|
|
2249
2254
|
}
|
|
2250
2255
|
function Se(n) {
|
|
@@ -2253,12 +2258,12 @@ function Se(n) {
|
|
|
2253
2258
|
function xe(n) {
|
|
2254
2259
|
return n = Se(n), (n < 16 ? "0" : "") + n.toString(16);
|
|
2255
2260
|
}
|
|
2256
|
-
function
|
|
2261
|
+
function Zs(n, e, t, s) {
|
|
2257
2262
|
return s <= 0 ? n = e = t = NaN : t <= 0 || t >= 1 ? n = e = NaN : e <= 0 && (n = NaN), new ne(n, e, t, s);
|
|
2258
2263
|
}
|
|
2259
2264
|
function Ci(n) {
|
|
2260
2265
|
if (n instanceof ne) return new ne(n.h, n.s, n.l, n.opacity);
|
|
2261
|
-
if (n instanceof
|
|
2266
|
+
if (n instanceof bt || (n = ut(n)), !n) return new ne();
|
|
2262
2267
|
if (n instanceof ne) return n;
|
|
2263
2268
|
n = n.rgb();
|
|
2264
2269
|
var e = n.r / 255, t = n.g / 255, s = n.b / 255, r = Math.min(e, t, s), i = Math.max(e, t, s), a = NaN, o = i - r, c = (i + r) / 2;
|
|
@@ -2270,16 +2275,16 @@ function Qo(n, e, t, s) {
|
|
|
2270
2275
|
function ne(n, e, t, s) {
|
|
2271
2276
|
this.h = +n, this.s = +e, this.l = +t, this.opacity = +s;
|
|
2272
2277
|
}
|
|
2273
|
-
|
|
2278
|
+
bs(ne, Qo, Ei(bt, {
|
|
2274
2279
|
brighter(n) {
|
|
2275
|
-
return n = n == null ?
|
|
2280
|
+
return n = n == null ? Ht : Math.pow(Ht, n), new ne(this.h, this.s, this.l * n, this.opacity);
|
|
2276
2281
|
},
|
|
2277
2282
|
darker(n) {
|
|
2278
|
-
return n = n == null ?
|
|
2283
|
+
return n = n == null ? lt : Math.pow(lt, n), new ne(this.h, this.s, this.l * n, this.opacity);
|
|
2279
2284
|
},
|
|
2280
2285
|
rgb() {
|
|
2281
2286
|
var n = this.h % 360 + (this.h < 0) * 360, e = isNaN(n) || isNaN(this.s) ? 0 : this.s, t = this.l, s = t + (t < 0.5 ? t : 1 - t) * e, r = 2 * t - s;
|
|
2282
|
-
return new
|
|
2287
|
+
return new j(
|
|
2283
2288
|
vn(n >= 240 ? n - 240 : n + 120, r, s),
|
|
2284
2289
|
vn(n, r, s),
|
|
2285
2290
|
vn(n < 120 ? n + 240 : n - 120, r, s),
|
|
@@ -2287,17 +2292,17 @@ vs(ne, Qo, Ei(wt, {
|
|
|
2287
2292
|
);
|
|
2288
2293
|
},
|
|
2289
2294
|
clamp() {
|
|
2290
|
-
return new ne(
|
|
2295
|
+
return new ne(Us(this.h), Ct(this.s), Ct(this.l), jt(this.opacity));
|
|
2291
2296
|
},
|
|
2292
2297
|
displayable() {
|
|
2293
2298
|
return (0 <= this.s && this.s <= 1 || isNaN(this.s)) && 0 <= this.l && this.l <= 1 && 0 <= this.opacity && this.opacity <= 1;
|
|
2294
2299
|
},
|
|
2295
2300
|
formatHsl() {
|
|
2296
|
-
const n =
|
|
2297
|
-
return `${n === 1 ? "hsl(" : "hsla("}${
|
|
2301
|
+
const n = jt(this.opacity);
|
|
2302
|
+
return `${n === 1 ? "hsl(" : "hsla("}${Us(this.h)}, ${Ct(this.s) * 100}%, ${Ct(this.l) * 100}%${n === 1 ? ")" : `, ${n})`}`;
|
|
2298
2303
|
}
|
|
2299
2304
|
}));
|
|
2300
|
-
function
|
|
2305
|
+
function Us(n) {
|
|
2301
2306
|
return n = (n || 0) % 360, n < 0 ? n + 360 : n;
|
|
2302
2307
|
}
|
|
2303
2308
|
function Ct(n) {
|
|
@@ -2306,7 +2311,7 @@ function Ct(n) {
|
|
|
2306
2311
|
function vn(n, e, t) {
|
|
2307
2312
|
return (n < 60 ? e + (t - e) * n / 60 : n < 180 ? t : n < 240 ? e + (t - e) * (240 - n) / 60 : e) * 255;
|
|
2308
2313
|
}
|
|
2309
|
-
const
|
|
2314
|
+
const ws = (n) => () => n;
|
|
2310
2315
|
function Jo(n, e) {
|
|
2311
2316
|
return function(t) {
|
|
2312
2317
|
return n + t * e;
|
|
@@ -2319,14 +2324,14 @@ function el(n, e, t) {
|
|
|
2319
2324
|
}
|
|
2320
2325
|
function tl(n) {
|
|
2321
2326
|
return (n = +n) == 1 ? ki : function(e, t) {
|
|
2322
|
-
return t - e ? el(e, t, n) :
|
|
2327
|
+
return t - e ? el(e, t, n) : ws(isNaN(e) ? t : e);
|
|
2323
2328
|
};
|
|
2324
2329
|
}
|
|
2325
2330
|
function ki(n, e) {
|
|
2326
2331
|
var t = e - n;
|
|
2327
|
-
return t ? Jo(n, t) :
|
|
2332
|
+
return t ? Jo(n, t) : ws(isNaN(n) ? e : n);
|
|
2328
2333
|
}
|
|
2329
|
-
const
|
|
2334
|
+
const $s = function n(e) {
|
|
2330
2335
|
var t = tl(e);
|
|
2331
2336
|
function s(r, i) {
|
|
2332
2337
|
var a = t((r = Un(r)).r, (i = Un(i)).r), o = t(r.g, i.g), c = t(r.b, i.b), l = ki(r.opacity, i.opacity);
|
|
@@ -2349,7 +2354,7 @@ function sl(n) {
|
|
|
2349
2354
|
}
|
|
2350
2355
|
function rl(n, e) {
|
|
2351
2356
|
var t = e ? e.length : 0, s = n ? Math.min(t, n.length) : 0, r = new Array(s), i = new Array(t), a;
|
|
2352
|
-
for (a = 0; a < s; ++a) r[a] =
|
|
2357
|
+
for (a = 0; a < s; ++a) r[a] = xs(n[a], e[a]);
|
|
2353
2358
|
for (; a < t; ++a) i[a] = e[a];
|
|
2354
2359
|
return function(o) {
|
|
2355
2360
|
for (a = 0; a < s; ++a) i[a] = r[a](o);
|
|
@@ -2371,7 +2376,7 @@ function al(n, e) {
|
|
|
2371
2376
|
var t = {}, s = {}, r;
|
|
2372
2377
|
(n === null || typeof n != "object") && (n = {}), (e === null || typeof e != "object") && (e = {});
|
|
2373
2378
|
for (r in e)
|
|
2374
|
-
r in n ? t[r] =
|
|
2379
|
+
r in n ? t[r] = xs(n[r], e[r]) : s[r] = e[r];
|
|
2375
2380
|
return function(i) {
|
|
2376
2381
|
for (r in t) s[r] = t[r](i);
|
|
2377
2382
|
return s;
|
|
@@ -2397,9 +2402,9 @@ function cl(n, e) {
|
|
|
2397
2402
|
return o.join("");
|
|
2398
2403
|
});
|
|
2399
2404
|
}
|
|
2400
|
-
function
|
|
2405
|
+
function xs(n, e) {
|
|
2401
2406
|
var t = typeof e, s;
|
|
2402
|
-
return e == null || t === "boolean" ?
|
|
2407
|
+
return e == null || t === "boolean" ? ws(e) : (t === "number" ? zt : t === "string" ? (s = ut(e)) ? (e = s, $s) : cl : e instanceof ut ? $s : e instanceof Date ? il : sl(e) ? nl : Array.isArray(e) ? rl : typeof e.valueOf != "function" && typeof e.toString != "function" || isNaN(e) ? al : zt)(n, e);
|
|
2403
2408
|
}
|
|
2404
2409
|
function ul(n, e) {
|
|
2405
2410
|
return n = +n, e = +e, function(t) {
|
|
@@ -2414,11 +2419,11 @@ function hl(n) {
|
|
|
2414
2419
|
function dl(n) {
|
|
2415
2420
|
return +n;
|
|
2416
2421
|
}
|
|
2417
|
-
var
|
|
2418
|
-
function
|
|
2422
|
+
var qs = [0, 1];
|
|
2423
|
+
function _e(n) {
|
|
2419
2424
|
return n;
|
|
2420
2425
|
}
|
|
2421
|
-
function
|
|
2426
|
+
function qn(n, e) {
|
|
2422
2427
|
return (e -= n = +n) ? function(t) {
|
|
2423
2428
|
return (t - n) / e;
|
|
2424
2429
|
} : hl(isNaN(e) ? NaN : 0.5);
|
|
@@ -2431,14 +2436,14 @@ function fl(n, e) {
|
|
|
2431
2436
|
}
|
|
2432
2437
|
function pl(n, e, t) {
|
|
2433
2438
|
var s = n[0], r = n[1], i = e[0], a = e[1];
|
|
2434
|
-
return r < s ? (s =
|
|
2439
|
+
return r < s ? (s = qn(r, s), i = t(a, i)) : (s = qn(s, r), i = t(i, a)), function(o) {
|
|
2435
2440
|
return i(s(o));
|
|
2436
2441
|
};
|
|
2437
2442
|
}
|
|
2438
2443
|
function ml(n, e, t) {
|
|
2439
2444
|
var s = Math.min(n.length, e.length) - 1, r = new Array(s), i = new Array(s), a = -1;
|
|
2440
2445
|
for (n[s] < n[0] && (n = n.slice().reverse(), e = e.slice().reverse()); ++a < s; )
|
|
2441
|
-
r[a] =
|
|
2446
|
+
r[a] = qn(n[a], n[a + 1]), i[a] = t(e[a], e[a + 1]);
|
|
2442
2447
|
return function(o) {
|
|
2443
2448
|
var c = No(n, o, 1, s) - 1;
|
|
2444
2449
|
return i[c](r[c](o));
|
|
@@ -2448,10 +2453,10 @@ function Pi(n, e) {
|
|
|
2448
2453
|
return e.domain(n.domain()).range(n.range()).interpolate(n.interpolate()).clamp(n.clamp()).unknown(n.unknown());
|
|
2449
2454
|
}
|
|
2450
2455
|
function gl() {
|
|
2451
|
-
var n =
|
|
2456
|
+
var n = qs, e = qs, t = xs, s, r, i, a = _e, o, c, l;
|
|
2452
2457
|
function u() {
|
|
2453
2458
|
var m = Math.min(n.length, e.length);
|
|
2454
|
-
return a !==
|
|
2459
|
+
return a !== _e && (a = fl(n[0], n[m - 1])), o = m > 2 ? ml : pl, c = l = null, d;
|
|
2455
2460
|
}
|
|
2456
2461
|
function d(m) {
|
|
2457
2462
|
return m == null || isNaN(m = +m) ? i : (c || (c = o(n.map(s), e, t)))(s(a(m)));
|
|
@@ -2465,7 +2470,7 @@ function gl() {
|
|
|
2465
2470
|
}, d.rangeRound = function(m) {
|
|
2466
2471
|
return e = Array.from(m), t = ul, u();
|
|
2467
2472
|
}, d.clamp = function(m) {
|
|
2468
|
-
return arguments.length ? (a = m ? !0 :
|
|
2473
|
+
return arguments.length ? (a = m ? !0 : _e, u()) : a !== _e;
|
|
2469
2474
|
}, d.interpolate = function(m) {
|
|
2470
2475
|
return arguments.length ? (t = m, u()) : t;
|
|
2471
2476
|
}, d.unknown = function(m) {
|
|
@@ -2475,7 +2480,7 @@ function gl() {
|
|
|
2475
2480
|
};
|
|
2476
2481
|
}
|
|
2477
2482
|
function Ri() {
|
|
2478
|
-
return gl()(
|
|
2483
|
+
return gl()(_e, _e);
|
|
2479
2484
|
}
|
|
2480
2485
|
function yl(n) {
|
|
2481
2486
|
return Math.abs(n = Math.round(n)) >= 1e21 ? n.toLocaleString("en").replace(/,/g, "") : n.toString(10);
|
|
@@ -2509,7 +2514,7 @@ var wl = /^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?
|
|
|
2509
2514
|
function Vt(n) {
|
|
2510
2515
|
if (!(e = wl.exec(n))) throw new Error("invalid format: " + n);
|
|
2511
2516
|
var e;
|
|
2512
|
-
return new
|
|
2517
|
+
return new Ss({
|
|
2513
2518
|
fill: e[1],
|
|
2514
2519
|
align: e[2],
|
|
2515
2520
|
sign: e[3],
|
|
@@ -2522,11 +2527,11 @@ function Vt(n) {
|
|
|
2522
2527
|
type: e[10]
|
|
2523
2528
|
});
|
|
2524
2529
|
}
|
|
2525
|
-
Vt.prototype =
|
|
2526
|
-
function
|
|
2530
|
+
Vt.prototype = Ss.prototype;
|
|
2531
|
+
function Ss(n) {
|
|
2527
2532
|
this.fill = n.fill === void 0 ? " " : n.fill + "", this.align = n.align === void 0 ? ">" : n.align + "", this.sign = n.sign === void 0 ? "-" : n.sign + "", this.symbol = n.symbol === void 0 ? "" : n.symbol + "", this.zero = !!n.zero, this.width = n.width === void 0 ? void 0 : +n.width, this.comma = !!n.comma, this.precision = n.precision === void 0 ? void 0 : +n.precision, this.trim = !!n.trim, this.type = n.type === void 0 ? "" : n.type + "";
|
|
2528
2533
|
}
|
|
2529
|
-
|
|
2534
|
+
Ss.prototype.toString = function() {
|
|
2530
2535
|
return this.fill + this.align + this.sign + this.symbol + (this.zero ? "0" : "") + (this.width === void 0 ? "" : Math.max(1, this.width | 0)) + (this.comma ? "," : "") + (this.precision === void 0 ? "" : "." + Math.max(0, this.precision | 0)) + (this.trim ? "~" : "") + this.type;
|
|
2531
2536
|
};
|
|
2532
2537
|
function xl(n) {
|
|
@@ -2558,7 +2563,7 @@ function Fs(n, e) {
|
|
|
2558
2563
|
var s = t[0], r = t[1];
|
|
2559
2564
|
return r < 0 ? "0." + new Array(-r).join("0") + s : s.length > r + 1 ? s.slice(0, r + 1) + "." + s.slice(r + 1) : s + new Array(r - s.length + 2).join("0");
|
|
2560
2565
|
}
|
|
2561
|
-
const
|
|
2566
|
+
const Hs = {
|
|
2562
2567
|
"%": (n, e) => (n * 100).toFixed(e),
|
|
2563
2568
|
b: (n) => Math.round(n).toString(2),
|
|
2564
2569
|
c: (n) => n + "",
|
|
@@ -2576,54 +2581,54 @@ const qs = {
|
|
|
2576
2581
|
function js(n) {
|
|
2577
2582
|
return n;
|
|
2578
2583
|
}
|
|
2579
|
-
var
|
|
2584
|
+
var zs = Array.prototype.map, Ws = ["y", "z", "a", "f", "p", "n", "µ", "m", "", "k", "M", "G", "T", "P", "E", "Z", "Y"];
|
|
2580
2585
|
function Tl(n) {
|
|
2581
|
-
var e = n.grouping === void 0 || n.thousands === void 0 ? js : vl(
|
|
2586
|
+
var e = n.grouping === void 0 || n.thousands === void 0 ? js : vl(zs.call(n.grouping, Number), n.thousands + ""), t = n.currency === void 0 ? "" : n.currency[0] + "", s = n.currency === void 0 ? "" : n.currency[1] + "", r = n.decimal === void 0 ? "." : n.decimal + "", i = n.numerals === void 0 ? js : bl(zs.call(n.numerals, String)), a = n.percent === void 0 ? "%" : n.percent + "", o = n.minus === void 0 ? "−" : n.minus + "", c = n.nan === void 0 ? "NaN" : n.nan + "";
|
|
2582
2587
|
function l(d) {
|
|
2583
2588
|
d = Vt(d);
|
|
2584
|
-
var m = d.fill, v = d.align,
|
|
2585
|
-
|
|
2586
|
-
var E = w === "$" ? t : w === "#" && /[boxX]/.test(
|
|
2587
|
-
M = M === void 0 ? 6 : /[gprs]/.test(
|
|
2588
|
-
function
|
|
2589
|
-
var oe = E,
|
|
2590
|
-
if (
|
|
2591
|
-
|
|
2589
|
+
var m = d.fill, v = d.align, S = d.sign, w = d.symbol, x = d.zero, R = d.width, L = d.comma, M = d.precision, Y = d.trim, N = d.type;
|
|
2590
|
+
N === "n" ? (L = !0, N = "g") : Hs[N] || (M === void 0 && (M = 12), Y = !0, N = "g"), (x || m === "0" && v === "=") && (x = !0, m = "0", v = "=");
|
|
2591
|
+
var E = w === "$" ? t : w === "#" && /[boxX]/.test(N) ? "0" + N.toLowerCase() : "", I = w === "$" ? s : /[%p]/.test(N) ? a : "", pe = Hs[N], Je = /[defgprs%]/.test(N);
|
|
2592
|
+
M = M === void 0 ? 6 : /[gprs]/.test(N) ? Math.max(1, Math.min(21, M)) : Math.max(0, Math.min(20, M));
|
|
2593
|
+
function St(P) {
|
|
2594
|
+
var oe = E, F = I, me, Tt, Re;
|
|
2595
|
+
if (N === "c")
|
|
2596
|
+
F = pe(P) + F, P = "";
|
|
2592
2597
|
else {
|
|
2593
2598
|
P = +P;
|
|
2594
|
-
var
|
|
2595
|
-
if (P = isNaN(P) ? c : pe(Math.abs(P), M), Y && (P = xl(P)),
|
|
2599
|
+
var Me = P < 0 || 1 / P < 0;
|
|
2600
|
+
if (P = isNaN(P) ? c : pe(Math.abs(P), M), Y && (P = xl(P)), Me && +P == 0 && S !== "+" && (Me = !1), oe = (Me ? S === "(" ? S : o : S === "-" || S === "(" ? "" : S) + oe, F = (N === "s" ? Ws[8 + Mi / 3] : "") + F + (Me && S === "(" ? ")" : ""), Je) {
|
|
2596
2601
|
for (me = -1, Tt = P.length; ++me < Tt; )
|
|
2597
|
-
if (
|
|
2598
|
-
|
|
2602
|
+
if (Re = P.charCodeAt(me), 48 > Re || Re > 57) {
|
|
2603
|
+
F = (Re === 46 ? r + P.slice(me + 1) : P.slice(me)) + F, P = P.slice(0, me);
|
|
2599
2604
|
break;
|
|
2600
2605
|
}
|
|
2601
2606
|
}
|
|
2602
2607
|
}
|
|
2603
|
-
|
|
2604
|
-
var Oe = oe.length + P.length +
|
|
2605
|
-
switch (
|
|
2608
|
+
L && !x && (P = e(P, 1 / 0));
|
|
2609
|
+
var Oe = oe.length + P.length + F.length, te = Oe < R ? new Array(R - Oe + 1).join(m) : "";
|
|
2610
|
+
switch (L && x && (P = e(te + P, te.length ? R - F.length : 1 / 0), te = ""), v) {
|
|
2606
2611
|
case "<":
|
|
2607
|
-
P = oe + P +
|
|
2612
|
+
P = oe + P + F + te;
|
|
2608
2613
|
break;
|
|
2609
2614
|
case "=":
|
|
2610
|
-
P = oe + te + P +
|
|
2615
|
+
P = oe + te + P + F;
|
|
2611
2616
|
break;
|
|
2612
2617
|
case "^":
|
|
2613
|
-
P = te.slice(0, Oe = te.length >> 1) + oe + P +
|
|
2618
|
+
P = te.slice(0, Oe = te.length >> 1) + oe + P + F + te.slice(Oe);
|
|
2614
2619
|
break;
|
|
2615
2620
|
default:
|
|
2616
|
-
P = te + oe + P +
|
|
2621
|
+
P = te + oe + P + F;
|
|
2617
2622
|
break;
|
|
2618
2623
|
}
|
|
2619
2624
|
return i(P);
|
|
2620
2625
|
}
|
|
2621
|
-
return
|
|
2626
|
+
return St.toString = function() {
|
|
2622
2627
|
return d + "";
|
|
2623
|
-
},
|
|
2628
|
+
}, St;
|
|
2624
2629
|
}
|
|
2625
2630
|
function u(d, m) {
|
|
2626
|
-
var v = l((d = Vt(d), d.type = "f", d)),
|
|
2631
|
+
var v = l((d = Vt(d), d.type = "f", d)), S = Math.max(-8, Math.min(8, Math.floor(He(m) / 3))) * 3, w = Math.pow(10, -S), x = Ws[8 + S / 3];
|
|
2627
2632
|
return function(R) {
|
|
2628
2633
|
return v(w * R) + x;
|
|
2629
2634
|
};
|
|
@@ -2633,14 +2638,14 @@ function Tl(n) {
|
|
|
2633
2638
|
formatPrefix: u
|
|
2634
2639
|
};
|
|
2635
2640
|
}
|
|
2636
|
-
var kt,
|
|
2641
|
+
var kt, Oi, Di;
|
|
2637
2642
|
El({
|
|
2638
2643
|
thousands: ",",
|
|
2639
2644
|
grouping: [3],
|
|
2640
2645
|
currency: ["$", ""]
|
|
2641
2646
|
});
|
|
2642
2647
|
function El(n) {
|
|
2643
|
-
return kt = Tl(n),
|
|
2648
|
+
return kt = Tl(n), Oi = kt.format, Di = kt.formatPrefix, kt;
|
|
2644
2649
|
}
|
|
2645
2650
|
function Cl(n) {
|
|
2646
2651
|
return Math.max(0, -He(Math.abs(n)));
|
|
@@ -2656,7 +2661,7 @@ function Rl(n, e, t, s) {
|
|
|
2656
2661
|
switch (s = Vt(s ?? ",f"), s.type) {
|
|
2657
2662
|
case "s": {
|
|
2658
2663
|
var a = Math.max(Math.abs(n), Math.abs(e));
|
|
2659
|
-
return s.precision == null && !isNaN(i = kl(r, a)) && (s.precision = i),
|
|
2664
|
+
return s.precision == null && !isNaN(i = kl(r, a)) && (s.precision = i), Di(s, a);
|
|
2660
2665
|
}
|
|
2661
2666
|
case "":
|
|
2662
2667
|
case "e":
|
|
@@ -2672,7 +2677,7 @@ function Rl(n, e, t, s) {
|
|
|
2672
2677
|
break;
|
|
2673
2678
|
}
|
|
2674
2679
|
}
|
|
2675
|
-
return
|
|
2680
|
+
return Oi(s);
|
|
2676
2681
|
}
|
|
2677
2682
|
function Ml(n) {
|
|
2678
2683
|
var e = n.domain;
|
|
@@ -2699,13 +2704,13 @@ function Ml(n) {
|
|
|
2699
2704
|
return n;
|
|
2700
2705
|
}, n;
|
|
2701
2706
|
}
|
|
2702
|
-
function
|
|
2707
|
+
function Li() {
|
|
2703
2708
|
var n = Ri();
|
|
2704
2709
|
return n.copy = function() {
|
|
2705
|
-
return Pi(n,
|
|
2710
|
+
return Pi(n, Li());
|
|
2706
2711
|
}, Ti.apply(n, arguments), Ml(n);
|
|
2707
2712
|
}
|
|
2708
|
-
function
|
|
2713
|
+
function Ol(n, e) {
|
|
2709
2714
|
n = n.slice();
|
|
2710
2715
|
var t = 0, s = n.length - 1, r = n[t], i = n[s], a;
|
|
2711
2716
|
return i < r && (a = t, t = s, s = a, a = r, r = i, i = a), n[t] = e.floor(r), n[s] = e.ceil(i), n;
|
|
@@ -2748,68 +2753,68 @@ Xt.every = (n) => (n = Math.floor(n), !isFinite(n) || !(n > 0) ? null : n > 1 ?
|
|
|
2748
2753
|
e.setTime(+e + t * n);
|
|
2749
2754
|
}, (e, t) => (t - e) / n) : Xt);
|
|
2750
2755
|
Xt.range;
|
|
2751
|
-
const le = 1e3, K = le * 60, ce = K * 60, he = ce * 24,
|
|
2756
|
+
const le = 1e3, K = le * 60, ce = K * 60, he = ce * 24, Ts = he * 7, Vs = he * 30, Sn = he * 365, Ye = B((n) => {
|
|
2752
2757
|
n.setTime(n - n.getMilliseconds());
|
|
2753
2758
|
}, (n, e) => {
|
|
2754
2759
|
n.setTime(+n + e * le);
|
|
2755
2760
|
}, (n, e) => (e - n) / le, (n) => n.getUTCSeconds());
|
|
2756
|
-
|
|
2757
|
-
const
|
|
2761
|
+
Ye.range;
|
|
2762
|
+
const Es = B((n) => {
|
|
2758
2763
|
n.setTime(n - n.getMilliseconds() - n.getSeconds() * le);
|
|
2759
2764
|
}, (n, e) => {
|
|
2760
2765
|
n.setTime(+n + e * K);
|
|
2761
2766
|
}, (n, e) => (e - n) / K, (n) => n.getMinutes());
|
|
2762
|
-
|
|
2763
|
-
const
|
|
2767
|
+
Es.range;
|
|
2768
|
+
const Dl = B((n) => {
|
|
2764
2769
|
n.setUTCSeconds(0, 0);
|
|
2765
2770
|
}, (n, e) => {
|
|
2766
2771
|
n.setTime(+n + e * K);
|
|
2767
2772
|
}, (n, e) => (e - n) / K, (n) => n.getUTCMinutes());
|
|
2768
|
-
|
|
2769
|
-
const
|
|
2773
|
+
Dl.range;
|
|
2774
|
+
const Cs = B((n) => {
|
|
2770
2775
|
n.setTime(n - n.getMilliseconds() - n.getSeconds() * le - n.getMinutes() * K);
|
|
2771
2776
|
}, (n, e) => {
|
|
2772
2777
|
n.setTime(+n + e * ce);
|
|
2773
2778
|
}, (n, e) => (e - n) / ce, (n) => n.getHours());
|
|
2774
|
-
|
|
2775
|
-
const
|
|
2779
|
+
Cs.range;
|
|
2780
|
+
const Ll = B((n) => {
|
|
2776
2781
|
n.setUTCMinutes(0, 0, 0);
|
|
2777
2782
|
}, (n, e) => {
|
|
2778
2783
|
n.setTime(+n + e * ce);
|
|
2779
2784
|
}, (n, e) => (e - n) / ce, (n) => n.getUTCHours());
|
|
2780
|
-
|
|
2781
|
-
const
|
|
2785
|
+
Ll.range;
|
|
2786
|
+
const wt = B(
|
|
2782
2787
|
(n) => n.setHours(0, 0, 0, 0),
|
|
2783
2788
|
(n, e) => n.setDate(n.getDate() + e),
|
|
2784
2789
|
(n, e) => (e - n - (e.getTimezoneOffset() - n.getTimezoneOffset()) * K) / he,
|
|
2785
2790
|
(n) => n.getDate() - 1
|
|
2786
2791
|
);
|
|
2787
|
-
|
|
2788
|
-
const
|
|
2792
|
+
wt.range;
|
|
2793
|
+
const ks = B((n) => {
|
|
2789
2794
|
n.setUTCHours(0, 0, 0, 0);
|
|
2790
2795
|
}, (n, e) => {
|
|
2791
2796
|
n.setUTCDate(n.getUTCDate() + e);
|
|
2792
2797
|
}, (n, e) => (e - n) / he, (n) => n.getUTCDate() - 1);
|
|
2793
|
-
|
|
2794
|
-
const
|
|
2798
|
+
ks.range;
|
|
2799
|
+
const _l = B((n) => {
|
|
2795
2800
|
n.setUTCHours(0, 0, 0, 0);
|
|
2796
2801
|
}, (n, e) => {
|
|
2797
2802
|
n.setUTCDate(n.getUTCDate() + e);
|
|
2798
2803
|
}, (n, e) => (e - n) / he, (n) => Math.floor(n / he));
|
|
2799
|
-
|
|
2804
|
+
_l.range;
|
|
2800
2805
|
function ke(n) {
|
|
2801
2806
|
return B((e) => {
|
|
2802
2807
|
e.setDate(e.getDate() - (e.getDay() + 7 - n) % 7), e.setHours(0, 0, 0, 0);
|
|
2803
2808
|
}, (e, t) => {
|
|
2804
2809
|
e.setDate(e.getDate() + t * 7);
|
|
2805
|
-
}, (e, t) => (t - e - (t.getTimezoneOffset() - e.getTimezoneOffset()) * K) /
|
|
2810
|
+
}, (e, t) => (t - e - (t.getTimezoneOffset() - e.getTimezoneOffset()) * K) / Ts);
|
|
2806
2811
|
}
|
|
2807
|
-
const mn = ke(0), Gt = ke(1), Yl = ke(2), Al = ke(3),
|
|
2812
|
+
const mn = ke(0), Gt = ke(1), Yl = ke(2), Al = ke(3), je = ke(4), Nl = ke(5), Il = ke(6);
|
|
2808
2813
|
mn.range;
|
|
2809
2814
|
Gt.range;
|
|
2810
2815
|
Yl.range;
|
|
2811
2816
|
Al.range;
|
|
2812
|
-
|
|
2817
|
+
je.range;
|
|
2813
2818
|
Nl.range;
|
|
2814
2819
|
Il.range;
|
|
2815
2820
|
function Pe(n) {
|
|
@@ -2817,28 +2822,28 @@ function Pe(n) {
|
|
|
2817
2822
|
e.setUTCDate(e.getUTCDate() - (e.getUTCDay() + 7 - n) % 7), e.setUTCHours(0, 0, 0, 0);
|
|
2818
2823
|
}, (e, t) => {
|
|
2819
2824
|
e.setUTCDate(e.getUTCDate() + t * 7);
|
|
2820
|
-
}, (e, t) => (t - e) /
|
|
2825
|
+
}, (e, t) => (t - e) / Ts);
|
|
2821
2826
|
}
|
|
2822
|
-
const
|
|
2823
|
-
|
|
2827
|
+
const _i = Pe(0), Kt = Pe(1), Bl = Pe(2), Zl = Pe(3), ze = Pe(4), Ul = Pe(5), $l = Pe(6);
|
|
2828
|
+
_i.range;
|
|
2824
2829
|
Kt.range;
|
|
2825
2830
|
Bl.range;
|
|
2826
2831
|
Zl.range;
|
|
2827
|
-
|
|
2832
|
+
ze.range;
|
|
2828
2833
|
Ul.range;
|
|
2829
2834
|
$l.range;
|
|
2830
|
-
const
|
|
2835
|
+
const Ps = B((n) => {
|
|
2831
2836
|
n.setDate(1), n.setHours(0, 0, 0, 0);
|
|
2832
2837
|
}, (n, e) => {
|
|
2833
2838
|
n.setMonth(n.getMonth() + e);
|
|
2834
2839
|
}, (n, e) => e.getMonth() - n.getMonth() + (e.getFullYear() - n.getFullYear()) * 12, (n) => n.getMonth());
|
|
2835
|
-
|
|
2836
|
-
const
|
|
2840
|
+
Ps.range;
|
|
2841
|
+
const ql = B((n) => {
|
|
2837
2842
|
n.setUTCDate(1), n.setUTCHours(0, 0, 0, 0);
|
|
2838
2843
|
}, (n, e) => {
|
|
2839
2844
|
n.setUTCMonth(n.getUTCMonth() + e);
|
|
2840
2845
|
}, (n, e) => e.getUTCMonth() - n.getUTCMonth() + (e.getUTCFullYear() - n.getUTCFullYear()) * 12, (n) => n.getUTCMonth());
|
|
2841
|
-
|
|
2846
|
+
ql.range;
|
|
2842
2847
|
const de = B((n) => {
|
|
2843
2848
|
n.setMonth(0, 1), n.setHours(0, 0, 0, 0);
|
|
2844
2849
|
}, (n, e) => {
|
|
@@ -2861,12 +2866,12 @@ Te.every = (n) => !isFinite(n = Math.floor(n)) || !(n > 0) ? null : B((e) => {
|
|
|
2861
2866
|
e.setUTCFullYear(e.getUTCFullYear() + t * n);
|
|
2862
2867
|
});
|
|
2863
2868
|
Te.range;
|
|
2864
|
-
function
|
|
2869
|
+
function Fl(n, e, t, s, r, i) {
|
|
2865
2870
|
const a = [
|
|
2866
|
-
[
|
|
2867
|
-
[
|
|
2868
|
-
[
|
|
2869
|
-
[
|
|
2871
|
+
[Ye, 1, le],
|
|
2872
|
+
[Ye, 5, 5 * le],
|
|
2873
|
+
[Ye, 15, 15 * le],
|
|
2874
|
+
[Ye, 30, 30 * le],
|
|
2870
2875
|
[i, 1, K],
|
|
2871
2876
|
[i, 5, 5 * K],
|
|
2872
2877
|
[i, 15, 15 * K],
|
|
@@ -2877,27 +2882,27 @@ function ql(n, e, t, s, r, i) {
|
|
|
2877
2882
|
[r, 12, 12 * ce],
|
|
2878
2883
|
[s, 1, he],
|
|
2879
2884
|
[s, 2, 2 * he],
|
|
2880
|
-
[t, 1,
|
|
2881
|
-
[e, 1,
|
|
2882
|
-
[e, 3, 3 *
|
|
2885
|
+
[t, 1, Ts],
|
|
2886
|
+
[e, 1, Vs],
|
|
2887
|
+
[e, 3, 3 * Vs],
|
|
2883
2888
|
[n, 1, Sn]
|
|
2884
2889
|
];
|
|
2885
2890
|
function o(l, u, d) {
|
|
2886
2891
|
const m = u < l;
|
|
2887
2892
|
m && ([l, u] = [u, l]);
|
|
2888
|
-
const v = d && typeof d.range == "function" ? d : c(l, u, d),
|
|
2889
|
-
return m ?
|
|
2893
|
+
const v = d && typeof d.range == "function" ? d : c(l, u, d), S = v ? v.range(l, +u + 1) : [];
|
|
2894
|
+
return m ? S.reverse() : S;
|
|
2890
2895
|
}
|
|
2891
2896
|
function c(l, u, d) {
|
|
2892
|
-
const m = Math.abs(u - l) / d, v =
|
|
2897
|
+
const m = Math.abs(u - l) / d, v = vs(([, , x]) => x).right(a, m);
|
|
2893
2898
|
if (v === a.length) return n.every(Zn(l / Sn, u / Sn, d));
|
|
2894
2899
|
if (v === 0) return Xt.every(Math.max(Zn(l, u, d), 1));
|
|
2895
|
-
const [
|
|
2896
|
-
return
|
|
2900
|
+
const [S, w] = a[m / a[v - 1][2] < a[v][2] / m ? v - 1 : v];
|
|
2901
|
+
return S.every(w);
|
|
2897
2902
|
}
|
|
2898
2903
|
return [o, c];
|
|
2899
2904
|
}
|
|
2900
|
-
const [
|
|
2905
|
+
const [Hl, jl] = Fl(de, Ps, mn, wt, Cs, Es);
|
|
2901
2906
|
function Tn(n) {
|
|
2902
2907
|
if (0 <= n.y && n.y < 100) {
|
|
2903
2908
|
var e = new Date(-1, n.m, n.d, n.H, n.M, n.S, n.L);
|
|
@@ -2912,18 +2917,18 @@ function En(n) {
|
|
|
2912
2917
|
}
|
|
2913
2918
|
return new Date(Date.UTC(n.y, n.m, n.d, n.H, n.M, n.S, n.L));
|
|
2914
2919
|
}
|
|
2915
|
-
function
|
|
2920
|
+
function et(n, e, t) {
|
|
2916
2921
|
return { y: n, m: e, d: t, H: 0, M: 0, S: 0, L: 0 };
|
|
2917
2922
|
}
|
|
2918
2923
|
function zl(n) {
|
|
2919
|
-
var e = n.dateTime, t = n.date, s = n.time, r = n.periods, i = n.days, a = n.shortDays, o = n.months, c = n.shortMonths, l =
|
|
2920
|
-
a:
|
|
2924
|
+
var e = n.dateTime, t = n.date, s = n.time, r = n.periods, i = n.days, a = n.shortDays, o = n.months, c = n.shortMonths, l = tt(r), u = nt(r), d = tt(i), m = nt(i), v = tt(a), S = nt(a), w = tt(o), x = nt(o), R = tt(c), L = nt(c), M = {
|
|
2925
|
+
a: Me,
|
|
2921
2926
|
A: Oe,
|
|
2922
2927
|
b: te,
|
|
2923
2928
|
B: Qi,
|
|
2924
2929
|
c: null,
|
|
2925
|
-
d:
|
|
2926
|
-
e:
|
|
2930
|
+
d: er,
|
|
2931
|
+
e: er,
|
|
2927
2932
|
f: mc,
|
|
2928
2933
|
g: Cc,
|
|
2929
2934
|
G: Pc,
|
|
@@ -2935,8 +2940,8 @@ function zl(n) {
|
|
|
2935
2940
|
M: yc,
|
|
2936
2941
|
p: Ji,
|
|
2937
2942
|
q: ea,
|
|
2938
|
-
Q:
|
|
2939
|
-
s:
|
|
2943
|
+
Q: sr,
|
|
2944
|
+
s: rr,
|
|
2940
2945
|
S: vc,
|
|
2941
2946
|
u: bc,
|
|
2942
2947
|
U: wc,
|
|
@@ -2948,28 +2953,28 @@ function zl(n) {
|
|
|
2948
2953
|
y: Ec,
|
|
2949
2954
|
Y: kc,
|
|
2950
2955
|
Z: Rc,
|
|
2951
|
-
"%":
|
|
2956
|
+
"%": nr
|
|
2952
2957
|
}, Y = {
|
|
2953
2958
|
a: ta,
|
|
2954
2959
|
A: na,
|
|
2955
2960
|
b: sa,
|
|
2956
2961
|
B: ra,
|
|
2957
2962
|
c: null,
|
|
2958
|
-
d:
|
|
2959
|
-
e:
|
|
2960
|
-
f:
|
|
2961
|
-
g:
|
|
2962
|
-
G:
|
|
2963
|
+
d: tr,
|
|
2964
|
+
e: tr,
|
|
2965
|
+
f: Lc,
|
|
2966
|
+
g: qc,
|
|
2967
|
+
G: Hc,
|
|
2963
2968
|
H: Mc,
|
|
2964
|
-
I:
|
|
2965
|
-
j:
|
|
2969
|
+
I: Oc,
|
|
2970
|
+
j: Dc,
|
|
2966
2971
|
L: Ni,
|
|
2967
|
-
m:
|
|
2972
|
+
m: _c,
|
|
2968
2973
|
M: Yc,
|
|
2969
2974
|
p: ia,
|
|
2970
2975
|
q: aa,
|
|
2971
|
-
Q:
|
|
2972
|
-
s:
|
|
2976
|
+
Q: sr,
|
|
2977
|
+
s: rr,
|
|
2973
2978
|
S: Ac,
|
|
2974
2979
|
u: Nc,
|
|
2975
2980
|
U: Ic,
|
|
@@ -2979,27 +2984,27 @@ function zl(n) {
|
|
|
2979
2984
|
x: null,
|
|
2980
2985
|
X: null,
|
|
2981
2986
|
y: $c,
|
|
2982
|
-
Y:
|
|
2983
|
-
Z:
|
|
2984
|
-
"%":
|
|
2985
|
-
},
|
|
2986
|
-
a:
|
|
2987
|
+
Y: Fc,
|
|
2988
|
+
Z: jc,
|
|
2989
|
+
"%": nr
|
|
2990
|
+
}, N = {
|
|
2991
|
+
a: St,
|
|
2987
2992
|
A: P,
|
|
2988
2993
|
b: oe,
|
|
2989
|
-
B:
|
|
2994
|
+
B: F,
|
|
2990
2995
|
c: me,
|
|
2991
|
-
d:
|
|
2992
|
-
e:
|
|
2996
|
+
d: Qs,
|
|
2997
|
+
e: Qs,
|
|
2993
2998
|
f: lc,
|
|
2994
|
-
g:
|
|
2995
|
-
G:
|
|
2996
|
-
H:
|
|
2997
|
-
I:
|
|
2999
|
+
g: Ks,
|
|
3000
|
+
G: Gs,
|
|
3001
|
+
H: Js,
|
|
3002
|
+
I: Js,
|
|
2998
3003
|
j: rc,
|
|
2999
3004
|
L: oc,
|
|
3000
3005
|
m: sc,
|
|
3001
3006
|
M: ic,
|
|
3002
|
-
p:
|
|
3007
|
+
p: Je,
|
|
3003
3008
|
q: nc,
|
|
3004
3009
|
Q: uc,
|
|
3005
3010
|
s: hc,
|
|
@@ -3010,74 +3015,74 @@ function zl(n) {
|
|
|
3010
3015
|
w: Gl,
|
|
3011
3016
|
W: ec,
|
|
3012
3017
|
x: Tt,
|
|
3013
|
-
X:
|
|
3014
|
-
y:
|
|
3015
|
-
Y:
|
|
3018
|
+
X: Re,
|
|
3019
|
+
y: Ks,
|
|
3020
|
+
Y: Gs,
|
|
3016
3021
|
Z: tc,
|
|
3017
3022
|
"%": cc
|
|
3018
3023
|
};
|
|
3019
3024
|
M.x = E(t, M), M.X = E(s, M), M.c = E(e, M), Y.x = E(t, Y), Y.X = E(s, Y), Y.c = E(e, Y);
|
|
3020
3025
|
function E(b, k) {
|
|
3021
|
-
return function(
|
|
3022
|
-
var g = [],
|
|
3023
|
-
for (
|
|
3024
|
-
b.charCodeAt(
|
|
3025
|
-
return g.push(b.slice(
|
|
3026
|
+
return function(O) {
|
|
3027
|
+
var g = [], H = -1, _ = 0, z = b.length, W, be, Rs;
|
|
3028
|
+
for (O instanceof Date || (O = /* @__PURE__ */ new Date(+O)); ++H < z; )
|
|
3029
|
+
b.charCodeAt(H) === 37 && (g.push(b.slice(_, H)), (be = Xs[W = b.charAt(++H)]) != null ? W = b.charAt(++H) : be = W === "e" ? " " : "0", (Rs = k[W]) && (W = Rs(O, be)), g.push(W), _ = H + 1);
|
|
3030
|
+
return g.push(b.slice(_, H)), g.join("");
|
|
3026
3031
|
};
|
|
3027
3032
|
}
|
|
3028
|
-
function
|
|
3029
|
-
return function(
|
|
3030
|
-
var g =
|
|
3031
|
-
if (
|
|
3033
|
+
function I(b, k) {
|
|
3034
|
+
return function(O) {
|
|
3035
|
+
var g = et(1900, void 0, 1), H = pe(g, b, O += "", 0), _, z;
|
|
3036
|
+
if (H != O.length) return null;
|
|
3032
3037
|
if ("Q" in g) return new Date(g.Q);
|
|
3033
3038
|
if ("s" in g) return new Date(g.s * 1e3 + ("L" in g ? g.L : 0));
|
|
3034
3039
|
if (k && !("Z" in g) && (g.Z = 0), "p" in g && (g.H = g.H % 12 + g.p * 12), g.m === void 0 && (g.m = "q" in g ? g.q : 0), "V" in g) {
|
|
3035
3040
|
if (g.V < 1 || g.V > 53) return null;
|
|
3036
|
-
"w" in g || (g.w = 1), "Z" in g ? (
|
|
3037
|
-
} else ("W" in g || "U" in g) && ("w" in g || (g.w = "u" in g ? g.u % 7 : "W" in g ? 1 : 0), z = "Z" in g ? En(
|
|
3041
|
+
"w" in g || (g.w = 1), "Z" in g ? (_ = En(et(g.y, 0, 1)), z = _.getUTCDay(), _ = z > 4 || z === 0 ? Kt.ceil(_) : Kt(_), _ = ks.offset(_, (g.V - 1) * 7), g.y = _.getUTCFullYear(), g.m = _.getUTCMonth(), g.d = _.getUTCDate() + (g.w + 6) % 7) : (_ = Tn(et(g.y, 0, 1)), z = _.getDay(), _ = z > 4 || z === 0 ? Gt.ceil(_) : Gt(_), _ = wt.offset(_, (g.V - 1) * 7), g.y = _.getFullYear(), g.m = _.getMonth(), g.d = _.getDate() + (g.w + 6) % 7);
|
|
3042
|
+
} else ("W" in g || "U" in g) && ("w" in g || (g.w = "u" in g ? g.u % 7 : "W" in g ? 1 : 0), z = "Z" in g ? En(et(g.y, 0, 1)).getUTCDay() : Tn(et(g.y, 0, 1)).getDay(), g.m = 0, g.d = "W" in g ? (g.w + 6) % 7 + g.W * 7 - (z + 5) % 7 : g.w + g.U * 7 - (z + 6) % 7);
|
|
3038
3043
|
return "Z" in g ? (g.H += g.Z / 100 | 0, g.M += g.Z % 100, En(g)) : Tn(g);
|
|
3039
3044
|
};
|
|
3040
3045
|
}
|
|
3041
|
-
function pe(b, k,
|
|
3042
|
-
for (var
|
|
3046
|
+
function pe(b, k, O, g) {
|
|
3047
|
+
for (var H = 0, _ = k.length, z = O.length, W, be; H < _; ) {
|
|
3043
3048
|
if (g >= z) return -1;
|
|
3044
|
-
if (W = k.charCodeAt(
|
|
3045
|
-
if (W = k.charAt(
|
|
3046
|
-
} else if (W !=
|
|
3049
|
+
if (W = k.charCodeAt(H++), W === 37) {
|
|
3050
|
+
if (W = k.charAt(H++), be = N[W in Xs ? k.charAt(H++) : W], !be || (g = be(b, O, g)) < 0) return -1;
|
|
3051
|
+
} else if (W != O.charCodeAt(g++))
|
|
3047
3052
|
return -1;
|
|
3048
3053
|
}
|
|
3049
3054
|
return g;
|
|
3050
3055
|
}
|
|
3051
|
-
function
|
|
3052
|
-
var g = l.exec(k.slice(
|
|
3053
|
-
return g ? (b.p = u.get(g[0].toLowerCase()),
|
|
3056
|
+
function Je(b, k, O) {
|
|
3057
|
+
var g = l.exec(k.slice(O));
|
|
3058
|
+
return g ? (b.p = u.get(g[0].toLowerCase()), O + g[0].length) : -1;
|
|
3054
3059
|
}
|
|
3055
|
-
function
|
|
3056
|
-
var g = v.exec(k.slice(
|
|
3057
|
-
return g ? (b.w =
|
|
3060
|
+
function St(b, k, O) {
|
|
3061
|
+
var g = v.exec(k.slice(O));
|
|
3062
|
+
return g ? (b.w = S.get(g[0].toLowerCase()), O + g[0].length) : -1;
|
|
3058
3063
|
}
|
|
3059
|
-
function P(b, k,
|
|
3060
|
-
var g = d.exec(k.slice(
|
|
3061
|
-
return g ? (b.w = m.get(g[0].toLowerCase()),
|
|
3064
|
+
function P(b, k, O) {
|
|
3065
|
+
var g = d.exec(k.slice(O));
|
|
3066
|
+
return g ? (b.w = m.get(g[0].toLowerCase()), O + g[0].length) : -1;
|
|
3062
3067
|
}
|
|
3063
|
-
function oe(b, k,
|
|
3064
|
-
var g = R.exec(k.slice(
|
|
3065
|
-
return g ? (b.m =
|
|
3068
|
+
function oe(b, k, O) {
|
|
3069
|
+
var g = R.exec(k.slice(O));
|
|
3070
|
+
return g ? (b.m = L.get(g[0].toLowerCase()), O + g[0].length) : -1;
|
|
3066
3071
|
}
|
|
3067
|
-
function
|
|
3068
|
-
var g = w.exec(k.slice(
|
|
3069
|
-
return g ? (b.m = x.get(g[0].toLowerCase()),
|
|
3072
|
+
function F(b, k, O) {
|
|
3073
|
+
var g = w.exec(k.slice(O));
|
|
3074
|
+
return g ? (b.m = x.get(g[0].toLowerCase()), O + g[0].length) : -1;
|
|
3070
3075
|
}
|
|
3071
|
-
function me(b, k,
|
|
3072
|
-
return pe(b, e, k,
|
|
3076
|
+
function me(b, k, O) {
|
|
3077
|
+
return pe(b, e, k, O);
|
|
3073
3078
|
}
|
|
3074
|
-
function Tt(b, k,
|
|
3075
|
-
return pe(b, t, k,
|
|
3079
|
+
function Tt(b, k, O) {
|
|
3080
|
+
return pe(b, t, k, O);
|
|
3076
3081
|
}
|
|
3077
|
-
function
|
|
3078
|
-
return pe(b, s, k,
|
|
3082
|
+
function Re(b, k, O) {
|
|
3083
|
+
return pe(b, s, k, O);
|
|
3079
3084
|
}
|
|
3080
|
-
function
|
|
3085
|
+
function Me(b) {
|
|
3081
3086
|
return a[b.getDay()];
|
|
3082
3087
|
}
|
|
3083
3088
|
function Oe(b) {
|
|
@@ -3121,7 +3126,7 @@ function zl(n) {
|
|
|
3121
3126
|
}, k;
|
|
3122
3127
|
},
|
|
3123
3128
|
parse: function(b) {
|
|
3124
|
-
var k =
|
|
3129
|
+
var k = I(b += "", !1);
|
|
3125
3130
|
return k.toString = function() {
|
|
3126
3131
|
return b;
|
|
3127
3132
|
}, k;
|
|
@@ -3133,25 +3138,25 @@ function zl(n) {
|
|
|
3133
3138
|
}, k;
|
|
3134
3139
|
},
|
|
3135
3140
|
utcParse: function(b) {
|
|
3136
|
-
var k =
|
|
3141
|
+
var k = I(b += "", !0);
|
|
3137
3142
|
return k.toString = function() {
|
|
3138
3143
|
return b;
|
|
3139
3144
|
}, k;
|
|
3140
3145
|
}
|
|
3141
3146
|
};
|
|
3142
3147
|
}
|
|
3143
|
-
var
|
|
3144
|
-
function
|
|
3148
|
+
var Xs = { "-": "", _: " ", 0: "0" }, Z = /^\s*\d+/, Wl = /^%/, Vl = /[\\^$*+?|[\]().{}]/g;
|
|
3149
|
+
function D(n, e, t) {
|
|
3145
3150
|
var s = n < 0 ? "-" : "", r = (s ? -n : n) + "", i = r.length;
|
|
3146
3151
|
return s + (i < t ? new Array(t - i + 1).join(e) + r : r);
|
|
3147
3152
|
}
|
|
3148
3153
|
function Xl(n) {
|
|
3149
3154
|
return n.replace(Vl, "\\$&");
|
|
3150
3155
|
}
|
|
3151
|
-
function
|
|
3156
|
+
function tt(n) {
|
|
3152
3157
|
return new RegExp("^(?:" + n.map(Xl).join("|") + ")", "i");
|
|
3153
3158
|
}
|
|
3154
|
-
function
|
|
3159
|
+
function nt(n) {
|
|
3155
3160
|
return new Map(n.map((e, t) => [e.toLowerCase(), t]));
|
|
3156
3161
|
}
|
|
3157
3162
|
function Gl(n, e, t) {
|
|
@@ -3174,11 +3179,11 @@ function ec(n, e, t) {
|
|
|
3174
3179
|
var s = Z.exec(e.slice(t, t + 2));
|
|
3175
3180
|
return s ? (n.W = +s[0], t + s[0].length) : -1;
|
|
3176
3181
|
}
|
|
3177
|
-
function
|
|
3182
|
+
function Gs(n, e, t) {
|
|
3178
3183
|
var s = Z.exec(e.slice(t, t + 4));
|
|
3179
3184
|
return s ? (n.y = +s[0], t + s[0].length) : -1;
|
|
3180
3185
|
}
|
|
3181
|
-
function
|
|
3186
|
+
function Ks(n, e, t) {
|
|
3182
3187
|
var s = Z.exec(e.slice(t, t + 2));
|
|
3183
3188
|
return s ? (n.y = +s[0] + (+s[0] > 68 ? 1900 : 2e3), t + s[0].length) : -1;
|
|
3184
3189
|
}
|
|
@@ -3194,7 +3199,7 @@ function sc(n, e, t) {
|
|
|
3194
3199
|
var s = Z.exec(e.slice(t, t + 2));
|
|
3195
3200
|
return s ? (n.m = s[0] - 1, t + s[0].length) : -1;
|
|
3196
3201
|
}
|
|
3197
|
-
function
|
|
3202
|
+
function Qs(n, e, t) {
|
|
3198
3203
|
var s = Z.exec(e.slice(t, t + 2));
|
|
3199
3204
|
return s ? (n.d = +s[0], t + s[0].length) : -1;
|
|
3200
3205
|
}
|
|
@@ -3202,7 +3207,7 @@ function rc(n, e, t) {
|
|
|
3202
3207
|
var s = Z.exec(e.slice(t, t + 3));
|
|
3203
3208
|
return s ? (n.m = 0, n.d = +s[0], t + s[0].length) : -1;
|
|
3204
3209
|
}
|
|
3205
|
-
function
|
|
3210
|
+
function Js(n, e, t) {
|
|
3206
3211
|
var s = Z.exec(e.slice(t, t + 2));
|
|
3207
3212
|
return s ? (n.H = +s[0], t + s[0].length) : -1;
|
|
3208
3213
|
}
|
|
@@ -3234,143 +3239,143 @@ function hc(n, e, t) {
|
|
|
3234
3239
|
var s = Z.exec(e.slice(t));
|
|
3235
3240
|
return s ? (n.s = +s[0], t + s[0].length) : -1;
|
|
3236
3241
|
}
|
|
3237
|
-
function
|
|
3238
|
-
return
|
|
3242
|
+
function er(n, e) {
|
|
3243
|
+
return D(n.getDate(), e, 2);
|
|
3239
3244
|
}
|
|
3240
3245
|
function dc(n, e) {
|
|
3241
|
-
return
|
|
3246
|
+
return D(n.getHours(), e, 2);
|
|
3242
3247
|
}
|
|
3243
3248
|
function fc(n, e) {
|
|
3244
|
-
return
|
|
3249
|
+
return D(n.getHours() % 12 || 12, e, 2);
|
|
3245
3250
|
}
|
|
3246
3251
|
function pc(n, e) {
|
|
3247
|
-
return
|
|
3252
|
+
return D(1 + wt.count(de(n), n), e, 3);
|
|
3248
3253
|
}
|
|
3249
3254
|
function Yi(n, e) {
|
|
3250
|
-
return
|
|
3255
|
+
return D(n.getMilliseconds(), e, 3);
|
|
3251
3256
|
}
|
|
3252
3257
|
function mc(n, e) {
|
|
3253
3258
|
return Yi(n, e) + "000";
|
|
3254
3259
|
}
|
|
3255
3260
|
function gc(n, e) {
|
|
3256
|
-
return
|
|
3261
|
+
return D(n.getMonth() + 1, e, 2);
|
|
3257
3262
|
}
|
|
3258
3263
|
function yc(n, e) {
|
|
3259
|
-
return
|
|
3264
|
+
return D(n.getMinutes(), e, 2);
|
|
3260
3265
|
}
|
|
3261
3266
|
function vc(n, e) {
|
|
3262
|
-
return
|
|
3267
|
+
return D(n.getSeconds(), e, 2);
|
|
3263
3268
|
}
|
|
3264
3269
|
function bc(n) {
|
|
3265
3270
|
var e = n.getDay();
|
|
3266
3271
|
return e === 0 ? 7 : e;
|
|
3267
3272
|
}
|
|
3268
3273
|
function wc(n, e) {
|
|
3269
|
-
return
|
|
3274
|
+
return D(mn.count(de(n) - 1, n), e, 2);
|
|
3270
3275
|
}
|
|
3271
3276
|
function Ai(n) {
|
|
3272
3277
|
var e = n.getDay();
|
|
3273
|
-
return e >= 4 || e === 0 ?
|
|
3278
|
+
return e >= 4 || e === 0 ? je(n) : je.ceil(n);
|
|
3274
3279
|
}
|
|
3275
3280
|
function xc(n, e) {
|
|
3276
|
-
return n = Ai(n),
|
|
3281
|
+
return n = Ai(n), D(je.count(de(n), n) + (de(n).getDay() === 4), e, 2);
|
|
3277
3282
|
}
|
|
3278
3283
|
function Sc(n) {
|
|
3279
3284
|
return n.getDay();
|
|
3280
3285
|
}
|
|
3281
3286
|
function Tc(n, e) {
|
|
3282
|
-
return
|
|
3287
|
+
return D(Gt.count(de(n) - 1, n), e, 2);
|
|
3283
3288
|
}
|
|
3284
3289
|
function Ec(n, e) {
|
|
3285
|
-
return
|
|
3290
|
+
return D(n.getFullYear() % 100, e, 2);
|
|
3286
3291
|
}
|
|
3287
3292
|
function Cc(n, e) {
|
|
3288
|
-
return n = Ai(n),
|
|
3293
|
+
return n = Ai(n), D(n.getFullYear() % 100, e, 2);
|
|
3289
3294
|
}
|
|
3290
3295
|
function kc(n, e) {
|
|
3291
|
-
return
|
|
3296
|
+
return D(n.getFullYear() % 1e4, e, 4);
|
|
3292
3297
|
}
|
|
3293
3298
|
function Pc(n, e) {
|
|
3294
3299
|
var t = n.getDay();
|
|
3295
|
-
return n = t >= 4 || t === 0 ?
|
|
3300
|
+
return n = t >= 4 || t === 0 ? je(n) : je.ceil(n), D(n.getFullYear() % 1e4, e, 4);
|
|
3296
3301
|
}
|
|
3297
3302
|
function Rc(n) {
|
|
3298
3303
|
var e = n.getTimezoneOffset();
|
|
3299
|
-
return (e > 0 ? "-" : (e *= -1, "+")) +
|
|
3304
|
+
return (e > 0 ? "-" : (e *= -1, "+")) + D(e / 60 | 0, "0", 2) + D(e % 60, "0", 2);
|
|
3300
3305
|
}
|
|
3301
|
-
function
|
|
3302
|
-
return
|
|
3306
|
+
function tr(n, e) {
|
|
3307
|
+
return D(n.getUTCDate(), e, 2);
|
|
3303
3308
|
}
|
|
3304
3309
|
function Mc(n, e) {
|
|
3305
|
-
return
|
|
3306
|
-
}
|
|
3307
|
-
function Dc(n, e) {
|
|
3308
|
-
return O(n.getUTCHours() % 12 || 12, e, 2);
|
|
3310
|
+
return D(n.getUTCHours(), e, 2);
|
|
3309
3311
|
}
|
|
3310
3312
|
function Oc(n, e) {
|
|
3311
|
-
return
|
|
3313
|
+
return D(n.getUTCHours() % 12 || 12, e, 2);
|
|
3314
|
+
}
|
|
3315
|
+
function Dc(n, e) {
|
|
3316
|
+
return D(1 + ks.count(Te(n), n), e, 3);
|
|
3312
3317
|
}
|
|
3313
3318
|
function Ni(n, e) {
|
|
3314
|
-
return
|
|
3319
|
+
return D(n.getUTCMilliseconds(), e, 3);
|
|
3315
3320
|
}
|
|
3316
|
-
function
|
|
3321
|
+
function Lc(n, e) {
|
|
3317
3322
|
return Ni(n, e) + "000";
|
|
3318
3323
|
}
|
|
3319
|
-
function
|
|
3320
|
-
return
|
|
3324
|
+
function _c(n, e) {
|
|
3325
|
+
return D(n.getUTCMonth() + 1, e, 2);
|
|
3321
3326
|
}
|
|
3322
3327
|
function Yc(n, e) {
|
|
3323
|
-
return
|
|
3328
|
+
return D(n.getUTCMinutes(), e, 2);
|
|
3324
3329
|
}
|
|
3325
3330
|
function Ac(n, e) {
|
|
3326
|
-
return
|
|
3331
|
+
return D(n.getUTCSeconds(), e, 2);
|
|
3327
3332
|
}
|
|
3328
3333
|
function Nc(n) {
|
|
3329
3334
|
var e = n.getUTCDay();
|
|
3330
3335
|
return e === 0 ? 7 : e;
|
|
3331
3336
|
}
|
|
3332
3337
|
function Ic(n, e) {
|
|
3333
|
-
return
|
|
3338
|
+
return D(_i.count(Te(n) - 1, n), e, 2);
|
|
3334
3339
|
}
|
|
3335
3340
|
function Ii(n) {
|
|
3336
3341
|
var e = n.getUTCDay();
|
|
3337
|
-
return e >= 4 || e === 0 ?
|
|
3342
|
+
return e >= 4 || e === 0 ? ze(n) : ze.ceil(n);
|
|
3338
3343
|
}
|
|
3339
3344
|
function Bc(n, e) {
|
|
3340
|
-
return n = Ii(n),
|
|
3345
|
+
return n = Ii(n), D(ze.count(Te(n), n) + (Te(n).getUTCDay() === 4), e, 2);
|
|
3341
3346
|
}
|
|
3342
3347
|
function Zc(n) {
|
|
3343
3348
|
return n.getUTCDay();
|
|
3344
3349
|
}
|
|
3345
3350
|
function Uc(n, e) {
|
|
3346
|
-
return
|
|
3351
|
+
return D(Kt.count(Te(n) - 1, n), e, 2);
|
|
3347
3352
|
}
|
|
3348
3353
|
function $c(n, e) {
|
|
3349
|
-
return
|
|
3350
|
-
}
|
|
3351
|
-
function Fc(n, e) {
|
|
3352
|
-
return n = Ii(n), O(n.getUTCFullYear() % 100, e, 2);
|
|
3354
|
+
return D(n.getUTCFullYear() % 100, e, 2);
|
|
3353
3355
|
}
|
|
3354
3356
|
function qc(n, e) {
|
|
3355
|
-
return
|
|
3357
|
+
return n = Ii(n), D(n.getUTCFullYear() % 100, e, 2);
|
|
3358
|
+
}
|
|
3359
|
+
function Fc(n, e) {
|
|
3360
|
+
return D(n.getUTCFullYear() % 1e4, e, 4);
|
|
3356
3361
|
}
|
|
3357
|
-
function
|
|
3362
|
+
function Hc(n, e) {
|
|
3358
3363
|
var t = n.getUTCDay();
|
|
3359
|
-
return n = t >= 4 || t === 0 ?
|
|
3364
|
+
return n = t >= 4 || t === 0 ? ze(n) : ze.ceil(n), D(n.getUTCFullYear() % 1e4, e, 4);
|
|
3360
3365
|
}
|
|
3361
|
-
function
|
|
3366
|
+
function jc() {
|
|
3362
3367
|
return "+0000";
|
|
3363
3368
|
}
|
|
3364
|
-
function
|
|
3369
|
+
function nr() {
|
|
3365
3370
|
return "%";
|
|
3366
3371
|
}
|
|
3367
|
-
function
|
|
3372
|
+
function sr(n) {
|
|
3368
3373
|
return +n;
|
|
3369
3374
|
}
|
|
3370
|
-
function
|
|
3375
|
+
function rr(n) {
|
|
3371
3376
|
return Math.floor(+n / 1e3);
|
|
3372
3377
|
}
|
|
3373
|
-
var
|
|
3378
|
+
var De, Bi;
|
|
3374
3379
|
zc({
|
|
3375
3380
|
dateTime: "%x, %X",
|
|
3376
3381
|
date: "%-m/%-d/%Y",
|
|
@@ -3382,7 +3387,7 @@ zc({
|
|
|
3382
3387
|
shortMonths: ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"]
|
|
3383
3388
|
});
|
|
3384
3389
|
function zc(n) {
|
|
3385
|
-
return
|
|
3390
|
+
return De = zl(n), Bi = De.format, De.parse, De.utcFormat, De.utcParse, De;
|
|
3386
3391
|
}
|
|
3387
3392
|
function Wc(n) {
|
|
3388
3393
|
return new Date(n);
|
|
@@ -3391,85 +3396,85 @@ function Vc(n) {
|
|
|
3391
3396
|
return n instanceof Date ? +n : +/* @__PURE__ */ new Date(+n);
|
|
3392
3397
|
}
|
|
3393
3398
|
function Zi(n, e, t, s, r, i, a, o, c, l) {
|
|
3394
|
-
var u = Ri(), d = u.invert, m = u.domain, v = l(".%L"),
|
|
3395
|
-
function
|
|
3396
|
-
return (c(E) < E ? v : o(E) < E ?
|
|
3399
|
+
var u = Ri(), d = u.invert, m = u.domain, v = l(".%L"), S = l(":%S"), w = l("%I:%M"), x = l("%I %p"), R = l("%a %d"), L = l("%b %d"), M = l("%B"), Y = l("%Y");
|
|
3400
|
+
function N(E) {
|
|
3401
|
+
return (c(E) < E ? v : o(E) < E ? S : a(E) < E ? w : i(E) < E ? x : s(E) < E ? r(E) < E ? R : L : t(E) < E ? M : Y)(E);
|
|
3397
3402
|
}
|
|
3398
3403
|
return u.invert = function(E) {
|
|
3399
3404
|
return new Date(d(E));
|
|
3400
3405
|
}, u.domain = function(E) {
|
|
3401
3406
|
return arguments.length ? m(Array.from(E, Vc)) : m().map(Wc);
|
|
3402
3407
|
}, u.ticks = function(E) {
|
|
3403
|
-
var
|
|
3404
|
-
return n(
|
|
3405
|
-
}, u.tickFormat = function(E,
|
|
3406
|
-
return
|
|
3408
|
+
var I = m();
|
|
3409
|
+
return n(I[0], I[I.length - 1], E ?? 10);
|
|
3410
|
+
}, u.tickFormat = function(E, I) {
|
|
3411
|
+
return I == null ? N : l(I);
|
|
3407
3412
|
}, u.nice = function(E) {
|
|
3408
|
-
var
|
|
3409
|
-
return (!E || typeof E.range != "function") && (E = e(
|
|
3413
|
+
var I = m();
|
|
3414
|
+
return (!E || typeof E.range != "function") && (E = e(I[0], I[I.length - 1], E ?? 10)), E ? m(Ol(I, E)) : u;
|
|
3410
3415
|
}, u.copy = function() {
|
|
3411
3416
|
return Pi(u, Zi(n, e, t, s, r, i, a, o, c, l));
|
|
3412
3417
|
}, u;
|
|
3413
3418
|
}
|
|
3414
3419
|
function Xc() {
|
|
3415
|
-
return Ti.apply(Zi(
|
|
3420
|
+
return Ti.apply(Zi(Hl, jl, de, Ps, mn, wt, Cs, Es, Ye, Bi).domain([new Date(2e3, 0, 1), new Date(2e3, 0, 2)]), arguments);
|
|
3416
3421
|
}
|
|
3417
|
-
const
|
|
3418
|
-
|
|
3422
|
+
const ir = [
|
|
3423
|
+
T.NANOSECOND,
|
|
3419
3424
|
// 1ns
|
|
3420
|
-
|
|
3425
|
+
T.nanoseconds(2),
|
|
3421
3426
|
// 2ns
|
|
3422
|
-
|
|
3427
|
+
T.nanoseconds(5),
|
|
3423
3428
|
// 5ns
|
|
3424
|
-
|
|
3429
|
+
T.nanoseconds(10),
|
|
3425
3430
|
// 10ns
|
|
3426
|
-
|
|
3431
|
+
T.nanoseconds(20),
|
|
3427
3432
|
// 20ns
|
|
3428
|
-
|
|
3433
|
+
T.nanoseconds(50),
|
|
3429
3434
|
// 50ns
|
|
3430
|
-
|
|
3435
|
+
T.nanoseconds(100),
|
|
3431
3436
|
// 100ns
|
|
3432
|
-
|
|
3437
|
+
T.nanoseconds(200),
|
|
3433
3438
|
// 200ns
|
|
3434
|
-
|
|
3439
|
+
T.nanoseconds(500),
|
|
3435
3440
|
// 500ns
|
|
3436
|
-
|
|
3441
|
+
T.MICROSECOND,
|
|
3437
3442
|
// 1µs
|
|
3438
|
-
|
|
3443
|
+
T.microseconds(2),
|
|
3439
3444
|
// 2µs
|
|
3440
|
-
|
|
3445
|
+
T.microseconds(5),
|
|
3441
3446
|
// 5µs
|
|
3442
|
-
|
|
3447
|
+
T.microseconds(10),
|
|
3443
3448
|
// 10µs
|
|
3444
|
-
|
|
3449
|
+
T.microseconds(20),
|
|
3445
3450
|
// 20µs
|
|
3446
|
-
|
|
3451
|
+
T.microseconds(50),
|
|
3447
3452
|
// 50µs
|
|
3448
|
-
|
|
3453
|
+
T.microseconds(100),
|
|
3449
3454
|
// 100µs
|
|
3450
|
-
|
|
3455
|
+
T.microseconds(200),
|
|
3451
3456
|
// 200µs
|
|
3452
|
-
|
|
3457
|
+
T.microseconds(500),
|
|
3453
3458
|
// 500µs
|
|
3454
|
-
|
|
3459
|
+
T.MILLISECOND,
|
|
3455
3460
|
// 1ms
|
|
3456
|
-
|
|
3461
|
+
T.milliseconds(2),
|
|
3457
3462
|
// 2ms
|
|
3458
|
-
|
|
3463
|
+
T.milliseconds(5),
|
|
3459
3464
|
// 5ms
|
|
3460
|
-
|
|
3465
|
+
T.milliseconds(10),
|
|
3461
3466
|
// 10ms
|
|
3462
|
-
|
|
3467
|
+
T.milliseconds(20),
|
|
3463
3468
|
// 20ms
|
|
3464
|
-
|
|
3469
|
+
T.milliseconds(50),
|
|
3465
3470
|
// 50ms
|
|
3466
|
-
|
|
3471
|
+
T.milliseconds(100),
|
|
3467
3472
|
// 100ms
|
|
3468
|
-
|
|
3473
|
+
T.milliseconds(200),
|
|
3469
3474
|
// 200ms
|
|
3470
|
-
|
|
3475
|
+
T.milliseconds(500),
|
|
3471
3476
|
// 500ms
|
|
3472
|
-
|
|
3477
|
+
T.SECOND
|
|
3473
3478
|
// 1s
|
|
3474
3479
|
];
|
|
3475
3480
|
class Gc {
|
|
@@ -3480,10 +3485,10 @@ class Gc {
|
|
|
3480
3485
|
* Creates a new PreciseTimeScale instance with default domain [0, 1] and range [0, 1].
|
|
3481
3486
|
*/
|
|
3482
3487
|
constructor() {
|
|
3483
|
-
this._domain = [new
|
|
3488
|
+
this._domain = [new A(0n), new A(1n)], this._range = [0, 1], this._span = this._domain[1].span(this._domain[0]);
|
|
3484
3489
|
}
|
|
3485
3490
|
domain(e) {
|
|
3486
|
-
return e === void 0 ? this._domain : (this._domain = [new
|
|
3491
|
+
return e === void 0 ? this._domain : (this._domain = [new A(e[0]), new A(e[1])], this._span = this._domain[1].span(this._domain[0]), this);
|
|
3487
3492
|
}
|
|
3488
3493
|
range(e) {
|
|
3489
3494
|
return e === void 0 ? this._range : (this._range = e, this);
|
|
@@ -3495,7 +3500,7 @@ class Gc {
|
|
|
3495
3500
|
* @returns The scaled numeric value within the range
|
|
3496
3501
|
*/
|
|
3497
3502
|
scale(e) {
|
|
3498
|
-
const s = new
|
|
3503
|
+
const s = new A(e).valueOf(), r = this._domain[0].valueOf(), i = this._domain[1].valueOf() - r, a = this._range[1] - this._range[0];
|
|
3499
3504
|
return Number(s - r) / Number(i) * a + this._range[0];
|
|
3500
3505
|
}
|
|
3501
3506
|
/**
|
|
@@ -3509,7 +3514,7 @@ class Gc {
|
|
|
3509
3514
|
const t = this.calculateOptimalStep(e).valueOf(), s = this._domain[0].valueOf(), r = this._domain[1].valueOf(), i = (s + t - 1n) / t * t, a = Number((r - i) / t);
|
|
3510
3515
|
return Array.from({ length: a + 1 }, (o, c) => {
|
|
3511
3516
|
const l = i + BigInt(c) * t;
|
|
3512
|
-
return new
|
|
3517
|
+
return new A(l);
|
|
3513
3518
|
}).filter((o) => o.afterEq(this._domain[0]) && o.beforeEq(this._domain[1]));
|
|
3514
3519
|
}
|
|
3515
3520
|
/**
|
|
@@ -3521,8 +3526,8 @@ class Gc {
|
|
|
3521
3526
|
*/
|
|
3522
3527
|
calculateOptimalStep(e) {
|
|
3523
3528
|
const t = this._span.valueOf() / BigInt(Math.ceil(e));
|
|
3524
|
-
let s =
|
|
3525
|
-
for (const r of
|
|
3529
|
+
let s = ir[0];
|
|
3530
|
+
for (const r of ir) {
|
|
3526
3531
|
if (r.valueOf() > t) break;
|
|
3527
3532
|
s = r;
|
|
3528
3533
|
}
|
|
@@ -3538,13 +3543,13 @@ class Gc {
|
|
|
3538
3543
|
* @returns Formatted string representation of the timestamp
|
|
3539
3544
|
*/
|
|
3540
3545
|
formatTick(e) {
|
|
3541
|
-
return this._span.lessThan(
|
|
3546
|
+
return this._span.lessThan(T.microseconds(50)) ? `${e.remainder(T.MILLISECOND).microseconds.toString()}µs` : `${e.remainder(T.SECOND).milliseconds.toString()}ms`;
|
|
3542
3547
|
}
|
|
3543
3548
|
}
|
|
3544
3549
|
const Kc = () => new Gc(), Ui = h.enum(["linear", "time"]), $i = h.object({
|
|
3545
3550
|
tickSpacing: h.number().default(75),
|
|
3546
3551
|
type: Ui.optional().default("linear")
|
|
3547
|
-
}),
|
|
3552
|
+
}), ar = (n) => {
|
|
3548
3553
|
const e = $i.parse(n);
|
|
3549
3554
|
return eu[e.type](e);
|
|
3550
3555
|
};
|
|
@@ -3556,12 +3561,12 @@ class Qc {
|
|
|
3556
3561
|
normalScale;
|
|
3557
3562
|
preciseScale;
|
|
3558
3563
|
constructor(e) {
|
|
3559
|
-
this.props = e, this.normalScale = Xc(), this.preciseScale = Kc(), this.prevScaleSize = 0, this.prevDomain = new G(new
|
|
3564
|
+
this.props = e, this.normalScale = Xc(), this.preciseScale = Kc(), this.prevScaleSize = 0, this.prevDomain = new G(new A(0), new A(0)), this.currTicks = [];
|
|
3560
3565
|
}
|
|
3561
3566
|
create({ decimalToDataScale: e, size: t }) {
|
|
3562
3567
|
const s = new G(
|
|
3563
|
-
new
|
|
3564
|
-
new
|
|
3568
|
+
new A(e.pos(0)),
|
|
3569
|
+
new A(e.pos(1))
|
|
3565
3570
|
);
|
|
3566
3571
|
if (this.prevDomain.equals(s) && this.prevScaleSize === t)
|
|
3567
3572
|
return this.currTicks;
|
|
@@ -3571,14 +3576,14 @@ class Qc {
|
|
|
3571
3576
|
}
|
|
3572
3577
|
if (s.span.milliseconds < 5) {
|
|
3573
3578
|
this.preciseScale.domain([s.start, s.end]);
|
|
3574
|
-
const r =
|
|
3579
|
+
const r = Fn(t, this.props.tickSpacing) / 2, i = this.preciseScale.ticks(r);
|
|
3575
3580
|
this.currTicks = i.map((a) => ({
|
|
3576
3581
|
label: this.preciseScale.formatTick(a),
|
|
3577
3582
|
position: this.preciseScale.scale(a)
|
|
3578
3583
|
}));
|
|
3579
3584
|
} else {
|
|
3580
3585
|
this.normalScale.domain([s.start.date(), s.end.date()]);
|
|
3581
|
-
const r = this.normalScale.ticks(
|
|
3586
|
+
const r = this.normalScale.ticks(Fn(t, this.props.tickSpacing));
|
|
3582
3587
|
this.currTicks = r.map((i) => ({
|
|
3583
3588
|
label: this.normalTickLabel(i),
|
|
3584
3589
|
position: this.normalScale(i)
|
|
@@ -3603,14 +3608,14 @@ class Jc {
|
|
|
3603
3608
|
currTicks;
|
|
3604
3609
|
d3Scale;
|
|
3605
3610
|
constructor(e) {
|
|
3606
|
-
this.props = e, this.prevDomain = C.construct(0, 0), this.prevScaleSize = 0, this.currTicks = [], this.d3Scale =
|
|
3611
|
+
this.props = e, this.prevDomain = C.construct(0, 0), this.prevScaleSize = 0, this.currTicks = [], this.d3Scale = Li();
|
|
3607
3612
|
}
|
|
3608
3613
|
create({ decimalToDataScale: e, size: t }) {
|
|
3609
3614
|
const s = { lower: e.pos(0), upper: e.pos(1) };
|
|
3610
3615
|
if (C.equals(this.prevDomain, s) && this.prevScaleSize === t)
|
|
3611
3616
|
return this.currTicks;
|
|
3612
3617
|
C.equals(this.prevDomain, s) || (this.d3Scale = this.d3Scale.domain([s.lower, s.upper])), this.prevScaleSize !== t && (this.d3Scale = this.d3Scale.range([0, t])), this.prevDomain = s, this.prevScaleSize = t;
|
|
3613
|
-
const r =
|
|
3618
|
+
const r = Fn(t, this.props.tickSpacing), i = this.d3Scale.ticks(r);
|
|
3614
3619
|
return this.currTicks = i.map((a) => ({
|
|
3615
3620
|
label: this.tickLabel(a),
|
|
3616
3621
|
position: this.d3Scale(a)
|
|
@@ -3620,51 +3625,51 @@ class Jc {
|
|
|
3620
3625
|
return e.toString();
|
|
3621
3626
|
}
|
|
3622
3627
|
}
|
|
3623
|
-
const
|
|
3628
|
+
const Fn = (n, e) => {
|
|
3624
3629
|
const t = Math.floor(n / e);
|
|
3625
3630
|
return t > 0 ? t : 1;
|
|
3626
3631
|
}, eu = {
|
|
3627
3632
|
linear: (n) => new Jc(n),
|
|
3628
3633
|
time: (n) => new Qc(n)
|
|
3629
|
-
},
|
|
3634
|
+
}, qi = $i.extend({
|
|
3630
3635
|
color: y.colorZ,
|
|
3631
3636
|
type: Ui.optional().default("linear"),
|
|
3632
3637
|
font: h.string(),
|
|
3633
3638
|
showGrid: h.boolean().optional().default(!0),
|
|
3634
3639
|
location: se.outer,
|
|
3635
3640
|
gridColor: y.colorZ
|
|
3636
|
-
}), J = 5,
|
|
3641
|
+
}), J = 5, ht = 6, xt = { useAtlas: !0 }, tu = {
|
|
3637
3642
|
bottom: (n, e) => new su(n, e),
|
|
3638
3643
|
top: (n, e) => new ru(n, e),
|
|
3639
3644
|
left: (n, e) => new iu(n, e),
|
|
3640
3645
|
right: (n, e) => new au(n, e)
|
|
3641
3646
|
}, nu = (n, e, t) => tu[n](e, t);
|
|
3642
|
-
class
|
|
3647
|
+
class Ke {
|
|
3643
3648
|
renderCtx;
|
|
3644
3649
|
state;
|
|
3645
3650
|
tickFactory;
|
|
3646
3651
|
constructor(e, t) {
|
|
3647
|
-
this.renderCtx = e, this.state = t, this.tickFactory =
|
|
3652
|
+
this.renderCtx = e, this.state = t, this.tickFactory = ar(this.state);
|
|
3648
3653
|
}
|
|
3649
3654
|
setState(e) {
|
|
3650
|
-
this.state = ga(
|
|
3655
|
+
this.state = ga(qi, e), this.tickFactory = ar(e);
|
|
3651
3656
|
}
|
|
3652
3657
|
drawLine(e, t) {
|
|
3653
3658
|
const { lower2d: s } = this.renderCtx;
|
|
3654
3659
|
s.moveTo(...f.couple(e)), s.lineTo(...f.couple(t));
|
|
3655
3660
|
}
|
|
3656
3661
|
drawTicks(e, t) {
|
|
3657
|
-
let s =
|
|
3662
|
+
let s = Ms.ZERO;
|
|
3658
3663
|
return e.forEach((r) => {
|
|
3659
|
-
const i = this.renderCtx.lower2d.textDimensions(r.label,
|
|
3660
|
-
s =
|
|
3664
|
+
const i = this.renderCtx.lower2d.textDimensions(r.label, xt);
|
|
3665
|
+
s = Ms.max([s, i]), t(i, r);
|
|
3661
3666
|
}), s;
|
|
3662
3667
|
}
|
|
3663
3668
|
static START_BOUND = C.construct(-1, 1);
|
|
3664
3669
|
maybeDrawGrid(e, t, s) {
|
|
3665
3670
|
const { showGrid: r, gridColor: i } = this.state;
|
|
3666
3671
|
if (r) {
|
|
3667
|
-
const a =
|
|
3672
|
+
const a = Ke.START_BOUND, o = C.construct(e - 1, e + 1), { lower2d: c } = this.renderCtx;
|
|
3668
3673
|
c.beginPath(), c.strokeStyle = y.hex(i), t.forEach((l) => {
|
|
3669
3674
|
C.contains(a, l.position) || C.contains(o, l.position) || this.drawLine(...s(l));
|
|
3670
3675
|
}), c.stroke();
|
|
@@ -3675,7 +3680,7 @@ class Qe {
|
|
|
3675
3680
|
this.renderCtx.lower2d.strokeStyle = t, this.renderCtx.lower2d.fillStyle = t, this.renderCtx.lower2d.font = this.state.font;
|
|
3676
3681
|
}
|
|
3677
3682
|
}
|
|
3678
|
-
class su extends
|
|
3683
|
+
class su extends Ke {
|
|
3679
3684
|
render(e) {
|
|
3680
3685
|
const { lower2d: t } = this.renderCtx, { plot: s, position: r } = e, { width: i, height: a } = p.dims(s), o = this.tickFactory.create({ ...e, size: i });
|
|
3681
3686
|
t.beginPath(), this.setColor(this.state.color), this.drawLine(r, f.translate(r, "x", i));
|
|
@@ -3686,18 +3691,18 @@ class su extends Qe {
|
|
|
3686
3691
|
), t.fillText(
|
|
3687
3692
|
u.label,
|
|
3688
3693
|
r.x + u.position - l.width / 2,
|
|
3689
|
-
r.y + J + l.height +
|
|
3694
|
+
r.y + J + l.height + ht,
|
|
3690
3695
|
void 0,
|
|
3691
|
-
|
|
3696
|
+
xt
|
|
3692
3697
|
);
|
|
3693
3698
|
});
|
|
3694
3699
|
return t.stroke(), this.maybeDrawGrid(i, o, (l) => [
|
|
3695
3700
|
f.translate(r, "x", l.position),
|
|
3696
3701
|
f.translate(r, { x: l.position, y: -a })
|
|
3697
|
-
]), { size: c.height + J +
|
|
3702
|
+
]), { size: c.height + J + ht };
|
|
3698
3703
|
}
|
|
3699
3704
|
}
|
|
3700
|
-
class ru extends
|
|
3705
|
+
class ru extends Ke {
|
|
3701
3706
|
render(e) {
|
|
3702
3707
|
const { lower2d: t } = this.renderCtx, { plot: s } = e, { width: r, height: i } = p.dims(s), a = f.translate(e.position, "y", e.size), o = this.tickFactory.create({ ...e, size: r });
|
|
3703
3708
|
t.beginPath(), this.setColor(this.state.color), this.drawLine(a, f.translate(a, "x", r));
|
|
@@ -3708,9 +3713,9 @@ class ru extends Qe {
|
|
|
3708
3713
|
), t.fillText(
|
|
3709
3714
|
u.label,
|
|
3710
3715
|
a.x + u.position - l.width / 2,
|
|
3711
|
-
a.y - J - l.height -
|
|
3716
|
+
a.y - J - l.height - ht,
|
|
3712
3717
|
void 0,
|
|
3713
|
-
|
|
3718
|
+
xt
|
|
3714
3719
|
);
|
|
3715
3720
|
});
|
|
3716
3721
|
return t.stroke(), this.maybeDrawGrid(r, o, (l) => [
|
|
@@ -3719,7 +3724,7 @@ class ru extends Qe {
|
|
|
3719
3724
|
]), { size: c.height + J };
|
|
3720
3725
|
}
|
|
3721
3726
|
}
|
|
3722
|
-
class iu extends
|
|
3727
|
+
class iu extends Ke {
|
|
3723
3728
|
render(e) {
|
|
3724
3729
|
const { lower2d: t } = this.renderCtx, { plot: s, position: r } = e, { height: i, width: a } = p.dims(s), o = f.translate(r, "x", e.size), c = this.tickFactory.create({ ...e, size: i });
|
|
3725
3730
|
t.beginPath(), this.setColor(this.state.color), this.drawLine(o, f.translate(o, "y", i));
|
|
@@ -3732,7 +3737,7 @@ class iu extends Qe {
|
|
|
3732
3737
|
o.x - u.width - J * 2,
|
|
3733
3738
|
o.y + d.position + u.height / 2,
|
|
3734
3739
|
void 0,
|
|
3735
|
-
|
|
3740
|
+
xt
|
|
3736
3741
|
);
|
|
3737
3742
|
});
|
|
3738
3743
|
return t.stroke(), this.maybeDrawGrid(i, c, (u) => [
|
|
@@ -3741,7 +3746,7 @@ class iu extends Qe {
|
|
|
3741
3746
|
]), { size: l.width + J * 2 };
|
|
3742
3747
|
}
|
|
3743
3748
|
}
|
|
3744
|
-
class au extends
|
|
3749
|
+
class au extends Ke {
|
|
3745
3750
|
render(e) {
|
|
3746
3751
|
const { lower2d: t } = this.renderCtx, { plot: s, position: r } = e, { height: i, width: a } = p.dims(s), o = this.tickFactory.create({ ...e, size: i });
|
|
3747
3752
|
t.beginPath(), this.setColor(this.state.color), this.drawLine(r, f.translateY(r, i));
|
|
@@ -3751,19 +3756,19 @@ class au extends Qe {
|
|
|
3751
3756
|
f.translate(r, { x: J, y: u.position })
|
|
3752
3757
|
), t.fillText(
|
|
3753
3758
|
u.label,
|
|
3754
|
-
r.x + J +
|
|
3759
|
+
r.x + J + ht,
|
|
3755
3760
|
r.y + u.position + l.height / 2,
|
|
3756
3761
|
void 0,
|
|
3757
|
-
|
|
3762
|
+
xt
|
|
3758
3763
|
);
|
|
3759
3764
|
});
|
|
3760
3765
|
return t.stroke(), this.maybeDrawGrid(i, o, (l) => [
|
|
3761
3766
|
f.translateY(r, l.position),
|
|
3762
3767
|
f.translate(r, { x: -a, y: l.position })
|
|
3763
|
-
]), { size: c.width + J +
|
|
3768
|
+
]), { size: c.width + J + ht };
|
|
3764
3769
|
}
|
|
3765
3770
|
}
|
|
3766
|
-
const gn =
|
|
3771
|
+
const gn = qi.extend({
|
|
3767
3772
|
axisKey: h.string().optional(),
|
|
3768
3773
|
bounds: C.bounds.optional(),
|
|
3769
3774
|
autoBounds: h.object({
|
|
@@ -3771,7 +3776,7 @@ const gn = Fi.extend({
|
|
|
3771
3776
|
upper: h.boolean().optional().default(!0)
|
|
3772
3777
|
}).or(h.boolean().optional().default(!0)),
|
|
3773
3778
|
autoBoundPadding: h.number().optional(),
|
|
3774
|
-
autoBoundUpdateInterval:
|
|
3779
|
+
autoBoundUpdateInterval: T.z.optional().default(T.seconds(10)),
|
|
3775
3780
|
size: h.number().optional().default(0),
|
|
3776
3781
|
label: h.string().optional().default(""),
|
|
3777
3782
|
labelSize: h.number().optional().default(0)
|
|
@@ -3781,25 +3786,25 @@ const gn = Fi.extend({
|
|
|
3781
3786
|
upper: n + ou
|
|
3782
3787
|
},
|
|
3783
3788
|
e
|
|
3784
|
-
), uu = C.DECIMAL,
|
|
3785
|
-
lower: Number(
|
|
3786
|
-
upper: Number(
|
|
3787
|
-
},
|
|
3789
|
+
), uu = C.DECIMAL, or = A.now(), hu = {
|
|
3790
|
+
lower: Number(or.valueOf()),
|
|
3791
|
+
upper: Number(or.add(T.HOUR).valueOf())
|
|
3792
|
+
}, Fi = (n) => n === "linear" ? uu : hu, du = (n, e = 0.1, t) => {
|
|
3788
3793
|
const s = C.max(n.filter(C.isFinite));
|
|
3789
|
-
if (!C.isFinite(s)) return
|
|
3794
|
+
if (!C.isFinite(s)) return Fi(t);
|
|
3790
3795
|
const { lower: r, upper: i } = s;
|
|
3791
3796
|
if (i === r) return { lower: r - 1, upper: i + 1 };
|
|
3792
3797
|
const a = (i - r) * e;
|
|
3793
3798
|
return { lower: r - a, upper: i + a };
|
|
3794
3799
|
}, fu = 0.01, pu = 0.1;
|
|
3795
|
-
class
|
|
3800
|
+
class Hi extends ae {
|
|
3796
3801
|
afterUpdate(e) {
|
|
3797
3802
|
const { internal: t } = this, { location: s, autoBoundUpdateInterval: r } = this.state;
|
|
3798
3803
|
t.render = V.use(e);
|
|
3799
3804
|
const i = fe(e), a = re.construct(s);
|
|
3800
3805
|
this.state.autoBoundPadding ??= a === "x" ? pu : fu, t.core = nu(s, t.render, {
|
|
3801
3806
|
color: i.colors.gray.l10,
|
|
3802
|
-
font:
|
|
3807
|
+
font: rt(i, { level: "small", code: !0 }),
|
|
3803
3808
|
gridColor: i.colors.gray.l1,
|
|
3804
3809
|
...this.state
|
|
3805
3810
|
}), ge(e, "layout"), t.updateBounds ??= ya(
|
|
@@ -3812,7 +3817,7 @@ class ji extends ae {
|
|
|
3812
3817
|
}
|
|
3813
3818
|
renderAxis(e, t) {
|
|
3814
3819
|
if (!e.canvases.includes("lower2d")) return;
|
|
3815
|
-
const { core: s } = this.internal, { grid: r, container: i } = e, a =
|
|
3820
|
+
const { core: s } = this.internal, { grid: r, container: i } = e, a = Oo(`${this.type}-${this.key}`, r, i), o = {
|
|
3816
3821
|
...e,
|
|
3817
3822
|
position: a,
|
|
3818
3823
|
decimalToDataScale: t,
|
|
@@ -3835,7 +3840,7 @@ class ji extends ae {
|
|
|
3835
3840
|
const l = t();
|
|
3836
3841
|
a = du(l, this.state.autoBoundPadding, this.state.type);
|
|
3837
3842
|
} catch (l) {
|
|
3838
|
-
a =
|
|
3843
|
+
a = Fi(this.state.type), o = l;
|
|
3839
3844
|
}
|
|
3840
3845
|
const c = i(a);
|
|
3841
3846
|
return this.internal.boundSnapshot = c, (this.state.bounds == null || s && this.state.bounds.lower !== c.lower || r && this.state.bounds.upper !== c.upper) && this.internal.updateBounds?.(c), [c, o];
|
|
@@ -3848,7 +3853,7 @@ class ji extends ae {
|
|
|
3848
3853
|
];
|
|
3849
3854
|
}
|
|
3850
3855
|
}
|
|
3851
|
-
const mu = (n) => typeof n == "boolean" ? { lower: n, upper: n } : { lower: n?.lower ?? !0, upper: n?.upper ?? !0 },
|
|
3856
|
+
const mu = (n) => typeof n == "boolean" ? { lower: n, upper: n } : { lower: n?.lower ?? !0, upper: n?.upper ?? !0 }, lr = `#version 300 es
|
|
3852
3857
|
precision lowp float;
|
|
3853
3858
|
|
|
3854
3859
|
uniform lowp vec4 u_color;
|
|
@@ -3900,18 +3905,18 @@ void main(void) {
|
|
|
3900
3905
|
gl_Position = vec4((u_scale_aggregate * vec2(a_x, float(a_y)) + u_offset_aggregate) + a_translate, 0.0, 1.0);
|
|
3901
3906
|
}
|
|
3902
3907
|
`, vu = h.object({
|
|
3903
|
-
x:
|
|
3904
|
-
y:
|
|
3908
|
+
x: Lt,
|
|
3909
|
+
y: Lt,
|
|
3905
3910
|
label: h.string().optional(),
|
|
3906
3911
|
color: y.colorZ,
|
|
3907
3912
|
strokeWidth: h.number().default(1),
|
|
3908
3913
|
downsample: h.number().min(1).max(50).default(1),
|
|
3909
|
-
downsampleMode:
|
|
3914
|
+
downsampleMode: ms.default("decimate"),
|
|
3910
3915
|
visible: h.boolean().optional().default(!0)
|
|
3911
|
-
}), bu = (n, e, t) => n === -1 || e === -1 || n >= t.series.length ? NaN : Number(t.series[n].at(e)), wu =
|
|
3916
|
+
}), bu = (n, e, t) => n === -1 || e === -1 || n >= t.series.length ? NaN : Number(t.series[n].at(e)), wu = T.milliseconds(2);
|
|
3912
3917
|
f.NAN, f.NAN, y.ZERO, C.ZERO;
|
|
3913
3918
|
const xu = (n, e) => e.equals($.UINT8) ? n.UNSIGNED_BYTE : n.FLOAT;
|
|
3914
|
-
class
|
|
3919
|
+
class cr extends va {
|
|
3915
3920
|
translationBufferCache = /* @__PURE__ */ new Map();
|
|
3916
3921
|
constructor(e, t, s) {
|
|
3917
3922
|
super(e, t, s), this.translationBufferCache = /* @__PURE__ */ new Map();
|
|
@@ -3975,7 +3980,7 @@ class lr extends va {
|
|
|
3975
3980
|
return t.vertexAttribPointer(r, 2, t.FLOAT, !1, 0, 0), t.enableVertexAttribArray(r), t.vertexAttribDivisor(r, 1), s.length / 2;
|
|
3976
3981
|
}
|
|
3977
3982
|
}
|
|
3978
|
-
class
|
|
3983
|
+
class Ne {
|
|
3979
3984
|
static CONTEXT_KEY = "pluto-line-gl-program";
|
|
3980
3985
|
// Uint8 hybrid program is used for high performance rendering of uint8 data along
|
|
3981
3986
|
// with float32 timestamp data. It's used as a hot path optimization for common
|
|
@@ -3985,7 +3990,7 @@ class Ie {
|
|
|
3985
3990
|
// channel types.
|
|
3986
3991
|
float32Program;
|
|
3987
3992
|
constructor(e) {
|
|
3988
|
-
this.uint8HybridProgram = new
|
|
3993
|
+
this.uint8HybridProgram = new cr(e, yu, lr), this.float32Program = new cr(e, gu, lr);
|
|
3989
3994
|
}
|
|
3990
3995
|
get gl() {
|
|
3991
3996
|
return this.uint8HybridProgram.renderCtx.gl;
|
|
@@ -3994,26 +3999,26 @@ class Ie {
|
|
|
3994
3999
|
return e.equals($.UINT8) ? this.uint8HybridProgram : this.float32Program;
|
|
3995
4000
|
}
|
|
3996
4001
|
static create(e, t) {
|
|
3997
|
-
const s = new
|
|
3998
|
-
return e.set(
|
|
4002
|
+
const s = new Ne(t);
|
|
4003
|
+
return e.set(Ne.CONTEXT_KEY, s), s;
|
|
3999
4004
|
}
|
|
4000
4005
|
static use(e) {
|
|
4001
|
-
const t = e.get(
|
|
4006
|
+
const t = e.get(Ne.CONTEXT_KEY);
|
|
4002
4007
|
if (t == null) throw new Ee("GLProgram not found");
|
|
4003
4008
|
return t;
|
|
4004
4009
|
}
|
|
4005
4010
|
}
|
|
4006
|
-
class
|
|
4011
|
+
class Hn extends q {
|
|
4007
4012
|
static TYPE = "line";
|
|
4008
4013
|
schema = vu;
|
|
4009
4014
|
afterUpdate(e) {
|
|
4010
4015
|
const { internal: t } = this, s = {
|
|
4011
|
-
onStatusChange:
|
|
4016
|
+
onStatusChange: Or(e)
|
|
4012
4017
|
};
|
|
4013
|
-
t.xTelem = ee(e, this.state.x, t.xTelem, s), t.yTelem = ee(e, this.state.y, t.yTelem, s), t.instrumentation =
|
|
4018
|
+
t.xTelem = ee(e, this.state.x, t.xTelem, s), t.yTelem = ee(e, this.state.y, t.yTelem, s), t.instrumentation = mt(e, "line"), t.lineCtx = Ne.use(e), t.requestRender = as(e), t.stopListeningXTelem?.(), t.stopListeningYTelem?.(), t.stopListeningXTelem = t.xTelem.onChange(() => t.requestRender("data")), t.stopListeningYTelem = t.yTelem.onChange(() => t.requestRender("data")), t.requestRender("layout"), (t.xDownsampler?.props.mode !== this.state.downsampleMode || t.xDownsampler?.props.windowSize !== this.state.downsample) && (t.xDownsampler = new at({
|
|
4014
4019
|
mode: this.state.downsampleMode,
|
|
4015
4020
|
windowSize: this.state.downsample
|
|
4016
|
-
}), t.yDownsampler = new
|
|
4021
|
+
}), t.yDownsampler = new at({
|
|
4017
4022
|
mode: this.state.downsampleMode,
|
|
4018
4023
|
windowSize: this.state.downsample
|
|
4019
4024
|
}));
|
|
@@ -4034,8 +4039,8 @@ class jn extends F {
|
|
|
4034
4039
|
i = this.internal.xDownsampler.transform(i);
|
|
4035
4040
|
let [a, o] = [-1, -1];
|
|
4036
4041
|
i.series.find((x, R) => {
|
|
4037
|
-
const
|
|
4038
|
-
return M && ([a, o] = [
|
|
4042
|
+
const L = x.binarySearch(t), M = L >= 0 && L < x.length;
|
|
4043
|
+
return M && ([a, o] = [L, R]), M;
|
|
4039
4044
|
});
|
|
4040
4045
|
const { key: c } = this, { color: l, label: u } = this.state, d = {
|
|
4041
4046
|
key: c,
|
|
@@ -4050,12 +4055,12 @@ class jn extends F {
|
|
|
4050
4055
|
d.value.x = bu(o, a, i);
|
|
4051
4056
|
let [, v] = r.value();
|
|
4052
4057
|
v = this.internal.yDownsampler.transform(v);
|
|
4053
|
-
const
|
|
4058
|
+
const S = v.series.find(
|
|
4054
4059
|
(x) => C.contains(x.alignmentBounds, m.alignment + BigInt(a))
|
|
4055
4060
|
);
|
|
4056
|
-
if (
|
|
4057
|
-
const w = Number(
|
|
4058
|
-
return d.value.y = Number(
|
|
4061
|
+
if (S == null) return d;
|
|
4062
|
+
const w = Number(S.alignment - m.alignment);
|
|
4063
|
+
return d.value.y = Number(S.at(a - w)), d.bounds = { ...S.bounds }, d.position = {
|
|
4059
4064
|
x: e.dataToDecimalScale.x.pos(d.value.x),
|
|
4060
4065
|
y: e.dataToDecimalScale.y.pos(d.value.y)
|
|
4061
4066
|
}, d;
|
|
@@ -4080,11 +4085,11 @@ class jn extends F {
|
|
|
4080
4085
|
props: e.region,
|
|
4081
4086
|
ops: Mu(v)
|
|
4082
4087
|
}));
|
|
4083
|
-
const
|
|
4088
|
+
const S = m.setAsActive(), w = m.bindState(this.state), x = m.renderCtx.scaleRegion(e.region).transform;
|
|
4084
4089
|
v.forEach((R) => {
|
|
4085
|
-
const
|
|
4086
|
-
m.bindScale(
|
|
4087
|
-
}),
|
|
4090
|
+
const L = Pu(c, R).transform;
|
|
4091
|
+
m.bindScale(L, x), m.draw(R, w, u.dataType, d.dataType);
|
|
4092
|
+
}), S();
|
|
4088
4093
|
}
|
|
4089
4094
|
}
|
|
4090
4095
|
const Su = 5e3, Tu = (n, e) => ku(Cu(n), e).map(
|
|
@@ -4115,29 +4120,39 @@ const Su = 5e3, Tu = (n, e) => ku(Cu(n), e).map(
|
|
|
4115
4120
|
}, Pu = (n, e) => n.translate(
|
|
4116
4121
|
n.x.dim(Number(e.x.sampleOffset)),
|
|
4117
4122
|
n.y.dim(Number(e.y.sampleOffset))
|
|
4118
|
-
), $h = { [
|
|
4123
|
+
), $h = { [Hn.TYPE]: Hn }, Ru = (n, e, t, s, r, i) => {
|
|
4119
4124
|
if (n.series.length === 0 || e.series.length === 0) return [];
|
|
4120
4125
|
const a = [];
|
|
4121
4126
|
return n.series.forEach(
|
|
4122
4127
|
(o) => e.series.forEach((c) => {
|
|
4123
|
-
if (!
|
|
4124
|
-
let l =
|
|
4125
|
-
o.alignment < c.alignment ? l =
|
|
4126
|
-
const d =
|
|
4127
|
-
|
|
4128
|
+
if (!Ou(o, c, i)) return;
|
|
4129
|
+
let l = 0n, u = 0n;
|
|
4130
|
+
o.alignment < c.alignment ? l = c.alignment - o.alignment : c.alignment < o.alignment && (u = o.alignment - c.alignment);
|
|
4131
|
+
const d = es.min(
|
|
4132
|
+
C.span(o.alignmentBounds) - l,
|
|
4133
|
+
C.span(c.alignmentBounds) - u
|
|
4134
|
+
);
|
|
4135
|
+
if (d === 0n) return;
|
|
4128
4136
|
let m = kr(
|
|
4129
|
-
Math.round(t * 4 * d),
|
|
4137
|
+
Math.round(t * 4 * Number(d)),
|
|
4130
4138
|
s,
|
|
4131
4139
|
51
|
|
4132
4140
|
);
|
|
4133
|
-
r !== "decimate" && (m = 1)
|
|
4141
|
+
r !== "decimate" && (m = 1);
|
|
4142
|
+
const v = Number(d / o.alignmentMultiple), S = Number(l / o.alignmentMultiple), w = Number(u / c.alignmentMultiple);
|
|
4143
|
+
a.push({ x: o, y: c, xOffset: S, yOffset: w, count: v, downsample: m });
|
|
4134
4144
|
})
|
|
4135
4145
|
), a;
|
|
4136
|
-
}, Mu = (n) => n.map((e) => ({ ...e, x: e.x.digest, y: e.y.digest })),
|
|
4146
|
+
}, Mu = (n) => n.map((e) => ({ ...e, x: e.x.digest, y: e.y.digest })), Ou = (n, e, t) => {
|
|
4147
|
+
if (n.alignmentMultiple !== e.alignmentMultiple)
|
|
4148
|
+
return console.warn(
|
|
4149
|
+
"encountered two series with different alignment multiples in draw operations",
|
|
4150
|
+
{ x: n.digest, y: e.digest }
|
|
4151
|
+
), !1;
|
|
4137
4152
|
const s = n.timeRange.overlapsWith(e.timeRange, t), r = C.overlapsWith(n.alignmentBounds, e.alignmentBounds);
|
|
4138
4153
|
return s && r;
|
|
4139
4154
|
};
|
|
4140
|
-
class
|
|
4155
|
+
class Qe {
|
|
4141
4156
|
canvas;
|
|
4142
4157
|
theme;
|
|
4143
4158
|
constructor(e, t) {
|
|
@@ -4224,7 +4239,7 @@ class Je {
|
|
|
4224
4239
|
spacing: s = 1,
|
|
4225
4240
|
level: r = "p"
|
|
4226
4241
|
}) {
|
|
4227
|
-
const i =
|
|
4242
|
+
const i = rt(this.theme, { level: r }), a = e.map((l) => Os(l, i, this.canvas)), o = this.theme.sizes.base * s, c = Math.max(...a.map((l) => l[re.dimension(t)])) + o;
|
|
4228
4243
|
return [
|
|
4229
4244
|
{
|
|
4230
4245
|
[re.dimension(re.swap(t))]: Math.max(
|
|
@@ -4233,7 +4248,7 @@ class Je {
|
|
|
4233
4248
|
[re.dimension(t)]: c * e.length - o
|
|
4234
4249
|
},
|
|
4235
4250
|
(l) => {
|
|
4236
|
-
const u =
|
|
4251
|
+
const u = rt(this.theme, { level: r });
|
|
4237
4252
|
this.canvas.font = u, this.canvas.fillStyle = y.hex(this.theme.colors.text), this.canvas.textBaseline = "top", e.forEach((d, m) => {
|
|
4238
4253
|
this.canvas.fillText(d, l.x, l.y + c * m);
|
|
4239
4254
|
});
|
|
@@ -4257,7 +4272,7 @@ class Je {
|
|
|
4257
4272
|
backgroundColor: (v) => v.colors.gray.l1
|
|
4258
4273
|
});
|
|
4259
4274
|
for (let v = 0; v < e; v++) {
|
|
4260
|
-
const
|
|
4275
|
+
const S = p.construct(
|
|
4261
4276
|
f.construct(
|
|
4262
4277
|
m.x + l.x,
|
|
4263
4278
|
m.y + v * t + l.y + r * v
|
|
@@ -4265,11 +4280,11 @@ class Je {
|
|
|
4265
4280
|
s,
|
|
4266
4281
|
t
|
|
4267
4282
|
);
|
|
4268
|
-
a(v,
|
|
4283
|
+
a(v, S);
|
|
4269
4284
|
}
|
|
4270
4285
|
}
|
|
4271
4286
|
drawTextInCenter({ box: e, text: t, level: s }) {
|
|
4272
|
-
const r =
|
|
4287
|
+
const r = Os(t, this.canvas.font, this.canvas), i = p.positionInCenter(p.construct(f.ZERO, r), e);
|
|
4273
4288
|
return this.text({ text: t, position: p.topLeft(i), level: s });
|
|
4274
4289
|
}
|
|
4275
4290
|
text({
|
|
@@ -4284,27 +4299,27 @@ class Je {
|
|
|
4284
4299
|
align: l = "top",
|
|
4285
4300
|
color: u
|
|
4286
4301
|
}) {
|
|
4287
|
-
this.canvas.font =
|
|
4302
|
+
this.canvas.font = rt(this.theme, { level: s, weight: r, code: o }), u != null ? this.canvas.fillStyle = y.hex(this.resolveColor(u)) : i == null ? this.canvas.fillStyle = y.hex(this.theme.colors.text) : this.canvas.fillStyle = y.hex(this.theme.colors.gray[`l${i}`]), this.canvas.textAlign = c, this.canvas.textBaseline = l;
|
|
4288
4303
|
let d;
|
|
4289
4304
|
a != null && (d = this.canvas.scissor(p.construct(t, a, 1e3))), this.canvas.fillText(e, t.x, t.y), d?.();
|
|
4290
4305
|
}
|
|
4291
4306
|
}
|
|
4292
|
-
const
|
|
4307
|
+
const ji = h.object({
|
|
4293
4308
|
position: h.number().optional(),
|
|
4294
4309
|
pixelPosition: h.number().optional(),
|
|
4295
4310
|
dragging: h.boolean(),
|
|
4296
4311
|
lineWidth: h.number().optional().default(1),
|
|
4297
4312
|
lineDash: h.number().optional().default(20),
|
|
4298
4313
|
color: y.colorZ
|
|
4299
|
-
}),
|
|
4300
|
-
class Qt extends
|
|
4314
|
+
}), Du = 3;
|
|
4315
|
+
class Qt extends q {
|
|
4301
4316
|
static TYPE = "Rule";
|
|
4302
|
-
schema =
|
|
4317
|
+
schema = ji;
|
|
4303
4318
|
lastUpdateRef = null;
|
|
4304
4319
|
afterUpdate(e) {
|
|
4305
4320
|
this.internal.renderCtx = V.use(e);
|
|
4306
4321
|
const t = fe(e);
|
|
4307
|
-
this.internal.draw = new
|
|
4322
|
+
this.internal.draw = new Qe(this.internal.renderCtx.upper2d, t), ge(e, "tool");
|
|
4308
4323
|
}
|
|
4309
4324
|
afterDelete(e) {
|
|
4310
4325
|
ge(e, "tool");
|
|
@@ -4312,7 +4327,7 @@ class Qt extends F {
|
|
|
4312
4327
|
updatePositions({ decimalToDataScale: e, plot: t }) {
|
|
4313
4328
|
const s = this.state.dragging, r = this.prevState.dragging && !s;
|
|
4314
4329
|
if ((s || r) && this.state.pixelPosition != null) {
|
|
4315
|
-
if (this.lastUpdateRef ??= this.state.pixelPosition, Math.abs(this.state.pixelPosition - this.lastUpdateRef) <
|
|
4330
|
+
if (this.lastUpdateRef ??= this.state.pixelPosition, Math.abs(this.state.pixelPosition - this.lastUpdateRef) < Du && !r)
|
|
4316
4331
|
return this.state.pixelPosition;
|
|
4317
4332
|
this.lastUpdateRef = this.state.pixelPosition;
|
|
4318
4333
|
const o = e.pos(this.state.pixelPosition / p.height(t));
|
|
@@ -4349,17 +4364,17 @@ class Qt extends F {
|
|
|
4349
4364
|
a.closePath(), a.stroke();
|
|
4350
4365
|
}
|
|
4351
4366
|
}
|
|
4352
|
-
const
|
|
4367
|
+
const Lu = {
|
|
4353
4368
|
[Qt.TYPE]: Qt
|
|
4354
|
-
},
|
|
4369
|
+
}, qh = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
4355
4370
|
__proto__: null,
|
|
4356
|
-
REGISTRY:
|
|
4371
|
+
REGISTRY: Lu,
|
|
4357
4372
|
Rule: Qt,
|
|
4358
|
-
ruleStateZ:
|
|
4359
|
-
}, Symbol.toStringTag, { value: "Module" })),
|
|
4373
|
+
ruleStateZ: ji
|
|
4374
|
+
}, Symbol.toStringTag, { value: "Module" })), Fh = gn.extend({
|
|
4360
4375
|
location: se.x.optional().default("left")
|
|
4361
|
-
}),
|
|
4362
|
-
class
|
|
4376
|
+
}), ur = 2, _u = (n) => p.signedWidth(n) < ur || p.signedHeight(n) < ur;
|
|
4377
|
+
class jn extends Hi {
|
|
4363
4378
|
static TYPE = "YAxis";
|
|
4364
4379
|
schema = gn;
|
|
4365
4380
|
xBounds() {
|
|
@@ -4382,7 +4397,7 @@ class Hn extends ji {
|
|
|
4382
4397
|
if (this.renderAxis(e, r), this.renderLines(e, t), this.renderRules(e, r), s != null) throw s;
|
|
4383
4398
|
}
|
|
4384
4399
|
renderLines({ xDataToDecimalScale: e, plot: t, canvases: s, exposure: r }, i) {
|
|
4385
|
-
if (!s.includes("gl") ||
|
|
4400
|
+
if (!s.includes("gl") || _u(t)) return;
|
|
4386
4401
|
const a = {
|
|
4387
4402
|
region: t,
|
|
4388
4403
|
dataToDecimalScale: new Q.XY(e, i),
|
|
@@ -4423,23 +4438,23 @@ class Hn extends ji {
|
|
|
4423
4438
|
return this.lines.map((e) => e.yBounds());
|
|
4424
4439
|
}
|
|
4425
4440
|
get lines() {
|
|
4426
|
-
return this.childrenOfType(
|
|
4441
|
+
return this.childrenOfType(Hn.TYPE);
|
|
4427
4442
|
}
|
|
4428
4443
|
get rules() {
|
|
4429
4444
|
return this.childrenOfType(Qt.TYPE);
|
|
4430
4445
|
}
|
|
4431
4446
|
}
|
|
4432
|
-
const Yu = h.object({ start:
|
|
4433
|
-
class
|
|
4447
|
+
const Yu = h.object({ start: A.z, end: A.z });
|
|
4448
|
+
class hr extends q {
|
|
4434
4449
|
static TYPE = "range-annotation";
|
|
4435
4450
|
schema = Yu;
|
|
4436
4451
|
afterUpdate(e) {
|
|
4437
|
-
this.internal.render = V.use(e), this.internal.draw = new
|
|
4452
|
+
this.internal.render = V.use(e), this.internal.draw = new Qe(this.internal.render.upper2d, fe(e));
|
|
4438
4453
|
}
|
|
4439
4454
|
}
|
|
4440
|
-
const
|
|
4441
|
-
channel:
|
|
4442
|
-
schema:
|
|
4455
|
+
const Hh = "ranges", Au = {
|
|
4456
|
+
channel: it.SET_CHANNEL_NAME,
|
|
4457
|
+
schema: it.payloadZ,
|
|
4443
4458
|
onChange: async ({ store: n, changed: e, client: t }) => {
|
|
4444
4459
|
const s = t.ranges.sugarOne(e), r = n.ranges.get(e.key);
|
|
4445
4460
|
let i;
|
|
@@ -4455,29 +4470,33 @@ const jh = "ranges", Au = {
|
|
|
4455
4470
|
);
|
|
4456
4471
|
}
|
|
4457
4472
|
}, Nu = {
|
|
4458
|
-
channel:
|
|
4459
|
-
schema:
|
|
4473
|
+
channel: it.DELETE_CHANNEL_NAME,
|
|
4474
|
+
schema: it.keyZ,
|
|
4460
4475
|
onChange: ({ store: n, changed: e }) => n.ranges.delete(e)
|
|
4461
|
-
},
|
|
4476
|
+
}, jh = {
|
|
4462
4477
|
equal: (n, e) => rn.equal(n.payload, e.payload),
|
|
4463
4478
|
listeners: [Au, Nu]
|
|
4464
4479
|
}, Iu = h.object({
|
|
4465
4480
|
region: p.box,
|
|
4466
4481
|
clearOverScan: f.crudeZ.optional().default(0),
|
|
4467
|
-
visible: h.boolean().optional().default(!0)
|
|
4468
|
-
|
|
4469
|
-
|
|
4482
|
+
visible: h.boolean().optional().default(!0),
|
|
4483
|
+
autoRenderInterval: h.number().optional().default(1e3)
|
|
4484
|
+
}), dr = ["upper2d", "lower2d"];
|
|
4485
|
+
class dt extends ae {
|
|
4470
4486
|
static TYPE = "Table";
|
|
4471
4487
|
static stateZ = Iu;
|
|
4472
|
-
schema =
|
|
4488
|
+
schema = dt.stateZ;
|
|
4473
4489
|
afterUpdate(e) {
|
|
4474
4490
|
const { internal: t } = this;
|
|
4475
|
-
t.renderCtx = V.use(e), t.handleError = ue(e),
|
|
4491
|
+
t.renderCtx = V.use(e), t.handleError = ue(e), t.autoRenderInterval ??= setInterval(
|
|
4492
|
+
() => this.state.visible && this.requestRender("low"),
|
|
4493
|
+
this.state.autoRenderInterval
|
|
4494
|
+
), is(e, () => {
|
|
4476
4495
|
this.state.visible && this.requestRender("low");
|
|
4477
4496
|
}), !(!this.state.visible && !this.prevState.visible) && this.requestRender("high");
|
|
4478
4497
|
}
|
|
4479
4498
|
afterDelete() {
|
|
4480
|
-
this.requestRender("high");
|
|
4499
|
+
this.internal.autoRenderInterval != null && clearInterval(this.internal.autoRenderInterval), this.requestRender("high");
|
|
4481
4500
|
}
|
|
4482
4501
|
render() {
|
|
4483
4502
|
if (this.deleted) return;
|
|
@@ -4487,7 +4506,7 @@ class ft extends ae {
|
|
|
4487
4506
|
const { renderCtx: t, handleError: s } = this.internal, r = Q.XY.translate(p.topLeft(this.state.region)), i = t.scissor(
|
|
4488
4507
|
this.state.region,
|
|
4489
4508
|
f.construct(this.state.clearOverScan),
|
|
4490
|
-
|
|
4509
|
+
dr
|
|
4491
4510
|
);
|
|
4492
4511
|
try {
|
|
4493
4512
|
for (const a of this.children) a.render({ viewportScale: r });
|
|
@@ -4501,30 +4520,30 @@ class ft extends ae {
|
|
|
4501
4520
|
requestRender(e) {
|
|
4502
4521
|
const { renderCtx: t } = this.internal;
|
|
4503
4522
|
t.loop.set({
|
|
4504
|
-
key: `${
|
|
4523
|
+
key: `${dt.TYPE}-${this.key}`,
|
|
4505
4524
|
render: this.render.bind(this),
|
|
4506
4525
|
priority: e,
|
|
4507
|
-
canvases:
|
|
4526
|
+
canvases: dr
|
|
4508
4527
|
});
|
|
4509
4528
|
}
|
|
4510
4529
|
}
|
|
4511
4530
|
const zh = {
|
|
4512
|
-
[
|
|
4531
|
+
[dt.TYPE]: dt
|
|
4513
4532
|
}, Bu = h.object({
|
|
4514
4533
|
authority: sn.authorityZ.optional(),
|
|
4515
4534
|
valid: h.boolean().optional()
|
|
4516
4535
|
}).default({ authority: void 0, valid: !1 }), Zu = h.object({
|
|
4517
4536
|
triggered: h.boolean(),
|
|
4518
|
-
status:
|
|
4537
|
+
status: Ve.statusZ(Bu),
|
|
4519
4538
|
sink: hn.optional().default(ln),
|
|
4520
|
-
source:
|
|
4539
|
+
source: hs.optional().default(ls)
|
|
4521
4540
|
});
|
|
4522
|
-
class
|
|
4541
|
+
class fr extends q {
|
|
4523
4542
|
static TYPE = "Chip";
|
|
4524
4543
|
schema = Zu;
|
|
4525
4544
|
afterUpdate(e) {
|
|
4526
4545
|
const { internal: t } = this, { sink: s, source: r } = this.state;
|
|
4527
|
-
t.source = ee(e, r, t.source), t.sink =
|
|
4546
|
+
t.source = ee(e, r, t.source), t.sink = vt(e, s, t.sink), this.state.triggered && !this.prevState.triggered && t.sink.set(this.state.status.details?.authority !== sn.ABSOLUTE_AUTHORITY), this.updateEnabledState(), t.stopListening?.(), t.stopListening = t.source.onChange(() => this.updateEnabledState());
|
|
4528
4547
|
}
|
|
4529
4548
|
updateEnabledState() {
|
|
4530
4549
|
const e = this.internal.source.value();
|
|
@@ -4536,7 +4555,7 @@ class dr extends F {
|
|
|
4536
4555
|
render() {
|
|
4537
4556
|
}
|
|
4538
4557
|
}
|
|
4539
|
-
const Uu = h.object({}),
|
|
4558
|
+
const Uu = h.object({}), pr = "control-state-provider", $u = ts.stateZ.extend({
|
|
4540
4559
|
subjectColor: y.colorZ
|
|
4541
4560
|
});
|
|
4542
4561
|
class Jt extends ae {
|
|
@@ -4549,7 +4568,7 @@ class Jt extends ae {
|
|
|
4549
4568
|
/** Stop listening for changes to the tracker */
|
|
4550
4569
|
disconnectTrackerChange;
|
|
4551
4570
|
/** An observer that lets external subscribers know when the control state changes */
|
|
4552
|
-
obs = new
|
|
4571
|
+
obs = new ss.Observer();
|
|
4553
4572
|
/**
|
|
4554
4573
|
* Grabs the state provider from the current aether context.
|
|
4555
4574
|
*
|
|
@@ -4557,16 +4576,16 @@ class Jt extends ae {
|
|
|
4557
4576
|
* @throws {Error} if the state provider is not in the context.
|
|
4558
4577
|
*/
|
|
4559
4578
|
static use(e) {
|
|
4560
|
-
return e.get(
|
|
4579
|
+
return e.get(pr);
|
|
4561
4580
|
}
|
|
4562
4581
|
afterUpdate(e) {
|
|
4563
4582
|
const { internal: t } = this;
|
|
4564
|
-
t.instrumentation =
|
|
4583
|
+
t.instrumentation = mt(e, "control-state");
|
|
4565
4584
|
const s = fe(e);
|
|
4566
4585
|
t.palette = s.colors.visualization.palettes.default, t.defaultColor = s.colors.gray.l8;
|
|
4567
|
-
const r =
|
|
4586
|
+
const r = Ge(e);
|
|
4568
4587
|
if (t.client != null && r === t.client) return;
|
|
4569
|
-
t.client = r, e.set(
|
|
4588
|
+
t.client = r, e.set(pr, this), ue(e)(async () => {
|
|
4570
4589
|
await this.maybeCloseTracker(), t.client != null && (this.internal.instrumentation.L.debug("starting state tracker"), await this.openTracker(t.client));
|
|
4571
4590
|
}, "failed to open control state tracker");
|
|
4572
4591
|
}
|
|
@@ -4602,7 +4621,7 @@ class Jt extends ae {
|
|
|
4602
4621
|
return;
|
|
4603
4622
|
}
|
|
4604
4623
|
this.disconnectTrackerChange?.(), this.disconnectTrackerChange = this.tracker.onChange((r) => {
|
|
4605
|
-
if (s.L.debug("transfer", { transfers: r.map((i) =>
|
|
4624
|
+
if (s.L.debug("transfer", { transfers: r.map((i) => ts.transferString(i)) }), this.tracker == null)
|
|
4606
4625
|
throw new Ee("tracker is null inside it's own onChange callback!");
|
|
4607
4626
|
this.updateColors(this.tracker), this.obs.notify(r);
|
|
4608
4627
|
});
|
|
@@ -4618,22 +4637,22 @@ class Jt extends ae {
|
|
|
4618
4637
|
});
|
|
4619
4638
|
}
|
|
4620
4639
|
}
|
|
4621
|
-
const
|
|
4640
|
+
const qu = ["acquired", "released", "overridden", "failed"], Fu = h.enum(qu), Hu = h.object({
|
|
4622
4641
|
name: h.string(),
|
|
4623
4642
|
authority: h.number().default(0),
|
|
4624
4643
|
acquireTrigger: h.number(),
|
|
4625
|
-
status:
|
|
4626
|
-
needsControlOf:
|
|
4644
|
+
status: Fu.optional(),
|
|
4645
|
+
needsControlOf: Ot.keyZ.array().optional().default([])
|
|
4627
4646
|
});
|
|
4628
|
-
class
|
|
4647
|
+
class mr extends ae {
|
|
4629
4648
|
static TYPE = "Controller";
|
|
4630
|
-
schema =
|
|
4649
|
+
schema = Hu;
|
|
4631
4650
|
registry = /* @__PURE__ */ new Map();
|
|
4632
4651
|
writer;
|
|
4633
4652
|
afterUpdate(e) {
|
|
4634
4653
|
const { internal: t } = this;
|
|
4635
|
-
t.instrumentation =
|
|
4636
|
-
const s =
|
|
4654
|
+
t.instrumentation = mt(e), t.addStatus = Or(e), t.runAsync = ue(e), (t.prevTrigger == null || Math.abs(this.state.acquireTrigger - t.prevTrigger) > 1) && (t.prevTrigger = this.state.acquireTrigger);
|
|
4655
|
+
const s = Ge(e), r = Jt.use(e);
|
|
4637
4656
|
t.stateProv = r, t.telemCtx = fi(e, this, t.telemCtx), t.client = s, t.runAsync(async () => {
|
|
4638
4657
|
t.client == null && await this.release(), this.state.acquireTrigger > t.prevTrigger ? await this.acquire() : this.state.acquireTrigger < t.prevTrigger && await this.release();
|
|
4639
4658
|
}, "failed to acquire control");
|
|
@@ -4667,7 +4686,7 @@ class pr extends ae {
|
|
|
4667
4686
|
message: `Cannot acquire control on ${this.state.name} because there are no channels to control.`,
|
|
4668
4687
|
variant: "warning"
|
|
4669
4688
|
});
|
|
4670
|
-
const r =
|
|
4689
|
+
const r = ns.now().sub(T.milliseconds(1));
|
|
4671
4690
|
this.writer = await e.openWriter({
|
|
4672
4691
|
start: r,
|
|
4673
4692
|
channels: s,
|
|
@@ -4734,14 +4753,14 @@ class pr extends ae {
|
|
|
4734
4753
|
return r != null && this.updateNeedsControlOf(), r;
|
|
4735
4754
|
}
|
|
4736
4755
|
}
|
|
4737
|
-
const
|
|
4756
|
+
const ju = h.object({
|
|
4738
4757
|
channel: h.number()
|
|
4739
4758
|
});
|
|
4740
4759
|
class zn extends fn {
|
|
4741
4760
|
static TYPE = "controlled-numeric-telem-sink";
|
|
4742
4761
|
controller;
|
|
4743
4762
|
runAsync;
|
|
4744
|
-
schema =
|
|
4763
|
+
schema = ju;
|
|
4745
4764
|
constructor(e, t, s) {
|
|
4746
4765
|
super(s), this.controller = e, this.runAsync = t;
|
|
4747
4766
|
}
|
|
@@ -4760,13 +4779,13 @@ class zn extends fn {
|
|
|
4760
4779
|
const { client: t } = this.controller.internal;
|
|
4761
4780
|
if (t == null) throw new ba("No cluster connected");
|
|
4762
4781
|
if (this.props.channel === 0)
|
|
4763
|
-
throw new
|
|
4782
|
+
throw new Xe("No command channel specified for actuator");
|
|
4764
4783
|
const s = await t.channels.retrieve(this.props.channel), r = { [s.key]: e };
|
|
4765
4784
|
if (s.index !== 0) {
|
|
4766
|
-
const i = await t.channels.retrieve(s.index), a =
|
|
4785
|
+
const i = await t.channels.retrieve(s.index), a = ns.now();
|
|
4767
4786
|
r[i.key] = Array.from(
|
|
4768
4787
|
{ length: e.length },
|
|
4769
|
-
(o, c) => a.add(
|
|
4788
|
+
(o, c) => a.add(T.nanoseconds(c))
|
|
4770
4789
|
);
|
|
4771
4790
|
}
|
|
4772
4791
|
await this.controller.set(r);
|
|
@@ -4779,7 +4798,7 @@ const Wh = (n) => ({
|
|
|
4779
4798
|
variant: "sink",
|
|
4780
4799
|
valueType: "number"
|
|
4781
4800
|
}), zu = h.object({
|
|
4782
|
-
authority: h.number().default(
|
|
4801
|
+
authority: h.number().default(ts.ABSOLUTE_AUTHORITY),
|
|
4783
4802
|
channel: h.number()
|
|
4784
4803
|
});
|
|
4785
4804
|
class Wn extends fn {
|
|
@@ -4842,7 +4861,7 @@ class Vn extends X {
|
|
|
4842
4861
|
}
|
|
4843
4862
|
value() {
|
|
4844
4863
|
this.maybeRevalidate();
|
|
4845
|
-
const e =
|
|
4864
|
+
const e = ns.now();
|
|
4846
4865
|
if (this.props.channel === 0)
|
|
4847
4866
|
return {
|
|
4848
4867
|
key: this.controller.key,
|
|
@@ -4876,12 +4895,12 @@ const Gh = (n) => ({
|
|
|
4876
4895
|
variant: "source",
|
|
4877
4896
|
valueType: "status"
|
|
4878
4897
|
}), Vu = h.object({ color: y.colorZ.optional() }).default({ color: void 0 }), Xu = h.object({
|
|
4879
|
-
statusSource:
|
|
4880
|
-
colorSource:
|
|
4881
|
-
status:
|
|
4898
|
+
statusSource: hs.optional().default(ls),
|
|
4899
|
+
colorSource: us.optional().default(cn),
|
|
4900
|
+
status: Ve.statusZ(Vu),
|
|
4882
4901
|
color: y.colorZ.optional()
|
|
4883
4902
|
});
|
|
4884
|
-
class
|
|
4903
|
+
class gr extends q {
|
|
4885
4904
|
static TYPE = "Indicator";
|
|
4886
4905
|
schema = Xu;
|
|
4887
4906
|
stopListeningStatus;
|
|
@@ -4901,10 +4920,10 @@ class mr extends F {
|
|
|
4901
4920
|
}
|
|
4902
4921
|
}
|
|
4903
4922
|
const Gu = h.object({
|
|
4904
|
-
needsControlOf:
|
|
4923
|
+
needsControlOf: Ot.keyZ.array(),
|
|
4905
4924
|
states: $u.array()
|
|
4906
4925
|
});
|
|
4907
|
-
class
|
|
4926
|
+
class yr extends q {
|
|
4908
4927
|
static TYPE = "Legend";
|
|
4909
4928
|
schema = Gu;
|
|
4910
4929
|
afterUpdate(e) {
|
|
@@ -4927,22 +4946,22 @@ class gr extends F {
|
|
|
4927
4946
|
}
|
|
4928
4947
|
}
|
|
4929
4948
|
const Kh = {
|
|
4930
|
-
[pr.TYPE]: pr,
|
|
4931
|
-
[Jt.TYPE]: Jt,
|
|
4932
4949
|
[mr.TYPE]: mr,
|
|
4933
|
-
[
|
|
4934
|
-
[gr.TYPE]: gr
|
|
4950
|
+
[Jt.TYPE]: Jt,
|
|
4951
|
+
[gr.TYPE]: gr,
|
|
4952
|
+
[fr.TYPE]: fr,
|
|
4953
|
+
[yr.TYPE]: yr
|
|
4935
4954
|
}, Ku = ["fire", "momentary", "pulse"], Qu = h.enum(Ku), Ju = h.object({
|
|
4936
4955
|
trigger: h.number(),
|
|
4937
4956
|
sink: hn.optional().default(ln),
|
|
4938
4957
|
mode: Qu.optional().default("fire")
|
|
4939
4958
|
}), eh = 2, th = 1;
|
|
4940
|
-
class
|
|
4959
|
+
class vr extends q {
|
|
4941
4960
|
static TYPE = "Button";
|
|
4942
4961
|
schema = Ju;
|
|
4943
4962
|
afterUpdate(e) {
|
|
4944
4963
|
const { sink: t, mode: s, trigger: r } = this.state, { internal: i } = this;
|
|
4945
|
-
i.prevTrigger ??= r, i.sink =
|
|
4964
|
+
i.prevTrigger ??= r, i.sink = vt(e, t, i.sink);
|
|
4946
4965
|
const a = i.prevTrigger;
|
|
4947
4966
|
i.prevTrigger = r;
|
|
4948
4967
|
const o = r === a + eh;
|
|
@@ -4952,7 +4971,7 @@ class yr extends F {
|
|
|
4952
4971
|
this.internal.sink.cleanup?.();
|
|
4953
4972
|
}
|
|
4954
4973
|
}
|
|
4955
|
-
const Qh = { [
|
|
4974
|
+
const Qh = { [vr.TYPE]: vr }, zi = h.object({
|
|
4956
4975
|
dpr: h.number(),
|
|
4957
4976
|
region: p.box,
|
|
4958
4977
|
bootstrap: h.boolean().optional().default(!1),
|
|
@@ -4982,7 +5001,7 @@ class Xn extends ae {
|
|
|
4982
5001
|
s,
|
|
4983
5002
|
r,
|
|
4984
5003
|
i
|
|
4985
|
-
),
|
|
5004
|
+
), Ne.create(e, this.renderCtx), this.setState((a) => ({
|
|
4986
5005
|
...a,
|
|
4987
5006
|
bootstrap: !1,
|
|
4988
5007
|
bootstrapped: !0,
|
|
@@ -5006,19 +5025,22 @@ const nh = {
|
|
|
5006
5025
|
zoom: h.number(),
|
|
5007
5026
|
region: p.box,
|
|
5008
5027
|
clearOverScan: f.crudeZ.optional().default(10),
|
|
5009
|
-
visible: h.boolean().optional().default(!0)
|
|
5028
|
+
visible: h.boolean().optional().default(!0),
|
|
5029
|
+
autoRenderInterval: h.number().optional()
|
|
5010
5030
|
}), Pt = ["upper2d", "lower2d"];
|
|
5011
|
-
class
|
|
5031
|
+
class We extends ae {
|
|
5012
5032
|
static TYPE = "Diagram";
|
|
5013
5033
|
static stateZ = Wi;
|
|
5014
|
-
schema =
|
|
5034
|
+
schema = We.stateZ;
|
|
5015
5035
|
afterUpdate(e) {
|
|
5016
|
-
this.internal.renderCtx = V.use(e), this.internal.handleError = ue(e),
|
|
5036
|
+
this.internal.renderCtx = V.use(e), this.internal.handleError = ue(e), this.internal.autoRenderInterval ??= setInterval(() => {
|
|
5037
|
+
this.state.visible && this.requestRender("low");
|
|
5038
|
+
}, this.state.autoRenderInterval), is(e, () => {
|
|
5017
5039
|
this.state.visible && this.requestRender("low");
|
|
5018
5040
|
}), !(!this.state.visible && !this.prevState.visible) && (this.internal.viewportScale = Q.XY.magnify(f.construct(this.state.zoom)).translate(p.topLeft(this.state.region)).translate(this.state.position), this.requestRender("high"));
|
|
5019
5041
|
}
|
|
5020
5042
|
afterDelete() {
|
|
5021
|
-
this.requestRender("high");
|
|
5043
|
+
this.internal.autoRenderInterval != null && clearInterval(this.internal.autoRenderInterval), this.requestRender("high");
|
|
5022
5044
|
}
|
|
5023
5045
|
render() {
|
|
5024
5046
|
if (this.deleted) return;
|
|
@@ -5045,7 +5067,7 @@ class Ve extends ae {
|
|
|
5045
5067
|
requestRender(e) {
|
|
5046
5068
|
const { renderCtx: t } = this.internal;
|
|
5047
5069
|
t.loop.set({
|
|
5048
|
-
key: `${
|
|
5070
|
+
key: `${We.TYPE}-${this.key}`,
|
|
5049
5071
|
render: this.render.bind(this),
|
|
5050
5072
|
priority: e,
|
|
5051
5073
|
canvases: Pt
|
|
@@ -5053,17 +5075,17 @@ class Ve extends ae {
|
|
|
5053
5075
|
}
|
|
5054
5076
|
}
|
|
5055
5077
|
const sh = {
|
|
5056
|
-
[
|
|
5078
|
+
[We.TYPE]: We
|
|
5057
5079
|
}, ed = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
5058
5080
|
__proto__: null,
|
|
5059
|
-
Diagram:
|
|
5081
|
+
Diagram: We,
|
|
5060
5082
|
REGISTRY: sh,
|
|
5061
5083
|
diagramStateZ: Wi
|
|
5062
5084
|
}, Symbol.toStringTag, { value: "Module" })), rh = h.object({
|
|
5063
5085
|
enabled: h.boolean(),
|
|
5064
|
-
source:
|
|
5086
|
+
source: cs.optional().default(os)
|
|
5065
5087
|
});
|
|
5066
|
-
class
|
|
5088
|
+
class br extends q {
|
|
5067
5089
|
static TYPE = "Light";
|
|
5068
5090
|
schema = rh;
|
|
5069
5091
|
afterUpdate(e) {
|
|
@@ -5075,10 +5097,10 @@ class vr extends F {
|
|
|
5075
5097
|
e !== this.state.enabled && this.setState((t) => ({ ...t, enabled: e }));
|
|
5076
5098
|
}
|
|
5077
5099
|
afterDelete() {
|
|
5078
|
-
this.internal.stopListening(), this.internal.source.cleanup?.();
|
|
5100
|
+
this.internal.stopListening?.(), this.internal.source.cleanup?.();
|
|
5079
5101
|
}
|
|
5080
5102
|
}
|
|
5081
|
-
const td = { [
|
|
5103
|
+
const td = { [br.TYPE]: br }, ih = f.construct(12), ah = 3, oh = 14, lh = f.construct(6), Vi = h.object({
|
|
5082
5104
|
position: f.xy.or(h.null()),
|
|
5083
5105
|
textColor: y.colorZ.optional().default(y.ZERO),
|
|
5084
5106
|
backgroundColor: y.colorZ.optional().default(y.ZERO),
|
|
@@ -5087,19 +5109,19 @@ const td = { [vr.TYPE]: vr }, ih = f.construct(12), ah = 3, oh = 14, lh = f.cons
|
|
|
5087
5109
|
ruleStrokeWidth: h.number().optional().default(1),
|
|
5088
5110
|
ruleStrokeDash: h.number().default(0)
|
|
5089
5111
|
});
|
|
5090
|
-
class en extends
|
|
5112
|
+
class en extends q {
|
|
5091
5113
|
static TYPE = "tooltip";
|
|
5092
5114
|
schema = Vi;
|
|
5093
5115
|
afterUpdate(e) {
|
|
5094
5116
|
const t = fe(e);
|
|
5095
|
-
y.isZero(this.state.textColor) && (this.state.textColor = t.colors.text), y.isZero(this.state.backgroundColor) && (this.state.backgroundColor = t.colors.gray.l1), y.isZero(this.state.borderColor) && (this.state.borderColor = t.colors.border), y.isZero(this.state.ruleColor) && (this.state.ruleColor = t.colors.gray.l7), this.internal.dotColor = t.colors.text, this.internal.dotColorContrast = t.colors.textInverted, this.internal.render = V.use(e), this.internal.draw = new
|
|
5117
|
+
y.isZero(this.state.textColor) && (this.state.textColor = t.colors.text), y.isZero(this.state.backgroundColor) && (this.state.backgroundColor = t.colors.gray.l1), y.isZero(this.state.borderColor) && (this.state.borderColor = t.colors.border), y.isZero(this.state.ruleColor) && (this.state.ruleColor = t.colors.gray.l7), this.internal.dotColor = t.colors.text, this.internal.dotColorContrast = t.colors.textInverted, this.internal.render = V.use(e), this.internal.draw = new Qe(this.internal.render.upper2d, t), ge(e, "tool");
|
|
5096
5118
|
}
|
|
5097
5119
|
afterDelete(e) {
|
|
5098
5120
|
ge(e, "tool");
|
|
5099
5121
|
}
|
|
5100
5122
|
render(e) {
|
|
5101
5123
|
if (this.deleted || this.state.position == null) return;
|
|
5102
|
-
const { region: t } = e, s = Q.XY.scale(p.DECIMAL).scale(t), r = Q.XY.scale(t).scale(p.DECIMAL), i = e.findByXDecimal(r.x.pos(this.state.position.x)), a = i.filter((w) => f.isFinite(w.value)), { draw: o } = this.internal, c = a.reduce((w, x) => w + x.position.x, 0) / a.length, l = new
|
|
5124
|
+
const { region: t } = e, s = Q.XY.scale(p.DECIMAL).scale(t), r = Q.XY.scale(t).scale(p.DECIMAL), i = e.findByXDecimal(r.x.pos(this.state.position.x)), a = i.filter((w) => f.isFinite(w.value)), { draw: o } = this.internal, c = a.reduce((w, x) => w + x.position.x, 0) / a.length, l = new A(
|
|
5103
5125
|
a.reduce((w, x) => w + x.value.x, 0) / a.length
|
|
5104
5126
|
), u = s.x.pos(c);
|
|
5105
5127
|
if (!C.contains(p.xBounds(t), u)) return;
|
|
@@ -5125,8 +5147,8 @@ class en extends F {
|
|
|
5125
5147
|
const d = r.pos(this.state.position), m = { ...se.TOP_LEFT };
|
|
5126
5148
|
d.x > 0.6 && (m.x = "right"), d.y > 0.6 && (m.y = "bottom");
|
|
5127
5149
|
let v = i.reduce((w, x) => Math.max(w, x.label?.length ?? 0), 0);
|
|
5128
|
-
const
|
|
5129
|
-
|
|
5150
|
+
const S = l.fString("preciseDate", "local").length;
|
|
5151
|
+
S > v && (v = S), o.list({
|
|
5130
5152
|
root: m,
|
|
5131
5153
|
offset: ih,
|
|
5132
5154
|
length: a.length + 1,
|
|
@@ -5136,12 +5158,12 @@ class en extends F {
|
|
|
5136
5158
|
width: v * 7 + 48,
|
|
5137
5159
|
position: this.state.position,
|
|
5138
5160
|
draw: (w, x) => {
|
|
5139
|
-
let R = "",
|
|
5161
|
+
let R = "", L = "", M = this.state.textColor;
|
|
5140
5162
|
if (w === 0)
|
|
5141
|
-
R = "Time",
|
|
5163
|
+
R = "Time", L = l.fString("preciseDate", "local");
|
|
5142
5164
|
else {
|
|
5143
5165
|
const Y = a[w - 1];
|
|
5144
|
-
R = Y.label ?? "",
|
|
5166
|
+
R = Y.label ?? "", L = es.roundBySpan(Y.value.y, Y.bounds).toString(), M = Y.color;
|
|
5145
5167
|
}
|
|
5146
5168
|
o.text({
|
|
5147
5169
|
position: p.topLeft(x),
|
|
@@ -5151,7 +5173,7 @@ class en extends F {
|
|
|
5151
5173
|
color: M
|
|
5152
5174
|
}), o.text({
|
|
5153
5175
|
position: f.translateY(p.topRight(x), -1),
|
|
5154
|
-
text:
|
|
5176
|
+
text: L,
|
|
5155
5177
|
level: "small",
|
|
5156
5178
|
justify: "right",
|
|
5157
5179
|
code: !0,
|
|
@@ -5174,16 +5196,16 @@ const ch = {
|
|
|
5174
5196
|
scrolling: h.boolean(),
|
|
5175
5197
|
empty: h.boolean(),
|
|
5176
5198
|
visible: h.boolean(),
|
|
5177
|
-
telem:
|
|
5178
|
-
font:
|
|
5199
|
+
telem: Lt.optional().default(Ar),
|
|
5200
|
+
font: Dr.optional().default("p"),
|
|
5179
5201
|
color: y.colorZ.optional().default(y.ZERO),
|
|
5180
5202
|
overshoot: f.xy.optional().default({ x: 0, y: 0 })
|
|
5181
|
-
}), hh = 0.98,
|
|
5203
|
+
}), hh = 0.98, st = "lower2d", dh = {
|
|
5182
5204
|
offset: 0n,
|
|
5183
5205
|
offsetRef: 0n,
|
|
5184
5206
|
scrollRef: 0
|
|
5185
5207
|
};
|
|
5186
|
-
class tn extends
|
|
5208
|
+
class tn extends q {
|
|
5187
5209
|
static TYPE = "log";
|
|
5188
5210
|
static z = uh;
|
|
5189
5211
|
schema = tn.z;
|
|
@@ -5219,7 +5241,7 @@ class tn extends F {
|
|
|
5219
5241
|
}
|
|
5220
5242
|
afterDelete() {
|
|
5221
5243
|
const { telem: e, render: t } = this.internal;
|
|
5222
|
-
e.cleanup?.(), t.erase(p.construct(this.state.region), f.ZERO,
|
|
5244
|
+
e.cleanup?.(), t.erase(p.construct(this.state.region), f.ZERO, st);
|
|
5223
5245
|
}
|
|
5224
5246
|
requestRender() {
|
|
5225
5247
|
const { render: e } = this.internal;
|
|
@@ -5227,7 +5249,7 @@ class tn extends F {
|
|
|
5227
5249
|
key: `${this.type}-${this.key}`,
|
|
5228
5250
|
render: () => this.render(),
|
|
5229
5251
|
priority: "high",
|
|
5230
|
-
canvases: [
|
|
5252
|
+
canvases: [st]
|
|
5231
5253
|
});
|
|
5232
5254
|
}
|
|
5233
5255
|
get lineHeight() {
|
|
@@ -5245,7 +5267,7 @@ class tn extends F {
|
|
|
5245
5267
|
render() {
|
|
5246
5268
|
const { render: e } = this.internal, t = this.state.region;
|
|
5247
5269
|
if (p.areaIsZero(t)) return;
|
|
5248
|
-
if (!this.state.visible) return () => e.erase(t, f.ZERO,
|
|
5270
|
+
if (!this.state.visible) return () => e.erase(t, f.ZERO, st);
|
|
5249
5271
|
let s;
|
|
5250
5272
|
if (!this.state.scrolling)
|
|
5251
5273
|
s = this.values.subIterator(
|
|
@@ -5259,7 +5281,7 @@ class tn extends F {
|
|
|
5259
5281
|
);
|
|
5260
5282
|
s = this.values.subAlignmentSpanIterator(l, this.visibleLineCount);
|
|
5261
5283
|
}
|
|
5262
|
-
const r = this.state.region, i = e[
|
|
5284
|
+
const r = this.state.region, i = e[st], a = new Qe(i, this.internal.theme), o = e.scissor(r, f.ZERO, [st]);
|
|
5263
5285
|
this.renderElements(a, s), this.renderScrollbar(a), o();
|
|
5264
5286
|
const c = p.copy(this.state.region);
|
|
5265
5287
|
return ({ canvases: l }) => e.erase(c, this.state.overshoot, ...l);
|
|
@@ -5312,12 +5334,12 @@ const sd = { [tn.TYPE]: tn }, Xi = h.object({
|
|
|
5312
5334
|
strokeWidth: h.number().optional().default(1),
|
|
5313
5335
|
strokeDash: h.number().optional().default(2)
|
|
5314
5336
|
});
|
|
5315
|
-
class nn extends
|
|
5337
|
+
class nn extends q {
|
|
5316
5338
|
static TYPE = "measure";
|
|
5317
5339
|
schema = Xi;
|
|
5318
5340
|
afterUpdate(e) {
|
|
5319
5341
|
const t = V.use(e);
|
|
5320
|
-
this.internal.theme = fe(e), this.internal.renderCtx = t, this.internal.draw = new
|
|
5342
|
+
this.internal.theme = fe(e), this.internal.renderCtx = t, this.internal.draw = new Qe(t.upper2d, this.internal.theme), ge(e, "tool");
|
|
5321
5343
|
}
|
|
5322
5344
|
afterDelete(e) {
|
|
5323
5345
|
ge(e, "layout");
|
|
@@ -5339,10 +5361,10 @@ class nn extends F {
|
|
|
5339
5361
|
const [w, x] = [e.findByXValue(a.x), e.findByXValue(o.x)];
|
|
5340
5362
|
return w.length === 0 || x.length === 0 ? null : [
|
|
5341
5363
|
w.sort(
|
|
5342
|
-
(R,
|
|
5364
|
+
(R, L) => f.distance(a, R.value) - f.distance(a, L.value)
|
|
5343
5365
|
)[0],
|
|
5344
5366
|
x.sort(
|
|
5345
|
-
(R,
|
|
5367
|
+
(R, L) => f.distance(o, R.value) - f.distance(o, L.value)
|
|
5346
5368
|
)[0]
|
|
5347
5369
|
];
|
|
5348
5370
|
}
|
|
@@ -5351,7 +5373,7 @@ class nn extends F {
|
|
|
5351
5373
|
e.findByXDecimal(u.x)
|
|
5352
5374
|
];
|
|
5353
5375
|
if (d.length === 0 || m.length === 0) return null;
|
|
5354
|
-
const [v,
|
|
5376
|
+
const [v, S] = [
|
|
5355
5377
|
d.sort(
|
|
5356
5378
|
(w, x) => f.distance(l, w.position) - f.distance(l, x.position)
|
|
5357
5379
|
)[0],
|
|
@@ -5359,7 +5381,7 @@ class nn extends F {
|
|
|
5359
5381
|
(w, x) => f.distance(u, w.position) - f.distance(u, x.position)
|
|
5360
5382
|
)[0]
|
|
5361
5383
|
];
|
|
5362
|
-
return this.internal.dataOne = v.value, this.internal.dataTwo =
|
|
5384
|
+
return this.internal.dataOne = v.value, this.internal.dataTwo = S.value, [v, S];
|
|
5363
5385
|
}
|
|
5364
5386
|
renderHover(e) {
|
|
5365
5387
|
if (this.state.hover == null) return;
|
|
@@ -5379,7 +5401,7 @@ class nn extends F {
|
|
|
5379
5401
|
this.renderHover(e);
|
|
5380
5402
|
const t = this.find(e);
|
|
5381
5403
|
if (t == null) return;
|
|
5382
|
-
const [s, r] = t, { draw: i } = this.internal, { strokeDash: a, strokeWidth: o } = this.state, c = Q.XY.scale(p.DECIMAL).scale(e.region), l = c.pos(s.position), u = c.pos(r.position), d = new
|
|
5404
|
+
const [s, r] = t, { draw: i } = this.internal, { strokeDash: a, strokeWidth: o } = this.state, c = Q.XY.scale(p.DECIMAL).scale(e.region), l = c.pos(s.position), u = c.pos(r.position), d = new T(Math.abs(s.value.x - r.value.x)), m = Math.abs(s.value.y - r.value.y), v = m / d.seconds;
|
|
5383
5405
|
i.line({
|
|
5384
5406
|
start: f.construct(l.x, l.y),
|
|
5385
5407
|
end: f.construct(l.x, u.y),
|
|
@@ -5398,7 +5420,7 @@ class nn extends F {
|
|
|
5398
5420
|
lineDash: a,
|
|
5399
5421
|
lineWidth: o
|
|
5400
5422
|
}), i.textContainer({
|
|
5401
|
-
text: [d.truncate(
|
|
5423
|
+
text: [d.truncate(T.MILLISECOND).toString()],
|
|
5402
5424
|
direction: "x",
|
|
5403
5425
|
position: f.construct((l.x + u.x) / 2, u.y),
|
|
5404
5426
|
level: "small"
|
|
@@ -5443,58 +5465,58 @@ const fh = {
|
|
|
5443
5465
|
trigger: h.number(),
|
|
5444
5466
|
command: h.number().optional(),
|
|
5445
5467
|
value: h.number(),
|
|
5446
|
-
sink: Ur.optional().default(
|
|
5447
|
-
source: Zr.optional().default(
|
|
5468
|
+
sink: Ur.optional().default(Lr),
|
|
5469
|
+
source: Zr.optional().default(_r)
|
|
5448
5470
|
});
|
|
5449
|
-
class
|
|
5471
|
+
class wr extends q {
|
|
5450
5472
|
static TYPE = "Setpoint";
|
|
5451
5473
|
schema = ph;
|
|
5452
5474
|
afterUpdate(e) {
|
|
5453
5475
|
const { sink: t, source: s, trigger: r, command: i } = this.state, { internal: a } = this;
|
|
5454
|
-
a.prevTrigger ??= r, (
|
|
5455
|
-
|
|
5456
|
-
|
|
5457
|
-
a.prevTrigger = r, r > o && i != null && this.internal.sink.set(i), this.updateValue(), a.stopListening?.(), a.stopListening = a.source.onChange(() => this.updateValue());
|
|
5458
|
-
})();
|
|
5476
|
+
a.prevTrigger ??= r, this.internal.source = ee(e, s, this.internal.source), a.sink = vt(e, t, a.sink);
|
|
5477
|
+
const o = a.prevTrigger;
|
|
5478
|
+
a.prevTrigger = r, r > o && i != null && this.internal.sink.set(i), this.updateValue(), a.stopListening?.(), a.stopListening = a.source.onChange(() => this.updateValue());
|
|
5459
5479
|
}
|
|
5460
5480
|
updateValue() {
|
|
5461
5481
|
const e = this.internal.source.value();
|
|
5462
|
-
e
|
|
5482
|
+
e === this.state.value || isNaN(e) || this.setState((t) => ({ ...t, value: e, triggered: !1 }));
|
|
5463
5483
|
}
|
|
5464
5484
|
afterDelete() {
|
|
5465
5485
|
const { internal: e } = this;
|
|
5466
|
-
e.stopListening(), e.source.cleanup?.(), e.sink.cleanup?.();
|
|
5486
|
+
e.stopListening?.(), e.source.cleanup?.(), e.sink.cleanup?.();
|
|
5467
5487
|
}
|
|
5468
5488
|
}
|
|
5469
|
-
const id = { [
|
|
5489
|
+
const id = { [wr.TYPE]: wr }, mh = h.object({
|
|
5470
5490
|
triggered: h.boolean(),
|
|
5471
5491
|
enabled: h.boolean(),
|
|
5472
5492
|
sink: hn.optional().default(ln),
|
|
5473
|
-
source:
|
|
5493
|
+
source: cs.optional().default(os)
|
|
5474
5494
|
});
|
|
5475
|
-
class
|
|
5495
|
+
class xr extends q {
|
|
5476
5496
|
static TYPE = "Toggle";
|
|
5477
5497
|
schema = mh;
|
|
5478
5498
|
afterUpdate(e) {
|
|
5479
5499
|
this.internal.addStatus = wa(e);
|
|
5480
5500
|
const { sink: t, source: s, triggered: r, enabled: i } = this.state, { triggered: a } = this.prevState, { internal: o } = this;
|
|
5481
|
-
o.source = ee(e, s, o.source), o.sink =
|
|
5501
|
+
o.source = ee(e, s, o.source), o.sink = vt(e, t, o.sink), r && !a && o.sink.set(!i), this.updateEnabledState(), o.stopListening?.(), o.stopListening = o.source.onChange(() => this.updateEnabledState());
|
|
5482
5502
|
}
|
|
5483
5503
|
updateEnabledState() {
|
|
5484
5504
|
const e = this.internal.source.value();
|
|
5485
5505
|
e !== this.state.enabled && this.setState((t) => ({ ...t, enabled: e, triggered: !1 }));
|
|
5486
5506
|
}
|
|
5487
5507
|
afterDelete() {
|
|
5488
|
-
this.internal.stopListening(), this.internal.source.cleanup?.(), this.internal.sink.cleanup?.();
|
|
5508
|
+
this.internal.stopListening?.(), this.internal.source.cleanup?.(), this.internal.sink.cleanup?.();
|
|
5489
5509
|
}
|
|
5490
5510
|
}
|
|
5491
|
-
const ad = { [
|
|
5511
|
+
const ad = { [xr.TYPE]: xr }, Cn = { useAtlas: !0 }, gh = h.object({
|
|
5492
5512
|
box: p.box,
|
|
5493
5513
|
telem: $r.optional().default(Yr),
|
|
5494
|
-
backgroundTelem:
|
|
5495
|
-
level:
|
|
5514
|
+
backgroundTelem: us.optional().default(cn),
|
|
5515
|
+
level: Dr.optional().default("p"),
|
|
5496
5516
|
color: y.colorZ.optional().default(y.ZERO),
|
|
5497
5517
|
precision: h.number().optional().default(2),
|
|
5518
|
+
stalenessTimeout: h.number().optional().default(5),
|
|
5519
|
+
stalenessColor: y.colorZ.optional().default(y.ZERO),
|
|
5498
5520
|
minWidth: h.number().optional().default(60),
|
|
5499
5521
|
width: h.number().optional(),
|
|
5500
5522
|
notation: Jn.notationZ.optional().default("standard"),
|
|
@@ -5503,13 +5525,15 @@ const ad = { [wr.TYPE]: wr }, Cn = { useAtlas: !0 }, gh = h.object({
|
|
|
5503
5525
|
valueBackgroundShift: f.xy.optional().default(f.ZERO),
|
|
5504
5526
|
valueBackgroundOverScan: f.xy.optional().default(f.ZERO)
|
|
5505
5527
|
}), yh = ["upper2d", "lower2d"];
|
|
5506
|
-
class
|
|
5528
|
+
class ft extends q {
|
|
5507
5529
|
static TYPE = "value";
|
|
5508
5530
|
static z = gh;
|
|
5509
|
-
schema =
|
|
5531
|
+
schema = ft.z;
|
|
5510
5532
|
afterUpdate(e) {
|
|
5511
5533
|
const { internal: t } = this;
|
|
5512
|
-
t.renderCtx = V.use(e), t.theme = fe(e),
|
|
5534
|
+
t.renderCtx = V.use(e), t.theme = fe(e), t.telem = ee(e, this.state.telem, t.telem), t.stopListening?.(), t.stopListening = t.telem.onChange(() => {
|
|
5535
|
+
t.lastReceived = performance.now(), this.requestRender();
|
|
5536
|
+
}), t.fontString = rt(t.theme, { level: this.state.level, code: !0 }), t.backgroundTelem = ee(
|
|
5513
5537
|
e,
|
|
5514
5538
|
this.state.backgroundTelem,
|
|
5515
5539
|
t.backgroundTelem
|
|
@@ -5531,52 +5555,58 @@ class pt extends F {
|
|
|
5531
5555
|
const { theme: t } = this.internal, s = e + t.sizes.base + this.fontHeight;
|
|
5532
5556
|
this.state.width == null || this.state.width + this.fontHeight * 0.5 < s || this.state.minWidth > s && this.state.width !== this.state.minWidth ? this.setState((r) => ({ ...r, width: Math.max(s, r.minWidth) })) : this.state.width - this.fontHeight > s && this.setState((r) => ({ ...r, width: Math.max(s, r.minWidth) }));
|
|
5533
5557
|
}
|
|
5558
|
+
getTextColor() {
|
|
5559
|
+
const { theme: e } = this.internal;
|
|
5560
|
+
return performance.now() - this.internal.lastReceived > this.state.stalenessTimeout * 1e3 ? y.isZero(this.state.stalenessColor) ? e.colors.warning.m1 : this.state.stalenessColor : y.isZero(this.state.color) ? y.pickByContrast(
|
|
5561
|
+
e.colors.border,
|
|
5562
|
+
e.colors.gray.l11,
|
|
5563
|
+
e.colors.gray.l0
|
|
5564
|
+
) : y.pickByContrast(
|
|
5565
|
+
e.colors.border,
|
|
5566
|
+
e.colors.gray.l11,
|
|
5567
|
+
this.state.color
|
|
5568
|
+
);
|
|
5569
|
+
}
|
|
5534
5570
|
render({ viewportScale: e = Q.XY.IDENTITY }) {
|
|
5535
5571
|
const { renderCtx: t, telem: s, backgroundTelem: r, fontString: i, requestRender: a } = this.internal, { location: o, box: c } = this.state;
|
|
5536
5572
|
if (p.areaIsZero(c)) return;
|
|
5537
5573
|
const l = p.topLeft(c), u = p.width(c), d = p.height(c), m = t.lower2d.applyScale(e);
|
|
5538
5574
|
let v = s.value();
|
|
5539
5575
|
m.font = i;
|
|
5540
|
-
const
|
|
5576
|
+
const S = this.fontHeight, w = v[0] == "-";
|
|
5541
5577
|
w && (v = v.slice(1));
|
|
5542
|
-
const { theme: x } = this.internal, R = m.textDimensions(v, Cn),
|
|
5543
|
-
a == null && t.erase(p.construct(this.prevState.box)), this.maybeUpdateWidth(
|
|
5578
|
+
const { theme: x } = this.internal, R = m.textDimensions(v, Cn), L = R.width + x.sizes.base, M = R.height;
|
|
5579
|
+
a == null && t.erase(p.construct(this.prevState.box)), this.maybeUpdateWidth(L);
|
|
5544
5580
|
const Y = { ...f.ZERO };
|
|
5545
|
-
o.x === "left" ? Y.x = 6 +
|
|
5546
|
-
const
|
|
5547
|
-
let E = !0;
|
|
5581
|
+
o.x === "left" ? Y.x = 6 + S * 0.75 : o.x === "center" && (Y.x = u / 2 - L / 2), o.y === "center" && (Y.y = d / 2 + M / 2);
|
|
5582
|
+
const N = f.translate(l, Y);
|
|
5548
5583
|
if (this.state.backgroundTelem.type != cn.type) {
|
|
5549
|
-
const
|
|
5550
|
-
if (!y.isZero(
|
|
5551
|
-
|
|
5552
|
-
const
|
|
5584
|
+
const I = r.value();
|
|
5585
|
+
if (!y.isZero(I)) {
|
|
5586
|
+
m.fillStyle = y.hex(I);
|
|
5587
|
+
const Je = this.state.useWidthForBackground ? this.state.width ?? this.state.minWidth : p.width(c);
|
|
5553
5588
|
m.fillRect(
|
|
5554
5589
|
...f.couple(f.translate(l, this.state.valueBackgroundShift)),
|
|
5555
|
-
|
|
5590
|
+
Je + this.state.valueBackgroundOverScan.x,
|
|
5556
5591
|
d + this.state.valueBackgroundOverScan.y
|
|
5557
5592
|
);
|
|
5558
|
-
const Re = y.pickByContrast(
|
|
5559
|
-
A,
|
|
5560
|
-
x.colors.gray.l0,
|
|
5561
|
-
x.colors.gray.l11
|
|
5562
|
-
);
|
|
5563
|
-
m.fillStyle = y.hex(Re);
|
|
5564
5593
|
}
|
|
5565
5594
|
}
|
|
5566
|
-
E
|
|
5595
|
+
const E = this.getTextColor();
|
|
5596
|
+
m.fillStyle = y.hex(E), w && m.fillText(
|
|
5567
5597
|
"-",
|
|
5568
|
-
...f.couple(f.translateX(
|
|
5598
|
+
...f.couple(f.translateX(N, -S * 0.6)),
|
|
5569
5599
|
void 0,
|
|
5570
5600
|
Cn
|
|
5571
|
-
), m.fillText(v, ...f.couple(
|
|
5601
|
+
), m.fillText(v, ...f.couple(N), void 0, Cn);
|
|
5572
5602
|
}
|
|
5573
5603
|
}
|
|
5574
5604
|
const vh = {
|
|
5575
|
-
[
|
|
5605
|
+
[ft.TYPE]: ft
|
|
5576
5606
|
}, od = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
5577
5607
|
__proto__: null,
|
|
5578
5608
|
REGISTRY: vh,
|
|
5579
|
-
Value:
|
|
5609
|
+
Value: ft
|
|
5580
5610
|
}, Symbol.toStringTag, { value: "Module" }));
|
|
5581
5611
|
class bh {
|
|
5582
5612
|
entries = /* @__PURE__ */ new Map();
|
|
@@ -5587,6 +5617,10 @@ class bh {
|
|
|
5587
5617
|
constructor(e, t = () => !1) {
|
|
5588
5618
|
this.handleError = e, this.equal = t;
|
|
5589
5619
|
}
|
|
5620
|
+
setOne(e, t, s, r) {
|
|
5621
|
+
const i = this.entries.get(t), a = xa(s, i);
|
|
5622
|
+
a == null || i != null && this.equal(a, i, t) || (this.entries.set(t, a), this.notifySet(e, t, a, r));
|
|
5623
|
+
}
|
|
5590
5624
|
/**
|
|
5591
5625
|
* Sets a value for the given key in the store.
|
|
5592
5626
|
*
|
|
@@ -5594,10 +5628,15 @@ class bh {
|
|
|
5594
5628
|
* @param value - The value to set, or a function to compute the value from the previous state
|
|
5595
5629
|
* @param opts - Options for the set operation
|
|
5596
5630
|
*/
|
|
5597
|
-
set(e, t, s) {
|
|
5598
|
-
if (Array.isArray(t))
|
|
5599
|
-
|
|
5600
|
-
|
|
5631
|
+
set(e, t, s, r) {
|
|
5632
|
+
if (Array.isArray(t))
|
|
5633
|
+
return t.forEach((i) => this.setOne(e, i.key, i, s));
|
|
5634
|
+
this.setOne(
|
|
5635
|
+
e,
|
|
5636
|
+
t,
|
|
5637
|
+
s,
|
|
5638
|
+
r
|
|
5639
|
+
);
|
|
5601
5640
|
}
|
|
5602
5641
|
get(e) {
|
|
5603
5642
|
return typeof e == "function" ? Array.from(this.entries.values()).filter(e) : Array.isArray(e) ? e.map((t) => this.entries.get(t)).filter((t) => t != null) : this.entries.get(e);
|
|
@@ -5628,9 +5667,7 @@ class bh {
|
|
|
5628
5667
|
* @returns A destructor function to remove the listener
|
|
5629
5668
|
*/
|
|
5630
5669
|
onSet(e, t, s) {
|
|
5631
|
-
return this.setListeners.set(t, { scope: e, key: s }), () =>
|
|
5632
|
-
this.setListeners.delete(t);
|
|
5633
|
-
};
|
|
5670
|
+
return this.setListeners.set(t, { scope: e, key: s }), () => this.setListeners.delete(t);
|
|
5634
5671
|
}
|
|
5635
5672
|
/**
|
|
5636
5673
|
* Registers a listener for delete operations.
|
|
@@ -5643,10 +5680,13 @@ class bh {
|
|
|
5643
5680
|
onDelete(e, t, s) {
|
|
5644
5681
|
return this.deleteListeners.set(t, { scope: e, key: s }), () => this.deleteListeners.delete(t);
|
|
5645
5682
|
}
|
|
5646
|
-
notifySet(e, t, s) {
|
|
5647
|
-
this.setListeners.forEach((
|
|
5648
|
-
const
|
|
5649
|
-
|
|
5683
|
+
notifySet(e, t, s, r) {
|
|
5684
|
+
this.setListeners.forEach((i, a) => {
|
|
5685
|
+
const o = i.key == null || i.key === t, c = i.scope !== e;
|
|
5686
|
+
o && c && this.handleError(
|
|
5687
|
+
async () => a(s, r),
|
|
5688
|
+
"Failed to notify set listener"
|
|
5689
|
+
);
|
|
5650
5690
|
});
|
|
5651
5691
|
}
|
|
5652
5692
|
notifyDelete(e, t) {
|
|
@@ -5657,7 +5697,7 @@ class bh {
|
|
|
5657
5697
|
}
|
|
5658
5698
|
scope(e) {
|
|
5659
5699
|
return {
|
|
5660
|
-
set: (t, s) => this.set(e, t, s),
|
|
5700
|
+
set: (t, s, r) => this.set(e, t, s, r),
|
|
5661
5701
|
get: (t) => this.get(t),
|
|
5662
5702
|
list: () => this.list(),
|
|
5663
5703
|
has: (t) => this.has(t),
|
|
@@ -5672,7 +5712,7 @@ const wh = (n, e) => Object.fromEntries(
|
|
|
5672
5712
|
t,
|
|
5673
5713
|
new bh(e, s)
|
|
5674
5714
|
])
|
|
5675
|
-
),
|
|
5715
|
+
), Sr = (n, e) => Object.fromEntries(
|
|
5676
5716
|
Object.entries(n).map(([t]) => [
|
|
5677
5717
|
t,
|
|
5678
5718
|
n[t].scope(e)
|
|
@@ -5701,17 +5741,17 @@ const wh = (n, e) => Object.fromEntries(
|
|
|
5701
5741
|
m.sort(xh), t(
|
|
5702
5742
|
async () => {
|
|
5703
5743
|
for (const v of m) {
|
|
5704
|
-
const
|
|
5744
|
+
const S = d.get(v), w = o[v];
|
|
5705
5745
|
if (w != null)
|
|
5706
5746
|
for (const { onChange: x, schema: R } of w)
|
|
5707
5747
|
await t(async () => {
|
|
5708
|
-
let
|
|
5709
|
-
|
|
5710
|
-
for (const M of
|
|
5748
|
+
let L;
|
|
5749
|
+
S.dataType.equals($.JSON) ? L = S.parseJSON(R) : L = Array.from(S).map((M) => R.parse(M));
|
|
5750
|
+
for (const M of L)
|
|
5711
5751
|
await t(
|
|
5712
5752
|
() => x({ changed: M, client: s, store: r }),
|
|
5713
5753
|
`Failed to handle streamer change for ${v}`,
|
|
5714
|
-
|
|
5754
|
+
Dt
|
|
5715
5755
|
);
|
|
5716
5756
|
}, `Failed to parse streamer change for ${v}`);
|
|
5717
5757
|
}
|
|
@@ -5736,7 +5776,7 @@ class Th {
|
|
|
5736
5776
|
client: e,
|
|
5737
5777
|
storeConfig: s,
|
|
5738
5778
|
handleError: i,
|
|
5739
|
-
store:
|
|
5779
|
+
store: Sr(this.store, ""),
|
|
5740
5780
|
openStreamer: t
|
|
5741
5781
|
}));
|
|
5742
5782
|
}
|
|
@@ -5744,7 +5784,7 @@ class Th {
|
|
|
5744
5784
|
this.streamCloser != null && await this.streamCloser;
|
|
5745
5785
|
}
|
|
5746
5786
|
scopedStore(e) {
|
|
5747
|
-
return
|
|
5787
|
+
return Sr(this.store, e);
|
|
5748
5788
|
}
|
|
5749
5789
|
async close() {
|
|
5750
5790
|
if (this.streamCloser == null) return;
|
|
@@ -5754,7 +5794,7 @@ class Th {
|
|
|
5754
5794
|
const Eh = we.object({}), Gn = "flux-context", Gi = "flux.Provider", Ch = (n, e) => n.get(Gn).scopedStore(e), kh = (n) => {
|
|
5755
5795
|
const e = (t, s) => {
|
|
5756
5796
|
if ("client" in n) return n.client;
|
|
5757
|
-
const r =
|
|
5797
|
+
const r = Ge(t);
|
|
5758
5798
|
return s != null && s?.client?.key === r?.key ? s : new Th({
|
|
5759
5799
|
client: r,
|
|
5760
5800
|
storeConfig: n.storeConfig,
|
|
@@ -5771,21 +5811,21 @@ const Eh = we.object({}), Gn = "flux-context", Gi = "flux.Provider", Ch = (n, e)
|
|
|
5771
5811
|
r.store = e(s, r.store), s.wasSetPreviously(Gn) || s.set(Gn, r.store);
|
|
5772
5812
|
}
|
|
5773
5813
|
};
|
|
5774
|
-
}, ld = (n) => ({ [Gi]: kh(n) }), Ph =
|
|
5814
|
+
}, ld = (n) => ({ [Gi]: kh(n) }), Ph = it.payloadZ.extend({
|
|
5775
5815
|
viewport: C.bounds
|
|
5776
5816
|
}), Rh = h.object({
|
|
5777
5817
|
cursor: f.xy.or(h.null()),
|
|
5778
5818
|
hovered: Ph.or(h.null()),
|
|
5779
5819
|
count: h.number()
|
|
5780
5820
|
});
|
|
5781
|
-
class Kn extends
|
|
5821
|
+
class Kn extends q {
|
|
5782
5822
|
static TYPE = "range-provider";
|
|
5783
5823
|
schema = Rh;
|
|
5784
5824
|
fetchedInitial = G.ZERO;
|
|
5785
5825
|
afterUpdate(e) {
|
|
5786
5826
|
const { internal: t } = this;
|
|
5787
|
-
t.render = V.use(e), t.draw = new
|
|
5788
|
-
const s =
|
|
5827
|
+
t.render = V.use(e), t.draw = new Qe(t.render.upper2d, fe(e)), t.requestRender = as(e), t.runAsync = ue(e), t.ranges ??= /* @__PURE__ */ new Map();
|
|
5828
|
+
const s = Ge(e);
|
|
5789
5829
|
if (t.requestRender("tool"), s == null) return;
|
|
5790
5830
|
t.client = s;
|
|
5791
5831
|
const r = Ch(e, this.key);
|
|
@@ -5801,7 +5841,7 @@ class Kn extends F {
|
|
|
5801
5841
|
}
|
|
5802
5842
|
fetchInitial(e) {
|
|
5803
5843
|
const { internal: t } = this, { client: s, runAsync: r } = t;
|
|
5804
|
-
s == null || this.fetchedInitial.equals(e,
|
|
5844
|
+
s == null || this.fetchedInitial.equals(e, T.minutes(1)) || (this.fetchedInitial = e, r(async () => {
|
|
5805
5845
|
(await s.ranges.retrieve(e)).forEach((a) => {
|
|
5806
5846
|
y.isCrude(a.color) && t.ranges.set(a.key, a);
|
|
5807
5847
|
}), this.setState((a) => ({ ...a, count: t.ranges.size }));
|
|
@@ -5821,7 +5861,7 @@ class Kn extends F {
|
|
|
5821
5861
|
o.forEach((m) => {
|
|
5822
5862
|
const v = y.colorZ.safeParse(m.color);
|
|
5823
5863
|
if (!v.success) return;
|
|
5824
|
-
const
|
|
5864
|
+
const S = v.data;
|
|
5825
5865
|
let w = c.pos(Number(m.timeRange.start.valueOf()));
|
|
5826
5866
|
const x = c.pos(Number(m.timeRange.end.valueOf()));
|
|
5827
5867
|
if (x < p.left(s) || w > p.right(s)) return;
|
|
@@ -5843,20 +5883,20 @@ class Kn extends F {
|
|
|
5843
5883
|
{ x: w, y: p.top(s) - 1 },
|
|
5844
5884
|
{ x, y: p.bottom(s) - 1 }
|
|
5845
5885
|
),
|
|
5846
|
-
backgroundColor: y.setAlpha(
|
|
5886
|
+
backgroundColor: y.setAlpha(S, 0.2),
|
|
5847
5887
|
bordered: !1
|
|
5848
5888
|
});
|
|
5849
|
-
const
|
|
5889
|
+
const L = p.construct(
|
|
5850
5890
|
{ x: w + 1, y: p.top(s) - 34 },
|
|
5851
5891
|
{ x: x - 1, y: p.top(s) - 12 }
|
|
5852
5892
|
);
|
|
5853
5893
|
a.container({
|
|
5854
|
-
region:
|
|
5855
|
-
backgroundColor: p.width(
|
|
5894
|
+
region: L,
|
|
5895
|
+
backgroundColor: p.width(L) < 20 ? y.setAlpha(S, 0.4) : (M) => R ? M.colors.gray.l2 : M.colors.gray.l0,
|
|
5856
5896
|
bordered: !0,
|
|
5857
5897
|
borderWidth: 1,
|
|
5858
5898
|
borderRadius: 2,
|
|
5859
|
-
borderColor: y.setAlpha(
|
|
5899
|
+
borderColor: y.setAlpha(S, 0.8)
|
|
5860
5900
|
}), a.text({
|
|
5861
5901
|
text: m.name,
|
|
5862
5902
|
position: { x: w + 8, y: p.top(s) - 30 },
|
|
@@ -5869,10 +5909,10 @@ class Kn extends F {
|
|
|
5869
5909
|
}
|
|
5870
5910
|
}
|
|
5871
5911
|
const cd = {
|
|
5872
|
-
[
|
|
5912
|
+
[hr.TYPE]: hr,
|
|
5873
5913
|
[Kn.TYPE]: Kn
|
|
5874
5914
|
}, ud = gn;
|
|
5875
|
-
class Qn extends
|
|
5915
|
+
class Qn extends Hi {
|
|
5876
5916
|
static TYPE = "XAxis";
|
|
5877
5917
|
schema = gn;
|
|
5878
5918
|
render(e) {
|
|
@@ -5908,7 +5948,7 @@ class Qn extends ji {
|
|
|
5908
5948
|
this.yAxes.forEach((r) => r.render(s));
|
|
5909
5949
|
}
|
|
5910
5950
|
get yAxes() {
|
|
5911
|
-
return this.childrenOfType(
|
|
5951
|
+
return this.childrenOfType(jn.TYPE);
|
|
5912
5952
|
}
|
|
5913
5953
|
get rangeAnnotations() {
|
|
5914
5954
|
return this.childrenOfType(Kn.TYPE);
|
|
@@ -5940,15 +5980,15 @@ const Mh = h.object({
|
|
|
5940
5980
|
grid: h.record(h.string(), Si),
|
|
5941
5981
|
visible: h.boolean().optional().default(!0),
|
|
5942
5982
|
clearOverScan: f.crudeZ.optional().default(f.ZERO)
|
|
5943
|
-
}),
|
|
5983
|
+
}), Oh = (n, e) => {
|
|
5944
5984
|
const t = p.width(n) * Math.sqrt(p.height(n)), s = p.width(e) * Math.sqrt(p.height(e));
|
|
5945
5985
|
return t / s;
|
|
5946
|
-
},
|
|
5947
|
-
class
|
|
5986
|
+
}, Dh = ["upper2d", "lower2d", "gl"], Lh = ["upper2d"];
|
|
5987
|
+
class Tr extends ae {
|
|
5948
5988
|
static TYPE = "LinePlot";
|
|
5949
5989
|
schema = Mh;
|
|
5950
5990
|
afterUpdate(e) {
|
|
5951
|
-
this.internal.instrumentation =
|
|
5991
|
+
this.internal.instrumentation = mt(e, "lineplot"), this.internal.handleError = ue(e), this.internal.renderCtx = V.use(e), is(e, (t) => {
|
|
5952
5992
|
this.state.visible && this.requestRender("low", t);
|
|
5953
5993
|
}), !(!this.state.visible && !this.prevState.visible) && this.requestRender("high", "layout");
|
|
5954
5994
|
}
|
|
@@ -5984,7 +6024,7 @@ class Sr extends ae {
|
|
|
5984
6024
|
return this.childrenOfType(In.TYPE);
|
|
5985
6025
|
}
|
|
5986
6026
|
get exposure() {
|
|
5987
|
-
return
|
|
6027
|
+
return Oh(this.state.viewport, this.state.container);
|
|
5988
6028
|
}
|
|
5989
6029
|
renderAxes(e, t) {
|
|
5990
6030
|
const s = { ...this.state, plot: e, canvases: t, exposure: this.exposure };
|
|
@@ -6019,7 +6059,7 @@ class Sr extends ae {
|
|
|
6019
6059
|
this.measures.forEach((s) => s.render(t));
|
|
6020
6060
|
}
|
|
6021
6061
|
calculatePlot() {
|
|
6022
|
-
return
|
|
6062
|
+
return Do(this.state.grid, this.state.container);
|
|
6023
6063
|
}
|
|
6024
6064
|
render(e) {
|
|
6025
6065
|
const { instrumentation: t, renderCtx: s, handleError: r } = this.internal;
|
|
@@ -6060,8 +6100,8 @@ class Sr extends ae {
|
|
|
6060
6100
|
}
|
|
6061
6101
|
requestRender(e, t) {
|
|
6062
6102
|
const { renderCtx: s } = this.internal;
|
|
6063
|
-
let r =
|
|
6064
|
-
t === "tool" && (r =
|
|
6103
|
+
let r = Dh;
|
|
6104
|
+
t === "tool" && (r = Lh), s.loop.set({
|
|
6065
6105
|
key: `${this.type}-${this.key}`,
|
|
6066
6106
|
render: () => this.render(r),
|
|
6067
6107
|
priority: e,
|
|
@@ -6070,46 +6110,46 @@ class Sr extends ae {
|
|
|
6070
6110
|
}
|
|
6071
6111
|
}
|
|
6072
6112
|
const hd = {
|
|
6073
|
-
[
|
|
6113
|
+
[Tr.TYPE]: Tr,
|
|
6074
6114
|
[Qn.TYPE]: Qn,
|
|
6075
|
-
[
|
|
6115
|
+
[jn.TYPE]: jn,
|
|
6076
6116
|
[In.TYPE]: In
|
|
6077
6117
|
};
|
|
6078
6118
|
export {
|
|
6079
|
-
|
|
6119
|
+
fr as $,
|
|
6080
6120
|
nd as A,
|
|
6081
6121
|
rd as B,
|
|
6082
|
-
|
|
6122
|
+
qh as C,
|
|
6083
6123
|
ed as D,
|
|
6084
6124
|
od as E,
|
|
6085
|
-
|
|
6125
|
+
jh as F,
|
|
6086
6126
|
In as G,
|
|
6087
6127
|
Mo as H,
|
|
6088
6128
|
Mh as I,
|
|
6089
6129
|
ud as J,
|
|
6090
|
-
|
|
6091
|
-
|
|
6130
|
+
Fh as K,
|
|
6131
|
+
Tr as L,
|
|
6092
6132
|
zt as M,
|
|
6093
|
-
|
|
6133
|
+
Ke as N,
|
|
6094
6134
|
su as O,
|
|
6095
6135
|
au as P,
|
|
6096
|
-
|
|
6136
|
+
qi as Q,
|
|
6097
6137
|
zh as R,
|
|
6098
6138
|
nu as S,
|
|
6099
6139
|
ru as T,
|
|
6100
|
-
|
|
6140
|
+
ar as U,
|
|
6101
6141
|
$i as V,
|
|
6102
6142
|
Ui as W,
|
|
6103
6143
|
Qn as X,
|
|
6104
|
-
|
|
6144
|
+
jn as Y,
|
|
6105
6145
|
Wn as Z,
|
|
6106
6146
|
Vn as _,
|
|
6107
|
-
|
|
6108
|
-
|
|
6109
|
-
|
|
6110
|
-
|
|
6111
|
-
|
|
6112
|
-
|
|
6147
|
+
as as a,
|
|
6148
|
+
Va as a$,
|
|
6149
|
+
mr as a0,
|
|
6150
|
+
gr as a1,
|
|
6151
|
+
yr as a2,
|
|
6152
|
+
qu as a3,
|
|
6113
6153
|
zn as a4,
|
|
6114
6154
|
Jt as a5,
|
|
6115
6155
|
Vh as a6,
|
|
@@ -6118,11 +6158,11 @@ export {
|
|
|
6118
6158
|
Xh as a9,
|
|
6119
6159
|
Xi as aA,
|
|
6120
6160
|
nn as aB,
|
|
6121
|
-
|
|
6161
|
+
ji as aC,
|
|
6122
6162
|
Qt as aD,
|
|
6123
6163
|
Aa as aE,
|
|
6124
6164
|
Na as aF,
|
|
6125
|
-
|
|
6165
|
+
ss as aG,
|
|
6126
6166
|
mi as aH,
|
|
6127
6167
|
Nn as aI,
|
|
6128
6168
|
Gi as aJ,
|
|
@@ -6130,30 +6170,30 @@ export {
|
|
|
6130
6170
|
Th as aL,
|
|
6131
6171
|
bh as aM,
|
|
6132
6172
|
wh as aN,
|
|
6133
|
-
|
|
6134
|
-
|
|
6135
|
-
|
|
6136
|
-
|
|
6137
|
-
|
|
6138
|
-
|
|
6139
|
-
|
|
6140
|
-
|
|
6141
|
-
|
|
6142
|
-
|
|
6143
|
-
|
|
6144
|
-
|
|
6145
|
-
|
|
6173
|
+
Sr as aO,
|
|
6174
|
+
vr as aP,
|
|
6175
|
+
Ju as aQ,
|
|
6176
|
+
th as aR,
|
|
6177
|
+
eh as aS,
|
|
6178
|
+
Ku as aT,
|
|
6179
|
+
Hr as aU,
|
|
6180
|
+
zr as aV,
|
|
6181
|
+
ri as aW,
|
|
6182
|
+
ii as aX,
|
|
6183
|
+
Ia as aY,
|
|
6184
|
+
Oa as aZ,
|
|
6185
|
+
Xa as a_,
|
|
6146
6186
|
Wu as aa,
|
|
6147
6187
|
Zu as ab,
|
|
6148
6188
|
Bu as ac,
|
|
6149
|
-
|
|
6189
|
+
Hu as ad,
|
|
6150
6190
|
Xu as ae,
|
|
6151
6191
|
Vu as af,
|
|
6152
6192
|
Gu as ag,
|
|
6153
6193
|
Wh as ah,
|
|
6154
|
-
|
|
6194
|
+
ju as ai,
|
|
6155
6195
|
Uu as aj,
|
|
6156
|
-
|
|
6196
|
+
Fu as ak,
|
|
6157
6197
|
$u as al,
|
|
6158
6198
|
zi as am,
|
|
6159
6199
|
Xn as an,
|
|
@@ -6162,48 +6202,48 @@ export {
|
|
|
6162
6202
|
cu as aq,
|
|
6163
6203
|
gn as ar,
|
|
6164
6204
|
vu as as,
|
|
6165
|
-
|
|
6205
|
+
Hn as at,
|
|
6166
6206
|
Vi as au,
|
|
6167
6207
|
en as av,
|
|
6168
6208
|
Yu as aw,
|
|
6169
|
-
|
|
6209
|
+
hr as ax,
|
|
6170
6210
|
Rh as ay,
|
|
6171
6211
|
Kn as az,
|
|
6172
6212
|
sd as b,
|
|
6173
|
-
|
|
6174
|
-
|
|
6175
|
-
|
|
6176
|
-
|
|
6177
|
-
|
|
6178
|
-
|
|
6179
|
-
|
|
6180
|
-
|
|
6181
|
-
|
|
6182
|
-
|
|
6183
|
-
|
|
6184
|
-
|
|
6185
|
-
|
|
6186
|
-
|
|
6187
|
-
|
|
6188
|
-
|
|
6189
|
-
|
|
6190
|
-
|
|
6191
|
-
|
|
6192
|
-
|
|
6193
|
-
|
|
6194
|
-
|
|
6195
|
-
|
|
6196
|
-
|
|
6197
|
-
|
|
6198
|
-
|
|
6199
|
-
|
|
6213
|
+
ft as b0,
|
|
6214
|
+
jr as b1,
|
|
6215
|
+
ti as b2,
|
|
6216
|
+
ja as b3,
|
|
6217
|
+
Da as b4,
|
|
6218
|
+
Ha as b5,
|
|
6219
|
+
$s as b6,
|
|
6220
|
+
cl as b7,
|
|
6221
|
+
ut as b8,
|
|
6222
|
+
xs as b9,
|
|
6223
|
+
rh as ba,
|
|
6224
|
+
br as bb,
|
|
6225
|
+
ph as bc,
|
|
6226
|
+
wr as bd,
|
|
6227
|
+
mh as be,
|
|
6228
|
+
xr as bf,
|
|
6229
|
+
Ga as bg,
|
|
6230
|
+
Ka as bh,
|
|
6231
|
+
ot as bi,
|
|
6232
|
+
xi as bj,
|
|
6233
|
+
dt as bk,
|
|
6234
|
+
$r as bl,
|
|
6235
|
+
Wi as bm,
|
|
6236
|
+
We as bn,
|
|
6237
|
+
uh as bo,
|
|
6238
|
+
tn as bp,
|
|
6239
|
+
is as c,
|
|
6200
6240
|
vh as d,
|
|
6201
6241
|
ch as e,
|
|
6202
6242
|
ad as f,
|
|
6203
6243
|
Po as g,
|
|
6204
6244
|
ro as h,
|
|
6205
6245
|
id as i,
|
|
6206
|
-
|
|
6246
|
+
Lu as j,
|
|
6207
6247
|
cd as k,
|
|
6208
6248
|
fh as l,
|
|
6209
6249
|
hd as m,
|
|
@@ -6216,7 +6256,7 @@ export {
|
|
|
6216
6256
|
Qh as t,
|
|
6217
6257
|
Ca as u,
|
|
6218
6258
|
ld as v,
|
|
6219
|
-
|
|
6259
|
+
Hh as w,
|
|
6220
6260
|
Zh as x,
|
|
6221
6261
|
Uh as y,
|
|
6222
6262
|
Jh as z
|