@hybridcore/ui 1.5.80 → 1.5.83
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/{AccordionDetails-mpRYHtGq.js → AccordionDetails-DhriPVPP.js} +9 -9
- package/dist/{Add-Cjs72ewI.js → Add-CMz4N2zT.js} +36 -35
- package/dist/{AxisRendererY-CFo972D5.js → AxisRendererY-kADUad00.js} +2464 -3363
- package/dist/{Box-SSMZuKnS.js → Box-B1AVyJ_s.js} +17 -16
- package/dist/{Button-jy67CcTH.js → Button-eqWvpDuh.js} +12 -11
- package/dist/{ButtonBase-CgQC8DUB.js → ButtonBase-DsX-jMQJ.js} +4 -4
- package/dist/{CardContent-CCq4R1KS.js → CardContent-DsYqqPeJ.js} +4 -4
- package/dist/{Checkbox-B0P8LhCl.js → Checkbox-CrU2hpWB.js} +13 -12
- package/dist/ColumnSeries-BTcqshjB.js +399 -0
- package/dist/DateAxis-CMum47iz.js +924 -0
- package/dist/{Delete-6rKk6pCT.js → Delete-86TO0fMo.js} +1 -1
- package/dist/{DialogContent-WDuguvBY.js → DialogContent-CqTojymQ.js} +10 -9
- package/dist/{FormControlLabel-BNT5EI0b.js → FormControlLabel-DzNokgFD.js} +8 -7
- package/dist/{IconButton-DekcZv4i.js → IconButton-DJ-31-Fd.js} +11 -10
- package/dist/{Input-BAbDr3Tk.js → Input-B7ry6o4t.js} +23 -22
- package/dist/{InputAdornment-BAVRrRts.js → InputAdornment-B7qEA4kN.js} +6 -5
- package/dist/{InputLabel-ClDXuWBr.js → InputLabel-rrSJo8M_.js} +10 -9
- package/dist/LineSeries-CfcpoYla.js +549 -0
- package/dist/{List-CNeRnfGL.js → List-DOD5kSk3.js} +4 -4
- package/dist/{ListItem-N_dSd02S.js → ListItem-r8PbsvCz.js} +6 -6
- package/dist/{MenuItem-Lcjh1XlV.js → MenuItem-C6qlUyV3.js} +7 -7
- package/dist/{Modal-Csc9jNOg.js → Modal-CkcFEpHa.js} +8 -8
- package/dist/{OutlinedInput-De2keFJK.js → OutlinedInput-BDK6qOwW.js} +6 -6
- package/dist/{Paper-DRRYGupP.js → Paper-CjqLScHA.js} +5 -5
- package/dist/{Select-BQ4C15bt.js → Select-jjAc5JX1.js} +102 -101
- package/dist/{Tabs-DqdkJU6b.js → Tabs-Cn42Z5QI.js} +8 -8
- package/dist/{TextField-Db_pNPbv.js → TextField-Bf46COnQ.js} +24 -23
- package/dist/{Typography-CLq43OVQ.js → Typography-D1t7XuLN.js} +6 -5
- package/dist/components/card/index.js +6 -6
- package/dist/components/card/styled.js +1 -1
- package/dist/components/charts/candlestick/logic.js +133 -526
- package/dist/components/charts/highlighting-line-data/logic.js +152 -695
- package/dist/components/collapsible-card/style.js +3 -3
- package/dist/components/confirm/dialog.js +3 -3
- package/dist/components/confirm/index.js +1 -1
- package/dist/components/container/index.js +7 -7
- package/dist/components/context-menu/index.js +10 -10
- package/dist/components/flex-col/index.js +10 -0
- package/dist/components/flex-row/index.js +10 -0
- package/dist/components/geometry-picker/index.js +3 -3
- package/dist/components/icon-button/index.js +1 -1
- package/dist/components/instance-form/components/composite-list/index.js +1 -1
- package/dist/components/instance-form/components/composite-matrix/components/editable-table/index.js +93 -0
- package/dist/components/instance-form/components/composite-matrix/components/editor/index.js +87 -0
- package/dist/components/instance-form/components/composite-matrix/components/editor/styled.js +1 -0
- package/dist/components/instance-form/components/composite-matrix/components/form/index.js +105 -0
- package/dist/components/instance-form/components/composite-matrix/components/json-editor/index.js +20551 -0
- package/dist/components/instance-form/components/composite-matrix/components/table/index.js +56 -0
- package/dist/components/instance-form/components/composite-matrix/index.js +52 -0
- package/dist/components/instance-form/components/composite-matrix/styled.js +69 -0
- package/dist/components/instance-form/components/variable/index.js +10 -9
- package/dist/components/instance-form/components/variables/index.js +1 -1
- package/dist/components/instance-hierarchy-table/styled.js +1 -1
- package/dist/components/map/styled.js +1 -1
- package/dist/components/metric-card/MetricChart.js +525 -0
- package/dist/components/metric-card/index.js +88 -45
- package/dist/components/metric-card/logic.js +82 -37
- package/dist/components/metric-card/styled.js +109 -90
- package/dist/components/paginated-list/styled.js +3 -3
- package/dist/components/property-mapping/index.js +1 -1
- package/dist/components/range-selector/components/composite-list-range/index.js +1 -1
- package/dist/components/range-selector/components/date-range/index.js +1 -1
- package/dist/components/range-selector/index.js +1 -1
- package/dist/components/search-input/index.js +4 -4
- package/dist/components/tabs/index.js +1 -1
- package/dist/components/template-filters/components/tab-panel/index.js +1 -1
- package/dist/components/template-form/components/property-list/index.js +7 -7
- package/dist/components/template-form/components/property-list/property-list-columns.js +3 -3
- package/dist/components/template-form/components/property-list/property-list-form.js +9 -9
- package/dist/components/template-form/components/recognition-property-list/index.js +6 -6
- package/dist/components/template-form/components/recognition-property-list/recognition-property-list-columns.js +2 -2
- package/dist/components/template-form/components/recognition-property-list/recognition-property-list-form.js +7 -7
- package/dist/components/template-form/index.js +5 -5
- package/dist/components/template-property-filters/property.js +5 -5
- package/dist/components/tree-select/index.js +5 -5
- package/dist/components/treeview-filter/item-label/index.js +3 -3
- package/dist/{createStyled-CUatW1r9.js → createStyled-BGx1I94c.js} +1 -1
- package/dist/{createSvgIcon-CsckVnG-.js → createSvgIcon-DLPYMuH1.js} +25 -24
- package/dist/{createSvgIcon-CBoAEepv.js → createSvgIcon-OuwzpcaC.js} +15 -14
- package/dist/{createTheme-DVoJnXAT.js → createTheme-CNnKNxwL.js} +1 -1
- package/dist/createTheme-CyC5HawC.js +879 -0
- package/dist/{dialog-D6oTCUrm.js → dialog-BE4D6swf.js} +6 -6
- package/dist/{exactProp-H1i70prd.js → exactProp-cjT0t_Pt.js} +2 -2
- package/dist/{extendSxProp-BmK2hLmq.js → extendSxProp-FEpqY5_S.js} +1 -1
- package/dist/index-DMSHuq6l.js +688 -0
- package/dist/{index-BmlSd3mA.js → index-MMaYBAn0.js} +138 -128
- package/dist/{index-R_b1ETBe.js → index-NNOChRJ7.js} +25 -24
- package/dist/{listItemTextClasses-CC7nbQWN.js → listItemTextClasses-CNjn41Of.js} +2 -2
- package/dist/main.d.ts +48 -14
- package/dist/main.js +47 -43
- package/dist/{property-list-form-B7SCqmD0.js → property-list-form-BvnaooEW.js} +13 -13
- package/dist/{styled-DkqItiLo.js → styled-B8ugzvji.js} +2 -2
- package/dist/{useTheme-GN5Dc3mG.js → useTheme-C15Eq8KG.js} +1 -1
- package/dist/{useTheme-B6oa3v5u.js → useTheme-D-uii9iX.js} +2 -2
- package/dist/{useThemeProps-BlXpIqSE.js → useThemeProps-DRP1dikX.js} +3 -3
- package/dist/{utils-BRsEqTye.js → utils-CsOZUsQj.js} +2 -2
- package/package.json +2 -1
- package/dist/createTheme-DrgvKMA_.js +0 -1563
|
@@ -1,332 +1,9 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { useThemeProps as
|
|
3
|
-
import { useRef as
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
enumerable: !0,
|
|
8
|
-
configurable: !0,
|
|
9
|
-
writable: !0,
|
|
10
|
-
value: 0
|
|
11
|
-
}), Object.defineProperty(this, "_pw", {
|
|
12
|
-
enumerable: !0,
|
|
13
|
-
configurable: !0,
|
|
14
|
-
writable: !0,
|
|
15
|
-
value: 0
|
|
16
|
-
}), Object.defineProperty(this, "_columnsUpdated", {
|
|
17
|
-
enumerable: !0,
|
|
18
|
-
configurable: !0,
|
|
19
|
-
writable: !0,
|
|
20
|
-
value: !1
|
|
21
|
-
});
|
|
22
|
-
}
|
|
23
|
-
_makeGraphics(e, t) {
|
|
24
|
-
return this.makeColumn(t, e);
|
|
25
|
-
}
|
|
26
|
-
_makeFieldNames() {
|
|
27
|
-
super._makeFieldNames();
|
|
28
|
-
const e = this.get("xAxis"), t = this.get("yAxis"), s = "CategoryAxis", o = "ValueAxis";
|
|
29
|
-
e.isType(s) && (this.get("openCategoryXField") || (this._xOpenField = this._xField)), e.isType(o) && (this.get("openValueXField") || (this._xOpenField = this._xField)), t.isType(s) && (this.get("openCategoryYField") || (this._yOpenField = this._yField)), t.isType(o) && (this.get("openValueYField") || (this._yOpenField = this._yField));
|
|
30
|
-
}
|
|
31
|
-
_prepareChildren() {
|
|
32
|
-
super._prepareChildren();
|
|
33
|
-
const e = this.get("xAxis"), t = this.get("yAxis"), s = this.dataItems.length, o = Math.max(0, this.startIndex() - 2), i = Math.min(this.endIndex() + 2, s - 1);
|
|
34
|
-
if (e.inited && t.inited)
|
|
35
|
-
for (let n = o; n <= i; n++) {
|
|
36
|
-
let l = this.dataItems[n];
|
|
37
|
-
this._createGraphics(l);
|
|
38
|
-
}
|
|
39
|
-
}
|
|
40
|
-
_updateChildren() {
|
|
41
|
-
const e = this.chart;
|
|
42
|
-
e && (this._ph = e.plotContainer.height(), this._pw = e.plotContainer.width());
|
|
43
|
-
const t = this.get("xAxis"), s = this.get("yAxis"), o = this.get("baseAxis"), i = this.columns.template;
|
|
44
|
-
this.isDirty("fill") && i.get("fill") == null && i.set("fill", this.get("fill")), this.isDirty("fillPattern") && i.get("fillPattern") == null && i.set("fillPattern", this.get("fillPattern")), this.isDirty("stroke") && i.get("stroke") == null && i.set("stroke", this.get("stroke"));
|
|
45
|
-
let n = 0, l = 0, d = 0;
|
|
46
|
-
k(o.series, (f) => {
|
|
47
|
-
if (f instanceof T) {
|
|
48
|
-
const c = f.get("stacked");
|
|
49
|
-
c && d == 0 && l++, !c && f.get("clustered") && l++;
|
|
50
|
-
}
|
|
51
|
-
f === this && (n = l - 1), d++;
|
|
52
|
-
}), this.get("clustered") || (n = 0, l = 1), l === 0 && (l = 1, n = 0);
|
|
53
|
-
const m = t.get("renderer"), x = s.get("renderer"), h = "cellStartLocation", u = "cellEndLocation", p = m.get(h, 0), _ = m.get(u, 1), g = x.get(h, 0), a = x.get(u, 1);
|
|
54
|
-
if (this._aLocationX0 = p + n / l * (_ - p), this._aLocationX1 = p + (n + 1) / l * (_ - p), this._aLocationY0 = g + n / l * (a - g), this._aLocationY1 = g + (n + 1) / l * (a - g), t.inited && s.inited) {
|
|
55
|
-
if (this._axesDirty || this._valuesDirty || this._stackDirty || this.isDirty("vcx") || this.isDirty("vcy") || this._sizeDirty) {
|
|
56
|
-
const f = this.dataItems.length;
|
|
57
|
-
let c = Math.max(0, this.startIndex() - 2), r = Math.min(this.endIndex() + 2, f - 1);
|
|
58
|
-
for (let y = 0; y < c; y++)
|
|
59
|
-
this._toggleColumn(this.dataItems[y], !1);
|
|
60
|
-
let w = this.dataItems[c];
|
|
61
|
-
for (let y = c; y <= r; y++) {
|
|
62
|
-
let b = this.dataItems[y];
|
|
63
|
-
if (b.get("valueX") != null && b.get("valueY") != null) {
|
|
64
|
-
if (w = b, y > 0 && c > 0)
|
|
65
|
-
for (let C = y - 1; C >= 0; C--) {
|
|
66
|
-
let Y = this.dataItems[C];
|
|
67
|
-
if (Y.get("valueX") != null && Y.get("valueY") != null) {
|
|
68
|
-
w = Y;
|
|
69
|
-
break;
|
|
70
|
-
}
|
|
71
|
-
}
|
|
72
|
-
break;
|
|
73
|
-
} else
|
|
74
|
-
this._toggleColumn(b, !1);
|
|
75
|
-
}
|
|
76
|
-
this._beforeColumnsDraw();
|
|
77
|
-
let X = 0;
|
|
78
|
-
s.isType("CategoryAxis") && t.isType("CategoryAxis") ? X = 2 : t === o ? X = 0 : s === o && (X = 1);
|
|
79
|
-
for (let y = c; y <= r; y++) {
|
|
80
|
-
let b = this.dataItems[y];
|
|
81
|
-
this._updateGraphics(b, w, X), b.get("valueX") != null && b.get("valueY") != null && (w = b);
|
|
82
|
-
}
|
|
83
|
-
this._afterColumnsDraw();
|
|
84
|
-
for (let y = r + 1; y < f; y++)
|
|
85
|
-
this._toggleColumn(this.dataItems[y], !1);
|
|
86
|
-
this._columnsUpdated = !0;
|
|
87
|
-
}
|
|
88
|
-
} else
|
|
89
|
-
this._skipped = !0;
|
|
90
|
-
this.getPrivate("doNotUpdateLegend") || this.updateLegendMarker(this.get("tooltipDataItem")), super._updateChildren();
|
|
91
|
-
}
|
|
92
|
-
_afterChanged() {
|
|
93
|
-
super._afterChanged(), this._columnsUpdated = !1;
|
|
94
|
-
}
|
|
95
|
-
_beforeColumnsDraw() {
|
|
96
|
-
}
|
|
97
|
-
_afterColumnsDraw() {
|
|
98
|
-
}
|
|
99
|
-
_createGraphics(e) {
|
|
100
|
-
let t = e.get("graphics");
|
|
101
|
-
if (!t) {
|
|
102
|
-
t = this._makeGraphics(this.columns, e), e.set("graphics", t), t._setDataItem(e);
|
|
103
|
-
const s = e.get("legendDataItem");
|
|
104
|
-
if (s) {
|
|
105
|
-
const i = s.get("markerRectangle");
|
|
106
|
-
if (i) {
|
|
107
|
-
const n = i.states.lookup("default");
|
|
108
|
-
k(K, (l) => {
|
|
109
|
-
const d = t.get(l, this.get(l));
|
|
110
|
-
i.set(l, d), n.set(l, d);
|
|
111
|
-
});
|
|
112
|
-
}
|
|
113
|
-
}
|
|
114
|
-
let o = e.get("rangeGraphics");
|
|
115
|
-
o && k(o, (i) => {
|
|
116
|
-
i.dispose();
|
|
117
|
-
}), o = [], e.setRaw("rangeGraphics", o), this.axisRanges.each((i) => {
|
|
118
|
-
const n = i.container, l = this._makeGraphics(i.columns, e);
|
|
119
|
-
o && o.push(l), l.setPrivate("list", i.columns), n.children.push(l);
|
|
120
|
-
});
|
|
121
|
-
}
|
|
122
|
-
}
|
|
123
|
-
createAxisRange(e) {
|
|
124
|
-
return k(this.dataItems, (t) => {
|
|
125
|
-
const s = t.get("graphics");
|
|
126
|
-
s && (s.dispose(), t.set("graphics", void 0));
|
|
127
|
-
}), super.createAxisRange(e);
|
|
128
|
-
}
|
|
129
|
-
_updateGraphics(e, t, s) {
|
|
130
|
-
let o = e.get("graphics");
|
|
131
|
-
const i = this._xField, n = this._yField, l = e.get(i), d = e.get(n), m = this.get("exactLocationX", !1);
|
|
132
|
-
if (l != null && d != null) {
|
|
133
|
-
const x = this._xOpenField, h = this._yOpenField, u = this.get("locationX", e.get("locationX", 0.5)), p = this.get("locationY", e.get("locationY", 0.5)), _ = this.get("openLocationX", e.get("openLocationX", u)), g = this.get("openLocationY", e.get("openLocationY", p)), a = o.get("width"), f = o.get("height"), c = this.get("stacked"), r = this.get("xAxis"), w = this.get("yAxis"), X = r.get("start"), y = r.get("end"), b = w.get("start"), C = w.get("end");
|
|
134
|
-
let Y, L, F, A, G = this.get("vcy", 1), R = this.get("vcx", 1), B = !1, Z = !1;
|
|
135
|
-
if (s == 0) {
|
|
136
|
-
let P = this._aLocationX0 + _ - 0.5, D = this._aLocationX1 + u - 0.5;
|
|
137
|
-
if (a instanceof V) {
|
|
138
|
-
let v = (D - P) * (1 - a.value) / 2;
|
|
139
|
-
P += v, D -= v;
|
|
140
|
-
}
|
|
141
|
-
if (Y = r.getDataItemPositionX(e, x, P, R, m), L = r.getDataItemPositionX(e, i, D, R, m), F = w.getDataItemPositionY(e, n, p, G), this._yOpenField !== this._yField)
|
|
142
|
-
A = w.getDataItemPositionY(e, h, g, G);
|
|
143
|
-
else if (c) {
|
|
144
|
-
let v = e.get("stackToItemY");
|
|
145
|
-
v ? A = w.getDataItemPositionY(v, n, g, v.component.get("vcy")) : A = w.basePosition();
|
|
146
|
-
} else
|
|
147
|
-
A = w.basePosition();
|
|
148
|
-
e.setRaw("point", { x: Y + (L - Y) / 2, y: F }), Z = !0;
|
|
149
|
-
} else if (s == 1) {
|
|
150
|
-
let P = this._aLocationY0 + g - 0.5, D = this._aLocationY1 + p - 0.5;
|
|
151
|
-
if (f instanceof V) {
|
|
152
|
-
let v = (D - P) * (1 - f.value) / 2;
|
|
153
|
-
P += v, D -= v;
|
|
154
|
-
}
|
|
155
|
-
if (F = w.getDataItemPositionY(e, h, P, G), A = w.getDataItemPositionY(e, n, D, G), L = r.getDataItemPositionX(e, i, u, R, m), this._xOpenField !== this._xField)
|
|
156
|
-
Y = r.getDataItemPositionX(e, x, _, R, m);
|
|
157
|
-
else if (c) {
|
|
158
|
-
let v = e.get("stackToItemX");
|
|
159
|
-
v ? Y = r.getDataItemPositionX(v, i, _, v.component.get("vcx"), m) : Y = r.basePosition();
|
|
160
|
-
} else
|
|
161
|
-
Y = r.basePosition();
|
|
162
|
-
B = !0, e.setRaw("point", { x: L, y: F + (A - F) / 2 });
|
|
163
|
-
} else if (s == 2) {
|
|
164
|
-
let P = this._aLocationX0 + _ - 0.5, D = this._aLocationX1 + u - 0.5;
|
|
165
|
-
if (a instanceof V) {
|
|
166
|
-
let v = (D - P) * (1 - a.value) / 2;
|
|
167
|
-
P += v, D -= v;
|
|
168
|
-
}
|
|
169
|
-
if (Y = r.getDataItemPositionX(e, x, P, R), L = r.getDataItemPositionX(e, i, D, R), P = this._aLocationY0 + g - 0.5, D = this._aLocationY1 + p - 0.5, f instanceof V) {
|
|
170
|
-
let v = (D - P) * (1 - f.value) / 2;
|
|
171
|
-
P += v, D -= v;
|
|
172
|
-
}
|
|
173
|
-
F = w.getDataItemPositionY(e, h, P, G), A = w.getDataItemPositionY(e, n, D, G), e.setRaw("point", { x: Y + (L - Y) / 2, y: F + (A - F) / 2 });
|
|
174
|
-
}
|
|
175
|
-
this._applyGraphicsStates(e, t), this._updateSeriesGraphics(e, o, Y, L, F, A, B, Z), Y < X && L < X || Y > y && L > y || F < b && A <= b || F >= C && A > C || Q(Y) || Q(F) ? this._toggleColumn(e, !1) : this._toggleColumn(e, !0);
|
|
176
|
-
let J = e.get("rangeGraphics");
|
|
177
|
-
J && k(J, (P) => {
|
|
178
|
-
this._updateSeriesGraphics(e, P, Y, L, F, A, B, Z);
|
|
179
|
-
});
|
|
180
|
-
} else
|
|
181
|
-
this._toggleColumn(e, !1);
|
|
182
|
-
}
|
|
183
|
-
_updateSeriesGraphics(e, t, s, o, i, n, l, d) {
|
|
184
|
-
const m = t.get("width"), x = t.get("height"), h = t.get("maxWidth"), u = t.get("maxHeight"), p = this.getPoint(s, i), _ = this.getPoint(o, n), g = e.get("point");
|
|
185
|
-
if (g) {
|
|
186
|
-
const a = this.getPoint(g.x, g.y);
|
|
187
|
-
g.x = a.x + this._x, g.y = a.y + this._y;
|
|
188
|
-
}
|
|
189
|
-
if (s = p.x, o = _.x, i = p.y, n = _.y, O(m)) {
|
|
190
|
-
const a = (o - s - m) / 2;
|
|
191
|
-
s += a, o -= a;
|
|
192
|
-
}
|
|
193
|
-
if (O(h) && h < Math.abs(o - s)) {
|
|
194
|
-
const a = (o - s - h) / 2;
|
|
195
|
-
s += a, o -= a;
|
|
196
|
-
}
|
|
197
|
-
if (O(x)) {
|
|
198
|
-
const a = (n - i - x) / 2;
|
|
199
|
-
i += a, n -= a;
|
|
200
|
-
}
|
|
201
|
-
if (O(u) && u < Math.abs(n - i)) {
|
|
202
|
-
const a = (n - i - u) / 2;
|
|
203
|
-
i += a, n -= a;
|
|
204
|
-
}
|
|
205
|
-
this.get("adjustBulletPosition") && (l && (o = Math.min(Math.max(0, o), this._pw), s = Math.min(Math.max(0, s), this._pw)), d && (i = Math.min(Math.max(0, i), this._ph), n = Math.min(Math.max(0, n), this._ph))), e.setRaw("left", s), e.setRaw("right", o), e.setRaw("top", i), e.setRaw("bottom", n), t.setPrivate("width", o - s), t.setPrivate("height", n - i), t.set("x", s), t.set("y", n - (n - i));
|
|
206
|
-
}
|
|
207
|
-
_handleDataSetChange() {
|
|
208
|
-
super._handleDataSetChange(), k(this._dataItems, (e) => {
|
|
209
|
-
this._toggleColumn(e, !1);
|
|
210
|
-
});
|
|
211
|
-
}
|
|
212
|
-
_applyGraphicsStates(e, t) {
|
|
213
|
-
const s = e.get("graphics"), o = s.states.lookup("dropFromOpen"), i = s.states.lookup("riseFromOpen"), n = s.states.lookup("dropFromPrevious"), l = s.states.lookup("riseFromPrevious");
|
|
214
|
-
if (o || n || i || l) {
|
|
215
|
-
const d = this.get("xAxis"), m = this.get("yAxis"), x = this.get("baseAxis");
|
|
216
|
-
let h, u, p;
|
|
217
|
-
x === d && m.isType("ValueAxis") ? (h = e.get(this._yOpenField), u = e.get(this._yField), p = t.get(this._yField)) : x === m && d.isType("ValueAxis") && (h = e.get(this._xOpenField), u = e.get(this._xField), p = t.get(this._xField)), O(h) && O(u) && (u < h ? o && o.apply() : i && i.apply(), O(p) && (u < p ? n && n.apply() : l && l.apply()));
|
|
218
|
-
}
|
|
219
|
-
}
|
|
220
|
-
/**
|
|
221
|
-
* @ignore
|
|
222
|
-
*/
|
|
223
|
-
disposeDataItem(e) {
|
|
224
|
-
super.disposeDataItem(e);
|
|
225
|
-
const t = e.get("graphics");
|
|
226
|
-
t && (this.columns.removeValue(t), t.dispose());
|
|
227
|
-
const s = e.get("rangeGraphics");
|
|
228
|
-
s && k(s, (o) => {
|
|
229
|
-
const i = o.getPrivate("list");
|
|
230
|
-
i && i.removeValue(o), o.dispose();
|
|
231
|
-
});
|
|
232
|
-
}
|
|
233
|
-
/**
|
|
234
|
-
* Hides series's data item.
|
|
235
|
-
*
|
|
236
|
-
* @param dataItem Data item
|
|
237
|
-
* @param duration Animation duration in milliseconds
|
|
238
|
-
* @return Promise
|
|
239
|
-
*/
|
|
240
|
-
hideDataItem(e, t) {
|
|
241
|
-
const s = Object.create(null, {
|
|
242
|
-
hideDataItem: { get: () => super.hideDataItem }
|
|
243
|
-
});
|
|
244
|
-
return $(this, void 0, void 0, function* () {
|
|
245
|
-
const o = [s.hideDataItem.call(this, e, t)], i = e.get("graphics");
|
|
246
|
-
i && o.push(i.hide(t));
|
|
247
|
-
const n = e.get("rangeGraphics");
|
|
248
|
-
n && k(n, (l) => {
|
|
249
|
-
o.push(l.hide(t));
|
|
250
|
-
}), yield Promise.all(o);
|
|
251
|
-
});
|
|
252
|
-
}
|
|
253
|
-
_toggleColumn(e, t) {
|
|
254
|
-
const s = e.get("graphics");
|
|
255
|
-
s && s.setPrivate("visible", t);
|
|
256
|
-
const o = e.get("rangeGraphics");
|
|
257
|
-
o && k(o, (n) => {
|
|
258
|
-
n.setPrivate("visible", t);
|
|
259
|
-
});
|
|
260
|
-
const i = e.bullets;
|
|
261
|
-
i && k(i, (n) => {
|
|
262
|
-
n.setPrivate("hidden", !t);
|
|
263
|
-
});
|
|
264
|
-
}
|
|
265
|
-
/**
|
|
266
|
-
* Shows series's data item.
|
|
267
|
-
*
|
|
268
|
-
* @param dataItem Data item
|
|
269
|
-
* @param duration Animation duration in milliseconds
|
|
270
|
-
* @return Promise
|
|
271
|
-
*/
|
|
272
|
-
showDataItem(e, t) {
|
|
273
|
-
const s = Object.create(null, {
|
|
274
|
-
showDataItem: { get: () => super.showDataItem }
|
|
275
|
-
});
|
|
276
|
-
return $(this, void 0, void 0, function* () {
|
|
277
|
-
const o = [s.showDataItem.call(this, e, t)], i = e.get("graphics");
|
|
278
|
-
i && o.push(i.show(t));
|
|
279
|
-
const n = e.get("rangeGraphics");
|
|
280
|
-
n && k(n, (l) => {
|
|
281
|
-
o.push(l.show(t));
|
|
282
|
-
}), yield Promise.all(o);
|
|
283
|
-
});
|
|
284
|
-
}
|
|
285
|
-
/**
|
|
286
|
-
* @ignore
|
|
287
|
-
*/
|
|
288
|
-
updateLegendMarker(e) {
|
|
289
|
-
let t = this.get("legendDataItem");
|
|
290
|
-
if (this.get("useLastColorForLegendMarker") && !e) {
|
|
291
|
-
const s = this.dataItems[this.endIndex() - 1];
|
|
292
|
-
s && (e = s);
|
|
293
|
-
}
|
|
294
|
-
if (t) {
|
|
295
|
-
let s = this.columns.template;
|
|
296
|
-
if (e) {
|
|
297
|
-
let i = e.get("graphics");
|
|
298
|
-
i && (s = i);
|
|
299
|
-
}
|
|
300
|
-
const o = t.get("markerRectangle");
|
|
301
|
-
if (o && !t.get("itemContainer").get("disabled")) {
|
|
302
|
-
const i = o.states.lookup("default");
|
|
303
|
-
k(K, (n) => {
|
|
304
|
-
const l = s.get(n, this.get(n));
|
|
305
|
-
o.set(n, l), i.set(n, l);
|
|
306
|
-
});
|
|
307
|
-
}
|
|
308
|
-
}
|
|
309
|
-
}
|
|
310
|
-
_getTooltipTarget(e) {
|
|
311
|
-
if (this.get("seriesTooltipTarget") == "bullet")
|
|
312
|
-
return super._getTooltipTarget(e);
|
|
313
|
-
let t = e.get("graphics");
|
|
314
|
-
return t || this;
|
|
315
|
-
}
|
|
316
|
-
}
|
|
317
|
-
Object.defineProperty(T, "className", {
|
|
318
|
-
enumerable: !0,
|
|
319
|
-
configurable: !0,
|
|
320
|
-
writable: !0,
|
|
321
|
-
value: "BaseColumnSeries"
|
|
322
|
-
});
|
|
323
|
-
Object.defineProperty(T, "classNames", {
|
|
324
|
-
enumerable: !0,
|
|
325
|
-
configurable: !0,
|
|
326
|
-
writable: !0,
|
|
327
|
-
value: se.classNames.concat([T.className])
|
|
328
|
-
});
|
|
329
|
-
class N extends W {
|
|
1
|
+
import { R as M, L, T as k, m as T, i as V, b as G, A as S, X as j, c as z, g as O, V as R, d as N, f as _, p as E } from "../../../AxisRendererY-kADUad00.js";
|
|
2
|
+
import { useThemeProps as H } from "@mui/material";
|
|
3
|
+
import { useRef as A, useLayoutEffect as W, useEffect as U } from "react";
|
|
4
|
+
import { X as Z, D as q } from "../../../DateAxis-CMum47iz.js";
|
|
5
|
+
import { C as F } from "../../../ColumnSeries-BTcqshjB.js";
|
|
6
|
+
class D extends M {
|
|
330
7
|
_beforeChanged() {
|
|
331
8
|
super._beforeChanged(), (this.isDirty("lowX0") || this.isDirty("lowY0") || this.isDirty("lowX1") || this.isDirty("lowY1") || this.isDirty("highX0") || this.isDirty("highX1") || this.isDirty("highY0") || this.isDirty("highY1")) && (this._clear = !0);
|
|
332
9
|
}
|
|
@@ -336,98 +13,28 @@ class N extends W {
|
|
|
336
13
|
e.moveTo(this.get("lowX0", 0), this.get("lowY0", 0)), e.lineTo(this.get("lowX1", 0), this.get("lowY1", 0)), e.moveTo(this.get("highX0", 0), this.get("highY0", 0)), e.lineTo(this.get("highX1", 0), this.get("highY1", 0));
|
|
337
14
|
}
|
|
338
15
|
}
|
|
339
|
-
Object.defineProperty(
|
|
16
|
+
Object.defineProperty(D, "className", {
|
|
340
17
|
enumerable: !0,
|
|
341
18
|
configurable: !0,
|
|
342
19
|
writable: !0,
|
|
343
20
|
value: "Candlestick"
|
|
344
21
|
});
|
|
345
|
-
Object.defineProperty(
|
|
346
|
-
enumerable: !0,
|
|
347
|
-
configurable: !0,
|
|
348
|
-
writable: !0,
|
|
349
|
-
value: W.classNames.concat([N.className])
|
|
350
|
-
});
|
|
351
|
-
class S extends T {
|
|
352
|
-
constructor() {
|
|
353
|
-
super(...arguments), Object.defineProperty(this, "allColumns", {
|
|
354
|
-
enumerable: !0,
|
|
355
|
-
configurable: !0,
|
|
356
|
-
writable: !0,
|
|
357
|
-
value: this.children.push(ie.new(this._root, {}))
|
|
358
|
-
}), Object.defineProperty(this, "allColumnsData", {
|
|
359
|
-
enumerable: !0,
|
|
360
|
-
configurable: !0,
|
|
361
|
-
writable: !0,
|
|
362
|
-
value: []
|
|
363
|
-
}), Object.defineProperty(this, "columns", {
|
|
364
|
-
enumerable: !0,
|
|
365
|
-
configurable: !0,
|
|
366
|
-
writable: !0,
|
|
367
|
-
value: this.addDisposer(new E(H.new({}), () => W._new(this._root, {
|
|
368
|
-
position: "absolute",
|
|
369
|
-
themeTags: U(this.columns.template.get("themeTags", []), ["series", "column"])
|
|
370
|
-
}, [this.columns.template])))
|
|
371
|
-
});
|
|
372
|
-
}
|
|
373
|
-
/**
|
|
374
|
-
* @ignore
|
|
375
|
-
*/
|
|
376
|
-
makeColumn(e, t) {
|
|
377
|
-
const s = t.make();
|
|
378
|
-
return this.get("turboMode") ? s.virtualParent = this.chart : this.mainContainer.children.push(s), s._setDataItem(e), t.push(s), s;
|
|
379
|
-
}
|
|
380
|
-
_processAxisRange(e) {
|
|
381
|
-
super._processAxisRange(e), e.columns = new E(H.new({}), () => W._new(this._root, {
|
|
382
|
-
position: "absolute",
|
|
383
|
-
themeTags: U(e.columns.template.get("themeTags", []), ["series", "column"])
|
|
384
|
-
}, [this.columns.template, e.columns.template]));
|
|
385
|
-
}
|
|
386
|
-
_beforeColumnsDraw() {
|
|
387
|
-
this.allColumnsData = [];
|
|
388
|
-
}
|
|
389
|
-
_afterColumnsDraw() {
|
|
390
|
-
this.get("turboMode") && this.allColumns.set("draw", (e) => {
|
|
391
|
-
e.clear(), k(this.allColumnsData, (t) => {
|
|
392
|
-
const s = t.width, o = t.height, i = t.x, n = t.y, l = t.stroke, d = t.fill, m = t.strokeWidth, x = t.strokeOpacity, h = t.fillOpacity;
|
|
393
|
-
e.beginFill(d, h), e.beginPath(), e.lineStyle(m, l, x), e.drawRect(i, n, s, o), e.endStroke(), e.endFill();
|
|
394
|
-
});
|
|
395
|
-
});
|
|
396
|
-
}
|
|
397
|
-
_updateSeriesGraphics(e, t, s, o, i, n, l, d) {
|
|
398
|
-
if (this.get("turboMode")) {
|
|
399
|
-
const m = t.get("stroke"), x = t.get("fillOpacity", 1), h = t.get("strokeOpacity", 1), u = t.get("strokeWidth", 1), p = t.get("fill"), _ = this.getPoint(s, i), g = this.getPoint(o, n), a = e.get("point");
|
|
400
|
-
if (a) {
|
|
401
|
-
const f = this.getPoint(a.x, a.y);
|
|
402
|
-
a.x = f.x + this._x, a.y = f.y + this._y;
|
|
403
|
-
}
|
|
404
|
-
s = _.x, o = g.x, i = _.y, n = g.y, e.setRaw("left", s), e.setRaw("right", o), e.setRaw("top", i), e.setRaw("bottom", n), this.allColumnsData.push({ width: o - s, height: n - i, x: s, y: i, stroke: m, fill: p, strokeWidth: u, strokeOpacity: h, fillOpacity: x });
|
|
405
|
-
} else
|
|
406
|
-
super._updateSeriesGraphics(e, t, s, o, i, n, l, d);
|
|
407
|
-
}
|
|
408
|
-
}
|
|
409
|
-
Object.defineProperty(S, "className", {
|
|
410
|
-
enumerable: !0,
|
|
411
|
-
configurable: !0,
|
|
412
|
-
writable: !0,
|
|
413
|
-
value: "ColumnSeries"
|
|
414
|
-
});
|
|
415
|
-
Object.defineProperty(S, "classNames", {
|
|
22
|
+
Object.defineProperty(D, "classNames", {
|
|
416
23
|
enumerable: !0,
|
|
417
24
|
configurable: !0,
|
|
418
25
|
writable: !0,
|
|
419
|
-
value:
|
|
26
|
+
value: M.classNames.concat([D.className])
|
|
420
27
|
});
|
|
421
|
-
class
|
|
28
|
+
class C extends F {
|
|
422
29
|
constructor() {
|
|
423
30
|
super(...arguments), Object.defineProperty(this, "columns", {
|
|
424
31
|
enumerable: !0,
|
|
425
32
|
configurable: !0,
|
|
426
33
|
writable: !0,
|
|
427
|
-
value: this.addDisposer(new
|
|
34
|
+
value: this.addDisposer(new L(k.new({
|
|
428
35
|
themeTags: ["autocolor"]
|
|
429
|
-
}), () =>
|
|
430
|
-
themeTags:
|
|
36
|
+
}), () => D._new(this._root, {
|
|
37
|
+
themeTags: T(this.columns.template.get("themeTags", []), ["candlestick", "series", "column"])
|
|
431
38
|
}, [this.columns.template])))
|
|
432
39
|
});
|
|
433
40
|
}
|
|
@@ -435,143 +42,143 @@ class z extends S {
|
|
|
435
42
|
* @ignore
|
|
436
43
|
*/
|
|
437
44
|
makeColumn(e, t) {
|
|
438
|
-
const
|
|
439
|
-
return this.get("turboMode") ?
|
|
440
|
-
}
|
|
441
|
-
_updateGraphics(e, t,
|
|
442
|
-
super._updateGraphics(e, t,
|
|
443
|
-
const
|
|
444
|
-
let
|
|
445
|
-
if (
|
|
446
|
-
let
|
|
447
|
-
|
|
448
|
-
let
|
|
449
|
-
|
|
45
|
+
const h = t.make();
|
|
46
|
+
return this.get("turboMode") ? h.virtualParent = this.chart : this.mainContainer.children.push(h), h._setDataItem(e), t.push(h), h;
|
|
47
|
+
}
|
|
48
|
+
_updateGraphics(e, t, h) {
|
|
49
|
+
super._updateGraphics(e, t, h);
|
|
50
|
+
const m = this.getRaw("xAxis"), d = this.getRaw("yAxis");
|
|
51
|
+
let Y = this.get("vcy", 1), n = this.get("vcx", 1), c, x, u, l, g, p, w, a, o = this.get("locationX", e.get("locationX", 0.5)), r = this.get("locationY", e.get("locationY", 0.5)), s = this.get("openLocationX", e.get("openLocationX", o)), i = this.get("openLocationY", e.get("openLocationY", r)), b;
|
|
52
|
+
if (h == 0) {
|
|
53
|
+
let y = d.getDataItemPositionY(e, this._yOpenField, 1, Y), f = d.getDataItemPositionY(e, this._yField, 1, Y);
|
|
54
|
+
l = d.getDataItemPositionY(e, this._yLowField, 1, Y), a = d.getDataItemPositionY(e, this._yHighField, 1, Y), w = Math.max(y, f), u = Math.min(y, f);
|
|
55
|
+
let X = this._aLocationX0 + s - 0.5, v = this._aLocationX1 + o - 0.5;
|
|
56
|
+
c = m.getDataItemPositionX(e, this._xField, X + (v - X) / 2, n), x = c, g = c, p = c, b = "vertical";
|
|
450
57
|
} else {
|
|
451
|
-
let
|
|
452
|
-
|
|
453
|
-
let
|
|
454
|
-
|
|
58
|
+
let y = m.getDataItemPositionX(e, this._xOpenField, 1, n), f = m.getDataItemPositionX(e, this._xField, 1, n);
|
|
59
|
+
x = m.getDataItemPositionX(e, this._xLowField, 1, n), p = m.getDataItemPositionX(e, this._xHighField, 1, n), g = Math.max(y, f), c = Math.min(y, f);
|
|
60
|
+
let X = this._aLocationY0 + i - 0.5, v = this._aLocationY1 + r - 0.5;
|
|
61
|
+
u = d.getDataItemPositionY(e, this._yField, X + (v - X) / 2, Y), l = u, w = u, a = u, b = "horizontal";
|
|
455
62
|
}
|
|
456
|
-
this._updateCandleGraphics(e,
|
|
63
|
+
this._updateCandleGraphics(e, c, x, u, l, g, p, w, a, b);
|
|
457
64
|
}
|
|
458
|
-
_updateCandleGraphics(e, t,
|
|
459
|
-
let
|
|
460
|
-
if (
|
|
461
|
-
let
|
|
65
|
+
_updateCandleGraphics(e, t, h, m, d, Y, n, c, x, u) {
|
|
66
|
+
let l = e.get("graphics");
|
|
67
|
+
if (l) {
|
|
68
|
+
let g = this.getPoint(t, m), p = this.getPoint(h, d), w = this.getPoint(Y, c), a = this.getPoint(n, x);
|
|
462
69
|
if (this.get("turboMode")) {
|
|
463
|
-
const
|
|
464
|
-
|
|
70
|
+
const o = this.allColumnsData[this.allColumnsData.length - 1];
|
|
71
|
+
o.lowX0 = g.x, o.lowY0 = g.y, o.lowX1 = p.x, o.lowY1 = p.y, o.highX0 = w.x, o.highY0 = w.y, o.highX1 = a.x, o.highY1 = a.y;
|
|
465
72
|
} else {
|
|
466
|
-
let
|
|
467
|
-
|
|
468
|
-
let
|
|
469
|
-
|
|
470
|
-
|
|
73
|
+
let o = l.x(), r = l.y();
|
|
74
|
+
l.set("lowX0", g.x - o), l.set("lowY0", g.y - r), l.set("lowX1", p.x - o), l.set("lowY1", p.y - r), l.set("highX0", w.x - o), l.set("highY0", w.y - r), l.set("highX1", a.x - o), l.set("highY1", a.y - r), l.set("orientation", u);
|
|
75
|
+
let s = e.get("rangeGraphics");
|
|
76
|
+
s && V(s, (i) => {
|
|
77
|
+
i.set("lowX0", g.x - o), i.set("lowY0", g.y - r), i.set("lowX1", p.x - o), i.set("lowY1", p.y - r), i.set("highX0", w.x - o), i.set("highY0", w.y - r), i.set("highX1", a.x - o), i.set("highY1", a.y - r), i.set("orientation", u);
|
|
471
78
|
});
|
|
472
79
|
}
|
|
473
80
|
}
|
|
474
81
|
}
|
|
475
82
|
_afterColumnsDraw() {
|
|
476
83
|
this.get("turboMode") && this.allColumns.set("draw", (e) => {
|
|
477
|
-
e.clear(),
|
|
84
|
+
e.clear(), V(this.allColumnsData, (t) => {
|
|
478
85
|
e.beginPath();
|
|
479
|
-
const
|
|
480
|
-
e.beginFill(
|
|
86
|
+
const h = t.width, m = t.height, d = t.x, Y = t.y, n = t.stroke, c = t.fill, x = t.strokeWidth, u = t.strokeOpacity, l = t.fillOpacity, g = t.lowX0, p = t.lowY0, w = t.lowX1, a = t.lowY1, o = t.highX0, r = t.highY0, s = t.highX1, i = t.highY1;
|
|
87
|
+
e.beginFill(c, l), e.beginPath(), e.lineStyle(x, n, u), e.drawRect(d, Y, h, m), e.moveTo(g, p), e.lineTo(w, a), e.moveTo(o, r), e.lineTo(s, i), e.endStroke(), e.endFill();
|
|
481
88
|
});
|
|
482
89
|
});
|
|
483
90
|
}
|
|
484
91
|
_processAxisRange(e) {
|
|
485
|
-
super._processAxisRange(e), e.columns = new
|
|
486
|
-
themeTags:
|
|
92
|
+
super._processAxisRange(e), e.columns = new L(k.new({}), () => D._new(this._root, {
|
|
93
|
+
themeTags: T(e.columns.template.get("themeTags", []), ["candlestick", "series", "column"])
|
|
487
94
|
}, [this.columns.template, e.columns.template]));
|
|
488
95
|
}
|
|
489
96
|
}
|
|
490
|
-
Object.defineProperty(
|
|
97
|
+
Object.defineProperty(C, "className", {
|
|
491
98
|
enumerable: !0,
|
|
492
99
|
configurable: !0,
|
|
493
100
|
writable: !0,
|
|
494
101
|
value: "CandlestickSeries"
|
|
495
102
|
});
|
|
496
|
-
Object.defineProperty(
|
|
103
|
+
Object.defineProperty(C, "classNames", {
|
|
497
104
|
enumerable: !0,
|
|
498
105
|
configurable: !0,
|
|
499
106
|
writable: !0,
|
|
500
|
-
value:
|
|
107
|
+
value: F.classNames.concat([C.className])
|
|
501
108
|
});
|
|
502
|
-
const
|
|
503
|
-
const e =
|
|
504
|
-
props:
|
|
109
|
+
const $ = (P) => {
|
|
110
|
+
const e = H({
|
|
111
|
+
props: P,
|
|
505
112
|
name: "MuiCandlestickChart"
|
|
506
113
|
}), {
|
|
507
114
|
data: t,
|
|
508
|
-
seriesName:
|
|
509
|
-
height:
|
|
510
|
-
width:
|
|
511
|
-
chartId:
|
|
512
|
-
showVolume:
|
|
513
|
-
risingColor:
|
|
514
|
-
fallingColor:
|
|
515
|
-
loading:
|
|
516
|
-
emptyMessage:
|
|
517
|
-
sx:
|
|
115
|
+
seriesName: h,
|
|
116
|
+
height: m = "500px",
|
|
117
|
+
width: d = "100%",
|
|
118
|
+
chartId: Y = "candlestick-chart",
|
|
119
|
+
showVolume: n = !1,
|
|
120
|
+
risingColor: c = "#00b050",
|
|
121
|
+
fallingColor: x = "#ff3b30",
|
|
122
|
+
loading: u = !1,
|
|
123
|
+
emptyMessage: l = "No data available",
|
|
124
|
+
sx: g,
|
|
518
125
|
...p
|
|
519
|
-
} = e,
|
|
126
|
+
} = e, w = {
|
|
520
127
|
...e,
|
|
521
|
-
height:
|
|
522
|
-
width:
|
|
523
|
-
chartId:
|
|
524
|
-
showVolume:
|
|
525
|
-
risingColor:
|
|
526
|
-
fallingColor:
|
|
527
|
-
loading:
|
|
528
|
-
emptyMessage:
|
|
529
|
-
},
|
|
530
|
-
return
|
|
531
|
-
if (!
|
|
532
|
-
const
|
|
533
|
-
|
|
534
|
-
const
|
|
535
|
-
|
|
128
|
+
height: m,
|
|
129
|
+
width: d,
|
|
130
|
+
chartId: Y,
|
|
131
|
+
showVolume: n,
|
|
132
|
+
risingColor: c,
|
|
133
|
+
fallingColor: x,
|
|
134
|
+
loading: u,
|
|
135
|
+
emptyMessage: l
|
|
136
|
+
}, a = A(null), o = A(null), r = A(null);
|
|
137
|
+
return W(() => {
|
|
138
|
+
if (!r.current) return;
|
|
139
|
+
const s = G.new(r.current);
|
|
140
|
+
o.current = s, s.setThemes([S.new(s)]);
|
|
141
|
+
const i = s.container.children.push(
|
|
142
|
+
j.new(s, {
|
|
536
143
|
panX: !0,
|
|
537
144
|
panY: !0,
|
|
538
145
|
wheelX: "panX",
|
|
539
146
|
wheelY: "zoomX",
|
|
540
147
|
pinchZoomX: !0,
|
|
541
|
-
layout:
|
|
148
|
+
layout: s.verticalLayout
|
|
542
149
|
})
|
|
543
150
|
);
|
|
544
|
-
|
|
151
|
+
a.current = i, i.set(
|
|
545
152
|
"cursor",
|
|
546
|
-
|
|
153
|
+
Z.new(s, {
|
|
547
154
|
behavior: "zoomX"
|
|
548
155
|
})
|
|
549
156
|
).lineY.set("visible", !1);
|
|
550
|
-
const
|
|
551
|
-
|
|
157
|
+
const b = i.xAxes.push(
|
|
158
|
+
q.new(s, {
|
|
552
159
|
maxDeviation: 0.3,
|
|
553
160
|
groupData: !0,
|
|
554
161
|
baseInterval: { timeUnit: "day", count: 1 },
|
|
555
|
-
renderer:
|
|
162
|
+
renderer: z.new(s, {
|
|
556
163
|
minorGridEnabled: !0
|
|
557
164
|
}),
|
|
558
|
-
tooltip:
|
|
165
|
+
tooltip: O.new(s, {})
|
|
559
166
|
})
|
|
560
|
-
),
|
|
561
|
-
|
|
562
|
-
renderer:
|
|
167
|
+
), y = i.yAxes.push(
|
|
168
|
+
R.new(s, {
|
|
169
|
+
renderer: N.new(s, {})
|
|
563
170
|
})
|
|
564
|
-
),
|
|
565
|
-
|
|
566
|
-
name:
|
|
567
|
-
xAxis:
|
|
568
|
-
yAxis:
|
|
171
|
+
), f = i.series.push(
|
|
172
|
+
C.new(s, {
|
|
173
|
+
name: h || "Price",
|
|
174
|
+
xAxis: b,
|
|
175
|
+
yAxis: y,
|
|
569
176
|
valueXField: "date",
|
|
570
177
|
openValueYField: "open",
|
|
571
178
|
highValueYField: "high",
|
|
572
179
|
lowValueYField: "low",
|
|
573
180
|
valueYField: "close",
|
|
574
|
-
tooltip:
|
|
181
|
+
tooltip: O.new(s, {
|
|
575
182
|
labelText: `
|
|
576
183
|
Open: {openValueY}
|
|
577
184
|
High: {highValueY}
|
|
@@ -582,61 +189,61 @@ const xe = (j) => {
|
|
|
582
189
|
})
|
|
583
190
|
})
|
|
584
191
|
);
|
|
585
|
-
|
|
586
|
-
fill:
|
|
587
|
-
stroke:
|
|
588
|
-
}),
|
|
589
|
-
fill:
|
|
590
|
-
stroke:
|
|
192
|
+
f.columns.template.states.create("riseFromPrevious", {
|
|
193
|
+
fill: _(c),
|
|
194
|
+
stroke: _(c)
|
|
195
|
+
}), f.columns.template.states.create("dropFromPrevious", {
|
|
196
|
+
fill: _(x),
|
|
197
|
+
stroke: _(x)
|
|
591
198
|
});
|
|
592
|
-
let
|
|
593
|
-
return
|
|
594
|
-
|
|
595
|
-
renderer:
|
|
199
|
+
let X = null, v = null;
|
|
200
|
+
return n && (v = i.yAxes.push(
|
|
201
|
+
R.new(s, {
|
|
202
|
+
renderer: N.new(s, {
|
|
596
203
|
opposite: !0
|
|
597
204
|
}),
|
|
598
205
|
numberFormat: "#a"
|
|
599
206
|
})
|
|
600
|
-
),
|
|
601
|
-
|
|
207
|
+
), X = i.series.push(
|
|
208
|
+
F.new(s, {
|
|
602
209
|
name: "Volume",
|
|
603
|
-
xAxis:
|
|
604
|
-
yAxis:
|
|
210
|
+
xAxis: b,
|
|
211
|
+
yAxis: v,
|
|
605
212
|
valueYField: "volume",
|
|
606
213
|
valueXField: "date",
|
|
607
|
-
fill:
|
|
608
|
-
stroke:
|
|
214
|
+
fill: _("#2962ff"),
|
|
215
|
+
stroke: _("#2962ff"),
|
|
609
216
|
opacity: 0.6
|
|
610
217
|
})
|
|
611
|
-
),
|
|
612
|
-
width:
|
|
613
|
-
})),
|
|
614
|
-
|
|
218
|
+
), X.columns.template.setAll({
|
|
219
|
+
width: E(80)
|
|
220
|
+
})), f.data.setAll(t), n && X && X.data.setAll(t), i.appear(1e3), f.appear(1e3), () => {
|
|
221
|
+
s.dispose();
|
|
615
222
|
};
|
|
616
|
-
}, []),
|
|
617
|
-
if (
|
|
618
|
-
const
|
|
223
|
+
}, []), U(() => {
|
|
224
|
+
if (a.current && o.current) {
|
|
225
|
+
const s = a.current.series.getIndex(
|
|
619
226
|
0
|
|
620
|
-
),
|
|
621
|
-
|
|
227
|
+
), i = n ? a.current.series.getIndex(1) : null;
|
|
228
|
+
s == null || s.data.setAll(t), i == null || i.data.setAll(t);
|
|
622
229
|
}
|
|
623
|
-
}, [t,
|
|
624
|
-
chartDivRef:
|
|
230
|
+
}, [t, n]), {
|
|
231
|
+
chartDivRef: r,
|
|
625
232
|
data: t,
|
|
626
|
-
seriesName:
|
|
627
|
-
height:
|
|
628
|
-
width:
|
|
629
|
-
chartId:
|
|
630
|
-
showVolume:
|
|
631
|
-
risingColor:
|
|
632
|
-
fallingColor:
|
|
633
|
-
loading:
|
|
634
|
-
emptyMessage:
|
|
635
|
-
sx:
|
|
233
|
+
seriesName: h,
|
|
234
|
+
height: m,
|
|
235
|
+
width: d,
|
|
236
|
+
chartId: Y,
|
|
237
|
+
showVolume: n,
|
|
238
|
+
risingColor: c,
|
|
239
|
+
fallingColor: x,
|
|
240
|
+
loading: u,
|
|
241
|
+
emptyMessage: l,
|
|
242
|
+
sx: g,
|
|
636
243
|
other: p,
|
|
637
|
-
ownerState:
|
|
244
|
+
ownerState: w
|
|
638
245
|
};
|
|
639
246
|
};
|
|
640
247
|
export {
|
|
641
|
-
|
|
248
|
+
$ as useCandlestickChartLogic
|
|
642
249
|
};
|