@visactor/vtable-calendar 1.17.3-alpha.8 → 1.17.3
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/vtable-calendar.js +217 -113
- package/dist/vtable-calendar.min.js +1 -1
- package/package.json +5 -5
package/dist/vtable-calendar.js
CHANGED
|
@@ -27723,6 +27723,7 @@
|
|
|
27723
27723
|
AFTER_SORT: "after_sort",
|
|
27724
27724
|
FREEZE_CLICK: "freeze_click",
|
|
27725
27725
|
SCROLL: "scroll",
|
|
27726
|
+
CAN_SCROLL: "can_scroll",
|
|
27726
27727
|
SCROLL_HORIZONTAL_END: "scroll_horizontal_end",
|
|
27727
27728
|
SCROLL_VERTICAL_END: "scroll_vertical_end",
|
|
27728
27729
|
DROPDOWN_MENU_CLICK: "dropdown_menu_click",
|
|
@@ -32238,7 +32239,7 @@
|
|
|
32238
32239
|
}
|
|
32239
32240
|
function getCellCornerRadius(col, row, table) {
|
|
32240
32241
|
const tableCornerRadius = table.theme.frameStyle.cornerRadius;
|
|
32241
|
-
if (Array.isArray(tableCornerRadius)) {
|
|
32242
|
+
if (table.theme.cellInnerBorder) if (Array.isArray(tableCornerRadius)) {
|
|
32242
32243
|
if (0 === col && 0 === row) return [tableCornerRadius[0], 0, 0, 0];
|
|
32243
32244
|
if (col === table.colCount - 1 && 0 === row) return [0, tableCornerRadius[1], 0, 0];
|
|
32244
32245
|
if (0 === col && row === table.rowCount - 1) return [0, 0, 0, tableCornerRadius[3]];
|
|
@@ -32364,7 +32365,7 @@
|
|
|
32364
32365
|
}
|
|
32365
32366
|
updateCustomCell(componentId, isHeaderCustomLayout) {
|
|
32366
32367
|
const table = this.table;
|
|
32367
|
-
if (table.isPivotTable()) {
|
|
32368
|
+
if ("autoWidth" === table.widthMode && table.scenegraph.recalculateColWidths(), (table.isAutoRowHeight() || "auto" === table.internalProps.defaultRowHeight && !isHeaderCustomLayout || "auto" === table.internalProps.defaultHeaderRowHeight && isHeaderCustomLayout) && table.scenegraph.recalculateRowHeights(), table.isPivotTable()) {
|
|
32368
32369
|
const ranges = getUpdateCustomCellRangeInPivotTable(componentId, table, isHeaderCustomLayout);
|
|
32369
32370
|
for (let i = 0; i < ranges.length; i++) {
|
|
32370
32371
|
const range = ranges[i];
|
|
@@ -32374,7 +32375,7 @@
|
|
|
32374
32375
|
const range = getUpdateCustomCellRangeInListTable(componentId, table, isHeaderCustomLayout);
|
|
32375
32376
|
for (let col = range.start.col; col <= range.end.col; col++) for (let row = range.start.row; row <= range.end.row; row++) table.scenegraph.updateCellContent(col, row);
|
|
32376
32377
|
}
|
|
32377
|
-
|
|
32378
|
+
table.scenegraph.renderSceneGraph();
|
|
32378
32379
|
}
|
|
32379
32380
|
getCustomLayoutFunc(col, row) {
|
|
32380
32381
|
var _a;
|
|
@@ -34062,8 +34063,9 @@
|
|
|
34062
34063
|
}
|
|
34063
34064
|
function updateCell$1(col, row, table, addNew, isShadow, forceFastUpdate) {
|
|
34064
34065
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t;
|
|
34065
|
-
const oldCellGroup = table.scenegraph.highPerformanceGetCell(col, row, !0)
|
|
34066
|
-
|
|
34066
|
+
const oldCellGroup = table.scenegraph.highPerformanceGetCell(col, row, !0);
|
|
34067
|
+
if ("cell" !== oldCellGroup.role && !addNew) return;
|
|
34068
|
+
const cellLocation = table.getCellLocation(col, row);
|
|
34067
34069
|
let isMerge,
|
|
34068
34070
|
range,
|
|
34069
34071
|
customStyle,
|
|
@@ -34627,7 +34629,7 @@
|
|
|
34627
34629
|
const layoutMap = table.internalProps.layoutMap;
|
|
34628
34630
|
table.isPivotTable() && (layoutMap.enableUseGetBodyCache(), layoutMap.enableUseHeaderPathCache()), table.defaultHeaderRowHeight, table.defaultHeaderColWidth;
|
|
34629
34631
|
const isDefaultHeaderHasAuto = "auto" === table.defaultHeaderRowHeight || isArray$7(table.defaultHeaderRowHeight) && table.defaultHeaderRowHeight.some(item => "auto" === item),
|
|
34630
|
-
isAllRowsAuto = table.isAutoRowHeight() || "adaptive" === table.heightMode && !1 !== table.options.autoHeightInAdaptiveMode,
|
|
34632
|
+
isAllRowsAuto = table.isAutoRowHeight(rowStart) || "adaptive" === table.heightMode && !1 !== table.options.autoHeightInAdaptiveMode,
|
|
34631
34633
|
isDefaultRowHeightIsAuto = "auto" === table.options.defaultRowHeight;
|
|
34632
34634
|
if (isAllRowsAuto || isDefaultHeaderHasAuto || isDefaultRowHeightIsAuto) {
|
|
34633
34635
|
rowStart = null != rowStart ? rowStart : 0, rowEnd = null != rowEnd ? rowEnd : table.rowCount - 1, (0 === rowStart && rowEnd === table.rowCount - 1 || isClearRowRangeHeightsMap) && table._clearRowRangeHeightsMap();
|
|
@@ -34643,7 +34645,7 @@
|
|
|
34643
34645
|
const height = computeRowHeight(row, 0, table.colCount - 1, table);
|
|
34644
34646
|
update ? newHeights[row] = Math.round(height) : table._setRowHeight(row, height);
|
|
34645
34647
|
}
|
|
34646
|
-
if (rowEnd < table.columnHeaderLevelCount || !isAllRowsAuto && !isDefaultRowHeightIsAuto) ;else if (table.internalProps.transpose || table.isPivotTable() && !table.internalProps.layoutMap.indicatorsAsCol || table.options.customComputeRowHeight || !checkFixedStyleAndNoWrap(table)) {
|
|
34648
|
+
if (rowEnd < table.columnHeaderLevelCount || !isAllRowsAuto && !isDefaultRowHeightIsAuto) ;else if (table.internalProps.transpose || table.isPivotTable() && !table.internalProps.layoutMap.indicatorsAsCol || table.options.customComputeRowHeight || !checkFixedStyleAndNoWrap(table, rowStart)) {
|
|
34647
34649
|
if (table.internalProps.transpose || table.isPivotTable() && !table.internalProps.layoutMap.indicatorsAsCol) for (let row = Math.max(rowStart, table.columnHeaderLevelCount); row <= rowEnd; row++) {
|
|
34648
34650
|
let height;
|
|
34649
34651
|
height = checkFixedStyleAndNoWrapForTranspose(table, row) ? computeRowHeight(row, 0, table.rowHeaderLevelCount, table) : computeRowHeight(row, 0, table.colCount - 1, table), update ? newHeights[row] = Math.round(height) : table._setRowHeight(row, height);
|
|
@@ -34717,7 +34719,7 @@
|
|
|
34717
34719
|
}
|
|
34718
34720
|
function computeRowHeight(row, startCol, endCol, table) {
|
|
34719
34721
|
var _a;
|
|
34720
|
-
if (!(table.isAutoRowHeight() || "adaptive" === table.heightMode && !1 !== table.options.autoHeightInAdaptiveMode) && "auto" !== table.getDefaultRowHeight(row)) return table.getDefaultRowHeight(row);
|
|
34722
|
+
if (!(table.isAutoRowHeight(row) || "adaptive" === table.heightMode && !1 !== table.options.autoHeightInAdaptiveMode) && "auto" !== table.getDefaultRowHeight(row)) return table.getDefaultRowHeight(row);
|
|
34721
34723
|
let maxHeight;
|
|
34722
34724
|
if (table.options.customComputeRowHeight) {
|
|
34723
34725
|
const customRowHeight = table.options.customComputeRowHeight({
|
|
@@ -34755,13 +34757,13 @@
|
|
|
34755
34757
|
const defaultHeight = table.getDefaultRowHeight(row);
|
|
34756
34758
|
return isNumber$4(defaultHeight) ? defaultHeight : table.defaultRowHeight;
|
|
34757
34759
|
}
|
|
34758
|
-
function checkFixedStyleAndNoWrap(table) {
|
|
34760
|
+
function checkFixedStyleAndNoWrap(table, rowStart) {
|
|
34759
34761
|
var _a, _b, _c;
|
|
34760
34762
|
const {
|
|
34761
34763
|
layoutMap: layoutMap
|
|
34762
34764
|
} = table.internalProps,
|
|
34763
34765
|
row = table.columnHeaderLevelCount;
|
|
34764
|
-
if ((table.internalProps.autoWrapText || table.internalProps.enableLineBreak || table.isPivotChart()) && (table.isAutoRowHeight() || "adaptive" === table.options.heightMode)) return !1;
|
|
34766
|
+
if ((table.internalProps.autoWrapText || table.internalProps.enableLineBreak || table.isPivotChart()) && (table.isAutoRowHeight(rowStart) || "adaptive" === table.options.heightMode)) return !1;
|
|
34765
34767
|
for (let col = 0; col < table.colCount; col++) {
|
|
34766
34768
|
const cellDefine = layoutMap.getBody(col, row);
|
|
34767
34769
|
if ("radio" === cellDefine.cellType) return !1;
|
|
@@ -34776,7 +34778,7 @@
|
|
|
34776
34778
|
const {
|
|
34777
34779
|
layoutMap: layoutMap
|
|
34778
34780
|
} = table.internalProps;
|
|
34779
|
-
if ((table.internalProps.autoWrapText || table.internalProps.enableLineBreak) && (table.isAutoRowHeight() || "adaptive" === table.options.heightMode)) return !1;
|
|
34781
|
+
if ((table.internalProps.autoWrapText || table.internalProps.enableLineBreak) && (table.isAutoRowHeight(row) || "adaptive" === table.options.heightMode)) return !1;
|
|
34780
34782
|
const cellDefine = layoutMap.getBody(table.rowHeaderLevelCount, row);
|
|
34781
34783
|
if ("function" == typeof cellDefine.style || "function" == typeof cellDefine.icon || (null === (_a = cellDefine.define) || void 0 === _a ? void 0 : _a.customRender) || (null === (_b = cellDefine.define) || void 0 === _b ? void 0 : _b.customLayout) || "function" == typeof (null === (_c = cellDefine.define) || void 0 === _c ? void 0 : _c.icon)) return !1;
|
|
34782
34784
|
const cellStyle = table._getCellStyle(table.rowHeaderLevelCount, row);
|
|
@@ -34787,7 +34789,7 @@
|
|
|
34787
34789
|
const {
|
|
34788
34790
|
layoutMap: layoutMap
|
|
34789
34791
|
} = table.internalProps;
|
|
34790
|
-
if (table.internalProps.autoWrapText && (table.isAutoRowHeight() || "adaptive" === table.options.heightMode)) return !1;
|
|
34792
|
+
if (table.internalProps.autoWrapText && (table.isAutoRowHeight(row) || "adaptive" === table.options.heightMode)) return !1;
|
|
34791
34793
|
const headerDefine = layoutMap.getHeader(table.rowHeaderLevelCount, row);
|
|
34792
34794
|
if ("function" == typeof headerDefine.style || "function" == typeof headerDefine.icons || (null === (_a = headerDefine.define) || void 0 === _a ? void 0 : _a.headerCustomRender) || (null === (_b = headerDefine.define) || void 0 === _b ? void 0 : _b.headerCustomLayout) || "function" == typeof (null === (_c = headerDefine.define) || void 0 === _c ? void 0 : _c.icon)) return !1;
|
|
34793
34795
|
const headerStyle = table._getCellStyle(table.rowHeaderLevelCount, row);
|
|
@@ -34818,7 +34820,8 @@
|
|
|
34818
34820
|
rect: getCellRect$1(col, row, table),
|
|
34819
34821
|
table: table,
|
|
34820
34822
|
originCol: col,
|
|
34821
|
-
originRow: row
|
|
34823
|
+
originRow: row,
|
|
34824
|
+
forComputation: !0
|
|
34822
34825
|
};
|
|
34823
34826
|
if ("react-custom-layout" === customLayout && (customLayout = (null === (_d = table.reactCustomLayout) || void 0 === _d ? void 0 : _d.getCustomLayoutFunc(col, row)) || emptyCustomLayout), isFunction$5(customLayout)) {
|
|
34824
34827
|
const customLayoutObj = customLayout(arg);
|
|
@@ -37734,7 +37737,8 @@
|
|
|
37734
37737
|
rect: getCellRect(col, row, table),
|
|
37735
37738
|
table: table,
|
|
37736
37739
|
originCol: col,
|
|
37737
|
-
originRow: row
|
|
37740
|
+
originRow: row,
|
|
37741
|
+
forComputation: !0
|
|
37738
37742
|
};
|
|
37739
37743
|
if ("react-custom-layout" === customLayout && (customLayout = (null === (_d = table.reactCustomLayout) || void 0 === _d ? void 0 : _d.getCustomLayoutFunc(col, row)) || emptyCustomLayout), isFunction$5(customLayout)) {
|
|
37740
37744
|
const customLayoutObj = customLayout(arg);
|
|
@@ -38090,7 +38094,7 @@
|
|
|
38090
38094
|
rightBottomCornerGroup: rightBottomCornerGroup
|
|
38091
38095
|
} = table.scenegraph;
|
|
38092
38096
|
let distCol, distRow, distColForCompute, distRowForCompute;
|
|
38093
|
-
proxy.setParamsForRow(), proxy.setParamsForColumn(), "adaptive" === table.widthMode || table.options.autoWrapText && ("adaptive" === table.heightMode || table.isAutoRowHeight()) ? (distColForCompute = table.colCount - 1, distCol = Math.min(proxy.firstScreenColLimit - 1, table.colCount - 1)) : distCol = Math.min(proxy.firstScreenColLimit - 1, table.colCount - 1), "adaptive" === table.heightMode ? (distRowForCompute = table.rowCount - 1, distRow = Math.min(proxy.firstScreenRowLimit - 1, table.rowCount - 1)) : distRow = Math.min(proxy.firstScreenRowLimit - 1, table.rowCount - 1), 0 === table.internalProps._widthResizedColMap.size && computeColsWidth(table, 0, null != distColForCompute ? distColForCompute : distCol), 0 === table.internalProps._heightResizedRowMap.size && computeRowsHeight(table, 0, "auto" === table.options.canvasHeight ? table.rowCount - 1 : null != distRowForCompute ? distRowForCompute : distRow), distCol < table.colCount - table.rightFrozenColCount && computeColsWidth(table, table.colCount - table.rightFrozenColCount, table.colCount - 1), distRow < table.rowCount - table.bottomFrozenRowCount && computeRowsHeight(table, table.rowCount - table.bottomFrozenRowCount, table.rowCount - 1), table.scenegraph.colHeaderGroup.setAttribute("x", table.getFrozenColsWidth()), table.scenegraph.rowHeaderGroup.setAttribute("y", table.getFrozenRowsHeight()), table.scenegraph.bottomFrozenGroup.setAttribute("x", table.getFrozenColsWidth()), table.scenegraph.rightFrozenGroup.setAttribute("y", table.getFrozenRowsHeight()), table.scenegraph.bodyGroup.setAttributes({
|
|
38097
|
+
proxy.setParamsForRow(), proxy.setParamsForColumn(), "adaptive" === table.widthMode || table.options.autoWrapText && ("adaptive" === table.heightMode || table.isAutoRowHeight(table.columnHeaderLevelCount)) ? (distColForCompute = table.colCount - 1, distCol = Math.min(proxy.firstScreenColLimit - 1, table.colCount - 1)) : distCol = Math.min(proxy.firstScreenColLimit - 1, table.colCount - 1), "adaptive" === table.heightMode ? (distRowForCompute = table.rowCount - 1, distRow = Math.min(proxy.firstScreenRowLimit - 1, table.rowCount - 1)) : distRow = Math.min(proxy.firstScreenRowLimit - 1, table.rowCount - 1), 0 === table.internalProps._widthResizedColMap.size && computeColsWidth(table, 0, null != distColForCompute ? distColForCompute : distCol), 0 === table.internalProps._heightResizedRowMap.size && computeRowsHeight(table, 0, "auto" === table.options.canvasHeight ? table.rowCount - 1 : null != distRowForCompute ? distRowForCompute : distRow), distCol < table.colCount - table.rightFrozenColCount && computeColsWidth(table, table.colCount - table.rightFrozenColCount, table.colCount - 1), distRow < table.rowCount - table.bottomFrozenRowCount && computeRowsHeight(table, table.rowCount - table.bottomFrozenRowCount, table.rowCount - 1), table.scenegraph.colHeaderGroup.setAttribute("x", table.getFrozenColsWidth()), table.scenegraph.rowHeaderGroup.setAttribute("y", table.getFrozenRowsHeight()), table.scenegraph.bottomFrozenGroup.setAttribute("x", table.getFrozenColsWidth()), table.scenegraph.rightFrozenGroup.setAttribute("y", table.getFrozenRowsHeight()), table.scenegraph.bodyGroup.setAttributes({
|
|
38094
38098
|
x: table.getFrozenColsWidth(),
|
|
38095
38099
|
y: table.getFrozenRowsHeight()
|
|
38096
38100
|
}), createColGroup(cornerHeaderGroup, xOrigin, yOrigin, 0, table.frozenColCount - 1, 0, table.frozenRowCount - 1, table.isListTable() ? "columnHeader" : "cornerHeader", table), distCol - table.rightFrozenColCount >= table.frozenColCount && createColGroup(colHeaderGroup, xOrigin, yOrigin, table.frozenColCount, distCol - table.rightFrozenColCount, 0, table.frozenRowCount - 1, "columnHeader", table), table.frozenColCount > 0 && (table.leftRowSeriesNumberCount > 0 && createColGroup(rowHeaderGroup, xOrigin, yOrigin, 0, table.leftRowSeriesNumberCount - 1, table.frozenRowCount, distRow - table.bottomFrozenRowCount, "rowHeader", table), table.frozenColCount > table.leftRowSeriesNumberCount && createColGroup(rowHeaderGroup, xOrigin, yOrigin, table.leftRowSeriesNumberCount, Math.min(table.frozenColCount - 1, table.rowHeaderLevelCount + table.leftRowSeriesNumberCount - 1), table.frozenRowCount, distRow - table.bottomFrozenRowCount, "rowHeader", table), table.frozenColCount > table.rowHeaderLevelCount + table.leftRowSeriesNumberCount && createColGroup(rowHeaderGroup, xOrigin, yOrigin, table.rowHeaderLevelCount + table.leftRowSeriesNumberCount, table.frozenColCount - 1, table.frozenRowCount, distRow - table.bottomFrozenRowCount, "body", table)), table.bottomFrozenRowCount > 0 && (table.frozenColCount > 0 && (table.leftRowSeriesNumberCount > 0 && createColGroup(leftBottomCornerGroup, xOrigin, yOrigin, 0, table.leftRowSeriesNumberCount - 1, table.rowCount - 1 - table.bottomFrozenRowCount + 1, table.rowCount - 1, "rowHeader", table), table.rowHeaderLevelCount > 0 && createColGroup(leftBottomCornerGroup, xOrigin, yOrigin, table.leftRowSeriesNumberCount, table.leftRowSeriesNumberCount + table.rowHeaderLevelCount - 1, table.rowCount - 1 - table.bottomFrozenRowCount + 1, table.rowCount - 1, "rowHeader", table), table.frozenColCount > table.rowHeaderLevelCount + table.leftRowSeriesNumberCount && createColGroup(leftBottomCornerGroup, xOrigin, yOrigin, table.rowHeaderLevelCount + table.leftRowSeriesNumberCount, table.frozenColCount - 1, table.rowCount - 1 - table.bottomFrozenRowCount + 1, table.rowCount - 1, "body", table)), distCol - table.rightFrozenColCount >= table.frozenColCount && createColGroup(bottomFrozenGroup, xOrigin, yOrigin, table.frozenColCount, distCol - table.rightFrozenColCount, table.rowCount - 1 - table.bottomFrozenRowCount + 1, table.rowCount - 1, table.isPivotChart() ? "rowHeader" : "body", table)), table.rightFrozenColCount > 0 && (createColGroup(rightTopCornerGroup, xOrigin, yOrigin, table.colCount - 1 - table.rightFrozenColCount + 1, table.colCount - 1, 0, table.frozenRowCount - 1, "columnHeader", table), createColGroup(rightFrozenGroup, xOrigin, yOrigin, table.colCount - 1 - table.rightFrozenColCount + 1, table.colCount - 1, table.frozenRowCount, distRow - table.bottomFrozenRowCount, table.isPivotChart() ? "rowHeader" : "body", table)), table.bottomFrozenRowCount > 0 && table.rightFrozenColCount > 0 && createColGroup(rightBottomCornerGroup, xOrigin, yOrigin, table.colCount - 1 - table.rightFrozenColCount + 1, table.colCount - 1, table.rowCount - 1 - table.bottomFrozenRowCount + 1, table.rowCount - 1, "body", table), distCol - table.rightFrozenColCount >= table.frozenColCount && createColGroup(bodyGroup, xOrigin, yOrigin, table.frozenColCount, distCol - table.rightFrozenColCount, table.frozenRowCount, distRow - table.bottomFrozenRowCount, "body", table), bodyGroup.firstChild || colHeaderGroup.firstChild || cornerHeaderGroup.firstChild || rowHeaderGroup.firstChild ? (proxy.currentRow = null !== (_d = null !== (_b = null === (_a = bodyGroup.firstChild) || void 0 === _a ? void 0 : _a.rowNumber) && void 0 !== _b ? _b : null === (_c = rowHeaderGroup.firstChild) || void 0 === _c ? void 0 : _c.rowNumber) && void 0 !== _d ? _d : proxy.totalRow, proxy.rowEnd = proxy.currentRow, proxy.rowUpdatePos = proxy.rowEnd + 1, proxy.referenceRow = proxy.rowStart + Math.floor((proxy.rowEnd - proxy.rowStart) / 2), proxy.currentCol = null !== (_m = null !== (_k = null !== (_h = null !== (_f = null === (_e = bodyGroup.lastChild) || void 0 === _e ? void 0 : _e.col) && void 0 !== _f ? _f : null === (_g = colHeaderGroup.lastChild) || void 0 === _g ? void 0 : _g.col) && void 0 !== _h ? _h : null === (_j = rowHeaderGroup.lastChild) || void 0 === _j ? void 0 : _j.col) && void 0 !== _k ? _k : null === (_l = cornerHeaderGroup.lastChild) || void 0 === _l ? void 0 : _l.col) && void 0 !== _m ? _m : proxy.totalCol, proxy.colEnd = proxy.currentCol, proxy.colUpdatePos = proxy.colEnd + 1, proxy.referenceCol = proxy.colStart + Math.floor((proxy.colEnd - proxy.colStart) / 2), proxy.progress()) : (proxy.currentRow = proxy.totalRow, proxy.rowEnd = proxy.currentRow, proxy.rowUpdatePos = proxy.rowEnd + 1, proxy.referenceRow = proxy.rowStart + Math.floor((proxy.rowEnd - proxy.rowStart) / 2), proxy.currentCol = proxy.totalCol, proxy.colEnd = proxy.currentCol, proxy.colUpdatePos = proxy.colEnd + 1, proxy.referenceCol = proxy.colStart + Math.floor((proxy.colEnd - proxy.colStart) / 2));
|
|
@@ -38374,20 +38378,20 @@
|
|
|
38374
38378
|
distStartRow = "up" === direction ? proxy.rowEnd + 1 : proxy.rowStart - count,
|
|
38375
38379
|
distEndRow = "up" === direction ? proxy.rowEnd + count : proxy.rowStart - 1;
|
|
38376
38380
|
let syncTopRow, syncBottomRow;
|
|
38377
|
-
if (proxy.table.isAutoRowHeight()) syncTopRow = distStartRow, syncBottomRow = distEndRow;else {
|
|
38381
|
+
if (proxy.table.isAutoRowHeight(startRow)) syncTopRow = distStartRow, syncBottomRow = distEndRow;else {
|
|
38378
38382
|
syncTopRow = Math.max(proxy.bodyTopRow, screenTopRow - 1 * proxy.screenRowCount), syncBottomRow = Math.min(proxy.bodyBottomRow, screenTopRow + 2 * proxy.screenRowCount, proxy.table.rowCount - 1);
|
|
38379
38383
|
}
|
|
38380
38384
|
computeRowsHeight(proxy.table, syncTopRow, syncBottomRow, !1), updatePartRowPosition(startRow, endRow, direction, proxy), proxy.rowStart = "up" === direction ? proxy.rowStart + count : proxy.rowStart - count, proxy.rowEnd = "up" === direction ? proxy.rowEnd + count : proxy.rowEnd - count;
|
|
38381
38385
|
const sync = updateRowContent(syncTopRow, syncBottomRow, proxy, !0);
|
|
38382
|
-
proxy.table.isAutoRowHeight() && (updateAutoRow(proxy.bodyLeftCol, proxy.bodyRightCol, syncTopRow, syncBottomRow, proxy.table, distEndRow > proxy.bodyBottomRow - (proxy.rowEnd - proxy.rowStart + 1) ? "down" : "up", !0), updateAutoRow(0, proxy.table.frozenColCount - 1, syncTopRow, syncBottomRow, proxy.table, distEndRow > proxy.bodyBottomRow - (proxy.rowEnd - proxy.rowStart + 1) ? "down" : "up", !0), updateAutoRow(proxy.table.colCount - proxy.table.rightFrozenColCount, proxy.table.colCount - 1, syncTopRow, syncBottomRow, proxy.table, distEndRow > proxy.bodyBottomRow - (proxy.rowEnd - proxy.rowStart + 1) ? "down" : "up", !0)), proxy.currentRow = "up" === direction ? proxy.currentRow + count : proxy.currentRow - count, proxy.totalRow = Math.max(0, Math.min(proxy.bodyBottomRow, "up" === direction ? proxy.totalRow + count : proxy.totalRow - count, proxy.table.rowCount - 1)), proxy.referenceRow = proxy.rowStart + Math.floor((proxy.rowEnd - proxy.rowStart) / 2), proxy.table.isAutoRowHeight() && sync ? proxy.rowUpdatePos = Math.min(proxy.rowUpdatePos, proxy.rowEnd + 1) : proxy.rowUpdatePos = Math.min(proxy.rowUpdatePos, distStartRow), proxy.rowUpdateDirection = direction, proxy.table.scenegraph.updateNextFrame(), yield proxy.progress();
|
|
38386
|
+
proxy.table.isAutoRowHeight(startRow) && (updateAutoRow(proxy.bodyLeftCol, proxy.bodyRightCol, syncTopRow, syncBottomRow, proxy.table, distEndRow > proxy.bodyBottomRow - (proxy.rowEnd - proxy.rowStart + 1) ? "down" : "up", !0), updateAutoRow(0, proxy.table.frozenColCount - 1, syncTopRow, syncBottomRow, proxy.table, distEndRow > proxy.bodyBottomRow - (proxy.rowEnd - proxy.rowStart + 1) ? "down" : "up", !0), updateAutoRow(proxy.table.colCount - proxy.table.rightFrozenColCount, proxy.table.colCount - 1, syncTopRow, syncBottomRow, proxy.table, distEndRow > proxy.bodyBottomRow - (proxy.rowEnd - proxy.rowStart + 1) ? "down" : "up", !0)), proxy.currentRow = "up" === direction ? proxy.currentRow + count : proxy.currentRow - count, proxy.totalRow = Math.max(0, Math.min(proxy.bodyBottomRow, "up" === direction ? proxy.totalRow + count : proxy.totalRow - count, proxy.table.rowCount - 1)), proxy.referenceRow = proxy.rowStart + Math.floor((proxy.rowEnd - proxy.rowStart) / 2), proxy.table.isAutoRowHeight(startRow) && sync ? proxy.rowUpdatePos = Math.min(proxy.rowUpdatePos, proxy.rowEnd + 1) : proxy.rowUpdatePos = Math.min(proxy.rowUpdatePos, distStartRow), proxy.rowUpdateDirection = direction, proxy.table.scenegraph.updateNextFrame(), yield proxy.progress();
|
|
38383
38387
|
} else {
|
|
38384
38388
|
const distStartRow = "up" === direction ? proxy.rowStart + count : proxy.rowStart - count,
|
|
38385
38389
|
distEndRow = Math.min(proxy.table.rowCount - 1, "up" === direction ? proxy.rowEnd + count : proxy.rowEnd - count),
|
|
38386
38390
|
distStartRowY = proxy.table.getRowsHeight(proxy.bodyTopRow, distStartRow - 1);
|
|
38387
38391
|
let syncTopRow, syncBottomRow;
|
|
38388
|
-
proxy.table.isAutoRowHeight() ? (syncTopRow = distStartRow, syncBottomRow = distEndRow) : (syncTopRow = Math.max(proxy.bodyTopRow, screenTopRow - 1 * proxy.screenRowCount), syncBottomRow = Math.min(proxy.bodyBottomRow, screenTopRow + 2 * proxy.screenRowCount, proxy.table.rowCount - 1)), computeRowsHeight(proxy.table, syncTopRow, syncBottomRow, !1), updateAllRowPosition(distStartRowY, count, direction, proxy), proxy.rowStart = distStartRow, proxy.rowEnd = distEndRow;
|
|
38392
|
+
proxy.table.isAutoRowHeight(distStartRow) ? (syncTopRow = distStartRow, syncBottomRow = distEndRow) : (syncTopRow = Math.max(proxy.bodyTopRow, screenTopRow - 1 * proxy.screenRowCount), syncBottomRow = Math.min(proxy.bodyBottomRow, screenTopRow + 2 * proxy.screenRowCount, proxy.table.rowCount - 1)), computeRowsHeight(proxy.table, syncTopRow, syncBottomRow, !1), updateAllRowPosition(distStartRowY, count, direction, proxy), proxy.rowStart = distStartRow, proxy.rowEnd = distEndRow;
|
|
38389
38393
|
const sync = updateRowContent(syncTopRow, syncBottomRow, proxy, !0);
|
|
38390
|
-
proxy.table.isAutoRowHeight() && (updateAutoRow(proxy.bodyLeftCol, proxy.bodyRightCol, syncTopRow, syncBottomRow, proxy.table, distEndRow > proxy.bodyBottomRow - (proxy.rowEnd - proxy.rowStart + 1) ? "down" : "up"), updateAutoRow(0, proxy.table.frozenColCount - 1, syncTopRow, syncBottomRow, proxy.table, distEndRow > proxy.bodyBottomRow - (proxy.rowEnd - proxy.rowStart + 1) ? "down" : "up"), updateAutoRow(proxy.table.colCount - proxy.table.rightFrozenColCount, proxy.table.colCount - 1, syncTopRow, syncBottomRow, proxy.table, distEndRow > proxy.bodyBottomRow - (proxy.rowEnd - proxy.rowStart + 1) ? "down" : "up")), proxy.currentRow = "up" === direction ? proxy.currentRow + count : proxy.currentRow - count, proxy.totalRow = Math.max(0, Math.min(proxy.bodyBottomRow, "up" === direction ? proxy.totalRow + count : proxy.totalRow - count, proxy.table.rowCount - 1)), proxy.referenceRow = proxy.rowStart + Math.floor((proxy.rowEnd - proxy.rowStart) / 2), proxy.table.isAutoRowHeight() && sync ? proxy.rowUpdatePos = proxy.rowEnd + 1 : proxy.rowUpdatePos = proxy.rowStart, proxy.rowUpdateDirection = distEndRow > proxy.bodyBottomRow - (proxy.rowEnd - proxy.rowStart + 1) ? "down" : "up", proxy.table.scenegraph.updateNextFrame(), yield proxy.progress();
|
|
38394
|
+
proxy.table.isAutoRowHeight(distStartRow) && (updateAutoRow(proxy.bodyLeftCol, proxy.bodyRightCol, syncTopRow, syncBottomRow, proxy.table, distEndRow > proxy.bodyBottomRow - (proxy.rowEnd - proxy.rowStart + 1) ? "down" : "up"), updateAutoRow(0, proxy.table.frozenColCount - 1, syncTopRow, syncBottomRow, proxy.table, distEndRow > proxy.bodyBottomRow - (proxy.rowEnd - proxy.rowStart + 1) ? "down" : "up"), updateAutoRow(proxy.table.colCount - proxy.table.rightFrozenColCount, proxy.table.colCount - 1, syncTopRow, syncBottomRow, proxy.table, distEndRow > proxy.bodyBottomRow - (proxy.rowEnd - proxy.rowStart + 1) ? "down" : "up")), proxy.currentRow = "up" === direction ? proxy.currentRow + count : proxy.currentRow - count, proxy.totalRow = Math.max(0, Math.min(proxy.bodyBottomRow, "up" === direction ? proxy.totalRow + count : proxy.totalRow - count, proxy.table.rowCount - 1)), proxy.referenceRow = proxy.rowStart + Math.floor((proxy.rowEnd - proxy.rowStart) / 2), proxy.table.isAutoRowHeight(distStartRow) && sync ? proxy.rowUpdatePos = proxy.rowEnd + 1 : proxy.rowUpdatePos = proxy.rowStart, proxy.rowUpdateDirection = distEndRow > proxy.bodyBottomRow - (proxy.rowEnd - proxy.rowStart + 1) ? "down" : "up", proxy.table.scenegraph.updateNextFrame(), yield proxy.progress();
|
|
38391
38395
|
}
|
|
38392
38396
|
});
|
|
38393
38397
|
}
|
|
@@ -38501,12 +38505,12 @@
|
|
|
38501
38505
|
"group" === colGroup.type && (colGroup.needUpdate = !0, null == colGroup || colGroup.forEachChildren(cellGroup => {
|
|
38502
38506
|
cellGroup.needUpdate = !0;
|
|
38503
38507
|
}));
|
|
38504
|
-
}), proxy.table.isAutoRowHeight() ? (syncTopRow = proxy.rowStart, syncBottomRow = proxy.rowEnd) : (syncTopRow = Math.max(proxy.bodyTopRow, proxy.screenTopRow - 1 * proxy.screenRowCount), syncBottomRow = Math.min(proxy.bodyBottomRow, proxy.screenTopRow + 2 * proxy.screenRowCount, proxy.table.rowCount - 1));
|
|
38508
|
+
}), proxy.table.isAutoRowHeight(proxy.rowStart) ? (syncTopRow = proxy.rowStart, syncBottomRow = proxy.rowEnd) : (syncTopRow = Math.max(proxy.bodyTopRow, proxy.screenTopRow - 1 * proxy.screenRowCount), syncBottomRow = Math.min(proxy.bodyBottomRow, proxy.screenTopRow + 2 * proxy.screenRowCount, proxy.table.rowCount - 1));
|
|
38505
38509
|
const oldBodyHeight = proxy.table.getAllRowsHeight();
|
|
38506
38510
|
computeRowsHeight(proxy.table, syncTopRow, syncBottomRow);
|
|
38507
38511
|
const newBodyHeight = proxy.table.getAllRowsHeight();
|
|
38508
38512
|
oldBodyHeight !== newBodyHeight && proxy.table.scenegraph.updateContainerHeight(proxy.table.frozenRowCount, newBodyHeight - oldBodyHeight);
|
|
38509
|
-
for (let col = 0; null !== (_a =
|
|
38513
|
+
for (let col = 0; col < (null !== (_a = proxy.table.frozenColCount) && void 0 !== _a ? _a : 0); col++) {
|
|
38510
38514
|
const columnGroup = proxy.table.scenegraph.getColGroup(col);
|
|
38511
38515
|
null == columnGroup || columnGroup.setAttribute("chartInstance", void 0);
|
|
38512
38516
|
for (let row = proxy.rowStart; row <= proxy.rowEnd; row++) proxy.table.scenegraph.updateCellContent(col, row);
|
|
@@ -38523,7 +38527,7 @@
|
|
|
38523
38527
|
for (let row = proxy.rowStart; row <= proxy.rowEnd; row++) proxy.table.scenegraph.updateCellContent(col, row);
|
|
38524
38528
|
for (let row = proxy.table.rowCount - proxy.table.bottomFrozenRowCount; row < proxy.table.rowCount; row++) proxy.table.scenegraph.updateCellContent(col, row);
|
|
38525
38529
|
}
|
|
38526
|
-
updateRowContent(syncTopRow, syncBottomRow, proxy), proxy.table.isAutoRowHeight() && updateAutoRow(proxy.bodyLeftCol, proxy.bodyRightCol, syncTopRow, syncBottomRow, proxy.table, proxy.rowEnd > proxy.bodyBottomRow - (proxy.rowEnd - proxy.rowStart + 1) ? "down" : "up"), proxy.rowUpdatePos = proxy.rowStart, proxy.rowUpdateDirection = proxy.rowEnd > proxy.bodyBottomRow - (proxy.rowEnd - proxy.rowStart + 1) ? "down" : "up", proxy.table.scenegraph.updateNextFrame(), proxy.table.isAutoRowHeight() || (yield proxy.progress());
|
|
38530
|
+
updateRowContent(syncTopRow, syncBottomRow, proxy), proxy.table.isAutoRowHeight(syncTopRow) && updateAutoRow(proxy.bodyLeftCol, proxy.bodyRightCol, syncTopRow, syncBottomRow, proxy.table, proxy.rowEnd > proxy.bodyBottomRow - (proxy.rowEnd - proxy.rowStart + 1) ? "down" : "up"), proxy.rowUpdatePos = proxy.rowStart, proxy.rowUpdateDirection = proxy.rowEnd > proxy.bodyBottomRow - (proxy.rowEnd - proxy.rowStart + 1) ? "down" : "up", proxy.table.scenegraph.updateNextFrame(), proxy.table.isAutoRowHeight(proxy.rowStart) || (yield proxy.progress());
|
|
38527
38531
|
});
|
|
38528
38532
|
}
|
|
38529
38533
|
|
|
@@ -38816,7 +38820,7 @@
|
|
|
38816
38820
|
};
|
|
38817
38821
|
class SceneProxy {
|
|
38818
38822
|
constructor(table) {
|
|
38819
|
-
this.isRelease = !1, this.mode = "column", this.rowLimit = 200, this.currentRow = 0, this.rowStart = 0, this.rowEnd = 0, this.referenceRow = 0, this.screenTopRow = 0, this.deltaY = 0, this.deltaHeight = 0, this.colLimit = 100, this.screenLeftCol = 0, this.deltaX = 0, this.deltaWidth = 0, this.cellCache = new Map(), this.table = table, this.table.isPivotChart() ? (this.rowLimit = Math.max(100, Math.ceil(2 * table.tableNoFrameHeight / table.defaultRowHeight)), this.colLimit = Math.max(100, Math.ceil(2 * table.tableNoFrameWidth / table.defaultColWidth))) : this.table.isAutoRowHeight() ? this.rowLimit = Math.max(100, Math.ceil(2 * table.tableNoFrameHeight / table.defaultRowHeight)) : ("autoWidth" === this.table.widthMode || (this.rowLimit = Math.max(200, Math.ceil(2 * table.tableNoFrameHeight / table.defaultRowHeight))), this.colLimit = Math.max(100, Math.ceil(2 * table.tableNoFrameWidth / table.defaultColWidth))), this.table.internalProps.transpose ? this.mode = "row" : this.table.isPivotTable() && (this.mode = "pivot"), this.table.options.maintainedDataCount && (this.rowLimit = this.table.options.maintainedDataCount);
|
|
38823
|
+
this.isRelease = !1, this.mode = "column", this.rowLimit = 200, this.currentRow = 0, this.rowStart = 0, this.rowEnd = 0, this.referenceRow = 0, this.screenTopRow = 0, this.deltaY = 0, this.deltaHeight = 0, this.colLimit = 100, this.screenLeftCol = 0, this.deltaX = 0, this.deltaWidth = 0, this.cellCache = new Map(), this.table = table, this.table.isPivotChart() ? (this.rowLimit = Math.max(100, Math.ceil(2 * table.tableNoFrameHeight / table.defaultRowHeight)), this.colLimit = Math.max(100, Math.ceil(2 * table.tableNoFrameWidth / table.defaultColWidth))) : this.table.isAutoRowHeight(table.columnHeaderLevelCount) ? this.rowLimit = Math.max(100, Math.ceil(2 * table.tableNoFrameHeight / table.defaultRowHeight)) : ("autoWidth" === this.table.widthMode || (this.rowLimit = Math.max(200, Math.ceil(2 * table.tableNoFrameHeight / table.defaultRowHeight))), this.colLimit = Math.max(100, Math.ceil(2 * table.tableNoFrameWidth / table.defaultColWidth))), this.table.internalProps.transpose ? this.mode = "row" : this.table.isPivotTable() && (this.mode = "pivot"), this.table.options.maintainedDataCount && (this.rowLimit = this.table.options.maintainedDataCount), this.table.options.maintainedColumnCount && (this.colLimit = this.table.options.maintainedColumnCount);
|
|
38820
38824
|
}
|
|
38821
38825
|
get bodyLeftCol() {
|
|
38822
38826
|
return this.table.frozenColCount;
|
|
@@ -38989,17 +38993,17 @@
|
|
|
38989
38993
|
}
|
|
38990
38994
|
updateCellGroups(count) {
|
|
38991
38995
|
const distRow = Math.min(this.bodyBottomRow, this.rowUpdatePos + count);
|
|
38992
|
-
this.table.isAutoRowHeight() && computeRowsHeight(this.table, this.rowUpdatePos, distRow, !1), updateRowContent(this.rowUpdatePos, distRow, this), this.table.isAutoRowHeight() && (updateAutoRow(this.bodyLeftCol, this.bodyRightCol, this.rowUpdatePos, distRow, this.table, this.rowUpdateDirection, !0), updateAutoRow(0, this.table.frozenColCount - 1, this.rowUpdatePos, distRow, this.table, this.rowUpdateDirection, !0), updateAutoRow(this.table.colCount - this.table.rightFrozenColCount, this.table.colCount - 1, this.rowUpdatePos, distRow, this.table, this.rowUpdateDirection, !0)), this.rowUpdatePos = distRow + 1;
|
|
38996
|
+
this.table.isAutoRowHeight(this.rowUpdatePos) && computeRowsHeight(this.table, this.rowUpdatePos, distRow, !1), updateRowContent(this.rowUpdatePos, distRow, this), this.table.isAutoRowHeight(this.rowUpdatePos) && (updateAutoRow(this.bodyLeftCol, this.bodyRightCol, this.rowUpdatePos, distRow, this.table, this.rowUpdateDirection, !0), updateAutoRow(0, this.table.frozenColCount - 1, this.rowUpdatePos, distRow, this.table, this.rowUpdateDirection, !0), updateAutoRow(this.table.colCount - this.table.rightFrozenColCount, this.table.colCount - 1, this.rowUpdatePos, distRow, this.table, this.rowUpdateDirection, !0)), this.rowUpdatePos = distRow + 1;
|
|
38993
38997
|
}
|
|
38994
38998
|
updateBottomFrozenCellGroups() {
|
|
38995
38999
|
const startRow = this.table.rowCount - this.table.bottomFrozenRowCount,
|
|
38996
39000
|
endRow = this.table.rowCount - 1;
|
|
38997
|
-
this.table.isAutoRowHeight() && computeRowsHeight(this.table, startRow, endRow, !1), updateRowContent(startRow, endRow, this), this.table.isAutoRowHeight() && (updateAutoRow(this.bodyLeftCol, this.bodyRightCol, startRow, endRow, this.table, this.rowUpdateDirection), updateAutoRow(0, this.table.frozenColCount - 1, startRow, endRow, this.table, this.rowUpdateDirection), updateAutoRow(this.table.colCount - this.table.rightFrozenColCount, this.table.colCount - 1, startRow, endRow, this.table, this.rowUpdateDirection));
|
|
39001
|
+
this.table.isAutoRowHeight(startRow) && computeRowsHeight(this.table, startRow, endRow, !1), updateRowContent(startRow, endRow, this), this.table.isAutoRowHeight(startRow) && (updateAutoRow(this.bodyLeftCol, this.bodyRightCol, startRow, endRow, this.table, this.rowUpdateDirection), updateAutoRow(0, this.table.frozenColCount - 1, startRow, endRow, this.table, this.rowUpdateDirection), updateAutoRow(this.table.colCount - this.table.rightFrozenColCount, this.table.colCount - 1, startRow, endRow, this.table, this.rowUpdateDirection));
|
|
38998
39002
|
}
|
|
38999
39003
|
updateRightFrozenCellGroups() {
|
|
39000
39004
|
const startCol = this.table.colCount - this.table.rightFrozenColCount,
|
|
39001
39005
|
endCol = this.table.colCount - 1;
|
|
39002
|
-
"autoWidth" === this.table.widthMode && computeColsWidth(this.table, startCol, endCol, !1), updateColContent(startCol, endCol, this), this.table.isAutoRowHeight() && updateAutoColumn(startCol, endCol, this.table, this.colUpdateDirection);
|
|
39006
|
+
"autoWidth" === this.table.widthMode && computeColsWidth(this.table, startCol, endCol, !1), updateColContent(startCol, endCol, this), this.table.isAutoRowHeight(this.rowStart) && updateAutoColumn(startCol, endCol, this.table, this.colUpdateDirection);
|
|
39003
39007
|
}
|
|
39004
39008
|
updateColCellGroupsAsync() {
|
|
39005
39009
|
return __awaiter$1(this, void 0, void 0, function* () {
|
|
@@ -39323,7 +39327,7 @@
|
|
|
39323
39327
|
}
|
|
39324
39328
|
isExtend && extendSelectRange();
|
|
39325
39329
|
};
|
|
39326
|
-
ifExtendSelectRange && extendSelectRange(), scene.selectingRangeComponents.forEach((selectComp, key) => {
|
|
39330
|
+
ifExtendSelectRange && (extendSelectRange(), selectRange.start.col > selectRange.end.col ? (selectRange.start.col = Math.max(startCol, endCol), selectRange.end.col = Math.min(startCol, endCol)) : (selectRange.start.col = Math.min(startCol, endCol), selectRange.end.col = Math.max(startCol, endCol)), selectRange.start.row > selectRange.end.row ? (selectRange.start.row = Math.max(startRow, endRow), selectRange.end.row = Math.min(startRow, endRow)) : (selectRange.start.row = Math.min(startRow, endRow), selectRange.end.row = Math.max(startRow, endRow))), scene.selectingRangeComponents.forEach((selectComp, key) => {
|
|
39327
39331
|
var _a;
|
|
39328
39332
|
selectComp.rect.delete(), null === (_a = selectComp.fillhandle) || void 0 === _a || _a.delete();
|
|
39329
39333
|
}), scene.selectingRangeComponents = new Map();
|
|
@@ -39562,7 +39566,7 @@
|
|
|
39562
39566
|
const minRow = Math.min(...addRows);
|
|
39563
39567
|
scene.proxy.rowUpdatePos = Math.min(minRow, scene.proxy.rowUpdatePos);
|
|
39564
39568
|
}
|
|
39565
|
-
scene.proxy.rowUpdateDirection = "
|
|
39569
|
+
scene.proxy.rowUpdateDirection = "up", scene.proxy.updateCellGroups(2 * scene.proxy.screenRowCount), updateBottomFrozeCellGroups();
|
|
39566
39570
|
} else removeRows.length && (setRowSeriesNumberCellNeedUpdate(removeRows[removeRows.length - 1], scene), scene.proxy.updateCellGroups(2 * scene.proxy.screenRowCount), updateBottomFrozeCellGroups());
|
|
39567
39571
|
scene.proxy.progress();
|
|
39568
39572
|
const newTotalHeight = table.getRowsHeight(table.frozenRowCount, table.rowCount - 1 - table.bottomFrozenRowCount);
|
|
@@ -39719,22 +39723,22 @@
|
|
|
39719
39723
|
beforeCell.mergeStartRow && beforeCell.mergeEndRow && beforeCell.mergeEndRow > beforeRow && (addNeedUpdateTag({
|
|
39720
39724
|
start: {
|
|
39721
39725
|
row: beforeCell.mergeStartRow,
|
|
39722
|
-
col: scene.table.isAutoRowHeight() ? 0 : beforeCell.mergeStartCol
|
|
39726
|
+
col: scene.table.isAutoRowHeight(afterRow) ? 0 : beforeCell.mergeStartCol
|
|
39723
39727
|
},
|
|
39724
39728
|
end: {
|
|
39725
39729
|
row: beforeCell.mergeEndRow,
|
|
39726
|
-
col: scene.table.isAutoRowHeight() ? scene.table.colCount - 1 : beforeCell.mergeEndCol
|
|
39730
|
+
col: scene.table.isAutoRowHeight(afterRow) ? scene.table.colCount - 1 : beforeCell.mergeEndCol
|
|
39727
39731
|
}
|
|
39728
39732
|
}, scene), row = beforeCell.mergeStartRow);
|
|
39729
39733
|
const afterCell = scene.highPerformanceGetCell(col, afterRow);
|
|
39730
39734
|
afterCell.mergeStartRow && afterCell.mergeEndRow && afterCell.mergeStartRow < afterRow && (addNeedUpdateTag({
|
|
39731
39735
|
start: {
|
|
39732
39736
|
row: afterCell.mergeStartRow,
|
|
39733
|
-
col: scene.table.isAutoRowHeight() ? 0 : afterCell.mergeStartCol
|
|
39737
|
+
col: scene.table.isAutoRowHeight(afterRow) ? 0 : afterCell.mergeStartCol
|
|
39734
39738
|
},
|
|
39735
39739
|
end: {
|
|
39736
39740
|
row: afterCell.mergeEndRow,
|
|
39737
|
-
col: scene.table.isAutoRowHeight() ? scene.table.colCount - 1 : afterCell.mergeEndCol
|
|
39741
|
+
col: scene.table.isAutoRowHeight(afterRow) ? scene.table.colCount - 1 : afterCell.mergeEndCol
|
|
39738
39742
|
}
|
|
39739
39743
|
}, scene), row = afterCell.mergeStartRow), isValid$3(row) && (updateRow = isValid$3(updateRow) ? Math.min(updateRow, row) : row);
|
|
39740
39744
|
}
|
|
@@ -41406,7 +41410,7 @@
|
|
|
41406
41410
|
const addRows = deduplication$1(addCells.map(cell => cell.row)).sort((a, b) => a - b),
|
|
41407
41411
|
updateRows = deduplication$1(updateCells.map(cell => cell.row)).sort((a, b) => a - b),
|
|
41408
41412
|
isNotFillHeight = this.table.getAllRowsHeight() - [...addRows, ...updateRows].reduce((tolHeight, rowNumber) => tolHeight + this.table.getRowHeight(rowNumber), 0) <= this.table.tableNoFrameHeight;
|
|
41409
|
-
if (updateRow(removeCells, addCells, updateCells, this.table, skipUpdateProxy), recalculateColWidths && this.recalculateColWidths(), "adaptive" === this.table.heightMode || this.table.autoFillHeight && (this.table.getAllRowsHeight() <= this.table.tableNoFrameHeight || isNotFillHeight)) this.table.scenegraph.recalculateRowHeights();else if (this.table.isAutoRowHeight()) for (let i = 0; i < updateRows.length; i++) {
|
|
41413
|
+
if (updateRow(removeCells, addCells, updateCells, this.table, skipUpdateProxy), recalculateColWidths && this.recalculateColWidths(), "adaptive" === this.table.heightMode || this.table.autoFillHeight && (this.table.getAllRowsHeight() <= this.table.tableNoFrameHeight || isNotFillHeight)) this.table.scenegraph.recalculateRowHeights();else if (this.table.isAutoRowHeight(this.table.columnHeaderLevelCount)) for (let i = 0; i < updateRows.length; i++) {
|
|
41410
41414
|
const row = updateRows[i],
|
|
41411
41415
|
oldHeight = this.table.getRowHeight(row),
|
|
41412
41416
|
newHeight = computeRowHeight(row, 0, this.table.colCount - 1, this.table);
|
|
@@ -41700,7 +41704,7 @@
|
|
|
41700
41704
|
} : table.getCellRange(col, row);
|
|
41701
41705
|
currentRange.start.col < cellRange.end.col ? currentRange.end.col = cellRange.end.col : currentRange.start.col > cellRange.start.col && (currentRange.end.col = cellRange.start.col), currentRange.start.row < cellRange.end.row ? currentRange.end.row = cellRange.end.row : currentRange.start.row > cellRange.start.row && (currentRange.end.row = cellRange.start.row), "body" === state.select.headerSelectMode && (table.isRowHeader(col, row) ? (currentRange.start.col = table.rowHeaderLevelCount + table.leftRowSeriesNumberCount, currentRange.end.col = table.colCount - 1) : table.isColumnHeader(col, row) ? (currentRange.start.row = table.columnHeaderLevelCount, currentRange.end.row = table.rowCount - 1) : table.internalProps.layoutMap.isSeriesNumberInBody(col, row) ? (currentRange.start.col = table.leftRowSeriesNumberCount, currentRange.end.col = table.colCount - 1) : table.isCornerHeader(col, row) ? (currentRange.start.col = table.rowHeaderLevelCount + table.leftRowSeriesNumberCount, currentRange.start.row = table.columnHeaderLevelCount, currentRange.end.col = table.colCount - 1, currentRange.end.row = table.rowCount - 1) : table.isSeriesNumber(col, row) && (currentRange.start.col = table.leftRowSeriesNumberCount, currentRange.start.row = table.columnHeaderLevelCount, currentRange.end.col = table.colCount - 1, currentRange.end.row = table.rowCount - 1)), skipBodyMerge && (currentRange.skipBodyMerge = !0);
|
|
41702
41706
|
}
|
|
41703
|
-
scenegraph.updateCellSelectBorder(currentRange, extendSelectRange);
|
|
41707
|
+
currentRange && currentRange.start.row <= table.rowCount - 1 && currentRange.end.row <= table.rowCount - 1 && currentRange.start.col <= table.colCount - 1 && currentRange.end.col <= table.colCount - 1 && scenegraph.updateCellSelectBorder(currentRange, extendSelectRange);
|
|
41704
41708
|
}
|
|
41705
41709
|
}
|
|
41706
41710
|
} else {
|
|
@@ -41898,7 +41902,7 @@
|
|
|
41898
41902
|
}
|
|
41899
41903
|
cellPos.col = col, cellPos.row = row;
|
|
41900
41904
|
const currentRange = null === (_b = state.select.ranges) || void 0 === _b ? void 0 : _b[state.select.ranges.length - 1];
|
|
41901
|
-
currentRange && scenegraph.updateCellSelectBorder(currentRange, extendSelectRange);
|
|
41905
|
+
currentRange && currentRange.start.row <= table.rowCount - 1 && currentRange.end.row <= table.rowCount - 1 && currentRange.start.col <= table.colCount - 1 && currentRange.end.col <= table.colCount - 1 && scenegraph.updateCellSelectBorder(currentRange, extendSelectRange);
|
|
41902
41906
|
}
|
|
41903
41907
|
}
|
|
41904
41908
|
} else cellPos.col = -1, cellPos.row = -1, state.select.ranges = [], scenegraph.deleteAllSelectBorder();
|
|
@@ -42793,7 +42797,7 @@
|
|
|
42793
42797
|
let isSelectAll = arguments.length > 4 && arguments[4] !== undefined ? arguments[4] : !1;
|
|
42794
42798
|
let makeSelectCellVisible = arguments.length > 5 && arguments[5] !== undefined ? arguments[5] : !0;
|
|
42795
42799
|
let skipBodyMerge = arguments.length > 6 && arguments[6] !== undefined ? arguments[6] : !1;
|
|
42796
|
-
-1 !== row && -1 !== row && (this.select.selecting = !0), updateSelectPosition(this, col, row, isShift, isCtrl, isSelectAll, makeSelectCellVisible, skipBodyMerge);
|
|
42800
|
+
-1 !== row && -1 !== row && (this.select.selecting = !0), col < 0 && (col = -1), row < 0 && (row = -1), col > this.table.colCount - 1 && (col = this.table.colCount - 1), row > this.table.rowCount - 1 && (row = this.table.rowCount - 1), updateSelectPosition(this, col, row, isShift, isCtrl, isSelectAll, makeSelectCellVisible, skipBodyMerge);
|
|
42797
42801
|
}
|
|
42798
42802
|
checkCellRangeInSelect(cellPosStart, cellPosEnd) {
|
|
42799
42803
|
return checkMultiCellInSelect(cellPosStart, cellPosEnd, this.select.ranges, this.select.highlightScope);
|
|
@@ -42958,13 +42962,13 @@
|
|
|
42958
42962
|
});
|
|
42959
42963
|
}
|
|
42960
42964
|
updateVerticalScrollBar(yRatio) {
|
|
42961
|
-
var _a, _b;
|
|
42965
|
+
var _a, _b, _c, _d;
|
|
42962
42966
|
const totalHeight = this.table.getAllRowsHeight(),
|
|
42963
42967
|
oldVerticalBarPos = this.scroll.verticalBarPos;
|
|
42964
42968
|
let verticalBarPos = Math.ceil(yRatio * (totalHeight - this.table.scenegraph.height));
|
|
42965
42969
|
isValid$3(verticalBarPos) && !isNaN(verticalBarPos) || (verticalBarPos = 0);
|
|
42966
42970
|
const dy = verticalBarPos - this.table.scenegraph.proxy.deltaY - oldVerticalBarPos;
|
|
42967
|
-
if (this.table.fireListeners(TABLE_EVENT_TYPE.
|
|
42971
|
+
if (this.table.fireListeners(TABLE_EVENT_TYPE.CAN_SCROLL, {
|
|
42968
42972
|
event: void 0,
|
|
42969
42973
|
scrollTop: verticalBarPos - this.table.scenegraph.proxy.deltaY,
|
|
42970
42974
|
scrollLeft: this.scroll.horizontalBarPos,
|
|
@@ -42978,16 +42982,27 @@
|
|
|
42978
42982
|
}).some(value => !1 === value)) {
|
|
42979
42983
|
const yRatio = this.scroll.verticalBarPos / (totalHeight - this.table.scenegraph.height);
|
|
42980
42984
|
this.table.scenegraph.component.updateVerticalScrollBarPos(yRatio);
|
|
42981
|
-
} else this.scroll.verticalBarPos = verticalBarPos, this.table.scenegraph.setY(-this.scroll.verticalBarPos, 1 === yRatio), this.scroll.verticalBarPos -= this.table.scenegraph.proxy.deltaY, this.table.scenegraph.proxy.deltaY = 0, this.updateHoverPos(-1, -1),
|
|
42985
|
+
} else this.scroll.verticalBarPos = verticalBarPos, this.table.scenegraph.setY(-this.scroll.verticalBarPos, 1 === yRatio), this.scroll.verticalBarPos -= this.table.scenegraph.proxy.deltaY, this.table.scenegraph.proxy.deltaY = 0, this.updateHoverPos(-1, -1), this.table.fireListeners(TABLE_EVENT_TYPE.SCROLL, {
|
|
42986
|
+
event: void 0,
|
|
42987
|
+
scrollTop: this.scroll.verticalBarPos,
|
|
42988
|
+
scrollLeft: this.scroll.horizontalBarPos,
|
|
42989
|
+
scrollHeight: null === (_c = this.table.theme.scrollStyle) || void 0 === _c ? void 0 : _c.width,
|
|
42990
|
+
scrollWidth: null === (_d = this.table.theme.scrollStyle) || void 0 === _d ? void 0 : _d.width,
|
|
42991
|
+
viewHeight: this.table.tableNoFrameHeight,
|
|
42992
|
+
viewWidth: this.table.tableNoFrameWidth,
|
|
42993
|
+
scrollDirection: "vertical",
|
|
42994
|
+
scrollRatioY: yRatio,
|
|
42995
|
+
dy: dy
|
|
42996
|
+
}), oldVerticalBarPos !== this.scroll.verticalBarPos && this.checkVerticalScrollBarEnd();
|
|
42982
42997
|
}
|
|
42983
42998
|
updateHorizontalScrollBar(xRatio) {
|
|
42984
|
-
var _a, _b;
|
|
42999
|
+
var _a, _b, _c, _d;
|
|
42985
43000
|
const totalWidth = this.table.getAllColsWidth(),
|
|
42986
43001
|
oldHorizontalBarPos = this.scroll.horizontalBarPos;
|
|
42987
43002
|
let horizontalBarPos = Math.ceil(xRatio * (totalWidth - this.table.scenegraph.width));
|
|
42988
43003
|
isValid$3(horizontalBarPos) && !isNaN(horizontalBarPos) || (horizontalBarPos = 0);
|
|
42989
43004
|
const dx = horizontalBarPos - this.table.scenegraph.proxy.deltaX - oldHorizontalBarPos;
|
|
42990
|
-
if (this.table.fireListeners(TABLE_EVENT_TYPE.
|
|
43005
|
+
if (this.table.fireListeners(TABLE_EVENT_TYPE.CAN_SCROLL, {
|
|
42991
43006
|
event: void 0,
|
|
42992
43007
|
scrollTop: this.scroll.verticalBarPos,
|
|
42993
43008
|
scrollLeft: horizontalBarPos - this.table.scenegraph.proxy.deltaX,
|
|
@@ -43001,11 +43016,22 @@
|
|
|
43001
43016
|
}).some(value => !1 === value)) {
|
|
43002
43017
|
const xRatio = this.scroll.horizontalBarPos / (totalWidth - this.table.scenegraph.width);
|
|
43003
43018
|
this.table.scenegraph.component.updateHorizontalScrollBarPos(xRatio);
|
|
43004
|
-
} else this.scroll.horizontalBarPos = horizontalBarPos, this.table.scenegraph.setX(-this.scroll.horizontalBarPos, 1 === xRatio), this.scroll.horizontalBarPos -= this.table.scenegraph.proxy.deltaX, this.table.scenegraph.proxy.deltaX = 0, this.updateHoverPos(-1, -1),
|
|
43019
|
+
} else this.scroll.horizontalBarPos = horizontalBarPos, this.table.scenegraph.setX(-this.scroll.horizontalBarPos, 1 === xRatio), this.scroll.horizontalBarPos -= this.table.scenegraph.proxy.deltaX, this.table.scenegraph.proxy.deltaX = 0, this.updateHoverPos(-1, -1), this.table.fireListeners(TABLE_EVENT_TYPE.SCROLL, {
|
|
43020
|
+
event: void 0,
|
|
43021
|
+
scrollTop: this.scroll.verticalBarPos,
|
|
43022
|
+
scrollLeft: this.scroll.horizontalBarPos,
|
|
43023
|
+
scrollHeight: null === (_c = this.table.theme.scrollStyle) || void 0 === _c ? void 0 : _c.width,
|
|
43024
|
+
scrollWidth: null === (_d = this.table.theme.scrollStyle) || void 0 === _d ? void 0 : _d.width,
|
|
43025
|
+
viewHeight: this.table.tableNoFrameHeight,
|
|
43026
|
+
viewWidth: this.table.tableNoFrameWidth,
|
|
43027
|
+
scrollDirection: "horizontal",
|
|
43028
|
+
scrollRatioX: xRatio,
|
|
43029
|
+
dx: dx
|
|
43030
|
+
}), oldHorizontalBarPos !== this.scroll.horizontalBarPos && this.checkHorizontalScrollBarEnd();
|
|
43005
43031
|
}
|
|
43006
43032
|
setScrollTop(top, event) {
|
|
43007
43033
|
let triggerEvent = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : !0;
|
|
43008
|
-
var _a, _b, _c, _d, _e;
|
|
43034
|
+
var _a, _b, _c, _d, _e, _f, _g;
|
|
43009
43035
|
const totalHeight = this.table.getAllRowsHeight(),
|
|
43010
43036
|
sizeTolerance = (null === (_a = this.table.options.customConfig) || void 0 === _a ? void 0 : _a._disableColumnAndRowSizeRound) ? 1 : 0;
|
|
43011
43037
|
top = Math.max(0, Math.min(top, totalHeight - this.table.scenegraph.height - sizeTolerance)), top = Math.ceil(top);
|
|
@@ -43015,7 +43041,7 @@
|
|
|
43015
43041
|
let verticalBarPos = top;
|
|
43016
43042
|
isValid$3(verticalBarPos) && !isNaN(verticalBarPos) || (verticalBarPos = 0);
|
|
43017
43043
|
const dy = verticalBarPos - oldVerticalBarPos;
|
|
43018
|
-
if (this.table.fireListeners(TABLE_EVENT_TYPE.
|
|
43044
|
+
if (this.table.fireListeners(TABLE_EVENT_TYPE.CAN_SCROLL, {
|
|
43019
43045
|
event: null == event ? void 0 : event.nativeEvent,
|
|
43020
43046
|
scrollTop: verticalBarPos,
|
|
43021
43047
|
scrollLeft: this.scroll.horizontalBarPos,
|
|
@@ -43031,11 +43057,24 @@
|
|
|
43031
43057
|
return void this.table.scenegraph.component.updateVerticalScrollBarPos(yRatio);
|
|
43032
43058
|
}
|
|
43033
43059
|
}
|
|
43034
|
-
(top !== this.scroll.verticalBarPos || this.table.isPivotChart()) && this.updateHoverPos(-1, -1), this.scroll.verticalBarPos = top, isValid$3(this.scroll.verticalBarPos) && !isNaN(this.scroll.verticalBarPos) || (this.scroll.verticalBarPos = 0), this.table.scenegraph.setY(-top), this.table.scenegraph.component.updateVerticalScrollBarPos(yRatio)
|
|
43060
|
+
(top !== this.scroll.verticalBarPos || this.table.isPivotChart()) && this.updateHoverPos(-1, -1), this.scroll.verticalBarPos = top, isValid$3(this.scroll.verticalBarPos) && !isNaN(this.scroll.verticalBarPos) || (this.scroll.verticalBarPos = 0), this.table.scenegraph.setY(-top), this.table.scenegraph.component.updateVerticalScrollBarPos(yRatio);
|
|
43061
|
+
const dy = this.scroll.verticalBarPos - oldVerticalBarPos;
|
|
43062
|
+
this.table.fireListeners(TABLE_EVENT_TYPE.SCROLL, {
|
|
43063
|
+
event: null == event ? void 0 : event.nativeEvent,
|
|
43064
|
+
scrollTop: this.scroll.verticalBarPos,
|
|
43065
|
+
scrollLeft: this.scroll.horizontalBarPos,
|
|
43066
|
+
scrollHeight: null === (_f = this.table.theme.scrollStyle) || void 0 === _f ? void 0 : _f.width,
|
|
43067
|
+
scrollWidth: null === (_g = this.table.theme.scrollStyle) || void 0 === _g ? void 0 : _g.width,
|
|
43068
|
+
viewHeight: this.table.tableNoFrameHeight,
|
|
43069
|
+
viewWidth: this.table.tableNoFrameWidth,
|
|
43070
|
+
scrollDirection: "vertical",
|
|
43071
|
+
scrollRatioY: yRatio,
|
|
43072
|
+
dy: dy
|
|
43073
|
+
}), oldVerticalBarPos !== top && triggerEvent && this.checkVerticalScrollBarEnd();
|
|
43035
43074
|
}
|
|
43036
43075
|
setScrollLeft(left, event) {
|
|
43037
43076
|
let triggerEvent = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : !0;
|
|
43038
|
-
var _a, _b, _c, _d, _e;
|
|
43077
|
+
var _a, _b, _c, _d, _e, _f, _g;
|
|
43039
43078
|
this.table.scrollLeft;
|
|
43040
43079
|
const totalWidth = this.table.getAllColsWidth(),
|
|
43041
43080
|
sizeTolerance = (this.table.getFrozenColsWidth(), (null === (_a = this.table.options.customConfig) || void 0 === _a ? void 0 : _a._disableColumnAndRowSizeRound) ? 1 : 0);
|
|
@@ -43046,7 +43085,7 @@
|
|
|
43046
43085
|
let horizontalBarPos = left;
|
|
43047
43086
|
isValid$3(horizontalBarPos) && !isNaN(horizontalBarPos) || (horizontalBarPos = 0);
|
|
43048
43087
|
const dx = horizontalBarPos - oldHorizontalBarPos;
|
|
43049
|
-
if (this.table.fireListeners(TABLE_EVENT_TYPE.
|
|
43088
|
+
if (this.table.fireListeners(TABLE_EVENT_TYPE.CAN_SCROLL, {
|
|
43050
43089
|
event: null == event ? void 0 : event.nativeEvent,
|
|
43051
43090
|
scrollTop: this.scroll.verticalBarPos,
|
|
43052
43091
|
scrollLeft: horizontalBarPos,
|
|
@@ -43062,7 +43101,20 @@
|
|
|
43062
43101
|
return void this.table.scenegraph.component.updateHorizontalScrollBarPos(xRatio);
|
|
43063
43102
|
}
|
|
43064
43103
|
}
|
|
43065
|
-
left !== this.scroll.horizontalBarPos && this.updateHoverPos(-1, -1), this.scroll.horizontalBarPos = left, isValid$3(this.scroll.horizontalBarPos) && !isNaN(this.scroll.horizontalBarPos) || (this.scroll.horizontalBarPos = 0), this.table.scenegraph.setX(-left), this.table.scenegraph.component.updateHorizontalScrollBarPos(xRatio)
|
|
43104
|
+
left !== this.scroll.horizontalBarPos && this.updateHoverPos(-1, -1), this.scroll.horizontalBarPos = left, isValid$3(this.scroll.horizontalBarPos) && !isNaN(this.scroll.horizontalBarPos) || (this.scroll.horizontalBarPos = 0), this.table.scenegraph.setX(-left), this.table.scenegraph.component.updateHorizontalScrollBarPos(xRatio);
|
|
43105
|
+
const dx = this.scroll.horizontalBarPos - oldHorizontalBarPos;
|
|
43106
|
+
this.table.fireListeners(TABLE_EVENT_TYPE.SCROLL, {
|
|
43107
|
+
event: null == event ? void 0 : event.nativeEvent,
|
|
43108
|
+
scrollTop: this.scroll.verticalBarPos,
|
|
43109
|
+
scrollLeft: this.scroll.horizontalBarPos,
|
|
43110
|
+
scrollHeight: null === (_f = this.table.theme.scrollStyle) || void 0 === _f ? void 0 : _f.width,
|
|
43111
|
+
scrollWidth: null === (_g = this.table.theme.scrollStyle) || void 0 === _g ? void 0 : _g.width,
|
|
43112
|
+
viewHeight: this.table.tableNoFrameHeight,
|
|
43113
|
+
viewWidth: this.table.tableNoFrameWidth,
|
|
43114
|
+
scrollDirection: "horizontal",
|
|
43115
|
+
scrollRatioX: xRatio,
|
|
43116
|
+
dx: dx
|
|
43117
|
+
}), oldHorizontalBarPos !== left && triggerEvent && this.checkHorizontalScrollBarEnd();
|
|
43066
43118
|
}
|
|
43067
43119
|
hideVerticalScrollBar() {
|
|
43068
43120
|
this.table.scenegraph.component.hideVerticalScrollBar();
|
|
@@ -43695,7 +43747,7 @@
|
|
|
43695
43747
|
callback: globalPointerdownCallback
|
|
43696
43748
|
}), vglobal.addEventListener("pointerup", globalPointerupCallback), vglobal.addEventListener("pointerdown", globalPointerdownCallback), table.scenegraph.tableGroup.addEventListener("pointerdown", e => {
|
|
43697
43749
|
var _a, _b, _c, _d, _e;
|
|
43698
|
-
table.hasListeners(TABLE_EVENT_TYPE.MOUSEDOWN_TABLE) && table.fireListeners(TABLE_EVENT_TYPE.MOUSEDOWN_TABLE, {
|
|
43750
|
+
if (table.hasListeners(TABLE_EVENT_TYPE.MOUSEDOWN_TABLE) && table.fireListeners(TABLE_EVENT_TYPE.MOUSEDOWN_TABLE, {
|
|
43699
43751
|
event: e.nativeEvent
|
|
43700
43752
|
}), table.eventManager.isDown = !0, table.eventManager.LastBodyPointerXY = {
|
|
43701
43753
|
x: e.x,
|
|
@@ -43703,7 +43755,7 @@
|
|
|
43703
43755
|
}, table.eventManager.LastPointerXY = {
|
|
43704
43756
|
x: e.x,
|
|
43705
43757
|
y: e.y
|
|
43706
|
-
};
|
|
43758
|
+
}, 0 !== e.button) return;
|
|
43707
43759
|
const eventArgsSet = getCellEventArgsSet(e);
|
|
43708
43760
|
if (eventManager.downIcon = void 0, stateManager.interactionState !== InteractionState.default) return;
|
|
43709
43761
|
if (table.isPivotChart() && "chart" !== (null === (_a = null == eventArgsSet ? void 0 : eventArgsSet.eventArgs) || void 0 === _a ? void 0 : _a.target.type) && table.scenegraph.updateChartState(null), (null === (_b = eventArgsSet.eventArgs) || void 0 === _b ? void 0 : _b.target) !== (null === (_c = stateManager.residentHoverIcon) || void 0 === _c ? void 0 : _c.icon) && stateManager.hideMenu(), "chart" === (null === (_d = null == eventArgsSet ? void 0 : eventArgsSet.eventArgs) || void 0 === _d ? void 0 : _d.target.type)) return;
|
|
@@ -44279,7 +44331,7 @@
|
|
|
44279
44331
|
}
|
|
44280
44332
|
}), handler.on(table.getElement(), "contextmenu", e => {
|
|
44281
44333
|
var _a;
|
|
44282
|
-
!1 !== (null === (_a = table.eventOptions) || void 0 === _a ? void 0 : _a.preventDefaultContextMenu)
|
|
44334
|
+
!1 !== (null === (_a = table.eventOptions) || void 0 === _a ? void 0 : _a.preventDefaultContextMenu) ? e.preventDefault() : globalPointerupCallback(e);
|
|
44283
44335
|
}), table.options.canvas || handler.on(table.getContainer(), "resize", e => {
|
|
44284
44336
|
var _a;
|
|
44285
44337
|
table.isReleased || 0 === e.width && 0 === e.height || ((table.autoFillWidth || table.autoFillHeight) && (null === (_a = table.editorManager) || void 0 === _a || _a.completeEdit()), isValid$3(table.options.pixelRatio) || table.setPixelRatio(getPixelRatio()), e.windowSizeNotChange || table.resize());
|
|
@@ -44710,6 +44762,75 @@
|
|
|
44710
44762
|
});
|
|
44711
44763
|
}
|
|
44712
44764
|
|
|
44765
|
+
function bindIconClickEvent(table) {
|
|
44766
|
+
table.on(TABLE_EVENT_TYPE.ICON_CLICK, iconInfo => {
|
|
44767
|
+
var _a;
|
|
44768
|
+
const {
|
|
44769
|
+
col: col,
|
|
44770
|
+
row: row,
|
|
44771
|
+
x: x,
|
|
44772
|
+
y: y,
|
|
44773
|
+
funcType: funcType,
|
|
44774
|
+
icon: icon,
|
|
44775
|
+
event: event
|
|
44776
|
+
} = iconInfo,
|
|
44777
|
+
{
|
|
44778
|
+
stateManager: stateManager
|
|
44779
|
+
} = table;
|
|
44780
|
+
if (funcType === IconFuncTypeEnum.dropDown) stateManager.triggerDropDownMenu(col, row, x, y, event);else if (funcType === IconFuncTypeEnum.sort) stateManager.triggerSort(col, row, icon, event);else if (funcType === IconFuncTypeEnum.frozen) stateManager.triggerFreeze(col, row, icon);else if (funcType === IconFuncTypeEnum.drillDown) drillClick(table);else if (funcType === IconFuncTypeEnum.collapse || funcType === IconFuncTypeEnum.expand) {
|
|
44781
|
+
const isHasSelected = !!(null === (_a = stateManager.select.ranges) || void 0 === _a ? void 0 : _a.length);
|
|
44782
|
+
stateManager.updateSelectPos(-1, -1), stateManager.endSelectCells(!0, isHasSelected), table.toggleHierarchyState(col, row);
|
|
44783
|
+
}
|
|
44784
|
+
});
|
|
44785
|
+
}
|
|
44786
|
+
|
|
44787
|
+
function bindDropdownMenuClickEvent(table) {
|
|
44788
|
+
table.on(TABLE_EVENT_TYPE.DROPDOWN_MENU_CLICK, () => {
|
|
44789
|
+
table.stateManager.hideMenu();
|
|
44790
|
+
});
|
|
44791
|
+
}
|
|
44792
|
+
|
|
44793
|
+
function bindDBClickAutoColumnWidthEvent(table) {
|
|
44794
|
+
table.on(TABLE_EVENT_TYPE.DBLCLICK_CELL, e => {
|
|
44795
|
+
var _a, _b, _c;
|
|
44796
|
+
if (e.federatedEvent) {
|
|
44797
|
+
const eventArgsSet = getCellEventArgsSet(e.federatedEvent),
|
|
44798
|
+
resizeCol = table.scenegraph.getResizeColAt(eventArgsSet.abstractPos.x, eventArgsSet.abstractPos.y, null === (_a = eventArgsSet.eventArgs) || void 0 === _a ? void 0 : _a.targetCell),
|
|
44799
|
+
disableDblclickAutoResizeColWidth = null !== (_b = table.options.disableDblclickAutoResizeColWidth) && void 0 !== _b ? _b : null === (_c = table.options.resize) || void 0 === _c ? void 0 : _c.disableDblclickAutoResizeColWidth;
|
|
44800
|
+
if (table.eventManager.checkCellFillhandle(eventArgsSet)) table.fireListeners(TABLE_EVENT_TYPE.DBLCLICK_FILL_HANDLE, {});else if (table._canResizeColumn(resizeCol.col, resizeCol.row) && resizeCol.col >= 0 && !disableDblclickAutoResizeColWidth) {
|
|
44801
|
+
table.scenegraph.updateAutoColWidth(resizeCol.col), table.internalProps._widthResizedColMap.add(resizeCol.col), table.scenegraph.updateChartSizeForResizeColWidth(resizeCol.col);
|
|
44802
|
+
const state = table.stateManager;
|
|
44803
|
+
state.columnResize.col < state.table.frozenColCount && !state.table.isPivotTable() && !state.table.transpose && state.table.scenegraph.component.setFrozenColumnShadow(state.table.frozenColCount - 1, state.columnResize.isRightFrozen);
|
|
44804
|
+
const colWidths = [];
|
|
44805
|
+
for (let col = 0; col < table.colCount; col++) colWidths.push(table.getColWidth(col));
|
|
44806
|
+
table.fireListeners(TABLE_EVENT_TYPE.RESIZE_COLUMN_END, {
|
|
44807
|
+
col: resizeCol.col,
|
|
44808
|
+
colWidths: colWidths
|
|
44809
|
+
});
|
|
44810
|
+
}
|
|
44811
|
+
}
|
|
44812
|
+
});
|
|
44813
|
+
}
|
|
44814
|
+
|
|
44815
|
+
function rightButtonClickEvent(table) {
|
|
44816
|
+
table.on(TABLE_EVENT_TYPE.CONTEXTMENU_CELL, e => {
|
|
44817
|
+
const {
|
|
44818
|
+
col: col,
|
|
44819
|
+
row: row
|
|
44820
|
+
} = e,
|
|
44821
|
+
ranges = table.getSelectedCellRanges();
|
|
44822
|
+
let cellInRange = !1;
|
|
44823
|
+
if (ranges.length > 0) for (let i = 0; i < ranges.length; i++) {
|
|
44824
|
+
const range = ranges[i];
|
|
44825
|
+
if (col >= range.start.col && col <= range.end.col && row >= range.start.row && row <= range.end.row) {
|
|
44826
|
+
cellInRange = !0;
|
|
44827
|
+
break;
|
|
44828
|
+
}
|
|
44829
|
+
}
|
|
44830
|
+
cellInRange || table.selectCell(col, row);
|
|
44831
|
+
});
|
|
44832
|
+
}
|
|
44833
|
+
|
|
44713
44834
|
class EventManager {
|
|
44714
44835
|
constructor(table) {
|
|
44715
44836
|
this.isDown = !1, this.isDraging = !1, this.globalEventListeners = [], this._enableTableScroll = !0, this.table = table, this.handleTextStickBindId = [], this.inertiaScroll = new InertiaScroll(table.stateManager), "node" === Env.mode || table.options.disableInteraction || (this.bindOuterEvent(), setTimeout(() => {
|
|
@@ -44734,44 +44855,7 @@
|
|
|
44734
44855
|
}, 0);
|
|
44735
44856
|
}
|
|
44736
44857
|
bindSelfEvent() {
|
|
44737
|
-
|
|
44738
|
-
const stateManager = this.table.stateManager;
|
|
44739
|
-
this.table.on(TABLE_EVENT_TYPE.ICON_CLICK, iconInfo => {
|
|
44740
|
-
var _a;
|
|
44741
|
-
const {
|
|
44742
|
-
col: col,
|
|
44743
|
-
row: row,
|
|
44744
|
-
x: x,
|
|
44745
|
-
y: y,
|
|
44746
|
-
funcType: funcType,
|
|
44747
|
-
icon: icon,
|
|
44748
|
-
event: event
|
|
44749
|
-
} = iconInfo;
|
|
44750
|
-
if (funcType === IconFuncTypeEnum.dropDown) stateManager.triggerDropDownMenu(col, row, x, y, event);else if (funcType === IconFuncTypeEnum.sort) stateManager.triggerSort(col, row, icon, event);else if (funcType === IconFuncTypeEnum.frozen) stateManager.triggerFreeze(col, row, icon);else if (funcType === IconFuncTypeEnum.drillDown) drillClick(this.table);else if (funcType === IconFuncTypeEnum.collapse || funcType === IconFuncTypeEnum.expand) {
|
|
44751
|
-
const isHasSelected = !!(null === (_a = stateManager.select.ranges) || void 0 === _a ? void 0 : _a.length);
|
|
44752
|
-
stateManager.updateSelectPos(-1, -1), stateManager.endSelectCells(!0, isHasSelected), this.table.toggleHierarchyState(col, row);
|
|
44753
|
-
}
|
|
44754
|
-
}), this.table.on(TABLE_EVENT_TYPE.DROPDOWN_MENU_CLICK, () => {
|
|
44755
|
-
stateManager.hideMenu();
|
|
44756
|
-
}), this.updateEventBinder(), bindMediaClick(this.table), this.table.on(TABLE_EVENT_TYPE.DBLCLICK_CELL, e => {
|
|
44757
|
-
var _a, _b, _c;
|
|
44758
|
-
if (e.federatedEvent) {
|
|
44759
|
-
const eventArgsSet = getCellEventArgsSet(e.federatedEvent),
|
|
44760
|
-
resizeCol = this.table.scenegraph.getResizeColAt(eventArgsSet.abstractPos.x, eventArgsSet.abstractPos.y, null === (_a = eventArgsSet.eventArgs) || void 0 === _a ? void 0 : _a.targetCell),
|
|
44761
|
-
disableDblclickAutoResizeColWidth = null !== (_b = this.table.options.disableDblclickAutoResizeColWidth) && void 0 !== _b ? _b : null === (_c = this.table.options.resize) || void 0 === _c ? void 0 : _c.disableDblclickAutoResizeColWidth;
|
|
44762
|
-
if (this.table.eventManager.checkCellFillhandle(eventArgsSet)) this.table.fireListeners(TABLE_EVENT_TYPE.DBLCLICK_FILL_HANDLE, {});else if (this.table._canResizeColumn(resizeCol.col, resizeCol.row) && resizeCol.col >= 0 && !disableDblclickAutoResizeColWidth) {
|
|
44763
|
-
this.table.scenegraph.updateAutoColWidth(resizeCol.col), this.table.internalProps._widthResizedColMap.add(resizeCol.col), this.table.scenegraph.updateChartSizeForResizeColWidth(resizeCol.col);
|
|
44764
|
-
const state = this.table.stateManager;
|
|
44765
|
-
state.columnResize.col < state.table.frozenColCount && !state.table.isPivotTable() && !state.table.transpose && state.table.scenegraph.component.setFrozenColumnShadow(state.table.frozenColCount - 1, state.columnResize.isRightFrozen);
|
|
44766
|
-
const colWidths = [];
|
|
44767
|
-
for (let col = 0; col < this.table.colCount; col++) colWidths.push(this.table.getColWidth(col));
|
|
44768
|
-
this.table.fireListeners(TABLE_EVENT_TYPE.RESIZE_COLUMN_END, {
|
|
44769
|
-
col: resizeCol.col,
|
|
44770
|
-
colWidths: colWidths
|
|
44771
|
-
});
|
|
44772
|
-
}
|
|
44773
|
-
}
|
|
44774
|
-
}), this.table.isPivotTable() && checkHaveDrill(this.table) && bindDrillEvent(this.table), bindSparklineHoverEvent(this.table), bindAxisClickEvent(this.table), bindAxisHoverEvent(this.table), bindGroupTitleCheckboxChange(this.table), bindButtonClickEvent(this.table);
|
|
44858
|
+
this.table.isReleased || (bindIconClickEvent(this.table), bindDropdownMenuClickEvent(this.table), this.updateEventBinder(), bindMediaClick(this.table), bindDBClickAutoColumnWidthEvent(this.table), this.table.isPivotTable() && checkHaveDrill(this.table) && bindDrillEvent(this.table), bindSparklineHoverEvent(this.table), bindAxisClickEvent(this.table), bindAxisHoverEvent(this.table), bindGroupTitleCheckboxChange(this.table), bindButtonClickEvent(this.table), rightButtonClickEvent(this.table));
|
|
44775
44859
|
}
|
|
44776
44860
|
dealTableHover(eventArgsSet) {
|
|
44777
44861
|
if (!eventArgsSet) return void this.table.stateManager.updateHoverPos(-1, -1);
|
|
@@ -47223,15 +47307,14 @@
|
|
|
47223
47307
|
} = getAxisOption(col, row, position, layout),
|
|
47224
47308
|
range = getAxisRange(layout.dataset.collectedValues, indicatorKeys, isZeroAlign, path, null != seriesIndice ? seriesIndice : index);
|
|
47225
47309
|
if (!range) return;
|
|
47226
|
-
|
|
47227
|
-
|
|
47228
|
-
|
|
47229
|
-
|
|
47230
|
-
|
|
47231
|
-
|
|
47232
|
-
|
|
47233
|
-
|
|
47234
|
-
}
|
|
47310
|
+
isPercent && (range.min = range.min < 0 ? -1 : 0, range.max = range.max > 0 ? 1 : 0), ((null == axisOption ? void 0 : axisOption.zero) || range.min === range.max) && (range.min = Math.min(range.min, 0), range.max = Math.max(range.max, 0));
|
|
47311
|
+
const getAxisDomainRangeAndLabels = Factory.getFunction("getAxisDomainRangeAndLabels"),
|
|
47312
|
+
{
|
|
47313
|
+
range: axisRange,
|
|
47314
|
+
ticks: selfTicks
|
|
47315
|
+
} = getAxisDomainRangeAndLabels(range.min, range.max, axisOption, isZeroAlign, "bottom" === position || "top" === position ? layout._table.getColWidth(col) || layout._table.tableNoFrameWidth : layout._table.getRowHeight(row) || layout._table.tableNoFrameHeight);
|
|
47316
|
+
(null == axisOption ? void 0 : axisOption.nice) && (range.min = axisRange[0], range.max = axisRange[1]);
|
|
47317
|
+
const ticks = selfTicks;
|
|
47235
47318
|
return isNumber$4(null == axisOption ? void 0 : axisOption.min) && (range.min = axisOption.min), isNumber$4(null == axisOption ? void 0 : axisOption.max) && (range.max = axisOption.max), {
|
|
47236
47319
|
index: null != seriesIndice ? seriesIndice : index,
|
|
47237
47320
|
range: range,
|
|
@@ -47523,7 +47606,7 @@
|
|
|
47523
47606
|
constructor(container) {
|
|
47524
47607
|
let options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
|
|
47525
47608
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r;
|
|
47526
|
-
if (super(), this.showFrozenIcon = !0, this.version = "1.17.3
|
|
47609
|
+
if (super(), this.showFrozenIcon = !0, this.version = "1.17.3", this.id = `VTable${Date.now()}`, this.isReleased = !1, this._chartEventMap = {}, this.throttleInvalidate = throttle2(this.render.bind(this), 200), !container && "node" !== options.mode && !options.canvas) throw new Error("vtable's container is undefined");
|
|
47527
47610
|
!1 === (null === (_a = options.customConfig) || void 0 === _a ? void 0 : _a.imageAnonymous) && (vglobal.isImageAnonymous = !1);
|
|
47528
47611
|
const {
|
|
47529
47612
|
frozenColCount = 0,
|
|
@@ -47571,7 +47654,7 @@
|
|
|
47571
47654
|
right: 0,
|
|
47572
47655
|
left: 0,
|
|
47573
47656
|
bottom: 0
|
|
47574
|
-
}, padding && ("number" == typeof padding ? (this.padding.top = padding, this.padding.left = padding, this.padding.bottom = padding, this.padding.right = padding) : (padding.top && (this.padding.top = padding.top), padding.bottom && (this.padding.bottom = padding.bottom), padding.left && (this.padding.left = padding.left), padding.right && (this.padding.right = padding.right))), isValid$3(canvasHeight)
|
|
47657
|
+
}, padding && ("number" == typeof padding ? (this.padding.top = padding, this.padding.left = padding, this.padding.bottom = padding, this.padding.right = padding) : (padding.top && (this.padding.top = padding.top), padding.bottom && (this.padding.bottom = padding.bottom), padding.left && (this.padding.left = padding.left), padding.right && (this.padding.right = padding.right))), (isValid$3(canvasHeight) || isValid$3(canvasWidth)) && (this.canvasSizeSeted = !0), this.tableNoFrameWidth = 0, this.tableNoFrameHeight = 0, this.canvasWidth = isNumber$4(canvasWidth) ? canvasWidth : void 0, this.canvasHeight = isNumber$4(canvasHeight) ? canvasHeight : void 0, this.columnWidthComputeMode = null !== (_b = options.columnWidthComputeMode) && void 0 !== _b ? _b : "normal";
|
|
47575
47658
|
const internalProps = this.internalProps = {};
|
|
47576
47659
|
void 0 !== showFrozenIcon && (this.showFrozenIcon = showFrozenIcon), "number" == typeof allowFrozenColCount && allowFrozenColCount <= 0 && (this.showFrozenIcon = !1), this.options.canvas ? ("node" !== Env.mode && (internalProps.element = this.options.canvas.parentElement, internalProps.element.style.position = "relative"), internalProps.focusControl = new FocusInput(this, internalProps.element), internalProps.canvas = this.options.canvas, internalProps.context = internalProps.canvas.getContext("2d")) : "node" !== Env.mode && (internalProps.element = createRootElement(this.padding), internalProps.focusControl = new FocusInput(this, internalProps.element), internalProps.canvas = document.createElement("canvas"), internalProps.element.appendChild(internalProps.canvas), internalProps.context = internalProps.canvas.getContext("2d"), (null === (_c = options.customConfig) || void 0 === _c ? void 0 : _c.createReactContainer) && createReactContainer(this)), internalProps.handler = new EventHandler(), isNumber$4(this.options.resizeTime) && (internalProps.handler.resizeTime = this.options.resizeTime), internalProps.pixelRatio = pixelRatio, internalProps.frozenColCount = frozenColCount, internalProps.frozenRowCount = frozenRowCount, internalProps.unfreezeAllOnExceedsMaxWidth = null == unfreezeAllOnExceedsMaxWidth || unfreezeAllOnExceedsMaxWidth, internalProps.defaultRowHeight = defaultRowHeight, internalProps.defaultHeaderRowHeight = null != defaultHeaderRowHeight ? defaultHeaderRowHeight : defaultRowHeight, internalProps.defaultColWidth = defaultColWidth, internalProps.defaultHeaderColWidth = null != defaultHeaderColWidth ? defaultHeaderColWidth : defaultColWidth, internalProps.keyboardOptions = keyboardOptions, internalProps.eventOptions = eventOptions, internalProps.rowSeriesNumber = rowSeriesNumber, internalProps.columnResizeMode = null !== (_d = null == resize ? void 0 : resize.columnResizeMode) && void 0 !== _d ? _d : columnResizeMode, internalProps.rowResizeMode = null !== (_e = null == resize ? void 0 : resize.rowResizeMode) && void 0 !== _e ? _e : rowResizeMode, internalProps.dragHeaderMode = null !== (_g = null !== (_f = null == dragOrder ? void 0 : dragOrder.dragHeaderMode) && void 0 !== _f ? _f : dragHeaderMode) && void 0 !== _g ? _g : "none", internalProps.renderChartAsync = renderChartAsync, setBatchRenderChartCount(renderChartAsyncBatchCount), internalProps.overscrollBehavior = null != overscrollBehavior ? overscrollBehavior : "auto", internalProps._rowHeightsMap = new NumberRangeMap(this), internalProps._rowRangeHeightsMap = new Map(), internalProps._colRangeWidthsMap = new Map(), internalProps._widthResizedColMap = new Set(), internalProps._heightResizedRowMap = new Set(), this.colWidthsMap = new NumberMap(), this.colContentWidthsMap = new NumberMap(), this.colWidthsLimit = {};
|
|
47577
47660
|
const that = this;
|
|
@@ -47888,9 +47971,12 @@
|
|
|
47888
47971
|
const element = this.getElement();
|
|
47889
47972
|
let widthWithoutPadding = 0,
|
|
47890
47973
|
heightWithoutPadding = 0;
|
|
47891
|
-
|
|
47974
|
+
const isDefWidth = isValid$3(this.canvasWidth),
|
|
47975
|
+
isDefHeight = isValid$3(this.canvasHeight);
|
|
47976
|
+
this.canvasSizeSeted && (isDefWidth && (widthWithoutPadding = this.canvasWidth), isDefHeight && (heightWithoutPadding = this.canvasHeight));
|
|
47977
|
+
if ((!isDefWidth || !isDefHeight) && element.parentElement) {
|
|
47892
47978
|
const computedStyle = element.parentElement.style || window.getComputedStyle(element.parentElement);
|
|
47893
|
-
widthWithoutPadding = element.parentElement.offsetWidth - parseInt(computedStyle.paddingLeft
|
|
47979
|
+
isDefWidth || (widthWithoutPadding = element.parentElement.offsetWidth - (parseInt(computedStyle.paddingLeft, 10) || 0) - (parseInt(computedStyle.paddingRight, 10) || 0)), isDefHeight || (heightWithoutPadding = element.parentElement.offsetHeight - parseInt(computedStyle.paddingTop || "0px", 10) - parseInt(computedStyle.paddingBottom || "0px", 20)), widthWithoutPadding = (null != widthWithoutPadding ? widthWithoutPadding : 1) - (this.options.tableSizeAntiJitter ? 1 : 0), heightWithoutPadding = (null != heightWithoutPadding ? heightWithoutPadding : 1) - (this.options.tableSizeAntiJitter ? 1 : 0);
|
|
47894
47980
|
}
|
|
47895
47981
|
element.style.width = widthWithoutPadding && widthWithoutPadding - padding.left - padding.right + "px" || "0px", element.style.height = heightWithoutPadding && heightWithoutPadding - padding.top - padding.bottom + "px" || "0px";
|
|
47896
47982
|
const {
|
|
@@ -47999,7 +48085,7 @@
|
|
|
47999
48085
|
return this._adjustColWidth(col, this._colWidthDefineToPxWidth(width));
|
|
48000
48086
|
}
|
|
48001
48087
|
isAutoRowHeight(row) {
|
|
48002
|
-
return "autoHeight" === this.heightMode || !!this.options.customComputeRowHeight || row >= 0 && row < this.columnHeaderLevelCount
|
|
48088
|
+
return "autoHeight" === this.heightMode || !!this.options.customComputeRowHeight || (row >= 0 && row < this.columnHeaderLevelCount ? "auto" === this.getDefaultRowHeight(row) : "auto" === this.internalProps.defaultRowHeight);
|
|
48003
48089
|
}
|
|
48004
48090
|
getColWidth(col) {
|
|
48005
48091
|
var _a;
|
|
@@ -48649,7 +48735,18 @@
|
|
|
48649
48735
|
var _a;
|
|
48650
48736
|
if (this.internalProps.customMergeCell) {
|
|
48651
48737
|
const customMerge = this.internalProps.customMergeCell(col, row, this);
|
|
48652
|
-
if (customMerge && customMerge.range && (isValid$3(customMerge.text) || customMerge.customLayout || customMerge.customRender))
|
|
48738
|
+
if (customMerge && customMerge.range && (isValid$3(customMerge.text) || customMerge.customLayout || customMerge.customRender)) {
|
|
48739
|
+
return {
|
|
48740
|
+
start: {
|
|
48741
|
+
col: Math.max(customMerge.range.start.col, 0),
|
|
48742
|
+
row: Math.max(customMerge.range.start.row, 0)
|
|
48743
|
+
},
|
|
48744
|
+
end: {
|
|
48745
|
+
col: Math.min(customMerge.range.end.col, this.colCount - 1),
|
|
48746
|
+
row: Math.min(customMerge.range.end.row, this.rowCount - 1)
|
|
48747
|
+
}
|
|
48748
|
+
};
|
|
48749
|
+
}
|
|
48653
48750
|
}
|
|
48654
48751
|
return null === (_a = this.internalProps.layoutMap) || void 0 === _a ? void 0 : _a.getCellRange(col, row);
|
|
48655
48752
|
}
|
|
@@ -50832,9 +50929,9 @@
|
|
|
50832
50929
|
}, null), this._headerObjectsIncludeHided = this._addHeaders(0, columns, []), this._headerObjects = this._headerObjectsIncludeHided.filter(col => !0 !== col.define.hide), this._headerObjectMap = this._headerObjects.reduce((o, e) => (o[e.id] = e, o), {}), this.rowHierarchyType = checkHasTreeDefine(this) ? "tree" : "grid", this._hasAggregation = checkHasAggregation(this), this._hasAggregationOnBottomCount = checkHasAggregationOnBottom(this), this._hasAggregationOnTopCount = checkHasAggregationOnTop(this), this.handleRowSeriesNumber(table.internalProps.rowSeriesNumber);
|
|
50833
50930
|
}
|
|
50834
50931
|
handleRowSeriesNumber(rowSeriesNumber) {
|
|
50835
|
-
var _a
|
|
50932
|
+
var _a;
|
|
50836
50933
|
rowSeriesNumber && (Array.isArray(rowSeriesNumber) ? this.rowSeriesNumberColumn = rowSeriesNumber.map((seriesNumber, index) => {
|
|
50837
|
-
var _a, _b
|
|
50934
|
+
var _a, _b;
|
|
50838
50935
|
return {
|
|
50839
50936
|
id: this.seqId++,
|
|
50840
50937
|
title: seriesNumber.title,
|
|
@@ -50842,11 +50939,11 @@
|
|
|
50842
50939
|
field: "_vtable_rowSeries_number_" + index
|
|
50843
50940
|
}, seriesNumber),
|
|
50844
50941
|
cellType: null !== (_a = seriesNumber.cellType) && void 0 !== _a ? _a : "text",
|
|
50845
|
-
headerType:
|
|
50942
|
+
headerType: "checkbox" === seriesNumber.cellType ? "checkbox" : "text",
|
|
50846
50943
|
style: seriesNumber.style,
|
|
50847
50944
|
width: seriesNumber.width,
|
|
50848
50945
|
format: seriesNumber.format,
|
|
50849
|
-
field: null !== (
|
|
50946
|
+
field: null !== (_b = seriesNumber.field) && void 0 !== _b ? _b : "_vtable_rowSeries_number_" + index,
|
|
50850
50947
|
icon: seriesNumber.icon,
|
|
50851
50948
|
headerIcon: seriesNumber.headerIcon,
|
|
50852
50949
|
isChildNode: !1
|
|
@@ -50858,7 +50955,7 @@
|
|
|
50858
50955
|
field: "_vtable_rowSeries_number"
|
|
50859
50956
|
}, rowSeriesNumber),
|
|
50860
50957
|
cellType: null !== (_a = rowSeriesNumber.cellType) && void 0 !== _a ? _a : "text",
|
|
50861
|
-
headerType:
|
|
50958
|
+
headerType: "checkbox" === rowSeriesNumber.cellType ? "checkbox" : "text",
|
|
50862
50959
|
style: rowSeriesNumber.style,
|
|
50863
50960
|
width: rowSeriesNumber.width,
|
|
50864
50961
|
format: rowSeriesNumber.format,
|
|
@@ -51740,7 +51837,7 @@
|
|
|
51740
51837
|
newWidth = computeColWidth(col, 0, table.rowCount - 1, table, !1);
|
|
51741
51838
|
newWidth !== oldWidth && table.scenegraph.updateColWidth(col, newWidth - oldWidth);
|
|
51742
51839
|
}
|
|
51743
|
-
if ("adaptive" === table.heightMode || table.autoFillHeight && table.getAllRowsHeight() <= table.tableNoFrameHeight) 0 === table.internalProps._heightResizedRowMap.size && table.scenegraph.recalculateRowHeights();else if (table.isAutoRowHeight() && !table.internalProps._heightResizedRowMap.has(row)) {
|
|
51840
|
+
if ("adaptive" === table.heightMode || table.autoFillHeight && table.getAllRowsHeight() <= table.tableNoFrameHeight) 0 === table.internalProps._heightResizedRowMap.size && table.scenegraph.recalculateRowHeights();else if (table.isAutoRowHeight(row) && !table.internalProps._heightResizedRowMap.has(row)) {
|
|
51744
51841
|
const oldHeight = table.getRowHeight(row),
|
|
51745
51842
|
newHeight = computeRowHeight(row, 0, table.colCount - 1, table);
|
|
51746
51843
|
table.scenegraph.updateRowHeight(row, newHeight - oldHeight);
|
|
@@ -51830,7 +51927,7 @@
|
|
|
51830
51927
|
newWidth = computeColWidth(sCol, 0, table.rowCount - 1, table, !1);
|
|
51831
51928
|
newWidth !== oldWidth && table.scenegraph.updateColWidth(sCol, newWidth - oldWidth);
|
|
51832
51929
|
}
|
|
51833
|
-
if ("adaptive" === table.heightMode || table.autoFillHeight && table.getAllRowsHeight() <= table.tableNoFrameHeight) table.scenegraph.recalculateRowHeights();else if (table.isAutoRowHeight()) {
|
|
51930
|
+
if ("adaptive" === table.heightMode || table.autoFillHeight && table.getAllRowsHeight() <= table.tableNoFrameHeight) table.scenegraph.recalculateRowHeights();else if (table.isAutoRowHeight(startRow)) {
|
|
51834
51931
|
const rows = [],
|
|
51835
51932
|
deltaYs = [];
|
|
51836
51933
|
for (let sRow = startRow; sRow <= range.end.row; sRow++) if (table.rowHeightsMap.get(sRow)) {
|
|
@@ -56117,7 +56214,7 @@
|
|
|
56117
56214
|
lineClamp: lineClamp
|
|
56118
56215
|
} = cellStyle,
|
|
56119
56216
|
autoColWidth = "auto" === colWidth,
|
|
56120
|
-
autoRowHeight = table.isAutoRowHeight(),
|
|
56217
|
+
autoRowHeight = table.isAutoRowHeight(row),
|
|
56121
56218
|
attribute = {
|
|
56122
56219
|
maxLineWidth: autoColWidth ? 1 / 0 : cellWidth - (padding[1] + padding[3] + hierarchyOffset) - size - spaceBetweenTextAndIcon,
|
|
56123
56220
|
textAlign: "left",
|
|
@@ -56658,13 +56755,20 @@
|
|
|
56658
56755
|
iconSize = Math.floor(Math.min(width - padding[1] - padding[3], height - padding[2] - padding[0]) / 2),
|
|
56659
56756
|
anchorX = 0 + (width > image.attribute.width ? image.attribute.x - 0 + image.attribute.width / 2 : width / 2),
|
|
56660
56757
|
anchorY = 0 + (height > image.attribute.height ? image.attribute.y - 0 + image.attribute.height / 2 : height / 2),
|
|
56758
|
+
imageGraphic = cellGroup.getChildByName("image", !0),
|
|
56759
|
+
{
|
|
56760
|
+
dx: dx,
|
|
56761
|
+
dy: dy
|
|
56762
|
+
} = imageGraphic.attribute,
|
|
56661
56763
|
playIcon = new Icon({
|
|
56662
56764
|
x: anchorX - iconSize / 2,
|
|
56663
56765
|
y: anchorY - iconSize / 2,
|
|
56664
56766
|
width: iconSize,
|
|
56665
56767
|
height: iconSize,
|
|
56666
56768
|
image: regedIcons.play.svg,
|
|
56667
|
-
cursor: regedIcons.play.cursor
|
|
56769
|
+
cursor: regedIcons.play.cursor,
|
|
56770
|
+
dx: dx,
|
|
56771
|
+
dy: dy
|
|
56668
56772
|
});
|
|
56669
56773
|
playIcon.name = "play-icon", cellGroup.appendChild(playIcon), table.scenegraph.updateNextFrame();
|
|
56670
56774
|
}), video.onerror = () => {
|