handsontable 0.0.0-next-3d099da-20231208 → 0.0.0-next-51d3397-20231211

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of handsontable might be problematic. Click here for more details.

Files changed (129) hide show
  1. package/3rdparty/walkontable/src/calculator/index.js +11 -6
  2. package/3rdparty/walkontable/src/calculator/index.mjs +5 -3
  3. package/3rdparty/walkontable/src/calculator/renderAllColumns.js +50 -0
  4. package/3rdparty/walkontable/src/calculator/renderAllColumns.mjs +46 -0
  5. package/3rdparty/walkontable/src/calculator/renderAllRows.js +50 -0
  6. package/3rdparty/walkontable/src/calculator/renderAllRows.mjs +46 -0
  7. package/3rdparty/walkontable/src/calculator/viewportColumns.js +1 -122
  8. package/3rdparty/walkontable/src/calculator/viewportColumns.mjs +2 -124
  9. package/3rdparty/walkontable/src/calculator/viewportRows.js +1 -1
  10. package/3rdparty/walkontable/src/calculator/viewportRows.mjs +2 -3
  11. package/3rdparty/walkontable/src/core/_base.js +0 -12
  12. package/3rdparty/walkontable/src/core/_base.mjs +0 -12
  13. package/3rdparty/walkontable/src/core/core.js +0 -2
  14. package/3rdparty/walkontable/src/core/core.mjs +0 -2
  15. package/3rdparty/walkontable/src/facade/core.js +0 -9
  16. package/3rdparty/walkontable/src/facade/core.mjs +0 -9
  17. package/3rdparty/walkontable/src/index.js +3 -4
  18. package/3rdparty/walkontable/src/index.mjs +1 -2
  19. package/3rdparty/walkontable/src/overlays.js +0 -3
  20. package/3rdparty/walkontable/src/overlays.mjs +0 -4
  21. package/3rdparty/walkontable/src/renderer/colGroup.js +10 -0
  22. package/3rdparty/walkontable/src/renderer/colGroup.mjs +10 -0
  23. package/3rdparty/walkontable/src/renderer/rows.js +4 -3
  24. package/3rdparty/walkontable/src/renderer/rows.mjs +4 -3
  25. package/3rdparty/walkontable/src/selection/manager.js +0 -1
  26. package/3rdparty/walkontable/src/selection/manager.mjs +0 -1
  27. package/3rdparty/walkontable/src/settings.js +3 -0
  28. package/3rdparty/walkontable/src/settings.mjs +2 -0
  29. package/3rdparty/walkontable/src/table.js +0 -1
  30. package/3rdparty/walkontable/src/table.mjs +0 -1
  31. package/3rdparty/walkontable/src/utils/column.js +27 -12
  32. package/3rdparty/walkontable/src/utils/column.mjs +27 -12
  33. package/3rdparty/walkontable/src/utils/columnStretching.js +219 -0
  34. package/3rdparty/walkontable/src/utils/columnStretching.mjs +215 -0
  35. package/3rdparty/walkontable/src/viewport.js +22 -17
  36. package/3rdparty/walkontable/src/viewport.mjs +23 -18
  37. package/base.js +4 -2
  38. package/base.mjs +2 -2
  39. package/core/focusCatcher/index.js +44 -6
  40. package/core/focusCatcher/index.mjs +44 -6
  41. package/core.js +0 -11
  42. package/core.mjs +0 -11
  43. package/dataMap/dataMap.js +1 -0
  44. package/dataMap/metaManager/metaSchema.js +28 -2
  45. package/dataMap/metaManager/metaSchema.mjs +28 -2
  46. package/dataMap/metaManager/mods/extendMetaProperties.js +12 -0
  47. package/dataMap/metaManager/mods/extendMetaProperties.mjs +12 -0
  48. package/dist/handsontable.css +2 -2
  49. package/dist/handsontable.full.css +3 -3
  50. package/dist/handsontable.full.js +3979 -5577
  51. package/dist/handsontable.full.min.css +3 -3
  52. package/dist/handsontable.full.min.js +66 -71
  53. package/dist/handsontable.js +3058 -4305
  54. package/dist/handsontable.min.css +2 -2
  55. package/dist/handsontable.min.js +35 -39
  56. package/editorManager.js +3 -4
  57. package/editorManager.mjs +3 -4
  58. package/editors/autocompleteEditor/autocompleteEditor.js +0 -2
  59. package/editors/autocompleteEditor/autocompleteEditor.mjs +0 -2
  60. package/editors/dateEditor/dateEditor.d.ts +1 -1
  61. package/editors/dateEditor/dateEditor.js +4 -1
  62. package/editors/dateEditor/dateEditor.mjs +4 -1
  63. package/editors/handsontableEditor/handsontableEditor.js +0 -1
  64. package/editors/handsontableEditor/handsontableEditor.mjs +0 -1
  65. package/editors/textEditor/textEditor.js +0 -4
  66. package/editors/textEditor/textEditor.mjs +0 -4
  67. package/helpers/browser.js +5 -2
  68. package/helpers/browser.mjs +5 -2
  69. package/helpers/feature.js +10 -0
  70. package/helpers/feature.mjs +9 -0
  71. package/helpers/mixed.js +1 -1
  72. package/helpers/mixed.mjs +1 -1
  73. package/package.json +3 -4
  74. package/pluginHooks.d.ts +6 -29
  75. package/pluginHooks.js +65 -123
  76. package/pluginHooks.mjs +62 -122
  77. package/plugins/copyPaste/clipboardData.js +18 -0
  78. package/plugins/copyPaste/clipboardData.mjs +14 -0
  79. package/plugins/copyPaste/copyPaste.js +129 -51
  80. package/plugins/copyPaste/copyPaste.mjs +132 -54
  81. package/plugins/copyPaste/copyableRanges.js +43 -7
  82. package/plugins/copyPaste/copyableRanges.mjs +42 -7
  83. package/plugins/copyPaste/pasteEvent.mjs +1 -1
  84. package/plugins/customBorders/customBorders.js +0 -5
  85. package/plugins/customBorders/customBorders.mjs +0 -5
  86. package/plugins/customBorders/utils.js +0 -1
  87. package/plugins/customBorders/utils.mjs +0 -1
  88. package/plugins/filters/ui/radioInput.js +1 -1
  89. package/plugins/filters/ui/radioInput.mjs +1 -1
  90. package/plugins/formulas/formulas.js +0 -2
  91. package/plugins/formulas/formulas.mjs +0 -2
  92. package/plugins/formulas/indexSyncer/axisSyncer.js +0 -1
  93. package/plugins/formulas/indexSyncer/axisSyncer.mjs +0 -1
  94. package/plugins/manualColumnResize/manualColumnResize.js +0 -1
  95. package/plugins/manualColumnResize/manualColumnResize.mjs +0 -1
  96. package/plugins/mergeCells/mergeCells.js +1 -127
  97. package/plugins/mergeCells/mergeCells.mjs +1 -127
  98. package/plugins/nestedHeaders/nestedHeaders.js +41 -87
  99. package/plugins/nestedHeaders/nestedHeaders.mjs +42 -88
  100. package/plugins/nestedHeaders/stateManager/headersTree.js +0 -1
  101. package/plugins/nestedHeaders/stateManager/headersTree.mjs +0 -1
  102. package/plugins/undoRedo/undoRedo.js +0 -2
  103. package/plugins/undoRedo/undoRedo.mjs +0 -2
  104. package/renderers/autocompleteRenderer/autocompleteRenderer.js +0 -1
  105. package/renderers/autocompleteRenderer/autocompleteRenderer.mjs +0 -1
  106. package/renderers/checkboxRenderer/checkboxRenderer.js +0 -2
  107. package/renderers/checkboxRenderer/checkboxRenderer.mjs +0 -2
  108. package/selection/highlight/highlight.js +0 -1
  109. package/selection/highlight/highlight.mjs +0 -1
  110. package/selection/index.js +1 -3
  111. package/selection/index.mjs +2 -2
  112. package/selection/utils.js +0 -34
  113. package/selection/utils.mjs +0 -33
  114. package/settings.d.ts +2 -1
  115. package/tableView.js +1 -2
  116. package/tableView.mjs +1 -2
  117. package/translations/indexMapper.js +2 -1
  118. package/utils/parseTable.js +84 -538
  119. package/utils/parseTable.mjs +83 -534
  120. package/validators/timeValidator/timeValidator.js +0 -1
  121. package/validators/timeValidator/timeValidator.mjs +0 -1
  122. package/plugins/copyPaste/clipboardData/clipboardData.js +0 -588
  123. package/plugins/copyPaste/clipboardData/clipboardData.mjs +0 -584
  124. package/plugins/copyPaste/clipboardData/copyClipboardData.js +0 -69
  125. package/plugins/copyPaste/clipboardData/copyClipboardData.mjs +0 -65
  126. package/plugins/copyPaste/clipboardData/index.js +0 -9
  127. package/plugins/copyPaste/clipboardData/index.mjs +0 -4
  128. package/plugins/copyPaste/clipboardData/pasteClipboardData.js +0 -81
  129. package/plugins/copyPaste/clipboardData/pasteClipboardData.mjs +0 -77
@@ -12,14 +12,15 @@ var _focusDetector = require("./focusDetector");
12
12
  * @param {Core} hot The Handsontable instance.
13
13
  */
14
14
  function installFocusCatcher(hot) {
15
+ const clampCoordsIfNeeded = normalizeCoordsIfNeeded(hot);
15
16
  let recentlyAddedFocusCoords;
16
17
  const {
17
18
  activate,
18
19
  deactivate
19
20
  } = (0, _focusDetector.installFocusDetector)(hot, {
20
21
  onFocusFromTop() {
21
- var _recentlyAddedFocusCo;
22
- const mostTopStartCoords = (_recentlyAddedFocusCo = recentlyAddedFocusCoords) !== null && _recentlyAddedFocusCo !== void 0 ? _recentlyAddedFocusCo : getMostTopStartPosition(hot);
22
+ var _clampCoordsIfNeeded;
23
+ const mostTopStartCoords = (_clampCoordsIfNeeded = clampCoordsIfNeeded(recentlyAddedFocusCoords)) !== null && _clampCoordsIfNeeded !== void 0 ? _clampCoordsIfNeeded : getMostTopStartPosition(hot);
23
24
  if (mostTopStartCoords) {
24
25
  hot.runHooks('modifyFocusOnTabNavigation', 'from_above', mostTopStartCoords);
25
26
  hot.selectCell(mostTopStartCoords.row, mostTopStartCoords.col);
@@ -27,8 +28,8 @@ function installFocusCatcher(hot) {
27
28
  hot.listen();
28
29
  },
29
30
  onFocusFromBottom() {
30
- var _recentlyAddedFocusCo2;
31
- const mostBottomEndCoords = (_recentlyAddedFocusCo2 = recentlyAddedFocusCoords) !== null && _recentlyAddedFocusCo2 !== void 0 ? _recentlyAddedFocusCo2 : getMostBottomEndPosition(hot);
31
+ var _clampCoordsIfNeeded2;
32
+ const mostBottomEndCoords = (_clampCoordsIfNeeded2 = clampCoordsIfNeeded(recentlyAddedFocusCoords)) !== null && _clampCoordsIfNeeded2 !== void 0 ? _clampCoordsIfNeeded2 : getMostBottomEndPosition(hot);
32
33
  if (mostBottomEndCoords) {
33
34
  hot.runHooks('modifyFocusOnTabNavigation', 'from_below', mostBottomEndCoords);
34
35
  hot.selectCell(mostBottomEndCoords.row, mostBottomEndCoords.col);
@@ -42,10 +43,12 @@ function installFocusCatcher(hot) {
42
43
  };
43
44
  let isSavingCoordsEnabled = true;
44
45
  let isTabOrShiftTabPressed = false;
46
+ let preventViewportScroll = false;
45
47
  hot.addHook('afterListen', () => deactivate());
46
48
  hot.addHook('afterUnlisten', () => activate());
47
49
  hot.addHook('afterSelection', (row, column, row2, column2, preventScrolling) => {
48
- if (isTabOrShiftTabPressed && rowWrapState.wrapped && rowWrapState.flipped) {
50
+ if (isTabOrShiftTabPressed && (rowWrapState.wrapped && rowWrapState.flipped || preventViewportScroll)) {
51
+ preventViewportScroll = false;
49
52
  preventScrolling.value = true;
50
53
  }
51
54
  if (isSavingCoordsEnabled) {
@@ -77,10 +80,16 @@ function installFocusCatcher(hot) {
77
80
  hot.getShortcutManager().getContext('grid').addShortcuts([{
78
81
  ...shortcutOptions,
79
82
  callback: () => {
83
+ const {
84
+ tabNavigation
85
+ } = hot.getSettings();
80
86
  isTabOrShiftTabPressed = true;
81
- if (hot.getSelectedRangeLast() && !hot.getSettings().tabNavigation) {
87
+ if (hot.getSelectedRangeLast() && !tabNavigation) {
82
88
  isSavingCoordsEnabled = false;
83
89
  }
90
+ if (!tabNavigation) {
91
+ preventViewportScroll = true;
92
+ }
84
93
  },
85
94
  position: 'before'
86
95
  }, {
@@ -165,4 +174,33 @@ function getMostBottomEndPosition(hot) {
165
174
  endColumn = -1;
166
175
  }
167
176
  return hot._createCellCoords((_rowIndexMapper$getVi = rowIndexMapper.getVisualFromRenderableIndex(bottomRow)) !== null && _rowIndexMapper$getVi !== void 0 ? _rowIndexMapper$getVi : bottomRow, (_columnIndexMapper$ge = columnIndexMapper.getVisualFromRenderableIndex(endColumn)) !== null && _columnIndexMapper$ge !== void 0 ? _columnIndexMapper$ge : endColumn);
177
+ }
178
+
179
+ /**
180
+ * Normalizes the coordinates (clamps to nearest visible cell position within dataset range).
181
+ *
182
+ * @param {Core} hot The Handsontable instance.
183
+ * @returns {function(Coords | undefined): Coords | null}
184
+ */
185
+ function normalizeCoordsIfNeeded(hot) {
186
+ return coords => {
187
+ if (!coords) {
188
+ return null;
189
+ }
190
+ const mostTopStartCoords = getMostTopStartPosition(hot);
191
+ const mostBottomEndCoords = getMostBottomEndPosition(hot);
192
+ if (coords.col < mostTopStartCoords.col) {
193
+ coords.col = mostTopStartCoords.col;
194
+ }
195
+ if (coords.col > mostBottomEndCoords.col) {
196
+ coords.col = mostBottomEndCoords.col;
197
+ }
198
+ if (coords.row < mostTopStartCoords.row) {
199
+ coords.row = mostTopStartCoords.row;
200
+ }
201
+ if (coords.row > mostBottomEndCoords.row) {
202
+ coords.row = mostBottomEndCoords.row;
203
+ }
204
+ return coords;
205
+ };
168
206
  }
@@ -8,14 +8,15 @@ import { installFocusDetector } from "./focusDetector.mjs";
8
8
  * @param {Core} hot The Handsontable instance.
9
9
  */
10
10
  export function installFocusCatcher(hot) {
11
+ const clampCoordsIfNeeded = normalizeCoordsIfNeeded(hot);
11
12
  let recentlyAddedFocusCoords;
12
13
  const {
13
14
  activate,
14
15
  deactivate
15
16
  } = installFocusDetector(hot, {
16
17
  onFocusFromTop() {
17
- var _recentlyAddedFocusCo;
18
- const mostTopStartCoords = (_recentlyAddedFocusCo = recentlyAddedFocusCoords) !== null && _recentlyAddedFocusCo !== void 0 ? _recentlyAddedFocusCo : getMostTopStartPosition(hot);
18
+ var _clampCoordsIfNeeded;
19
+ const mostTopStartCoords = (_clampCoordsIfNeeded = clampCoordsIfNeeded(recentlyAddedFocusCoords)) !== null && _clampCoordsIfNeeded !== void 0 ? _clampCoordsIfNeeded : getMostTopStartPosition(hot);
19
20
  if (mostTopStartCoords) {
20
21
  hot.runHooks('modifyFocusOnTabNavigation', 'from_above', mostTopStartCoords);
21
22
  hot.selectCell(mostTopStartCoords.row, mostTopStartCoords.col);
@@ -23,8 +24,8 @@ export function installFocusCatcher(hot) {
23
24
  hot.listen();
24
25
  },
25
26
  onFocusFromBottom() {
26
- var _recentlyAddedFocusCo2;
27
- const mostBottomEndCoords = (_recentlyAddedFocusCo2 = recentlyAddedFocusCoords) !== null && _recentlyAddedFocusCo2 !== void 0 ? _recentlyAddedFocusCo2 : getMostBottomEndPosition(hot);
27
+ var _clampCoordsIfNeeded2;
28
+ const mostBottomEndCoords = (_clampCoordsIfNeeded2 = clampCoordsIfNeeded(recentlyAddedFocusCoords)) !== null && _clampCoordsIfNeeded2 !== void 0 ? _clampCoordsIfNeeded2 : getMostBottomEndPosition(hot);
28
29
  if (mostBottomEndCoords) {
29
30
  hot.runHooks('modifyFocusOnTabNavigation', 'from_below', mostBottomEndCoords);
30
31
  hot.selectCell(mostBottomEndCoords.row, mostBottomEndCoords.col);
@@ -38,10 +39,12 @@ export function installFocusCatcher(hot) {
38
39
  };
39
40
  let isSavingCoordsEnabled = true;
40
41
  let isTabOrShiftTabPressed = false;
42
+ let preventViewportScroll = false;
41
43
  hot.addHook('afterListen', () => deactivate());
42
44
  hot.addHook('afterUnlisten', () => activate());
43
45
  hot.addHook('afterSelection', (row, column, row2, column2, preventScrolling) => {
44
- if (isTabOrShiftTabPressed && rowWrapState.wrapped && rowWrapState.flipped) {
46
+ if (isTabOrShiftTabPressed && (rowWrapState.wrapped && rowWrapState.flipped || preventViewportScroll)) {
47
+ preventViewportScroll = false;
45
48
  preventScrolling.value = true;
46
49
  }
47
50
  if (isSavingCoordsEnabled) {
@@ -73,10 +76,16 @@ export function installFocusCatcher(hot) {
73
76
  hot.getShortcutManager().getContext('grid').addShortcuts([{
74
77
  ...shortcutOptions,
75
78
  callback: () => {
79
+ const {
80
+ tabNavigation
81
+ } = hot.getSettings();
76
82
  isTabOrShiftTabPressed = true;
77
- if (hot.getSelectedRangeLast() && !hot.getSettings().tabNavigation) {
83
+ if (hot.getSelectedRangeLast() && !tabNavigation) {
78
84
  isSavingCoordsEnabled = false;
79
85
  }
86
+ if (!tabNavigation) {
87
+ preventViewportScroll = true;
88
+ }
80
89
  },
81
90
  position: 'before'
82
91
  }, {
@@ -161,4 +170,33 @@ function getMostBottomEndPosition(hot) {
161
170
  endColumn = -1;
162
171
  }
163
172
  return hot._createCellCoords((_rowIndexMapper$getVi = rowIndexMapper.getVisualFromRenderableIndex(bottomRow)) !== null && _rowIndexMapper$getVi !== void 0 ? _rowIndexMapper$getVi : bottomRow, (_columnIndexMapper$ge = columnIndexMapper.getVisualFromRenderableIndex(endColumn)) !== null && _columnIndexMapper$ge !== void 0 ? _columnIndexMapper$ge : endColumn);
173
+ }
174
+
175
+ /**
176
+ * Normalizes the coordinates (clamps to nearest visible cell position within dataset range).
177
+ *
178
+ * @param {Core} hot The Handsontable instance.
179
+ * @returns {function(Coords | undefined): Coords | null}
180
+ */
181
+ function normalizeCoordsIfNeeded(hot) {
182
+ return coords => {
183
+ if (!coords) {
184
+ return null;
185
+ }
186
+ const mostTopStartCoords = getMostTopStartPosition(hot);
187
+ const mostBottomEndCoords = getMostBottomEndPosition(hot);
188
+ if (coords.col < mostTopStartCoords.col) {
189
+ coords.col = mostTopStartCoords.col;
190
+ }
191
+ if (coords.col > mostBottomEndCoords.col) {
192
+ coords.col = mostBottomEndCoords.col;
193
+ }
194
+ if (coords.row < mostTopStartCoords.row) {
195
+ coords.row = mostTopStartCoords.row;
196
+ }
197
+ if (coords.row > mostBottomEndCoords.row) {
198
+ coords.row = mostBottomEndCoords.row;
199
+ }
200
+ return coords;
201
+ };
164
202
  }
package/core.js CHANGED
@@ -254,7 +254,6 @@ function Core(rootElement, userSettings) {
254
254
  if (!this.rootElement.id || this.rootElement.id.substring(0, 3) === 'ht_') {
255
255
  this.rootElement.id = this.guid; // if root element does not have an id, assign a random id
256
256
  }
257
-
258
257
  const visualToRenderableCoords = coords => {
259
258
  const {
260
259
  row: visualRow,
@@ -274,7 +273,6 @@ function Core(rootElement, userSettings) {
274
273
  renderableRow >= 0 ? instance.rowIndexMapper.getVisualFromRenderableIndex(renderableRow) : renderableRow, renderableColumn >= 0 ? instance.columnIndexMapper.getVisualFromRenderableIndex(renderableColumn) : renderableColumn // eslint-disable-line max-len
275
274
  );
276
275
  };
277
-
278
276
  let selection = new _selection.Selection(tableMeta, {
279
277
  rowIndexMapper: instance.rowIndexMapper,
280
278
  columnIndexMapper: instance.columnIndexMapper,
@@ -577,7 +575,6 @@ function Core(rootElement, userSettings) {
577
575
  instance._refreshBorders(); // it will call render and prepare methods
578
576
  }
579
577
  }
580
-
581
578
  break;
582
579
  case 'insert_col_start':
583
580
  case 'insert_col_end':
@@ -600,7 +597,6 @@ function Core(rootElement, userSettings) {
600
597
  spliceArray.length += colDelta; // inserts empty (undefined) elements at the end of an array
601
598
  Array.prototype.splice.apply(tableMeta.colHeaders, spliceArray); // inserts empty (undefined) elements into the colHeader array
602
599
  }
603
-
604
600
  const currentSelectedRange = selection.selectedRange.current();
605
601
  const currentFromRange = currentSelectedRange === null || currentSelectedRange === void 0 ? void 0 : currentSelectedRange.from;
606
602
  const currentFromColumn = currentFromRange === null || currentFromRange === void 0 ? void 0 : currentFromRange.col;
@@ -634,7 +630,6 @@ function Core(rootElement, userSettings) {
634
630
  instance._refreshBorders(); // it will call render and prepare methods
635
631
  }
636
632
  }
637
-
638
633
  break;
639
634
  case 'remove_row':
640
635
  const removeRow = indexes => {
@@ -730,7 +725,6 @@ function Core(rootElement, userSettings) {
730
725
  grid.adjustRowsAndCols(); // makes sure that we did not add rows that will be removed in next refresh
731
726
  }
732
727
  },
733
-
734
728
  /**
735
729
  * Makes sure there are empty rows at the bottom of the table.
736
730
  *
@@ -1186,7 +1180,6 @@ function Core(rootElement, userSettings) {
1186
1180
  }
1187
1181
  callback(isValid); // called when async validators are resolved and beforeChange was not async
1188
1182
  };
1189
-
1190
1183
  for (let i = changes.length - 1; i >= 0; i--) {
1191
1184
  const [row, prop,, newValue] = changes[i];
1192
1185
  const col = datamap.propToCol(prop);
@@ -1456,7 +1449,6 @@ function Core(rootElement, userSettings) {
1456
1449
  if (typeof input[i][1] !== 'number') {
1457
1450
  throw new Error('Method `setDataAtCell` accepts row and column number as its parameters. If you want to use object property name, use method `setDataAtRowProp`'); // eslint-disable-line max-len
1458
1451
  }
1459
-
1460
1452
  if (input[i][1] >= this.countCols()) {
1461
1453
  prop = input[i][1];
1462
1454
  } else {
@@ -1587,7 +1579,6 @@ function Core(rootElement, userSettings) {
1587
1579
  if (!(typeof input === 'object' && typeof input[0] === 'object')) {
1588
1580
  throw new Error('populateFromArray parameter `input` must be an array of arrays'); // API changed in 0.9-beta2, let's check if you use it correctly
1589
1581
  }
1590
-
1591
1582
  const c = typeof endRow === 'number' ? instance._createCellCoords(endRow, endCol) : null;
1592
1583
  return grid.populateFromArray(instance._createCellCoords(row, column), input, c, source, method);
1593
1584
  };
@@ -3488,7 +3479,6 @@ function Core(rootElement, userSettings) {
3488
3479
  } else if (tableMeta.colHeaders && typeof tableMeta.colHeaders !== 'string' && typeof tableMeta.colHeaders !== 'number') {
3489
3480
  result = (0, _data.spreadsheetColumnLabel)(columnIndex); // see #1458
3490
3481
  }
3491
-
3492
3482
  result = instance.runHooks('modifyColumnHeaderValue', result, column, headerLevel);
3493
3483
  return result;
3494
3484
  };
@@ -4119,7 +4109,6 @@ function Core(rootElement, userSettings) {
4119
4109
  };
4120
4110
  /* eslint-enable prefer-rest-params */
4121
4111
  }
4122
-
4123
4112
  const {
4124
4113
  row,
4125
4114
  col,
package/core.mjs CHANGED
@@ -249,7 +249,6 @@ export default function Core(rootElement, userSettings) {
249
249
  if (!this.rootElement.id || this.rootElement.id.substring(0, 3) === 'ht_') {
250
250
  this.rootElement.id = this.guid; // if root element does not have an id, assign a random id
251
251
  }
252
-
253
252
  const visualToRenderableCoords = coords => {
254
253
  const {
255
254
  row: visualRow,
@@ -269,7 +268,6 @@ export default function Core(rootElement, userSettings) {
269
268
  renderableRow >= 0 ? instance.rowIndexMapper.getVisualFromRenderableIndex(renderableRow) : renderableRow, renderableColumn >= 0 ? instance.columnIndexMapper.getVisualFromRenderableIndex(renderableColumn) : renderableColumn // eslint-disable-line max-len
270
269
  );
271
270
  };
272
-
273
271
  let selection = new Selection(tableMeta, {
274
272
  rowIndexMapper: instance.rowIndexMapper,
275
273
  columnIndexMapper: instance.columnIndexMapper,
@@ -572,7 +570,6 @@ export default function Core(rootElement, userSettings) {
572
570
  instance._refreshBorders(); // it will call render and prepare methods
573
571
  }
574
572
  }
575
-
576
573
  break;
577
574
  case 'insert_col_start':
578
575
  case 'insert_col_end':
@@ -595,7 +592,6 @@ export default function Core(rootElement, userSettings) {
595
592
  spliceArray.length += colDelta; // inserts empty (undefined) elements at the end of an array
596
593
  Array.prototype.splice.apply(tableMeta.colHeaders, spliceArray); // inserts empty (undefined) elements into the colHeader array
597
594
  }
598
-
599
595
  const currentSelectedRange = selection.selectedRange.current();
600
596
  const currentFromRange = currentSelectedRange === null || currentSelectedRange === void 0 ? void 0 : currentSelectedRange.from;
601
597
  const currentFromColumn = currentFromRange === null || currentFromRange === void 0 ? void 0 : currentFromRange.col;
@@ -629,7 +625,6 @@ export default function Core(rootElement, userSettings) {
629
625
  instance._refreshBorders(); // it will call render and prepare methods
630
626
  }
631
627
  }
632
-
633
628
  break;
634
629
  case 'remove_row':
635
630
  const removeRow = indexes => {
@@ -725,7 +720,6 @@ export default function Core(rootElement, userSettings) {
725
720
  grid.adjustRowsAndCols(); // makes sure that we did not add rows that will be removed in next refresh
726
721
  }
727
722
  },
728
-
729
723
  /**
730
724
  * Makes sure there are empty rows at the bottom of the table.
731
725
  *
@@ -1181,7 +1175,6 @@ export default function Core(rootElement, userSettings) {
1181
1175
  }
1182
1176
  callback(isValid); // called when async validators are resolved and beforeChange was not async
1183
1177
  };
1184
-
1185
1178
  for (let i = changes.length - 1; i >= 0; i--) {
1186
1179
  const [row, prop,, newValue] = changes[i];
1187
1180
  const col = datamap.propToCol(prop);
@@ -1451,7 +1444,6 @@ export default function Core(rootElement, userSettings) {
1451
1444
  if (typeof input[i][1] !== 'number') {
1452
1445
  throw new Error('Method `setDataAtCell` accepts row and column number as its parameters. If you want to use object property name, use method `setDataAtRowProp`'); // eslint-disable-line max-len
1453
1446
  }
1454
-
1455
1447
  if (input[i][1] >= this.countCols()) {
1456
1448
  prop = input[i][1];
1457
1449
  } else {
@@ -1582,7 +1574,6 @@ export default function Core(rootElement, userSettings) {
1582
1574
  if (!(typeof input === 'object' && typeof input[0] === 'object')) {
1583
1575
  throw new Error('populateFromArray parameter `input` must be an array of arrays'); // API changed in 0.9-beta2, let's check if you use it correctly
1584
1576
  }
1585
-
1586
1577
  const c = typeof endRow === 'number' ? instance._createCellCoords(endRow, endCol) : null;
1587
1578
  return grid.populateFromArray(instance._createCellCoords(row, column), input, c, source, method);
1588
1579
  };
@@ -3483,7 +3474,6 @@ export default function Core(rootElement, userSettings) {
3483
3474
  } else if (tableMeta.colHeaders && typeof tableMeta.colHeaders !== 'string' && typeof tableMeta.colHeaders !== 'number') {
3484
3475
  result = spreadsheetColumnLabel(columnIndex); // see #1458
3485
3476
  }
3486
-
3487
3477
  result = instance.runHooks('modifyColumnHeaderValue', result, column, headerLevel);
3488
3478
  return result;
3489
3479
  };
@@ -4114,7 +4104,6 @@ export default function Core(rootElement, userSettings) {
4114
4104
  };
4115
4105
  /* eslint-enable prefer-rest-params */
4116
4106
  }
4117
-
4118
4107
  const {
4119
4108
  row,
4120
4109
  col,
@@ -33,6 +33,7 @@ The above copyright notice and this permission notice shall be included in all c
33
33
 
34
34
  THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
35
35
  */
36
+
36
37
  /**
37
38
  * Utility class that gets and saves data from/to the data source using mapping of columns numbers to object property names.
38
39
  *
@@ -3573,7 +3573,7 @@ var _default = () => {
3573
3573
  *
3574
3574
  * @memberof Options#
3575
3575
  * @type {boolean}
3576
- * @default undefined
3576
+ * @default false
3577
3577
  * @category Core
3578
3578
  *
3579
3579
  * @example
@@ -3582,7 +3582,33 @@ var _default = () => {
3582
3582
  * renderAllRows: true,
3583
3583
  * ```
3584
3584
  */
3585
- renderAllRows: undefined,
3585
+ renderAllRows: false,
3586
+ /**
3587
+ * The `renderAllColumns` option configures Handsontable's [column virtualization](@/guides/columns/column-virtualization.md).
3588
+ *
3589
+ * You can set the `renderAllColumns` option to one of the following:
3590
+ *
3591
+ * | Setting | Description |
3592
+ * | ----------------- | -------------------------------------------------------------------------------------------------- |
3593
+ * | `false` (default) | Enable [column virtualization](@/guides/columns/column-virtualization.md) |
3594
+ * | `true` | Disable [column virtualization](@/guides/columns/column-virtualization.md)<br>(render all columns of the grid) |
3595
+ *
3596
+ * Read more:
3597
+ * - [Row virtualization](@/guides/columns/column-virtualization.md)
3598
+ *
3599
+ * @since 14.1.0
3600
+ * @memberof Options#
3601
+ * @type {boolean}
3602
+ * @default false
3603
+ * @category Core
3604
+ *
3605
+ * @example
3606
+ * ```js
3607
+ * // disable column virtualization
3608
+ * renderAllColumns: true,
3609
+ * ```
3610
+ */
3611
+ renderAllColumns: false,
3586
3612
  /**
3587
3613
  * @description
3588
3614
  * The `renderer` option sets a [cell renderer](@/guides/cell-functions/cell-renderer.md) for a cell.
@@ -3570,7 +3570,7 @@ export default (() => {
3570
3570
  *
3571
3571
  * @memberof Options#
3572
3572
  * @type {boolean}
3573
- * @default undefined
3573
+ * @default false
3574
3574
  * @category Core
3575
3575
  *
3576
3576
  * @example
@@ -3579,7 +3579,33 @@ export default (() => {
3579
3579
  * renderAllRows: true,
3580
3580
  * ```
3581
3581
  */
3582
- renderAllRows: undefined,
3582
+ renderAllRows: false,
3583
+ /**
3584
+ * The `renderAllColumns` option configures Handsontable's [column virtualization](@/guides/columns/column-virtualization.md).
3585
+ *
3586
+ * You can set the `renderAllColumns` option to one of the following:
3587
+ *
3588
+ * | Setting | Description |
3589
+ * | ----------------- | -------------------------------------------------------------------------------------------------- |
3590
+ * | `false` (default) | Enable [column virtualization](@/guides/columns/column-virtualization.md) |
3591
+ * | `true` | Disable [column virtualization](@/guides/columns/column-virtualization.md)<br>(render all columns of the grid) |
3592
+ *
3593
+ * Read more:
3594
+ * - [Row virtualization](@/guides/columns/column-virtualization.md)
3595
+ *
3596
+ * @since 14.1.0
3597
+ * @memberof Options#
3598
+ * @type {boolean}
3599
+ * @default false
3600
+ * @category Core
3601
+ *
3602
+ * @example
3603
+ * ```js
3604
+ * // disable column virtualization
3605
+ * renderAllColumns: true,
3606
+ * ```
3607
+ */
3608
+ renderAllColumns: false,
3583
3609
  /**
3584
3610
  * @description
3585
3611
  * The `renderer` option sets a [cell renderer](@/guides/cell-functions/cell-renderer.md) for a cell.
@@ -44,6 +44,18 @@ class ExtendMetaPropertiesMod {
44
44
  throw new Error(`The \`${propName}\` option can not be updated after the Handsontable is initialized.`);
45
45
  }
46
46
  }
47
+ }], ['renderAllColumns', {
48
+ onChange(propName, value, isInitialChange) {
49
+ if (!isInitialChange) {
50
+ throw new Error(`The \`${propName}\` option can not be updated after the Handsontable is initialized.`);
51
+ }
52
+ }
53
+ }], ['renderAllRows', {
54
+ onChange(propName, value, isInitialChange) {
55
+ if (!isInitialChange) {
56
+ throw new Error(`The \`${propName}\` option can not be updated after the Handsontable is initialized.`);
57
+ }
58
+ }
47
59
  }]]));
48
60
  this.metaManager = metaManager;
49
61
  this.extendMetaProps();
@@ -41,6 +41,18 @@ export class ExtendMetaPropertiesMod {
41
41
  throw new Error(`The \`${propName}\` option can not be updated after the Handsontable is initialized.`);
42
42
  }
43
43
  }
44
+ }], ['renderAllColumns', {
45
+ onChange(propName, value, isInitialChange) {
46
+ if (!isInitialChange) {
47
+ throw new Error(`The \`${propName}\` option can not be updated after the Handsontable is initialized.`);
48
+ }
49
+ }
50
+ }], ['renderAllRows', {
51
+ onChange(propName, value, isInitialChange) {
52
+ if (!isInitialChange) {
53
+ throw new Error(`The \`${propName}\` option can not be updated after the Handsontable is initialized.`);
54
+ }
55
+ }
44
56
  }]]));
45
57
  this.metaManager = metaManager;
46
58
  this.extendMetaProps();
@@ -25,8 +25,8 @@
25
25
  * INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES OF ANY CHARACTER ARISING FROM
26
26
  * USE OR INABILITY TO USE THIS SOFTWARE.
27
27
  *
28
- * Version: 0.0.0-next-3d099da-20231208
29
- * Release date: 30/11/2023 (built at 08/12/2023 08:37:44)
28
+ * Version: 0.0.0-next-51d3397-20231211
29
+ * Release date: 30/11/2023 (built at 11/12/2023 13:18:35)
30
30
  */
31
31
  /**
32
32
  * Fix for bootstrap styles
@@ -25,8 +25,8 @@
25
25
  * INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES OF ANY CHARACTER ARISING FROM
26
26
  * USE OR INABILITY TO USE THIS SOFTWARE.
27
27
  *
28
- * Version: 0.0.0-next-3d099da-20231208
29
- * Release date: 30/11/2023 (built at 08/12/2023 08:37:44)
28
+ * Version: 0.0.0-next-51d3397-20231211
29
+ * Release date: 30/11/2023 (built at 11/12/2023 13:18:35)
30
30
  */
31
31
  /**
32
32
  * Fix for bootstrap styles
@@ -1043,7 +1043,7 @@ http://nicolasgallagher.com/micro-clearfix-hack/
1043
1043
  color: #666;
1044
1044
  font-size: 12px;
1045
1045
  line-height: 15px;
1046
- text-align: right;
1046
+ text-align: center;
1047
1047
  background: #f5f5f5;
1048
1048
  height: initial;
1049
1049
  }