handsontable 0.0.0-next-200799f-20240311 → 0.0.0-next-bff5041-20240315
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.
Potentially problematic release.
This version of handsontable might be problematic. Click here for more details.
- package/3rdparty/walkontable/src/calculator/viewportColumns.js +12 -17
- package/3rdparty/walkontable/src/calculator/viewportColumns.mjs +12 -17
- package/3rdparty/walkontable/src/calculator/viewportRows.js +10 -15
- package/3rdparty/walkontable/src/calculator/viewportRows.mjs +10 -15
- package/3rdparty/walkontable/src/cell/coords.js +12 -17
- package/3rdparty/walkontable/src/cell/coords.mjs +12 -17
- package/3rdparty/walkontable/src/cell/range.d.ts +0 -1
- package/3rdparty/walkontable/src/cell/range.js +23 -45
- package/3rdparty/walkontable/src/cell/range.mjs +23 -45
- package/3rdparty/walkontable/src/core/_base.js +1 -1
- package/3rdparty/walkontable/src/core/_base.mjs +1 -1
- package/3rdparty/walkontable/src/event.js +72 -104
- package/3rdparty/walkontable/src/event.mjs +72 -104
- package/3rdparty/walkontable/src/overlays.js +1 -1
- package/3rdparty/walkontable/src/overlays.mjs +1 -1
- package/3rdparty/walkontable/src/scroll.js +15 -17
- package/3rdparty/walkontable/src/scroll.mjs +15 -17
- package/3rdparty/walkontable/src/selection/manager.js +48 -69
- package/3rdparty/walkontable/src/selection/manager.mjs +48 -69
- package/3rdparty/walkontable/src/selection/scanner.js +33 -42
- package/3rdparty/walkontable/src/selection/scanner.mjs +33 -42
- package/3rdparty/walkontable/src/utils/columnStretching.js +27 -44
- package/3rdparty/walkontable/src/utils/columnStretching.mjs +27 -44
- package/3rdparty/walkontable/src/utils/orderView/view.js +1 -1
- package/3rdparty/walkontable/src/utils/orderView/view.mjs +1 -1
- package/base.js +2 -2
- package/base.mjs +2 -2
- package/core/viewportScroll/index.js +1 -4
- package/core/viewportScroll/index.mjs +1 -4
- package/core.d.ts +3 -4
- package/core.js +22 -79
- package/core.mjs +22 -79
- package/dataMap/dataSource.js +1 -1
- package/dataMap/dataSource.mjs +1 -1
- package/dataMap/metaManager/metaLayers/cellMeta.js +1 -1
- package/dataMap/metaManager/metaLayers/cellMeta.mjs +1 -1
- package/dataMap/replaceData.js +1 -1
- package/dataMap/replaceData.mjs +1 -1
- package/dist/handsontable.css +2 -2
- package/dist/handsontable.full.css +2 -2
- package/dist/handsontable.full.js +7620 -10327
- package/dist/handsontable.full.min.css +2 -2
- package/dist/handsontable.full.min.js +277 -277
- package/dist/handsontable.js +5525 -7779
- package/dist/handsontable.min.css +2 -2
- package/dist/handsontable.min.js +33 -33
- package/dist/languages/all.min.js +1 -1
- package/dist/languages/ar-AR.min.js +1 -1
- package/dist/languages/cs-CZ.min.js +1 -1
- package/dist/languages/de-CH.min.js +1 -1
- package/dist/languages/de-DE.min.js +1 -1
- package/dist/languages/en-US.min.js +1 -1
- package/dist/languages/es-MX.min.js +1 -1
- package/dist/languages/fr-FR.min.js +1 -1
- package/dist/languages/hr-HR.min.js +1 -1
- package/dist/languages/it-IT.min.js +1 -1
- package/dist/languages/ja-JP.min.js +1 -1
- package/dist/languages/ko-KR.min.js +1 -1
- package/dist/languages/lv-LV.min.js +1 -1
- package/dist/languages/nb-NO.min.js +1 -1
- package/dist/languages/nl-NL.min.js +1 -1
- package/dist/languages/pl-PL.min.js +1 -1
- package/dist/languages/pt-BR.min.js +1 -1
- package/dist/languages/ru-RU.min.js +1 -1
- package/dist/languages/sr-SP.min.js +1 -1
- package/dist/languages/zh-CN.min.js +1 -1
- package/dist/languages/zh-TW.min.js +1 -1
- package/editorManager.js +21 -27
- package/editorManager.mjs +21 -27
- package/editors/autocompleteEditor/autocompleteEditor.js +6 -10
- package/editors/autocompleteEditor/autocompleteEditor.mjs +6 -10
- package/eventManager.js +1 -1
- package/eventManager.mjs +1 -1
- package/focusManager.js +58 -82
- package/focusManager.mjs +58 -82
- package/helpers/dom/element.js +1 -1
- package/helpers/dom/element.mjs +1 -1
- package/helpers/mixed.js +1 -1
- package/helpers/mixed.mjs +1 -1
- package/helpers/object.js +2 -2
- package/helpers/object.mjs +2 -2
- package/index.d.ts +10 -0
- package/package.json +2 -1
- package/pluginHooks.d.ts +0 -4
- package/pluginHooks.js +2 -44
- package/pluginHooks.mjs +2 -44
- package/plugins/autoColumnSize/autoColumnSize.js +49 -65
- package/plugins/autoColumnSize/autoColumnSize.mjs +49 -65
- package/plugins/autoRowSize/autoRowSize.js +28 -34
- package/plugins/autoRowSize/autoRowSize.mjs +28 -34
- package/plugins/autofill/autofill.js +30 -38
- package/plugins/autofill/autofill.mjs +30 -38
- package/plugins/base/base.js +12 -17
- package/plugins/base/base.mjs +12 -17
- package/plugins/bindRowsWithHeaders/bindRowsWithHeaders.js +5 -5
- package/plugins/bindRowsWithHeaders/bindRowsWithHeaders.mjs +5 -5
- package/plugins/collapsibleColumns/collapsibleColumns.js +36 -54
- package/plugins/collapsibleColumns/collapsibleColumns.mjs +36 -54
- package/plugins/columnSorting/columnSorting.js +40 -46
- package/plugins/columnSorting/columnSorting.mjs +40 -46
- package/plugins/columnSummary/columnSummary.js +22 -26
- package/plugins/columnSummary/columnSummary.mjs +22 -26
- package/plugins/comments/comments.js +116 -158
- package/plugins/comments/comments.mjs +116 -158
- package/plugins/contextMenu/contextMenu.js +20 -26
- package/plugins/contextMenu/contextMenu.mjs +20 -26
- package/plugins/contextMenu/itemsFactory.js +1 -1
- package/plugins/contextMenu/itemsFactory.mjs +1 -1
- package/plugins/contextMenu/menu/defaultShortcutsList.js +10 -26
- package/plugins/contextMenu/menu/defaultShortcutsList.mjs +10 -26
- package/plugins/contextMenu/menu/menu.js +13 -21
- package/plugins/contextMenu/menu/menu.mjs +13 -21
- package/plugins/contextMenu/menu/positioner.js +41 -58
- package/plugins/contextMenu/menu/positioner.mjs +41 -58
- package/plugins/copyPaste/copyPaste.js +113 -154
- package/plugins/copyPaste/copyPaste.mjs +113 -154
- package/plugins/copyPaste/copyableRanges.js +43 -66
- package/plugins/copyPaste/copyableRanges.mjs +43 -66
- package/plugins/customBorders/customBorders.js +11 -13
- package/plugins/customBorders/customBorders.mjs +11 -13
- package/plugins/dragToScroll/dragToScroll.js +6 -6
- package/plugins/dragToScroll/dragToScroll.mjs +6 -6
- package/plugins/dropdownMenu/dropdownMenu.js +78 -100
- package/plugins/dropdownMenu/dropdownMenu.mjs +78 -100
- package/plugins/exportFile/dataProvider.js +1 -1
- package/plugins/exportFile/dataProvider.mjs +1 -1
- package/plugins/filters/component/actionBar.js +9 -9
- package/plugins/filters/component/actionBar.mjs +8 -8
- package/plugins/filters/component/condition.js +13 -15
- package/plugins/filters/component/condition.mjs +13 -15
- package/plugins/filters/component/operators.js +6 -6
- package/plugins/filters/component/operators.mjs +6 -6
- package/plugins/filters/component/value.js +24 -28
- package/plugins/filters/component/value.mjs +24 -28
- package/plugins/filters/conditionUpdateObserver.js +22 -24
- package/plugins/filters/conditionUpdateObserver.mjs +22 -24
- package/plugins/filters/dataFilter.js +1 -1
- package/plugins/filters/dataFilter.mjs +1 -1
- package/plugins/filters/filters.js +81 -95
- package/plugins/filters/filters.mjs +81 -95
- package/plugins/filters/ui/input.js +13 -19
- package/plugins/filters/ui/input.mjs +13 -19
- package/plugins/filters/ui/link.js +8 -13
- package/plugins/filters/ui/link.mjs +8 -13
- package/plugins/filters/ui/multipleSelect.js +85 -112
- package/plugins/filters/ui/multipleSelect.mjs +85 -112
- package/plugins/filters/ui/radioInput.js +12 -20
- package/plugins/filters/ui/radioInput.mjs +12 -20
- package/plugins/filters/ui/select.js +50 -72
- package/plugins/filters/ui/select.mjs +49 -71
- package/plugins/formulas/formulas.js +268 -326
- package/plugins/formulas/formulas.mjs +269 -327
- package/plugins/formulas/indexSyncer/axisSyncer.js +38 -61
- package/plugins/formulas/indexSyncer/axisSyncer.mjs +38 -61
- package/plugins/formulas/indexSyncer/index.js +25 -48
- package/plugins/formulas/indexSyncer/index.mjs +25 -48
- package/plugins/hiddenColumns/hiddenColumns.js +64 -83
- package/plugins/hiddenColumns/hiddenColumns.mjs +64 -83
- package/plugins/hiddenRows/hiddenRows.js +63 -82
- package/plugins/hiddenRows/hiddenRows.mjs +63 -82
- package/plugins/manualColumnFreeze/manualColumnFreeze.js +24 -32
- package/plugins/manualColumnFreeze/manualColumnFreeze.mjs +25 -33
- package/plugins/manualColumnMove/manualColumnMove.js +126 -170
- package/plugins/manualColumnMove/manualColumnMove.mjs +126 -170
- package/plugins/manualColumnResize/manualColumnResize.js +169 -230
- package/plugins/manualColumnResize/manualColumnResize.mjs +169 -230
- package/plugins/manualRowMove/manualRowMove.js +99 -128
- package/plugins/manualRowMove/manualRowMove.mjs +99 -128
- package/plugins/manualRowResize/manualRowResize.js +150 -209
- package/plugins/manualRowResize/manualRowResize.mjs +150 -209
- package/plugins/mergeCells/calculations/selection.js +71 -2
- package/plugins/mergeCells/calculations/selection.mjs +71 -2
- package/plugins/mergeCells/cellsCollection.js +1 -117
- package/plugins/mergeCells/cellsCollection.mjs +1 -117
- package/plugins/mergeCells/contextMenuItem/toggleMerge.js +1 -11
- package/plugins/mergeCells/contextMenuItem/toggleMerge.mjs +1 -11
- package/plugins/mergeCells/mergeCells.js +355 -595
- package/plugins/mergeCells/mergeCells.mjs +355 -595
- package/plugins/multiColumnSorting/multiColumnSorting.js +0 -6
- package/plugins/multiColumnSorting/multiColumnSorting.mjs +0 -6
- package/plugins/multipleSelectionHandles/multipleSelectionHandles.js +1 -1
- package/plugins/multipleSelectionHandles/multipleSelectionHandles.mjs +1 -1
- package/plugins/nestedHeaders/nestedHeaders.js +204 -254
- package/plugins/nestedHeaders/nestedHeaders.mjs +205 -255
- package/plugins/nestedHeaders/stateManager/headersTree.js +21 -32
- package/plugins/nestedHeaders/stateManager/headersTree.mjs +21 -32
- package/plugins/nestedHeaders/stateManager/index.js +30 -41
- package/plugins/nestedHeaders/stateManager/index.mjs +30 -41
- package/plugins/nestedHeaders/stateManager/sourceSettings.js +19 -30
- package/plugins/nestedHeaders/stateManager/sourceSettings.mjs +19 -30
- package/plugins/nestedRows/data/dataManager.js +1 -1
- package/plugins/nestedRows/data/dataManager.mjs +1 -1
- package/plugins/nestedRows/nestedRows.js +138 -179
- package/plugins/nestedRows/nestedRows.mjs +139 -180
- package/plugins/nestedRows/ui/contextMenu.js +11 -15
- package/plugins/nestedRows/ui/contextMenu.mjs +10 -14
- package/plugins/nestedRows/utils/rowMoveController.js +1 -1
- package/plugins/nestedRows/utils/rowMoveController.mjs +1 -1
- package/plugins/persistentState/storage.js +2 -2
- package/plugins/persistentState/storage.mjs +2 -2
- package/plugins/search/search.js +7 -7
- package/plugins/search/search.mjs +7 -7
- package/plugins/touchScroll/touchScroll.js +15 -19
- package/plugins/touchScroll/touchScroll.mjs +16 -20
- package/plugins/trimRows/trimRows.js +6 -6
- package/plugins/trimRows/trimRows.mjs +6 -6
- package/renderers/checkboxRenderer/checkboxRenderer.js +4 -4
- package/renderers/checkboxRenderer/checkboxRenderer.mjs +4 -4
- package/selection/highlight/highlight.js +14 -14
- package/selection/highlight/highlight.mjs +13 -13
- package/selection/highlight/visualSelection.js +2 -16
- package/selection/highlight/visualSelection.mjs +2 -16
- package/selection/selection.js +60 -252
- package/selection/selection.mjs +59 -251
- package/selection/transformation.js +101 -175
- package/selection/transformation.mjs +101 -175
- package/shortcutContexts/commands/editor/closeAndSave.js +2 -2
- package/shortcutContexts/commands/editor/closeAndSave.mjs +2 -2
- package/shortcutContexts/commands/editor/open.js +3 -18
- package/shortcutContexts/commands/editor/open.mjs +3 -18
- package/shortcutContexts/commands/extendCellsSelection/down.js +1 -1
- package/shortcutContexts/commands/extendCellsSelection/down.mjs +1 -1
- package/shortcutContexts/commands/extendCellsSelection/left.js +1 -1
- package/shortcutContexts/commands/extendCellsSelection/left.mjs +1 -1
- package/shortcutContexts/commands/extendCellsSelection/right.js +1 -1
- package/shortcutContexts/commands/extendCellsSelection/right.mjs +1 -1
- package/shortcutContexts/commands/extendCellsSelection/toColumns.js +1 -1
- package/shortcutContexts/commands/extendCellsSelection/toColumns.mjs +1 -1
- package/shortcutContexts/commands/extendCellsSelection/toMostBottom.js +1 -3
- package/shortcutContexts/commands/extendCellsSelection/toMostBottom.mjs +1 -3
- package/shortcutContexts/commands/extendCellsSelection/toMostInlineEnd.js +3 -9
- package/shortcutContexts/commands/extendCellsSelection/toMostInlineEnd.mjs +3 -9
- package/shortcutContexts/commands/extendCellsSelection/toMostInlineStart.js +3 -10
- package/shortcutContexts/commands/extendCellsSelection/toMostInlineStart.mjs +3 -10
- package/shortcutContexts/commands/extendCellsSelection/toMostLeft.js +1 -3
- package/shortcutContexts/commands/extendCellsSelection/toMostLeft.mjs +1 -3
- package/shortcutContexts/commands/extendCellsSelection/toMostRight.js +1 -3
- package/shortcutContexts/commands/extendCellsSelection/toMostRight.mjs +1 -3
- package/shortcutContexts/commands/extendCellsSelection/toMostTop.js +1 -3
- package/shortcutContexts/commands/extendCellsSelection/toMostTop.mjs +1 -3
- package/shortcutContexts/commands/extendCellsSelection/toRows.js +1 -1
- package/shortcutContexts/commands/extendCellsSelection/toRows.mjs +1 -1
- package/shortcutContexts/commands/extendCellsSelection/up.js +1 -1
- package/shortcutContexts/commands/extendCellsSelection/up.mjs +1 -1
- package/shortcutContexts/commands/moveCellSelection/inlineEnd.js +1 -6
- package/shortcutContexts/commands/moveCellSelection/inlineEnd.mjs +1 -6
- package/shortcutContexts/commands/moveCellSelection/inlineStart.js +1 -6
- package/shortcutContexts/commands/moveCellSelection/inlineStart.mjs +1 -6
- package/shortcutContexts/grid.js +2 -2
- package/shortcutContexts/grid.mjs +2 -2
- package/shortcuts/context.js +1 -2
- package/shortcuts/context.mjs +1 -2
- package/tableView.js +52 -98
- package/tableView.mjs +52 -98
- package/translations/changesObservable/observable.js +21 -38
- package/translations/changesObservable/observable.mjs +21 -38
- package/translations/changesObservable/observer.js +7 -12
- package/translations/changesObservable/observer.mjs +6 -11
- package/translations/mapCollections/aggregatedCollection.js +1 -1
- package/translations/mapCollections/aggregatedCollection.mjs +1 -1
- package/translations/maps/indexMap.js +1 -1
- package/translations/maps/indexMap.mjs +1 -1
- package/utils/dataStructures/linkedList.js +1 -6
- package/utils/dataStructures/linkedList.mjs +1 -6
- package/utils/dataStructures/tree.js +1 -1
- package/utils/dataStructures/tree.mjs +1 -1
- package/utils/interval.js +26 -44
- package/utils/interval.mjs +26 -44
- package/core/viewportScroll/scrollStrategies/focusScroll.js +0 -15
- package/core/viewportScroll/scrollStrategies/focusScroll.mjs +0 -11
- package/plugins/mergeCells/focusOrder.js +0 -258
- package/plugins/mergeCells/focusOrder.mjs +0 -253
package/focusManager.mjs
CHANGED
@@ -2,12 +2,9 @@ import "core-js/modules/es.error.cause.js";
|
|
2
2
|
function _classPrivateMethodInitSpec(obj, privateSet) { _checkPrivateRedeclaration(obj, privateSet); privateSet.add(obj); }
|
3
3
|
function _classPrivateFieldInitSpec(obj, privateMap, value) { _checkPrivateRedeclaration(obj, privateMap); privateMap.set(obj, value); }
|
4
4
|
function _checkPrivateRedeclaration(obj, privateCollection) { if (privateCollection.has(obj)) { throw new TypeError("Cannot initialize the same private elements twice on an object"); } }
|
5
|
-
function
|
6
|
-
function
|
7
|
-
function
|
8
|
-
function _classPrivateFieldSet(receiver, privateMap, value) { var descriptor = _classExtractFieldDescriptor(receiver, privateMap, "set"); _classApplyDescriptorSet(receiver, descriptor, value); return value; }
|
9
|
-
function _classExtractFieldDescriptor(receiver, privateMap, action) { if (!privateMap.has(receiver)) { throw new TypeError("attempted to " + action + " private field on non-instance"); } return privateMap.get(receiver); }
|
10
|
-
function _classApplyDescriptorSet(receiver, descriptor, value) { if (descriptor.set) { descriptor.set.call(receiver, value); } else { if (!descriptor.writable) { throw new TypeError("attempted to set read only private field"); } descriptor.value = value; } }
|
5
|
+
function _classPrivateFieldGet(s, a) { return s.get(_assertClassBrand(s, a)); }
|
6
|
+
function _classPrivateFieldSet(s, a, r) { return s.set(_assertClassBrand(s, a), r), r; }
|
7
|
+
function _assertClassBrand(e, t, n) { if ("function" == typeof e ? e === t : e.has(t)) return arguments.length < 3 ? t : n; throw new TypeError("Private element is not present on this object"); }
|
11
8
|
import { warn } from "./helpers/console.mjs";
|
12
9
|
import { isOutsideInput } from "./helpers/dom/element.mjs";
|
13
10
|
import { debounce } from "./helpers/function.mjs";
|
@@ -32,40 +29,20 @@ var _focusMode = /*#__PURE__*/new WeakMap();
|
|
32
29
|
var _refocusDelay = /*#__PURE__*/new WeakMap();
|
33
30
|
var _refocusElementGetter = /*#__PURE__*/new WeakMap();
|
34
31
|
var _debouncedSelect = /*#__PURE__*/new WeakMap();
|
35
|
-
var
|
36
|
-
var _focusCell = /*#__PURE__*/new WeakSet();
|
37
|
-
var _focusEditorElement = /*#__PURE__*/new WeakSet();
|
38
|
-
var _onUpdateSettings = /*#__PURE__*/new WeakSet();
|
32
|
+
var _FocusManager_brand = /*#__PURE__*/new WeakSet();
|
39
33
|
export class FocusManager {
|
40
34
|
constructor(hotInstance) {
|
41
35
|
var _this = this;
|
42
|
-
/**
|
43
|
-
* Update the manager configuration after calling `updateSettings`.
|
44
|
-
*
|
45
|
-
* @param {object} newSettings The new settings passed to the `updateSettings` method.
|
46
|
-
*/
|
47
|
-
_classPrivateMethodInitSpec(this, _onUpdateSettings);
|
48
|
-
/**
|
49
|
-
* Manage the browser's focus after cell selection end.
|
50
|
-
*/
|
51
|
-
_classPrivateMethodInitSpec(this, _focusEditorElement);
|
52
|
-
/**
|
53
|
-
* Manage the browser's focus after each cell selection change.
|
54
|
-
*/
|
55
|
-
_classPrivateMethodInitSpec(this, _focusCell);
|
56
36
|
/**
|
57
37
|
* Get and return the currently selected and highlighted cell/header element.
|
58
38
|
*
|
59
39
|
* @param {Function} callback Callback function to be called after the cell element is retrieved.
|
60
40
|
*/
|
61
|
-
_classPrivateMethodInitSpec(this,
|
41
|
+
_classPrivateMethodInitSpec(this, _FocusManager_brand);
|
62
42
|
/**
|
63
43
|
* The Handsontable instance.
|
64
44
|
*/
|
65
|
-
_classPrivateFieldInitSpec(this, _hot,
|
66
|
-
writable: true,
|
67
|
-
value: void 0
|
68
|
-
});
|
45
|
+
_classPrivateFieldInitSpec(this, _hot, void 0);
|
69
46
|
/**
|
70
47
|
* The currently enabled focus mode.
|
71
48
|
* Can be either:
|
@@ -76,59 +53,47 @@ export class FocusManager {
|
|
76
53
|
*
|
77
54
|
* @type {'cell' | 'mixed'}
|
78
55
|
*/
|
79
|
-
_classPrivateFieldInitSpec(this, _focusMode,
|
80
|
-
writable: true,
|
81
|
-
value: void 0
|
82
|
-
});
|
56
|
+
_classPrivateFieldInitSpec(this, _focusMode, void 0);
|
83
57
|
/**
|
84
58
|
* The delay after which the focus switches from the lastly selected cell to the active editor's `TEXTAREA`
|
85
59
|
* element if the focus mode is set to 'mixed'.
|
86
60
|
*
|
87
61
|
* @type {number}
|
88
62
|
*/
|
89
|
-
_classPrivateFieldInitSpec(this, _refocusDelay,
|
90
|
-
writable: true,
|
91
|
-
value: 50
|
92
|
-
});
|
63
|
+
_classPrivateFieldInitSpec(this, _refocusDelay, 50);
|
93
64
|
/**
|
94
65
|
* Getter function for the element to be used when refocusing the browser after a delay. If `null`, the active
|
95
66
|
* editor's `TEXTAREA` element will be used.
|
96
67
|
*
|
97
68
|
* @type {null|Function}
|
98
69
|
*/
|
99
|
-
_classPrivateFieldInitSpec(this, _refocusElementGetter,
|
100
|
-
writable: true,
|
101
|
-
value: null
|
102
|
-
});
|
70
|
+
_classPrivateFieldInitSpec(this, _refocusElementGetter, null);
|
103
71
|
/**
|
104
72
|
* Map of the debounced `select` functions.
|
105
73
|
*
|
106
74
|
* @type {Map<number, Function>}
|
107
75
|
*/
|
108
|
-
_classPrivateFieldInitSpec(this, _debouncedSelect,
|
109
|
-
writable: true,
|
110
|
-
value: new Map()
|
111
|
-
});
|
76
|
+
_classPrivateFieldInitSpec(this, _debouncedSelect, new Map());
|
112
77
|
const hotSettings = hotInstance.getSettings();
|
113
|
-
_classPrivateFieldSet(
|
114
|
-
_classPrivateFieldSet(
|
115
|
-
_classPrivateFieldGet(
|
78
|
+
_classPrivateFieldSet(_hot, this, hotInstance);
|
79
|
+
_classPrivateFieldSet(_focusMode, this, hotSettings.imeFastEdit ? FOCUS_MODES.MIXED : FOCUS_MODES.CELL);
|
80
|
+
_classPrivateFieldGet(_hot, this).addHook('afterUpdateSettings', function () {
|
116
81
|
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
|
117
82
|
args[_key] = arguments[_key];
|
118
83
|
}
|
119
|
-
return
|
84
|
+
return _assertClassBrand(_FocusManager_brand, _this, _onUpdateSettings).call(_this, ...args);
|
120
85
|
});
|
121
|
-
_classPrivateFieldGet(
|
86
|
+
_classPrivateFieldGet(_hot, this).addHook('afterSelection', function () {
|
122
87
|
for (var _len2 = arguments.length, args = new Array(_len2), _key2 = 0; _key2 < _len2; _key2++) {
|
123
88
|
args[_key2] = arguments[_key2];
|
124
89
|
}
|
125
|
-
return
|
90
|
+
return _assertClassBrand(_FocusManager_brand, _this, _focusCell).call(_this, ...args);
|
126
91
|
});
|
127
|
-
_classPrivateFieldGet(
|
92
|
+
_classPrivateFieldGet(_hot, this).addHook('afterSelectionEnd', function () {
|
128
93
|
for (var _len3 = arguments.length, args = new Array(_len3), _key3 = 0; _key3 < _len3; _key3++) {
|
129
94
|
args[_key3] = arguments[_key3];
|
130
95
|
}
|
131
|
-
return
|
96
|
+
return _assertClassBrand(_FocusManager_brand, _this, _focusEditorElement).call(_this, ...args);
|
132
97
|
});
|
133
98
|
}
|
134
99
|
|
@@ -138,7 +103,7 @@ export class FocusManager {
|
|
138
103
|
* @returns {'cell' | 'mixed'}
|
139
104
|
*/
|
140
105
|
getFocusMode() {
|
141
|
-
return _classPrivateFieldGet(
|
106
|
+
return _classPrivateFieldGet(_focusMode, this);
|
142
107
|
}
|
143
108
|
|
144
109
|
/**
|
@@ -148,7 +113,7 @@ export class FocusManager {
|
|
148
113
|
*/
|
149
114
|
setFocusMode(focusMode) {
|
150
115
|
if (Object.values(FOCUS_MODES).includes(focusMode)) {
|
151
|
-
_classPrivateFieldSet(
|
116
|
+
_classPrivateFieldSet(_focusMode, this, focusMode);
|
152
117
|
} else {
|
153
118
|
warn(`"${focusMode}" is not a valid focus mode.`);
|
154
119
|
}
|
@@ -161,7 +126,7 @@ export class FocusManager {
|
|
161
126
|
* @returns {number} Delay in milliseconds.
|
162
127
|
*/
|
163
128
|
getRefocusDelay() {
|
164
|
-
return _classPrivateFieldGet(
|
129
|
+
return _classPrivateFieldGet(_refocusDelay, this);
|
165
130
|
}
|
166
131
|
|
167
132
|
/**
|
@@ -171,7 +136,7 @@ export class FocusManager {
|
|
171
136
|
* @param {number} delay Delay in milliseconds.
|
172
137
|
*/
|
173
138
|
setRefocusDelay(delay) {
|
174
|
-
_classPrivateFieldSet(
|
139
|
+
_classPrivateFieldSet(_refocusDelay, this, delay);
|
175
140
|
}
|
176
141
|
|
177
142
|
/**
|
@@ -180,7 +145,7 @@ export class FocusManager {
|
|
180
145
|
* @param {Function} getRefocusElementFunction The refocus element getter.
|
181
146
|
*/
|
182
147
|
setRefocusElementGetter(getRefocusElementFunction) {
|
183
|
-
_classPrivateFieldSet(
|
148
|
+
_classPrivateFieldSet(_refocusElementGetter, this, getRefocusElementFunction);
|
184
149
|
}
|
185
150
|
|
186
151
|
/**
|
@@ -189,11 +154,11 @@ export class FocusManager {
|
|
189
154
|
* @returns {HTMLTextAreaElement|HTMLElement|undefined}
|
190
155
|
*/
|
191
156
|
getRefocusElement() {
|
192
|
-
if (typeof _classPrivateFieldGet(
|
193
|
-
return _classPrivateFieldGet(
|
157
|
+
if (typeof _classPrivateFieldGet(_refocusElementGetter, this) === 'function') {
|
158
|
+
return _classPrivateFieldGet(_refocusElementGetter, this).call(this);
|
194
159
|
} else {
|
195
160
|
var _classPrivateFieldGet2;
|
196
|
-
return (_classPrivateFieldGet2 = _classPrivateFieldGet(
|
161
|
+
return (_classPrivateFieldGet2 = _classPrivateFieldGet(_hot, this).getActiveEditor()) === null || _classPrivateFieldGet2 === void 0 ? void 0 : _classPrivateFieldGet2.TEXTAREA;
|
197
162
|
}
|
198
163
|
}
|
199
164
|
|
@@ -205,15 +170,15 @@ export class FocusManager {
|
|
205
170
|
focusOnHighlightedCell(selectedCell) {
|
206
171
|
const focusElement = element => {
|
207
172
|
var _classPrivateFieldGet3, _classPrivateFieldGet4;
|
208
|
-
const currentHighlightCoords = (_classPrivateFieldGet3 = _classPrivateFieldGet(
|
173
|
+
const currentHighlightCoords = (_classPrivateFieldGet3 = _classPrivateFieldGet(_hot, this).getSelectedRangeLast()) === null || _classPrivateFieldGet3 === void 0 ? void 0 : _classPrivateFieldGet3.highlight;
|
209
174
|
if (!currentHighlightCoords) {
|
210
175
|
return;
|
211
176
|
}
|
212
|
-
let elementToBeFocused = _classPrivateFieldGet(
|
177
|
+
let elementToBeFocused = _classPrivateFieldGet(_hot, this).runHooks('modifyFocusedElement', currentHighlightCoords.row, currentHighlightCoords.col, element);
|
213
178
|
if (!(elementToBeFocused instanceof HTMLElement)) {
|
214
179
|
elementToBeFocused = element;
|
215
180
|
}
|
216
|
-
if (elementToBeFocused && !((_classPrivateFieldGet4 = _classPrivateFieldGet(
|
181
|
+
if (elementToBeFocused && !((_classPrivateFieldGet4 = _classPrivateFieldGet(_hot, this).getActiveEditor()) !== null && _classPrivateFieldGet4 !== void 0 && _classPrivateFieldGet4.isOpened())) {
|
217
182
|
elementToBeFocused.focus({
|
218
183
|
preventScroll: true
|
219
184
|
});
|
@@ -222,7 +187,7 @@ export class FocusManager {
|
|
222
187
|
if (selectedCell) {
|
223
188
|
focusElement(selectedCell);
|
224
189
|
} else {
|
225
|
-
|
190
|
+
_assertClassBrand(_FocusManager_brand, this, _getSelectedCell).call(this, element => focusElement(element));
|
226
191
|
}
|
227
192
|
}
|
228
193
|
|
@@ -234,41 +199,44 @@ export class FocusManager {
|
|
234
199
|
*/
|
235
200
|
refocusToEditorTextarea() {
|
236
201
|
var _classPrivateFieldGet5;
|
237
|
-
let delay = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : _classPrivateFieldGet(
|
202
|
+
let delay = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : _classPrivateFieldGet(_refocusDelay, this);
|
238
203
|
const refocusElement = this.getRefocusElement();
|
239
204
|
|
240
205
|
// Re-focus on the editor's `TEXTAREA` element (or a predefined element) if the `imeFastEdit` option is enabled.
|
241
|
-
if (_classPrivateFieldGet(
|
242
|
-
if (!_classPrivateFieldGet(
|
243
|
-
_classPrivateFieldGet(
|
206
|
+
if (_classPrivateFieldGet(_hot, this).getSettings().imeFastEdit && !((_classPrivateFieldGet5 = _classPrivateFieldGet(_hot, this).getActiveEditor()) !== null && _classPrivateFieldGet5 !== void 0 && _classPrivateFieldGet5.isOpened()) && !!refocusElement) {
|
207
|
+
if (!_classPrivateFieldGet(_debouncedSelect, this).has(delay)) {
|
208
|
+
_classPrivateFieldGet(_debouncedSelect, this).set(delay, debounce(() => {
|
244
209
|
refocusElement.select();
|
245
210
|
}, delay));
|
246
211
|
}
|
247
|
-
_classPrivateFieldGet(
|
212
|
+
_classPrivateFieldGet(_debouncedSelect, this).get(delay)();
|
248
213
|
}
|
249
214
|
}
|
250
215
|
}
|
251
|
-
function
|
216
|
+
function _getSelectedCell(callback) {
|
252
217
|
var _classPrivateFieldGet6;
|
253
|
-
const highlight = (_classPrivateFieldGet6 = _classPrivateFieldGet(
|
254
|
-
if (!highlight || !_classPrivateFieldGet(
|
218
|
+
const highlight = (_classPrivateFieldGet6 = _classPrivateFieldGet(_hot, this).getSelectedRangeLast()) === null || _classPrivateFieldGet6 === void 0 ? void 0 : _classPrivateFieldGet6.highlight;
|
219
|
+
if (!highlight || !_classPrivateFieldGet(_hot, this).selection.isCellVisible(highlight)) {
|
255
220
|
callback(null);
|
256
221
|
return;
|
257
222
|
}
|
258
|
-
const cell = _classPrivateFieldGet(
|
223
|
+
const cell = _classPrivateFieldGet(_hot, this).getCell(highlight.row, highlight.col, true);
|
259
224
|
if (cell === null) {
|
260
|
-
_classPrivateFieldGet(
|
261
|
-
callback(_classPrivateFieldGet(
|
225
|
+
_classPrivateFieldGet(_hot, this).addHookOnce('afterScroll', () => {
|
226
|
+
callback(_classPrivateFieldGet(_hot, this).getCell(highlight.row, highlight.col, true));
|
262
227
|
});
|
263
228
|
} else {
|
264
229
|
callback(cell);
|
265
230
|
}
|
266
231
|
}
|
267
|
-
|
268
|
-
|
232
|
+
/**
|
233
|
+
* Manage the browser's focus after each cell selection change.
|
234
|
+
*/
|
235
|
+
function _focusCell() {
|
236
|
+
_assertClassBrand(_FocusManager_brand, this, _getSelectedCell).call(this, selectedCell => {
|
269
237
|
const {
|
270
238
|
activeElement
|
271
|
-
} = _classPrivateFieldGet(
|
239
|
+
} = _classPrivateFieldGet(_hot, this).rootDocument;
|
272
240
|
|
273
241
|
// Blurring the `activeElement` removes the unwanted border around the focusable element (#6877)
|
274
242
|
// and resets the `document.activeElement` property. The blurring should happen only when the
|
@@ -280,14 +248,22 @@ function _focusCell2() {
|
|
280
248
|
this.focusOnHighlightedCell(selectedCell);
|
281
249
|
});
|
282
250
|
}
|
283
|
-
|
284
|
-
|
251
|
+
/**
|
252
|
+
* Manage the browser's focus after cell selection end.
|
253
|
+
*/
|
254
|
+
function _focusEditorElement() {
|
255
|
+
_assertClassBrand(_FocusManager_brand, this, _getSelectedCell).call(this, selectedCell => {
|
285
256
|
if (this.getFocusMode() === FOCUS_MODES.MIXED && selectedCell.nodeName === 'TD') {
|
286
257
|
this.refocusToEditorTextarea();
|
287
258
|
}
|
288
259
|
});
|
289
260
|
}
|
290
|
-
|
261
|
+
/**
|
262
|
+
* Update the manager configuration after calling `updateSettings`.
|
263
|
+
*
|
264
|
+
* @param {object} newSettings The new settings passed to the `updateSettings` method.
|
265
|
+
*/
|
266
|
+
function _onUpdateSettings(newSettings) {
|
291
267
|
if (newSettings.imeFastEdit && this.getFocusMode() !== FOCUS_MODES.MIXED) {
|
292
268
|
this.setFocusMode(FOCUS_MODES.MIXED);
|
293
269
|
} else if (!newSettings.imeFastEdit && this.getFocusMode() !== FOCUS_MODES.CELL) {
|
package/helpers/dom/element.js
CHANGED
@@ -56,8 +56,8 @@ exports.selectElementIfAllowed = selectElementIfAllowed;
|
|
56
56
|
exports.setAttribute = setAttribute;
|
57
57
|
exports.setCaretPosition = setCaretPosition;
|
58
58
|
exports.setOverlayPosition = setOverlayPosition;
|
59
|
-
require("core-js/modules/es.array.push.js");
|
60
59
|
require("core-js/modules/es.error.cause.js");
|
60
|
+
require("core-js/modules/es.array.push.js");
|
61
61
|
var _string = require("../string");
|
62
62
|
var _a11y = require("../a11y");
|
63
63
|
/**
|
package/helpers/dom/element.mjs
CHANGED
package/helpers/mixed.js
CHANGED
@@ -134,7 +134,7 @@ const domMessages = {
|
|
134
134
|
function _injectProductInfo(key, element) {
|
135
135
|
const hasValidType = !isEmpty(key);
|
136
136
|
const isNonCommercial = typeof key === 'string' && key.toLowerCase() === 'non-commercial-and-evaluation';
|
137
|
-
const hotVersion = "0.0.0-next-
|
137
|
+
const hotVersion = "0.0.0-next-bff5041-20240315";
|
138
138
|
let keyValidityDate;
|
139
139
|
let consoleMessageState = 'invalid';
|
140
140
|
let domMessageState = 'invalid';
|
package/helpers/mixed.mjs
CHANGED
@@ -124,7 +124,7 @@ const domMessages = {
|
|
124
124
|
export function _injectProductInfo(key, element) {
|
125
125
|
const hasValidType = !isEmpty(key);
|
126
126
|
const isNonCommercial = typeof key === 'string' && key.toLowerCase() === 'non-commercial-and-evaluation';
|
127
|
-
const hotVersion = "0.0.0-next-
|
127
|
+
const hotVersion = "0.0.0-next-bff5041-20240315";
|
128
128
|
let keyValidityDate;
|
129
129
|
let consoleMessageState = 'invalid';
|
130
130
|
let domMessageState = 'invalid';
|
package/helpers/object.js
CHANGED
@@ -17,9 +17,9 @@ exports.isObjectEqual = isObjectEqual;
|
|
17
17
|
exports.mixin = mixin;
|
18
18
|
exports.objectEach = objectEach;
|
19
19
|
exports.setProperty = setProperty;
|
20
|
-
require("core-js/modules/es.json.stringify.js");
|
21
|
-
require("core-js/modules/es.array.push.js");
|
22
20
|
require("core-js/modules/es.error.cause.js");
|
21
|
+
require("core-js/modules/es.array.push.js");
|
22
|
+
require("core-js/modules/es.json.stringify.js");
|
23
23
|
var _array = require("./array");
|
24
24
|
/**
|
25
25
|
* Generate schema for passed object.
|
package/helpers/object.mjs
CHANGED
@@ -1,6 +1,6 @@
|
|
1
|
-
import "core-js/modules/es.json.stringify.js";
|
2
|
-
import "core-js/modules/es.array.push.js";
|
3
1
|
import "core-js/modules/es.error.cause.js";
|
2
|
+
import "core-js/modules/es.array.push.js";
|
3
|
+
import "core-js/modules/es.json.stringify.js";
|
4
4
|
import { arrayEach } from "./array.mjs";
|
5
5
|
/**
|
6
6
|
* Generate schema for passed object.
|
package/index.d.ts
CHANGED
@@ -361,6 +361,7 @@ declare namespace Handsontable {
|
|
361
361
|
export class CopyPaste extends _CopyPaste {}
|
362
362
|
export class CustomBorders extends _CustomBorders {}
|
363
363
|
export class DragToScroll extends _DragToScroll {}
|
364
|
+
export class DropdownMenu extends _DropdownMenu {}
|
364
365
|
export class ExportFile extends _ExportFile {}
|
365
366
|
export class Filters extends _Filters {}
|
366
367
|
export class Formulas extends _Formulas {}
|
@@ -378,6 +379,7 @@ declare namespace Handsontable {
|
|
378
379
|
export class NestedRows extends _NestedRows {}
|
379
380
|
export class PersistentState extends _PersistentState {}
|
380
381
|
export class Search extends _Search {}
|
382
|
+
export class TouchScroll extends _TouchScroll {}
|
381
383
|
export class TrimRows extends _TrimRows {}
|
382
384
|
export class UndoRedo extends _UndoRedo {}
|
383
385
|
|
@@ -441,6 +443,10 @@ declare namespace Handsontable {
|
|
441
443
|
export { DragToScrollSettings as Settings };
|
442
444
|
}
|
443
445
|
|
446
|
+
export namespace DropdownMenu {
|
447
|
+
export { DropdownMenuSettings as Settings };
|
448
|
+
}
|
449
|
+
|
444
450
|
export namespace ExportFile {
|
445
451
|
export { ExportFileSettings as Settings };
|
446
452
|
}
|
@@ -517,6 +523,10 @@ declare namespace Handsontable {
|
|
517
523
|
export { SearchQueryMethod };
|
518
524
|
}
|
519
525
|
|
526
|
+
export namespace TouchScroll {
|
527
|
+
export { TouchScrollSettings as Settings };
|
528
|
+
}
|
529
|
+
|
520
530
|
export namespace TrimRows {
|
521
531
|
export { TrimRowsSettings as Settings };
|
522
532
|
}
|
package/package.json
CHANGED
@@ -10,7 +10,7 @@
|
|
10
10
|
"url": "https://github.com/handsontable/handsontable/issues"
|
11
11
|
},
|
12
12
|
"author": "Handsoncode <hello@handsontable.com>",
|
13
|
-
"version": "0.0.0-next-
|
13
|
+
"version": "0.0.0-next-bff5041-20240315",
|
14
14
|
"main": "index",
|
15
15
|
"module": "index.mjs",
|
16
16
|
"jsnext:main": "index.mjs",
|
@@ -98,6 +98,7 @@
|
|
98
98
|
"string-replace-loader": "^3.1.0",
|
99
99
|
"stylelint": "^13.3.3",
|
100
100
|
"typescript": "3.8.2",
|
101
|
+
"@typescript-eslint/eslint-plugin": "^4.33.0",
|
101
102
|
"webpack": "^5.88.1",
|
102
103
|
"webpack-cli": "^5.1.4"
|
103
104
|
},
|
package/pluginHooks.d.ts
CHANGED
@@ -13,15 +13,12 @@ import {
|
|
13
13
|
DropdownMenu,
|
14
14
|
} from './plugins/dropdownMenu';
|
15
15
|
import {
|
16
|
-
ColumnSorting,
|
17
16
|
Config as ColumnSortingConfig,
|
18
17
|
} from './plugins/columnSorting';
|
19
18
|
import {
|
20
|
-
Filters,
|
21
19
|
ColumnConditions as FiltersColumnConditions,
|
22
20
|
} from './plugins/filters';
|
23
21
|
import {
|
24
|
-
UndoRedo,
|
25
22
|
Action as UndoRedoAction,
|
26
23
|
} from './plugins/undoRedo';
|
27
24
|
import {
|
@@ -133,7 +130,6 @@ export interface Events {
|
|
133
130
|
afterSelectionByProp?: (row: number, prop: string, row2: number, prop2: string, preventScrolling: { value: boolean }, selectionLayerLevel: number) => void;
|
134
131
|
afterSelectionEnd?: (row: number, column: number, row2: number, column2: number, selectionLayerLevel: number) => void;
|
135
132
|
afterSelectionEndByProp?: (row: number, prop: string, row2: number, prop2: string, selectionLayerLevel: number) => void;
|
136
|
-
afterSelectionFocusSet?: (row: number, column: number, preventScrolling: { value: boolean }) => void;
|
137
133
|
afterSelectRows?: (from: CellCoords, to: CellCoords, highlight: CellCoords) => void;
|
138
134
|
afterSetCellMeta?: (row: number, column: number, key: string, value: any) => void;
|
139
135
|
afterSetDataAtCell?: (changes: CellChange[], source?: ChangeSource) => void;
|
package/pluginHooks.js
CHANGED
@@ -1,8 +1,8 @@
|
|
1
1
|
"use strict";
|
2
2
|
|
3
3
|
exports.__esModule = true;
|
4
|
-
require("core-js/modules/es.array.push.js");
|
5
4
|
require("core-js/modules/es.error.cause.js");
|
5
|
+
require("core-js/modules/es.array.push.js");
|
6
6
|
var _array = require("./helpers/array");
|
7
7
|
var _object = require("./helpers/object");
|
8
8
|
var _string = require("./helpers/string");
|
@@ -650,9 +650,7 @@ const REGISTERED_HOOKS = [/* eslint-disable jsdoc/require-description-complete-s
|
|
650
650
|
* @param {string} prop Selection start data source object property name.
|
651
651
|
* @param {number} row2 Selection end visual row index.
|
652
652
|
* @param {string} prop2 Selection end data source object property name.
|
653
|
-
* @param {object} preventScrolling
|
654
|
-
* Property `preventScrolling.value` expects a boolean value that
|
655
|
-
* Handsontable uses to control scroll behavior after selection.
|
653
|
+
* @param {object} preventScrolling Object with `value` property where its value change will be observed.
|
656
654
|
* @param {number} selectionLayerLevel The number which indicates what selection layer is currently modified.
|
657
655
|
* @example
|
658
656
|
* ```js
|
@@ -702,46 +700,6 @@ const REGISTERED_HOOKS = [/* eslint-disable jsdoc/require-description-complete-s
|
|
702
700
|
* @param {number} selectionLayerLevel The number which indicates what selection layer is currently modified.
|
703
701
|
*/
|
704
702
|
'afterSelectionEndByProp',
|
705
|
-
/**
|
706
|
-
* Fired after the focus position within a selected range is changed.
|
707
|
-
*
|
708
|
-
* @since 14.2.0
|
709
|
-
* @event Hooks#afterSelectionFocusSet
|
710
|
-
* @param {number} row The focus visual row index position.
|
711
|
-
* @param {number} column The focus visual column index position.
|
712
|
-
* @param {object} preventScrolling A reference to the observable object with the `value` property.
|
713
|
-
* Property `preventScrolling.value` expects a boolean value that
|
714
|
-
* Handsontable uses to control scroll behavior after selection.
|
715
|
-
* @example
|
716
|
-
* ```js
|
717
|
-
* ::: only-for javascript
|
718
|
-
* new Handsontable(element, {
|
719
|
-
* afterSelectionFocusSet: (row, column, preventScrolling) => {
|
720
|
-
* // If set to `false` (default): when focused cell selection is outside the viewport,
|
721
|
-
* // Handsontable scrolls the viewport to that cell.
|
722
|
-
* // If set to `true`: when focused cell selection is outside the viewport,
|
723
|
-
* // Handsontable doesn't scroll the viewport.
|
724
|
-
* preventScrolling.value = true;
|
725
|
-
* }
|
726
|
-
* })
|
727
|
-
* ```
|
728
|
-
* :::
|
729
|
-
*
|
730
|
-
* ::: only-for react
|
731
|
-
* ```jsx
|
732
|
-
* <HotTable
|
733
|
-
* afterSelectionFocusSet={(row, column, preventScrolling) => {
|
734
|
-
* // If set to `false` (default): when focused cell selection is outside the viewport,
|
735
|
-
* // Handsontable scrolls the viewport to that cell.
|
736
|
-
* // If set to `true`: when focused cell selection is outside the viewport,
|
737
|
-
* // Handsontable doesn't scroll the viewport.
|
738
|
-
* preventScrolling.value = true;
|
739
|
-
* }}
|
740
|
-
* />
|
741
|
-
* ```
|
742
|
-
* :::
|
743
|
-
*/
|
744
|
-
'afterSelectionFocusSet',
|
745
703
|
/**
|
746
704
|
* Fired before one or more columns are selected (e.g. During mouse header click or {@link Core#selectColumns} API call).
|
747
705
|
*
|
package/pluginHooks.mjs
CHANGED
@@ -1,5 +1,5 @@
|
|
1
|
-
import "core-js/modules/es.array.push.js";
|
2
1
|
import "core-js/modules/es.error.cause.js";
|
2
|
+
import "core-js/modules/es.array.push.js";
|
3
3
|
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
4
4
|
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == typeof i ? i : String(i); }
|
5
5
|
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); }
|
@@ -646,9 +646,7 @@ const REGISTERED_HOOKS = [/* eslint-disable jsdoc/require-description-complete-s
|
|
646
646
|
* @param {string} prop Selection start data source object property name.
|
647
647
|
* @param {number} row2 Selection end visual row index.
|
648
648
|
* @param {string} prop2 Selection end data source object property name.
|
649
|
-
* @param {object} preventScrolling
|
650
|
-
* Property `preventScrolling.value` expects a boolean value that
|
651
|
-
* Handsontable uses to control scroll behavior after selection.
|
649
|
+
* @param {object} preventScrolling Object with `value` property where its value change will be observed.
|
652
650
|
* @param {number} selectionLayerLevel The number which indicates what selection layer is currently modified.
|
653
651
|
* @example
|
654
652
|
* ```js
|
@@ -698,46 +696,6 @@ const REGISTERED_HOOKS = [/* eslint-disable jsdoc/require-description-complete-s
|
|
698
696
|
* @param {number} selectionLayerLevel The number which indicates what selection layer is currently modified.
|
699
697
|
*/
|
700
698
|
'afterSelectionEndByProp',
|
701
|
-
/**
|
702
|
-
* Fired after the focus position within a selected range is changed.
|
703
|
-
*
|
704
|
-
* @since 14.2.0
|
705
|
-
* @event Hooks#afterSelectionFocusSet
|
706
|
-
* @param {number} row The focus visual row index position.
|
707
|
-
* @param {number} column The focus visual column index position.
|
708
|
-
* @param {object} preventScrolling A reference to the observable object with the `value` property.
|
709
|
-
* Property `preventScrolling.value` expects a boolean value that
|
710
|
-
* Handsontable uses to control scroll behavior after selection.
|
711
|
-
* @example
|
712
|
-
* ```js
|
713
|
-
* ::: only-for javascript
|
714
|
-
* new Handsontable(element, {
|
715
|
-
* afterSelectionFocusSet: (row, column, preventScrolling) => {
|
716
|
-
* // If set to `false` (default): when focused cell selection is outside the viewport,
|
717
|
-
* // Handsontable scrolls the viewport to that cell.
|
718
|
-
* // If set to `true`: when focused cell selection is outside the viewport,
|
719
|
-
* // Handsontable doesn't scroll the viewport.
|
720
|
-
* preventScrolling.value = true;
|
721
|
-
* }
|
722
|
-
* })
|
723
|
-
* ```
|
724
|
-
* :::
|
725
|
-
*
|
726
|
-
* ::: only-for react
|
727
|
-
* ```jsx
|
728
|
-
* <HotTable
|
729
|
-
* afterSelectionFocusSet={(row, column, preventScrolling) => {
|
730
|
-
* // If set to `false` (default): when focused cell selection is outside the viewport,
|
731
|
-
* // Handsontable scrolls the viewport to that cell.
|
732
|
-
* // If set to `true`: when focused cell selection is outside the viewport,
|
733
|
-
* // Handsontable doesn't scroll the viewport.
|
734
|
-
* preventScrolling.value = true;
|
735
|
-
* }}
|
736
|
-
* />
|
737
|
-
* ```
|
738
|
-
* :::
|
739
|
-
*/
|
740
|
-
'afterSelectionFocusSet',
|
741
699
|
/**
|
742
700
|
* Fired before one or more columns are selected (e.g. During mouse header click or {@link Core#selectColumns} API call).
|
743
701
|
*
|