k-vtable 1.0.17 → 1.0.19
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/cjs/ListTable.js +2 -1
- package/cjs/ListTable.js.map +1 -1
- package/cjs/PivotChart.d.ts +4 -0
- package/cjs/PivotChart.js +30 -18
- package/cjs/PivotChart.js.map +1 -1
- package/cjs/PivotTable.js +2 -1
- package/cjs/PivotTable.js.map +1 -1
- package/cjs/core/BaseTable.d.ts +4 -4
- package/cjs/core/BaseTable.js +21 -21
- package/cjs/core/BaseTable.js.map +1 -1
- package/cjs/core/record-helper.js +12 -4
- package/cjs/core/record-helper.js.map +1 -1
- package/cjs/data/DataSource.d.ts +1 -0
- package/cjs/data/DataSource.js +6 -9
- package/cjs/data/DataSource.js.map +1 -1
- package/cjs/dataset/dataset.js +1 -1
- package/cjs/dataset/dataset.js.map +1 -1
- package/cjs/event/event.js +17 -8
- package/cjs/event/event.js.map +1 -1
- package/cjs/event/listener/container-dom.js +20 -17
- package/cjs/event/listener/container-dom.js.map +1 -1
- package/cjs/event/self-event-listener/list-table/checkbox.js +4 -2
- package/cjs/event/self-event-listener/list-table/checkbox.js.map +1 -1
- package/cjs/index.d.ts +3 -3
- package/cjs/index.js +4 -4
- package/cjs/index.js.map +1 -1
- package/cjs/layout/chart-helper/get-axis-config.js +73 -28
- package/cjs/layout/chart-helper/get-axis-config.js.map +1 -1
- package/cjs/layout/chart-helper/get-chart-spec.js +19 -9
- package/cjs/layout/chart-helper/get-chart-spec.js.map +1 -1
- package/cjs/layout/pivot-header-layout.d.ts +3 -3
- package/cjs/layout/pivot-header-layout.js +23 -12
- package/cjs/layout/pivot-header-layout.js.map +1 -1
- package/cjs/scenegraph/graphic/chart.d.ts +1 -0
- package/cjs/scenegraph/graphic/chart.js.map +1 -1
- package/cjs/scenegraph/graphic/contributions/chart-render-helper.js +4 -1
- package/cjs/scenegraph/graphic/contributions/chart-render-helper.js.map +1 -1
- package/cjs/scenegraph/graphic/contributions/chart-render.js +4 -1
- package/cjs/scenegraph/graphic/contributions/chart-render.js.map +1 -1
- package/cjs/scenegraph/graphic/contributions/vchart-graphic-picker.js +9 -0
- package/cjs/scenegraph/graphic/contributions/vchart-graphic-picker.js.map +1 -1
- package/cjs/scenegraph/group-creater/cell-type/chart-cell.js +2 -1
- package/cjs/scenegraph/group-creater/cell-type/chart-cell.js.map +1 -1
- package/cjs/scenegraph/layout/compute-col-width.js +3 -1
- package/cjs/scenegraph/layout/compute-col-width.js.map +1 -1
- package/cjs/scenegraph/layout/compute-row-height.js +13 -6
- package/cjs/scenegraph/layout/compute-row-height.js.map +1 -1
- package/cjs/scenegraph/layout/frozen.js +2 -2
- package/cjs/scenegraph/layout/frozen.js.map +1 -1
- package/cjs/scenegraph/scenegraph.js +1 -1
- package/cjs/scenegraph/scenegraph.js.map +1 -1
- package/cjs/scenegraph/select/update-select-border.js +24 -21
- package/cjs/scenegraph/select/update-select-border.js.map +1 -1
- package/cjs/state/cell-move/index.js +1 -1
- package/cjs/state/cell-move/index.js.map +1 -1
- package/cjs/state/resize/update-resize-column.js +1 -1
- package/cjs/state/resize/update-resize-column.js.map +1 -1
- package/cjs/state/select/update-position.d.ts +1 -1
- package/cjs/state/select/update-position.js +7 -7
- package/cjs/state/select/update-position.js.map +1 -1
- package/cjs/state/state.d.ts +2 -1
- package/cjs/state/state.js +5 -4
- package/cjs/state/state.js.map +1 -1
- package/cjs/ts-types/base-table.d.ts +1 -0
- package/cjs/ts-types/base-table.js.map +1 -1
- package/cjs/ts-types/table-engine.d.ts +1 -0
- package/cjs/ts-types/table-engine.js.map +1 -1
- package/cjs/vrender.js.map +1 -1
- package/dist/vtable.js +387 -129
- package/dist/vtable.min.js +2 -2
- package/es/ListTable.js +2 -1
- package/es/ListTable.js.map +1 -1
- package/es/PivotChart.d.ts +4 -0
- package/es/PivotChart.js +30 -18
- package/es/PivotChart.js.map +1 -1
- package/es/PivotTable.js +2 -1
- package/es/PivotTable.js.map +1 -1
- package/es/core/BaseTable.d.ts +4 -4
- package/es/core/BaseTable.js +21 -21
- package/es/core/BaseTable.js.map +1 -1
- package/es/core/record-helper.js +12 -4
- package/es/core/record-helper.js.map +1 -1
- package/es/data/DataSource.d.ts +1 -0
- package/es/data/DataSource.js +6 -9
- package/es/data/DataSource.js.map +1 -1
- package/es/dataset/dataset.js +1 -1
- package/es/dataset/dataset.js.map +1 -1
- package/es/event/event.js +17 -8
- package/es/event/event.js.map +1 -1
- package/es/event/listener/container-dom.js +20 -17
- package/es/event/listener/container-dom.js.map +1 -1
- package/es/event/self-event-listener/list-table/checkbox.js +4 -2
- package/es/event/self-event-listener/list-table/checkbox.js.map +1 -1
- package/es/index.d.ts +3 -3
- package/es/index.js +3 -3
- package/es/index.js.map +1 -1
- package/es/layout/chart-helper/get-axis-config.js +73 -28
- package/es/layout/chart-helper/get-axis-config.js.map +1 -1
- package/es/layout/chart-helper/get-chart-spec.js +19 -9
- package/es/layout/chart-helper/get-chart-spec.js.map +1 -1
- package/es/layout/pivot-header-layout.d.ts +3 -3
- package/es/layout/pivot-header-layout.js +23 -12
- package/es/layout/pivot-header-layout.js.map +1 -1
- package/es/scenegraph/graphic/chart.d.ts +1 -0
- package/es/scenegraph/graphic/chart.js.map +1 -1
- package/es/scenegraph/graphic/contributions/chart-render-helper.js +4 -1
- package/es/scenegraph/graphic/contributions/chart-render-helper.js.map +1 -1
- package/es/scenegraph/graphic/contributions/chart-render.js +4 -1
- package/es/scenegraph/graphic/contributions/chart-render.js.map +1 -1
- package/es/scenegraph/graphic/contributions/vchart-graphic-picker.js +9 -0
- package/es/scenegraph/graphic/contributions/vchart-graphic-picker.js.map +1 -1
- package/es/scenegraph/group-creater/cell-type/chart-cell.js +2 -1
- package/es/scenegraph/group-creater/cell-type/chart-cell.js.map +1 -1
- package/es/scenegraph/layout/compute-col-width.js +3 -1
- package/es/scenegraph/layout/compute-col-width.js.map +1 -1
- package/es/scenegraph/layout/compute-row-height.js +13 -6
- package/es/scenegraph/layout/compute-row-height.js.map +1 -1
- package/es/scenegraph/layout/frozen.js +2 -2
- package/es/scenegraph/layout/frozen.js.map +1 -1
- package/es/scenegraph/scenegraph.js +1 -1
- package/es/scenegraph/scenegraph.js.map +1 -1
- package/es/scenegraph/select/update-select-border.js +24 -21
- package/es/scenegraph/select/update-select-border.js.map +1 -1
- package/es/state/cell-move/index.js +1 -1
- package/es/state/cell-move/index.js.map +1 -1
- package/es/state/resize/update-resize-column.js +1 -1
- package/es/state/resize/update-resize-column.js.map +1 -1
- package/es/state/select/update-position.d.ts +1 -1
- package/es/state/select/update-position.js +7 -7
- package/es/state/select/update-position.js.map +1 -1
- package/es/state/state.d.ts +2 -1
- package/es/state/state.js +5 -4
- package/es/state/state.js.map +1 -1
- package/es/ts-types/base-table.d.ts +1 -0
- package/es/ts-types/base-table.js.map +1 -1
- package/es/ts-types/table-engine.d.ts +1 -0
- package/es/ts-types/table-engine.js.map +1 -1
- package/es/vrender.js.map +1 -1
- package/package.json +6 -6
package/dist/vtable.js
CHANGED
|
@@ -31098,7 +31098,7 @@
|
|
|
31098
31098
|
width: width,
|
|
31099
31099
|
height: height
|
|
31100
31100
|
} = item.attribute;
|
|
31101
|
-
contentWidth < startX + width && (startX = 0, startY += height + spaceRow, pages += 1), index > 0 && item.setAttributes({
|
|
31101
|
+
contentWidth < startX + width && index > 0 && (startX = 0, startY += height + spaceRow, pages += 1), index > 0 && item.setAttributes({
|
|
31102
31102
|
x: startX,
|
|
31103
31103
|
y: startY
|
|
31104
31104
|
}), startX += spaceCol + width;
|
|
@@ -31109,9 +31109,10 @@
|
|
|
31109
31109
|
if (compWidth = this._itemMaxWidth * maxCol + (maxCol - 1) * spaceCol, compHeight = maxHeight, contentWidth = compWidth, comp = this._createPager(compStyle), this._pagerComponent = comp, this._innerView.add(comp), contentHeight = maxHeight - comp.AABBBounds.height() - pagerSpace - renderStartY, contentHeight <= 0) return this._innerView.removeChild(comp), !1;
|
|
31110
31110
|
itemsContainer.getChildren().forEach((item, index) => {
|
|
31111
31111
|
const {
|
|
31112
|
+
width: width,
|
|
31112
31113
|
height: height
|
|
31113
31114
|
} = item.attribute;
|
|
31114
|
-
contentHeight < startY + height && (startY = 0, startX += this._itemMaxWidth + spaceCol, pages += 1), index > 0 && item.setAttributes({
|
|
31115
|
+
contentHeight < startY + height && index > 0 && (startY = 0, startX += this._itemMaxWidth + spaceCol, pages += 1), index > 0 && item.setAttributes({
|
|
31115
31116
|
x: startX,
|
|
31116
31117
|
y: startY
|
|
31117
31118
|
}), startY += spaceRow + height;
|
|
@@ -39425,22 +39426,23 @@
|
|
|
39425
39426
|
}
|
|
39426
39427
|
}
|
|
39427
39428
|
else {
|
|
39428
|
-
|
|
39429
|
-
targetI = this.currentPagerIndexedData[targetIndex];
|
|
39430
|
-
const records = this.records.splice(sourceI, 1);
|
|
39431
|
-
records.unshift(targetI, 0);
|
|
39432
|
-
Array.prototype.splice.apply(this.records, records);
|
|
39429
|
+
this.exchangeRecordData(sourceIndex, targetIndex);
|
|
39433
39430
|
}
|
|
39434
39431
|
this.restoreTreeHierarchyState();
|
|
39435
39432
|
this.updatePagerData();
|
|
39436
39433
|
}
|
|
39437
39434
|
else {
|
|
39438
|
-
|
|
39439
|
-
records.unshift(targetIndex, 0);
|
|
39440
|
-
Array.prototype.splice.apply(this.records, records);
|
|
39435
|
+
this.exchangeRecordData(sourceIndex, targetIndex);
|
|
39441
39436
|
}
|
|
39442
39437
|
}
|
|
39443
39438
|
}
|
|
39439
|
+
exchangeRecordData(sourceIndex, targetIndex) {
|
|
39440
|
+
const sourceI = this.getRecordIndexPaths(sourceIndex);
|
|
39441
|
+
const targetI = this.getRecordIndexPaths(targetIndex);
|
|
39442
|
+
const records = this.records.splice(sourceI, 1);
|
|
39443
|
+
records.unshift(targetI, 0);
|
|
39444
|
+
Array.prototype.splice.apply(this.records, records);
|
|
39445
|
+
}
|
|
39444
39446
|
restoreTreeHierarchyState() {
|
|
39445
39447
|
if (this.hierarchyExpandLevel) {
|
|
39446
39448
|
for (let i = 0; i < this._sourceLength; i++) {
|
|
@@ -46078,8 +46080,17 @@
|
|
|
46078
46080
|
if (table.isPivotChart() &&
|
|
46079
46081
|
row >= table.columnHeaderLevelCount &&
|
|
46080
46082
|
row < table.rowCount - table.bottomFrozenRowCount) {
|
|
46081
|
-
|
|
46082
|
-
|
|
46083
|
+
let ifNeedComputeRowHeight = table.internalProps.layoutMap.indicatorsAsCol;
|
|
46084
|
+
let isHeatmap = false;
|
|
46085
|
+
if (!table.internalProps.layoutMap.indicatorsAsCol) {
|
|
46086
|
+
const chartSpec = table.internalProps.layoutMap.getChartSpec(table.rowHeaderLevelCount, row);
|
|
46087
|
+
if (chartSpec.type === 'heatmap') {
|
|
46088
|
+
isHeatmap = true;
|
|
46089
|
+
ifNeedComputeRowHeight = true;
|
|
46090
|
+
}
|
|
46091
|
+
}
|
|
46092
|
+
if (ifNeedComputeRowHeight) {
|
|
46093
|
+
const optimunHeight = table.internalProps.layoutMap.getOptimunHeightForChart(row, isHeatmap);
|
|
46083
46094
|
if (optimunHeight > 0) {
|
|
46084
46095
|
return optimunHeight;
|
|
46085
46096
|
}
|
|
@@ -49105,7 +49116,7 @@
|
|
|
49105
49116
|
const formatResult = table.options.specFormat(chart.attribute.spec, chartInstance, chart);
|
|
49106
49117
|
if (formatResult.needFormatSpec && formatResult.spec) {
|
|
49107
49118
|
const spec = formatResult.spec;
|
|
49108
|
-
chartInstance.updateSpecSync(spec);
|
|
49119
|
+
chartInstance.updateSpecSync(spec, false, { reuse: false, morph: false });
|
|
49109
49120
|
updateSpec = formatResult.updateSpec ?? true;
|
|
49110
49121
|
}
|
|
49111
49122
|
}
|
|
@@ -49286,7 +49297,7 @@
|
|
|
49286
49297
|
const formatResult = table.options.specFormat(chart.attribute.spec, activeChartInstance, chart);
|
|
49287
49298
|
if (formatResult.needFormatSpec && formatResult.spec) {
|
|
49288
49299
|
const spec = formatResult.spec;
|
|
49289
|
-
activeChartInstance.updateSpecSync(spec);
|
|
49300
|
+
activeChartInstance.updateSpecSync(spec, false, { reuse: false, morph: false });
|
|
49290
49301
|
}
|
|
49291
49302
|
}
|
|
49292
49303
|
const viewBox = chart.getViewBox();
|
|
@@ -50692,6 +50703,19 @@
|
|
|
50692
50703
|
type = 'chart';
|
|
50693
50704
|
numberType = CHART_NUMBER_TYPE;
|
|
50694
50705
|
contains(chart, point, params) {
|
|
50706
|
+
if (chart.attribute.detectPickChartItem) {
|
|
50707
|
+
const vChart = chart.activeChartInstance;
|
|
50708
|
+
if (!vChart) {
|
|
50709
|
+
return false;
|
|
50710
|
+
}
|
|
50711
|
+
const vchartStage = vChart.getStage();
|
|
50712
|
+
vchartStage.dirtyBounds?.clear();
|
|
50713
|
+
const pick = vchartStage.pick(point.x, point.y);
|
|
50714
|
+
if (pick.graphic === null && pick.group.name === 'root') {
|
|
50715
|
+
return false;
|
|
50716
|
+
}
|
|
50717
|
+
return pick;
|
|
50718
|
+
}
|
|
50695
50719
|
if (!chart.AABBBounds.containsPoint(point)) {
|
|
50696
50720
|
return false;
|
|
50697
50721
|
}
|
|
@@ -50898,7 +50922,12 @@
|
|
|
50898
50922
|
}
|
|
50899
50923
|
if (table.isPivotChart() && col >= table.rowHeaderLevelCount && col < table.colCount - table.rightFrozenColCount) {
|
|
50900
50924
|
if (!table.internalProps.layoutMap.indicatorsAsCol) {
|
|
50901
|
-
const
|
|
50925
|
+
const chartSpec = table.internalProps.layoutMap.getChartSpec(col, table.columnHeaderLevelCount);
|
|
50926
|
+
let isHeatmap = false;
|
|
50927
|
+
if (chartSpec.type === 'heatmap') {
|
|
50928
|
+
isHeatmap = true;
|
|
50929
|
+
}
|
|
50930
|
+
const optimunWidth = table.internalProps.layoutMap.getOptimunWidthForChart(col, isHeatmap);
|
|
50902
50931
|
if (optimunWidth > 0) {
|
|
50903
50932
|
return optimunWidth;
|
|
50904
50933
|
}
|
|
@@ -53421,26 +53450,41 @@
|
|
|
53421
53450
|
function updateAllSelectComponent(scene) {
|
|
53422
53451
|
const size0 = scene.customSelectedRangeComponents.size;
|
|
53423
53452
|
let index0 = 0;
|
|
53453
|
+
let firstItem0 = null;
|
|
53424
53454
|
scene.customSelectedRangeComponents.forEach((selectComp, key) => {
|
|
53455
|
+
if (index0 === 0) {
|
|
53456
|
+
firstItem0 = selectComp;
|
|
53457
|
+
}
|
|
53425
53458
|
updateComponent(selectComp, key, scene, {
|
|
53426
53459
|
size: size0,
|
|
53427
|
-
index: ++index0
|
|
53460
|
+
index: ++index0,
|
|
53461
|
+
firstItem: firstItem0
|
|
53428
53462
|
});
|
|
53429
53463
|
});
|
|
53430
53464
|
const size1 = scene.selectingRangeComponents.size;
|
|
53431
53465
|
let index1 = 0;
|
|
53466
|
+
let firstItem1 = null;
|
|
53432
53467
|
scene.selectingRangeComponents.forEach((selectComp, key) => {
|
|
53468
|
+
if (index1 === 0) {
|
|
53469
|
+
firstItem1 = selectComp;
|
|
53470
|
+
}
|
|
53433
53471
|
updateComponent(selectComp, key, scene, {
|
|
53434
53472
|
size: size1,
|
|
53435
|
-
index: ++index1
|
|
53473
|
+
index: ++index1,
|
|
53474
|
+
firstItem: firstItem1
|
|
53436
53475
|
});
|
|
53437
53476
|
});
|
|
53438
53477
|
const size2 = scene.selectedRangeComponents.size;
|
|
53439
53478
|
let index2 = 0;
|
|
53479
|
+
let firstItem2 = null;
|
|
53440
53480
|
scene.selectedRangeComponents.forEach((selectComp, key) => {
|
|
53481
|
+
if (index2 === 0) {
|
|
53482
|
+
firstItem2 = selectComp;
|
|
53483
|
+
}
|
|
53441
53484
|
updateComponent(selectComp, key, scene, {
|
|
53442
53485
|
size: size2,
|
|
53443
|
-
index: ++index2
|
|
53486
|
+
index: ++index2,
|
|
53487
|
+
firstItem: firstItem2
|
|
53444
53488
|
});
|
|
53445
53489
|
});
|
|
53446
53490
|
}
|
|
@@ -53516,9 +53560,13 @@
|
|
|
53516
53560
|
? other.size === 1
|
|
53517
53561
|
? 2
|
|
53518
53562
|
: other.index === 1
|
|
53519
|
-
?
|
|
53520
|
-
: other.index === other.size
|
|
53563
|
+
? selectComp.role === 'rightFrozen'
|
|
53521
53564
|
? [0, 2, 2, 0]
|
|
53565
|
+
: [2, 0, 0, 2]
|
|
53566
|
+
: other.index === other.size
|
|
53567
|
+
? other.firstItem?.role === 'rightFrozen'
|
|
53568
|
+
? [2, 0, 0, 2]
|
|
53569
|
+
: [0, 2, 2, 0]
|
|
53522
53570
|
: 0
|
|
53523
53571
|
: 0
|
|
53524
53572
|
});
|
|
@@ -54799,7 +54847,7 @@
|
|
|
54799
54847
|
else if (scene.table.options.frozenColCount) {
|
|
54800
54848
|
scene.component.setRightFrozenColumnShadow(scene.table.colCount - scene.table.rightFrozenColCount);
|
|
54801
54849
|
}
|
|
54802
|
-
scene.component.
|
|
54850
|
+
scene.component.setBottomFrozenColumnShadow();
|
|
54803
54851
|
scene.component.setTopFrozenColumnShadow();
|
|
54804
54852
|
scene.hasFrozen = true;
|
|
54805
54853
|
scene.frozenColCount = scene.table.frozenColCount;
|
|
@@ -54851,7 +54899,7 @@
|
|
|
54851
54899
|
else if (scene.table.options.rightFrozenColCount) {
|
|
54852
54900
|
scene.component.setRightFrozenColumnShadow(scene.table.colCount - scene.table.rightFrozenColCount);
|
|
54853
54901
|
}
|
|
54854
|
-
scene.component.
|
|
54902
|
+
scene.component.setBottomFrozenColumnShadow();
|
|
54855
54903
|
scene.component.setTopFrozenColumnShadow();
|
|
54856
54904
|
scene.hasFrozen = true;
|
|
54857
54905
|
}
|
|
@@ -57931,7 +57979,7 @@
|
|
|
57931
57979
|
return this.table.getRowsHeight(0, row - 1);
|
|
57932
57980
|
}
|
|
57933
57981
|
else if (row < this.table.rowCount - this.table.bottomFrozenRowCount) {
|
|
57934
|
-
return this.table.getRowsHeight(this.table.
|
|
57982
|
+
return this.table.getRowsHeight(this.table.columnHeaderLevelCount, row - 1);
|
|
57935
57983
|
}
|
|
57936
57984
|
else if (row < this.table.rowCount) {
|
|
57937
57985
|
return this.table.getRowsHeight(this.table.rowCount - this.table.bottomFrozenRowCount, row - 1);
|
|
@@ -58249,10 +58297,10 @@
|
|
|
58249
58297
|
return table._getLayoutCellId(col, row) === table._getLayoutCellId(range1Col, range1Row);
|
|
58250
58298
|
}
|
|
58251
58299
|
|
|
58252
|
-
function updateSelectPosition(state, col, row,
|
|
58300
|
+
function updateSelectPosition(state, col, row, enableShiftSelectMode, enableCtrlSelectMode, isSelectAll, makeSelectCellVisible = true, skipBodyMerge = false) {
|
|
58253
58301
|
const { table, interactionState } = state;
|
|
58254
58302
|
const { scenegraph } = table;
|
|
58255
|
-
const {
|
|
58303
|
+
const { cellPos } = state.select;
|
|
58256
58304
|
state.select.isSelectAll = isSelectAll;
|
|
58257
58305
|
if (col !== -1 && row !== -1 && makeSelectCellVisible) {
|
|
58258
58306
|
table._makeVisibleCell(col, row);
|
|
@@ -58308,11 +58356,7 @@
|
|
|
58308
58356
|
!table.eventManager.isDraging &&
|
|
58309
58357
|
!table.stateManager.isResizeCol()) {
|
|
58310
58358
|
const currentRange = state.select.ranges[state.select.ranges.length - 1];
|
|
58311
|
-
if (
|
|
58312
|
-
if (!isCtrl || disableCtrlMultiSelect) {
|
|
58313
|
-
cellPos.col = col;
|
|
58314
|
-
cellPos.row = row;
|
|
58315
|
-
}
|
|
58359
|
+
if (enableShiftSelectMode && currentRange) {
|
|
58316
58360
|
if (state.select.headerSelectMode !== 'cell' && table.isColumnHeader(col, row)) {
|
|
58317
58361
|
const startCol = Math.min(currentRange.start.col, currentRange.end.col, col);
|
|
58318
58362
|
const endCol = Math.max(currentRange.start.col, currentRange.end.col, col);
|
|
@@ -58358,12 +58402,15 @@
|
|
|
58358
58402
|
else {
|
|
58359
58403
|
currentRange.end = { col, row };
|
|
58360
58404
|
}
|
|
58405
|
+
if (!enableShiftSelectMode) {
|
|
58406
|
+
currentRange.end = currentRange.start;
|
|
58407
|
+
}
|
|
58361
58408
|
scenegraph.deleteLastSelectedRangeComponents();
|
|
58362
58409
|
scenegraph.updateCellSelectBorder(currentRange);
|
|
58363
58410
|
}
|
|
58364
58411
|
else {
|
|
58365
58412
|
let extendSelectRange = true;
|
|
58366
|
-
if (cellPos.col !== -1 && cellPos.row !== -1 &&
|
|
58413
|
+
if (cellPos.col !== -1 && cellPos.row !== -1 && !enableCtrlSelectMode) {
|
|
58367
58414
|
state.select.ranges = [];
|
|
58368
58415
|
scenegraph.deleteAllSelectBorder();
|
|
58369
58416
|
}
|
|
@@ -59098,7 +59145,7 @@
|
|
|
59098
59145
|
else if (state.table.options.rightFrozenColCount) {
|
|
59099
59146
|
state.table.scenegraph.component.setRightFrozenColumnShadow(state.table.colCount - state.table.rightFrozenColCount);
|
|
59100
59147
|
}
|
|
59101
|
-
state.table.scenegraph.component.
|
|
59148
|
+
state.table.scenegraph.component.setBottomFrozenColumnShadow();
|
|
59102
59149
|
state.table.scenegraph.component.setTopFrozenColumnShadow();
|
|
59103
59150
|
state.table.scenegraph.updateNextFrame();
|
|
59104
59151
|
if (state.table.options.customConfig?.notUpdateInColumnRowMove === true) {
|
|
@@ -59240,7 +59287,7 @@
|
|
|
59240
59287
|
else if (state.table.options.rightFrozenColCount) {
|
|
59241
59288
|
state.table.scenegraph.component.setRightFrozenColumnShadow(state.table.colCount - state.table.rightFrozenColCount);
|
|
59242
59289
|
}
|
|
59243
|
-
state.table.scenegraph.component.
|
|
59290
|
+
state.table.scenegraph.component.setBottomFrozenColumnShadow();
|
|
59244
59291
|
state.table.scenegraph.component.setTopFrozenColumnShadow();
|
|
59245
59292
|
state.table.scenegraph.updateNextFrame();
|
|
59246
59293
|
}
|
|
@@ -60356,6 +60403,7 @@
|
|
|
60356
60403
|
this.select.cornerHeaderSelectMode = cornerHeaderSelectMode;
|
|
60357
60404
|
this.select.highlightInRange = highlightInRange;
|
|
60358
60405
|
this.select.disableCtrlMultiSelect = this.table.options.keyboardOptions?.ctrlMultiSelect === false;
|
|
60406
|
+
this.select.disableShiftMultiSelect = this.table.options.keyboardOptions?.shiftMultiSelect === false;
|
|
60359
60407
|
}
|
|
60360
60408
|
isSelected(col, row) {
|
|
60361
60409
|
let seled = false;
|
|
@@ -60436,7 +60484,7 @@
|
|
|
60436
60484
|
updateHoverPos(col, row) {
|
|
60437
60485
|
updateHoverPosition(this, col, row);
|
|
60438
60486
|
}
|
|
60439
|
-
updateSelectPos(col, row,
|
|
60487
|
+
updateSelectPos(col, row, enableShiftSelectMode = false, enableCtrlSelectMode = false, isSelectAll = false, makeSelectCellVisible = true, skipBodyMerge = false) {
|
|
60440
60488
|
if (row !== -1 && row !== -1) {
|
|
60441
60489
|
this.select.selecting = true;
|
|
60442
60490
|
}
|
|
@@ -60454,7 +60502,7 @@
|
|
|
60454
60502
|
}
|
|
60455
60503
|
const oldCellPosCol = this.select.cellPos.col;
|
|
60456
60504
|
const oldCellPosRow = this.select.cellPos.row;
|
|
60457
|
-
updateSelectPosition(this, col, row,
|
|
60505
|
+
updateSelectPosition(this, col, row, enableShiftSelectMode, enableCtrlSelectMode, isSelectAll, makeSelectCellVisible, skipBodyMerge);
|
|
60458
60506
|
if (this.table.hasListeners(TABLE_EVENT_TYPE.SELECTED_CHANGED) &&
|
|
60459
60507
|
(oldCellPosCol !== col || oldCellPosRow !== row)) {
|
|
60460
60508
|
this.table.fireListeners(TABLE_EVENT_TYPE.SELECTED_CHANGED, {
|
|
@@ -62842,7 +62890,8 @@
|
|
|
62842
62890
|
if (isCellDisableSelect(table, targetCol, targetRow)) {
|
|
62843
62891
|
return;
|
|
62844
62892
|
}
|
|
62845
|
-
table.
|
|
62893
|
+
const enableShiftSelectMode = table.options.keyboardOptions?.shiftMultiSelect ?? true;
|
|
62894
|
+
table.selectCell(targetCol, targetRow, e.shiftKey && enableShiftSelectMode);
|
|
62846
62895
|
if ((table.options.keyboardOptions?.moveEditCellOnArrowKeys ?? false) &&
|
|
62847
62896
|
table.editorManager?.editingEditor) {
|
|
62848
62897
|
table.editorManager?.completeEdit();
|
|
@@ -62867,7 +62916,8 @@
|
|
|
62867
62916
|
if (isCellDisableSelect(table, targetCol, targetRow)) {
|
|
62868
62917
|
return;
|
|
62869
62918
|
}
|
|
62870
|
-
table.
|
|
62919
|
+
const enableShiftSelectMode = table.options.keyboardOptions?.shiftMultiSelect ?? true;
|
|
62920
|
+
table.selectCell(targetCol, targetRow, e.shiftKey && enableShiftSelectMode);
|
|
62871
62921
|
}
|
|
62872
62922
|
return;
|
|
62873
62923
|
}
|
|
@@ -62877,7 +62927,8 @@
|
|
|
62877
62927
|
if (isCellDisableSelect(table, targetCol, targetRow)) {
|
|
62878
62928
|
return;
|
|
62879
62929
|
}
|
|
62880
|
-
table.
|
|
62930
|
+
const enableShiftSelectMode = table.options.keyboardOptions?.shiftMultiSelect ?? true;
|
|
62931
|
+
table.selectCell(targetCol, targetRow, e.shiftKey && enableShiftSelectMode);
|
|
62881
62932
|
}
|
|
62882
62933
|
else if ((table.options.keyboardOptions?.editCellOnEnter ?? true) &&
|
|
62883
62934
|
(table.stateManager.select.ranges?.length ?? 0) === 1) {
|
|
@@ -63543,10 +63594,10 @@
|
|
|
63543
63594
|
});
|
|
63544
63595
|
}
|
|
63545
63596
|
function bindGroupCheckboxTreeChange(table) {
|
|
63546
|
-
if (table.internalProps.enableCheckboxCascade !== true) {
|
|
63547
|
-
return;
|
|
63548
|
-
}
|
|
63549
63597
|
table.on('checkbox_state_change', args => {
|
|
63598
|
+
if (table.internalProps.enableCheckboxCascade !== true) {
|
|
63599
|
+
return;
|
|
63600
|
+
}
|
|
63550
63601
|
const { col, row, checked, field } = args;
|
|
63551
63602
|
const isCheckboxAndTree = table.internalProps.columns.some(column => column.tree);
|
|
63552
63603
|
table.internalProps.enableCheckboxCascade && field !== '_vtable_rowSeries_number';
|
|
@@ -63712,10 +63763,10 @@
|
|
|
63712
63763
|
});
|
|
63713
63764
|
}
|
|
63714
63765
|
function bindHeaderCheckboxChange(table) {
|
|
63715
|
-
if (table.internalProps.enableHeaderCheckboxCascade !== true) {
|
|
63716
|
-
return;
|
|
63717
|
-
}
|
|
63718
63766
|
table.on('checkbox_state_change', args => {
|
|
63767
|
+
if (table.internalProps.enableHeaderCheckboxCascade !== true) {
|
|
63768
|
+
return;
|
|
63769
|
+
}
|
|
63719
63770
|
const { col, row, checked, field } = args;
|
|
63720
63771
|
if (table.isHeader(col, row)) {
|
|
63721
63772
|
table.stateManager.setHeaderCheckedState(field, checked);
|
|
@@ -63971,7 +64022,9 @@
|
|
|
63971
64022
|
this.table.stateManager.updateSelectPos(-1, -1);
|
|
63972
64023
|
return false;
|
|
63973
64024
|
}
|
|
63974
|
-
|
|
64025
|
+
const shiftMultiSelect = this.table.keyboardOptions?.shiftMultiSelect ?? true;
|
|
64026
|
+
const ctrlMultiSelect = this.table.keyboardOptions?.ctrlMultiSelect ?? true;
|
|
64027
|
+
this.table.stateManager.updateSelectPos(this.table.stateManager.select.selectInline === 'row' ? this.table.colCount - 1 : eventArgs.col, this.table.stateManager.select.selectInline === 'col' ? this.table.rowCount - 1 : eventArgs.row, eventArgs.event.shiftKey && shiftMultiSelect, (eventArgs.event.ctrlKey || eventArgs.event.metaKey) && ctrlMultiSelect, false, isSelectMoving ? false : this.table.options.select?.makeSelectCellVisible ?? true);
|
|
63975
64028
|
return true;
|
|
63976
64029
|
}
|
|
63977
64030
|
return false;
|
|
@@ -64019,10 +64072,13 @@
|
|
|
64019
64072
|
updateCol = eventArgs.col;
|
|
64020
64073
|
}
|
|
64021
64074
|
}
|
|
64022
|
-
|
|
64075
|
+
const ctrlMultiSelect = this.table.keyboardOptions?.ctrlMultiSelect ?? true;
|
|
64076
|
+
this.table.stateManager.updateSelectPos(isSelectMoving ? updateCol : currentRange.end.col, isSelectMoving ? updateRow : currentRange.end.row, true, (eventArgs.event.ctrlKey || eventArgs.event.metaKey) && ctrlMultiSelect, false, !isSelectMoving);
|
|
64023
64077
|
}
|
|
64024
64078
|
else {
|
|
64025
|
-
|
|
64079
|
+
const shiftMultiSelect = this.table.keyboardOptions?.shiftMultiSelect ?? true;
|
|
64080
|
+
const ctrlMultiSelect = this.table.keyboardOptions?.ctrlMultiSelect ?? true;
|
|
64081
|
+
this.table.stateManager.updateSelectPos(eventArgs.col, eventArgs.row, eventArgs.event.shiftKey && shiftMultiSelect, (eventArgs.event.ctrlKey || eventArgs.event.metaKey) && ctrlMultiSelect, false, !isSelectMoving);
|
|
64026
64082
|
}
|
|
64027
64083
|
return true;
|
|
64028
64084
|
}
|
|
@@ -64202,7 +64258,7 @@
|
|
|
64202
64258
|
return false;
|
|
64203
64259
|
}
|
|
64204
64260
|
release() {
|
|
64205
|
-
this.gesture
|
|
64261
|
+
this.gesture?.release();
|
|
64206
64262
|
this.globalEventListeners.forEach(item => {
|
|
64207
64263
|
if (item.env === 'document') {
|
|
64208
64264
|
document.removeEventListener(item.name, item.callback);
|
|
@@ -64385,7 +64441,7 @@
|
|
|
64385
64441
|
rowValues.push(cell);
|
|
64386
64442
|
});
|
|
64387
64443
|
});
|
|
64388
|
-
const changedCellResults = await table.changeCellValues(col, row, values);
|
|
64444
|
+
const changedCellResults = await table.changeCellValues(col, row, values, true);
|
|
64389
64445
|
if (table.hasListeners(TABLE_EVENT_TYPE.PASTED_DATA)) {
|
|
64390
64446
|
table.fireListeners(TABLE_EVENT_TYPE.PASTED_DATA, {
|
|
64391
64447
|
col,
|
|
@@ -68174,6 +68230,7 @@
|
|
|
68174
68230
|
}
|
|
68175
68231
|
});
|
|
68176
68232
|
const axisRange = getRange('bottom', col, row - 1, col, row, col, row, 0, layout);
|
|
68233
|
+
const { chartType } = getAxisOption(col, row - 1, 'bottom', layout);
|
|
68177
68234
|
if (!axisRange) {
|
|
68178
68235
|
return;
|
|
68179
68236
|
}
|
|
@@ -68192,12 +68249,20 @@
|
|
|
68192
68249
|
axisOption.zero = false;
|
|
68193
68250
|
}
|
|
68194
68251
|
}
|
|
68252
|
+
let domain = [];
|
|
68253
|
+
if (chartType === 'heatmap') {
|
|
68254
|
+
const colDimensionKey = layout.getDimensionKeyInChartSpec(col, layout.rowCount - layout.bottomFrozenRowCount - 1, 'xField');
|
|
68255
|
+
const data = layout.dataset.collectedValues[colDimensionKey] ?? [];
|
|
68256
|
+
const colPath = layout.getColKeysPath(col, row);
|
|
68257
|
+
domain = data?.[colPath ?? ''] ?? [];
|
|
68258
|
+
}
|
|
68195
68259
|
return merge$1({
|
|
68196
68260
|
title: {
|
|
68197
68261
|
visible: true,
|
|
68198
68262
|
text: indicatorInfo?.title
|
|
68199
68263
|
},
|
|
68200
|
-
range
|
|
68264
|
+
range,
|
|
68265
|
+
domain: axisOption?.type === 'linear' ? undefined : Array.from(domain)
|
|
68201
68266
|
}, axisOption, {
|
|
68202
68267
|
orient: 'bottom',
|
|
68203
68268
|
type: axisOption?.type || 'linear',
|
|
@@ -68257,6 +68322,7 @@
|
|
|
68257
68322
|
}
|
|
68258
68323
|
});
|
|
68259
68324
|
const axisRange = getRange('left', col + 1, row, col, row, col, row, 0, layout);
|
|
68325
|
+
const { chartType } = getAxisOption(col + 1, row, 'left', layout);
|
|
68260
68326
|
if (!axisRange) {
|
|
68261
68327
|
return;
|
|
68262
68328
|
}
|
|
@@ -68275,13 +68341,21 @@
|
|
|
68275
68341
|
axisOption.zero = false;
|
|
68276
68342
|
}
|
|
68277
68343
|
}
|
|
68344
|
+
let domain = [];
|
|
68345
|
+
if (chartType === 'heatmap') {
|
|
68346
|
+
const rowDimensionKey = layout.getDimensionKeyInChartSpec(layout.rowHeaderLevelCount, row, 'yField');
|
|
68347
|
+
const data = layout.dataset.collectedValues[rowDimensionKey] ?? [];
|
|
68348
|
+
const rowPath = layout.getRowKeysPath(col, row);
|
|
68349
|
+
domain = data?.[rowPath ?? ''] ?? [];
|
|
68350
|
+
}
|
|
68278
68351
|
return merge$1({
|
|
68279
68352
|
title: {
|
|
68280
68353
|
visible: true,
|
|
68281
68354
|
text: indicatorInfo?.title,
|
|
68282
68355
|
autoRotate: true
|
|
68283
68356
|
},
|
|
68284
|
-
range: range
|
|
68357
|
+
range: range,
|
|
68358
|
+
domain: axisOption?.type === 'linear' ? undefined : Array.from(domain)
|
|
68285
68359
|
}, axisOption, {
|
|
68286
68360
|
orient: 'left',
|
|
68287
68361
|
type: axisOption?.type || 'linear',
|
|
@@ -68300,6 +68374,7 @@
|
|
|
68300
68374
|
row >= layout.columnHeaderLevelCount &&
|
|
68301
68375
|
row < layout.rowCount - layout.bottomFrozenRowCount) {
|
|
68302
68376
|
const axisRange = getRange('right', col - 1, row, layout.rowHeaderLevelCount - 1, row, col, row, 1, layout);
|
|
68377
|
+
const { chartType } = getAxisOption(col - 1, row, 'right', layout);
|
|
68303
68378
|
if (!axisRange) {
|
|
68304
68379
|
return;
|
|
68305
68380
|
}
|
|
@@ -68318,11 +68393,19 @@
|
|
|
68318
68393
|
axisOption.zero = false;
|
|
68319
68394
|
}
|
|
68320
68395
|
}
|
|
68396
|
+
let domain = [];
|
|
68397
|
+
if (chartType === 'heatmap') {
|
|
68398
|
+
const rowDimensionKey = layout.getDimensionKeyInChartSpec(layout.colCount - layout.rightFrozenColCount - 1, row, 'yField');
|
|
68399
|
+
const data = layout.dataset.collectedValues[rowDimensionKey] ?? [];
|
|
68400
|
+
const rowPath = layout.getRowKeysPath(col, row);
|
|
68401
|
+
domain = data?.[rowPath ?? ''] ?? [];
|
|
68402
|
+
}
|
|
68321
68403
|
return merge$1({
|
|
68322
68404
|
range: range,
|
|
68323
68405
|
title: {
|
|
68324
68406
|
autoRotate: true
|
|
68325
|
-
}
|
|
68407
|
+
},
|
|
68408
|
+
domain: axisOption?.type === 'linear' ? undefined : Array.from(domain)
|
|
68326
68409
|
}, axisOption, {
|
|
68327
68410
|
orient: 'right',
|
|
68328
68411
|
type: axisOption?.type || 'linear',
|
|
@@ -68570,38 +68653,80 @@
|
|
|
68570
68653
|
return orient === 'bottom' || orient === 'top';
|
|
68571
68654
|
}
|
|
68572
68655
|
function hasLinearAxis(spec, tableAxesConfig, isHorizontal, isThisXAxis) {
|
|
68573
|
-
if (!isArray$7(spec.axes) || spec.axes.length === 0) {
|
|
68656
|
+
if ((!isArray$7(spec.axes) || spec.axes.length === 0) && (!isArray$7(tableAxesConfig) || tableAxesConfig.length === 0)) {
|
|
68574
68657
|
return (isHorizontal && isThisXAxis) || (!isHorizontal && !isThisXAxis);
|
|
68575
68658
|
}
|
|
68576
|
-
|
|
68577
|
-
|
|
68578
|
-
|
|
68579
|
-
|
|
68580
|
-
|
|
68581
|
-
|
|
68582
|
-
|
|
68583
|
-
|
|
68584
|
-
|
|
68585
|
-
|
|
68586
|
-
|
|
68587
|
-
|
|
68588
|
-
|
|
68659
|
+
if (isArray$7(spec.axes) && spec.axes.length > 0) {
|
|
68660
|
+
for (let i = 0; i < spec.axes.length; i++) {
|
|
68661
|
+
const axisSpec = spec.axes[i];
|
|
68662
|
+
if (!isHorizontal && isThisXAxis && axisSpec.orient === 'bottom') {
|
|
68663
|
+
if (spec.type === 'heatmap') {
|
|
68664
|
+
return axisSpec.type === 'linear';
|
|
68665
|
+
}
|
|
68666
|
+
if (axisSpec.type === 'linear') {
|
|
68667
|
+
return true;
|
|
68668
|
+
}
|
|
68669
|
+
}
|
|
68670
|
+
if (isHorizontal && isThisXAxis && axisSpec.orient === 'bottom') {
|
|
68671
|
+
if (spec.type === 'heatmap') {
|
|
68672
|
+
return axisSpec.type === 'linear';
|
|
68673
|
+
}
|
|
68674
|
+
if (axisSpec.type !== 'linear') {
|
|
68675
|
+
return true;
|
|
68676
|
+
}
|
|
68677
|
+
}
|
|
68678
|
+
if (!isHorizontal && !isThisXAxis && axisSpec.orient === 'left') {
|
|
68679
|
+
if (spec.type === 'heatmap') {
|
|
68680
|
+
return axisSpec.type === 'linear';
|
|
68681
|
+
}
|
|
68682
|
+
if (axisSpec.type !== 'linear') {
|
|
68683
|
+
return true;
|
|
68684
|
+
}
|
|
68685
|
+
}
|
|
68686
|
+
if (isHorizontal && !isThisXAxis && axisSpec.orient === 'left') {
|
|
68687
|
+
if (spec.type === 'heatmap') {
|
|
68688
|
+
return axisSpec.type === 'linear';
|
|
68689
|
+
}
|
|
68690
|
+
if (axisSpec.type === 'linear') {
|
|
68691
|
+
return true;
|
|
68692
|
+
}
|
|
68693
|
+
}
|
|
68589
68694
|
}
|
|
68590
68695
|
}
|
|
68591
68696
|
if (isArray$7(tableAxesConfig) && tableAxesConfig.length > 0) {
|
|
68592
68697
|
for (let i = 0; i < tableAxesConfig.length; i++) {
|
|
68593
68698
|
const axisSpec = tableAxesConfig[i];
|
|
68594
|
-
if (!isHorizontal && isThisXAxis && axisSpec.orient === 'bottom'
|
|
68595
|
-
|
|
68699
|
+
if (!isHorizontal && isThisXAxis && axisSpec.orient === 'bottom') {
|
|
68700
|
+
if (spec.type === 'heatmap') {
|
|
68701
|
+
return axisSpec.type === 'linear';
|
|
68702
|
+
}
|
|
68703
|
+
if (axisSpec.type === 'linear') {
|
|
68704
|
+
return true;
|
|
68705
|
+
}
|
|
68596
68706
|
}
|
|
68597
|
-
if (isHorizontal && isThisXAxis && axisSpec.orient === 'bottom'
|
|
68598
|
-
|
|
68707
|
+
if (isHorizontal && isThisXAxis && axisSpec.orient === 'bottom') {
|
|
68708
|
+
if (spec.type === 'heatmap') {
|
|
68709
|
+
return axisSpec.type === 'linear';
|
|
68710
|
+
}
|
|
68711
|
+
if (axisSpec.type !== 'linear') {
|
|
68712
|
+
return true;
|
|
68713
|
+
}
|
|
68599
68714
|
}
|
|
68600
|
-
if (!isHorizontal && !isThisXAxis && axisSpec.orient === 'left'
|
|
68601
|
-
|
|
68715
|
+
if (!isHorizontal && !isThisXAxis && axisSpec.orient === 'left') {
|
|
68716
|
+
if (spec.type === 'heatmap') {
|
|
68717
|
+
return axisSpec.type === 'linear';
|
|
68718
|
+
}
|
|
68719
|
+
if (axisSpec.type !== 'linear') {
|
|
68720
|
+
return true;
|
|
68721
|
+
}
|
|
68602
68722
|
}
|
|
68603
|
-
if (isHorizontal && !isThisXAxis && axisSpec.orient === 'left'
|
|
68604
|
-
|
|
68723
|
+
if (isHorizontal && !isThisXAxis && axisSpec.orient === 'left') {
|
|
68724
|
+
if (spec.type === 'heatmap') {
|
|
68725
|
+
return axisSpec.type === 'linear';
|
|
68726
|
+
}
|
|
68727
|
+
if (axisSpec.type === 'linear') {
|
|
68728
|
+
return true;
|
|
68729
|
+
}
|
|
68605
68730
|
}
|
|
68606
68731
|
}
|
|
68607
68732
|
}
|
|
@@ -69266,7 +69391,7 @@
|
|
|
69266
69391
|
return TABLE_EVENT_TYPE;
|
|
69267
69392
|
}
|
|
69268
69393
|
options;
|
|
69269
|
-
version = "1.0.
|
|
69394
|
+
version = "1.0.19";
|
|
69270
69395
|
pagination;
|
|
69271
69396
|
id = `VTable${Date.now()}`;
|
|
69272
69397
|
headerStyleCache;
|
|
@@ -69428,7 +69553,8 @@
|
|
|
69428
69553
|
if (Env.mode === 'node') {
|
|
69429
69554
|
return that.canvasWidth / (pixelRatio ?? 1);
|
|
69430
69555
|
}
|
|
69431
|
-
return this._.canvas.width /
|
|
69556
|
+
return (this._.canvas.width /
|
|
69557
|
+
(this._.context.pixelRatio ?? that.internalProps.pixelRatio ?? window.devicePixelRatio));
|
|
69432
69558
|
}
|
|
69433
69559
|
};
|
|
69434
69560
|
internalProps.cellTextOverflows = {};
|
|
@@ -69877,6 +70003,7 @@
|
|
|
69877
70003
|
setPixelRatio(pixelRatio) {
|
|
69878
70004
|
if (pixelRatio !== this.internalProps?.pixelRatio) {
|
|
69879
70005
|
this.internalProps.pixelRatio = pixelRatio;
|
|
70006
|
+
const that = this;
|
|
69880
70007
|
const canvasWidth = this.canvasWidth;
|
|
69881
70008
|
this.internalProps.calcWidthContext = {
|
|
69882
70009
|
_: this.internalProps,
|
|
@@ -69884,7 +70011,8 @@
|
|
|
69884
70011
|
if (Env.mode === 'node') {
|
|
69885
70012
|
return canvasWidth / (pixelRatio ?? 1);
|
|
69886
70013
|
}
|
|
69887
|
-
return this._.canvas.width /
|
|
70014
|
+
return (this._.canvas.width /
|
|
70015
|
+
(this._.context.pixelRatio ?? that.internalProps.pixelRatio ?? window.devicePixelRatio));
|
|
69888
70016
|
}
|
|
69889
70017
|
};
|
|
69890
70018
|
this.scenegraph.setPixelRatio(pixelRatio);
|
|
@@ -70841,7 +70969,7 @@
|
|
|
70841
70969
|
this.scenegraph.stage.release();
|
|
70842
70970
|
this.scenegraph.proxy.release();
|
|
70843
70971
|
internalProps.focusControl.release();
|
|
70844
|
-
const
|
|
70972
|
+
const parentElement = internalProps.element?.parentElement;
|
|
70845
70973
|
if (parentElement && !this.options.canvas) {
|
|
70846
70974
|
parentElement.removeChild(internalProps.element);
|
|
70847
70975
|
}
|
|
@@ -71163,9 +71291,9 @@
|
|
|
71163
71291
|
clearSelected() {
|
|
71164
71292
|
this.stateManager.updateSelectPos(-1, -1);
|
|
71165
71293
|
}
|
|
71166
|
-
selectCell(col, row,
|
|
71294
|
+
selectCell(col, row, enableShiftSelectMode, enableCtrlSelectMode, makeSelectCellVisible, skipBodyMerge = false) {
|
|
71167
71295
|
const isHasSelected = !!this.stateManager.select.ranges?.length;
|
|
71168
|
-
this.stateManager.updateSelectPos(col, row,
|
|
71296
|
+
this.stateManager.updateSelectPos(col, row, enableShiftSelectMode, enableCtrlSelectMode, false, makeSelectCellVisible ?? this.options.select?.makeSelectCellVisible ?? true, skipBodyMerge);
|
|
71169
71297
|
this.stateManager.endSelectCells(true, isHasSelected);
|
|
71170
71298
|
}
|
|
71171
71299
|
selectCells(cellRanges) {
|
|
@@ -71239,37 +71367,37 @@
|
|
|
71239
71367
|
]);
|
|
71240
71368
|
}
|
|
71241
71369
|
}
|
|
71242
|
-
startDragSelectCol(colIndex,
|
|
71370
|
+
startDragSelectCol(colIndex, enableCtrlSelectMode, enableShiftSelectMode) {
|
|
71243
71371
|
const lastSelectRange = this.stateManager.select.ranges[this.stateManager.select.ranges.length - 1];
|
|
71244
|
-
const startCol =
|
|
71372
|
+
const startCol = enableShiftSelectMode && lastSelectRange?.start?.col ? lastSelectRange?.start?.col : colIndex;
|
|
71245
71373
|
const startRow = 0;
|
|
71246
71374
|
const endCol = colIndex;
|
|
71247
71375
|
const endRow = this.rowCount - 1;
|
|
71248
|
-
this.stateManager.updateSelectPos(startCol, startRow,
|
|
71376
|
+
this.stateManager.updateSelectPos(startCol, startRow, enableShiftSelectMode, enableCtrlSelectMode, false, this.options.select?.makeSelectCellVisible ?? true, true);
|
|
71249
71377
|
this.stateManager.updateInteractionState(InteractionState.grabing);
|
|
71250
|
-
this.stateManager.updateSelectPos(endCol, endRow,
|
|
71378
|
+
this.stateManager.updateSelectPos(endCol, endRow, enableShiftSelectMode, enableCtrlSelectMode, false, this.options.select?.makeSelectCellVisible ?? true, true);
|
|
71251
71379
|
}
|
|
71252
|
-
dragSelectCol(colIndex,
|
|
71380
|
+
dragSelectCol(colIndex, enableCtrlSelectMode) {
|
|
71253
71381
|
const currentSelectRanges = this.stateManager.select.ranges;
|
|
71254
71382
|
const lastSelectRange = currentSelectRanges[currentSelectRanges.length - 1];
|
|
71255
71383
|
if (lastSelectRange) {
|
|
71256
71384
|
lastSelectRange.end.col = colIndex;
|
|
71257
71385
|
}
|
|
71258
|
-
this.stateManager.updateSelectPos(colIndex, this.rowCount - 1, false,
|
|
71386
|
+
this.stateManager.updateSelectPos(colIndex, this.rowCount - 1, false, enableCtrlSelectMode, false, this.options.select?.makeSelectCellVisible ?? true, true);
|
|
71259
71387
|
}
|
|
71260
71388
|
endDragSelect() {
|
|
71261
71389
|
this.stateManager.updateInteractionState(InteractionState.default);
|
|
71262
71390
|
this.stateManager.endSelectCells(false, false);
|
|
71263
71391
|
}
|
|
71264
|
-
startDragSelectRow(rowIndex,
|
|
71392
|
+
startDragSelectRow(rowIndex, enableCtrlSelectMode, isShift) {
|
|
71265
71393
|
const lastSelectRange = this.stateManager.select.ranges[this.stateManager.select.ranges.length - 1];
|
|
71266
71394
|
const startCol = 0;
|
|
71267
71395
|
const startRow = isShift && lastSelectRange?.start?.row ? lastSelectRange?.start?.row : rowIndex;
|
|
71268
71396
|
const endCol = this.colCount - 1;
|
|
71269
71397
|
const endRow = rowIndex;
|
|
71270
|
-
this.stateManager.updateSelectPos(startCol, startRow, isShift,
|
|
71398
|
+
this.stateManager.updateSelectPos(startCol, startRow, isShift, enableCtrlSelectMode, false, this.options.select?.makeSelectCellVisible ?? true, true);
|
|
71271
71399
|
this.stateManager.updateInteractionState(InteractionState.grabing);
|
|
71272
|
-
this.stateManager.updateSelectPos(endCol, endRow, isShift,
|
|
71400
|
+
this.stateManager.updateSelectPos(endCol, endRow, isShift, enableCtrlSelectMode, false, this.options.select?.makeSelectCellVisible ?? true, true);
|
|
71273
71401
|
}
|
|
71274
71402
|
dragSelectRow(rowIndex, isCtrl) {
|
|
71275
71403
|
const currentSelectRanges = this.stateManager.select.ranges;
|
|
@@ -73957,7 +74085,11 @@
|
|
|
73957
74085
|
columnObj.chartSpec.type !== 'gauge' &&
|
|
73958
74086
|
columnObj.chartSpec.type !== 'pie' &&
|
|
73959
74087
|
columnObj.chartSpec.type !== 'funnel' &&
|
|
73960
|
-
columnObj.chartSpec.type !== 'rose'
|
|
74088
|
+
columnObj.chartSpec.type !== 'rose' &&
|
|
74089
|
+
columnObj.chartSpec.type !== 'sunburst' &&
|
|
74090
|
+
columnObj.chartSpec.type !== 'treemap' &&
|
|
74091
|
+
columnObj.chartSpec.type !== 'sankey' &&
|
|
74092
|
+
columnObj.chartSpec.type !== 'circlePacking') {
|
|
73961
74093
|
isHasCartesianChart = true;
|
|
73962
74094
|
break;
|
|
73963
74095
|
}
|
|
@@ -73974,7 +74106,11 @@
|
|
|
73974
74106
|
chartSpec.type === 'gauge' ||
|
|
73975
74107
|
chartSpec.type === 'wordCloud' ||
|
|
73976
74108
|
chartSpec.type === 'funnel' ||
|
|
73977
|
-
chartSpec.type === 'rose'
|
|
74109
|
+
chartSpec.type === 'rose' ||
|
|
74110
|
+
chartSpec.type === 'sunburst' ||
|
|
74111
|
+
chartSpec.type === 'treemap' ||
|
|
74112
|
+
chartSpec.type === 'sankey' ||
|
|
74113
|
+
chartSpec.type === 'circlePacking') {
|
|
73978
74114
|
isHasCartesianChart = false;
|
|
73979
74115
|
}
|
|
73980
74116
|
}
|
|
@@ -73994,7 +74130,11 @@
|
|
|
73994
74130
|
columnObj.chartSpec.type !== 'radar' &&
|
|
73995
74131
|
columnObj.chartSpec.type !== 'gauge' &&
|
|
73996
74132
|
columnObj.chartSpec.type !== 'funnel' &&
|
|
73997
|
-
columnObj.chartSpec.type !== 'rose'
|
|
74133
|
+
columnObj.chartSpec.type !== 'rose' &&
|
|
74134
|
+
columnObj.chartSpec.type !== 'sunburst' &&
|
|
74135
|
+
columnObj.chartSpec.type !== 'treemap' &&
|
|
74136
|
+
columnObj.chartSpec.type !== 'sankey' &&
|
|
74137
|
+
columnObj.chartSpec.type !== 'circlePacking') {
|
|
73998
74138
|
isHasCartesianChart = true;
|
|
73999
74139
|
break;
|
|
74000
74140
|
}
|
|
@@ -74009,7 +74149,11 @@
|
|
|
74009
74149
|
chartSpec.type !== 'gauge' &&
|
|
74010
74150
|
chartSpec.type !== 'wordCloud' &&
|
|
74011
74151
|
chartSpec.type !== 'funnel' &&
|
|
74012
|
-
chartSpec.type !== 'rose'
|
|
74152
|
+
chartSpec.type !== 'rose' &&
|
|
74153
|
+
chartSpec.type !== 'sunburst' &&
|
|
74154
|
+
chartSpec.type !== 'treemap' &&
|
|
74155
|
+
chartSpec.type !== 'sankey' &&
|
|
74156
|
+
chartSpec.type !== 'circlePacking') {
|
|
74013
74157
|
isHasCartesianChart = true;
|
|
74014
74158
|
}
|
|
74015
74159
|
}
|
|
@@ -74030,7 +74174,16 @@
|
|
|
74030
74174
|
serie.sortDataByAxis = true;
|
|
74031
74175
|
});
|
|
74032
74176
|
}
|
|
74033
|
-
if (chartSpec.type !== '
|
|
74177
|
+
if (chartSpec.type !== 'pie' &&
|
|
74178
|
+
chartSpec.type !== 'radar' &&
|
|
74179
|
+
chartSpec.type !== 'gauge' &&
|
|
74180
|
+
chartSpec.type !== 'wordCloud' &&
|
|
74181
|
+
chartSpec.type !== 'funnel' &&
|
|
74182
|
+
chartSpec.type !== 'rose' &&
|
|
74183
|
+
chartSpec.type !== 'sunburst' &&
|
|
74184
|
+
chartSpec.type !== 'treemap' &&
|
|
74185
|
+
chartSpec.type !== 'sankey' &&
|
|
74186
|
+
chartSpec.type !== 'circlePacking') {
|
|
74034
74187
|
chartSpec.axes = layout.getChartAxes(col, row);
|
|
74035
74188
|
}
|
|
74036
74189
|
chartSpec.padding = 0;
|
|
@@ -74111,9 +74264,18 @@
|
|
|
74111
74264
|
if (hasSameAxis(axisOption, axes)) {
|
|
74112
74265
|
return;
|
|
74113
74266
|
}
|
|
74267
|
+
const { chartType } = getAxisOption(col, row, index === 0 ? 'left' : 'right', layout);
|
|
74268
|
+
let domain = [];
|
|
74269
|
+
if (chartType === 'heatmap') {
|
|
74270
|
+
const rowDimensionKey = layout.getDimensionKeyInChartSpec(layout.rowHeaderLevelCount, row, 'yField');
|
|
74271
|
+
const data = layout.dataset.collectedValues[rowDimensionKey] ?? [];
|
|
74272
|
+
const rowPath = layout.getRowKeysPath(col, row);
|
|
74273
|
+
domain = data?.[rowPath ?? ''] ?? [];
|
|
74274
|
+
}
|
|
74114
74275
|
axes.push(merge$1({
|
|
74115
74276
|
range,
|
|
74116
|
-
label: { style: { fontSize: DEFAULT_TEXT_FONT_SIZE } }
|
|
74277
|
+
label: { style: { fontSize: DEFAULT_TEXT_FONT_SIZE } },
|
|
74278
|
+
domain: axisOption?.type === 'linear' ? undefined : Array.from(domain)
|
|
74117
74279
|
}, axisOption, {
|
|
74118
74280
|
type: axisOption?.type || 'linear',
|
|
74119
74281
|
orient: index === 0 ? 'left' : 'right',
|
|
@@ -74122,7 +74284,8 @@
|
|
|
74122
74284
|
domainLine: { visible: false },
|
|
74123
74285
|
seriesIndex: axisOption?.seriesId ? undefined : index,
|
|
74124
74286
|
tick: {
|
|
74125
|
-
tickMode: getTickModeFunction(targetTicks, targetRange, range, index)
|
|
74287
|
+
tickMode: getTickModeFunction(targetTicks, targetRange, range, index),
|
|
74288
|
+
visible: false
|
|
74126
74289
|
},
|
|
74127
74290
|
sync: { axisId: NO_AXISID_FRO_VTABLE }
|
|
74128
74291
|
}));
|
|
@@ -76412,6 +76575,9 @@
|
|
|
76412
76575
|
if (deletedRecordIndexs.length === 0) {
|
|
76413
76576
|
return;
|
|
76414
76577
|
}
|
|
76578
|
+
for (let index = 0; index < deletedRecordIndexs.length; index++) {
|
|
76579
|
+
adjustCheckBoxStateMapWithDeleteRecordIndex(table, deletedRecordIndexs[index], 1);
|
|
76580
|
+
}
|
|
76415
76581
|
const oldRowCount = table.transpose ? table.colCount : table.rowCount;
|
|
76416
76582
|
table.refreshRowColCount();
|
|
76417
76583
|
const newRowCount = table.transpose ? table.colCount : table.rowCount;
|
|
@@ -76688,12 +76854,28 @@
|
|
|
76688
76854
|
});
|
|
76689
76855
|
}
|
|
76690
76856
|
else {
|
|
76691
|
-
const
|
|
76692
|
-
|
|
76693
|
-
|
|
76694
|
-
|
|
76695
|
-
|
|
76696
|
-
|
|
76857
|
+
const toDelete = [];
|
|
76858
|
+
const toUpdate = [];
|
|
76859
|
+
checkedState.forEach((value, key) => {
|
|
76860
|
+
const dataIndex = Number(key);
|
|
76861
|
+
if (!isNaN(dataIndex) && dataIndex >= recordIndex) {
|
|
76862
|
+
if (dataIndex === recordIndex) {
|
|
76863
|
+
toDelete.push(key);
|
|
76864
|
+
}
|
|
76865
|
+
else if (dataIndex > recordIndex) {
|
|
76866
|
+
toUpdate.push({
|
|
76867
|
+
originKey: key,
|
|
76868
|
+
targetKey: (dataIndex - count).toString(),
|
|
76869
|
+
value
|
|
76870
|
+
});
|
|
76871
|
+
}
|
|
76872
|
+
}
|
|
76873
|
+
});
|
|
76874
|
+
toDelete.forEach(key => checkedState.delete(key));
|
|
76875
|
+
toUpdate.forEach(({ originKey, targetKey, value }) => {
|
|
76876
|
+
checkedState.delete(originKey);
|
|
76877
|
+
checkedState.set(targetKey, value);
|
|
76878
|
+
});
|
|
76697
76879
|
}
|
|
76698
76880
|
}
|
|
76699
76881
|
function adjustCheckBoxStateMapWithAddRecordIndex(table, recordIndex, count) {
|
|
@@ -77946,7 +78128,7 @@
|
|
|
77946
78128
|
return this.dataSource.getTableIndex(index);
|
|
77947
78129
|
}
|
|
77948
78130
|
release() {
|
|
77949
|
-
this.editorManager
|
|
78131
|
+
this.editorManager?.release();
|
|
77950
78132
|
super.release();
|
|
77951
78133
|
}
|
|
77952
78134
|
expandAllTreeNode() {
|
|
@@ -82143,6 +82325,7 @@
|
|
|
82143
82325
|
data: table.getCellValue(col, row) || [],
|
|
82144
82326
|
cellPadding: padding,
|
|
82145
82327
|
dpr: table.internalProps.pixelRatio,
|
|
82328
|
+
detectPickChartItem: table.options.customConfig?.detectPickChartItem,
|
|
82146
82329
|
axes: table.isPivotChart() ? table.internalProps.layoutMap.getChartAxes(col, row) : [],
|
|
82147
82330
|
tableChartOption: table.options.chartOption,
|
|
82148
82331
|
col,
|
|
@@ -87441,13 +87624,30 @@
|
|
|
87441
87624
|
this._largeCellRangeCache.length = 0;
|
|
87442
87625
|
this._CellHeaderPathMap = new Map();
|
|
87443
87626
|
}
|
|
87444
|
-
getDimensionKeyInChartSpec(_col, _row) {
|
|
87627
|
+
getDimensionKeyInChartSpec(_col, _row, type) {
|
|
87445
87628
|
let dimensionKey;
|
|
87446
87629
|
if (this.indicatorsAsCol === false) {
|
|
87630
|
+
const chartSpec = this.getRawChartSpec(_col, _row);
|
|
87631
|
+
if (chartSpec) {
|
|
87632
|
+
dimensionKey =
|
|
87633
|
+
type === 'yField'
|
|
87634
|
+
? chartSpec.yField ?? chartSpec?.series?.[0]?.yField
|
|
87635
|
+
: chartSpec.type === 'histogram'
|
|
87636
|
+
? chartSpec.x2Field
|
|
87637
|
+
: chartSpec.xField ?? chartSpec?.series?.[0]?.xField;
|
|
87638
|
+
if (dimensionKey) {
|
|
87639
|
+
return dimensionKey;
|
|
87640
|
+
}
|
|
87641
|
+
}
|
|
87447
87642
|
for (let i = 0; i < this.indicatorsDefine.length; i++) {
|
|
87448
87643
|
const chartSpec = this.indicatorsDefine[i].chartSpec;
|
|
87449
87644
|
if (chartSpec) {
|
|
87450
|
-
dimensionKey =
|
|
87645
|
+
dimensionKey =
|
|
87646
|
+
type === 'yField'
|
|
87647
|
+
? chartSpec.yField ?? chartSpec?.series?.[0]?.yField
|
|
87648
|
+
: chartSpec.type === 'histogram'
|
|
87649
|
+
? chartSpec.x2Field
|
|
87650
|
+
: chartSpec.xField ?? chartSpec?.series?.[0]?.xField;
|
|
87451
87651
|
if (dimensionKey) {
|
|
87452
87652
|
return dimensionKey;
|
|
87453
87653
|
}
|
|
@@ -87455,10 +87655,27 @@
|
|
|
87455
87655
|
}
|
|
87456
87656
|
}
|
|
87457
87657
|
else {
|
|
87658
|
+
const chartSpec = this.getRawChartSpec(_col, _row);
|
|
87659
|
+
if (chartSpec) {
|
|
87660
|
+
dimensionKey =
|
|
87661
|
+
type === 'xField'
|
|
87662
|
+
? chartSpec.type === 'histogram'
|
|
87663
|
+
? chartSpec.x2Field
|
|
87664
|
+
: chartSpec.xField ?? chartSpec?.series?.[0]?.xField
|
|
87665
|
+
: chartSpec.yField ?? chartSpec?.series?.[0]?.yField;
|
|
87666
|
+
if (dimensionKey) {
|
|
87667
|
+
return dimensionKey;
|
|
87668
|
+
}
|
|
87669
|
+
}
|
|
87458
87670
|
for (let i = 0; i < this.indicatorsDefine.length; i++) {
|
|
87459
87671
|
const chartSpec = this.indicatorsDefine[i].chartSpec;
|
|
87460
87672
|
if (chartSpec) {
|
|
87461
|
-
dimensionKey =
|
|
87673
|
+
dimensionKey =
|
|
87674
|
+
type === 'xField'
|
|
87675
|
+
? chartSpec.type === 'histogram'
|
|
87676
|
+
? chartSpec.x2Field
|
|
87677
|
+
: chartSpec.xField ?? chartSpec?.series?.[0]?.xField
|
|
87678
|
+
: chartSpec.yField ?? chartSpec?.series?.[0]?.yField;
|
|
87462
87679
|
if (dimensionKey) {
|
|
87463
87680
|
return dimensionKey;
|
|
87464
87681
|
}
|
|
@@ -87584,8 +87801,13 @@
|
|
|
87584
87801
|
}
|
|
87585
87802
|
return null;
|
|
87586
87803
|
}
|
|
87587
|
-
getOptimunHeightForChart(row) {
|
|
87804
|
+
getOptimunHeightForChart(row, isHeatmap) {
|
|
87588
87805
|
const path = this.getCellHeaderPaths(this.rowHeaderLevelCount, row).rowHeaderPaths;
|
|
87806
|
+
if (isHeatmap) {
|
|
87807
|
+
if (path[path.length - 1].indicatorKey) {
|
|
87808
|
+
path.pop();
|
|
87809
|
+
}
|
|
87810
|
+
}
|
|
87589
87811
|
let collectedValues;
|
|
87590
87812
|
for (const key in this.dataset.collectValuesBy) {
|
|
87591
87813
|
if (this.dataset.collectValuesBy[key].type === 'yField' && !this.dataset.collectValuesBy[key].range) {
|
|
@@ -87604,12 +87826,12 @@
|
|
|
87604
87826
|
}
|
|
87605
87827
|
else {
|
|
87606
87828
|
const barWidth = this._chartItemSpanSize || 25;
|
|
87607
|
-
height = (collectedValues?.length ?? 0) * (barWidth + barWidth / 3);
|
|
87829
|
+
height = (collectedValues?.length ?? 0) * (barWidth + (isHeatmap ? 0 : barWidth / 3));
|
|
87608
87830
|
}
|
|
87609
87831
|
const padding = getQuadProps(this._chartPadding ?? this._table.theme.bodyStyle.padding ?? 0);
|
|
87610
87832
|
return height + padding[0] + padding[2];
|
|
87611
87833
|
}
|
|
87612
|
-
getOptimunWidthForChart(col) {
|
|
87834
|
+
getOptimunWidthForChart(col, isHeatmap) {
|
|
87613
87835
|
const path = this.getCellHeaderPaths(col, this.columnHeaderLevelCount).colHeaderPaths;
|
|
87614
87836
|
let collectedValues;
|
|
87615
87837
|
for (const key in this.dataset.collectValuesBy) {
|
|
@@ -87629,7 +87851,7 @@
|
|
|
87629
87851
|
}
|
|
87630
87852
|
else {
|
|
87631
87853
|
const barWidth = this._chartItemSpanSize || 25;
|
|
87632
|
-
width = (collectedValues?.length ?? 0) * (barWidth + barWidth / 3);
|
|
87854
|
+
width = (collectedValues?.length ?? 0) * (barWidth + (isHeatmap ? 0 : barWidth / 3));
|
|
87633
87855
|
}
|
|
87634
87856
|
const padding = getQuadProps(this._chartPadding ?? this._table.theme.bodyStyle.padding ?? 0);
|
|
87635
87857
|
return width + padding[1] + padding[3];
|
|
@@ -88619,7 +88841,7 @@
|
|
|
88619
88841
|
const record = this.records[i];
|
|
88620
88842
|
if (!isNeedFilter || this.filterRecord(record)) {
|
|
88621
88843
|
this.filteredRecords.push(record);
|
|
88622
|
-
this.processRecord(record);
|
|
88844
|
+
record && this.processRecord(record);
|
|
88623
88845
|
}
|
|
88624
88846
|
}
|
|
88625
88847
|
}
|
|
@@ -91684,7 +91906,7 @@
|
|
|
91684
91906
|
}
|
|
91685
91907
|
release() {
|
|
91686
91908
|
this.internalProps.layoutMap.clearHeaderPathCache();
|
|
91687
|
-
this.editorManager
|
|
91909
|
+
this.editorManager?.release();
|
|
91688
91910
|
super.release();
|
|
91689
91911
|
}
|
|
91690
91912
|
}
|
|
@@ -92324,9 +92546,14 @@
|
|
|
92324
92546
|
if (typeof indicators[i] !== 'string' && indicators[i].chartSpec) {
|
|
92325
92547
|
if (indicators[i].chartSpec?.type === 'pie' ||
|
|
92326
92548
|
indicators[i].chartSpec?.type === 'rose' ||
|
|
92549
|
+
indicators[i].chartSpec?.type === 'funnel' ||
|
|
92327
92550
|
indicators[i].chartSpec?.type === 'radar' ||
|
|
92328
92551
|
indicators[i].chartSpec?.type === 'gauge' ||
|
|
92329
|
-
indicators[i].chartSpec?.type === 'wordCloud'
|
|
92552
|
+
indicators[i].chartSpec?.type === 'wordCloud' ||
|
|
92553
|
+
indicators[i].chartSpec?.type === 'sunburst' ||
|
|
92554
|
+
indicators[i].chartSpec?.type === 'treemap' ||
|
|
92555
|
+
indicators[i].chartSpec?.type === 'sankey' ||
|
|
92556
|
+
indicators[i].chartSpec?.type === 'circlePacking') {
|
|
92330
92557
|
continue;
|
|
92331
92558
|
}
|
|
92332
92559
|
const indicatorDefine = indicators[i];
|
|
@@ -92335,11 +92562,15 @@
|
|
|
92335
92562
|
indicatorSpec?.stack !== false &&
|
|
92336
92563
|
(indicatorSpec?.type === 'bar' || indicatorSpec?.type === 'area') &&
|
|
92337
92564
|
(indicatorSpec.stack = true);
|
|
92338
|
-
|
|
92339
|
-
|
|
92340
|
-
|
|
92341
|
-
|
|
92342
|
-
|
|
92565
|
+
if (indicatorSpec?.type !== 'heatmap') {
|
|
92566
|
+
collectValuesBy[indicatorDefine.indicatorKey] = {
|
|
92567
|
+
by: rowKeys,
|
|
92568
|
+
range: true,
|
|
92569
|
+
sumBy: indicatorSpec.type === 'histogram'
|
|
92570
|
+
? columnKeys.concat(indicatorSpec?.xField, indicatorSpec?.x2Field)
|
|
92571
|
+
: indicatorSpec?.stack && columnKeys.concat(indicatorSpec?.xField)
|
|
92572
|
+
};
|
|
92573
|
+
}
|
|
92343
92574
|
if (indicatorSpec.series) {
|
|
92344
92575
|
indicatorSpec.series.forEach((chartSeries) => {
|
|
92345
92576
|
const xField = typeof chartSeries.xField === 'string' ? chartSeries.xField : chartSeries.xField[0];
|
|
@@ -92367,7 +92598,11 @@
|
|
|
92367
92598
|
});
|
|
92368
92599
|
}
|
|
92369
92600
|
else {
|
|
92370
|
-
const xField =
|
|
92601
|
+
const xField = indicatorSpec.type === 'histogram'
|
|
92602
|
+
? indicatorSpec.x2Field
|
|
92603
|
+
: typeof indicatorSpec.xField === 'string'
|
|
92604
|
+
? indicatorSpec.xField
|
|
92605
|
+
: indicatorSpec.xField[0];
|
|
92371
92606
|
collectValuesBy[xField] = {
|
|
92372
92607
|
by: columnKeys,
|
|
92373
92608
|
type: indicatorSpec.direction !== 'horizontal' ? 'xField' : undefined,
|
|
@@ -92380,8 +92615,11 @@
|
|
|
92380
92615
|
const yField = indicatorSpec.yField;
|
|
92381
92616
|
collectValuesBy[yField] = {
|
|
92382
92617
|
by: rowKeys,
|
|
92383
|
-
|
|
92384
|
-
|
|
92618
|
+
type: indicatorSpec.direction !== 'horizontal' ? 'yField' : undefined,
|
|
92619
|
+
range: hasLinearAxis(indicatorSpec, this._axes, indicatorSpec.direction === 'horizontal', false),
|
|
92620
|
+
sumBy: indicatorSpec.type === 'histogram'
|
|
92621
|
+
? columnKeys.concat(indicatorSpec?.xField, indicatorSpec?.x2Field)
|
|
92622
|
+
: indicatorSpec.stack && columnKeys.concat(indicatorSpec?.xField),
|
|
92385
92623
|
sortBy: indicatorSpec.direction === 'horizontal' ? indicatorSpec?.data?.fields?.[yField]?.domain : undefined,
|
|
92386
92624
|
extendRange: parseMarkLineGetExtendRange(indicatorSpec.markLine)
|
|
92387
92625
|
};
|
|
@@ -92392,11 +92630,13 @@
|
|
|
92392
92630
|
indicatorSpec?.stack !== false &&
|
|
92393
92631
|
(indicatorSpec?.type === 'bar' || indicatorSpec?.type === 'area') &&
|
|
92394
92632
|
(indicatorSpec.stack = true);
|
|
92395
|
-
|
|
92396
|
-
|
|
92397
|
-
|
|
92398
|
-
|
|
92399
|
-
|
|
92633
|
+
if (indicatorSpec?.type !== 'heatmap') {
|
|
92634
|
+
collectValuesBy[indicatorDefine.indicatorKey] = {
|
|
92635
|
+
by: columnKeys,
|
|
92636
|
+
range: true,
|
|
92637
|
+
sumBy: indicatorSpec?.stack && rowKeys.concat(indicatorSpec?.yField)
|
|
92638
|
+
};
|
|
92639
|
+
}
|
|
92400
92640
|
if (indicatorSpec.series) {
|
|
92401
92641
|
indicatorSpec.series.forEach((chartSeries) => {
|
|
92402
92642
|
const yField = typeof chartSeries.yField === 'string' ? chartSeries.yField : chartSeries.yField[0];
|
|
@@ -92434,9 +92674,10 @@
|
|
|
92434
92674
|
indicatorSpec?.stack !== false &&
|
|
92435
92675
|
(indicatorSpec?.type === 'bar' || indicatorSpec?.type === 'area') &&
|
|
92436
92676
|
(indicatorSpec.stack = true);
|
|
92437
|
-
const xField = indicatorSpec.xField;
|
|
92677
|
+
const xField = indicatorSpec.type === 'histogram' ? indicatorSpec.x2Field : indicatorSpec.xField;
|
|
92438
92678
|
collectValuesBy[xField] = {
|
|
92439
92679
|
by: columnKeys,
|
|
92680
|
+
type: indicatorSpec.direction === 'horizontal' ? 'xField' : undefined,
|
|
92440
92681
|
range: hasLinearAxis(indicatorSpec, this._axes, indicatorSpec.direction === 'horizontal', true),
|
|
92441
92682
|
sumBy: indicatorSpec.stack && rowKeys.concat(indicatorSpec?.yField),
|
|
92442
92683
|
sortBy: indicatorSpec.direction !== 'horizontal' ? indicatorSpec?.data?.fields?.[xField]?.domain : undefined,
|
|
@@ -92535,6 +92776,23 @@
|
|
|
92535
92776
|
});
|
|
92536
92777
|
}
|
|
92537
92778
|
updateFilterRules(filterRules) {
|
|
92779
|
+
this._throttledUpdateFilterRules(filterRules);
|
|
92780
|
+
}
|
|
92781
|
+
_throttleTimer = null;
|
|
92782
|
+
_latestFilterRules = null;
|
|
92783
|
+
_throttledUpdateFilterRules(filterRules) {
|
|
92784
|
+
this._latestFilterRules = filterRules;
|
|
92785
|
+
if (this._throttleTimer === null) {
|
|
92786
|
+
this._executeFilterUpdate(filterRules);
|
|
92787
|
+
this._throttleTimer = window.setTimeout(() => {
|
|
92788
|
+
if (this._latestFilterRules !== filterRules) {
|
|
92789
|
+
this._executeFilterUpdate(this._latestFilterRules);
|
|
92790
|
+
}
|
|
92791
|
+
this._throttleTimer = null;
|
|
92792
|
+
}, 200);
|
|
92793
|
+
}
|
|
92794
|
+
}
|
|
92795
|
+
_executeFilterUpdate(filterRules) {
|
|
92538
92796
|
this.internalProps.dataConfig.filterRules = filterRules;
|
|
92539
92797
|
this.dataset.updateFilterRules(filterRules);
|
|
92540
92798
|
clearChartCacheImage(this.scenegraph);
|
|
@@ -93430,7 +93688,7 @@
|
|
|
93430
93688
|
}
|
|
93431
93689
|
|
|
93432
93690
|
registerForVrender();
|
|
93433
|
-
const version = "1.0.
|
|
93691
|
+
const version = "1.0.19";
|
|
93434
93692
|
function getIcons() {
|
|
93435
93693
|
return get$2();
|
|
93436
93694
|
}
|
|
@@ -93474,7 +93732,7 @@
|
|
|
93474
93732
|
exports.getTargetCell = getTargetCell;
|
|
93475
93733
|
exports.graphicUtil = graphicUtil;
|
|
93476
93734
|
exports.jsx = jsx;
|
|
93477
|
-
exports.
|
|
93735
|
+
exports.pluginsDefinition = index$1;
|
|
93478
93736
|
exports.register = register$1;
|
|
93479
93737
|
exports.registerAnimation = registerAnimation;
|
|
93480
93738
|
exports.registerAxis = registerAxis;
|