@visactor/vtable 0.12.3-alpha.1 → 0.13.0-alpha.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/vtable.js CHANGED
@@ -46613,11 +46613,13 @@
46613
46613
  computeRowsHeight(this.table, 0, this.table.rowCount - 1, true, true);
46614
46614
  }
46615
46615
  resize() {
46616
- if (this.table.widthMode === 'adaptive' || this.table.autoFillWidth) {
46617
- this.recalculateColWidths();
46618
- }
46619
- if (this.table.heightMode === 'adaptive' || this.table.autoFillHeight) {
46620
- this.recalculateRowHeights();
46616
+ if (this.table.internalProps._widthResizedColMap.size === 0) {
46617
+ if (this.table.widthMode === 'adaptive' || this.table.autoFillWidth) {
46618
+ this.recalculateColWidths();
46619
+ }
46620
+ if (this.table.heightMode === 'adaptive' || this.table.autoFillHeight) {
46621
+ this.recalculateRowHeights();
46622
+ }
46621
46623
  }
46622
46624
  this.dealWidthMode();
46623
46625
  this.dealHeightMode();
@@ -47554,7 +47556,7 @@
47554
47556
  else if (interactionState === InteractionState.default) {
47555
47557
  const currentRange = state.select.ranges[state.select.ranges.length - 1];
47556
47558
  if (isShift && currentRange) {
47557
- if (table.isColumnHeader(col, row)) {
47559
+ if (state.select.headerSelectMode !== 'cell' && table.isColumnHeader(col, row)) {
47558
47560
  const startCol = Math.min(currentRange.start.col, currentRange.end.col, col);
47559
47561
  const endCol = Math.max(currentRange.start.col, currentRange.end.col, col);
47560
47562
  const startRow = Math.min(currentRange.start.row, currentRange.end.row, row);
@@ -47562,7 +47564,7 @@
47562
47564
  currentRange.start = { col: startCol, row: startRow };
47563
47565
  currentRange.end = { col: endCol, row: endRow };
47564
47566
  }
47565
- else if (table.isRowHeader(col, row)) {
47567
+ else if (state.select.headerSelectMode !== 'cell' && table.isRowHeader(col, row)) {
47566
47568
  const startCol = Math.min(currentRange.start.col, currentRange.end.col, col);
47567
47569
  const endCol = table.colCount - 1;
47568
47570
  const startRow = Math.min(currentRange.start.row, currentRange.end.row, row);
@@ -47581,13 +47583,13 @@
47581
47583
  state.select.ranges = [];
47582
47584
  scenegraph.deleteAllSelectBorder();
47583
47585
  }
47584
- if (table.isColumnHeader(col, row)) {
47586
+ if (state.select.headerSelectMode !== 'cell' && table.isColumnHeader(col, row)) {
47585
47587
  state.select.ranges.push({
47586
47588
  start: { col, row },
47587
47589
  end: { col, row: table.rowCount - 1 }
47588
47590
  });
47589
47591
  }
47590
- else if (table.isRowHeader(col, row)) {
47592
+ else if (state.select.headerSelectMode !== 'cell' && table.isRowHeader(col, row)) {
47591
47593
  state.select.ranges.push({
47592
47594
  start: { col, row },
47593
47595
  end: { col: table.colCount - 1, row }
@@ -48199,7 +48201,8 @@
48199
48201
  }
48200
48202
  }
48201
48203
  setSelectState() {
48202
- const { disableSelect, disableHeaderSelect } = this.table.options?.select ?? {
48204
+ const { headerSelectMode, disableSelect, disableHeaderSelect } = this.table.options?.select ?? {
48205
+ headerSelectMode: 'inline',
48203
48206
  disableSelect: false,
48204
48207
  disableHeaderSelect: false
48205
48208
  };
@@ -48211,6 +48214,7 @@
48211
48214
  }
48212
48215
  this.select.singleStyle = !disableSelect;
48213
48216
  this.select.disableHeader = disableHeaderSelect;
48217
+ this.select.headerSelectMode = headerSelectMode;
48214
48218
  }
48215
48219
  isSelected(col, row) {
48216
48220
  let seled = false;
@@ -52729,7 +52733,7 @@
52729
52733
  return TABLE_EVENT_TYPE;
52730
52734
  }
52731
52735
  options;
52732
- version = "0.12.3-alpha.1";
52736
+ version = "0.13.0-alpha.2";
52733
52737
  pagination;
52734
52738
  id = `VTable${Date.now()}`;
52735
52739
  headerStyleCache;
@@ -62440,7 +62444,7 @@
62440
62444
  return new Tag(params ? params.attribute : {});
62441
62445
  }
62442
62446
 
62443
- const version = "0.12.3-alpha.1";
62447
+ const version = "0.13.0-alpha.2";
62444
62448
  function getIcons() {
62445
62449
  return get$1();
62446
62450
  }