tvcharts 0.6.63 → 0.6.65
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/echarts.js +926 -131
- package/dist/echarts.js.map +3 -3
- package/index.js +2 -2
- package/lib/chart/arrowsPlot/ArrowsPlotSeries.js +5 -23
- package/lib/chart/barPlot/BarPath.js +68 -0
- package/lib/chart/barPlot/BarPlotSeries.js +135 -0
- package/lib/chart/barPlot/BarPlotView.js +109 -0
- package/lib/chart/barPlot/barPlotLayout.js +149 -0
- package/lib/chart/barPlot/install.js +51 -0
- package/lib/chart/candlePlot/CandlePlotSeries.js +140 -0
- package/lib/chart/candlePlot/CandlePlotView.js +125 -0
- package/lib/chart/candlePlot/NormalBoxPath.js +65 -0
- package/lib/chart/candlePlot/WickPath.js +57 -0
- package/lib/chart/candlePlot/candlePlotLayout.js +194 -0
- package/lib/chart/candlePlot/install.js +51 -0
- package/lib/component/dataZoom/AxisProxy.js +2 -1
- package/lib/component/dataZoom/DataZoomModel.js +2 -2
- package/lib/component/marker/MarkLabelView.js +5 -7
- package/lib/coord/cartesian/Cartesian2D.js +2 -1
- package/lib/core/echarts.js +0 -4
- package/lib/export/charts.js +2 -0
- package/lib/model/Global.js +3 -1
- package/lib/model/Series.js +7 -1
- package/lib/util/seriesType.js +34 -0
- package/lib/util/states.js +5 -4
- package/package.json +1 -1
- package/types/dist/charts.d.ts +1 -1
- package/types/dist/components.d.ts +1 -1
- package/types/dist/renderers.d.ts +1 -1
- package/types/dist/shared.d.ts +10 -6
- package/types/src/chart/arrowsPlot/ArrowsPlotSeries.d.ts +0 -5
- package/types/src/chart/barPlot/BarPath.d.ts +17 -0
- package/types/src/chart/barPlot/BarPlotSeries.d.ts +48 -0
- package/types/src/chart/barPlot/BarPlotView.d.ts +16 -0
- package/types/src/chart/barPlot/barPlotLayout.d.ts +14 -0
- package/types/src/chart/barPlot/install.d.ts +2 -0
- package/types/src/chart/candlePlot/CandlePlotSeries.d.ts +54 -0
- package/types/src/chart/candlePlot/CandlePlotView.d.ts +16 -0
- package/types/src/chart/candlePlot/NormalBoxPath.d.ts +16 -0
- package/types/src/chart/candlePlot/WickPath.d.ts +15 -0
- package/types/src/chart/candlePlot/candlePlotLayout.d.ts +14 -0
- package/types/src/chart/candlePlot/install.d.ts +2 -0
- package/types/src/export/charts.d.ts +2 -0
- package/types/src/util/seriesType.d.ts +3 -0
package/dist/echarts.js
CHANGED
|
@@ -11434,6 +11434,16 @@ var setCommonECData = (seriesIndex, dataType, dataIdx, el) => {
|
|
|
11434
11434
|
}
|
|
11435
11435
|
};
|
|
11436
11436
|
|
|
11437
|
+
// src/util/seriesType.ts
|
|
11438
|
+
var candleArr = ["candlestick", "candlePlot", "barPlot"];
|
|
11439
|
+
function isCandle(type) {
|
|
11440
|
+
return candleArr.includes(type);
|
|
11441
|
+
}
|
|
11442
|
+
var plotsArr = ["labels", "linesPlot", "charPlot", "arrowsPlot"];
|
|
11443
|
+
function isPlot(type) {
|
|
11444
|
+
return plotsArr.includes(type);
|
|
11445
|
+
}
|
|
11446
|
+
|
|
11437
11447
|
// src/chart/helper/createRenderPlanner.ts
|
|
11438
11448
|
function createRenderPlanner() {
|
|
11439
11449
|
const inner24 = makeInner();
|
|
@@ -11461,10 +11471,10 @@ var candlestickVisual = {
|
|
|
11461
11471
|
plan: createRenderPlanner(),
|
|
11462
11472
|
performRawSeries: true,
|
|
11463
11473
|
reset: function(seriesModel, ecModel) {
|
|
11464
|
-
function
|
|
11474
|
+
function getColor3(sign, model) {
|
|
11465
11475
|
return model.get(sign > 0 ? positiveColorQuery : negativeColorQuery);
|
|
11466
11476
|
}
|
|
11467
|
-
function
|
|
11477
|
+
function getBorderColor2(sign, model) {
|
|
11468
11478
|
return model.get(sign === 0 ? dojiBorderColorQuery : sign > 0 ? positiveBorderColorQuery : negativeBorderColorQuery);
|
|
11469
11479
|
}
|
|
11470
11480
|
if (ecModel.isSeriesFiltered(seriesModel)) {
|
|
@@ -11478,8 +11488,8 @@ var candlestickVisual = {
|
|
|
11478
11488
|
const itemModel = data.getItemModel(dataIndex);
|
|
11479
11489
|
const sign = data.getItemLayout(dataIndex).sign;
|
|
11480
11490
|
const style = itemModel.getItemStyle();
|
|
11481
|
-
style.fill =
|
|
11482
|
-
style.stroke =
|
|
11491
|
+
style.fill = getColor3(sign, itemModel);
|
|
11492
|
+
style.stroke = getBorderColor2(sign, itemModel) || style.fill;
|
|
11483
11493
|
const existsStyle = data.ensureUniqueItemVisual(dataIndex, "style");
|
|
11484
11494
|
extend(existsStyle, style);
|
|
11485
11495
|
}
|
|
@@ -11947,8 +11957,8 @@ function getSeriesPointData(ecModel, payload = {}) {
|
|
|
11947
11957
|
index = Math.min(lastIndex, index);
|
|
11948
11958
|
let values = isRaw ? data.getValuesByRawIndex(index) : data.getValues(index);
|
|
11949
11959
|
let color2 = data.getItemVisual(index, "style")?.fill;
|
|
11950
|
-
const isCandlesStick = seriesModel.subType
|
|
11951
|
-
const dim =
|
|
11960
|
+
const isCandlesStick = isCandle(seriesModel.subType);
|
|
11961
|
+
const dim = isCandlesStick ? "close" : "y";
|
|
11952
11962
|
const fnKey = isRaw ? "getByRawIndex" : "get";
|
|
11953
11963
|
if (isCandlesStick) {
|
|
11954
11964
|
const closeValue = data[fnKey]("close", index);
|
|
@@ -11959,7 +11969,7 @@ function getSeriesPointData(ecModel, payload = {}) {
|
|
|
11959
11969
|
if (fill) {
|
|
11960
11970
|
color2 = fill;
|
|
11961
11971
|
}
|
|
11962
|
-
} else if (
|
|
11972
|
+
} else if (isPlot(seriesModel.subType)) {
|
|
11963
11973
|
const isLinesPlot = seriesModel.subType === "linesPlot";
|
|
11964
11974
|
const dataItem = data.getItemModel(index, isRaw);
|
|
11965
11975
|
const fill = dataItem.get([isLinesPlot ? "lineStyle" : "itemStyle", "color"]);
|
|
@@ -16283,6 +16293,9 @@ var BUILTIN_CHARTS_MAP = {
|
|
|
16283
16293
|
labels: "LabelsChart",
|
|
16284
16294
|
hlines: "HLinesChart",
|
|
16285
16295
|
fills: "FillsChart",
|
|
16296
|
+
arrowsPlot: "ArrowsPlotChart",
|
|
16297
|
+
candlePlot: "CandlePlotChart",
|
|
16298
|
+
barPlot: "BarPlotChart",
|
|
16286
16299
|
bgcolor: "BgColorChart",
|
|
16287
16300
|
heatmap: "HeatmapChart",
|
|
16288
16301
|
pictorialBar: "PictorialBarChart",
|
|
@@ -16380,7 +16393,7 @@ var GlobalModel = class extends Model_default {
|
|
|
16380
16393
|
return;
|
|
16381
16394
|
}
|
|
16382
16395
|
if (!Component_default.hasClass(mainType)) {
|
|
16383
|
-
option[mainType] = option[mainType] == null ? clone(componentOption) : merge(option[mainType], componentOption, true);
|
|
16396
|
+
option[mainType] = option[mainType] == null && ~mainType.indexOf("custom") ? clone(componentOption) : merge(option[mainType], componentOption, true);
|
|
16384
16397
|
} else if (mainType) {
|
|
16385
16398
|
newCmptTypes.push(mainType);
|
|
16386
16399
|
newCmptTypeMap.set(mainType, true);
|
|
@@ -38626,7 +38639,7 @@ var Cartesian2D = class extends Cartesian_default {
|
|
|
38626
38639
|
const seriesModal = this.seriesModal;
|
|
38627
38640
|
if (seriesModal) {
|
|
38628
38641
|
const seriesData = seriesModal.getData();
|
|
38629
|
-
const dim = seriesModal.subType
|
|
38642
|
+
const dim = isCandle(seriesModal.subType) ? "close" : "y";
|
|
38630
38643
|
baseValue = seriesData.get(dim, 0);
|
|
38631
38644
|
}
|
|
38632
38645
|
return baseValue;
|
|
@@ -49289,7 +49302,7 @@ var GaugeView2 = class extends Chart_default {
|
|
|
49289
49302
|
}
|
|
49290
49303
|
sectors.reverse();
|
|
49291
49304
|
each(sectors, (sector) => group.add(sector));
|
|
49292
|
-
const
|
|
49305
|
+
const getColor3 = function(percent) {
|
|
49293
49306
|
if (percent <= 0) {
|
|
49294
49307
|
return colorList[0][1];
|
|
49295
49308
|
}
|
|
@@ -49301,12 +49314,12 @@ var GaugeView2 = class extends Chart_default {
|
|
|
49301
49314
|
}
|
|
49302
49315
|
return colorList[i - 1][1];
|
|
49303
49316
|
};
|
|
49304
|
-
this._renderTicks(seriesModel, ecModel, api2,
|
|
49305
|
-
this._renderTitleAndDetail(seriesModel, ecModel, api2,
|
|
49317
|
+
this._renderTicks(seriesModel, ecModel, api2, getColor3, posInfo, startAngle, endAngle, clockwise, axisLineWidth);
|
|
49318
|
+
this._renderTitleAndDetail(seriesModel, ecModel, api2, getColor3, posInfo);
|
|
49306
49319
|
this._renderAnchor(seriesModel, posInfo);
|
|
49307
|
-
this._renderPointer(seriesModel, ecModel, api2,
|
|
49320
|
+
this._renderPointer(seriesModel, ecModel, api2, getColor3, posInfo, startAngle, endAngle, clockwise, axisLineWidth);
|
|
49308
49321
|
}
|
|
49309
|
-
_renderTicks(seriesModel, ecModel, api2,
|
|
49322
|
+
_renderTicks(seriesModel, ecModel, api2, getColor3, posInfo, startAngle, endAngle, clockwise, axisLineWidth) {
|
|
49310
49323
|
const group = this.group;
|
|
49311
49324
|
const cx = posInfo.cx;
|
|
49312
49325
|
const cy = posInfo.cy;
|
|
@@ -49345,7 +49358,7 @@ var GaugeView2 = class extends Chart_default {
|
|
|
49345
49358
|
});
|
|
49346
49359
|
if (splitLineStyle.stroke === "auto") {
|
|
49347
49360
|
splitLine.setStyle({
|
|
49348
|
-
stroke:
|
|
49361
|
+
stroke: getColor3(i / splitNumber)
|
|
49349
49362
|
});
|
|
49350
49363
|
}
|
|
49351
49364
|
group.add(splitLine);
|
|
@@ -49353,7 +49366,7 @@ var GaugeView2 = class extends Chart_default {
|
|
|
49353
49366
|
if (labelModel.get("show")) {
|
|
49354
49367
|
const distance2 = labelModel.get("distance") + splitLineDistance;
|
|
49355
49368
|
const label = formatLabel(round(i / splitNumber * (maxVal - minVal) + minVal), labelModel.get("formatter"));
|
|
49356
|
-
const autoColor =
|
|
49369
|
+
const autoColor = getColor3(i / splitNumber);
|
|
49357
49370
|
const textStyleX = unitX * (r - splitLineLen - distance2) + cx;
|
|
49358
49371
|
const textStyleY = unitY * (r - splitLineLen - distance2) + cy;
|
|
49359
49372
|
const rotateType = labelModel.get("rotate");
|
|
@@ -49417,7 +49430,7 @@ var GaugeView2 = class extends Chart_default {
|
|
|
49417
49430
|
});
|
|
49418
49431
|
if (tickLineStyle.stroke === "auto") {
|
|
49419
49432
|
tickLine.setStyle({
|
|
49420
|
-
stroke:
|
|
49433
|
+
stroke: getColor3((i + j / subSplitNumber) / splitNumber)
|
|
49421
49434
|
});
|
|
49422
49435
|
}
|
|
49423
49436
|
group.add(tickLine);
|
|
@@ -49429,7 +49442,7 @@ var GaugeView2 = class extends Chart_default {
|
|
|
49429
49442
|
}
|
|
49430
49443
|
}
|
|
49431
49444
|
}
|
|
49432
|
-
_renderPointer(seriesModel, ecModel, api2,
|
|
49445
|
+
_renderPointer(seriesModel, ecModel, api2, getColor3, posInfo, startAngle, endAngle, clockwise, axisLineWidth) {
|
|
49433
49446
|
const group = this.group;
|
|
49434
49447
|
const oldData = this._data;
|
|
49435
49448
|
const oldProgressData = this._progressEls;
|
|
@@ -49569,7 +49582,7 @@ var GaugeView2 = class extends Chart_default {
|
|
|
49569
49582
|
}
|
|
49570
49583
|
pointer.setStyle(itemModel.getModel(["pointer", "itemStyle"]).getItemStyle());
|
|
49571
49584
|
if (pointer.style.fill === "auto") {
|
|
49572
|
-
pointer.setStyle("fill",
|
|
49585
|
+
pointer.setStyle("fill", getColor3(linearMap(data.get(valueDim, idx), valueExtent, [0, 1], true)));
|
|
49573
49586
|
}
|
|
49574
49587
|
pointer.z2EmphasisLift = 0;
|
|
49575
49588
|
setStatesStylesFromModel(pointer, itemModel);
|
|
@@ -49601,7 +49614,7 @@ var GaugeView2 = class extends Chart_default {
|
|
|
49601
49614
|
this.group.add(anchor);
|
|
49602
49615
|
}
|
|
49603
49616
|
}
|
|
49604
|
-
_renderTitleAndDetail(seriesModel, ecModel, api2,
|
|
49617
|
+
_renderTitleAndDetail(seriesModel, ecModel, api2, getColor3, posInfo) {
|
|
49605
49618
|
const data = seriesModel.getData();
|
|
49606
49619
|
const valueDim = data.mapDimension("value");
|
|
49607
49620
|
const minVal = +seriesModel.get("min");
|
|
@@ -49626,7 +49639,7 @@ var GaugeView2 = class extends Chart_default {
|
|
|
49626
49639
|
const itemModel = data.getItemModel(idx);
|
|
49627
49640
|
const value = data.get(valueDim, idx);
|
|
49628
49641
|
const itemGroup = new Group_default();
|
|
49629
|
-
const autoColor =
|
|
49642
|
+
const autoColor = getColor3(linearMap(value, [minVal, maxVal], [0, 1], true));
|
|
49630
49643
|
const itemTitleModel = itemModel.getModel("title");
|
|
49631
49644
|
if (itemTitleModel.get("show")) {
|
|
49632
49645
|
const titleOffsetCenter = itemTitleModel.get("offsetCenter");
|
|
@@ -56400,7 +56413,8 @@ MineLinesSeriesModel.defaultOption = {
|
|
|
56400
56413
|
},
|
|
56401
56414
|
large: true,
|
|
56402
56415
|
largeThreshold: 600,
|
|
56403
|
-
clip: true
|
|
56416
|
+
clip: true,
|
|
56417
|
+
statusLineInvisible: true
|
|
56404
56418
|
};
|
|
56405
56419
|
var MineLinesSeries_default = MineLinesSeriesModel;
|
|
56406
56420
|
|
|
@@ -56628,7 +56642,8 @@ LineFillsSeriesModel.defaultOption = {
|
|
|
56628
56642
|
large: true,
|
|
56629
56643
|
largeThreshold: 600,
|
|
56630
56644
|
clip: true,
|
|
56631
|
-
notFilterData: true
|
|
56645
|
+
notFilterData: true,
|
|
56646
|
+
statusLineInvisible: true
|
|
56632
56647
|
};
|
|
56633
56648
|
var LineFillsSeries_default = LineFillsSeriesModel;
|
|
56634
56649
|
|
|
@@ -56901,7 +56916,8 @@ BoxesSeriesModel.defaultOption = {
|
|
|
56901
56916
|
},
|
|
56902
56917
|
large: true,
|
|
56903
56918
|
largeThreshold: 600,
|
|
56904
|
-
clip: true
|
|
56919
|
+
clip: true,
|
|
56920
|
+
statusLineInvisible: true
|
|
56905
56921
|
};
|
|
56906
56922
|
var BoxesSeries_default = BoxesSeriesModel;
|
|
56907
56923
|
|
|
@@ -57164,11 +57180,9 @@ var CharPlotView2 = class extends Chart_default {
|
|
|
57164
57180
|
textGroup.add(el);
|
|
57165
57181
|
});
|
|
57166
57182
|
const location = seriesModel.get("location");
|
|
57167
|
-
let vAlign = "
|
|
57183
|
+
let vAlign = "middle";
|
|
57168
57184
|
if (["abovebar", "bottom", "absolute"].includes(location)) {
|
|
57169
57185
|
vAlign = "bottom";
|
|
57170
|
-
} else if (location === "belowbar" || location === "top") {
|
|
57171
|
-
return fontSize;
|
|
57172
57186
|
}
|
|
57173
57187
|
each(textList, function(item) {
|
|
57174
57188
|
const el = new Text_default({
|
|
@@ -57278,7 +57292,7 @@ var CharPlotLayout = {
|
|
|
57278
57292
|
continue;
|
|
57279
57293
|
}
|
|
57280
57294
|
const itemModel = data.getItemModel(i);
|
|
57281
|
-
const {color: color2,
|
|
57295
|
+
const {color: color2, textcolor} = itemModel.get("itemStyle");
|
|
57282
57296
|
const point = coordSys.dataToPoint(tmpIn);
|
|
57283
57297
|
const x = point[0];
|
|
57284
57298
|
const y = price ?? point[1] + distance2;
|
|
@@ -57289,7 +57303,7 @@ var CharPlotLayout = {
|
|
|
57289
57303
|
textColor: color2
|
|
57290
57304
|
});
|
|
57291
57305
|
}
|
|
57292
|
-
const textColor =
|
|
57306
|
+
const textColor = textcolor || color2;
|
|
57293
57307
|
if (text && textColor) {
|
|
57294
57308
|
textList.push({
|
|
57295
57309
|
x,
|
|
@@ -57316,6 +57330,781 @@ function install29(registers) {
|
|
|
57316
57330
|
registers.registerLayout(CharPlotLayout_default);
|
|
57317
57331
|
}
|
|
57318
57332
|
|
|
57333
|
+
// src/chart/candlePlot/NormalBoxPath.ts
|
|
57334
|
+
var NormalBoxPathShape2 = class {
|
|
57335
|
+
};
|
|
57336
|
+
var NormalBoxPath2 = class extends Path_default {
|
|
57337
|
+
constructor(opts) {
|
|
57338
|
+
super(opts);
|
|
57339
|
+
this.type = "normalCandlePlotBox";
|
|
57340
|
+
}
|
|
57341
|
+
getDefaultShape() {
|
|
57342
|
+
return new NormalBoxPathShape2();
|
|
57343
|
+
}
|
|
57344
|
+
buildPath(ctx2, shape) {
|
|
57345
|
+
const {points: points4, isSimpleBox} = shape;
|
|
57346
|
+
for (let index = 0; index < points4.length; ) {
|
|
57347
|
+
const point1 = points4[index++];
|
|
57348
|
+
const point2 = points4[index++];
|
|
57349
|
+
const point3 = points4[index++];
|
|
57350
|
+
const point4 = points4[index++];
|
|
57351
|
+
if (isSimpleBox) {
|
|
57352
|
+
const x = point1[0];
|
|
57353
|
+
ctx2.moveTo(x, point1[1]);
|
|
57354
|
+
ctx2.lineTo(x, point3[1]);
|
|
57355
|
+
} else {
|
|
57356
|
+
ctx2.moveTo(point1[0], point1[1]);
|
|
57357
|
+
ctx2.lineTo(point2[0], point2[1]);
|
|
57358
|
+
ctx2.lineTo(point3[0], point3[1]);
|
|
57359
|
+
ctx2.lineTo(point4[0], point4[1]);
|
|
57360
|
+
ctx2.closePath();
|
|
57361
|
+
}
|
|
57362
|
+
}
|
|
57363
|
+
}
|
|
57364
|
+
};
|
|
57365
|
+
var NormalBoxPath_default = NormalBoxPath2;
|
|
57366
|
+
|
|
57367
|
+
// src/chart/candlePlot/WickPath.ts
|
|
57368
|
+
var WickPathShape = class {
|
|
57369
|
+
};
|
|
57370
|
+
var WickPath = class extends Path_default {
|
|
57371
|
+
constructor(opts) {
|
|
57372
|
+
super(opts);
|
|
57373
|
+
this.type = "wickPath";
|
|
57374
|
+
}
|
|
57375
|
+
getDefaultShape() {
|
|
57376
|
+
return new WickPathShape();
|
|
57377
|
+
}
|
|
57378
|
+
buildPath(ctx2, shape) {
|
|
57379
|
+
const {points: points4} = shape;
|
|
57380
|
+
for (let index = 0; index < points4.length; ) {
|
|
57381
|
+
const point1 = points4[index++];
|
|
57382
|
+
const point2 = points4[index++];
|
|
57383
|
+
const point3 = points4[index++];
|
|
57384
|
+
const point4 = points4[index++];
|
|
57385
|
+
ctx2.moveTo(point1[0], point1[1]);
|
|
57386
|
+
ctx2.lineTo(point2[0], point2[1]);
|
|
57387
|
+
ctx2.moveTo(point3[0], point3[1]);
|
|
57388
|
+
ctx2.lineTo(point4[0], point4[1]);
|
|
57389
|
+
}
|
|
57390
|
+
}
|
|
57391
|
+
};
|
|
57392
|
+
var WickPath_default = WickPath;
|
|
57393
|
+
|
|
57394
|
+
// src/chart/candlePlot/CandlePlotView.ts
|
|
57395
|
+
var CandlePlotView2 = class extends Chart_default {
|
|
57396
|
+
constructor() {
|
|
57397
|
+
super(...arguments);
|
|
57398
|
+
this.type = CandlePlotView2.type;
|
|
57399
|
+
}
|
|
57400
|
+
render(seriesModel, ecModel, api2) {
|
|
57401
|
+
this._progressiveEls = null;
|
|
57402
|
+
this._renderNormal(seriesModel);
|
|
57403
|
+
}
|
|
57404
|
+
eachRendered(cb) {
|
|
57405
|
+
traverseElements(this._progressiveEls || this.group, cb);
|
|
57406
|
+
}
|
|
57407
|
+
_renderNormal(seriesModel) {
|
|
57408
|
+
const data = seriesModel.getData();
|
|
57409
|
+
const group = this.group;
|
|
57410
|
+
group.removeAll();
|
|
57411
|
+
const isSimpleBox = data.getLayout("isSimpleBox");
|
|
57412
|
+
const bodyPointsByColor = data.getLayout("bodyPointsByColor");
|
|
57413
|
+
const wickPointsByColor = data.getLayout("wickPointsByColor");
|
|
57414
|
+
each(bodyPointsByColor, function(points4, key) {
|
|
57415
|
+
const [fill, stroke] = key.split(":");
|
|
57416
|
+
const el = new NormalBoxPath_default({
|
|
57417
|
+
shape: {
|
|
57418
|
+
points: points4,
|
|
57419
|
+
isSimpleBox
|
|
57420
|
+
},
|
|
57421
|
+
style: {
|
|
57422
|
+
fill,
|
|
57423
|
+
stroke
|
|
57424
|
+
}
|
|
57425
|
+
});
|
|
57426
|
+
group.add(el);
|
|
57427
|
+
});
|
|
57428
|
+
each(wickPointsByColor, function(points4, key) {
|
|
57429
|
+
const [stroke] = key.split(":");
|
|
57430
|
+
const el = new WickPath_default({
|
|
57431
|
+
shape: {
|
|
57432
|
+
points: points4
|
|
57433
|
+
},
|
|
57434
|
+
style: {
|
|
57435
|
+
stroke
|
|
57436
|
+
}
|
|
57437
|
+
});
|
|
57438
|
+
group.add(el);
|
|
57439
|
+
});
|
|
57440
|
+
const clipPath = seriesModel.get("clip", true) ? createClipPath(seriesModel.coordinateSystem, false, seriesModel) : null;
|
|
57441
|
+
if (clipPath) {
|
|
57442
|
+
this.group.setClipPath(clipPath);
|
|
57443
|
+
} else {
|
|
57444
|
+
this.group.removeClipPath();
|
|
57445
|
+
}
|
|
57446
|
+
}
|
|
57447
|
+
remove(ecModel) {
|
|
57448
|
+
this._clear();
|
|
57449
|
+
}
|
|
57450
|
+
_clear() {
|
|
57451
|
+
this.group.removeAll();
|
|
57452
|
+
}
|
|
57453
|
+
};
|
|
57454
|
+
var CandlePlotView = CandlePlotView2;
|
|
57455
|
+
CandlePlotView.type = "candlePlot";
|
|
57456
|
+
var CandlePlotView_default = CandlePlotView;
|
|
57457
|
+
|
|
57458
|
+
// src/chart/candlePlot/CandlePlotSeries.ts
|
|
57459
|
+
var CandlePlotSeriesModel2 = class extends Series_default {
|
|
57460
|
+
constructor() {
|
|
57461
|
+
super(...arguments);
|
|
57462
|
+
this.type = CandlePlotSeriesModel2.type;
|
|
57463
|
+
this.defaultValueDimensions = [
|
|
57464
|
+
{name: "open", defaultTooltip: true},
|
|
57465
|
+
{name: "close", defaultTooltip: true},
|
|
57466
|
+
{name: "lowest", defaultTooltip: true},
|
|
57467
|
+
{name: "highest", defaultTooltip: true}
|
|
57468
|
+
];
|
|
57469
|
+
}
|
|
57470
|
+
getShadowDim() {
|
|
57471
|
+
return "open";
|
|
57472
|
+
}
|
|
57473
|
+
};
|
|
57474
|
+
var CandlePlotSeriesModel = CandlePlotSeriesModel2;
|
|
57475
|
+
CandlePlotSeriesModel.type = "series.candlePlot";
|
|
57476
|
+
CandlePlotSeriesModel.dependencies = ["xAxis", "yAxis", "grid"];
|
|
57477
|
+
CandlePlotSeriesModel.defaultOption = {
|
|
57478
|
+
z: 2,
|
|
57479
|
+
coordinateSystem: "cartesian2d",
|
|
57480
|
+
legendHoverLink: true,
|
|
57481
|
+
layout: null,
|
|
57482
|
+
clip: true,
|
|
57483
|
+
itemStyle: {
|
|
57484
|
+
color: "#eb5454",
|
|
57485
|
+
color0: "#47b262",
|
|
57486
|
+
borderColor: "#eb5454",
|
|
57487
|
+
borderColor0: "#47b262",
|
|
57488
|
+
wickColor: "#eb5454",
|
|
57489
|
+
wickColor0: "#47b262",
|
|
57490
|
+
borderColorDoji: null,
|
|
57491
|
+
borderWidth: 1
|
|
57492
|
+
},
|
|
57493
|
+
emphasis: {
|
|
57494
|
+
scale: true,
|
|
57495
|
+
itemStyle: {
|
|
57496
|
+
borderWidth: 2
|
|
57497
|
+
}
|
|
57498
|
+
},
|
|
57499
|
+
barMaxWidth: null,
|
|
57500
|
+
barMinWidth: null,
|
|
57501
|
+
barWidth: null,
|
|
57502
|
+
large: true,
|
|
57503
|
+
largeThreshold: 600,
|
|
57504
|
+
progressive: 3e3,
|
|
57505
|
+
progressiveThreshold: 1e4,
|
|
57506
|
+
progressiveChunkMode: "mod",
|
|
57507
|
+
animationEasing: "linear",
|
|
57508
|
+
animationDuration: 300
|
|
57509
|
+
};
|
|
57510
|
+
mixin(CandlePlotSeriesModel, WhiskerBoxCommonMixin, true);
|
|
57511
|
+
var CandlePlotSeries_default = CandlePlotSeriesModel;
|
|
57512
|
+
|
|
57513
|
+
// src/chart/candlePlot/candlePlotLayout.ts
|
|
57514
|
+
var positiveBorderColorQuery2 = ["itemStyle", "borderColor"];
|
|
57515
|
+
var negativeBorderColorQuery2 = ["itemStyle", "borderColor0"];
|
|
57516
|
+
var dojiBorderColorQuery2 = ["itemStyle", "borderColorDoji"];
|
|
57517
|
+
var positiveColorQuery2 = ["itemStyle", "color"];
|
|
57518
|
+
var negativeColorQuery2 = ["itemStyle", "color0"];
|
|
57519
|
+
var positiveWickColorQuery = ["itemStyle", "wickColor"];
|
|
57520
|
+
var negativeWickColorQuery = ["itemStyle", "wickColor0"];
|
|
57521
|
+
function getColor(sign, model) {
|
|
57522
|
+
return model.get(sign > 0 ? positiveColorQuery2 : negativeColorQuery2);
|
|
57523
|
+
}
|
|
57524
|
+
function getBorderColor(sign, model) {
|
|
57525
|
+
return model.get(sign === 0 ? dojiBorderColorQuery2 : sign > 0 ? positiveBorderColorQuery2 : negativeBorderColorQuery2);
|
|
57526
|
+
}
|
|
57527
|
+
function getWickColor(sign, model) {
|
|
57528
|
+
return model.get(sign === 0 ? dojiBorderColorQuery2 : sign > 0 ? positiveWickColorQuery : negativeWickColorQuery);
|
|
57529
|
+
}
|
|
57530
|
+
var candlePlotLayout = {
|
|
57531
|
+
seriesType: "candlePlot",
|
|
57532
|
+
plan: createRenderPlanner(),
|
|
57533
|
+
reset: function(seriesModel) {
|
|
57534
|
+
const coordSys = seriesModel.coordinateSystem;
|
|
57535
|
+
const data = seriesModel.getData();
|
|
57536
|
+
const candleWidth = calculateCandleWidth2(seriesModel, data);
|
|
57537
|
+
const cDimIdx = 0;
|
|
57538
|
+
const vDimIdx = 1;
|
|
57539
|
+
const coordDims = ["x", "y"];
|
|
57540
|
+
const cDimI = data.getDimensionIndex(data.mapDimension(coordDims[cDimIdx]));
|
|
57541
|
+
const vDimsI = map(data.mapDimensionsAll(coordDims[vDimIdx]), data.getDimensionIndex, data);
|
|
57542
|
+
const openDimI = vDimsI[0];
|
|
57543
|
+
const closeDimI = vDimsI[1];
|
|
57544
|
+
const lowestDimI = vDimsI[2];
|
|
57545
|
+
const highestDimI = vDimsI[3];
|
|
57546
|
+
const isSimpleBox = candleWidth <= 1.3;
|
|
57547
|
+
if (cDimI < 0 || vDimsI.length < 4) {
|
|
57548
|
+
return;
|
|
57549
|
+
}
|
|
57550
|
+
const showLast = seriesModel.get("showLast");
|
|
57551
|
+
return {
|
|
57552
|
+
progress: normalProgress
|
|
57553
|
+
};
|
|
57554
|
+
function normalProgress(params, data2) {
|
|
57555
|
+
let dataIndex;
|
|
57556
|
+
const store = data2.getStore();
|
|
57557
|
+
const bodyPointsByColor = {};
|
|
57558
|
+
const wickPointsByColor = {};
|
|
57559
|
+
const lastIndex = data2.count(true) - 1;
|
|
57560
|
+
while ((dataIndex = params.next()) != null) {
|
|
57561
|
+
if (showLast && lastIndex - data2.getRawIndex(dataIndex) >= showLast) {
|
|
57562
|
+
continue;
|
|
57563
|
+
}
|
|
57564
|
+
const axisDimVal = store.get(cDimI, dataIndex);
|
|
57565
|
+
const openVal = store.get(openDimI, dataIndex);
|
|
57566
|
+
const closeVal = store.get(closeDimI, dataIndex);
|
|
57567
|
+
const lowestVal = store.get(lowestDimI, dataIndex);
|
|
57568
|
+
const highestVal = store.get(highestDimI, dataIndex);
|
|
57569
|
+
const ocLow = Math.min(openVal, closeVal);
|
|
57570
|
+
const ocHigh = Math.max(openVal, closeVal);
|
|
57571
|
+
const ocLowPoint = getPoint(ocLow, axisDimVal);
|
|
57572
|
+
const ocHighPoint = getPoint(ocHigh, axisDimVal);
|
|
57573
|
+
const lowestPoint = getPoint(lowestVal, axisDimVal);
|
|
57574
|
+
const highestPoint = getPoint(highestVal, axisDimVal);
|
|
57575
|
+
const itemModel = data2.getItemModel(dataIndex);
|
|
57576
|
+
const hasDojiColor = !!itemModel.get(["itemStyle", "borderColorDoji"]);
|
|
57577
|
+
const sign = getSign2(store, dataIndex, openVal, closeVal, closeDimI, hasDojiColor);
|
|
57578
|
+
const key = `${getColor(sign, itemModel) || "none"}:${getBorderColor(sign, itemModel) || "none"}`;
|
|
57579
|
+
const bodyPoints = bodyPointsByColor[key] || [];
|
|
57580
|
+
addBodyEnd(bodyPoints, ocHighPoint, 0);
|
|
57581
|
+
addBodyEnd(bodyPoints, ocLowPoint, 1);
|
|
57582
|
+
bodyPointsByColor[key] = bodyPoints;
|
|
57583
|
+
const wickKey = getWickColor(sign, itemModel);
|
|
57584
|
+
if (wickKey) {
|
|
57585
|
+
const wickPoint = wickPointsByColor[wickKey] || [];
|
|
57586
|
+
wickPoint.push(subPixelOptimizePoint(highestPoint), subPixelOptimizePoint(ocHighPoint), subPixelOptimizePoint(lowestPoint), subPixelOptimizePoint(ocLowPoint));
|
|
57587
|
+
wickPointsByColor[wickKey] = wickPoint;
|
|
57588
|
+
}
|
|
57589
|
+
}
|
|
57590
|
+
data2.setLayout({
|
|
57591
|
+
candleWidth,
|
|
57592
|
+
bodyPointsByColor,
|
|
57593
|
+
wickPointsByColor,
|
|
57594
|
+
isSimpleBox
|
|
57595
|
+
});
|
|
57596
|
+
function getPoint(val, axisDimVal) {
|
|
57597
|
+
const p = [];
|
|
57598
|
+
p[cDimIdx] = axisDimVal;
|
|
57599
|
+
p[vDimIdx] = val;
|
|
57600
|
+
const points4 = isNaN(axisDimVal) || isNaN(val) ? [NaN, NaN] : coordSys.dataToPoint(p);
|
|
57601
|
+
if (!isNaN(points4[0])) {
|
|
57602
|
+
points4[0] = points4[0] + 0.5;
|
|
57603
|
+
}
|
|
57604
|
+
if (!isNaN(points4[1])) {
|
|
57605
|
+
points4[1] = Math.floor(points4[1]);
|
|
57606
|
+
}
|
|
57607
|
+
return points4;
|
|
57608
|
+
}
|
|
57609
|
+
function addBodyEnd(ends, point, start2) {
|
|
57610
|
+
const point1 = point.slice();
|
|
57611
|
+
const point2 = point.slice();
|
|
57612
|
+
point1[cDimIdx] = subPixelOptimize2(point1[cDimIdx] + candleWidth / 2, 1, false);
|
|
57613
|
+
point2[cDimIdx] = subPixelOptimize2(point2[cDimIdx] - candleWidth / 2, 1, true);
|
|
57614
|
+
if (point1[cDimIdx] === point2[cDimIdx]) {
|
|
57615
|
+
point1[0] = start2 ? point1[0] - 0.5 : point1[0] + 0.5;
|
|
57616
|
+
point2[0] = start2 ? point1[0] + 0.5 : point1[0] - 0.5;
|
|
57617
|
+
}
|
|
57618
|
+
point1[1] += 0.5;
|
|
57619
|
+
point2[1] += 0.5;
|
|
57620
|
+
start2 ? ends.push(point1, point2) : ends.push(point2, point1);
|
|
57621
|
+
}
|
|
57622
|
+
function subPixelOptimizePoint(point) {
|
|
57623
|
+
point[cDimIdx] = subPixelOptimize2(point[cDimIdx], 1);
|
|
57624
|
+
return point;
|
|
57625
|
+
}
|
|
57626
|
+
}
|
|
57627
|
+
}
|
|
57628
|
+
};
|
|
57629
|
+
function getSign2(store, dataIndex, openVal, closeVal, closeDimI, hasDojiColor) {
|
|
57630
|
+
let sign;
|
|
57631
|
+
if (openVal > closeVal) {
|
|
57632
|
+
sign = -1;
|
|
57633
|
+
} else if (openVal < closeVal) {
|
|
57634
|
+
sign = 1;
|
|
57635
|
+
} else {
|
|
57636
|
+
sign = hasDojiColor ? 0 : dataIndex > 0 ? store.get(closeDimI, dataIndex - 1) <= closeVal ? 1 : -1 : 1;
|
|
57637
|
+
}
|
|
57638
|
+
return sign;
|
|
57639
|
+
}
|
|
57640
|
+
function calculateCandleWidth2(seriesModel, data) {
|
|
57641
|
+
const baseAxis = seriesModel.getBaseAxis();
|
|
57642
|
+
let extent3;
|
|
57643
|
+
const bandWidth = baseAxis.type === "category" ? baseAxis.getBandWidth() : (extent3 = baseAxis.getExtent(), Math.abs(extent3[1] - extent3[0]) / data.count());
|
|
57644
|
+
return Math.max(bandWidth * 0.7, 1);
|
|
57645
|
+
}
|
|
57646
|
+
var candlePlotLayout_default = candlePlotLayout;
|
|
57647
|
+
|
|
57648
|
+
// src/chart/candlePlot/install.ts
|
|
57649
|
+
function install30(registers) {
|
|
57650
|
+
registers.registerChartView(CandlePlotView_default);
|
|
57651
|
+
registers.registerSeriesModel(CandlePlotSeries_default);
|
|
57652
|
+
registers.registerLayout(candlePlotLayout_default);
|
|
57653
|
+
}
|
|
57654
|
+
|
|
57655
|
+
// src/chart/barPlot/BarPath.ts
|
|
57656
|
+
var BarPathShape = class {
|
|
57657
|
+
};
|
|
57658
|
+
var BarPath = class extends Path_default {
|
|
57659
|
+
constructor(opts) {
|
|
57660
|
+
super(opts);
|
|
57661
|
+
this.type = "BarPath";
|
|
57662
|
+
}
|
|
57663
|
+
getDefaultShape() {
|
|
57664
|
+
return new BarPathShape();
|
|
57665
|
+
}
|
|
57666
|
+
buildPath(ctx2, shape) {
|
|
57667
|
+
const {points: points4, isSimpleBox, candleWidth} = shape;
|
|
57668
|
+
const width = Math.floor(candleWidth / 2) + 0.5;
|
|
57669
|
+
for (let index = 0; index < points4.length; ) {
|
|
57670
|
+
const point1 = points4[index++];
|
|
57671
|
+
const point2 = points4[index++];
|
|
57672
|
+
const point3 = points4[index++];
|
|
57673
|
+
const point4 = points4[index++];
|
|
57674
|
+
if (isSimpleBox) {
|
|
57675
|
+
const x = point3[0];
|
|
57676
|
+
ctx2.moveTo(x, point3[1]);
|
|
57677
|
+
ctx2.lineTo(x, point4[1]);
|
|
57678
|
+
} else {
|
|
57679
|
+
ctx2.moveTo(point3[0], point3[1]);
|
|
57680
|
+
ctx2.lineTo(point4[0], point4[1]);
|
|
57681
|
+
ctx2.moveTo(point1[0], point1[1]);
|
|
57682
|
+
ctx2.lineTo(point1[0] - width, point1[1]);
|
|
57683
|
+
ctx2.moveTo(point2[0], point2[1]);
|
|
57684
|
+
ctx2.lineTo(point2[0] + width, point2[1]);
|
|
57685
|
+
}
|
|
57686
|
+
}
|
|
57687
|
+
}
|
|
57688
|
+
};
|
|
57689
|
+
var BarPath_default2 = BarPath;
|
|
57690
|
+
|
|
57691
|
+
// src/chart/barPlot/BarPlotView.ts
|
|
57692
|
+
var BarPlotView2 = class extends Chart_default {
|
|
57693
|
+
constructor() {
|
|
57694
|
+
super(...arguments);
|
|
57695
|
+
this.type = BarPlotView2.type;
|
|
57696
|
+
}
|
|
57697
|
+
render(seriesModel, ecModel, api2) {
|
|
57698
|
+
this._progressiveEls = null;
|
|
57699
|
+
this._renderNormal(seriesModel);
|
|
57700
|
+
}
|
|
57701
|
+
eachRendered(cb) {
|
|
57702
|
+
traverseElements(this._progressiveEls || this.group, cb);
|
|
57703
|
+
}
|
|
57704
|
+
_renderNormal(seriesModel) {
|
|
57705
|
+
const data = seriesModel.getData();
|
|
57706
|
+
const group = this.group;
|
|
57707
|
+
group.removeAll();
|
|
57708
|
+
const candleWidth = data.getLayout("candleWidth");
|
|
57709
|
+
const isSimpleBox = data.getLayout("isSimpleBox");
|
|
57710
|
+
const bodyPointsByColor = data.getLayout("bodyPointsByColor");
|
|
57711
|
+
each(bodyPointsByColor, function(points4, stroke) {
|
|
57712
|
+
const el = new BarPath_default2({
|
|
57713
|
+
shape: {
|
|
57714
|
+
points: points4,
|
|
57715
|
+
isSimpleBox,
|
|
57716
|
+
candleWidth
|
|
57717
|
+
},
|
|
57718
|
+
style: {
|
|
57719
|
+
stroke,
|
|
57720
|
+
fill: "none"
|
|
57721
|
+
}
|
|
57722
|
+
});
|
|
57723
|
+
group.add(el);
|
|
57724
|
+
});
|
|
57725
|
+
const clipPath = seriesModel.get("clip", true) ? createClipPath(seriesModel.coordinateSystem, false, seriesModel) : null;
|
|
57726
|
+
if (clipPath) {
|
|
57727
|
+
this.group.setClipPath(clipPath);
|
|
57728
|
+
} else {
|
|
57729
|
+
this.group.removeClipPath();
|
|
57730
|
+
}
|
|
57731
|
+
}
|
|
57732
|
+
remove(ecModel) {
|
|
57733
|
+
this._clear();
|
|
57734
|
+
}
|
|
57735
|
+
_clear() {
|
|
57736
|
+
this.group.removeAll();
|
|
57737
|
+
}
|
|
57738
|
+
};
|
|
57739
|
+
var BarPlotView = BarPlotView2;
|
|
57740
|
+
BarPlotView.type = "barPlot";
|
|
57741
|
+
var BarPlotView_default = BarPlotView;
|
|
57742
|
+
|
|
57743
|
+
// src/chart/barPlot/BarPlotSeries.ts
|
|
57744
|
+
var BarPlotSeriesModel2 = class extends Series_default {
|
|
57745
|
+
constructor() {
|
|
57746
|
+
super(...arguments);
|
|
57747
|
+
this.type = BarPlotSeriesModel2.type;
|
|
57748
|
+
this.defaultValueDimensions = [
|
|
57749
|
+
{name: "open", defaultTooltip: true},
|
|
57750
|
+
{name: "close", defaultTooltip: true},
|
|
57751
|
+
{name: "lowest", defaultTooltip: true},
|
|
57752
|
+
{name: "highest", defaultTooltip: true}
|
|
57753
|
+
];
|
|
57754
|
+
}
|
|
57755
|
+
getShadowDim() {
|
|
57756
|
+
return "open";
|
|
57757
|
+
}
|
|
57758
|
+
};
|
|
57759
|
+
var BarPlotSeriesModel = BarPlotSeriesModel2;
|
|
57760
|
+
BarPlotSeriesModel.type = "series.barPlot";
|
|
57761
|
+
BarPlotSeriesModel.dependencies = ["xAxis", "yAxis", "grid"];
|
|
57762
|
+
BarPlotSeriesModel.defaultOption = {
|
|
57763
|
+
z: 2,
|
|
57764
|
+
coordinateSystem: "cartesian2d",
|
|
57765
|
+
legendHoverLink: true,
|
|
57766
|
+
layout: null,
|
|
57767
|
+
clip: true,
|
|
57768
|
+
itemStyle: {
|
|
57769
|
+
color: "#eb5454",
|
|
57770
|
+
color0: "#47b262",
|
|
57771
|
+
borderWidth: 1
|
|
57772
|
+
},
|
|
57773
|
+
emphasis: {
|
|
57774
|
+
scale: true,
|
|
57775
|
+
itemStyle: {
|
|
57776
|
+
borderWidth: 2
|
|
57777
|
+
}
|
|
57778
|
+
},
|
|
57779
|
+
barMaxWidth: null,
|
|
57780
|
+
barMinWidth: null,
|
|
57781
|
+
barWidth: null,
|
|
57782
|
+
large: true,
|
|
57783
|
+
largeThreshold: 600,
|
|
57784
|
+
progressive: 3e3,
|
|
57785
|
+
progressiveThreshold: 1e4,
|
|
57786
|
+
progressiveChunkMode: "mod",
|
|
57787
|
+
animationEasing: "linear",
|
|
57788
|
+
animationDuration: 300
|
|
57789
|
+
};
|
|
57790
|
+
mixin(BarPlotSeriesModel, WhiskerBoxCommonMixin, true);
|
|
57791
|
+
var BarPlotSeries_default = BarPlotSeriesModel;
|
|
57792
|
+
|
|
57793
|
+
// src/chart/barPlot/barPlotLayout.ts
|
|
57794
|
+
var positiveColorQuery3 = ["itemStyle", "color"];
|
|
57795
|
+
var negativeColorQuery3 = ["itemStyle", "color0"];
|
|
57796
|
+
function getColor2(sign, model) {
|
|
57797
|
+
return model.get(sign > 0 ? positiveColorQuery3 : negativeColorQuery3);
|
|
57798
|
+
}
|
|
57799
|
+
var barPlotLayout = {
|
|
57800
|
+
seriesType: "barPlot",
|
|
57801
|
+
plan: createRenderPlanner(),
|
|
57802
|
+
reset: function(seriesModel) {
|
|
57803
|
+
const coordSys = seriesModel.coordinateSystem;
|
|
57804
|
+
const data = seriesModel.getData();
|
|
57805
|
+
const candleWidth = calculateCandleWidth3(seriesModel, data);
|
|
57806
|
+
const cDimIdx = 0;
|
|
57807
|
+
const vDimIdx = 1;
|
|
57808
|
+
const coordDims = ["x", "y"];
|
|
57809
|
+
const cDimI = data.getDimensionIndex(data.mapDimension(coordDims[cDimIdx]));
|
|
57810
|
+
const vDimsI = map(data.mapDimensionsAll(coordDims[vDimIdx]), data.getDimensionIndex, data);
|
|
57811
|
+
const openDimI = vDimsI[0];
|
|
57812
|
+
const closeDimI = vDimsI[1];
|
|
57813
|
+
const lowestDimI = vDimsI[2];
|
|
57814
|
+
const highestDimI = vDimsI[3];
|
|
57815
|
+
const isSimpleBox = candleWidth <= 1.3;
|
|
57816
|
+
if (cDimI < 0 || vDimsI.length < 4) {
|
|
57817
|
+
return;
|
|
57818
|
+
}
|
|
57819
|
+
const showLast = seriesModel.get("showLast");
|
|
57820
|
+
return {
|
|
57821
|
+
progress: normalProgress
|
|
57822
|
+
};
|
|
57823
|
+
function normalProgress(params, data2) {
|
|
57824
|
+
let dataIndex;
|
|
57825
|
+
const store = data2.getStore();
|
|
57826
|
+
const bodyPointsByColor = {};
|
|
57827
|
+
const lastIndex = data2.count(true) - 1;
|
|
57828
|
+
while ((dataIndex = params.next()) != null) {
|
|
57829
|
+
if (showLast && lastIndex - data2.getRawIndex(dataIndex) >= showLast) {
|
|
57830
|
+
continue;
|
|
57831
|
+
}
|
|
57832
|
+
const axisDimVal = store.get(cDimI, dataIndex);
|
|
57833
|
+
const openVal = store.get(openDimI, dataIndex);
|
|
57834
|
+
const closeVal = store.get(closeDimI, dataIndex);
|
|
57835
|
+
const lowestVal = store.get(lowestDimI, dataIndex);
|
|
57836
|
+
const highestVal = store.get(highestDimI, dataIndex);
|
|
57837
|
+
const ocLowPoint = getPoint(openVal, axisDimVal, 0.5);
|
|
57838
|
+
const ocHighPoint = getPoint(closeVal, axisDimVal, 0.5);
|
|
57839
|
+
const lowestPoint = getPoint(lowestVal, axisDimVal);
|
|
57840
|
+
const highestPoint = getPoint(highestVal, axisDimVal);
|
|
57841
|
+
const itemModel = data2.getItemModel(dataIndex);
|
|
57842
|
+
const sign = getSign3(store, dataIndex, openVal, closeVal, closeDimI);
|
|
57843
|
+
const key = getColor2(sign, itemModel);
|
|
57844
|
+
if (key) {
|
|
57845
|
+
const bodyPoints = bodyPointsByColor[key] || [];
|
|
57846
|
+
bodyPoints.push(ocLowPoint, ocHighPoint, lowestPoint, highestPoint);
|
|
57847
|
+
bodyPointsByColor[key] = bodyPoints;
|
|
57848
|
+
}
|
|
57849
|
+
}
|
|
57850
|
+
data2.setLayout({
|
|
57851
|
+
candleWidth,
|
|
57852
|
+
bodyPointsByColor,
|
|
57853
|
+
isSimpleBox
|
|
57854
|
+
});
|
|
57855
|
+
function getPoint(val, axisDimVal, yOffset = 0) {
|
|
57856
|
+
const p = [];
|
|
57857
|
+
p[cDimIdx] = axisDimVal;
|
|
57858
|
+
p[vDimIdx] = val;
|
|
57859
|
+
const points4 = isNaN(axisDimVal) || isNaN(val) ? [NaN, NaN] : coordSys.dataToPoint(p);
|
|
57860
|
+
if (!isNaN(points4[0])) {
|
|
57861
|
+
points4[0] = points4[0] + 0.5;
|
|
57862
|
+
}
|
|
57863
|
+
if (!isNaN(points4[1])) {
|
|
57864
|
+
points4[1] = Math.floor(points4[1]) + yOffset;
|
|
57865
|
+
}
|
|
57866
|
+
return points4;
|
|
57867
|
+
}
|
|
57868
|
+
}
|
|
57869
|
+
}
|
|
57870
|
+
};
|
|
57871
|
+
function getSign3(store, dataIndex, openVal, closeVal, closeDimI) {
|
|
57872
|
+
let sign;
|
|
57873
|
+
if (openVal > closeVal) {
|
|
57874
|
+
sign = -1;
|
|
57875
|
+
} else {
|
|
57876
|
+
sign = 1;
|
|
57877
|
+
}
|
|
57878
|
+
return sign;
|
|
57879
|
+
}
|
|
57880
|
+
function calculateCandleWidth3(seriesModel, data) {
|
|
57881
|
+
const baseAxis = seriesModel.getBaseAxis();
|
|
57882
|
+
let extent3;
|
|
57883
|
+
const bandWidth = baseAxis.type === "category" ? baseAxis.getBandWidth() : (extent3 = baseAxis.getExtent(), Math.abs(extent3[1] - extent3[0]) / data.count());
|
|
57884
|
+
return Math.max(bandWidth * 0.7, 1);
|
|
57885
|
+
}
|
|
57886
|
+
var barPlotLayout_default = barPlotLayout;
|
|
57887
|
+
|
|
57888
|
+
// src/chart/barPlot/install.ts
|
|
57889
|
+
function install31(registers) {
|
|
57890
|
+
registers.registerChartView(BarPlotView_default);
|
|
57891
|
+
registers.registerSeriesModel(BarPlotSeries_default);
|
|
57892
|
+
registers.registerLayout(barPlotLayout_default);
|
|
57893
|
+
}
|
|
57894
|
+
|
|
57895
|
+
// src/chart/arrowsPlot/ArrowsPlotSeries.ts
|
|
57896
|
+
var ArrowsPlotSeriesModel2 = class extends Series_default {
|
|
57897
|
+
constructor() {
|
|
57898
|
+
super(...arguments);
|
|
57899
|
+
this.type = ArrowsPlotSeriesModel2.type;
|
|
57900
|
+
}
|
|
57901
|
+
getInitialData(option, ecModel) {
|
|
57902
|
+
return createSeriesData_default(null, this, {
|
|
57903
|
+
useEncodeDefaulter: true
|
|
57904
|
+
});
|
|
57905
|
+
}
|
|
57906
|
+
};
|
|
57907
|
+
var ArrowsPlotSeriesModel = ArrowsPlotSeriesModel2;
|
|
57908
|
+
ArrowsPlotSeriesModel.type = "series.arrowsPlot";
|
|
57909
|
+
ArrowsPlotSeriesModel.dependencies = ["grid", "polar"];
|
|
57910
|
+
ArrowsPlotSeriesModel.defaultOption = {
|
|
57911
|
+
coordinateSystem: "cartesian2d",
|
|
57912
|
+
z: 2,
|
|
57913
|
+
large: false,
|
|
57914
|
+
largeThreshold: 2e3,
|
|
57915
|
+
emphasis: {
|
|
57916
|
+
scale: true
|
|
57917
|
+
},
|
|
57918
|
+
clip: true
|
|
57919
|
+
};
|
|
57920
|
+
var ArrowsPlotSeries_default = ArrowsPlotSeriesModel;
|
|
57921
|
+
|
|
57922
|
+
// src/chart/arrowsPlot/ArrowSymbolPath.ts
|
|
57923
|
+
var ArrowSymbolPathShape = class {
|
|
57924
|
+
};
|
|
57925
|
+
var ArrowSymbolPath = class extends Path_default {
|
|
57926
|
+
constructor(opts) {
|
|
57927
|
+
super(opts);
|
|
57928
|
+
}
|
|
57929
|
+
getDefaultShape() {
|
|
57930
|
+
return new ArrowSymbolPathShape();
|
|
57931
|
+
}
|
|
57932
|
+
buildPath(path, shape) {
|
|
57933
|
+
const {points: points4, barWidth, valueLength, minHeight} = shape;
|
|
57934
|
+
const symbolProxy = this.symbolProxy;
|
|
57935
|
+
const symbolProxyShape = symbolProxy.shape;
|
|
57936
|
+
const isUp = symbolProxyShape.symbolType === "arrowUp";
|
|
57937
|
+
const w = barWidth * 0.7;
|
|
57938
|
+
const triangleWidth = Math.floor(w * 0.3);
|
|
57939
|
+
const triangleHeight = w / 2;
|
|
57940
|
+
for (let i = 0; i < points4.length; i++) {
|
|
57941
|
+
const {x, y, value} = points4[i];
|
|
57942
|
+
const height = Math.max(Math.round(value * valueLength), minHeight, triangleHeight);
|
|
57943
|
+
symbolProxyShape.x = x;
|
|
57944
|
+
symbolProxyShape.y = y + (isUp ? height / 2 + 10 : -height / 2 - 10);
|
|
57945
|
+
symbolProxyShape.width = w;
|
|
57946
|
+
symbolProxyShape.height = height;
|
|
57947
|
+
symbolProxyShape.triangleWidth = triangleWidth;
|
|
57948
|
+
symbolProxyShape.triangleHeight = triangleHeight;
|
|
57949
|
+
symbolProxy.buildPath(path, symbolProxyShape, true);
|
|
57950
|
+
}
|
|
57951
|
+
}
|
|
57952
|
+
};
|
|
57953
|
+
var ArrowSymbolPath_default = ArrowSymbolPath;
|
|
57954
|
+
|
|
57955
|
+
// src/chart/arrowsPlot/ArrowPlotView.ts
|
|
57956
|
+
var ArrowsPlotView2 = class extends Chart_default {
|
|
57957
|
+
constructor() {
|
|
57958
|
+
super(...arguments);
|
|
57959
|
+
this.type = ArrowsPlotView2.type;
|
|
57960
|
+
}
|
|
57961
|
+
render(seriesModel, ecModel, api2) {
|
|
57962
|
+
const data = seriesModel.getData();
|
|
57963
|
+
this._renderArrows(data, seriesModel);
|
|
57964
|
+
this._finished = true;
|
|
57965
|
+
}
|
|
57966
|
+
_renderArrows(data, seriesModel) {
|
|
57967
|
+
if (!this._symbolGroup) {
|
|
57968
|
+
this._symbolGroup = new Group_default();
|
|
57969
|
+
this.group.add(this._symbolGroup);
|
|
57970
|
+
} else {
|
|
57971
|
+
this._symbolGroup.removeAll();
|
|
57972
|
+
}
|
|
57973
|
+
const symbolGroup = this._symbolGroup;
|
|
57974
|
+
const bandWidth = seriesModel.coordinateSystem.getAxesByScale("ordinal")[0].scale.barSpace;
|
|
57975
|
+
const maxheight = seriesModel.get("maxheight");
|
|
57976
|
+
const minheight = seriesModel.get("minheight");
|
|
57977
|
+
const upArrowsByColor = data.getLayout("upArrowsByColor");
|
|
57978
|
+
const maxValue = data.getLayout("maxValue");
|
|
57979
|
+
each(upArrowsByColor, function(item, color2) {
|
|
57980
|
+
const el = new ArrowSymbolPath_default({
|
|
57981
|
+
shape: {
|
|
57982
|
+
points: item,
|
|
57983
|
+
barWidth: bandWidth,
|
|
57984
|
+
minHeight: minheight,
|
|
57985
|
+
valueLength: maxheight / maxValue
|
|
57986
|
+
},
|
|
57987
|
+
style: {
|
|
57988
|
+
fill: color2
|
|
57989
|
+
}
|
|
57990
|
+
});
|
|
57991
|
+
el.symbolProxy = createSymbol("arrowUp", 0, 0, 0, 0);
|
|
57992
|
+
symbolGroup.add(el);
|
|
57993
|
+
});
|
|
57994
|
+
const downArrowsByColor = data.getLayout("downArrowsByColor");
|
|
57995
|
+
const minValue = data.getLayout("minValue");
|
|
57996
|
+
each(downArrowsByColor, function(item, color2) {
|
|
57997
|
+
const el = new ArrowSymbolPath_default({
|
|
57998
|
+
shape: {
|
|
57999
|
+
points: item,
|
|
58000
|
+
barWidth: bandWidth,
|
|
58001
|
+
minHeight: minheight,
|
|
58002
|
+
valueLength: maxheight / minValue
|
|
58003
|
+
},
|
|
58004
|
+
style: {
|
|
58005
|
+
fill: color2
|
|
58006
|
+
}
|
|
58007
|
+
});
|
|
58008
|
+
el.symbolProxy = createSymbol("arrowDown", 0, 0, 0, 0);
|
|
58009
|
+
symbolGroup.add(el);
|
|
58010
|
+
});
|
|
58011
|
+
}
|
|
58012
|
+
_getClipShape(seriesModel) {
|
|
58013
|
+
if (!seriesModel.get("clip", true)) {
|
|
58014
|
+
return;
|
|
58015
|
+
}
|
|
58016
|
+
const coordSys = seriesModel.coordinateSystem;
|
|
58017
|
+
return coordSys && coordSys.getArea && coordSys.getArea(0.1);
|
|
58018
|
+
}
|
|
58019
|
+
remove(ecModel, api2) {
|
|
58020
|
+
this._symbolGroup && this._symbolGroup.removeAll();
|
|
58021
|
+
this._symbolGroup = null;
|
|
58022
|
+
}
|
|
58023
|
+
dispose() {
|
|
58024
|
+
}
|
|
58025
|
+
};
|
|
58026
|
+
var ArrowsPlotView = ArrowsPlotView2;
|
|
58027
|
+
ArrowsPlotView.type = "arrowsPlot";
|
|
58028
|
+
var ArrowPlotView_default = ArrowsPlotView;
|
|
58029
|
+
|
|
58030
|
+
// src/chart/arrowsPlot/ArrowsPlotLayout.ts
|
|
58031
|
+
var ArrowsPlotLayout = {
|
|
58032
|
+
seriesType: "arrowsPlot",
|
|
58033
|
+
plan: createRenderPlanner(),
|
|
58034
|
+
reset: function(seriesModel) {
|
|
58035
|
+
const data = seriesModel.getData();
|
|
58036
|
+
const coordSys = seriesModel.coordinateSystem;
|
|
58037
|
+
if (!coordSys) {
|
|
58038
|
+
return;
|
|
58039
|
+
}
|
|
58040
|
+
const dims = map(coordSys.dimensions, function(dim) {
|
|
58041
|
+
return data.mapDimension(dim);
|
|
58042
|
+
}).slice(0, 2);
|
|
58043
|
+
const store = data.getStore();
|
|
58044
|
+
const dimIdx0 = data.getDimensionIndex(dims[0]);
|
|
58045
|
+
const dimIdx1 = data.getDimensionIndex(dims[1]);
|
|
58046
|
+
const xOffset = seriesModel.get("offset") || 0;
|
|
58047
|
+
const showLast = seriesModel.get("showLast");
|
|
58048
|
+
return {
|
|
58049
|
+
progress(params, arrowsPlotData) {
|
|
58050
|
+
const upArrowsByColor = {};
|
|
58051
|
+
const downArrowsByColor = {};
|
|
58052
|
+
let maxValue = 0;
|
|
58053
|
+
let minValue = 0;
|
|
58054
|
+
const lastIndex = data.count(true) - 1;
|
|
58055
|
+
const tmpIn = [];
|
|
58056
|
+
for (let i = params.start; i < params.end; i++) {
|
|
58057
|
+
if (showLast && lastIndex - data.getRawIndex(i) >= showLast) {
|
|
58058
|
+
continue;
|
|
58059
|
+
}
|
|
58060
|
+
tmpIn[0] = store.get(dimIdx0, i) + xOffset;
|
|
58061
|
+
tmpIn[1] = store.get(dimIdx1, i);
|
|
58062
|
+
if (isNaN(tmpIn[1])) {
|
|
58063
|
+
continue;
|
|
58064
|
+
}
|
|
58065
|
+
const itemModel = data.getItemModel(i);
|
|
58066
|
+
const {upColor, downColor, value} = itemModel.get("itemStyle");
|
|
58067
|
+
const point = coordSys.dataToPoint(tmpIn);
|
|
58068
|
+
if (value > 0) {
|
|
58069
|
+
const upArrows = upArrowsByColor[upColor] || [];
|
|
58070
|
+
upArrows.push({
|
|
58071
|
+
x: point[0],
|
|
58072
|
+
y: point[1],
|
|
58073
|
+
value
|
|
58074
|
+
});
|
|
58075
|
+
upArrowsByColor[upColor] = upArrows;
|
|
58076
|
+
maxValue = Math.max(maxValue, value);
|
|
58077
|
+
} else {
|
|
58078
|
+
const downArrows = downArrowsByColor[downColor] || [];
|
|
58079
|
+
downArrows.push({
|
|
58080
|
+
x: point[0],
|
|
58081
|
+
y: point[1],
|
|
58082
|
+
value
|
|
58083
|
+
});
|
|
58084
|
+
downArrowsByColor[downColor] = downArrows;
|
|
58085
|
+
minValue = Math.min(minValue, value);
|
|
58086
|
+
}
|
|
58087
|
+
downArrowsByColor[downColor];
|
|
58088
|
+
}
|
|
58089
|
+
arrowsPlotData.setLayout({
|
|
58090
|
+
upArrowsByColor,
|
|
58091
|
+
downArrowsByColor,
|
|
58092
|
+
maxValue,
|
|
58093
|
+
minValue
|
|
58094
|
+
});
|
|
58095
|
+
}
|
|
58096
|
+
};
|
|
58097
|
+
}
|
|
58098
|
+
};
|
|
58099
|
+
var ArrowsPlotLayout_default = ArrowsPlotLayout;
|
|
58100
|
+
|
|
58101
|
+
// src/chart/arrowsPlot/install.ts
|
|
58102
|
+
function install32(registers) {
|
|
58103
|
+
registers.registerSeriesModel(ArrowsPlotSeries_default);
|
|
58104
|
+
registers.registerChartView(ArrowPlotView_default);
|
|
58105
|
+
registers.registerLayout(ArrowsPlotLayout_default);
|
|
58106
|
+
}
|
|
58107
|
+
|
|
57319
58108
|
// src/chart/labels/LabelsSeries.ts
|
|
57320
58109
|
var LabelsSeriesModel2 = class extends Series_default {
|
|
57321
58110
|
constructor() {
|
|
@@ -57948,7 +58737,7 @@ var labelsLayout = {
|
|
|
57948
58737
|
var labelsLayout_default = labelsLayout;
|
|
57949
58738
|
|
|
57950
58739
|
// src/chart/labels/install.ts
|
|
57951
|
-
function
|
|
58740
|
+
function install33(registers) {
|
|
57952
58741
|
registers.registerSeriesModel(LabelsSeries_default);
|
|
57953
58742
|
registers.registerChartView(LabelsView_default);
|
|
57954
58743
|
registers.registerLayout(labelsLayout_default);
|
|
@@ -58083,7 +58872,7 @@ var hLinesLayout = {
|
|
|
58083
58872
|
var hLinesLayout_default = hLinesLayout;
|
|
58084
58873
|
|
|
58085
58874
|
// src/chart/hlines/install.ts
|
|
58086
|
-
function
|
|
58875
|
+
function install34(registers) {
|
|
58087
58876
|
registers.registerChartView(HLinesView_default);
|
|
58088
58877
|
registers.registerSeriesModel(HLinesSeries_default);
|
|
58089
58878
|
registers.registerLayout(hLinesLayout_default);
|
|
@@ -58366,7 +59155,7 @@ var fillsLayout = {
|
|
|
58366
59155
|
var fillsLayout_default = fillsLayout;
|
|
58367
59156
|
|
|
58368
59157
|
// src/chart/fills/install.ts
|
|
58369
|
-
function
|
|
59158
|
+
function install35(registers) {
|
|
58370
59159
|
registers.registerChartView(FillsView_default);
|
|
58371
59160
|
registers.registerSeriesModel(FillsSeries_default);
|
|
58372
59161
|
registers.registerLayout(fillsLayout_default);
|
|
@@ -58570,7 +59359,7 @@ var bgColorLayout = {
|
|
|
58570
59359
|
var BgColorLayout_default = bgColorLayout;
|
|
58571
59360
|
|
|
58572
59361
|
// src/chart/bgColor/install.ts
|
|
58573
|
-
function
|
|
59362
|
+
function install36(registers) {
|
|
58574
59363
|
registers.registerChartView(BgColorView_default);
|
|
58575
59364
|
registers.registerSeriesModel(BgColorSeries_default);
|
|
58576
59365
|
registers.registerLayout(BgColorLayout_default);
|
|
@@ -58968,7 +59757,7 @@ HeatmapSeriesModel.defaultOption = {
|
|
|
58968
59757
|
var HeatmapSeries_default = HeatmapSeriesModel;
|
|
58969
59758
|
|
|
58970
59759
|
// src/chart/heatmap/install.ts
|
|
58971
|
-
function
|
|
59760
|
+
function install37(registers) {
|
|
58972
59761
|
registers.registerChartView(HeatmapView_default);
|
|
58973
59762
|
registers.registerSeriesModel(HeatmapSeries_default);
|
|
58974
59763
|
}
|
|
@@ -59531,7 +60320,7 @@ PictorialBarSeriesModel.defaultOption = inheritDefaultOption(BaseBarSeries_defau
|
|
|
59531
60320
|
var PictorialBarSeries_default = PictorialBarSeriesModel;
|
|
59532
60321
|
|
|
59533
60322
|
// src/chart/bar/installPictorialBar.ts
|
|
59534
|
-
function
|
|
60323
|
+
function install38(registers) {
|
|
59535
60324
|
registers.registerChartView(PictorialBarView_default);
|
|
59536
60325
|
registers.registerSeriesModel(PictorialBarSeries_default);
|
|
59537
60326
|
registers.registerLayout(registers.PRIORITY.VISUAL.LAYOUT, curry(layout2, "pictorialBar"));
|
|
@@ -59932,7 +60721,7 @@ function computeBaseline(data) {
|
|
|
59932
60721
|
}
|
|
59933
60722
|
|
|
59934
60723
|
// src/chart/themeRiver/install.ts
|
|
59935
|
-
function
|
|
60724
|
+
function install39(registers) {
|
|
59936
60725
|
registers.registerChartView(ThemeRiverView_default);
|
|
59937
60726
|
registers.registerSeriesModel(ThemeRiverSeries_default);
|
|
59938
60727
|
registers.registerLayout(themeRiverLayout);
|
|
@@ -60570,7 +61359,7 @@ function sunburstVisual(ecModel) {
|
|
|
60570
61359
|
}
|
|
60571
61360
|
|
|
60572
61361
|
// src/chart/sunburst/install.ts
|
|
60573
|
-
function
|
|
61362
|
+
function install40(registers) {
|
|
60574
61363
|
registers.registerChartView(SunburstView_default);
|
|
60575
61364
|
registers.registerSeriesModel(SunburstSeries_default);
|
|
60576
61365
|
registers.registerLayout(curry(sunburstLayout, "sunburst"));
|
|
@@ -62018,7 +62807,7 @@ function hasOwnPathData(shape) {
|
|
|
62018
62807
|
}
|
|
62019
62808
|
|
|
62020
62809
|
// src/chart/custom/install.ts
|
|
62021
|
-
function
|
|
62810
|
+
function install41(registers) {
|
|
62022
62811
|
registers.registerChartView(CustomView_default);
|
|
62023
62812
|
registers.registerSeriesModel(CustomSeries_default);
|
|
62024
62813
|
}
|
|
@@ -62746,7 +63535,7 @@ var AxisPointerModel_default = AxisPointerModel;
|
|
|
62746
63535
|
|
|
62747
63536
|
// src/component/axisPointer/globalListener.ts
|
|
62748
63537
|
var inner12 = makeInner();
|
|
62749
|
-
var
|
|
63538
|
+
var each12 = each;
|
|
62750
63539
|
function register(key, api2, handler) {
|
|
62751
63540
|
if (env_default.node) {
|
|
62752
63541
|
return;
|
|
@@ -62770,7 +63559,7 @@ function initGlobalListeners(zr, api2) {
|
|
|
62770
63559
|
function useHandler(eventType, cb) {
|
|
62771
63560
|
zr.on(eventType, function(e2) {
|
|
62772
63561
|
const dis = makeDispatchAction(api2);
|
|
62773
|
-
|
|
63562
|
+
each12(inner12(zr).records, function(record) {
|
|
62774
63563
|
record && cb(record, e2, dis.dispatchAction);
|
|
62775
63564
|
});
|
|
62776
63565
|
dispatchTooltipFinally(dis.pendings, api2);
|
|
@@ -63239,7 +64028,7 @@ function illegalPoint(point) {
|
|
|
63239
64028
|
}
|
|
63240
64029
|
|
|
63241
64030
|
// src/component/axisPointer/install.ts
|
|
63242
|
-
function
|
|
64031
|
+
function install42(registers) {
|
|
63243
64032
|
AxisView_default.registerAxisPointerClass("CartesianAxisPointer", CartesianAxisPointer_default);
|
|
63244
64033
|
registers.registerComponentModel(AxisPointerModel_default);
|
|
63245
64034
|
registers.registerComponentView(AxisPointerView_default);
|
|
@@ -63268,9 +64057,9 @@ function install39(registers) {
|
|
|
63268
64057
|
}
|
|
63269
64058
|
|
|
63270
64059
|
// src/component/grid/install.ts
|
|
63271
|
-
function
|
|
64060
|
+
function install43(registers) {
|
|
63272
64061
|
use(install6);
|
|
63273
|
-
use(
|
|
64062
|
+
use(install42);
|
|
63274
64063
|
}
|
|
63275
64064
|
|
|
63276
64065
|
// src/component/axisPointer/PolarAxisPointer.ts
|
|
@@ -64324,8 +65113,8 @@ var PolarView2 = class extends Component_default2 {
|
|
|
64324
65113
|
};
|
|
64325
65114
|
var PolarView = PolarView2;
|
|
64326
65115
|
PolarView.type = "polar";
|
|
64327
|
-
function
|
|
64328
|
-
use(
|
|
65116
|
+
function install44(registers) {
|
|
65117
|
+
use(install42);
|
|
64329
65118
|
AxisView_default.registerAxisPointerClass("PolarAxisPointer", PolarAxisPointer_default);
|
|
64330
65119
|
registers.registerCoordinateSystem("polar", polarCreator_default);
|
|
64331
65120
|
registers.registerComponentModel(PolarModel_default);
|
|
@@ -64788,8 +65577,8 @@ var SingleView2 = class extends Component_default2 {
|
|
|
64788
65577
|
};
|
|
64789
65578
|
var SingleView = SingleView2;
|
|
64790
65579
|
SingleView.type = "single";
|
|
64791
|
-
function
|
|
64792
|
-
use(
|
|
65580
|
+
function install45(registers) {
|
|
65581
|
+
use(install42);
|
|
64793
65582
|
AxisView_default.registerAxisPointerClass("SingleAxisPointer", SingleAxisPointer_default);
|
|
64794
65583
|
registers.registerComponentView(SingleView);
|
|
64795
65584
|
registers.registerComponentView(SingleAxisView_default);
|
|
@@ -65479,7 +66268,7 @@ function getCoordSys5(finder) {
|
|
|
65479
66268
|
var Calendar_default = Calendar;
|
|
65480
66269
|
|
|
65481
66270
|
// src/component/calendar/install.ts
|
|
65482
|
-
function
|
|
66271
|
+
function install46(registers) {
|
|
65483
66272
|
registers.registerComponentModel(CalendarModel_default);
|
|
65484
66273
|
registers.registerComponentView(CalendarView_default);
|
|
65485
66274
|
registers.registerCoordinateSystem("calendar", Calendar_default);
|
|
@@ -65868,7 +66657,7 @@ function setEventData(el, graphicModel, elOption) {
|
|
|
65868
66657
|
}
|
|
65869
66658
|
|
|
65870
66659
|
// src/component/graphic/install.ts
|
|
65871
|
-
function
|
|
66660
|
+
function install47(registers) {
|
|
65872
66661
|
registers.registerComponentModel(GraphicComponentModel);
|
|
65873
66662
|
registers.registerComponentView(GraphicComponentView);
|
|
65874
66663
|
registers.registerPreprocessor(function(option) {
|
|
@@ -66212,8 +67001,11 @@ var DataZoomModel2 = class extends Component_default {
|
|
|
66212
67001
|
if (opt.lastBarRightSideDiffBarCount) {
|
|
66213
67002
|
thisOption.lastBarRightSideDiffBarCount = opt.lastBarRightSideDiffBarCount;
|
|
66214
67003
|
}
|
|
66215
|
-
if (!isLocal && opt.barSpace
|
|
66216
|
-
this._distanceRange = [
|
|
67004
|
+
if (!isLocal && (typeof opt.barSpace === "number" || typeof opt.lastBarRightSideDiffBarCount === "number")) {
|
|
67005
|
+
this._distanceRange = [
|
|
67006
|
+
opt.barSpace || thisOption.barSpace,
|
|
67007
|
+
opt.lastBarRightSideDiffBarCount || thisOption.lastBarRightSideDiffBarCount
|
|
67008
|
+
];
|
|
66217
67009
|
}
|
|
66218
67010
|
this._updateRangeUse(opt);
|
|
66219
67011
|
}
|
|
@@ -66350,7 +67142,7 @@ SelectDataZoomView.type = "dataZoom.select";
|
|
|
66350
67142
|
var SelectZoomView_default = SelectDataZoomView;
|
|
66351
67143
|
|
|
66352
67144
|
// src/component/dataZoom/AxisProxy.ts
|
|
66353
|
-
var
|
|
67145
|
+
var each13 = each;
|
|
66354
67146
|
var asc2 = asc;
|
|
66355
67147
|
var leftMinVisibleBarCount = 2;
|
|
66356
67148
|
var rightMinVisibleBarCount = 2;
|
|
@@ -66405,7 +67197,7 @@ var AxisProxy = class {
|
|
|
66405
67197
|
const percentWindow = [];
|
|
66406
67198
|
const valueWindow = [];
|
|
66407
67199
|
let hasPropModeValue;
|
|
66408
|
-
|
|
67200
|
+
each13(["start", "end"], function(prop, idx) {
|
|
66409
67201
|
let boundPercent = opt[prop];
|
|
66410
67202
|
let boundValue = opt[prop + "Value"];
|
|
66411
67203
|
if (rangePropMode[idx] === "percent") {
|
|
@@ -66503,7 +67295,7 @@ var AxisProxy = class {
|
|
|
66503
67295
|
if (filterMode === "none") {
|
|
66504
67296
|
return;
|
|
66505
67297
|
}
|
|
66506
|
-
|
|
67298
|
+
each13(seriesModels, function(seriesModel) {
|
|
66507
67299
|
let seriesData = seriesModel.getData();
|
|
66508
67300
|
const dataDims = seriesData.mapDimensionsAll(axisDim);
|
|
66509
67301
|
if (!dataDims.length || seriesModel.get("notFilterData")) {
|
|
@@ -66541,7 +67333,7 @@ var AxisProxy = class {
|
|
|
66541
67333
|
});
|
|
66542
67334
|
} else {
|
|
66543
67335
|
const offset = seriesModel.get("offset");
|
|
66544
|
-
|
|
67336
|
+
each13(dataDims, function(dim) {
|
|
66545
67337
|
if (filterMode === "empty") {
|
|
66546
67338
|
seriesModel.setData(seriesData = seriesData.map(dim, function(value) {
|
|
66547
67339
|
return !isInWindow(value) ? NaN : value;
|
|
@@ -66567,7 +67359,7 @@ var AxisProxy = class {
|
|
|
66567
67359
|
}
|
|
66568
67360
|
});
|
|
66569
67361
|
}
|
|
66570
|
-
|
|
67362
|
+
each13(dataDims, function(dim) {
|
|
66571
67363
|
seriesData.setApproximateExtent(valueWindow, dim);
|
|
66572
67364
|
});
|
|
66573
67365
|
});
|
|
@@ -66582,7 +67374,7 @@ var AxisProxy = class {
|
|
|
66582
67374
|
const minMaxSpan = this._minMaxSpan = {};
|
|
66583
67375
|
const dataZoomModel = this._dataZoomModel;
|
|
66584
67376
|
const dataExtent = this._dataExtent;
|
|
66585
|
-
|
|
67377
|
+
each13(["min", "max"], function(minMax) {
|
|
66586
67378
|
let percentSpan = dataZoomModel.get(minMax + "Span");
|
|
66587
67379
|
let valueSpan = dataZoomModel.get(minMax + "ValueSpan");
|
|
66588
67380
|
valueSpan != null && (valueSpan = this.getAxisModel().axis.scale.parse(valueSpan));
|
|
@@ -66618,14 +67410,14 @@ function calculateDataExtent(axisProxy, axisDim, seriesModels) {
|
|
|
66618
67410
|
const dataExtent = [Infinity, -Infinity];
|
|
66619
67411
|
const axisModel = axisProxy.getAxisModel();
|
|
66620
67412
|
const dataFromSeriesName = axisModel.axis.model.get("dataFromSeriesName");
|
|
66621
|
-
|
|
67413
|
+
each13(seriesModels, function(seriesModel) {
|
|
66622
67414
|
if (dataFromSeriesName && seriesModel.name !== dataFromSeriesName) {
|
|
66623
67415
|
return;
|
|
66624
67416
|
}
|
|
66625
67417
|
const seriesData = seriesModel.getData();
|
|
66626
67418
|
let baseValue = void 0;
|
|
66627
67419
|
if (axisModel.axis.type === "percentage") {
|
|
66628
|
-
baseValue = seriesData.get(seriesModel.subType
|
|
67420
|
+
baseValue = seriesData.get(isCandle(seriesModel.subType) ? "close" : "y", 0);
|
|
66629
67421
|
}
|
|
66630
67422
|
unionAxisExtentFromData(dataExtent, seriesData, axisDim, baseValue);
|
|
66631
67423
|
});
|
|
@@ -66751,7 +67543,7 @@ function installCommon(registers) {
|
|
|
66751
67543
|
}
|
|
66752
67544
|
|
|
66753
67545
|
// src/component/dataZoom/installDataZoomSelect.ts
|
|
66754
|
-
function
|
|
67546
|
+
function install48(registers) {
|
|
66755
67547
|
registers.registerComponentModel(SelectZoomModel_default);
|
|
66756
67548
|
registers.registerComponentView(SelectZoomView_default);
|
|
66757
67549
|
installCommon(registers);
|
|
@@ -67638,11 +68430,11 @@ registerAction({
|
|
|
67638
68430
|
var DataView_default = DataView;
|
|
67639
68431
|
|
|
67640
68432
|
// src/component/dataZoom/history.ts
|
|
67641
|
-
var
|
|
68433
|
+
var each14 = each;
|
|
67642
68434
|
var inner16 = makeInner();
|
|
67643
68435
|
function push(ecModel, newSnapshot) {
|
|
67644
68436
|
const storedSnapshots = getStoreSnapshots(ecModel);
|
|
67645
|
-
|
|
68437
|
+
each14(newSnapshot, function(batchItem, dataZoomId) {
|
|
67646
68438
|
let i = storedSnapshots.length - 1;
|
|
67647
68439
|
for (; i >= 0; i--) {
|
|
67648
68440
|
const snapshot = storedSnapshots[i];
|
|
@@ -67669,7 +68461,7 @@ function pop(ecModel) {
|
|
|
67669
68461
|
const head = storedSnapshots[storedSnapshots.length - 1];
|
|
67670
68462
|
storedSnapshots.length > 1 && storedSnapshots.pop();
|
|
67671
68463
|
const snapshot = {};
|
|
67672
|
-
|
|
68464
|
+
each14(head, function(batchItem, dataZoomId) {
|
|
67673
68465
|
for (let i = storedSnapshots.length - 1; i >= 0; i--) {
|
|
67674
68466
|
batchItem = storedSnapshots[i][dataZoomId];
|
|
67675
68467
|
if (batchItem) {
|
|
@@ -67982,7 +68774,7 @@ function getSize2(xyMinMax) {
|
|
|
67982
68774
|
var BrushTargetManager_default = BrushTargetManager;
|
|
67983
68775
|
|
|
67984
68776
|
// src/component/toolbox/feature/DataZoom.ts
|
|
67985
|
-
var
|
|
68777
|
+
var each15 = each;
|
|
67986
68778
|
var DATA_ZOOM_ID_BASE = makeInternalComponentId("toolbox-dataZoom_");
|
|
67987
68779
|
var DataZoomFeature = class extends ToolboxFeature {
|
|
67988
68780
|
render(featureModel, ecModel, api2, payload) {
|
|
@@ -68050,7 +68842,7 @@ var DataZoomFeature = class extends ToolboxFeature {
|
|
|
68050
68842
|
}
|
|
68051
68843
|
_dispatchZoomAction(snapshot) {
|
|
68052
68844
|
const batch = [];
|
|
68053
|
-
|
|
68845
|
+
each15(snapshot, function(batchItem, dataZoomId) {
|
|
68054
68846
|
batch.push(clone(batchItem));
|
|
68055
68847
|
});
|
|
68056
68848
|
batch.length && this.api.dispatchAction({
|
|
@@ -68133,8 +68925,8 @@ registerInternalOptionCreator("dataZoom", function(ecModel) {
|
|
|
68133
68925
|
const dzOptions = [];
|
|
68134
68926
|
const finder = makeAxisFinder(dzFeatureModel);
|
|
68135
68927
|
const finderResult = parseFinder(ecModel, finder);
|
|
68136
|
-
|
|
68137
|
-
|
|
68928
|
+
each15(finderResult.xAxisModels, (axisModel) => buildInternalOptions(axisModel, "xAxis", "xAxisIndex"));
|
|
68929
|
+
each15(finderResult.yAxisModels, (axisModel) => buildInternalOptions(axisModel, "yAxis", "yAxisIndex"));
|
|
68138
68930
|
function buildInternalOptions(axisModel, axisMainType, axisIndexPropName) {
|
|
68139
68931
|
const axisIndex = axisModel.componentIndex;
|
|
68140
68932
|
const newOpt = {
|
|
@@ -68151,7 +68943,7 @@ registerInternalOptionCreator("dataZoom", function(ecModel) {
|
|
|
68151
68943
|
var DataZoom_default = DataZoomFeature;
|
|
68152
68944
|
|
|
68153
68945
|
// src/component/toolbox/install.ts
|
|
68154
|
-
function
|
|
68946
|
+
function install49(registers) {
|
|
68155
68947
|
registers.registerComponentModel(ToolboxModel_default);
|
|
68156
68948
|
registers.registerComponentView(ToolboxView_default);
|
|
68157
68949
|
registerFeature("saveAsImage", SaveAsImage_default);
|
|
@@ -68159,7 +68951,7 @@ function install46(registers) {
|
|
|
68159
68951
|
registerFeature("dataView", DataView_default);
|
|
68160
68952
|
registerFeature("dataZoom", DataZoom_default);
|
|
68161
68953
|
registerFeature("restore", Restore_default);
|
|
68162
|
-
use(
|
|
68954
|
+
use(install48);
|
|
68163
68955
|
}
|
|
68164
68956
|
|
|
68165
68957
|
// src/component/tooltip/TooltipModel.ts
|
|
@@ -69327,8 +70119,8 @@ function findComponentReference(payload, ecModel, api2) {
|
|
|
69327
70119
|
var TooltipView_default = TooltipView;
|
|
69328
70120
|
|
|
69329
70121
|
// src/component/tooltip/install.ts
|
|
69330
|
-
function
|
|
69331
|
-
use(
|
|
70122
|
+
function install50(registers) {
|
|
70123
|
+
use(install42);
|
|
69332
70124
|
registers.registerComponentModel(TooltipModel_default);
|
|
69333
70125
|
registers.registerComponentView(TooltipView_default);
|
|
69334
70126
|
registers.registerAction({
|
|
@@ -69386,7 +70178,7 @@ function removeDuplicate(arr) {
|
|
|
69386
70178
|
}
|
|
69387
70179
|
|
|
69388
70180
|
// src/visual/visualSolution.ts
|
|
69389
|
-
var
|
|
70181
|
+
var each16 = each;
|
|
69390
70182
|
function hasKeys(obj) {
|
|
69391
70183
|
if (obj) {
|
|
69392
70184
|
for (const name in obj) {
|
|
@@ -69398,9 +70190,9 @@ function hasKeys(obj) {
|
|
|
69398
70190
|
}
|
|
69399
70191
|
function createVisualMappings(option, stateList, supplementVisualOption) {
|
|
69400
70192
|
const visualMappings = {};
|
|
69401
|
-
|
|
70193
|
+
each16(stateList, function(state) {
|
|
69402
70194
|
const mappings = visualMappings[state] = createMappings();
|
|
69403
|
-
|
|
70195
|
+
each16(option[state], function(visualData, visualType) {
|
|
69404
70196
|
if (!VisualMapping_default.isValidType(visualType)) {
|
|
69405
70197
|
return;
|
|
69406
70198
|
}
|
|
@@ -69944,7 +70736,7 @@ var BrushFeature = class extends ToolboxFeature {
|
|
|
69944
70736
|
var Brush_default = BrushFeature;
|
|
69945
70737
|
|
|
69946
70738
|
// src/component/brush/install.ts
|
|
69947
|
-
function
|
|
70739
|
+
function install51(registers) {
|
|
69948
70740
|
registers.registerComponentView(BrushView_default);
|
|
69949
70741
|
registers.registerComponentModel(BrushModel_default);
|
|
69950
70742
|
registers.registerPreprocessor(brushPreprocessor);
|
|
@@ -70091,7 +70883,7 @@ var TitleView2 = class extends Component_default2 {
|
|
|
70091
70883
|
};
|
|
70092
70884
|
var TitleView = TitleView2;
|
|
70093
70885
|
TitleView.type = "title";
|
|
70094
|
-
function
|
|
70886
|
+
function install52(registers) {
|
|
70095
70887
|
registers.registerComponentModel(TitleModel);
|
|
70096
70888
|
registers.registerComponentView(TitleView);
|
|
70097
70889
|
}
|
|
@@ -70456,7 +71248,7 @@ TableView.type = "table";
|
|
|
70456
71248
|
var TableView_default = TableView;
|
|
70457
71249
|
|
|
70458
71250
|
// src/component/table/install.ts
|
|
70459
|
-
function
|
|
71251
|
+
function install53(registers) {
|
|
70460
71252
|
registers.registerComponentModel(TableModel_default);
|
|
70461
71253
|
registers.registerComponentView(TableView_default);
|
|
70462
71254
|
}
|
|
@@ -71310,7 +72102,7 @@ function has(obj, attr) {
|
|
|
71310
72102
|
}
|
|
71311
72103
|
|
|
71312
72104
|
// src/component/timeline/install.ts
|
|
71313
|
-
function
|
|
72105
|
+
function install54(registers) {
|
|
71314
72106
|
registers.registerComponentModel(SliderTimelineModel_default);
|
|
71315
72107
|
registers.registerComponentView(SliderTimelineView_default);
|
|
71316
72108
|
registers.registerSubTypeDefaulter("timeline", function() {
|
|
@@ -71751,7 +72543,7 @@ function createData(coordSys, seriesModel, mpModel) {
|
|
|
71751
72543
|
var MarkPointView_default = MarkPointView;
|
|
71752
72544
|
|
|
71753
72545
|
// src/component/marker/installMarkPoint.ts
|
|
71754
|
-
function
|
|
72546
|
+
function install55(registers) {
|
|
71755
72547
|
registers.registerComponentModel(MarkPointModel_default);
|
|
71756
72548
|
registers.registerComponentView(MarkPointView_default);
|
|
71757
72549
|
registers.registerPreprocessor(function(opt) {
|
|
@@ -72069,7 +72861,7 @@ function createList2(coordSys, seriesModel, mlModel) {
|
|
|
72069
72861
|
var MarkLineView_default = MarkLineView;
|
|
72070
72862
|
|
|
72071
72863
|
// src/component/marker/installMarkLine.ts
|
|
72072
|
-
function
|
|
72864
|
+
function install56(registers) {
|
|
72073
72865
|
registers.registerComponentModel(MarkLineModel_default);
|
|
72074
72866
|
registers.registerComponentView(MarkLineView_default);
|
|
72075
72867
|
registers.registerPreprocessor(function(opt) {
|
|
@@ -72383,7 +73175,7 @@ function createList3(coordSys, seriesModel, maModel) {
|
|
|
72383
73175
|
var MarkAreaView_default = MarkAreaView;
|
|
72384
73176
|
|
|
72385
73177
|
// src/component/marker/installMarkArea.ts
|
|
72386
|
-
function
|
|
73178
|
+
function install57(registers) {
|
|
72387
73179
|
registers.registerComponentModel(MarkAreaModel_default);
|
|
72388
73180
|
registers.registerComponentView(MarkAreaView_default);
|
|
72389
73181
|
registers.registerPreprocessor(function(opt) {
|
|
@@ -72530,13 +73322,13 @@ var markerTypeCalculator2 = {
|
|
|
72530
73322
|
const seriesData = seriesModel.getData();
|
|
72531
73323
|
const lastIndex = seriesData.count(true) - 1;
|
|
72532
73324
|
let fill = seriesData.getItemVisual(lastIndex, "style")?.fill;
|
|
72533
|
-
if (seriesModel.subType
|
|
73325
|
+
if (isCandle(seriesModel.subType)) {
|
|
72534
73326
|
const dataItem = seriesData.getItemModel(lastIndex, true);
|
|
72535
73327
|
const closeValue = seriesData.getByRawIndex("close", lastIndex);
|
|
72536
73328
|
const openValue = seriesData.getByRawIndex("open", lastIndex);
|
|
72537
73329
|
const sign = openValue > closeValue ? -1 : 1;
|
|
72538
73330
|
fill = dataItem.get(sign > 0 ? positiveBorderColorQuery : negativeBorderColorQuery);
|
|
72539
|
-
} else if (
|
|
73331
|
+
} else if (isPlot(seriesModel.subType)) {
|
|
72540
73332
|
const isLinesPlot = seriesModel.subType === "linesPlot";
|
|
72541
73333
|
const dataItem = seriesData.getItemModel(lastIndex, true);
|
|
72542
73334
|
fill = dataItem.get([isLinesPlot ? "lineStyle" : "itemStyle", "color"]);
|
|
@@ -72561,8 +73353,8 @@ var markerTypeCalculator2 = {
|
|
|
72561
73353
|
}
|
|
72562
73354
|
const backgroundColor2 = seriesModel.ecModel.get("backgroundColor");
|
|
72563
73355
|
const lastItem = seriesData.count() - 1;
|
|
72564
|
-
let fill = seriesModel.subType
|
|
72565
|
-
if (
|
|
73356
|
+
let fill = isCandle(seriesModel.subType) ? seriesData.getItemVisual(lastItem, "style")?.stroke : seriesData.getItemVisual(lastItem, "style")?.fill;
|
|
73357
|
+
if (isPlot(seriesModel.subType)) {
|
|
72566
73358
|
const isLinesPlot = seriesModel.subType === "linesPlot";
|
|
72567
73359
|
const dataItem = seriesData.getItemModel(lastItem);
|
|
72568
73360
|
fill = dataItem.get([isLinesPlot ? "lineStyle" : "itemStyle", "color"]);
|
|
@@ -73026,7 +73818,7 @@ function updateLabel({x, y, labelData, markerModel, gridRect, position: position
|
|
|
73026
73818
|
var MarkLabelView_default = MarkLabelView;
|
|
73027
73819
|
|
|
73028
73820
|
// src/component/marker/installMarkLabel.ts
|
|
73029
|
-
function
|
|
73821
|
+
function install58(registers) {
|
|
73030
73822
|
registers.registerComponentModel(MarkLabelModal_default);
|
|
73031
73823
|
registers.registerComponentView(MarkLabelView_default);
|
|
73032
73824
|
registers.registerPreprocessor(function(opt) {
|
|
@@ -73269,7 +74061,7 @@ var LegendModel_default = LegendModel;
|
|
|
73269
74061
|
|
|
73270
74062
|
// src/component/legend/LegendView.ts
|
|
73271
74063
|
var curry2 = curry;
|
|
73272
|
-
var
|
|
74064
|
+
var each17 = each;
|
|
73273
74065
|
var Group3 = Group_default;
|
|
73274
74066
|
var LegendView2 = class extends Component_default2 {
|
|
73275
74067
|
constructor() {
|
|
@@ -73333,7 +74125,7 @@ var LegendView2 = class extends Component_default2 {
|
|
|
73333
74125
|
ecModel.eachRawSeries(function(seriesModel) {
|
|
73334
74126
|
!seriesModel.get("legendHoverLink") && excludeSeriesId.push(seriesModel.id);
|
|
73335
74127
|
});
|
|
73336
|
-
|
|
74128
|
+
each17(legendModel.getData(), function(legendItemModel, dataIndex) {
|
|
73337
74129
|
const name = legendItemModel.get("name");
|
|
73338
74130
|
if (!this.newlineDisabled && (name === "" || name === "\n")) {
|
|
73339
74131
|
const g = new Group3();
|
|
@@ -73405,7 +74197,7 @@ var LegendView2 = class extends Component_default2 {
|
|
|
73405
74197
|
}
|
|
73406
74198
|
_createSelector(selector2, legendModel, api2, orient, selectorPosition) {
|
|
73407
74199
|
const selectorGroup = this.getSelectorGroup();
|
|
73408
|
-
|
|
74200
|
+
each17(selector2, function createSelectorButton(selectorItem) {
|
|
73409
74201
|
const type = selectorItem.type;
|
|
73410
74202
|
const labelText = new Text_default({
|
|
73411
74203
|
style: {
|
|
@@ -73558,7 +74350,7 @@ function getLegendStyle(iconType, legendItemModel, lineVisualStyle, itemVisualSt
|
|
|
73558
74350
|
if (style.lineWidth === "auto") {
|
|
73559
74351
|
style.lineWidth = visualStyle.lineWidth > 0 ? 2 : 0;
|
|
73560
74352
|
}
|
|
73561
|
-
|
|
74353
|
+
each17(style, (propVal, propName) => {
|
|
73562
74354
|
style[propName] === "inherit" && (style[propName] = visualStyle[propName]);
|
|
73563
74355
|
});
|
|
73564
74356
|
}
|
|
@@ -73708,7 +74500,7 @@ function installLegendAction(registers) {
|
|
|
73708
74500
|
}
|
|
73709
74501
|
|
|
73710
74502
|
// src/component/legend/installLegendPlain.ts
|
|
73711
|
-
function
|
|
74503
|
+
function install59(registers) {
|
|
73712
74504
|
registers.registerComponentModel(LegendModel_default);
|
|
73713
74505
|
registers.registerComponentView(LegendView_default);
|
|
73714
74506
|
registers.registerProcessor(registers.PRIORITY.PROCESSOR.SERIES_FILTER, legendFilter);
|
|
@@ -74038,17 +74830,17 @@ function installScrollableLegendAction(registers) {
|
|
|
74038
74830
|
}
|
|
74039
74831
|
|
|
74040
74832
|
// src/component/legend/installLegendScroll.ts
|
|
74041
|
-
function
|
|
74042
|
-
use(
|
|
74833
|
+
function install60(registers) {
|
|
74834
|
+
use(install59);
|
|
74043
74835
|
registers.registerComponentModel(ScrollableLegendModel_default);
|
|
74044
74836
|
registers.registerComponentView(ScrollableLegendView_default);
|
|
74045
74837
|
installScrollableLegendAction(registers);
|
|
74046
74838
|
}
|
|
74047
74839
|
|
|
74048
74840
|
// src/component/legend/install.ts
|
|
74049
|
-
function
|
|
74050
|
-
use(
|
|
74051
|
-
use(
|
|
74841
|
+
function install61(registers) {
|
|
74842
|
+
use(install59);
|
|
74843
|
+
use(install60);
|
|
74052
74844
|
}
|
|
74053
74845
|
|
|
74054
74846
|
// src/component/dataZoom/InsideZoomModel.ts
|
|
@@ -74475,7 +75267,7 @@ var getDirectionInfo = {
|
|
|
74475
75267
|
var InsideZoomView_default = InsideZoomView;
|
|
74476
75268
|
|
|
74477
75269
|
// src/component/dataZoom/installDataZoomInside.ts
|
|
74478
|
-
function
|
|
75270
|
+
function install62(registers) {
|
|
74479
75271
|
installCommon(registers);
|
|
74480
75272
|
registers.registerComponentModel(InsideZoomModel_default);
|
|
74481
75273
|
registers.registerComponentView(InsideZoomView_default);
|
|
@@ -75231,16 +76023,16 @@ function getCursor(orient) {
|
|
|
75231
76023
|
var SliderZoomView_default = SliderZoomView;
|
|
75232
76024
|
|
|
75233
76025
|
// src/component/dataZoom/installDataZoomSlider.ts
|
|
75234
|
-
function
|
|
76026
|
+
function install63(registers) {
|
|
75235
76027
|
registers.registerComponentModel(SliderZoomModel_default);
|
|
75236
76028
|
registers.registerComponentView(SliderZoomView_default);
|
|
75237
76029
|
installCommon(registers);
|
|
75238
76030
|
}
|
|
75239
76031
|
|
|
75240
76032
|
// src/component/dataZoom/install.ts
|
|
75241
|
-
function
|
|
75242
|
-
use(
|
|
75243
|
-
use(
|
|
76033
|
+
function install64(registers) {
|
|
76034
|
+
use(install62);
|
|
76035
|
+
use(install63);
|
|
75244
76036
|
}
|
|
75245
76037
|
|
|
75246
76038
|
// src/visual/visualDefault.ts
|
|
@@ -75290,7 +76082,7 @@ var visualDefault_default = visualDefault;
|
|
|
75290
76082
|
var mapVisual2 = VisualMapping_default.mapVisual;
|
|
75291
76083
|
var eachVisual = VisualMapping_default.eachVisual;
|
|
75292
76084
|
var isArray2 = isArray;
|
|
75293
|
-
var
|
|
76085
|
+
var each18 = each;
|
|
75294
76086
|
var asc3 = asc;
|
|
75295
76087
|
var linearMap2 = linearMap;
|
|
75296
76088
|
var VisualMapModel2 = class extends Component_default {
|
|
@@ -75440,7 +76232,7 @@ var VisualMapModel2 = class extends Component_default {
|
|
|
75440
76232
|
let optAbsent = base3[stateAbsent];
|
|
75441
76233
|
if (optExist && !optAbsent) {
|
|
75442
76234
|
optAbsent = base3[stateAbsent] = {};
|
|
75443
|
-
|
|
76235
|
+
each18(optExist, function(visualData, visualType) {
|
|
75444
76236
|
if (!VisualMapping_default.isValidType(visualType)) {
|
|
75445
76237
|
return;
|
|
75446
76238
|
}
|
|
@@ -75460,7 +76252,7 @@ var VisualMapModel2 = class extends Component_default {
|
|
|
75460
76252
|
const inactiveColor = this.get("inactiveColor");
|
|
75461
76253
|
const itemSymbol = this.getItemSymbol();
|
|
75462
76254
|
const defaultSymbol = itemSymbol || "roundRect";
|
|
75463
|
-
|
|
76255
|
+
each18(this.stateList, function(state) {
|
|
75464
76256
|
const itemSize = this.itemSize;
|
|
75465
76257
|
let visuals = controller2[state];
|
|
75466
76258
|
if (!visuals) {
|
|
@@ -75820,7 +76612,7 @@ function makeHighDownBatch(batch, visualMapModel) {
|
|
|
75820
76612
|
|
|
75821
76613
|
// src/component/visualMap/ContinuousView.ts
|
|
75822
76614
|
var linearMap3 = linearMap;
|
|
75823
|
-
var
|
|
76615
|
+
var each19 = each;
|
|
75824
76616
|
var mathMin11 = Math.min;
|
|
75825
76617
|
var mathMax11 = Math.max;
|
|
75826
76618
|
var HOVER_LINK_SIZE = 12;
|
|
@@ -76148,7 +76940,7 @@ var ContinuousView2 = class extends VisualMapView_default {
|
|
|
76148
76940
|
const handleLabels = shapes.handleLabels;
|
|
76149
76941
|
const itemSize = visualMapModel.itemSize;
|
|
76150
76942
|
const dataExtent = visualMapModel.getExtent();
|
|
76151
|
-
|
|
76943
|
+
each19([0, 1], function(handleIndex) {
|
|
76152
76944
|
const handleThumb = handleThumbs[handleIndex];
|
|
76153
76945
|
handleThumb.setStyle("fill", visualInRange.handlesColor[handleIndex]);
|
|
76154
76946
|
handleThumb.y = handleEnds[handleIndex];
|
|
@@ -76454,13 +77246,13 @@ function getColorVisual(seriesModel, visualMapModel, value, valueState) {
|
|
|
76454
77246
|
}
|
|
76455
77247
|
|
|
76456
77248
|
// src/component/visualMap/preprocessor.ts
|
|
76457
|
-
var
|
|
77249
|
+
var each20 = each;
|
|
76458
77250
|
function visualMapPreprocessor(option) {
|
|
76459
77251
|
let visualMap = option && option.visualMap;
|
|
76460
77252
|
if (!isArray(visualMap)) {
|
|
76461
77253
|
visualMap = visualMap ? [visualMap] : [];
|
|
76462
77254
|
}
|
|
76463
|
-
|
|
77255
|
+
each20(visualMap, function(opt) {
|
|
76464
77256
|
if (!opt) {
|
|
76465
77257
|
return;
|
|
76466
77258
|
}
|
|
@@ -76470,7 +77262,7 @@ function visualMapPreprocessor(option) {
|
|
|
76470
77262
|
}
|
|
76471
77263
|
const pieces = opt.pieces;
|
|
76472
77264
|
if (pieces && isArray(pieces)) {
|
|
76473
|
-
|
|
77265
|
+
each20(pieces, function(piece) {
|
|
76474
77266
|
if (isObject(piece)) {
|
|
76475
77267
|
if (has2(piece, "start") && !has2(piece, "min")) {
|
|
76476
77268
|
piece.min = piece.start;
|
|
@@ -76505,7 +77297,7 @@ function installCommon2(registers) {
|
|
|
76505
77297
|
}
|
|
76506
77298
|
|
|
76507
77299
|
// src/component/visualMap/installVisualMapContinuous.ts
|
|
76508
|
-
function
|
|
77300
|
+
function install65(registers) {
|
|
76509
77301
|
registers.registerComponentModel(ContinuousModel_default);
|
|
76510
77302
|
registers.registerComponentView(ContinuousView_default);
|
|
76511
77303
|
installCommon2(registers);
|
|
@@ -76945,16 +77737,16 @@ PiecewiseVisualMapView.type = "visualMap.piecewise";
|
|
|
76945
77737
|
var PiecewiseView_default = PiecewiseVisualMapView;
|
|
76946
77738
|
|
|
76947
77739
|
// src/component/visualMap/installVisualMapPiecewise.ts
|
|
76948
|
-
function
|
|
77740
|
+
function install66(registers) {
|
|
76949
77741
|
registers.registerComponentModel(PiecewiseModel_default);
|
|
76950
77742
|
registers.registerComponentView(PiecewiseView_default);
|
|
76951
77743
|
installCommon2(registers);
|
|
76952
77744
|
}
|
|
76953
77745
|
|
|
76954
77746
|
// src/component/visualMap/install.ts
|
|
76955
|
-
function
|
|
76956
|
-
use(
|
|
76957
|
-
use(
|
|
77747
|
+
function install67(registers) {
|
|
77748
|
+
use(install65);
|
|
77749
|
+
use(install66);
|
|
76958
77750
|
}
|
|
76959
77751
|
|
|
76960
77752
|
// src/visual/aria.ts
|
|
@@ -77150,7 +77942,7 @@ function ariaPreprocessor(option) {
|
|
|
77150
77942
|
}
|
|
77151
77943
|
|
|
77152
77944
|
// src/component/aria/install.ts
|
|
77153
|
-
function
|
|
77945
|
+
function install68(registers) {
|
|
77154
77946
|
registers.registerPreprocessor(ariaPreprocessor);
|
|
77155
77947
|
registers.registerVisual(registers.PRIORITY.VISUAL.ARIA, ariaVisual);
|
|
77156
77948
|
}
|
|
@@ -77488,7 +78280,7 @@ var sortTransform = {
|
|
|
77488
78280
|
};
|
|
77489
78281
|
|
|
77490
78282
|
// src/component/transform/install.ts
|
|
77491
|
-
function
|
|
78283
|
+
function install69(registers) {
|
|
77492
78284
|
registers.registerTransform(filterTransform);
|
|
77493
78285
|
registers.registerTransform(sortTransform);
|
|
77494
78286
|
}
|
|
@@ -77526,7 +78318,7 @@ var DatasetView = class extends Component_default2 {
|
|
|
77526
78318
|
}
|
|
77527
78319
|
};
|
|
77528
78320
|
DatasetView.type = "dataset";
|
|
77529
|
-
function
|
|
78321
|
+
function install70(registers) {
|
|
77530
78322
|
registers.registerComponentModel(DatasetModel);
|
|
77531
78323
|
registers.registerComponentView(DatasetView);
|
|
77532
78324
|
}
|
|
@@ -79253,44 +80045,47 @@ use([
|
|
|
79253
80045
|
install26,
|
|
79254
80046
|
install27,
|
|
79255
80047
|
install28,
|
|
79256
|
-
install30,
|
|
79257
|
-
install31,
|
|
79258
80048
|
install33,
|
|
79259
80049
|
install32,
|
|
80050
|
+
install30,
|
|
80051
|
+
install31,
|
|
79260
80052
|
install34,
|
|
79261
|
-
install35,
|
|
79262
80053
|
install36,
|
|
80054
|
+
install35,
|
|
79263
80055
|
install37,
|
|
79264
|
-
install38
|
|
80056
|
+
install38,
|
|
80057
|
+
install39,
|
|
80058
|
+
install40,
|
|
80059
|
+
install41
|
|
79265
80060
|
]);
|
|
79266
|
-
use(install40);
|
|
79267
|
-
use(install41);
|
|
79268
|
-
use(install10);
|
|
79269
|
-
use(install42);
|
|
79270
|
-
use(install17);
|
|
79271
80061
|
use(install43);
|
|
79272
80062
|
use(install44);
|
|
80063
|
+
use(install10);
|
|
80064
|
+
use(install45);
|
|
80065
|
+
use(install17);
|
|
79273
80066
|
use(install46);
|
|
79274
80067
|
use(install47);
|
|
79275
|
-
use(install39);
|
|
79276
|
-
use(install48);
|
|
79277
80068
|
use(install49);
|
|
79278
80069
|
use(install50);
|
|
80070
|
+
use(install42);
|
|
79279
80071
|
use(install51);
|
|
79280
80072
|
use(install52);
|
|
79281
80073
|
use(install53);
|
|
79282
80074
|
use(install54);
|
|
79283
80075
|
use(install55);
|
|
80076
|
+
use(install56);
|
|
80077
|
+
use(install57);
|
|
79284
80078
|
use(install58);
|
|
79285
80079
|
use(install61);
|
|
79286
|
-
use(install59);
|
|
79287
|
-
use(install60);
|
|
79288
80080
|
use(install64);
|
|
79289
80081
|
use(install62);
|
|
79290
80082
|
use(install63);
|
|
80083
|
+
use(install67);
|
|
79291
80084
|
use(install65);
|
|
79292
80085
|
use(install66);
|
|
79293
|
-
use(
|
|
80086
|
+
use(install68);
|
|
80087
|
+
use(install69);
|
|
80088
|
+
use(install70);
|
|
79294
80089
|
use(installUniversalTransition);
|
|
79295
80090
|
use(installLabelLayout);
|
|
79296
80091
|
|