evui 3.3.5 → 3.3.6
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/evui.common.js +44 -27
- package/dist/evui.common.js.map +1 -1
- package/dist/evui.umd.js +44 -27
- package/dist/evui.umd.js.map +1 -1
- package/dist/evui.umd.min.js +1 -1
- package/dist/evui.umd.min.js.map +1 -1
- package/package.json +1 -1
- package/src/components/chart/element/element.tip.js +37 -22
- package/src/components/chart/uses.js +1 -0
package/dist/evui.common.js
CHANGED
|
@@ -7850,7 +7850,7 @@ $({ target: 'Number', stat: true }, {
|
|
|
7850
7850
|
/***/ "9224":
|
|
7851
7851
|
/***/ (function(module) {
|
|
7852
7852
|
|
|
7853
|
-
module.exports = JSON.parse("{\"a\":\"3.3.
|
|
7853
|
+
module.exports = JSON.parse("{\"a\":\"3.3.6\"}");
|
|
7854
7854
|
|
|
7855
7855
|
/***/ }),
|
|
7856
7856
|
|
|
@@ -38531,6 +38531,7 @@ var plugins_pie_modules = {
|
|
|
38531
38531
|
|
|
38532
38532
|
|
|
38533
38533
|
|
|
38534
|
+
|
|
38534
38535
|
var element_tip_modules = {
|
|
38535
38536
|
/**
|
|
38536
38537
|
* Draw TextTip with tip's locationInfo
|
|
@@ -38542,28 +38543,10 @@ var element_tip_modules = {
|
|
|
38542
38543
|
var opt = this.options;
|
|
38543
38544
|
var isHorizontal = !!opt.horizontal;
|
|
38544
38545
|
var maxTipOpt = opt.maxTip;
|
|
38545
|
-
var
|
|
38546
|
+
var selTipOpt = opt.selectItem;
|
|
38546
38547
|
var maxArgs;
|
|
38547
38548
|
|
|
38548
|
-
if (
|
|
38549
|
-
var maxSID = this.minMax[isHorizontal ? 'x' : 'y'][0].maxSID;
|
|
38550
|
-
maxArgs = this.calculateTipInfo(this.seriesList[maxSID], 'max', null);
|
|
38551
|
-
|
|
38552
|
-
if (maxTipOpt.use && maxArgs) {
|
|
38553
|
-
this.drawTextTip(_objectSpread2({
|
|
38554
|
-
opt: maxTipOpt,
|
|
38555
|
-
tipType: 'max'
|
|
38556
|
-
}, maxArgs));
|
|
38557
|
-
|
|
38558
|
-
if (maxTipOpt.showIndicator) {
|
|
38559
|
-
this.drawFixedIndicator(_objectSpread2({
|
|
38560
|
-
opt: maxTipOpt
|
|
38561
|
-
}, maxArgs));
|
|
38562
|
-
}
|
|
38563
|
-
}
|
|
38564
|
-
}
|
|
38565
|
-
|
|
38566
|
-
if (selectItemOpt.use && tipLocationInfo) {
|
|
38549
|
+
if (selTipOpt.use && tipLocationInfo) {
|
|
38567
38550
|
var seriesInfo = this.seriesList[tipLocationInfo === null || tipLocationInfo === void 0 ? void 0 : tipLocationInfo.sId];
|
|
38568
38551
|
|
|
38569
38552
|
if (!(seriesInfo !== null && seriesInfo !== void 0 && seriesInfo.show)) {
|
|
@@ -38572,7 +38555,7 @@ var element_tip_modules = {
|
|
|
38572
38555
|
|
|
38573
38556
|
var selArgs = this.calculateTipInfo(seriesInfo, 'sel', tipLocationInfo);
|
|
38574
38557
|
|
|
38575
|
-
if (
|
|
38558
|
+
if (selArgs) {
|
|
38576
38559
|
var _maxArgs;
|
|
38577
38560
|
|
|
38578
38561
|
var isSamePos = false;
|
|
@@ -38581,17 +38564,25 @@ var element_tip_modules = {
|
|
|
38581
38564
|
isSamePos = true;
|
|
38582
38565
|
}
|
|
38583
38566
|
|
|
38584
|
-
if (
|
|
38567
|
+
if (selTipOpt.showTextTip || selTipOpt.showTip) {
|
|
38568
|
+
if (selTipOpt.tipText === 'label') {
|
|
38569
|
+
var axisOpt = isHorizontal ? opt.axesY[0] : opt.axesX[0];
|
|
38570
|
+
var label = selArgs.label;
|
|
38571
|
+
selArgs.text = axisOpt.type === 'time' ? dayjs_min_default()(label).format(axisOpt.timeFormat) : label;
|
|
38572
|
+
} else {
|
|
38573
|
+
selArgs.text = numberWithComma(selArgs.value);
|
|
38574
|
+
}
|
|
38575
|
+
|
|
38585
38576
|
this.drawTextTip(_objectSpread2({
|
|
38586
|
-
opt:
|
|
38577
|
+
opt: selTipOpt,
|
|
38587
38578
|
tipType: 'sel',
|
|
38588
38579
|
isSamePos: isSamePos
|
|
38589
38580
|
}, selArgs));
|
|
38590
38581
|
}
|
|
38591
38582
|
|
|
38592
|
-
if (
|
|
38583
|
+
if (selTipOpt.showIndicator) {
|
|
38593
38584
|
this.drawFixedIndicator(_objectSpread2({
|
|
38594
|
-
opt:
|
|
38585
|
+
opt: selTipOpt
|
|
38595
38586
|
}, selArgs));
|
|
38596
38587
|
}
|
|
38597
38588
|
}
|
|
@@ -38600,6 +38591,25 @@ var element_tip_modules = {
|
|
|
38600
38591
|
this.lastHitInfo = tipLocationInfo;
|
|
38601
38592
|
}
|
|
38602
38593
|
}
|
|
38594
|
+
|
|
38595
|
+
if (maxTipOpt.use) {
|
|
38596
|
+
var maxSID = this.minMax[isHorizontal ? 'x' : 'y'][0].maxSID;
|
|
38597
|
+
maxArgs = this.calculateTipInfo(this.seriesList[maxSID], 'max', null);
|
|
38598
|
+
|
|
38599
|
+
if (maxTipOpt.use && maxArgs) {
|
|
38600
|
+
maxArgs.text = numberWithComma(maxArgs.value);
|
|
38601
|
+
this.drawTextTip(_objectSpread2({
|
|
38602
|
+
opt: maxTipOpt,
|
|
38603
|
+
tipType: 'max'
|
|
38604
|
+
}, maxArgs));
|
|
38605
|
+
|
|
38606
|
+
if (maxTipOpt.showIndicator) {
|
|
38607
|
+
this.drawFixedIndicator(_objectSpread2({
|
|
38608
|
+
opt: maxTipOpt
|
|
38609
|
+
}, maxArgs));
|
|
38610
|
+
}
|
|
38611
|
+
}
|
|
38612
|
+
}
|
|
38603
38613
|
},
|
|
38604
38614
|
|
|
38605
38615
|
/**
|
|
@@ -38654,17 +38664,23 @@ var element_tip_modules = {
|
|
|
38654
38664
|
}
|
|
38655
38665
|
|
|
38656
38666
|
var value = isHorizontal ? series.minMax.maxX : series.minMax.maxY;
|
|
38667
|
+
var label;
|
|
38657
38668
|
|
|
38658
38669
|
if (tipType === 'sel') {
|
|
38659
38670
|
if (hitInfo && hitInfo.value !== null) {
|
|
38660
38671
|
value = hitInfo.useStack ? hitInfo.acc : hitInfo.value;
|
|
38672
|
+
label = hitInfo.label;
|
|
38661
38673
|
lastTip.value = value;
|
|
38674
|
+
lastTip.label = label;
|
|
38662
38675
|
} else if (lastTip.value !== null) {
|
|
38663
38676
|
value = lastTip.value;
|
|
38677
|
+
label = lastTip.label;
|
|
38664
38678
|
} else if (lastTip.pos !== null) {
|
|
38665
38679
|
var item = type === 'bar' ? this.getItemByLabelIndex(lastTip.pos) : this.getItemByLabel(lastTip.pos);
|
|
38666
38680
|
value = item.useStack ? item.acc : item.value;
|
|
38681
|
+
label = item.label;
|
|
38667
38682
|
lastTip.value = value;
|
|
38683
|
+
lastTip.label = label;
|
|
38668
38684
|
}
|
|
38669
38685
|
}
|
|
38670
38686
|
|
|
@@ -38698,7 +38714,7 @@ var element_tip_modules = {
|
|
|
38698
38714
|
var dataObj = {
|
|
38699
38715
|
dp: dp,
|
|
38700
38716
|
value: value,
|
|
38701
|
-
|
|
38717
|
+
label: label,
|
|
38702
38718
|
type: type
|
|
38703
38719
|
};
|
|
38704
38720
|
return _objectSpread2(_objectSpread2({}, sizeObj), dataObj);
|
|
@@ -39889,6 +39905,7 @@ var DEFAULT_OPTIONS = {
|
|
|
39889
39905
|
selectItem: {
|
|
39890
39906
|
use: false,
|
|
39891
39907
|
showTextTip: false,
|
|
39908
|
+
tipText: 'value',
|
|
39892
39909
|
showTip: false,
|
|
39893
39910
|
showIndicator: false,
|
|
39894
39911
|
fixedPosTop: false,
|