@visactor/vtable-calendar 1.22.11-alpha.9 → 1.22.11

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.
@@ -34879,7 +34879,6 @@
34879
34879
  AFTER_UPDATE_CELL_CONTENT_WIDTH: "after_update_cell_content_width",
34880
34880
  AFTER_UPDATE_SELECT_BORDER_HEIGHT: "after_update_select_border_height",
34881
34881
  CHANGE_CELL_VALUE: "change_cell_value",
34882
- CHANGE_CELL_VALUES: "change_cell_values",
34883
34882
  DRAG_FILL_HANDLE_END: "drag_fill_handle_end",
34884
34883
  MOUSEDOWN_FILL_HANDLE: "mousedown_fill_handle",
34885
34884
  DBLCLICK_FILL_HANDLE: "dblclick_fill_handle",
@@ -36998,24 +36997,6 @@
36998
36997
  }
36999
36998
  }
37000
36999
  }
37001
- changeFieldValueByRecordIndex(value, recordIndex, field, table) {
37002
- var _a, _b, _c, _d;
37003
- if (null === field) return;
37004
- if (null == recordIndex) return;
37005
- const rawKey = recordIndex.toString();
37006
- if (!this.beforeChangedRecordsMap.has(rawKey)) {
37007
- const rawRecords = Array.isArray(null === (_a = this.dataSourceObj) || void 0 === _a ? void 0 : _a.records) ? this.dataSourceObj.records : null,
37008
- originRecord = rawRecords ? Array.isArray(recordIndex) ? getValueFromDeepArray(rawRecords, recordIndex) : rawRecords[recordIndex] : void 0;
37009
- this.beforeChangedRecordsMap.set(rawKey, null !== (_b = cloneDeep(originRecord, void 0, ["vtable_gantt_linkedFrom", "vtable_gantt_linkedTo"])) && void 0 !== _b ? _b : {});
37010
- }
37011
- if ("string" == typeof field || "number" == typeof field) {
37012
- const beforeChangedValue = null === (_c = this.beforeChangedRecordsMap.get(rawKey)) || void 0 === _c ? void 0 : _c[field],
37013
- rawRecords = Array.isArray(null === (_d = this.dataSourceObj) || void 0 === _d ? void 0 : _d.records) ? this.dataSourceObj.records : null,
37014
- record = rawRecords ? Array.isArray(recordIndex) ? getValueFromDeepArray(rawRecords, recordIndex) : rawRecords[recordIndex] : void 0;
37015
- let formatValue = value;
37016
- "number" == typeof beforeChangedValue && isAllDigits(value) && (formatValue = parseFloat(value)), record ? record[field] = formatValue : rawRecords && "number" == typeof recordIndex && (rawRecords[recordIndex] = "Array" === this.addRecordRule ? [] : {}, rawRecords[recordIndex][field] = formatValue);
37017
- }
37018
- }
37019
37000
  cacheBeforeChangedRecord(dataIndex, table) {
37020
37001
  var _a;
37021
37002
  if (!this.beforeChangedRecordsMap.has(dataIndex.toString())) {
@@ -37031,92 +37012,41 @@
37031
37012
  Array.isArray(indexed) || this.records.splice(indexed, 1, record);
37032
37013
  }
37033
37014
  }
37034
- _getRawRecordsArray() {
37015
+ addRecord(record, index) {
37035
37016
  var _a;
37036
- const rawRecords = null === (_a = this.dataSourceObj) || void 0 === _a ? void 0 : _a.records;
37037
- return Array.isArray(rawRecords) ? rawRecords : null;
37038
- }
37039
- _hasFilterInEffect() {
37040
- var _a, _b, _c, _d, _e;
37041
- return (null !== (_c = null === (_b = null === (_a = this.dataConfig) || void 0 === _a ? void 0 : _a.filterRules) || void 0 === _b ? void 0 : _b.length) && void 0 !== _c ? _c : 0) >= 1 || (null !== (_e = null === (_d = this.lastFilterRules) || void 0 === _d ? void 0 : _d.length) && void 0 !== _e ? _e : 0) >= 1;
37042
- }
37043
- _normalizeInsertIndex(index, length) {
37044
- return null == index || index > length ? length : index < 0 ? 0 : index;
37045
- }
37046
- _mapViewInsertIndexToRawInsertIndex(rawRecords, viewIndex) {
37047
- if (0 === this.records.length) return rawRecords.length;
37048
- if (viewIndex <= 0) {
37049
- const firstVisibleRecord = this.records[0],
37050
- rawIndex = rawRecords.indexOf(firstVisibleRecord);
37051
- return rawIndex >= 0 ? rawIndex : 0;
37052
- }
37053
- if (viewIndex >= this.records.length) {
37054
- const lastVisibleRecord = this.records[this.records.length - 1],
37055
- rawIndex = rawRecords.indexOf(lastVisibleRecord);
37056
- return rawIndex >= 0 ? rawIndex + 1 : rawRecords.length;
37057
- }
37058
- const prevRecord = this.records[viewIndex - 1],
37059
- rawIndex = rawRecords.indexOf(prevRecord);
37060
- return rawIndex >= 0 ? rawIndex + 1 : rawRecords.length;
37061
- }
37062
- _resetIndexingFromViewRecords() {
37063
- if (this._sourceLength = this.records.length, this.currentIndexedData = Array.from({
37064
- length: this._sourceLength
37065
- }, (_, i) => i), "tree" === this.rowHierarchyType && this.initTreeHierarchyState(), this.userPagination) return this.pagination.totalCount = this._sourceLength, void this.updatePagerData();
37066
- this.pagination.perPageCount = this._sourceLength, this.pagination.totalCount = this._sourceLength, this.updatePagerData();
37067
- }
37068
- addRecord(record, index, syncToOriginalRecords = !1) {
37069
- var _a, _b, _c;
37070
- if (!syncToOriginalRecords) {
37071
- if (Array.isArray(this.records)) {
37072
- this.records.splice(index, 0, record), this.adjustBeforeChangedRecordsMap(index, 1), this.currentIndexedData.push(this.currentIndexedData.length), this._sourceLength += 1;
37073
- for (let i = 0; i < this.fieldAggregators.length; i++) this.fieldAggregators[i].push(record);
37074
- if ("tree" === this.rowHierarchyType && this.initTreeHierarchyState(), this.userPagination) {
37075
- this.pagination.totalCount = this._sourceLength;
37076
- const {
37077
- perPageCount: perPageCount,
37078
- currentPage: currentPage
37079
- } = this.pagination;
37080
- index < perPageCount * (currentPage || 0) + perPageCount && this.updatePagerData();
37081
- } else this.pagination.perPageCount = this._sourceLength, this.pagination.totalCount = this._sourceLength, this.updatePagerData();
37082
- (null === (_a = this.dataSourceObj) || void 0 === _a ? void 0 : _a.added) && this.dataSourceObj.added(index, 1);
37083
- }
37084
- return;
37017
+ if (Array.isArray(this.records)) {
37018
+ this.records.splice(index, 0, record), this.adjustBeforeChangedRecordsMap(index, 1), this.currentIndexedData.push(this.currentIndexedData.length), this._sourceLength += 1;
37019
+ for (let i = 0; i < this.fieldAggregators.length; i++) this.fieldAggregators[i].push(record);
37020
+ if ("tree" === this.rowHierarchyType && this.initTreeHierarchyState(), this.userPagination) {
37021
+ this.pagination.totalCount = this._sourceLength;
37022
+ const {
37023
+ perPageCount: perPageCount,
37024
+ currentPage: currentPage
37025
+ } = this.pagination;
37026
+ index < perPageCount * (currentPage || 0) + perPageCount && this.updatePagerData();
37027
+ } else this.pagination.perPageCount = this._sourceLength, this.pagination.totalCount = this._sourceLength, this.updatePagerData();
37028
+ (null === (_a = this.dataSourceObj) || void 0 === _a ? void 0 : _a.added) && this.dataSourceObj.added(index, 1);
37085
37029
  }
37086
- const rawRecords = this._getRawRecordsArray();
37087
- if (!rawRecords) return;
37088
- const viewInsertIndex = this._normalizeInsertIndex(index, this.records.length),
37089
- rawInsertIndex = this._hasFilterInEffect() ? this._mapViewInsertIndexToRawInsertIndex(rawRecords, viewInsertIndex) : this._normalizeInsertIndex(viewInsertIndex, rawRecords.length);
37090
- rawRecords.splice(rawInsertIndex, 0, record), syncToOriginalRecords && this._hasFilterInEffect() && this.markForceVisibleRecord(record), this.beforeChangedRecordsMap.clear(), this.sortedIndexMap.clear(), this.updateFilterRules(null === (_b = this.dataConfig) || void 0 === _b ? void 0 : _b.filterRules), (null === (_c = this.dataSourceObj) || void 0 === _c ? void 0 : _c.added) && this.dataSourceObj.added(rawInsertIndex, 1);
37091
37030
  }
37092
- addRecords(recordArr, index, syncToOriginalRecords = !1) {
37093
- var _a, _b, _c;
37094
- if (!syncToOriginalRecords) {
37095
- if (Array.isArray(this.records)) {
37096
- if (Array.isArray(recordArr)) {
37097
- this.records.splice(index, 0, ...recordArr), this.adjustBeforeChangedRecordsMap(index, recordArr.length);
37098
- for (let i = 0; i < recordArr.length; i++) this.currentIndexedData.push(this.currentIndexedData.length);
37099
- this._sourceLength += recordArr.length;
37100
- for (let i = 0; i < this.fieldAggregators.length; i++) for (let j = 0; j < recordArr.length; j++) this.fieldAggregators[i].push(recordArr[j]);
37101
- }
37102
- if (this.userPagination) {
37103
- this.pagination.totalCount = this._sourceLength;
37104
- const {
37105
- perPageCount: perPageCount,
37106
- currentPage: currentPage
37107
- } = this.pagination;
37108
- index < perPageCount * (currentPage || 0) + perPageCount && this.updatePagerData();
37109
- } else this.pagination.perPageCount = this._sourceLength, this.pagination.totalCount = this._sourceLength, this.updatePagerData();
37110
- (null === (_a = this.dataSourceObj) || void 0 === _a ? void 0 : _a.added) && this.dataSourceObj.added(index, recordArr.length);
37031
+ addRecords(recordArr, index) {
37032
+ var _a;
37033
+ if (Array.isArray(this.records)) {
37034
+ if (Array.isArray(recordArr)) {
37035
+ this.records.splice(index, 0, ...recordArr), this.adjustBeforeChangedRecordsMap(index, recordArr.length);
37036
+ for (let i = 0; i < recordArr.length; i++) this.currentIndexedData.push(this.currentIndexedData.length);
37037
+ this._sourceLength += recordArr.length;
37038
+ for (let i = 0; i < this.fieldAggregators.length; i++) for (let j = 0; j < recordArr.length; j++) this.fieldAggregators[i].push(recordArr[j]);
37111
37039
  }
37112
- return;
37040
+ if (this.userPagination) {
37041
+ this.pagination.totalCount = this._sourceLength;
37042
+ const {
37043
+ perPageCount: perPageCount,
37044
+ currentPage: currentPage
37045
+ } = this.pagination;
37046
+ index < perPageCount * (currentPage || 0) + perPageCount && this.updatePagerData();
37047
+ } else this.pagination.perPageCount = this._sourceLength, this.pagination.totalCount = this._sourceLength, this.updatePagerData();
37048
+ (null === (_a = this.dataSourceObj) || void 0 === _a ? void 0 : _a.added) && this.dataSourceObj.added(index, recordArr.length);
37113
37049
  }
37114
- const rawRecords = this._getRawRecordsArray();
37115
- if (!rawRecords || !Array.isArray(recordArr) || 0 === recordArr.length) return;
37116
- const viewInsertIndex = this._normalizeInsertIndex(index, this.records.length),
37117
- rawInsertIndex = this._hasFilterInEffect() ? this._mapViewInsertIndexToRawInsertIndex(rawRecords, viewInsertIndex) : this._normalizeInsertIndex(viewInsertIndex, rawRecords.length);
37118
- if (rawRecords.splice(rawInsertIndex, 0, ...recordArr), syncToOriginalRecords && this._hasFilterInEffect()) for (let i = 0; i < recordArr.length; i++) this.markForceVisibleRecord(recordArr[i]);
37119
- this.beforeChangedRecordsMap.clear(), this.sortedIndexMap.clear(), this.updateFilterRules(null === (_b = this.dataConfig) || void 0 === _b ? void 0 : _b.filterRules), (null === (_c = this.dataSourceObj) || void 0 === _c ? void 0 : _c.added) && this.dataSourceObj.added(rawInsertIndex, recordArr.length);
37120
37050
  }
37121
37051
  addRecordForSorted(record) {
37122
37052
  Array.isArray(this.records) && (this.beforeChangedRecordsMap.clear(), this.records.push(record), this.currentIndexedData.push(this.currentIndexedData.length), this._sourceLength += 1, this.sortedIndexMap.clear(), this.userPagination || (this.pagination.perPageCount = this._sourceLength, this.pagination.totalCount = this._sourceLength));
@@ -37132,49 +37062,27 @@
37132
37062
  }
37133
37063
  }
37134
37064
  adjustBeforeChangedRecordsMap(insertIndex, insertCount, type = "add") {
37135
- const delta = "add" === type ? insertCount : -insertCount,
37136
- numericKeys = [];
37137
- this.beforeChangedRecordsMap.forEach((_, key) => {
37138
- const numKey = Number(key);
37139
- Number.isInteger(numKey) && numKey.toString() === key && numKey >= insertIndex && numericKeys.push(numKey);
37140
- }), numericKeys.sort((a, b) => "add" === type ? b - a : a - b);
37141
- for (let i = 0; i < numericKeys.length; i++) {
37142
- const key = numericKeys[i],
37143
- record = this.beforeChangedRecordsMap.get(key.toString());
37144
- this.beforeChangedRecordsMap.delete(key.toString()), this.beforeChangedRecordsMap.set((key + delta).toString(), record);
37145
- }
37146
- }
37147
- deleteRecords(recordIndexs, syncToOriginalRecords = !1) {
37148
- var _a, _b, _c;
37149
- if (!syncToOriginalRecords) {
37150
- if (Array.isArray(this.records)) {
37151
- const realDeletedRecordIndexs = [],
37152
- recordIndexsMaxToMin = recordIndexs.sort((a, b) => b - a);
37153
- for (let index = 0; index < recordIndexsMaxToMin.length; index++) {
37154
- const recordIndex = recordIndexsMaxToMin[index];
37155
- if (recordIndex >= this._sourceLength || recordIndex < 0) continue;
37156
- this.adjustBeforeChangedRecordsMap(recordIndex, 1, "delete"), realDeletedRecordIndexs.push(recordIndex);
37157
- const deletedRecord = this.records[recordIndex];
37158
- for (let i = 0; i < this.fieldAggregators.length; i++) this.fieldAggregators[i].deleteRecord(deletedRecord);
37159
- this.records.splice(recordIndex, 1), this.currentIndexedData.pop(), this._sourceLength -= 1;
37160
- }
37161
- return this.userPagination || (this.pagination.perPageCount = this._sourceLength, this.pagination.totalCount = this._sourceLength), this.updatePagerData(), (null === (_a = this.dataSourceObj) || void 0 === _a ? void 0 : _a.deleted) && this.dataSourceObj.deleted(realDeletedRecordIndexs), realDeletedRecordIndexs;
37162
- }
37163
- return [];
37065
+ for (let key = this.beforeChangedRecordsMap.size - 1; key >= insertIndex; key--) {
37066
+ const record = this.beforeChangedRecordsMap.get(key.toString());
37067
+ this.beforeChangedRecordsMap.delete(key.toString()), this.beforeChangedRecordsMap.set((key + ("add" === type ? insertCount : -insertCount)).toString(), record);
37164
37068
  }
37165
- const rawRecords = this._getRawRecordsArray();
37166
- if (!rawRecords || !Array.isArray(this.records)) return [];
37167
- const realDeletedRecordIndexs = [],
37168
- recordIndexsMaxToMin = recordIndexs.slice().sort((a, b) => b - a),
37169
- rawDeletedIndexs = [];
37170
- for (let index = 0; index < recordIndexsMaxToMin.length; index++) {
37171
- const viewIndex = recordIndexsMaxToMin[index];
37172
- if (viewIndex >= this.records.length || viewIndex < 0) continue;
37173
- const deletedRecord = this.records[viewIndex],
37174
- rawIndex = rawRecords.indexOf(deletedRecord);
37175
- rawIndex >= 0 && (rawRecords.splice(rawIndex, 1), rawDeletedIndexs.push(rawIndex)), realDeletedRecordIndexs.push(viewIndex);
37069
+ }
37070
+ deleteRecords(recordIndexs) {
37071
+ var _a;
37072
+ if (Array.isArray(this.records)) {
37073
+ const realDeletedRecordIndexs = [],
37074
+ recordIndexsMaxToMin = recordIndexs.sort((a, b) => b - a);
37075
+ for (let index = 0; index < recordIndexsMaxToMin.length; index++) {
37076
+ const recordIndex = recordIndexsMaxToMin[index];
37077
+ if (recordIndex >= this._sourceLength || recordIndex < 0) continue;
37078
+ this.adjustBeforeChangedRecordsMap(recordIndex, 1, "delete"), realDeletedRecordIndexs.push(recordIndex);
37079
+ const deletedRecord = this.records[recordIndex];
37080
+ for (let i = 0; i < this.fieldAggregators.length; i++) this.fieldAggregators[i].deleteRecord(deletedRecord);
37081
+ this.records.splice(recordIndex, 1), this.currentIndexedData.pop(), this._sourceLength -= 1;
37082
+ }
37083
+ return this.userPagination || (this.pagination.perPageCount = this._sourceLength, this.pagination.totalCount = this._sourceLength), this.updatePagerData(), (null === (_a = this.dataSourceObj) || void 0 === _a ? void 0 : _a.deleted) && this.dataSourceObj.deleted(realDeletedRecordIndexs), realDeletedRecordIndexs;
37176
37084
  }
37177
- return this.beforeChangedRecordsMap.clear(), this.sortedIndexMap.clear(), this.updateFilterRules(null === (_b = this.dataConfig) || void 0 === _b ? void 0 : _b.filterRules), (null === (_c = this.dataSourceObj) || void 0 === _c ? void 0 : _c.deleted) && this.dataSourceObj.deleted(rawDeletedIndexs), realDeletedRecordIndexs;
37085
+ return [];
37178
37086
  }
37179
37087
  deleteRecordsForSorted(recordIndexs) {
37180
37088
  if (Array.isArray(this.records)) {
@@ -37188,34 +37096,18 @@
37188
37096
  this.sortedIndexMap.clear(), this.userPagination || (this.pagination.perPageCount = this._sourceLength, this.pagination.totalCount = this._sourceLength), this.beforeChangedRecordsMap.clear();
37189
37097
  }
37190
37098
  }
37191
- updateRecords(records, recordIndexs, syncToOriginalRecords = !1) {
37192
- var _a;
37193
- if (!syncToOriginalRecords) {
37194
- const realDeletedRecordIndexs = [];
37195
- for (let index = 0; index < recordIndexs.length; index++) {
37196
- const recordIndex = recordIndexs[index];
37197
- if (Array.isArray(recordIndex)) this.beforeChangedRecordsMap.delete(recordIndex.toString()), realDeletedRecordIndexs.push(recordIndex), recordIndex.slice(0, -1).reduce((acc, key) => (void 0 === acc[key] && (acc[key] = {}), acc[key].children), this.records)[recordIndex[recordIndex.length - 1]] = records[index];else {
37198
- if (recordIndex >= this._sourceLength || recordIndex < 0) continue;
37199
- this.beforeChangedRecordsMap.delete(recordIndex.toString()), realDeletedRecordIndexs.push(recordIndex);
37200
- for (let i = 0; i < this.fieldAggregators.length; i++) this.fieldAggregators[i].updateRecord(this.records[recordIndex], records[index]);
37201
- this.records[recordIndex] = records[index];
37202
- }
37203
- }
37204
- return this.userPagination && this.updatePagerData(), realDeletedRecordIndexs;
37205
- }
37206
- const rawRecords = this._getRawRecordsArray();
37207
- if (!rawRecords || !Array.isArray(this.records)) return [];
37208
- const realUpdatedIndexs = [];
37099
+ updateRecords(records, recordIndexs) {
37100
+ const realDeletedRecordIndexs = [];
37209
37101
  for (let index = 0; index < recordIndexs.length; index++) {
37210
37102
  const recordIndex = recordIndexs[index];
37211
- if (Array.isArray(recordIndex)) this.beforeChangedRecordsMap.delete(recordIndex.toString()), realUpdatedIndexs.push(recordIndex), recordIndex.slice(0, -1).reduce((acc, key) => (void 0 === acc[key] && (acc[key] = {}), acc[key].children), rawRecords)[recordIndex[recordIndex.length - 1]] = records[index];else {
37212
- if (recordIndex >= this.records.length || recordIndex < 0) continue;
37213
- const oldRecord = this.records[recordIndex],
37214
- rawIndex = rawRecords.indexOf(oldRecord);
37215
- rawIndex >= 0 && (rawRecords[rawIndex] = records[index]), realUpdatedIndexs.push(recordIndex);
37103
+ if (Array.isArray(recordIndex)) this.beforeChangedRecordsMap.delete(recordIndex.toString()), realDeletedRecordIndexs.push(recordIndex), recordIndex.slice(0, -1).reduce((acc, key) => (void 0 === acc[key] && (acc[key] = {}), acc[key].children), this.records)[recordIndex[recordIndex.length - 1]] = records[index];else {
37104
+ if (recordIndex >= this._sourceLength || recordIndex < 0) continue;
37105
+ this.beforeChangedRecordsMap.delete(recordIndex.toString()), realDeletedRecordIndexs.push(recordIndex);
37106
+ for (let i = 0; i < this.fieldAggregators.length; i++) this.fieldAggregators[i].updateRecord(this.records[recordIndex], records[index]);
37107
+ this.records[recordIndex] = records[index];
37216
37108
  }
37217
37109
  }
37218
- return this.beforeChangedRecordsMap.clear(), this.sortedIndexMap.clear(), this.updateFilterRules(null === (_a = this.dataConfig) || void 0 === _a ? void 0 : _a.filterRules), realUpdatedIndexs;
37110
+ return this.userPagination && this.updatePagerData(), realDeletedRecordIndexs;
37219
37111
  }
37220
37112
  updateRecordsForSorted(records, recordIndexs) {
37221
37113
  for (let index = 0; index < recordIndexs.length; index++) {
@@ -37283,30 +37175,23 @@
37283
37175
  setSortedIndexMap(field, filedMap) {
37284
37176
  this.sortedIndexMap.set(field, filedMap);
37285
37177
  }
37286
- markForceVisibleRecord(record) {
37287
- !record || "object" != typeof record && "function" != typeof record || (this._forceVisibleRecords || (this._forceVisibleRecords = new WeakSet()), this._forceVisibleRecords.add(record));
37288
- }
37289
- clearForceVisibleRecords() {
37290
- this._forceVisibleRecords = void 0;
37291
- }
37292
37178
  clearFilteredChildren(record) {
37293
37179
  var _a, _b;
37294
37180
  record.filteredChildren = void 0;
37295
37181
  for (let i = 0; i < (null !== (_b = null === (_a = record.children) || void 0 === _a ? void 0 : _a.length) && void 0 !== _b ? _b : 0); i++) this.clearFilteredChildren(record.children[i]);
37296
37182
  }
37297
37183
  filterRecord(record) {
37298
- var _a, _b, _c, _d;
37299
- if (null === (_a = this._forceVisibleRecords) || void 0 === _a ? void 0 : _a.has(record)) return !0;
37184
+ var _a, _b, _c;
37300
37185
  let isReserved = !0;
37301
- for (let i = 0; i < (null === (_b = this.dataConfig.filterRules) || void 0 === _b ? void 0 : _b.length); i++) {
37302
- const filterRule = null === (_c = this.dataConfig) || void 0 === _c ? void 0 : _c.filterRules[i];
37186
+ for (let i = 0; i < (null === (_a = this.dataConfig.filterRules) || void 0 === _a ? void 0 : _a.length); i++) {
37187
+ const filterRule = null === (_b = this.dataConfig) || void 0 === _b ? void 0 : _b.filterRules[i];
37303
37188
  if (filterRule.filterKey) {
37304
37189
  const filterValue = record[filterRule.filterKey];
37305
37190
  if (-1 === filterRule.filteredValues.indexOf(filterValue)) {
37306
37191
  isReserved = !1;
37307
37192
  break;
37308
37193
  }
37309
- } else if (!(null === (_d = filterRule.filterFunc) || void 0 === _d ? void 0 : _d.call(filterRule, record))) {
37194
+ } else if (!(null === (_c = filterRule.filterFunc) || void 0 === _c ? void 0 : _c.call(filterRule, record))) {
37310
37195
  isReserved = !1;
37311
37196
  break;
37312
37197
  }
@@ -47890,7 +47775,7 @@
47890
47775
  rowUpdatePos = isValid$1(rowUpdatePos) ? isValid$1(pos) ? Math.min(rowUpdatePos, pos) : rowUpdatePos : pos;
47891
47776
  }
47892
47777
  let updateAfter;
47893
- if (scene.table._clearRowRangeHeightsMap(), addRows.forEach(row => {
47778
+ if (scene.table._clearRowRangeHeightsMap(), verifyProxyRowStatus(scene), addRows.forEach(row => {
47894
47779
  const needUpdateAfter = addRow(row, scene, skipUpdateProxy);
47895
47780
  updateAfter = null != updateAfter ? updateAfter : needUpdateAfter, rowHeightsMap.insert(row);
47896
47781
  }), resetRowNumberAndY(scene), addRows.length) {
@@ -48120,6 +48005,25 @@
48120
48005
  function setRowSeriesNumberCellNeedUpdate(startUpdateRow, scene) {
48121
48006
  if (scene.table.isHasSeriesNumber()) for (let row = startUpdateRow; row <= scene.table.rowCount - 1; row++) updateCell$1(0, row, scene.table, !1);
48122
48007
  }
48008
+ function verifyProxyRowStatus(scene) {
48009
+ const proxy = scene.proxy,
48010
+ {
48011
+ rowStart: rowStart,
48012
+ rowEnd: rowEnd,
48013
+ rowLimit: rowLimit,
48014
+ totalRow: totalRow
48015
+ } = proxy;
48016
+ if (rowStart > rowEnd) return proxy.rowStart = scene.table.columnHeaderLevelCount, proxy.rowEnd = Math.min(totalRow, proxy.rowStart + rowLimit - 1), void (proxy.currentRow = 0);
48017
+ if (rowStart + rowLimit - 1 > totalRow) {
48018
+ const oldRowStart = proxy.rowStart,
48019
+ newRowStart = Math.max(scene.table.columnHeaderLevelCount, totalRow - rowLimit + 1);
48020
+ if (newRowStart === oldRowStart) return;
48021
+ proxy.rowStart = newRowStart, proxy.rowEnd = Math.min(totalRow, newRowStart + rowLimit - 1), proxy.currentRow = proxy.rowEnd + 1;
48022
+ const addRowCount = oldRowStart - proxy.rowStart;
48023
+ for (let i = 0; i < addRowCount; i++) addRowCellGroup(proxy.rowStart + i, scene);
48024
+ proxy.rowUpdatePos = proxy.rowStart;
48025
+ }
48026
+ }
48123
48027
 
48124
48028
  function createReactContainer(table) {
48125
48029
  const {
@@ -50075,7 +49979,7 @@
50075
49979
  } else if (-1 === cellPos.col || -1 === cellPos.row || -1 !== col && -1 !== row) {
50076
49980
  if (interactionState !== InteractionState.default || table.eventManager.isDraging || table.stateManager.isResizeCol()) {
50077
49981
  if ((interactionState === InteractionState.grabing || table.eventManager.isDraging) && !table.stateManager.isResizeCol()) {
50078
- let extendSelectRange = !0;
49982
+ let extendSelectRange = !isValid$1(skipBodyMerge) || !skipBodyMerge;
50079
49983
  -1 === cellPos.col && (cellPos.col = col), -1 === cellPos.row && (cellPos.row = row), cellPos.col = col, cellPos.row = row;
50080
49984
  const currentRange = state.select.ranges[state.select.ranges.length - 1];
50081
49985
  if (currentRange) {
@@ -50197,7 +50101,7 @@
50197
50101
  };
50198
50102
  enableShiftSelectMode || (currentRange.end = currentRange.start), scenegraph.deleteLastSelectedRangeComponents(), scenegraph.updateCellSelectBorder(currentRange);
50199
50103
  } else {
50200
- let extendSelectRange = !0;
50104
+ let extendSelectRange = !isValid$1(skipBodyMerge) || !skipBodyMerge;
50201
50105
  if (-1 === cellPos.col || -1 === cellPos.row || enableCtrlSelectMode || (state.select.ranges = [], scenegraph.deleteAllSelectBorder()), "cell" !== state.select.headerSelectMode && table.isColumnHeader(col, row)) {
50202
50106
  const cellRange = table.getCellRange(col, row);
50203
50107
  "body" === state.select.headerSelectMode ? state.select.ranges.push({
@@ -53543,7 +53447,7 @@
53543
53447
  };
53544
53448
  class EventManager {
53545
53449
  constructor(table) {
53546
- this.isDown = !1, this.isDraging = !1, this.globalEventListeners = [], this._enableTableScroll = !0, this.cutWaitPaste = !1, this.clipboardCheckTimer = null, this.cutOperationTime = 0, this.lastClipboardContent = "", this.cutCellRange = null, this.cutRanges = null, this.copySourceRange = null, this.table = table, this.handleTextStickBindId = [], this.inertiaScroll = new InertiaScroll(table.stateManager), "node" === Env.mode || table.options.disableInteraction || (this.bindOuterEvent(), setTimeout(() => {
53450
+ this.isDown = !1, this.isDraging = !1, this.globalEventListeners = [], this._enableTableScroll = !0, this.cutWaitPaste = !1, this.clipboardCheckTimer = null, this.cutOperationTime = 0, this.lastClipboardContent = "", this.cutCellRange = null, this.copySourceRange = null, this.table = table, this.handleTextStickBindId = [], this.inertiaScroll = new InertiaScroll(table.stateManager), "node" === Env.mode || table.options.disableInteraction || (this.bindOuterEvent(), setTimeout(() => {
53547
53451
  this.bindSelfEvent();
53548
53452
  }, 0));
53549
53453
  }
@@ -53845,25 +53749,15 @@
53845
53749
  } catch (error) {}
53846
53750
  }
53847
53751
  handleCut(e) {
53848
- var _a;
53849
53752
  return __awaiter$1(this, void 0, void 0, function* () {
53850
- this.handleCopy(e, !0), this.cutWaitPaste = !0, this.cutCellRange = this.table.getSelectedCellInfos(), this.cutRanges = null === (_a = this.table.stateManager.select.ranges) || void 0 === _a ? void 0 : _a.map(r => ({
53851
- start: {
53852
- col: r.start.col,
53853
- row: r.start.row
53854
- },
53855
- end: {
53856
- col: r.end.col,
53857
- row: r.end.row
53858
- }
53859
- })), this.clipboardCheckTimer && clearTimeout(this.clipboardCheckTimer), this.clipboardCheckTimer = window.setTimeout(() => {
53860
- this.cutWaitPaste && (this.cutWaitPaste = !1, this.cutCellRange = null, this.cutRanges = null, this.clipboardCheckTimer = null);
53753
+ this.handleCopy(e, !0), this.cutWaitPaste = !0, this.cutCellRange = this.table.getSelectedCellInfos(), this.clipboardCheckTimer && clearTimeout(this.clipboardCheckTimer), this.clipboardCheckTimer = window.setTimeout(() => {
53754
+ this.cutWaitPaste && (this.cutWaitPaste = !1, this.cutCellRange = null, this.clipboardCheckTimer = null);
53861
53755
  }, 3e4), this.saveClipboardContent();
53862
53756
  });
53863
53757
  }
53864
53758
  handlePaste(e) {
53865
53759
  this.cutWaitPaste ? this.checkClipboardChanged().then(changed => {
53866
- this.executePaste(e), changed || this.clearCutArea(this.table), this.cutWaitPaste && (this.cutWaitPaste = !1, this.cutCellRange = null, this.cutRanges = null, this.clipboardCheckTimer && (clearTimeout(this.clipboardCheckTimer), this.clipboardCheckTimer = null));
53760
+ this.executePaste(e), changed || this.clearCutArea(this.table), this.cutWaitPaste && (this.cutWaitPaste = !1, this.cutCellRange = null, this.clipboardCheckTimer && (clearTimeout(this.clipboardCheckTimer), this.clipboardCheckTimer = null));
53867
53761
  }).catch(() => {
53868
53762
  this.executePaste(e), this.cutWaitPaste && (this.cutWaitPaste = !1, this.cutCellRange = null, this.clipboardCheckTimer && (clearTimeout(this.clipboardCheckTimer), this.clipboardCheckTimer = null));
53869
53763
  }) : this.executePaste(e);
@@ -53940,9 +53834,9 @@
53940
53834
  }
53941
53835
  clearCutArea(table) {
53942
53836
  try {
53943
- const ranges = this.cutRanges;
53944
- if (!ranges || 0 === ranges.length) return;
53945
- table.changeCellValuesByIds(ranges, "");
53837
+ const selectCells = this.cutCellRange;
53838
+ if (!selectCells || 0 === selectCells.length) return;
53839
+ for (let i = 0; i < selectCells.length; i++) for (let j = 0; j < selectCells[i].length; j++) selectCells[i][j] && table.changeCellValue(selectCells[i][j].col, selectCells[i][j].row, void 0);
53946
53840
  } catch (error) {}
53947
53841
  }
53948
53842
  checkClipboardChanged() {
@@ -55878,22 +55772,41 @@
55878
55772
 
55879
55773
  class CustomCellStylePlugin {
55880
55774
  constructor(table, customCellStyle, customCellStyleArrangement) {
55881
- this.table = table, this.customCellStyle = customCellStyle, this.customCellStyleArrangement = customCellStyleArrangement;
55775
+ this.table = table, this.customCellStyle = customCellStyle, this.customCellStyleArrangement = customCellStyleArrangement, this._customCellStyleArrangementIndex = new Map(), this._customCellStyleArrangementTombstoneCount = 0, this._rebuildCustomCellStyleArrangementIndex();
55776
+ }
55777
+ _getCustomCellStyleArrangementKey(cellPos) {
55778
+ if (cellPos.range) {
55779
+ const {
55780
+ start: start,
55781
+ end: end
55782
+ } = cellPos.range;
55783
+ return `range:${start.col},${start.row},${end.col},${end.row}`;
55784
+ }
55785
+ if (void 0 !== cellPos.col && void 0 !== cellPos.row) return `cell:${cellPos.col},${cellPos.row}`;
55882
55786
  }
55883
- clearCustomCellStyleArrangement() {
55884
- this.customCellStyleArrangement = [];
55787
+ _rebuildCustomCellStyleArrangementIndex() {
55788
+ this._customCellStyleArrangementIndex.clear(), this._customCellStyleArrangementTombstoneCount = 0;
55789
+ for (let i = 0; i < this.customCellStyleArrangement.length; i++) {
55790
+ if (!isValid$1(this.customCellStyleArrangement[i].customStyleId)) {
55791
+ this._customCellStyleArrangementTombstoneCount++;
55792
+ continue;
55793
+ }
55794
+ const key = this._getCustomCellStyleArrangementKey(this.customCellStyleArrangement[i].cellPosition);
55795
+ key && this._customCellStyleArrangementIndex.set(key, i);
55796
+ }
55885
55797
  }
55886
- addCustomCellStyleArrangement(cellPosition, customStyleId) {
55887
- this.customCellStyleArrangement.push({
55888
- cellPosition: cellPosition,
55889
- customStyleId: customStyleId
55890
- });
55798
+ _compactCustomCellStyleArrangementIfNeeded() {
55799
+ const length = this.customCellStyleArrangement.length;
55800
+ if (this._customCellStyleArrangementTombstoneCount < 2048) return;
55801
+ if (4 * this._customCellStyleArrangementTombstoneCount < length) return;
55802
+ const compacted = this.customCellStyleArrangement.filter(style => isValid$1(style.customStyleId));
55803
+ compacted.length !== this.customCellStyleArrangement.length ? (this.customCellStyleArrangement.length = 0, this.customCellStyleArrangement.push(...compacted), this._rebuildCustomCellStyleArrangementIndex()) : this._customCellStyleArrangementTombstoneCount = 0;
55891
55804
  }
55892
55805
  getCustomCellStyle(col, row) {
55893
55806
  const customStyleIds = this.getCustomCellStyleIds(col, row);
55894
55807
  if (customStyleIds.length) {
55895
55808
  const styles = [];
55896
- return customStyleIds.forEach(customStyleId => {
55809
+ if (customStyleIds.forEach(customStyleId => {
55897
55810
  const styleOption = this.getCustomCellStyleOption(customStyleId);
55898
55811
  if (isFunction$3(null == styleOption ? void 0 : styleOption.style)) {
55899
55812
  const style = styleOption.style({
@@ -55906,14 +55819,15 @@
55906
55819
  });
55907
55820
  styles.push(style);
55908
55821
  } else (null == styleOption ? void 0 : styleOption.style) && styles.push(styleOption.style);
55909
- }), merge({}, ...styles);
55822
+ }), !styles.length) return;
55823
+ return merge({}, ...styles);
55910
55824
  }
55911
55825
  }
55912
55826
  getCustomCellStyleIds(col, row) {
55913
55827
  const customStyleIds = [],
55914
55828
  range = this.table.getCellRange(col, row);
55915
55829
  for (let c = range.start.col; c <= range.end.col; c++) for (let r = range.start.row; r <= range.end.row; r++) this.customCellStyleArrangement.forEach(style => {
55916
- style.cellPosition.range ? style.cellPosition.range.start.col <= c && style.cellPosition.range.end.col >= c && style.cellPosition.range.start.row <= r && style.cellPosition.range.end.row >= r && customStyleIds.push(style.customStyleId) : style.cellPosition.col === c && style.cellPosition.row === r && customStyleIds.push(style.customStyleId);
55830
+ isValid$1(style.customStyleId) && (style.cellPosition.range ? style.cellPosition.range.start.col <= c && style.cellPosition.range.end.col >= c && style.cellPosition.range.start.row <= r && style.cellPosition.range.end.row >= r && customStyleIds.push(style.customStyleId) : style.cellPosition.col === c && style.cellPosition.row === r && customStyleIds.push(style.customStyleId));
55917
55831
  });
55918
55832
  return customStyleIds;
55919
55833
  }
@@ -55934,21 +55848,35 @@
55934
55848
  }), this.table.scenegraph.updateNextFrame();
55935
55849
  }
55936
55850
  arrangeCustomCellStyle(cellPos, customStyleId, forceFastUpdate) {
55937
- var _a;
55938
- const index = this.customCellStyleArrangement.findIndex(style => style.cellPosition.range && cellPos.range ? style.cellPosition.range.start.col === cellPos.range.start.col && style.cellPosition.range.start.row === cellPos.range.start.row && style.cellPosition.range.end.col === cellPos.range.end.col && style.cellPosition.range.end.row === cellPos.range.end.row : style.cellPosition.col === cellPos.col && style.cellPosition.row === cellPos.row);
55939
- if (-1 === index && !customStyleId) return;
55940
- if (-1 === index && customStyleId) this.customCellStyleArrangement.push({
55941
- cellPosition: {
55942
- col: cellPos.col,
55943
- row: cellPos.row,
55944
- range: cellPos.range
55945
- },
55946
- customStyleId: customStyleId
55947
- });else {
55851
+ var _a, _b;
55852
+ const inputKey = this._getCustomCellStyleArrangementKey(cellPos);
55853
+ let index = inputKey && null !== (_a = this._customCellStyleArrangementIndex.get(inputKey)) && void 0 !== _a ? _a : -1;
55854
+ if (inputKey && -1 !== index) {
55855
+ const item = this.customCellStyleArrangement[index],
55856
+ itemKey = item ? this._getCustomCellStyleArrangementKey(item.cellPosition) : void 0;
55857
+ item && isValid$1(item.customStyleId) && itemKey === inputKey || (index = this.customCellStyleArrangement.findIndex(style => !!isValid$1(style.customStyleId) && this._getCustomCellStyleArrangementKey(style.cellPosition) === inputKey), -1 !== index ? this._customCellStyleArrangementIndex.set(inputKey, index) : this._customCellStyleArrangementIndex.delete(inputKey));
55858
+ }
55859
+ if (-1 !== index || inputKey || (index = this.customCellStyleArrangement.findIndex(style => !!isValid$1(style.customStyleId) && (style.cellPosition.range && cellPos.range ? style.cellPosition.range.start.col === cellPos.range.start.col && style.cellPosition.range.start.row === cellPos.range.start.row && style.cellPosition.range.end.col === cellPos.range.end.col && style.cellPosition.range.end.row === cellPos.range.end.row : style.cellPosition.col === cellPos.col && style.cellPosition.row === cellPos.row))), -1 === index && !customStyleId) return;
55860
+ if (-1 === index && customStyleId) {
55861
+ this.customCellStyleArrangement.push({
55862
+ cellPosition: {
55863
+ col: cellPos.col,
55864
+ row: cellPos.row,
55865
+ range: cellPos.range
55866
+ },
55867
+ customStyleId: customStyleId
55868
+ });
55869
+ const pushedIndex = this.customCellStyleArrangement.length - 1,
55870
+ pushedKey = this._getCustomCellStyleArrangementKey(this.customCellStyleArrangement[pushedIndex].cellPosition);
55871
+ pushedKey && this._customCellStyleArrangementIndex.set(pushedKey, pushedIndex);
55872
+ } else {
55948
55873
  if (this.customCellStyleArrangement[index].customStyleId === customStyleId) return;
55949
- customStyleId ? this.customCellStyleArrangement[index].customStyleId = customStyleId : this.customCellStyleArrangement.splice(index, 1);
55874
+ if (customStyleId) this.customCellStyleArrangement[index].customStyleId = customStyleId;else {
55875
+ const existedKey = this._getCustomCellStyleArrangementKey(this.customCellStyleArrangement[index].cellPosition);
55876
+ isValid$1(this.customCellStyleArrangement[index].customStyleId) && this._customCellStyleArrangementTombstoneCount++, this.customCellStyleArrangement[index].customStyleId = null, existedKey && this._customCellStyleArrangementIndex.delete(existedKey), this._compactCustomCellStyleArrangementIfNeeded();
55877
+ }
55950
55878
  }
55951
- const style = null === (_a = this.getCustomCellStyleOption(customStyleId)) || void 0 === _a ? void 0 : _a.style;
55879
+ const style = customStyleId ? null === (_b = this.getCustomCellStyleOption(customStyleId)) || void 0 === _b ? void 0 : _b.style : void 0;
55952
55880
  if (style) {
55953
55881
  forceFastUpdate = !0;
55954
55882
  for (const key in style) if (-1 === cellStyleKeys.indexOf(key)) {
@@ -55963,7 +55891,7 @@
55963
55891
  this.table.scenegraph.updateNextFrame();
55964
55892
  }
55965
55893
  updateCustomCell(customCellStyle, customCellStyleArrangement) {
55966
- this.customCellStyle.length = 0, this.customCellStyleArrangement.length = 0, customCellStyle.forEach(cellStyle => {
55894
+ this.customCellStyle.length = 0, this.customCellStyleArrangement.length = 0, this._customCellStyleArrangementIndex.clear(), this._customCellStyleArrangementTombstoneCount = 0, customCellStyle.forEach(cellStyle => {
55967
55895
  this.registerCustomCellStyle(cellStyle.id, cellStyle.style);
55968
55896
  }), customCellStyleArrangement.forEach(cellStyle => {
55969
55897
  this.arrangeCustomCellStyle(cellStyle.cellPosition, cellStyle.customStyleId);
@@ -56194,7 +56122,7 @@
56194
56122
  }
56195
56123
  constructor(container, options = {}) {
56196
56124
  var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y, _z;
56197
- if (super(), this.showFrozenIcon = !0, this.version = "1.22.11-alpha.9", this.id = `VTable${Date.now()}`, this.isReleased = !1, this._chartEventMap = {}, this.throttleInvalidate = throttle2(this.render.bind(this), 200), "node" === Env.mode ? (options = container, container = null) : container instanceof HTMLElement || (options = container, container = container.container ? container.container : null), !container && "node" !== options.mode && !options.canvas) throw new Error("vtable's container is undefined");
56125
+ if (super(), this.showFrozenIcon = !0, this.version = "1.22.11", this.id = `VTable${Date.now()}`, this.isReleased = !1, this._chartEventMap = {}, this.throttleInvalidate = throttle2(this.render.bind(this), 200), "node" === Env.mode ? (options = container, container = null) : container instanceof HTMLElement || (options = container, container = container.container ? container.container : null), !container && "node" !== options.mode && !options.canvas) throw new Error("vtable's container is undefined");
56198
56126
  this.pluginManager = new PluginManager(this, options), this.fireListeners(TABLE_EVENT_TYPE.BEFORE_INIT, {
56199
56127
  options: options,
56200
56128
  container: container
@@ -57408,16 +57336,16 @@
57408
57336
  startCol = enableShiftSelectMode && (null === (_a = null == lastSelectRange ? void 0 : lastSelectRange.start) || void 0 === _a ? void 0 : _a.col) ? null === (_b = null == lastSelectRange ? void 0 : lastSelectRange.start) || void 0 === _b ? void 0 : _b.col : colIndex,
57409
57337
  endCol = colIndex,
57410
57338
  endRow = this.rowCount - 1;
57411
- this.stateManager.updateSelectPos(startCol, 0, enableShiftSelectMode, enableCtrlSelectMode, !1, null === (_d = null === (_c = this.options.select) || void 0 === _c ? void 0 : _c.makeSelectCellVisible) || void 0 === _d || _d, !0), this.stateManager.updateInteractionState(InteractionState.grabing), this.stateManager.updateSelectPos(endCol, endRow, enableShiftSelectMode, enableCtrlSelectMode, !1, null === (_f = null === (_e = this.options.select) || void 0 === _e ? void 0 : _e.makeSelectCellVisible) || void 0 === _f || _f, !0);
57339
+ this.stateManager.updateSelectPos(startCol, 0, enableShiftSelectMode, enableCtrlSelectMode, !1, null === (_d = null === (_c = this.options.select) || void 0 === _c ? void 0 : _c.makeSelectCellVisible) || void 0 === _d || _d, !0), this.stateManager.updateInteractionState(InteractionState.grabing), this.stateManager.updateSelectPos(endCol, endRow, enableShiftSelectMode, enableCtrlSelectMode, !1, null === (_f = null === (_e = this.options.select) || void 0 === _e ? void 0 : _e.makeSelectCellVisible) || void 0 === _f || _f, !0), this.stateManager.select.selecting = !1;
57412
57340
  }
57413
57341
  dragSelectCol(colIndex, enableCtrlSelectMode) {
57414
57342
  var _a, _b;
57415
57343
  const currentSelectRanges = this.stateManager.select.ranges,
57416
57344
  lastSelectRange = currentSelectRanges[currentSelectRanges.length - 1];
57417
- lastSelectRange && (lastSelectRange.end.col = colIndex), this.stateManager.updateSelectPos(colIndex, this.rowCount - 1, !1, enableCtrlSelectMode, !1, null === (_b = null === (_a = this.options.select) || void 0 === _a ? void 0 : _a.makeSelectCellVisible) || void 0 === _b || _b, !0);
57345
+ lastSelectRange && (lastSelectRange.end.col = colIndex), this.stateManager.updateSelectPos(colIndex, this.rowCount - 1, !1, enableCtrlSelectMode, !1, null === (_b = null === (_a = this.options.select) || void 0 === _a ? void 0 : _a.makeSelectCellVisible) || void 0 === _b || _b, !0), this.stateManager.select.selecting = !1;
57418
57346
  }
57419
57347
  endDragSelect() {
57420
- this.stateManager.updateInteractionState(InteractionState.default), this.stateManager.endSelectCells(!1, !1);
57348
+ this.stateManager.updateInteractionState(InteractionState.default);
57421
57349
  }
57422
57350
  startDragSelectRow(rowIndex, enableCtrlSelectMode, isShift) {
57423
57351
  var _a, _b, _c, _d, _e, _f;
@@ -57425,13 +57353,13 @@
57425
57353
  startRow = isShift && (null === (_a = null == lastSelectRange ? void 0 : lastSelectRange.start) || void 0 === _a ? void 0 : _a.row) ? null === (_b = null == lastSelectRange ? void 0 : lastSelectRange.start) || void 0 === _b ? void 0 : _b.row : rowIndex,
57426
57354
  endCol = this.colCount - 1,
57427
57355
  endRow = rowIndex;
57428
- this.stateManager.updateSelectPos(0, startRow, isShift, enableCtrlSelectMode, !1, null === (_d = null === (_c = this.options.select) || void 0 === _c ? void 0 : _c.makeSelectCellVisible) || void 0 === _d || _d, !0), this.stateManager.updateInteractionState(InteractionState.grabing), this.stateManager.updateSelectPos(endCol, endRow, isShift, enableCtrlSelectMode, !1, null === (_f = null === (_e = this.options.select) || void 0 === _e ? void 0 : _e.makeSelectCellVisible) || void 0 === _f || _f, !0);
57356
+ this.stateManager.updateSelectPos(0, startRow, isShift, enableCtrlSelectMode, !1, null === (_d = null === (_c = this.options.select) || void 0 === _c ? void 0 : _c.makeSelectCellVisible) || void 0 === _d || _d, !0), this.stateManager.updateInteractionState(InteractionState.grabing), this.stateManager.updateSelectPos(endCol, endRow, isShift, enableCtrlSelectMode, !1, null === (_f = null === (_e = this.options.select) || void 0 === _e ? void 0 : _e.makeSelectCellVisible) || void 0 === _f || _f, !0), this.stateManager.select.selecting = !1;
57429
57357
  }
57430
57358
  dragSelectRow(rowIndex, isCtrl) {
57431
57359
  var _a, _b;
57432
57360
  const currentSelectRanges = this.stateManager.select.ranges,
57433
57361
  lastSelectRange = currentSelectRanges[currentSelectRanges.length - 1];
57434
- lastSelectRange && (lastSelectRange.end.row = rowIndex), this.stateManager.updateSelectPos(this.colCount - 1, rowIndex, !1, isCtrl, !1, null === (_b = null === (_a = this.options.select) || void 0 === _a ? void 0 : _a.makeSelectCellVisible) || void 0 === _b || _b, !0);
57362
+ lastSelectRange && (lastSelectRange.end.row = rowIndex), this.stateManager.updateSelectPos(this.colCount - 1, rowIndex, !1, isCtrl, !1, null === (_b = null === (_a = this.options.select) || void 0 === _a ? void 0 : _a.makeSelectCellVisible) || void 0 === _b || _b, !0), this.stateManager.select.selecting = !1;
57435
57363
  }
57436
57364
  get recordsCount() {
57437
57365
  var _a;
@@ -58353,6 +58281,18 @@
58353
58281
  }
58354
58282
  return !1;
58355
58283
  }
58284
+ updateCellContent(col, row) {
58285
+ this.scenegraph.updateCellContent(col, row);
58286
+ }
58287
+ updateCellContentRange(startCol, startRow, endCol, endRow) {
58288
+ for (let i = startCol; i <= endCol; i++) for (let j = startRow; j <= endRow; j++) this.scenegraph.updateCellContent(i, j);
58289
+ }
58290
+ updateCellContentRanges(ranges) {
58291
+ for (let i = 0; i < ranges.length; i++) {
58292
+ const range = ranges[i];
58293
+ this.updateCellContentRange(range.start.col, range.start.row, range.end.col, range.end.row);
58294
+ }
58295
+ }
58356
58296
  }
58357
58297
 
58358
58298
  const chartTypes = {};
@@ -59819,8 +59759,8 @@
59819
59759
  col === this.table.colCount - 1 ? referencePosition.rect.width = rect.width - 1 : referencePosition.rect.width = rect.width + 1, row === this.table.rowCount - 1 ? referencePosition.rect.height = rect.height - 1 : referencePosition.rect.height = rect.height + 1;
59820
59760
  const editor = this.table.getEditor(col, row);
59821
59761
  editor && setTimeout(() => {
59822
- var _a;
59823
- editor && this.editingEditor !== editor && (null === (_a = editor.prepareEdit) || void 0 === _a || _a.call(editor, {
59762
+ var _a, _b;
59763
+ editor && this.editingEditor !== editor && (null === (_b = (_a = editor).prepareEdit) || void 0 === _b || _b.call(_a, {
59824
59764
  referencePosition: referencePosition,
59825
59765
  container: this.table.getElement(),
59826
59766
  table: this.table,
@@ -59833,14 +59773,14 @@
59833
59773
  this.listenersId.push(doubleClickEventId, clickEventId, selectedChangedEventId);
59834
59774
  }
59835
59775
  startEditCell(col, row, value, editElement) {
59836
- var _a, _b, _c, _d, _e, _f, _g, _h, _j;
59776
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l;
59837
59777
  if (this.editingEditor) return;
59838
59778
  const editor = this.table.getEditor(col, row);
59839
59779
  if (editor) {
59840
- if (editElement && editor.setElement(editElement), this.table.internalProps.layoutMap.isSeriesNumber(col, row)) return;
59841
- if (null === (_b = null === (_a = this.table.internalProps.layoutMap) || void 0 === _a ? void 0 : _a.isAggregation) || void 0 === _b ? void 0 : _b.call(_a, col, row)) {
59842
- const isPivotTable = null === (_d = (_c = this.table).isPivotTable) || void 0 === _d ? void 0 : _d.call(_c),
59843
- updateAggregationOnEditCell = !!isPivotTable && (null === (_f = null === (_e = this.table.internalProps) || void 0 === _e ? void 0 : _e.dataConfig) || void 0 === _f ? void 0 : _f.updateAggregationOnEditCell);
59780
+ if (editElement && (null === (_b = (_a = editor).setElement) || void 0 === _b || _b.call(_a, editElement)), this.table.internalProps.layoutMap.isSeriesNumber(col, row)) return;
59781
+ if (null === (_d = null === (_c = this.table.internalProps.layoutMap) || void 0 === _c ? void 0 : _c.isAggregation) || void 0 === _d ? void 0 : _d.call(_c, col, row)) {
59782
+ const isPivotTable = null === (_f = (_e = this.table).isPivotTable) || void 0 === _f ? void 0 : _f.call(_e),
59783
+ updateAggregationOnEditCell = !!isPivotTable && (null === (_h = null === (_g = this.table.internalProps) || void 0 === _g ? void 0 : _g.dataConfig) || void 0 === _h ? void 0 : _h.updateAggregationOnEditCell);
59844
59784
  if (!isPivotTable || isPivotTable && updateAggregationOnEditCell) return;
59845
59785
  }
59846
59786
  const record = this.table.getCellRawRecord(col, row);
@@ -59859,9 +59799,9 @@
59859
59799
  height: rect.height
59860
59800
  }
59861
59801
  };
59862
- col === this.table.colCount - 1 ? referencePosition.rect.width = rect.width - 1 : referencePosition.rect.width = rect.width + 1, row === this.table.rowCount - 1 ? referencePosition.rect.height = rect.height - 1 : referencePosition.rect.height = rect.height + 1, editor.beginEditing, null === (_g = editor.beginEditing) || void 0 === _g || _g.call(editor, this.table.getElement(), referencePosition, dataValue), editor.bindSuccessCallback, null === (_h = editor.bindSuccessCallback) || void 0 === _h || _h.call(editor, () => {
59802
+ col === this.table.colCount - 1 ? referencePosition.rect.width = rect.width - 1 : referencePosition.rect.width = rect.width + 1, row === this.table.rowCount - 1 ? referencePosition.rect.height = rect.height - 1 : referencePosition.rect.height = rect.height + 1, editor.beginEditing, null === (_j = editor.beginEditing) || void 0 === _j || _j.call(editor, this.table.getElement(), referencePosition, dataValue), editor.bindSuccessCallback, null === (_k = editor.bindSuccessCallback) || void 0 === _k || _k.call(editor, () => {
59863
59803
  this.completeEdit();
59864
- }), null === (_j = editor.onStart) || void 0 === _j || _j.call(editor, {
59804
+ }), null === (_l = editor.onStart) || void 0 === _l || _l.call(editor, {
59865
59805
  value: dataValue,
59866
59806
  endEdit: () => {
59867
59807
  this.completeEdit();
@@ -59969,16 +59909,15 @@
59969
59909
  step((generator = generator.apply(thisArg, _arguments || [])).next());
59970
59910
  });
59971
59911
  };
59972
- function listTableChangeCellValue(col, row, value, workOnEditableCell, triggerEvent, table, silentChangeCellValuesEvent) {
59912
+ function listTableChangeCellValue(col, row, value, workOnEditableCell, triggerEvent, table) {
59973
59913
  if (workOnEditableCell && table.isHasEditorDefine(col, row) || !1 === workOnEditableCell) {
59974
- const recordShowIndex = table.getRecordShowIndexByCell(col, row),
59975
- recordIndex = recordShowIndex >= 0 ? table.dataSource.getIndexKey(recordShowIndex) : void 0,
59914
+ const recordIndex = table.getRecordShowIndexByCell(col, row),
59976
59915
  {
59977
59916
  field: field
59978
59917
  } = table.internalProps.layoutMap.getBody(col, row),
59979
59918
  beforeChangeValue = table.getCellRawValue(col, row),
59980
59919
  oldValue = table.getCellOriginValue(col, row);
59981
- table.isHeader(col, row) ? table.internalProps.layoutMap.updateColumnTitle(col, row, value) : table.dataSource.changeFieldValue(value, recordShowIndex, field, col, row, table);
59920
+ table.isHeader(col, row) ? table.internalProps.layoutMap.updateColumnTitle(col, row, value) : table.dataSource.changeFieldValue(value, recordIndex, field, col, row, table);
59982
59921
  const range = table.getCellRange(col, row),
59983
59922
  aggregators = table.internalProps.layoutMap.getAggregatorsByCell(col, row);
59984
59923
  if (aggregators) {
@@ -60001,24 +59940,16 @@
60001
59940
  table.scenegraph.updateRowHeight(row, newHeight - oldHeight);
60002
59941
  }
60003
59942
  const changedValue = table.getCellOriginValue(col, row);
60004
- if (oldValue !== changedValue && triggerEvent) {
60005
- const changeValue = {
60006
- col: col,
60007
- row: row,
60008
- recordIndex: recordIndex,
60009
- field: field,
60010
- rawValue: beforeChangeValue,
60011
- currentValue: oldValue,
60012
- changedValue: changedValue
60013
- };
60014
- table.fireListeners(TABLE_EVENT_TYPE.CHANGE_CELL_VALUE, changeValue), silentChangeCellValuesEvent || table.fireListeners(TABLE_EVENT_TYPE.CHANGE_CELL_VALUES, {
60015
- values: [changeValue]
60016
- });
60017
- }
60018
- table.scenegraph.updateNextFrame();
59943
+ oldValue !== changedValue && triggerEvent && table.fireListeners(TABLE_EVENT_TYPE.CHANGE_CELL_VALUE, {
59944
+ col: col,
59945
+ row: row,
59946
+ rawValue: beforeChangeValue,
59947
+ currentValue: oldValue,
59948
+ changedValue: changedValue
59949
+ }), table.scenegraph.updateNextFrame();
60019
59950
  }
60020
59951
  }
60021
- function listTableChangeCellValues(startCol, startRow, values, workOnEditableCell, triggerEvent, table, silentChangeCellValuesEvent) {
59952
+ function listTableChangeCellValues(startCol, startRow, values, workOnEditableCell, triggerEvent, table) {
60022
59953
  var _a, _b;
60023
59954
  return __awaiter(this, void 0, void 0, function* () {
60024
59955
  const changedCellResults = [];
@@ -60040,7 +59971,6 @@
60040
59971
  oldRowValues.push(oldValue);
60041
59972
  }
60042
59973
  }
60043
- const resultChangeValues = [];
60044
59974
  for (let i = 0; i < values.length && !(startRow + i > table.rowCount - 1); i++) {
60045
59975
  changedCellResults[i] = [], pasteRowEnd = startRow + i;
60046
59976
  const rowValues = values[i];
@@ -60064,34 +59994,25 @@
60064
59994
  if (isCanChange) {
60065
59995
  changedCellResults[i][j] = !0;
60066
59996
  const value = rowValues[j],
60067
- recordShowIndex = table.getRecordShowIndexByCell(startCol + j, startRow + i),
60068
- recordIndex = recordShowIndex >= 0 ? table.dataSource.getIndexKey(recordShowIndex) : void 0,
59997
+ recordIndex = table.getRecordShowIndexByCell(startCol + j, startRow + i),
60069
59998
  {
60070
59999
  field: field
60071
60000
  } = table.internalProps.layoutMap.getBody(startCol + j, startRow + i),
60072
60001
  beforeChangeValue = beforeChangeValues[i][j],
60073
60002
  oldValue = oldValues[i][j];
60074
- table.isHeader(startCol + j, startRow + i) ? table.internalProps.layoutMap.updateColumnTitle(startCol + j, startRow + i, value) : table.dataSource.changeFieldValue(value, recordShowIndex, field, startCol + j, startRow + i, table);
60003
+ table.isHeader(startCol + j, startRow + i) ? table.internalProps.layoutMap.updateColumnTitle(startCol + j, startRow + i, value) : table.dataSource.changeFieldValue(value, recordIndex, field, startCol + j, startRow + i, table);
60075
60004
  const changedValue = table.getCellOriginValue(startCol + j, startRow + i);
60076
- if (oldValue !== changedValue && triggerEvent) {
60077
- const changeValue = {
60078
- col: startCol + j,
60079
- row: startRow + i,
60080
- recordIndex: recordIndex,
60081
- field: field,
60082
- rawValue: beforeChangeValue,
60083
- currentValue: oldValue,
60084
- changedValue: changedValue
60085
- };
60086
- table.fireListeners(TABLE_EVENT_TYPE.CHANGE_CELL_VALUE, changeValue), resultChangeValues.push(changeValue);
60087
- }
60005
+ oldValue !== changedValue && triggerEvent && table.fireListeners(TABLE_EVENT_TYPE.CHANGE_CELL_VALUE, {
60006
+ col: startCol + j,
60007
+ row: startRow + i,
60008
+ rawValue: beforeChangeValue,
60009
+ currentValue: oldValue,
60010
+ changedValue: changedValue
60011
+ });
60088
60012
  } else changedCellResults[i][j] = !1;
60089
60013
  }
60090
60014
  pasteColEnd = Math.max(pasteColEnd, thisRowPasteColEnd);
60091
60015
  }
60092
- silentChangeCellValuesEvent || table.fireListeners(TABLE_EVENT_TYPE.CHANGE_CELL_VALUES, {
60093
- values: resultChangeValues
60094
- });
60095
60016
  const startRange = table.getCellRange(startCol, startRow),
60096
60017
  range = table.getCellRange(pasteColEnd, pasteRowEnd),
60097
60018
  aggregators = table.internalProps.layoutMap.getAggregatorsByCellRange(startRange.start.col, startRange.start.row, range.end.col, range.end.row);
@@ -60125,58 +60046,6 @@
60125
60046
  return table.scenegraph.updateNextFrame(), changedCellResults;
60126
60047
  });
60127
60048
  }
60128
- function listTableChangeCellValuesByIds(ranges, value, workOnEditableCell, triggerEvent, table, silentChangeCellValuesEvent) {
60129
- var _a, _b;
60130
- return __awaiter(this, void 0, void 0, function* () {
60131
- const resultChangeValues = [],
60132
- processed = new Set(),
60133
- nextValue = null != value ? value : "";
60134
- for (let i = 0; i < (null !== (_a = null == ranges ? void 0 : ranges.length) && void 0 !== _a ? _a : 0); i++) {
60135
- const range = ranges[i],
60136
- startCol = Math.min(range.start.col, range.end.col),
60137
- endCol = Math.max(range.start.col, range.end.col),
60138
- startRow = Math.min(range.start.row, range.end.row),
60139
- endRow = Math.max(range.start.row, range.end.row);
60140
- if (startCol > endCol || startRow > endRow) continue;
60141
- const values = [],
60142
- oldValues = [];
60143
- for (let row = startRow; row <= endRow; row++) {
60144
- const rowValues = [],
60145
- rowOldValues = [];
60146
- for (let col = startCol; col <= endCol; col++) rowValues.push(nextValue), rowOldValues.push(table.getCellOriginValue(col, row));
60147
- values.push(rowValues), oldValues.push(rowOldValues);
60148
- }
60149
- const changedCellResults = yield listTableChangeCellValues(startCol, startRow, values, workOnEditableCell, triggerEvent, table, !0);
60150
- for (let r = 0; r < values.length; r++) for (let c = 0; c < values[r].length; c++) {
60151
- const col = startCol + c,
60152
- row = startRow + r,
60153
- key = `${col},${row}`;
60154
- if (processed.has(key)) continue;
60155
- if (processed.add(key), !triggerEvent || !(null === (_b = null == changedCellResults ? void 0 : changedCellResults[r]) || void 0 === _b ? void 0 : _b[c])) continue;
60156
- const oldValue = oldValues[r][c],
60157
- changedValue = table.getCellOriginValue(col, row);
60158
- if (oldValue === changedValue) continue;
60159
- const recordShowIndex = table.getRecordShowIndexByCell(col, row),
60160
- recordIndex = recordShowIndex >= 0 ? table.dataSource.getIndexKey(recordShowIndex) : void 0,
60161
- {
60162
- field: field
60163
- } = table.internalProps.layoutMap.getBody(col, row);
60164
- resultChangeValues.push({
60165
- col: col,
60166
- row: row,
60167
- recordIndex: recordIndex,
60168
- field: field,
60169
- rawValue: oldValue,
60170
- currentValue: oldValue,
60171
- changedValue: changedValue
60172
- });
60173
- }
60174
- }
60175
- !silentChangeCellValuesEvent && triggerEvent && table.fireListeners(TABLE_EVENT_TYPE.CHANGE_CELL_VALUES, {
60176
- values: resultChangeValues
60177
- });
60178
- });
60179
- }
60180
60049
  function getCellUpdateType(col, row, table, oldCellUpdateType) {
60181
60050
  if ("group" === oldCellUpdateType) return oldCellUpdateType;
60182
60051
  if ("sort" === oldCellUpdateType && !table.internalProps.groupBy) return oldCellUpdateType;
@@ -60194,16 +60063,13 @@
60194
60063
  }), table.dataSource.sort(sortState));
60195
60064
  }
60196
60065
  function listTableAddRecord(record, recordIndex, table) {
60197
- var _a, _b, _c, _d, _e, _f;
60066
+ var _a, _b, _c, _d;
60198
60067
  try {
60199
60068
  if (!record) return !1;
60200
- if (table.internalProps.groupBy) null === (_b = (_a = table.dataSource).addRecordsForGroup) || void 0 === _b || _b.call(_a, [record], recordIndex), table.refreshRowColCount(), table.internalProps.layoutMap.clearCellRangeMap(), table.sortState && sortRecords(table), table.scenegraph.clearCells(), table.scenegraph.createSceneGraph();else if ("tree" === table.dataSource.rowHierarchyType) null === (_d = (_c = table.dataSource).addRecordsForTree) || void 0 === _d || _d.call(_c, [record], recordIndex), adjustCheckBoxStateMapWithAddRecordIndex(table, recordIndex, 1), table.refreshRowColCount(), table.internalProps.layoutMap.clearCellRangeMap(), table.sortState && sortRecords(table), table.scenegraph.clearCells(), table.scenegraph.createSceneGraph();else if (table.sortState) {
60201
- !!(null === (_e = table.options) || void 0 === _e ? void 0 : _e.syncRecordOperationsToSourceRecords) ? table.dataSource.addRecord(record, table.dataSource.records.length, !0) : table.dataSource.addRecordForSorted(record), table.stateManager.checkedState.clear(), sortRecords(table), table.refreshRowColCount(), table.scenegraph.clearCells(), table.scenegraph.createSceneGraph();
60202
- } else {
60069
+ if (table.internalProps.groupBy) null === (_b = (_a = table.dataSource).addRecordsForGroup) || void 0 === _b || _b.call(_a, [record], recordIndex), table.refreshRowColCount(), table.internalProps.layoutMap.clearCellRangeMap(), table.sortState && sortRecords(table), table.scenegraph.clearCells(), table.scenegraph.createSceneGraph();else if ("tree" === table.dataSource.rowHierarchyType) null === (_d = (_c = table.dataSource).addRecordsForTree) || void 0 === _d || _d.call(_c, [record], recordIndex), adjustCheckBoxStateMapWithAddRecordIndex(table, recordIndex, 1), table.refreshRowColCount(), table.internalProps.layoutMap.clearCellRangeMap(), table.sortState && sortRecords(table), table.scenegraph.clearCells(), table.scenegraph.createSceneGraph();else if (table.sortState) table.dataSource.addRecordForSorted(record), table.stateManager.checkedState.clear(), sortRecords(table), table.refreshRowColCount(), table.scenegraph.clearCells(), table.scenegraph.createSceneGraph();else {
60203
60070
  (void 0 === recordIndex || recordIndex > table.dataSource.sourceLength) && (recordIndex = table.dataSource.sourceLength);
60204
- const headerCount = table.transpose ? table.rowHeaderLevelCount : table.columnHeaderLevelCount,
60205
- syncToOriginalRecords = !!(null === (_f = table.options) || void 0 === _f ? void 0 : _f.syncRecordOperationsToSourceRecords);
60206
- if (table.dataSource.addRecord(record, recordIndex, syncToOriginalRecords), adjustCheckBoxStateMapWithAddRecordIndex(table, recordIndex, 1), syncToOriginalRecords) return table.refreshRowColCount(), table.internalProps.layoutMap.clearCellRangeMap(), table.scenegraph.clearCells(), table.scenegraph.createSceneGraph(), !0;
60071
+ const headerCount = table.transpose ? table.rowHeaderLevelCount : table.columnHeaderLevelCount;
60072
+ table.dataSource.addRecord(record, recordIndex), adjustCheckBoxStateMapWithAddRecordIndex(table, recordIndex, 1);
60207
60073
  const oldRowCount = table.rowCount;
60208
60074
  if (table.refreshRowColCount(), 0 === table.scenegraph.proxy.totalActualBodyRowCount) return table.scenegraph.clearCells(), table.scenegraph.createSceneGraph(), !0;
60209
60075
  const newRowCount = table.transpose ? table.colCount : table.rowCount;
@@ -60272,16 +60138,13 @@
60272
60138
  }
60273
60139
  }
60274
60140
  function listTableAddRecords(records, recordIndex, table) {
60275
- var _a, _b, _c, _d, _e, _f;
60141
+ var _a, _b, _c, _d;
60276
60142
  try {
60277
60143
  if (!records || 0 === records.length) return !1;
60278
- if (table.internalProps.groupBy) null === (_b = (_a = table.dataSource).addRecordsForGroup) || void 0 === _b || _b.call(_a, records, recordIndex), table.refreshRowColCount(), table.internalProps.layoutMap.clearCellRangeMap(), table.sortState && sortRecords(table), table.scenegraph.clearCells(), table.scenegraph.createSceneGraph();else if ("tree" === table.dataSource.rowHierarchyType) null === (_d = (_c = table.dataSource).addRecordsForTree) || void 0 === _d || _d.call(_c, records, recordIndex), adjustCheckBoxStateMapWithAddRecordIndex(table, recordIndex, records.length), table.refreshRowColCount(), table.internalProps.layoutMap.clearCellRangeMap(), table.sortState && sortRecords(table), table.scenegraph.clearCells(), table.scenegraph.createSceneGraph();else if (table.sortState) {
60279
- !!(null === (_e = table.options) || void 0 === _e ? void 0 : _e.syncRecordOperationsToSourceRecords) ? table.dataSource.addRecords(records, table.dataSource.records.length, !0) : table.dataSource.addRecordsForSorted(records), sortRecords(table), table.refreshRowColCount(), table.scenegraph.clearCells(), table.scenegraph.createSceneGraph();
60280
- } else {
60144
+ if (table.internalProps.groupBy) null === (_b = (_a = table.dataSource).addRecordsForGroup) || void 0 === _b || _b.call(_a, records, recordIndex), table.refreshRowColCount(), table.internalProps.layoutMap.clearCellRangeMap(), table.sortState && sortRecords(table), table.scenegraph.clearCells(), table.scenegraph.createSceneGraph();else if ("tree" === table.dataSource.rowHierarchyType) null === (_d = (_c = table.dataSource).addRecordsForTree) || void 0 === _d || _d.call(_c, records, recordIndex), adjustCheckBoxStateMapWithAddRecordIndex(table, recordIndex, records.length), table.refreshRowColCount(), table.internalProps.layoutMap.clearCellRangeMap(), table.sortState && sortRecords(table), table.scenegraph.clearCells(), table.scenegraph.createSceneGraph();else if (table.sortState) table.dataSource.addRecordsForSorted(records), sortRecords(table), table.refreshRowColCount(), table.scenegraph.clearCells(), table.scenegraph.createSceneGraph();else {
60281
60145
  void 0 === recordIndex || recordIndex > table.dataSource.sourceLength ? recordIndex = table.dataSource.sourceLength : recordIndex < 0 && (recordIndex = 0);
60282
- const headerCount = table.transpose ? table.rowHeaderLevelCount : table.columnHeaderLevelCount,
60283
- syncToOriginalRecords = !!(null === (_f = table.options) || void 0 === _f ? void 0 : _f.syncRecordOperationsToSourceRecords);
60284
- if (table.dataSource.addRecords(records, recordIndex, syncToOriginalRecords), adjustCheckBoxStateMapWithAddRecordIndex(table, recordIndex, records.length), syncToOriginalRecords) return table.refreshRowColCount(), table.internalProps.layoutMap.clearCellRangeMap(), table.scenegraph.clearCells(), table.scenegraph.createSceneGraph(), !0;
60146
+ const headerCount = table.transpose ? table.rowHeaderLevelCount : table.columnHeaderLevelCount;
60147
+ table.dataSource.addRecords(records, recordIndex), adjustCheckBoxStateMapWithAddRecordIndex(table, recordIndex, records.length);
60285
60148
  const oldRowCount = table.transpose ? table.colCount : table.rowCount;
60286
60149
  if (table.refreshRowColCount(), 0 === table.scenegraph.proxy.totalActualBodyRowCount) return table.scenegraph.clearCells(), table.scenegraph.createSceneGraph(), !0;
60287
60150
  const newRowCount = table.transpose ? table.colCount : table.rowCount;
@@ -60350,20 +60213,16 @@
60350
60213
  }
60351
60214
  }
60352
60215
  function listTableDeleteRecords(recordIndexs, table) {
60353
- var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
60216
+ var _a, _b, _c, _d, _e, _f, _g, _h;
60354
60217
  if ((null == recordIndexs ? void 0 : recordIndexs.length) > 0) if (table.internalProps.groupBy) null === (_b = (_a = table.dataSource).deleteRecordsForGroup) || void 0 === _b || _b.call(_a, recordIndexs), table.refreshRowColCount(), table.internalProps.layoutMap.clearCellRangeMap(), table.sortState && sortRecords(table), table.scenegraph.clearCells(), table.scenegraph.createSceneGraph();else if ("tree" === table.dataSource.rowHierarchyType) {
60355
60218
  const deletedRecordIndexs = null === (_d = (_c = table.dataSource).deleteRecordsForTree) || void 0 === _d ? void 0 : _d.call(_c, recordIndexs);
60356
60219
  if (0 === deletedRecordIndexs.length) return;
60357
60220
  for (let index = 0; index < deletedRecordIndexs.length; index++) adjustCheckBoxStateMapWithDeleteRecordIndex(table, deletedRecordIndexs[index], 1);
60358
60221
  table.refreshRowColCount(), table.internalProps.layoutMap.clearCellRangeMap(), table.sortState && sortRecords(table), table.scenegraph.clearCells(), table.scenegraph.createSceneGraph();
60359
- } else if (table.sortState) {
60360
- !!(null === (_e = table.options) || void 0 === _e ? void 0 : _e.syncRecordOperationsToSourceRecords) ? table.dataSource.deleteRecords(recordIndexs, !0) : table.dataSource.deleteRecordsForSorted(recordIndexs), sortRecords(table), table.refreshRowColCount(), table.scenegraph.clearCells(), table.scenegraph.createSceneGraph();
60361
- } else {
60362
- const syncToOriginalRecords = !!(null === (_f = table.options) || void 0 === _f ? void 0 : _f.syncRecordOperationsToSourceRecords),
60363
- deletedRecordIndexs = table.dataSource.deleteRecords(recordIndexs, syncToOriginalRecords);
60222
+ } else if (table.sortState) table.dataSource.deleteRecordsForSorted(recordIndexs), sortRecords(table), table.refreshRowColCount(), table.scenegraph.clearCells(), table.scenegraph.createSceneGraph();else {
60223
+ const deletedRecordIndexs = table.dataSource.deleteRecords(recordIndexs);
60364
60224
  if (0 === deletedRecordIndexs.length) return;
60365
60225
  for (let index = 0; index < deletedRecordIndexs.length; index++) adjustCheckBoxStateMapWithDeleteRecordIndex(table, deletedRecordIndexs[index], 1);
60366
- if (syncToOriginalRecords) return table.refreshRowColCount(), table.internalProps.layoutMap.clearCellRangeMap(), table.scenegraph.clearCells(), void table.scenegraph.createSceneGraph();
60367
60226
  const oldRowCount = table.transpose ? table.colCount : table.rowCount;
60368
60227
  table.refreshRowColCount();
60369
60228
  const newRowCount = table.transpose ? table.colCount : table.rowCount,
@@ -60401,7 +60260,7 @@
60401
60260
  col: 0,
60402
60261
  row: row
60403
60262
  });
60404
- null === (_g = table.reactCustomLayout) || void 0 === _g || _g.clearCache(), table.transpose ? table.scenegraph.updateCol(delRows, [], updateRows) : table.scenegraph.updateRow(delRows, [], updateRows), null === (_h = table.reactCustomLayout) || void 0 === _h || _h.updateAllCustomCell();
60263
+ null === (_e = table.reactCustomLayout) || void 0 === _e || _e.clearCache(), table.transpose ? table.scenegraph.updateCol(delRows, [], updateRows) : table.scenegraph.updateRow(delRows, [], updateRows), null === (_f = table.reactCustomLayout) || void 0 === _f || _f.updateAllCustomCell();
60405
60264
  }
60406
60265
  } else {
60407
60266
  const delRows = [],
@@ -60433,19 +60292,15 @@
60433
60292
  col: 0,
60434
60293
  row: row
60435
60294
  });
60436
- null === (_j = table.reactCustomLayout) || void 0 === _j || _j.clearCache(), table.transpose ? table.scenegraph.updateCol(delRows, [], updateRows) : table.scenegraph.updateRow(delRows, [], updateRows), null === (_k = table.reactCustomLayout) || void 0 === _k || _k.updateAllCustomCell();
60295
+ null === (_g = table.reactCustomLayout) || void 0 === _g || _g.clearCache(), table.transpose ? table.scenegraph.updateCol(delRows, [], updateRows) : table.scenegraph.updateRow(delRows, [], updateRows), null === (_h = table.reactCustomLayout) || void 0 === _h || _h.updateAllCustomCell();
60437
60296
  }
60438
60297
  }
60439
60298
  }
60440
60299
  function listTableUpdateRecords(records, recordIndexs, table) {
60441
- var _a, _b, _c, _d, _e, _f;
60442
- if ((null == recordIndexs ? void 0 : recordIndexs.length) > 0) if (table.internalProps.groupBy) null === (_b = (_a = table.dataSource).updateRecordsForGroup) || void 0 === _b || _b.call(_a, records, recordIndexs), table.refreshRowColCount(), table.internalProps.layoutMap.clearCellRangeMap(), table.sortState && sortRecords(table), table.scenegraph.clearCells(), table.scenegraph.createSceneGraph();else if ("tree" === table.dataSource.rowHierarchyType) null === (_d = (_c = table.dataSource).updateRecordsForTree) || void 0 === _d || _d.call(_c, records, recordIndexs), table.refreshRowColCount(), table.internalProps.layoutMap.clearCellRangeMap(), table.sortState && sortRecords(table), table.scenegraph.clearCells(), table.scenegraph.createSceneGraph();else if (table.sortState) {
60443
- !!(null === (_e = table.options) || void 0 === _e ? void 0 : _e.syncRecordOperationsToSourceRecords) ? table.dataSource.updateRecords(records, recordIndexs, !0) : table.dataSource.updateRecordsForSorted(records, recordIndexs), sortRecords(table), table.refreshRowColCount(), table.scenegraph.clearCells(), table.scenegraph.createSceneGraph();
60444
- } else {
60445
- const syncToOriginalRecords = !!(null === (_f = table.options) || void 0 === _f ? void 0 : _f.syncRecordOperationsToSourceRecords),
60446
- updateRecordIndexs = table.dataSource.updateRecords(records, recordIndexs, syncToOriginalRecords);
60300
+ var _a, _b, _c, _d;
60301
+ if ((null == recordIndexs ? void 0 : recordIndexs.length) > 0) if (table.internalProps.groupBy) null === (_b = (_a = table.dataSource).updateRecordsForGroup) || void 0 === _b || _b.call(_a, records, recordIndexs), table.refreshRowColCount(), table.internalProps.layoutMap.clearCellRangeMap(), table.sortState && sortRecords(table), table.scenegraph.clearCells(), table.scenegraph.createSceneGraph();else if ("tree" === table.dataSource.rowHierarchyType) null === (_d = (_c = table.dataSource).updateRecordsForTree) || void 0 === _d || _d.call(_c, records, recordIndexs), table.refreshRowColCount(), table.internalProps.layoutMap.clearCellRangeMap(), table.sortState && sortRecords(table), table.scenegraph.clearCells(), table.scenegraph.createSceneGraph();else if (table.sortState) table.dataSource.updateRecordsForSorted(records, recordIndexs), sortRecords(table), table.refreshRowColCount(), table.scenegraph.clearCells(), table.scenegraph.createSceneGraph();else {
60302
+ const updateRecordIndexs = table.dataSource.updateRecords(records, recordIndexs);
60447
60303
  if (0 === updateRecordIndexs.length) return;
60448
- if (syncToOriginalRecords) return table.refreshRowColCount(), table.internalProps.layoutMap.clearCellRangeMap(), table.scenegraph.clearCells(), void table.scenegraph.createSceneGraph();
60449
60304
  const recordIndexsMinToMax = updateRecordIndexs.map(index => table.getBodyRowIndexByRecordIndex(index)).sort((a, b) => a - b);
60450
60305
  if (table.pagination) {
60451
60306
  const {
@@ -61211,8 +61066,8 @@
61211
61066
  updateFilterRules(filterRules, options = {
61212
61067
  clearRowHeightCache: !0
61213
61068
  }) {
61214
- var _a, _b, _c;
61215
- this.scenegraph.clearCells(), null === (_b = (_a = this.dataSource).clearForceVisibleRecords) || void 0 === _b || _b.call(_a), this.sortState ? (this.dataSource.updateFilterRulesForSorted(filterRules), sortRecords(this)) : this.dataSource.updateFilterRules(filterRules, null == options ? void 0 : options.onFilterRecordsEnd), this.refreshRowColCount(), this.stateManager.initCheckedState(this.records), this.scenegraph.createSceneGraph(!(null == options ? void 0 : options.clearRowHeightCache)), null === (_c = this.internalProps.emptyTip) || void 0 === _c || _c.resetVisible(), this.resize();
61069
+ var _a;
61070
+ this.scenegraph.clearCells(), this.sortState ? (this.dataSource.updateFilterRulesForSorted(filterRules), sortRecords(this)) : this.dataSource.updateFilterRules(filterRules, null == options ? void 0 : options.onFilterRecordsEnd), this.refreshRowColCount(), this.stateManager.initCheckedState(this.records), this.scenegraph.createSceneGraph(!(null == options ? void 0 : options.clearRowHeightCache)), null === (_a = this.internalProps.emptyTip) || void 0 === _a || _a.resetVisible(), this.resize();
61216
61071
  }
61217
61072
  getFilteredRecords() {
61218
61073
  return this.dataSource.records;
@@ -61354,165 +61209,43 @@
61354
61209
  }
61355
61210
  return isValid$1(editorDefine);
61356
61211
  }
61357
- changeCellValue(col, row, value, workOnEditableCell = !1, triggerEvent = !0, silentChangeCellValuesEvent) {
61358
- return listTableChangeCellValue(col, row, value, workOnEditableCell, triggerEvent, this, silentChangeCellValuesEvent);
61359
- }
61360
- changeCellValues(startCol, startRow, values, workOnEditableCell = !1, triggerEvent = !0, silentChangeCellValuesEvent) {
61361
- return listTableChangeCellValues(startCol, startRow, values, workOnEditableCell, triggerEvent, this, silentChangeCellValuesEvent);
61362
- }
61363
- changeCellValuesByIds(ranges, value, workOnEditableCell = !1, triggerEvent = !0, silentChangeCellValuesEvent) {
61364
- return listTableChangeCellValuesByIds(ranges, value, workOnEditableCell, triggerEvent, this, silentChangeCellValuesEvent);
61365
- }
61366
- changeSourceCellValue(recordIndex, field, value) {
61367
- const tableIndex = this.getTableIndexByRecordIndex(recordIndex),
61368
- cellAddr = this.getCellAddrByFieldRecord(field, recordIndex);
61369
- if (tableIndex < 0 || cellAddr.col < 0 || cellAddr.row < 0) return;
61370
- this.dataSource.changeFieldValue(value, tableIndex, field, cellAddr.col, cellAddr.row, this);
61371
- const beforeChangeValue = this.getCellRawValue(cellAddr.col, cellAddr.row),
61372
- oldValue = this.getCellOriginValue(cellAddr.col, cellAddr.row),
61373
- changedValue = this.getCellOriginValue(cellAddr.col, cellAddr.row);
61374
- if (oldValue !== changedValue) {
61375
- const changeValue = {
61376
- col: cellAddr.col,
61377
- row: cellAddr.row,
61378
- recordIndex: recordIndex,
61379
- field: field,
61380
- rawValue: beforeChangeValue,
61381
- currentValue: oldValue,
61382
- changedValue: changedValue
61383
- };
61384
- this.fireListeners(TABLE_EVENT_TYPE.CHANGE_CELL_VALUE, changeValue), this.fireListeners(TABLE_EVENT_TYPE.CHANGE_CELL_VALUES, {
61385
- values: [changeValue]
61386
- });
61387
- }
61388
- }
61389
- changeCellValueByRecord(recordIndex, field, value, options) {
61390
- var _a, _b, _c, _d, _e;
61391
- const triggerEvent = null === (_a = null == options ? void 0 : options.triggerEvent) || void 0 === _a || _a,
61392
- silentChangeCellValuesEvent = null == options ? void 0 : options.silentChangeCellValuesEvent,
61393
- autoRefresh = null === (_b = null == options ? void 0 : options.autoRefresh) || void 0 === _b || _b,
61394
- records = null === (_c = this.dataSource.dataSourceObj) || void 0 === _c ? void 0 : _c.records;
61395
- let record, oldValue;
61396
- if (!Array.isArray(records) || "string" != typeof field && "number" != typeof field || (record = Array.isArray(recordIndex) ? getValueFromDeepArray(records, recordIndex) : records[recordIndex], oldValue = null == record ? void 0 : record[field]), this.dataSource.changeFieldValueByRecordIndex(value, recordIndex, field, this), !triggerEvent) return;
61397
- const changedValue = !record || "string" != typeof field && "number" != typeof field ? value : null == record ? void 0 : record[field];
61398
- if (oldValue !== changedValue) {
61399
- const cellAddr = this.getCellAddrByFieldRecord(field, recordIndex),
61400
- changeValue = {
61401
- col: null !== (_d = null == cellAddr ? void 0 : cellAddr.col) && void 0 !== _d ? _d : -1,
61402
- row: null !== (_e = null == cellAddr ? void 0 : cellAddr.row) && void 0 !== _e ? _e : -1,
61403
- recordIndex: recordIndex,
61404
- field: field,
61405
- rawValue: oldValue,
61406
- currentValue: oldValue,
61407
- changedValue: changedValue
61408
- };
61409
- this.fireListeners(TABLE_EVENT_TYPE.CHANGE_CELL_VALUE, changeValue), silentChangeCellValuesEvent || this.fireListeners(TABLE_EVENT_TYPE.CHANGE_CELL_VALUES, {
61410
- values: [changeValue]
61411
- });
61412
- }
61413
- autoRefresh && this.refreshAfterSourceChange();
61414
- }
61415
- changeCellValueBySource(recordIndex, field, value, triggerEvent = !0, silentChangeCellValuesEvent) {
61416
- return this.changeCellValueByRecord(recordIndex, field, value, {
61417
- triggerEvent: triggerEvent,
61418
- silentChangeCellValuesEvent: silentChangeCellValuesEvent,
61419
- autoRefresh: !0
61420
- });
61421
- }
61422
- changeCellValuesByRecords(changeValues, options) {
61423
- var _a, _b, _c, _d, _e, _f, _g;
61424
- const triggerEvent = null === (_a = null == options ? void 0 : options.triggerEvent) || void 0 === _a || _a,
61425
- silentChangeCellValuesEvent = null == options ? void 0 : options.silentChangeCellValuesEvent,
61426
- autoRefresh = null === (_b = null == options ? void 0 : options.autoRefresh) || void 0 === _b || _b,
61427
- resultChangeValues = [];
61428
- for (let i = 0; i < changeValues.length; i++) {
61429
- const {
61430
- recordIndex: recordIndex,
61431
- field: field,
61432
- value: value
61433
- } = changeValues[i],
61434
- records = null === (_c = this.dataSource.dataSourceObj) || void 0 === _c ? void 0 : _c.records;
61435
- let record, oldValue;
61436
- if (!Array.isArray(records) || "string" != typeof field && "number" != typeof field || (record = Array.isArray(recordIndex) ? getValueFromDeepArray(records, recordIndex) : records[recordIndex], oldValue = null == record ? void 0 : record[field]), this.dataSource.changeFieldValueByRecordIndex(value, recordIndex, field, this), triggerEvent) {
61437
- const changedValue = !record || "string" != typeof field && "number" != typeof field ? value : null == record ? void 0 : record[field];
61438
- if (oldValue !== changedValue) {
61439
- const changeValue = {
61440
- col: null !== (_e = null === (_d = this.getCellAddrByFieldRecord(field, recordIndex)) || void 0 === _d ? void 0 : _d.col) && void 0 !== _e ? _e : -1,
61441
- row: null !== (_g = null === (_f = this.getCellAddrByFieldRecord(field, recordIndex)) || void 0 === _f ? void 0 : _f.row) && void 0 !== _g ? _g : -1,
61442
- recordIndex: recordIndex,
61443
- field: field,
61444
- rawValue: oldValue,
61445
- currentValue: oldValue,
61446
- changedValue: changedValue
61447
- };
61448
- this.fireListeners(TABLE_EVENT_TYPE.CHANGE_CELL_VALUE, changeValue), resultChangeValues.push(changeValue);
61449
- }
61450
- }
61451
- }
61452
- !silentChangeCellValuesEvent && resultChangeValues.length && triggerEvent && this.fireListeners(TABLE_EVENT_TYPE.CHANGE_CELL_VALUES, {
61453
- values: resultChangeValues
61454
- }), autoRefresh && this.refreshAfterSourceChange();
61455
- }
61456
- changeCellValuesBySource(changeValues, triggerEvent = !0, silentChangeCellValuesEvent) {
61457
- return this.changeCellValuesByRecords(changeValues, {
61458
- triggerEvent: triggerEvent,
61459
- silentChangeCellValuesEvent: silentChangeCellValuesEvent,
61460
- autoRefresh: !0
61461
- });
61212
+ changeCellValue(col, row, value, workOnEditableCell = !1, triggerEvent = !0) {
61213
+ return listTableChangeCellValue(col, row, value, workOnEditableCell, triggerEvent, this);
61462
61214
  }
61463
- refreshAfterSourceChange(options) {
61464
- var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
61465
- const reapplyFilter = null === (_a = null == options ? void 0 : options.reapplyFilter) || void 0 === _a || _a,
61466
- reapplySort = null === (_b = null == options ? void 0 : options.reapplySort) || void 0 === _b || _b,
61467
- clearRowHeightCache = null === (_c = null == options ? void 0 : options.clearRowHeightCache) || void 0 === _c || _c;
61468
- this.scenegraph.clearCells(), this.sortState && reapplySort && (null === (_e = (_d = this.dataSource).clearSortedIndexMap) || void 0 === _e || _e.call(_d), null === (_g = null === (_f = this.dataSource.sortedIndexMap) || void 0 === _f ? void 0 : _f.clear) || void 0 === _g || _g.call(_f)), reapplyFilter ? this.sortState && reapplySort ? (this.dataSource.updateFilterRulesForSorted(null === (_h = this.dataSource.dataConfig) || void 0 === _h ? void 0 : _h.filterRules), sortRecords(this)) : this.dataSource.updateFilterRules(null === (_j = this.dataSource.dataConfig) || void 0 === _j ? void 0 : _j.filterRules) : this.sortState && reapplySort && sortRecords(this);
61469
- const traverseColumns = columns => {
61470
- var _a, _b, _c, _d;
61471
- for (let i = 0; i < (null !== (_a = null == columns ? void 0 : columns.length) && void 0 !== _a ? _a : 0); i++) {
61472
- const column = columns[i],
61473
- aggregators = null == column ? void 0 : column.vtable_aggregator;
61474
- if (aggregators) if (Array.isArray(aggregators)) for (let j = 0; j < aggregators.length; j++) null === (_c = null === (_b = aggregators[j]) || void 0 === _b ? void 0 : _b.recalculate) || void 0 === _c || _c.call(_b);else null === (_d = null == aggregators ? void 0 : aggregators.recalculate) || void 0 === _d || _d.call(aggregators);
61475
- (null == column ? void 0 : column.columns) && traverseColumns(column.columns);
61476
- }
61477
- };
61478
- traverseColumns(this.internalProps.columns), this.refreshRowColCount(), this.internalProps.layoutMap.clearCellRangeMap(), this.internalProps.useOneRowHeightFillAll = !1, this.stateManager.initCheckedState(this.records), this.scenegraph.createSceneGraph(!clearRowHeightCache), null === (_k = this.internalProps.emptyTip) || void 0 === _k || _k.resetVisible(), this.resize();
61215
+ changeCellValues(startCol, startRow, values, workOnEditableCell = !1, triggerEvent = !0) {
61216
+ return listTableChangeCellValues(startCol, startRow, values, workOnEditableCell, triggerEvent, this);
61479
61217
  }
61480
- addRecord(record, recordIndex, triggerEvent = !0) {
61218
+ addRecord(record, recordIndex) {
61481
61219
  var _a;
61482
61220
  const success = listTableAddRecord(record, recordIndex, this);
61483
- adjustHeightResizedRowMapWithAddRecordIndex(this, recordIndex, [record]), null === (_a = this.internalProps.emptyTip) || void 0 === _a || _a.resetVisible(), triggerEvent && success && this.fireListeners(TABLE_EVENT_TYPE.ADD_RECORD, {
61221
+ adjustHeightResizedRowMapWithAddRecordIndex(this, recordIndex, [record]), null === (_a = this.internalProps.emptyTip) || void 0 === _a || _a.resetVisible(), success && this.fireListeners(TABLE_EVENT_TYPE.ADD_RECORD, {
61484
61222
  records: [record],
61485
61223
  recordIndex: recordIndex,
61486
61224
  recordCount: 1
61487
61225
  });
61488
61226
  }
61489
- addRecords(records, recordIndex, triggerEvent = !0) {
61227
+ addRecords(records, recordIndex) {
61490
61228
  var _a;
61491
61229
  const success = listTableAddRecords(records, recordIndex, this);
61492
- "number" == typeof recordIndex && adjustHeightResizedRowMapWithAddRecordIndex(this, recordIndex, records), null === (_a = this.internalProps.emptyTip) || void 0 === _a || _a.resetVisible(), triggerEvent && success && this.fireListeners(TABLE_EVENT_TYPE.ADD_RECORD, {
61230
+ "number" == typeof recordIndex && adjustHeightResizedRowMapWithAddRecordIndex(this, recordIndex, records), null === (_a = this.internalProps.emptyTip) || void 0 === _a || _a.resetVisible(), success && this.fireListeners(TABLE_EVENT_TYPE.ADD_RECORD, {
61493
61231
  records: records,
61494
61232
  recordIndex: recordIndex,
61495
61233
  recordCount: records.length
61496
61234
  });
61497
61235
  }
61498
- deleteRecords(recordIndexs, triggerEvent = !0) {
61236
+ deleteRecords(recordIndexs) {
61499
61237
  var _a;
61500
- const deletedRecords = [];
61501
- (null == recordIndexs ? void 0 : recordIndexs.length) > 0 && recordIndexs.forEach(index => {
61502
- let record = null;
61503
- record = "number" == typeof index ? this.dataSource.get(index) : [], deletedRecords.push(record);
61504
- }), listTableDeleteRecords(recordIndexs, this), adjustHeightResizedRowMapWithDeleteRecordIndex(this, recordIndexs), null === (_a = this.internalProps.emptyTip) || void 0 === _a || _a.resetVisible();
61238
+ listTableDeleteRecords(recordIndexs, this), adjustHeightResizedRowMapWithDeleteRecordIndex(this, recordIndexs), null === (_a = this.internalProps.emptyTip) || void 0 === _a || _a.resetVisible();
61505
61239
  const rowIndexs = [];
61506
61240
  for (let i = 0; i < recordIndexs.length; i++) rowIndexs.push(this.getBodyRowIndexByRecordIndex(recordIndexs[i]) + this.columnHeaderLevelCount);
61507
- triggerEvent && this.fireListeners(TABLE_EVENT_TYPE.DELETE_RECORD, {
61241
+ this.fireListeners(TABLE_EVENT_TYPE.DELETE_RECORD, {
61508
61242
  recordIndexs: recordIndexs,
61509
- records: deletedRecords,
61510
61243
  rowIndexs: rowIndexs,
61511
61244
  deletedCount: (Array.isArray(recordIndexs[0]), recordIndexs.length)
61512
61245
  });
61513
61246
  }
61514
- updateRecords(records, recordIndexs, triggerEvent = !0) {
61515
- listTableUpdateRecords(records, recordIndexs, this), triggerEvent && this.fireListeners(TABLE_EVENT_TYPE.UPDATE_RECORD, {
61247
+ updateRecords(records, recordIndexs) {
61248
+ listTableUpdateRecords(records, recordIndexs, this), this.fireListeners(TABLE_EVENT_TYPE.UPDATE_RECORD, {
61516
61249
  records: records,
61517
61250
  recordIndexs: recordIndexs,
61518
61251
  updateCount: records.length