@visactor/vtable 1.4.2-alpha.1 → 1.4.2-alpha.2
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/PivotTable.js +19 -19
- package/cjs/PivotTable.js.map +1 -1
- package/cjs/core/BaseTable.js +3 -5
- package/cjs/core/BaseTable.js.map +1 -1
- package/cjs/core/FouseInput.js +2 -1
- package/cjs/core/row-series-number-helper.js +1 -2
- package/cjs/event/event.js +3 -7
- package/cjs/event/event.js.map +1 -1
- package/cjs/event/listener/table-group.js +15 -25
- package/cjs/event/listener/table-group.js.map +1 -1
- package/cjs/index.d.ts +1 -1
- package/cjs/index.js +1 -1
- package/cjs/index.js.map +1 -1
- package/cjs/layout/tree-helper.js +1 -0
- package/cjs/plugins/themes.js +1 -2
- package/cjs/state/cell-move/index.js +1 -4
- package/cjs/state/cell-move/index.js.map +1 -1
- package/cjs/state/sort/index.js +3 -7
- package/cjs/state/sort/index.js.map +1 -1
- package/cjs/state/state.d.ts +1 -1
- package/cjs/state/state.js +6 -10
- package/cjs/state/state.js.map +1 -1
- package/cjs/vrender.js.map +1 -1
- package/dist/vtable.js +69 -37
- package/dist/vtable.min.js +1 -1
- package/es/PivotTable.js +19 -19
- package/es/PivotTable.js.map +1 -1
- package/es/core/BaseTable.js +3 -5
- package/es/core/BaseTable.js.map +1 -1
- package/es/core/FouseInput.js +2 -1
- package/es/core/row-series-number-helper.js +1 -2
- package/es/event/event.js +2 -6
- package/es/event/event.js.map +1 -1
- package/es/event/listener/table-group.js +15 -25
- package/es/event/listener/table-group.js.map +1 -1
- package/es/index.d.ts +1 -1
- package/es/index.js +1 -1
- package/es/index.js.map +1 -1
- package/es/layout/tree-helper.js +2 -1
- package/es/plugins/themes.js +1 -2
- package/es/state/cell-move/index.js +1 -4
- package/es/state/cell-move/index.js.map +1 -1
- package/es/state/sort/index.js +3 -7
- package/es/state/sort/index.js.map +1 -1
- package/es/state/state.d.ts +1 -1
- package/es/state/state.js +6 -10
- package/es/state/state.js.map +1 -1
- package/es/vrender.js.map +1 -1
- package/package.json +4 -4
package/dist/vtable.js
CHANGED
|
@@ -66137,9 +66137,7 @@
|
|
|
66137
66137
|
table.internalProps.useOneRowHeightFillAll = false;
|
|
66138
66138
|
table.internalProps.layoutMap.clearCellRangeMap();
|
|
66139
66139
|
table.scenegraph.sortCell();
|
|
66140
|
-
const isHasSelected = !!table.stateManager.select.ranges?.length;
|
|
66141
66140
|
table.stateManager.updateSelectPos(-1, -1);
|
|
66142
|
-
table.stateManager.endSelectCells(true, isHasSelected);
|
|
66143
66141
|
}
|
|
66144
66142
|
function executeSort(newState, table, headerDefine) {
|
|
66145
66143
|
const hd = table.internalProps.layoutMap.headerObjects.find((col) => col && col.field === newState.field);
|
|
@@ -66606,9 +66604,7 @@
|
|
|
66606
66604
|
? state.columnMove.y
|
|
66607
66605
|
: 0;
|
|
66608
66606
|
state.table.scenegraph.component.showMoveCol(col, row, delta);
|
|
66609
|
-
const isHasSelected = !!state.select.ranges?.length;
|
|
66610
66607
|
state.table.stateManager.updateSelectPos(-1, -1);
|
|
66611
|
-
state.table.stateManager.endSelectCells(true, isHasSelected);
|
|
66612
66608
|
state.table.scenegraph.updateNextFrame();
|
|
66613
66609
|
}
|
|
66614
66610
|
function updateMoveCol(col, row, x, y, state) {
|
|
@@ -67793,7 +67789,7 @@
|
|
|
67793
67789
|
isSelecting() {
|
|
67794
67790
|
return this.select.selecting;
|
|
67795
67791
|
}
|
|
67796
|
-
endSelectCells(fireListener = true
|
|
67792
|
+
endSelectCells(fireListener = true) {
|
|
67797
67793
|
if (this.select.selecting) {
|
|
67798
67794
|
this.select.selecting = false;
|
|
67799
67795
|
if (this.select.ranges.length === 0) {
|
|
@@ -67829,7 +67825,7 @@
|
|
|
67829
67825
|
row: lastRow
|
|
67830
67826
|
});
|
|
67831
67827
|
}
|
|
67832
|
-
else if (
|
|
67828
|
+
else if (fireListener) {
|
|
67833
67829
|
if (this.select.ranges.length === 0) {
|
|
67834
67830
|
this.table.fireListeners(TABLE_EVENT_TYPE.SELECTED_CLEAR, {});
|
|
67835
67831
|
}
|
|
@@ -67850,9 +67846,7 @@
|
|
|
67850
67846
|
this.columnResize.x = x;
|
|
67851
67847
|
this.columnResize.isRightFrozen = isRightFrozen;
|
|
67852
67848
|
this.table.scenegraph.component.showResizeCol(col, y, isRightFrozen);
|
|
67853
|
-
const isHasSelected = !!this.select.ranges?.length;
|
|
67854
67849
|
this.updateSelectPos(-1, -1);
|
|
67855
|
-
this.endSelectCells(true, isHasSelected);
|
|
67856
67850
|
this.table.scenegraph.updateNextFrame();
|
|
67857
67851
|
}
|
|
67858
67852
|
updateResizeCol(xInTable, yInTable) {
|
|
@@ -67872,9 +67866,7 @@
|
|
|
67872
67866
|
this.rowResize.y = y;
|
|
67873
67867
|
this.rowResize.isBottomFrozen = isBottomFrozen;
|
|
67874
67868
|
this.table.scenegraph.component.showResizeRow(row, x, isBottomFrozen);
|
|
67875
|
-
const isHasSelected = !!this.select.ranges?.length;
|
|
67876
67869
|
this.updateSelectPos(-1, -1);
|
|
67877
|
-
this.endSelectCells(true, isHasSelected);
|
|
67878
67870
|
this.table.scenegraph.updateNextFrame();
|
|
67879
67871
|
}
|
|
67880
67872
|
updateResizeRow(xInTable, yInTable) {
|
|
@@ -68792,9 +68784,7 @@
|
|
|
68792
68784
|
stateManager.updateInteractionState(InteractionState.default);
|
|
68793
68785
|
eventManager.dealTableHover();
|
|
68794
68786
|
if (table.options.select?.outsideClickDeselect) {
|
|
68795
|
-
const isHasSelected = !!stateManager.select.ranges?.length;
|
|
68796
68787
|
eventManager.dealTableSelect();
|
|
68797
|
-
stateManager.endSelectCells(true, isHasSelected);
|
|
68798
68788
|
}
|
|
68799
68789
|
});
|
|
68800
68790
|
table.scenegraph.tableGroup.addEventListener('pointerdown', (e) => {
|
|
@@ -69003,9 +68993,8 @@
|
|
|
69003
68993
|
const eventArgsSet = getCellEventArgsSet(e);
|
|
69004
68994
|
if (eventManager.touchSetTimeout) {
|
|
69005
68995
|
clearTimeout(eventManager.touchSetTimeout);
|
|
69006
|
-
const isHasSelected = !!stateManager.select.ranges?.length;
|
|
69007
68996
|
eventManager.dealTableSelect(eventArgsSet);
|
|
69008
|
-
stateManager.endSelectCells(
|
|
68997
|
+
stateManager.endSelectCells();
|
|
69009
68998
|
eventManager.touchSetTimeout = undefined;
|
|
69010
68999
|
}
|
|
69011
69000
|
}
|
|
@@ -69050,7 +69039,6 @@
|
|
|
69050
69039
|
eventManager.downIcon = hitIcon;
|
|
69051
69040
|
if (!hitIcon &&
|
|
69052
69041
|
!eventManager.checkCellFillhandle(eventArgsSet) &&
|
|
69053
|
-
!stateManager.columnResize.resizing &&
|
|
69054
69042
|
eventManager.checkColumnResize(eventArgsSet, true)) {
|
|
69055
69043
|
table.scenegraph.updateChartState(null);
|
|
69056
69044
|
stateManager.updateInteractionState(InteractionState.grabing);
|
|
@@ -69084,11 +69072,10 @@
|
|
|
69084
69072
|
!target.isDescendantsOf(table.scenegraph.tableGroup)) {
|
|
69085
69073
|
stateManager.updateInteractionState(InteractionState.default);
|
|
69086
69074
|
eventManager.dealTableHover();
|
|
69087
|
-
|
|
69075
|
+
stateManager.endSelectCells();
|
|
69088
69076
|
if (table.options.select?.blankAreaClickDeselect ?? true) {
|
|
69089
69077
|
eventManager.dealTableSelect();
|
|
69090
69078
|
}
|
|
69091
|
-
stateManager.endSelectCells(true, isHasSelected);
|
|
69092
69079
|
stateManager.updateCursor();
|
|
69093
69080
|
table.scenegraph.updateChartState(null);
|
|
69094
69081
|
}
|
|
@@ -70467,9 +70454,7 @@
|
|
|
70467
70454
|
drillClick(this.table);
|
|
70468
70455
|
}
|
|
70469
70456
|
else if (funcType === IconFuncTypeEnum.collapse || funcType === IconFuncTypeEnum.expand) {
|
|
70470
|
-
|
|
70471
|
-
stateManager.updateSelectPos(-1, -1);
|
|
70472
|
-
stateManager.endSelectCells(true, isHasSelected);
|
|
70457
|
+
this.table.stateManager.updateSelectPos(-1, -1);
|
|
70473
70458
|
this.table.toggleHierarchyState(col, row);
|
|
70474
70459
|
}
|
|
70475
70460
|
});
|
|
@@ -74750,7 +74735,7 @@
|
|
|
74750
74735
|
return TABLE_EVENT_TYPE;
|
|
74751
74736
|
}
|
|
74752
74737
|
options;
|
|
74753
|
-
version = "1.4.2-alpha.
|
|
74738
|
+
version = "1.4.2-alpha.2";
|
|
74754
74739
|
pagination;
|
|
74755
74740
|
id = `VTable${Date.now()}`;
|
|
74756
74741
|
headerStyleCache;
|
|
@@ -76391,9 +76376,8 @@
|
|
|
76391
76376
|
this.stateManager.updateSelectPos(-1, -1);
|
|
76392
76377
|
}
|
|
76393
76378
|
selectCell(col, row, isShift, isCtrl) {
|
|
76394
|
-
const isHasSelected = !!this.stateManager.select.ranges?.length;
|
|
76395
76379
|
this.stateManager.updateSelectPos(col, row, isShift, isCtrl);
|
|
76396
|
-
this.stateManager.endSelectCells(
|
|
76380
|
+
this.stateManager.endSelectCells();
|
|
76397
76381
|
}
|
|
76398
76382
|
selectCells(cellRanges) {
|
|
76399
76383
|
const { scrollLeft, scrollTop } = this;
|
|
@@ -76406,7 +76390,7 @@
|
|
|
76406
76390
|
this.stateManager.updateInteractionState(InteractionState.grabing);
|
|
76407
76391
|
this.stateManager.updateSelectPos(cellRange.end.col, cellRange.end.row, false, index >= 1, false, false, true);
|
|
76408
76392
|
}
|
|
76409
|
-
this.stateManager.endSelectCells(false
|
|
76393
|
+
this.stateManager.endSelectCells(false);
|
|
76410
76394
|
this.stateManager.updateInteractionState(InteractionState.default);
|
|
76411
76395
|
});
|
|
76412
76396
|
this.setScrollTop(scrollTop);
|
|
@@ -85731,7 +85715,11 @@
|
|
|
85731
85715
|
const cellDimensionPath = this.internalProps.layoutMap.getCellHeaderPaths(col, row);
|
|
85732
85716
|
if (cellDimensionPath) {
|
|
85733
85717
|
let indicatorPosition;
|
|
85734
|
-
const colKeys = cellDimensionPath.colHeaderPaths
|
|
85718
|
+
const colKeys = cellDimensionPath.colHeaderPaths
|
|
85719
|
+
?.filter((path) => {
|
|
85720
|
+
return !path.virtual;
|
|
85721
|
+
})
|
|
85722
|
+
.map((colPath, index) => {
|
|
85735
85723
|
if (colPath.indicatorKey) {
|
|
85736
85724
|
indicatorPosition = {
|
|
85737
85725
|
position: 'col',
|
|
@@ -85740,7 +85728,11 @@
|
|
|
85740
85728
|
}
|
|
85741
85729
|
return colPath.indicatorKey ?? colPath.value;
|
|
85742
85730
|
});
|
|
85743
|
-
const rowKeys = cellDimensionPath.rowHeaderPaths
|
|
85731
|
+
const rowKeys = cellDimensionPath.rowHeaderPaths
|
|
85732
|
+
?.filter((path) => {
|
|
85733
|
+
return !path.virtual;
|
|
85734
|
+
})
|
|
85735
|
+
.map((rowPath, index) => {
|
|
85744
85736
|
if (rowPath.indicatorKey) {
|
|
85745
85737
|
indicatorPosition = {
|
|
85746
85738
|
position: 'row',
|
|
@@ -85866,7 +85858,11 @@
|
|
|
85866
85858
|
else if (this.dataset) {
|
|
85867
85859
|
let indicatorPosition;
|
|
85868
85860
|
const cellDimensionPath = this.internalProps.layoutMap.getCellHeaderPaths(col, row);
|
|
85869
|
-
const colKeys = cellDimensionPath.colHeaderPaths
|
|
85861
|
+
const colKeys = cellDimensionPath.colHeaderPaths
|
|
85862
|
+
?.filter((path) => {
|
|
85863
|
+
return !path.virtual;
|
|
85864
|
+
})
|
|
85865
|
+
.map((colPath, index) => {
|
|
85870
85866
|
if (colPath.indicatorKey) {
|
|
85871
85867
|
indicatorPosition = {
|
|
85872
85868
|
position: 'col',
|
|
@@ -85875,7 +85871,11 @@
|
|
|
85875
85871
|
}
|
|
85876
85872
|
return colPath.indicatorKey ?? colPath.value;
|
|
85877
85873
|
});
|
|
85878
|
-
const rowKeys = cellDimensionPath.rowHeaderPaths
|
|
85874
|
+
const rowKeys = cellDimensionPath.rowHeaderPaths
|
|
85875
|
+
?.filter((path) => {
|
|
85876
|
+
return !path.virtual;
|
|
85877
|
+
})
|
|
85878
|
+
.map((rowPath, index) => {
|
|
85879
85879
|
if (rowPath.indicatorKey) {
|
|
85880
85880
|
indicatorPosition = {
|
|
85881
85881
|
position: 'row',
|
|
@@ -85914,7 +85914,11 @@
|
|
|
85914
85914
|
else if (this.dataset) {
|
|
85915
85915
|
let indicatorPosition;
|
|
85916
85916
|
const cellDimensionPath = this.internalProps.layoutMap.getCellHeaderPaths(col, row);
|
|
85917
|
-
const colKeys = cellDimensionPath.colHeaderPaths
|
|
85917
|
+
const colKeys = cellDimensionPath.colHeaderPaths
|
|
85918
|
+
?.filter((path) => {
|
|
85919
|
+
return !path.virtual;
|
|
85920
|
+
})
|
|
85921
|
+
.map((colPath, index) => {
|
|
85918
85922
|
if (colPath.indicatorKey) {
|
|
85919
85923
|
indicatorPosition = {
|
|
85920
85924
|
position: 'col',
|
|
@@ -85923,7 +85927,11 @@
|
|
|
85923
85927
|
}
|
|
85924
85928
|
return colPath.indicatorKey ?? colPath.value;
|
|
85925
85929
|
});
|
|
85926
|
-
const rowKeys = cellDimensionPath.rowHeaderPaths
|
|
85930
|
+
const rowKeys = cellDimensionPath.rowHeaderPaths
|
|
85931
|
+
?.filter((path) => {
|
|
85932
|
+
return !path.virtual;
|
|
85933
|
+
})
|
|
85934
|
+
.map((rowPath, index) => {
|
|
85927
85935
|
if (rowPath.indicatorKey) {
|
|
85928
85936
|
indicatorPosition = {
|
|
85929
85937
|
position: 'row',
|
|
@@ -85961,7 +85969,11 @@
|
|
|
85961
85969
|
else if (this.dataset) {
|
|
85962
85970
|
let indicatorPosition;
|
|
85963
85971
|
const cellDimensionPath = this.internalProps.layoutMap.getCellHeaderPaths(col, row);
|
|
85964
|
-
const colKeys = cellDimensionPath.colHeaderPaths
|
|
85972
|
+
const colKeys = cellDimensionPath.colHeaderPaths
|
|
85973
|
+
?.filter((path) => {
|
|
85974
|
+
return !path.virtual;
|
|
85975
|
+
})
|
|
85976
|
+
.map((colPath, index) => {
|
|
85965
85977
|
if (colPath.indicatorKey) {
|
|
85966
85978
|
indicatorPosition = {
|
|
85967
85979
|
position: 'col',
|
|
@@ -85970,7 +85982,11 @@
|
|
|
85970
85982
|
}
|
|
85971
85983
|
return colPath.indicatorKey ?? colPath.value;
|
|
85972
85984
|
});
|
|
85973
|
-
const rowKeys = cellDimensionPath.rowHeaderPaths
|
|
85985
|
+
const rowKeys = cellDimensionPath.rowHeaderPaths
|
|
85986
|
+
?.filter((path) => {
|
|
85987
|
+
return !path.virtual;
|
|
85988
|
+
})
|
|
85989
|
+
.map((rowPath, index) => {
|
|
85974
85990
|
if (rowPath.indicatorKey) {
|
|
85975
85991
|
indicatorPosition = {
|
|
85976
85992
|
position: 'row',
|
|
@@ -86008,7 +86024,11 @@
|
|
|
86008
86024
|
else if (this.dataset) {
|
|
86009
86025
|
let indicatorPosition;
|
|
86010
86026
|
const cellDimensionPath = this.internalProps.layoutMap.getCellHeaderPaths(col, row);
|
|
86011
|
-
const colKeys = cellDimensionPath.colHeaderPaths
|
|
86027
|
+
const colKeys = cellDimensionPath.colHeaderPaths
|
|
86028
|
+
?.filter((path) => {
|
|
86029
|
+
return !path.virtual;
|
|
86030
|
+
})
|
|
86031
|
+
.map((colPath, index) => {
|
|
86012
86032
|
if (colPath.indicatorKey) {
|
|
86013
86033
|
indicatorPosition = {
|
|
86014
86034
|
position: 'col',
|
|
@@ -86017,7 +86037,11 @@
|
|
|
86017
86037
|
}
|
|
86018
86038
|
return colPath.indicatorKey ?? colPath.value;
|
|
86019
86039
|
});
|
|
86020
|
-
const rowKeys = cellDimensionPath.rowHeaderPaths
|
|
86040
|
+
const rowKeys = cellDimensionPath.rowHeaderPaths
|
|
86041
|
+
?.filter((path) => {
|
|
86042
|
+
return !path.virtual;
|
|
86043
|
+
})
|
|
86044
|
+
.map((rowPath, index) => {
|
|
86021
86045
|
if (rowPath.indicatorKey) {
|
|
86022
86046
|
indicatorPosition = {
|
|
86023
86047
|
position: 'row',
|
|
@@ -86659,10 +86683,18 @@
|
|
|
86659
86683
|
cellDimensionPath.rowHeaderPaths[cellDimensionPath.rowHeaderPaths.length - 1].dimensionKey, oldValue, newValue);
|
|
86660
86684
|
}
|
|
86661
86685
|
else {
|
|
86662
|
-
const colKeys = cellDimensionPath.colHeaderPaths
|
|
86686
|
+
const colKeys = cellDimensionPath.colHeaderPaths
|
|
86687
|
+
?.filter((path) => {
|
|
86688
|
+
return !path.virtual;
|
|
86689
|
+
})
|
|
86690
|
+
.map((colPath) => {
|
|
86663
86691
|
return colPath.indicatorKey ?? colPath.value;
|
|
86664
86692
|
});
|
|
86665
|
-
const rowKeys = cellDimensionPath.rowHeaderPaths
|
|
86693
|
+
const rowKeys = cellDimensionPath.rowHeaderPaths
|
|
86694
|
+
?.filter((path) => {
|
|
86695
|
+
return !path.virtual;
|
|
86696
|
+
})
|
|
86697
|
+
.map((rowPath) => {
|
|
86666
86698
|
return rowPath.indicatorKey ?? rowPath.value;
|
|
86667
86699
|
});
|
|
86668
86700
|
this.dataset.changeTreeNodeValue(!this.internalProps.layoutMap.indicatorsAsCol ? rowKeys.slice(0, -1) : rowKeys, this.internalProps.layoutMap.indicatorsAsCol ? colKeys.slice(0, -1) : colKeys, this.internalProps.layoutMap.getIndicatorKey(col, row), newValue);
|
|
@@ -88351,7 +88383,7 @@
|
|
|
88351
88383
|
}
|
|
88352
88384
|
|
|
88353
88385
|
registerForVrender();
|
|
88354
|
-
const version = "1.4.2-alpha.
|
|
88386
|
+
const version = "1.4.2-alpha.2";
|
|
88355
88387
|
function getIcons() {
|
|
88356
88388
|
return get$2();
|
|
88357
88389
|
}
|