handsontable 14.5.0-next-2d9f0a9-20240730 → 14.6.0-next-4d69faf-20240924

Sign up to get free protection for your applications and to get access to all the features.
Files changed (124) hide show
  1. package/3rdparty/walkontable/src/renderer/rows.js +10 -0
  2. package/3rdparty/walkontable/src/renderer/rows.mjs +11 -1
  3. package/3rdparty/walkontable/src/selection/manager.js +7 -7
  4. package/3rdparty/walkontable/src/selection/manager.mjs +7 -7
  5. package/3rdparty/walkontable/src/selection/scanner.js +7 -7
  6. package/3rdparty/walkontable/src/selection/scanner.mjs +7 -7
  7. package/CHANGELOG.md +29 -0
  8. package/base.js +2 -2
  9. package/base.mjs +2 -2
  10. package/core.d.ts +13 -2
  11. package/core.js +160 -9
  12. package/core.mjs +160 -9
  13. package/dataMap/metaManager/lazyFactoryMap.js +7 -7
  14. package/dataMap/metaManager/lazyFactoryMap.mjs +7 -7
  15. package/dataMap/metaManager/metaSchema.js +5 -6
  16. package/dataMap/metaManager/metaSchema.mjs +7 -8
  17. package/dataMap/metaManager/mods/dynamicCellMeta.js +7 -7
  18. package/dataMap/metaManager/mods/dynamicCellMeta.mjs +7 -7
  19. package/dataMap/metaManager/mods/extendMetaProperties.js +7 -7
  20. package/dataMap/metaManager/mods/extendMetaProperties.mjs +7 -7
  21. package/dataMap/metaManager/utils.js +7 -7
  22. package/dataMap/metaManager/utils.mjs +7 -7
  23. package/dist/handsontable.css +3 -17
  24. package/dist/handsontable.full.css +3 -17
  25. package/dist/handsontable.full.js +3498 -3219
  26. package/dist/handsontable.full.min.css +3 -3
  27. package/dist/handsontable.full.min.js +109 -119
  28. package/dist/handsontable.js +3172 -2897
  29. package/dist/handsontable.min.css +3 -3
  30. package/dist/handsontable.min.js +19 -19
  31. package/editors/autocompleteEditor/autocompleteEditor.d.ts +1 -1
  32. package/helpers/a11y.js +2 -0
  33. package/helpers/a11y.mjs +1 -0
  34. package/helpers/array.js +7 -7
  35. package/helpers/array.mjs +7 -7
  36. package/helpers/mixed.js +2 -2
  37. package/helpers/mixed.mjs +2 -2
  38. package/helpers/number.js +7 -7
  39. package/helpers/number.mjs +7 -7
  40. package/package.json +1 -1
  41. package/pluginHooks.d.ts +1 -1
  42. package/pluginHooks.js +1 -0
  43. package/pluginHooks.mjs +1 -0
  44. package/plugins/autoRowSize/autoRowSize.js +1 -2
  45. package/plugins/autoRowSize/autoRowSize.mjs +1 -2
  46. package/plugins/columnSorting/columnSorting.js +10 -1
  47. package/plugins/columnSorting/columnSorting.mjs +10 -1
  48. package/plugins/columnSorting/utils.js +7 -7
  49. package/plugins/columnSorting/utils.mjs +7 -7
  50. package/plugins/contextMenu/contextMenu.js +7 -0
  51. package/plugins/contextMenu/contextMenu.mjs +7 -0
  52. package/plugins/contextMenu/menu/menu.js +47 -14
  53. package/plugins/contextMenu/menu/menu.mjs +48 -15
  54. package/plugins/contextMenu/menu/menuItemRenderer.js +3 -4
  55. package/plugins/contextMenu/menu/menuItemRenderer.mjs +5 -6
  56. package/plugins/contextMenu/menu/positioner.js +4 -12
  57. package/plugins/contextMenu/menu/positioner.mjs +4 -12
  58. package/plugins/contextMenu/menu/utils.js +11 -0
  59. package/plugins/contextMenu/menu/utils.mjs +10 -0
  60. package/plugins/contextMenu/predefinedItems/alignment.js +56 -49
  61. package/plugins/contextMenu/predefinedItems/alignment.mjs +57 -50
  62. package/plugins/contextMenu/predefinedItems/readOnly.js +8 -0
  63. package/plugins/contextMenu/predefinedItems/readOnly.mjs +8 -0
  64. package/plugins/contextMenu/utils.js +26 -0
  65. package/plugins/contextMenu/utils.mjs +24 -0
  66. package/plugins/copyPaste/copyPaste.js +14 -14
  67. package/plugins/copyPaste/copyPaste.mjs +14 -14
  68. package/plugins/dropdownMenu/dropdownMenu.js +10 -4
  69. package/plugins/dropdownMenu/dropdownMenu.mjs +10 -4
  70. package/plugins/filters/component/condition.js +6 -1
  71. package/plugins/filters/component/condition.mjs +6 -1
  72. package/plugins/filters/component/value.js +6 -1
  73. package/plugins/filters/component/value.mjs +6 -1
  74. package/plugins/filters/conditionCollection.d.ts +4 -3
  75. package/plugins/filters/conditionCollection.js +26 -0
  76. package/plugins/filters/conditionCollection.mjs +26 -0
  77. package/plugins/filters/filters.js +4 -1
  78. package/plugins/filters/filters.mjs +4 -1
  79. package/plugins/filters/ui/multipleSelect.js +7 -9
  80. package/plugins/filters/ui/multipleSelect.mjs +7 -9
  81. package/plugins/filters/utils.js +7 -7
  82. package/plugins/filters/utils.mjs +7 -7
  83. package/plugins/formulas/formulas.js +7 -7
  84. package/plugins/formulas/formulas.mjs +7 -7
  85. package/plugins/hiddenColumns/hiddenColumns.js +7 -7
  86. package/plugins/hiddenColumns/hiddenColumns.mjs +7 -7
  87. package/plugins/hiddenRows/hiddenRows.js +7 -7
  88. package/plugins/hiddenRows/hiddenRows.mjs +7 -7
  89. package/plugins/mergeCells/cellsCollection.js +18 -16
  90. package/plugins/mergeCells/cellsCollection.mjs +19 -17
  91. package/plugins/mergeCells/mergeCells.js +7 -7
  92. package/plugins/mergeCells/mergeCells.mjs +7 -7
  93. package/plugins/nestedHeaders/stateManager/nodeModifiers/collapse.js +7 -7
  94. package/plugins/nestedHeaders/stateManager/nodeModifiers/collapse.mjs +7 -7
  95. package/plugins/nestedHeaders/stateManager/nodeModifiers/expand.js +7 -7
  96. package/plugins/nestedHeaders/stateManager/nodeModifiers/expand.mjs +7 -7
  97. package/plugins/nestedRows/nestedRows.js +7 -7
  98. package/plugins/nestedRows/nestedRows.mjs +7 -7
  99. package/plugins/trimRows/trimRows.js +7 -7
  100. package/plugins/trimRows/trimRows.mjs +7 -7
  101. package/plugins/undoRedo/undoRedo.js +9 -5
  102. package/plugins/undoRedo/undoRedo.mjs +9 -5
  103. package/renderers/checkboxRenderer/checkboxRenderer.js +18 -6
  104. package/renderers/checkboxRenderer/checkboxRenderer.mjs +18 -6
  105. package/selection/selection.js +7 -7
  106. package/selection/selection.mjs +7 -7
  107. package/selection/utils.js +7 -7
  108. package/selection/utils.mjs +7 -7
  109. package/shortcutContexts/grid.js +10 -3
  110. package/shortcutContexts/grid.mjs +10 -3
  111. package/shortcuts/keyObserver.js +7 -7
  112. package/shortcuts/keyObserver.mjs +7 -7
  113. package/shortcuts/utils.js +3 -1
  114. package/shortcuts/utils.mjs +3 -1
  115. package/translations/changesObservable/observable.js +7 -7
  116. package/translations/changesObservable/observable.mjs +7 -7
  117. package/translations/indexMapper.js +7 -7
  118. package/translations/indexMapper.mjs +7 -7
  119. package/utils/dataStructures/uniqueSet.js +7 -7
  120. package/utils/dataStructures/uniqueSet.mjs +7 -7
  121. package/utils/ghostTable.js +11 -9
  122. package/utils/ghostTable.mjs +12 -10
  123. package/utils/paginator.js +7 -7
  124. package/utils/paginator.mjs +7 -7
@@ -12,6 +12,10 @@ function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e
12
12
  function _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }
13
13
  function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == typeof i ? i : i + ""; }
14
14
  function _toPrimitive(t, r) { if ("object" != typeof t || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != typeof i) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
15
+ const ROW_CLASSNAMES = {
16
+ rowEven: 'ht__row_even',
17
+ rowOdd: 'ht__row_odd'
18
+ };
15
19
  let performanceWarningAppeared = false;
16
20
 
17
21
  /**
@@ -75,6 +79,12 @@ class RowsRenderer extends _base.default {
75
79
  // `aria-rowindex` is incremented by both tbody and thead rows.
76
80
  (0, _a11y.A11Y_ROWINDEX)(sourceRowIndex + ((_this$table$rowUtils$ = (_this$table$rowUtils = this.table.rowUtils) === null || _this$table$rowUtils === void 0 || (_this$table$rowUtils = _this$table$rowUtils.dataAccessObject) === null || _this$table$rowUtils === void 0 ? void 0 : _this$table$rowUtils.columnHeaders.length) !== null && _this$table$rowUtils$ !== void 0 ? _this$table$rowUtils$ : 0) + 1)]);
77
81
  }
82
+ (0, _element.removeClass)(TR, [ROW_CLASSNAMES.rowEven, ROW_CLASSNAMES.rowOdd]);
83
+ if ((sourceRowIndex + 1) % 2 === 0) {
84
+ (0, _element.addClass)(TR, ROW_CLASSNAMES.rowEven);
85
+ } else {
86
+ (0, _element.addClass)(TR, ROW_CLASSNAMES.rowOdd);
87
+ }
78
88
  }
79
89
  this.orderView.end();
80
90
  }
@@ -6,8 +6,12 @@ import BaseRenderer from "./_base.mjs";
6
6
  import { warn } from "./../../../../helpers/console.mjs";
7
7
  import { toSingleLine } from "./../../../../helpers/templateLiteralTag.mjs";
8
8
  import { OrderView } from "./../utils/orderView/index.mjs";
9
- import { setAttribute } from "../../../../helpers/dom/element.mjs";
9
+ import { addClass, removeClass, setAttribute } from "../../../../helpers/dom/element.mjs";
10
10
  import { A11Y_ROW, A11Y_ROWGROUP, A11Y_ROWINDEX } from "../../../../helpers/a11y.mjs";
11
+ const ROW_CLASSNAMES = {
12
+ rowEven: 'ht__row_even',
13
+ rowOdd: 'ht__row_odd'
14
+ };
11
15
  let performanceWarningAppeared = false;
12
16
 
13
17
  /**
@@ -71,6 +75,12 @@ export default class RowsRenderer extends BaseRenderer {
71
75
  // `aria-rowindex` is incremented by both tbody and thead rows.
72
76
  A11Y_ROWINDEX(sourceRowIndex + ((_this$table$rowUtils$ = (_this$table$rowUtils = this.table.rowUtils) === null || _this$table$rowUtils === void 0 || (_this$table$rowUtils = _this$table$rowUtils.dataAccessObject) === null || _this$table$rowUtils === void 0 ? void 0 : _this$table$rowUtils.columnHeaders.length) !== null && _this$table$rowUtils$ !== void 0 ? _this$table$rowUtils$ : 0) + 1)]);
73
77
  }
78
+ removeClass(TR, [ROW_CLASSNAMES.rowEven, ROW_CLASSNAMES.rowOdd]);
79
+ if ((sourceRowIndex + 1) % 2 === 0) {
80
+ addClass(TR, ROW_CLASSNAMES.rowEven);
81
+ } else {
82
+ addClass(TR, ROW_CLASSNAMES.rowOdd);
83
+ }
74
84
  }
75
85
  this.orderView.end();
76
86
  }
@@ -4,13 +4,13 @@ exports.__esModule = true;
4
4
  require("core-js/modules/es.error.cause.js");
5
5
  require("core-js/modules/es.array.push.js");
6
6
  require("core-js/modules/es.array.unscopables.flat.js");
7
- require("core-js/modules/esnext.set.difference.v2.js");
8
- require("core-js/modules/esnext.set.intersection.v2.js");
9
- require("core-js/modules/esnext.set.is-disjoint-from.v2.js");
10
- require("core-js/modules/esnext.set.is-subset-of.v2.js");
11
- require("core-js/modules/esnext.set.is-superset-of.v2.js");
12
- require("core-js/modules/esnext.set.symmetric-difference.v2.js");
13
- require("core-js/modules/esnext.set.union.v2.js");
7
+ require("core-js/modules/es.set.difference.v2.js");
8
+ require("core-js/modules/es.set.intersection.v2.js");
9
+ require("core-js/modules/es.set.is-disjoint-from.v2.js");
10
+ require("core-js/modules/es.set.is-subset-of.v2.js");
11
+ require("core-js/modules/es.set.is-superset-of.v2.js");
12
+ require("core-js/modules/es.set.symmetric-difference.v2.js");
13
+ require("core-js/modules/es.set.union.v2.js");
14
14
  var _element = require("../../../../helpers/dom/element");
15
15
  var _scanner2 = require("./scanner");
16
16
  var _border = _interopRequireDefault(require("./border/border"));
@@ -1,13 +1,13 @@
1
1
  import "core-js/modules/es.error.cause.js";
2
2
  import "core-js/modules/es.array.push.js";
3
3
  import "core-js/modules/es.array.unscopables.flat.js";
4
- import "core-js/modules/esnext.set.difference.v2.js";
5
- import "core-js/modules/esnext.set.intersection.v2.js";
6
- import "core-js/modules/esnext.set.is-disjoint-from.v2.js";
7
- import "core-js/modules/esnext.set.is-subset-of.v2.js";
8
- import "core-js/modules/esnext.set.is-superset-of.v2.js";
9
- import "core-js/modules/esnext.set.symmetric-difference.v2.js";
10
- import "core-js/modules/esnext.set.union.v2.js";
4
+ import "core-js/modules/es.set.difference.v2.js";
5
+ import "core-js/modules/es.set.intersection.v2.js";
6
+ import "core-js/modules/es.set.is-disjoint-from.v2.js";
7
+ import "core-js/modules/es.set.is-subset-of.v2.js";
8
+ import "core-js/modules/es.set.is-superset-of.v2.js";
9
+ import "core-js/modules/es.set.symmetric-difference.v2.js";
10
+ import "core-js/modules/es.set.union.v2.js";
11
11
  function _classPrivateMethodInitSpec(e, a) { _checkPrivateRedeclaration(e, a), a.add(e); }
12
12
  function _classPrivateFieldInitSpec(e, t, a) { _checkPrivateRedeclaration(e, t), t.set(e, a); }
13
13
  function _checkPrivateRedeclaration(e, t) { if (t.has(e)) throw new TypeError("Cannot initialize the same private elements twice on an object"); }
@@ -2,13 +2,13 @@
2
2
 
3
3
  exports.__esModule = true;
4
4
  require("core-js/modules/es.error.cause.js");
5
- require("core-js/modules/esnext.set.difference.v2.js");
6
- require("core-js/modules/esnext.set.intersection.v2.js");
7
- require("core-js/modules/esnext.set.is-disjoint-from.v2.js");
8
- require("core-js/modules/esnext.set.is-subset-of.v2.js");
9
- require("core-js/modules/esnext.set.is-superset-of.v2.js");
10
- require("core-js/modules/esnext.set.symmetric-difference.v2.js");
11
- require("core-js/modules/esnext.set.union.v2.js");
5
+ require("core-js/modules/es.set.difference.v2.js");
6
+ require("core-js/modules/es.set.intersection.v2.js");
7
+ require("core-js/modules/es.set.is-disjoint-from.v2.js");
8
+ require("core-js/modules/es.set.is-subset-of.v2.js");
9
+ require("core-js/modules/es.set.is-superset-of.v2.js");
10
+ require("core-js/modules/es.set.symmetric-difference.v2.js");
11
+ require("core-js/modules/es.set.union.v2.js");
12
12
  var _element = require("../../../../helpers/dom/element");
13
13
  function _classPrivateMethodInitSpec(e, a) { _checkPrivateRedeclaration(e, a), a.add(e); }
14
14
  function _classPrivateFieldInitSpec(e, t, a) { _checkPrivateRedeclaration(e, t), t.set(e, a); }
@@ -1,11 +1,11 @@
1
1
  import "core-js/modules/es.error.cause.js";
2
- import "core-js/modules/esnext.set.difference.v2.js";
3
- import "core-js/modules/esnext.set.intersection.v2.js";
4
- import "core-js/modules/esnext.set.is-disjoint-from.v2.js";
5
- import "core-js/modules/esnext.set.is-subset-of.v2.js";
6
- import "core-js/modules/esnext.set.is-superset-of.v2.js";
7
- import "core-js/modules/esnext.set.symmetric-difference.v2.js";
8
- import "core-js/modules/esnext.set.union.v2.js";
2
+ import "core-js/modules/es.set.difference.v2.js";
3
+ import "core-js/modules/es.set.intersection.v2.js";
4
+ import "core-js/modules/es.set.is-disjoint-from.v2.js";
5
+ import "core-js/modules/es.set.is-subset-of.v2.js";
6
+ import "core-js/modules/es.set.is-superset-of.v2.js";
7
+ import "core-js/modules/es.set.symmetric-difference.v2.js";
8
+ import "core-js/modules/es.set.union.v2.js";
9
9
  function _classPrivateMethodInitSpec(e, a) { _checkPrivateRedeclaration(e, a), a.add(e); }
10
10
  function _classPrivateFieldInitSpec(e, t, a) { _checkPrivateRedeclaration(e, t), t.set(e, a); }
11
11
  function _checkPrivateRedeclaration(e, t) { if (t.has(e)) throw new TypeError("Cannot initialize the same private elements twice on an object"); }
package/CHANGELOG.md CHANGED
@@ -9,6 +9,35 @@ adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
9
9
 
10
10
  <!-- UNVERSIONED -->
11
11
 
12
+ ## [14.6.0] - 2024-10-01
13
+
14
+ ### Added
15
+ - Fix aria-label, aria-checked and menuitemcheckbox roles for the readOnly and alignment contextMenu items [#11091](https://github.com/handsontable/handsontable/pull/11091)
16
+ - Extended the `beforeFilter` hook with a second argument to allow correct Undo/Redo functionality. [#11170](https://github.com/handsontable/handsontable/pull/11170)
17
+ - Added even and odd class names to the TR elements. [#11183](https://github.com/handsontable/handsontable/pull/11183)
18
+ - Added new API to retrieve visible, partially visible and rendered row and columns indexes. [#11189](https://github.com/handsontable/handsontable/pull/11189)
19
+
20
+ ### Changed
21
+ - Make the focus visible for `select` cell type cells. [#11160](https://github.com/handsontable/handsontable/pull/11160)
22
+
23
+ ### Removed
24
+ - Remove -ms fix from css [#11055](https://github.com/handsontable/handsontable/issues/11055)
25
+
26
+ ### Fixed
27
+ - Fixed a bug that prevents copy valus from cell comments. [#11103](https://github.com/handsontable/handsontable/pull/11103)
28
+ - Fixed submenu misalignment after horizontal scroll. [#11106](https://github.com/handsontable/handsontable/pull/11106)
29
+ - Fixed rows misalign for cells that content produce heights with fractions. [#11110](https://github.com/handsontable/handsontable/pull/11110)
30
+ - Fixed dropdown menu misalignment after opening with a keyboard shortcut. [#11115](https://github.com/handsontable/handsontable/pull/11115)
31
+ - Fixed a bug where the data was saved in a wrong cell, when sorting a column with an open editor. [#11129](https://github.com/handsontable/handsontable/pull/11129)
32
+ - Fixed copy/paste/cut issues when `outsideClickDeselects` was disabled [#11139](https://github.com/handsontable/handsontable/pull/11139)
33
+ - Fixed merged cells that break after adding a new row. [#11145](https://github.com/handsontable/handsontable/pull/11145)
34
+ - Fixed F2 keyboard shortcut (enter into editing mode). [#11151](https://github.com/handsontable/handsontable/pull/11151)
35
+ - Fixed context/dropdown menu column width calculations depending on the content. [#11156](https://github.com/handsontable/handsontable/pull/11156)
36
+ - Updated TS typings for `selectCell` method. [#11161](https://github.com/handsontable/handsontable/pull/11161)
37
+ - Fixed a problem with deleting content from a selection when it contained both `checkbox` and non-`checkbox`-typed cells. [#11182](https://github.com/handsontable/handsontable/pull/11182)
38
+ - Fixed a problem where the Context Menu container wasn't reflecting the size of its contents. [#11190](https://github.com/handsontable/handsontable/pull/11190)
39
+ - Fixed an issue connected with throwing an error triggered by some keyboard shortcuts when there was no selection [#11195](https://github.com/handsontable/handsontable/pull/11195)
40
+
12
41
  ## [14.5.0] - 2024-07-24
13
42
 
14
43
  ### Added
package/base.js CHANGED
@@ -45,8 +45,8 @@ Handsontable.hooks = _pluginHooks.default.getSingleton();
45
45
  Handsontable.CellCoords = _src.CellCoords;
46
46
  Handsontable.CellRange = _src.CellRange;
47
47
  Handsontable.packageName = 'handsontable';
48
- Handsontable.buildDate = "30/07/2024 09:10:59";
49
- Handsontable.version = "14.5.0-next-2d9f0a9-20240730";
48
+ Handsontable.buildDate = "24/09/2024 11:36:15";
49
+ Handsontable.version = "14.6.0-next-4d69faf-20240924";
50
50
  Handsontable.languages = {
51
51
  dictionaryKeys: _registry.dictionaryKeys,
52
52
  getLanguageDictionary: _registry.getLanguageDictionary,
package/base.mjs CHANGED
@@ -35,8 +35,8 @@ Handsontable.hooks = Hooks.getSingleton();
35
35
  Handsontable.CellCoords = CellCoords;
36
36
  Handsontable.CellRange = CellRange;
37
37
  Handsontable.packageName = 'handsontable';
38
- Handsontable.buildDate = "30/07/2024 09:11:05";
39
- Handsontable.version = "14.5.0-next-2d9f0a9-20240730";
38
+ Handsontable.buildDate = "24/09/2024 11:36:21";
39
+ Handsontable.version = "14.6.0-next-4d69faf-20240924";
40
40
  Handsontable.languages = {
41
41
  dictionaryKeys,
42
42
  getLanguageDictionary,
package/core.d.ts CHANGED
@@ -81,8 +81,20 @@ export default class Core {
81
81
  getDataAtRowProp(row: number, prop: string): CellValue;
82
82
  getDataType(rowFrom: number, columnFrom: number, rowTo: number, columnTo: number): CellType | 'mixed';
83
83
  getDirectionFactor(): 1 | -1;
84
+ getFirstFullyVisibleColumn(): number | null;
85
+ getFirstFullyVisibleRow(): number | null;
86
+ getFirstPartiallyVisibleColumn(): number | null;
87
+ getFirstPartiallyVisibleRow(): number | null;
88
+ getFirstRenderedVisibleColumn(): number | null;
89
+ getFirstRenderedVisibleRow(): number | null;
84
90
  getFocusManager(): FocusManager;
85
91
  getInstance(): Core;
92
+ getLastFullyVisibleColumn(): number | null;
93
+ getLastFullyVisibleRow(): number | null;
94
+ getLastPartiallyVisibleColumn(): number | null;
95
+ getLastPartiallyVisibleRow(): number | null;
96
+ getLastRenderedVisibleColumn(): number | null;
97
+ getLastRenderedVisibleRow(): number | null;
86
98
  getPlugin<T extends keyof Plugins>(pluginName: T): Plugins[T];
87
99
  getPlugin(pluginName: string): Plugins['basePlugin'];
88
100
  getRowHeader(): Array<string | number>;
@@ -139,8 +151,7 @@ export default class Core {
139
151
  scrollViewportTo(row?: number, column?: number, snapToBottom?: boolean, snapToRight?: boolean, considerHiddenIndexes?: boolean): boolean;
140
152
  scrollToFocusedCell(callback?: () => void): void;
141
153
  selectAll(includeRowHeaders?: boolean, includeColumnHeaders?: boolean, options?: { focusPosition?: SimpleCellCoords | CellCoords, disableHeadersHighlight?: boolean }): void;
142
- selectCell(row: number, column: number, endRow?: number, endColumn?: number, scrollToCell?: boolean, changeListener?: boolean): boolean;
143
- selectCellByProp(row: number, prop: string, endRow?: number, endProp?: string, scrollToCell?: boolean): boolean;
154
+ selectCell(row: number, column: number | string, endRow?: number, endColumn?: number | string, scrollToCell?: boolean, changeListener?: boolean): boolean;
144
155
  selectCells(coords: Array<[number, number | string, number, number | string]> | CellRange[], scrollToCell?: boolean, changeListener?: boolean): boolean;
145
156
  selectColumns(startColumn: number | string, endColumn?: number | string, focusPosition?: number | SimpleCellCoords | CellCoords): boolean;
146
157
  selectRows(startRow: number, endRow?: number, focusPosition?: number | SimpleCellCoords | CellCoords): boolean;
package/core.js CHANGED
@@ -4,13 +4,13 @@ exports.__esModule = true;
4
4
  exports.default = Core;
5
5
  require("core-js/modules/es.error.cause.js");
6
6
  require("core-js/modules/es.array.push.js");
7
- require("core-js/modules/esnext.set.difference.v2.js");
8
- require("core-js/modules/esnext.set.intersection.v2.js");
9
- require("core-js/modules/esnext.set.is-disjoint-from.v2.js");
10
- require("core-js/modules/esnext.set.is-subset-of.v2.js");
11
- require("core-js/modules/esnext.set.is-superset-of.v2.js");
12
- require("core-js/modules/esnext.set.symmetric-difference.v2.js");
13
- require("core-js/modules/esnext.set.union.v2.js");
7
+ require("core-js/modules/es.set.difference.v2.js");
8
+ require("core-js/modules/es.set.intersection.v2.js");
9
+ require("core-js/modules/es.set.is-disjoint-from.v2.js");
10
+ require("core-js/modules/es.set.is-subset-of.v2.js");
11
+ require("core-js/modules/es.set.is-superset-of.v2.js");
12
+ require("core-js/modules/es.set.symmetric-difference.v2.js");
13
+ require("core-js/modules/es.set.union.v2.js");
14
14
  require("core-js/modules/web.immediate.js");
15
15
  var _element = require("./helpers/dom/element");
16
16
  var _function = require("./helpers/function");
@@ -2445,8 +2445,7 @@ function Core(rootElement, userSettings) {
2445
2445
  * by adding or removing rows and columns at specified positions.
2446
2446
  *
2447
2447
  * ::: tip
2448
- * The `alter()` method works only when your [`data`](@/api/options.md#data)
2449
- * is an [array of arrays](@/guides/getting-started/binding-to-data/binding-to-data.md#array-of-arrays).
2448
+ * If you use an array of objects in your [`data`](@/api/options.md#data), the column-related actions won't work.
2450
2449
  * :::
2451
2450
  *
2452
2451
  * ```js
@@ -4241,6 +4240,158 @@ function Core(rootElement, userSettings) {
4241
4240
  return editorManager.getActiveEditor();
4242
4241
  };
4243
4242
 
4243
+ /**
4244
+ * Returns the first rendered row in the DOM (usually, it is not visible in the table's viewport).
4245
+ *
4246
+ * @since 14.6.0
4247
+ * @memberof Core#
4248
+ * @function getFirstRenderedVisibleRow
4249
+ * @returns {number | null}
4250
+ */
4251
+ this.getFirstRenderedVisibleRow = function () {
4252
+ return instance.view.getFirstRenderedVisibleRow();
4253
+ };
4254
+
4255
+ /**
4256
+ * Returns the last rendered row in the DOM (usually, it is not visible in the table's viewport).
4257
+ *
4258
+ * @since 14.6.0
4259
+ * @memberof Core#
4260
+ * @function getLastRenderedVisibleRow
4261
+ * @returns {number | null}
4262
+ */
4263
+ this.getLastRenderedVisibleRow = function () {
4264
+ return instance.view.getLastRenderedVisibleRow();
4265
+ };
4266
+
4267
+ /**
4268
+ * Returns the first rendered column in the DOM (usually, it is not visible in the table's viewport).
4269
+ *
4270
+ * @since 14.6.0
4271
+ * @memberof Core#
4272
+ * @function getFirstRenderedVisibleColumn
4273
+ * @returns {number | null}
4274
+ */
4275
+ this.getFirstRenderedVisibleColumn = function () {
4276
+ return instance.view.getFirstRenderedVisibleColumn();
4277
+ };
4278
+
4279
+ /**
4280
+ * Returns the last rendered column in the DOM (usually, it is not visible in the table's viewport).
4281
+ *
4282
+ * @since 14.6.0
4283
+ * @memberof Core#
4284
+ * @function getLastRenderedVisibleColumn
4285
+ * @returns {number | null}
4286
+ */
4287
+ this.getLastRenderedVisibleColumn = function () {
4288
+ return instance.view.getLastRenderedVisibleColumn();
4289
+ };
4290
+
4291
+ /**
4292
+ * Returns the first fully visible row in the table viewport. When the table has overlays the method returns
4293
+ * the first row of the main table that is not overlapped by overlay.
4294
+ *
4295
+ * @since 14.6.0
4296
+ * @memberof Core#
4297
+ * @function getFirstFullyVisibleRow
4298
+ * @returns {number | null}
4299
+ */
4300
+ this.getFirstFullyVisibleRow = function () {
4301
+ return instance.view.getFirstFullyVisibleRow();
4302
+ };
4303
+
4304
+ /**
4305
+ * Returns the last fully visible row in the table viewport. When the table has overlays the method returns
4306
+ * the first row of the main table that is not overlapped by overlay.
4307
+ *
4308
+ * @since 14.6.0
4309
+ * @memberof Core#
4310
+ * @function getLastFullyVisibleRow
4311
+ * @returns {number | null}
4312
+ */
4313
+ this.getLastFullyVisibleRow = function () {
4314
+ return instance.view.getLastFullyVisibleRow();
4315
+ };
4316
+
4317
+ /**
4318
+ * Returns the first fully visible column in the table viewport. When the table has overlays the method returns
4319
+ * the first row of the main table that is not overlapped by overlay.
4320
+ *
4321
+ * @since 14.6.0
4322
+ * @memberof Core#
4323
+ * @function getFirstFullyVisibleColumn
4324
+ * @returns {number | null}
4325
+ */
4326
+ this.getFirstFullyVisibleColumn = function () {
4327
+ return instance.view.getFirstFullyVisibleColumn();
4328
+ };
4329
+
4330
+ /**
4331
+ * Returns the last fully visible column in the table viewport. When the table has overlays the method returns
4332
+ * the first row of the main table that is not overlapped by overlay.
4333
+ *
4334
+ * @since 14.6.0
4335
+ * @memberof Core#
4336
+ * @function getLastFullyVisibleColumn
4337
+ * @returns {number | null}
4338
+ */
4339
+ this.getLastFullyVisibleColumn = function () {
4340
+ return instance.view.getLastFullyVisibleColumn();
4341
+ };
4342
+
4343
+ /**
4344
+ * Returns the first partially visible row in the table viewport. When the table has overlays the method returns
4345
+ * the first row of the main table that is not overlapped by overlay.
4346
+ *
4347
+ * @since 14.6.0
4348
+ * @memberof Core#
4349
+ * @function getFirstPartiallyVisibleRow
4350
+ * @returns {number | null}
4351
+ */
4352
+ this.getFirstPartiallyVisibleRow = function () {
4353
+ return instance.view.getFirstPartiallyVisibleRow();
4354
+ };
4355
+
4356
+ /**
4357
+ * Returns the last partially visible row in the table viewport. When the table has overlays the method returns
4358
+ * the first row of the main table that is not overlapped by overlay.
4359
+ *
4360
+ * @since 14.6.0
4361
+ * @memberof Core#
4362
+ * @function getLastPartiallyVisibleRow
4363
+ * @returns {number | null}
4364
+ */
4365
+ this.getLastPartiallyVisibleRow = function () {
4366
+ return instance.view.getLastPartiallyVisibleRow();
4367
+ };
4368
+
4369
+ /**
4370
+ * Returns the first partially visible column in the table viewport. When the table has overlays the method returns
4371
+ * the first row of the main table that is not overlapped by overlay.
4372
+ *
4373
+ * @since 14.6.0
4374
+ * @memberof Core#
4375
+ * @function getFirstPartiallyVisibleColumn
4376
+ * @returns {number | null}
4377
+ */
4378
+ this.getFirstPartiallyVisibleColumn = function () {
4379
+ return instance.view.getFirstPartiallyVisibleColumn();
4380
+ };
4381
+
4382
+ /**
4383
+ * Returns the last partially visible column in the table viewport. When the table has overlays the method returns
4384
+ * the first row of the main table that is not overlapped by overlay.
4385
+ *
4386
+ * @since 14.6.0
4387
+ * @memberof Core#
4388
+ * @function getLastPartiallyVisibleColumn
4389
+ * @returns {number | null}
4390
+ */
4391
+ this.getLastPartiallyVisibleColumn = function () {
4392
+ return instance.view.getLastPartiallyVisibleColumn();
4393
+ };
4394
+
4244
4395
  /**
4245
4396
  * Returns plugin instance by provided its name.
4246
4397
  *
package/core.mjs CHANGED
@@ -1,12 +1,12 @@
1
1
  import "core-js/modules/es.error.cause.js";
2
2
  import "core-js/modules/es.array.push.js";
3
- import "core-js/modules/esnext.set.difference.v2.js";
4
- import "core-js/modules/esnext.set.intersection.v2.js";
5
- import "core-js/modules/esnext.set.is-disjoint-from.v2.js";
6
- import "core-js/modules/esnext.set.is-subset-of.v2.js";
7
- import "core-js/modules/esnext.set.is-superset-of.v2.js";
8
- import "core-js/modules/esnext.set.symmetric-difference.v2.js";
9
- import "core-js/modules/esnext.set.union.v2.js";
3
+ import "core-js/modules/es.set.difference.v2.js";
4
+ import "core-js/modules/es.set.intersection.v2.js";
5
+ import "core-js/modules/es.set.is-disjoint-from.v2.js";
6
+ import "core-js/modules/es.set.is-subset-of.v2.js";
7
+ import "core-js/modules/es.set.is-superset-of.v2.js";
8
+ import "core-js/modules/es.set.symmetric-difference.v2.js";
9
+ import "core-js/modules/es.set.union.v2.js";
10
10
  import "core-js/modules/web.immediate.js";
11
11
  import { addClass, empty, observeVisibilityChangeOnce, removeClass } from "./helpers/dom/element.mjs";
12
12
  import { isFunction } from "./helpers/function.mjs";
@@ -2440,8 +2440,7 @@ export default function Core(rootElement, userSettings) {
2440
2440
  * by adding or removing rows and columns at specified positions.
2441
2441
  *
2442
2442
  * ::: tip
2443
- * The `alter()` method works only when your [`data`](@/api/options.md#data)
2444
- * is an [array of arrays](@/guides/getting-started/binding-to-data/binding-to-data.md#array-of-arrays).
2443
+ * If you use an array of objects in your [`data`](@/api/options.md#data), the column-related actions won't work.
2445
2444
  * :::
2446
2445
  *
2447
2446
  * ```js
@@ -4236,6 +4235,158 @@ export default function Core(rootElement, userSettings) {
4236
4235
  return editorManager.getActiveEditor();
4237
4236
  };
4238
4237
 
4238
+ /**
4239
+ * Returns the first rendered row in the DOM (usually, it is not visible in the table's viewport).
4240
+ *
4241
+ * @since 14.6.0
4242
+ * @memberof Core#
4243
+ * @function getFirstRenderedVisibleRow
4244
+ * @returns {number | null}
4245
+ */
4246
+ this.getFirstRenderedVisibleRow = function () {
4247
+ return instance.view.getFirstRenderedVisibleRow();
4248
+ };
4249
+
4250
+ /**
4251
+ * Returns the last rendered row in the DOM (usually, it is not visible in the table's viewport).
4252
+ *
4253
+ * @since 14.6.0
4254
+ * @memberof Core#
4255
+ * @function getLastRenderedVisibleRow
4256
+ * @returns {number | null}
4257
+ */
4258
+ this.getLastRenderedVisibleRow = function () {
4259
+ return instance.view.getLastRenderedVisibleRow();
4260
+ };
4261
+
4262
+ /**
4263
+ * Returns the first rendered column in the DOM (usually, it is not visible in the table's viewport).
4264
+ *
4265
+ * @since 14.6.0
4266
+ * @memberof Core#
4267
+ * @function getFirstRenderedVisibleColumn
4268
+ * @returns {number | null}
4269
+ */
4270
+ this.getFirstRenderedVisibleColumn = function () {
4271
+ return instance.view.getFirstRenderedVisibleColumn();
4272
+ };
4273
+
4274
+ /**
4275
+ * Returns the last rendered column in the DOM (usually, it is not visible in the table's viewport).
4276
+ *
4277
+ * @since 14.6.0
4278
+ * @memberof Core#
4279
+ * @function getLastRenderedVisibleColumn
4280
+ * @returns {number | null}
4281
+ */
4282
+ this.getLastRenderedVisibleColumn = function () {
4283
+ return instance.view.getLastRenderedVisibleColumn();
4284
+ };
4285
+
4286
+ /**
4287
+ * Returns the first fully visible row in the table viewport. When the table has overlays the method returns
4288
+ * the first row of the main table that is not overlapped by overlay.
4289
+ *
4290
+ * @since 14.6.0
4291
+ * @memberof Core#
4292
+ * @function getFirstFullyVisibleRow
4293
+ * @returns {number | null}
4294
+ */
4295
+ this.getFirstFullyVisibleRow = function () {
4296
+ return instance.view.getFirstFullyVisibleRow();
4297
+ };
4298
+
4299
+ /**
4300
+ * Returns the last fully visible row in the table viewport. When the table has overlays the method returns
4301
+ * the first row of the main table that is not overlapped by overlay.
4302
+ *
4303
+ * @since 14.6.0
4304
+ * @memberof Core#
4305
+ * @function getLastFullyVisibleRow
4306
+ * @returns {number | null}
4307
+ */
4308
+ this.getLastFullyVisibleRow = function () {
4309
+ return instance.view.getLastFullyVisibleRow();
4310
+ };
4311
+
4312
+ /**
4313
+ * Returns the first fully visible column in the table viewport. When the table has overlays the method returns
4314
+ * the first row of the main table that is not overlapped by overlay.
4315
+ *
4316
+ * @since 14.6.0
4317
+ * @memberof Core#
4318
+ * @function getFirstFullyVisibleColumn
4319
+ * @returns {number | null}
4320
+ */
4321
+ this.getFirstFullyVisibleColumn = function () {
4322
+ return instance.view.getFirstFullyVisibleColumn();
4323
+ };
4324
+
4325
+ /**
4326
+ * Returns the last fully visible column in the table viewport. When the table has overlays the method returns
4327
+ * the first row of the main table that is not overlapped by overlay.
4328
+ *
4329
+ * @since 14.6.0
4330
+ * @memberof Core#
4331
+ * @function getLastFullyVisibleColumn
4332
+ * @returns {number | null}
4333
+ */
4334
+ this.getLastFullyVisibleColumn = function () {
4335
+ return instance.view.getLastFullyVisibleColumn();
4336
+ };
4337
+
4338
+ /**
4339
+ * Returns the first partially visible row in the table viewport. When the table has overlays the method returns
4340
+ * the first row of the main table that is not overlapped by overlay.
4341
+ *
4342
+ * @since 14.6.0
4343
+ * @memberof Core#
4344
+ * @function getFirstPartiallyVisibleRow
4345
+ * @returns {number | null}
4346
+ */
4347
+ this.getFirstPartiallyVisibleRow = function () {
4348
+ return instance.view.getFirstPartiallyVisibleRow();
4349
+ };
4350
+
4351
+ /**
4352
+ * Returns the last partially visible row in the table viewport. When the table has overlays the method returns
4353
+ * the first row of the main table that is not overlapped by overlay.
4354
+ *
4355
+ * @since 14.6.0
4356
+ * @memberof Core#
4357
+ * @function getLastPartiallyVisibleRow
4358
+ * @returns {number | null}
4359
+ */
4360
+ this.getLastPartiallyVisibleRow = function () {
4361
+ return instance.view.getLastPartiallyVisibleRow();
4362
+ };
4363
+
4364
+ /**
4365
+ * Returns the first partially visible column in the table viewport. When the table has overlays the method returns
4366
+ * the first row of the main table that is not overlapped by overlay.
4367
+ *
4368
+ * @since 14.6.0
4369
+ * @memberof Core#
4370
+ * @function getFirstPartiallyVisibleColumn
4371
+ * @returns {number | null}
4372
+ */
4373
+ this.getFirstPartiallyVisibleColumn = function () {
4374
+ return instance.view.getFirstPartiallyVisibleColumn();
4375
+ };
4376
+
4377
+ /**
4378
+ * Returns the last partially visible column in the table viewport. When the table has overlays the method returns
4379
+ * the first row of the main table that is not overlapped by overlay.
4380
+ *
4381
+ * @since 14.6.0
4382
+ * @memberof Core#
4383
+ * @function getLastPartiallyVisibleColumn
4384
+ * @returns {number | null}
4385
+ */
4386
+ this.getLastPartiallyVisibleColumn = function () {
4387
+ return instance.view.getLastPartiallyVisibleColumn();
4388
+ };
4389
+
4239
4390
  /**
4240
4391
  * Returns plugin instance by provided its name.
4241
4392
  *
@@ -3,13 +3,13 @@
3
3
  exports.__esModule = true;
4
4
  require("core-js/modules/es.error.cause.js");
5
5
  require("core-js/modules/es.array.push.js");
6
- require("core-js/modules/esnext.set.difference.v2.js");
7
- require("core-js/modules/esnext.set.intersection.v2.js");
8
- require("core-js/modules/esnext.set.is-disjoint-from.v2.js");
9
- require("core-js/modules/esnext.set.is-subset-of.v2.js");
10
- require("core-js/modules/esnext.set.is-superset-of.v2.js");
11
- require("core-js/modules/esnext.set.symmetric-difference.v2.js");
12
- require("core-js/modules/esnext.set.union.v2.js");
6
+ require("core-js/modules/es.set.difference.v2.js");
7
+ require("core-js/modules/es.set.intersection.v2.js");
8
+ require("core-js/modules/es.set.is-disjoint-from.v2.js");
9
+ require("core-js/modules/es.set.is-subset-of.v2.js");
10
+ require("core-js/modules/es.set.is-superset-of.v2.js");
11
+ require("core-js/modules/es.set.symmetric-difference.v2.js");
12
+ require("core-js/modules/es.set.union.v2.js");
13
13
  var _array = require("../../helpers/array");
14
14
  var _utils = require("./utils");
15
15
  function _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }
@@ -1,12 +1,12 @@
1
1
  import "core-js/modules/es.error.cause.js";
2
2
  import "core-js/modules/es.array.push.js";
3
- import "core-js/modules/esnext.set.difference.v2.js";
4
- import "core-js/modules/esnext.set.intersection.v2.js";
5
- import "core-js/modules/esnext.set.is-disjoint-from.v2.js";
6
- import "core-js/modules/esnext.set.is-subset-of.v2.js";
7
- import "core-js/modules/esnext.set.is-superset-of.v2.js";
8
- import "core-js/modules/esnext.set.symmetric-difference.v2.js";
9
- import "core-js/modules/esnext.set.union.v2.js";
3
+ import "core-js/modules/es.set.difference.v2.js";
4
+ import "core-js/modules/es.set.intersection.v2.js";
5
+ import "core-js/modules/es.set.is-disjoint-from.v2.js";
6
+ import "core-js/modules/es.set.is-subset-of.v2.js";
7
+ import "core-js/modules/es.set.is-superset-of.v2.js";
8
+ import "core-js/modules/es.set.symmetric-difference.v2.js";
9
+ import "core-js/modules/es.set.union.v2.js";
10
10
  function _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }
11
11
  function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == typeof i ? i : i + ""; }
12
12
  function _toPrimitive(t, r) { if ("object" != typeof t || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != typeof i) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }