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
@@ -1,11 +1,9 @@
|
|
1
1
|
import "core-js/modules/es.error.cause.js";
|
2
2
|
function _classPrivateFieldInitSpec(obj, privateMap, value) { _checkPrivateRedeclaration(obj, privateMap); privateMap.set(obj, value); }
|
3
3
|
function _checkPrivateRedeclaration(obj, privateCollection) { if (privateCollection.has(obj)) { throw new TypeError("Cannot initialize the same private elements twice on an object"); } }
|
4
|
-
function _classPrivateFieldGet(
|
5
|
-
function
|
6
|
-
function
|
7
|
-
function _classExtractFieldDescriptor(receiver, privateMap, action) { if (!privateMap.has(receiver)) { throw new TypeError("attempted to " + action + " private field on non-instance"); } return privateMap.get(receiver); }
|
8
|
-
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; } }
|
4
|
+
function _classPrivateFieldGet(s, a) { return s.get(_assertClassBrand(s, a)); }
|
5
|
+
function _classPrivateFieldSet(s, a, r) { return s.set(_assertClassBrand(s, a), r), r; }
|
6
|
+
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"); }
|
9
7
|
import { closestDown, hasClass, isChildOf, getParent } from "../../../helpers/dom/element.mjs";
|
10
8
|
import { partial } from "../../../helpers/function.mjs";
|
11
9
|
import { isTouchSupported } from "../../../helpers/feature.mjs";
|
@@ -36,35 +34,17 @@ class Event {
|
|
36
34
|
*/
|
37
35
|
constructor(facadeGetter, domBindings, wtSettings, eventManager, wtTable, selectionManager) {
|
38
36
|
let parent = arguments.length > 6 && arguments[6] !== undefined ? arguments[6] : null;
|
39
|
-
_classPrivateFieldInitSpec(this, _wtSettings,
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
_classPrivateFieldInitSpec(this,
|
44
|
-
writable: true,
|
45
|
-
value: void 0
|
46
|
-
});
|
47
|
-
_classPrivateFieldInitSpec(this, _wtTable, {
|
48
|
-
writable: true,
|
49
|
-
value: void 0
|
50
|
-
});
|
51
|
-
_classPrivateFieldInitSpec(this, _selectionManager, {
|
52
|
-
writable: true,
|
53
|
-
value: void 0
|
54
|
-
});
|
55
|
-
_classPrivateFieldInitSpec(this, _parent, {
|
56
|
-
writable: true,
|
57
|
-
value: void 0
|
58
|
-
});
|
37
|
+
_classPrivateFieldInitSpec(this, _wtSettings, void 0);
|
38
|
+
_classPrivateFieldInitSpec(this, _domBindings, void 0);
|
39
|
+
_classPrivateFieldInitSpec(this, _wtTable, void 0);
|
40
|
+
_classPrivateFieldInitSpec(this, _selectionManager, void 0);
|
41
|
+
_classPrivateFieldInitSpec(this, _parent, void 0);
|
59
42
|
/**
|
60
43
|
* Instance of {@link EventManager}.
|
61
44
|
*
|
62
45
|
* @type {EventManager}
|
63
46
|
*/
|
64
|
-
_classPrivateFieldInitSpec(this, _eventManager,
|
65
|
-
writable: true,
|
66
|
-
value: void 0
|
67
|
-
});
|
47
|
+
_classPrivateFieldInitSpec(this, _eventManager, void 0);
|
68
48
|
/**
|
69
49
|
* Should be use only for passing face called external origin methods, like registered event listeners.
|
70
50
|
* It provides backward compatibility by getting instance facade.
|
@@ -75,38 +55,26 @@ class Event {
|
|
75
55
|
*
|
76
56
|
* @type {FacadeGetter}
|
77
57
|
*/
|
78
|
-
_classPrivateFieldInitSpec(this, _facadeGetter,
|
79
|
-
writable: true,
|
80
|
-
value: void 0
|
81
|
-
});
|
58
|
+
_classPrivateFieldInitSpec(this, _facadeGetter, void 0);
|
82
59
|
/**
|
83
60
|
* @type {boolean}
|
84
61
|
*/
|
85
|
-
_classPrivateFieldInitSpec(this, _selectedCellBeforeTouchEnd,
|
86
|
-
writable: true,
|
87
|
-
value: void 0
|
88
|
-
});
|
62
|
+
_classPrivateFieldInitSpec(this, _selectedCellBeforeTouchEnd, void 0);
|
89
63
|
/**
|
90
64
|
* @type {number[]}
|
91
65
|
*/
|
92
|
-
_classPrivateFieldInitSpec(this, _dblClickTimeout,
|
93
|
-
writable: true,
|
94
|
-
value: [null, null]
|
95
|
-
});
|
66
|
+
_classPrivateFieldInitSpec(this, _dblClickTimeout, [null, null]);
|
96
67
|
/**
|
97
68
|
* @type {number[]}
|
98
69
|
*/
|
99
|
-
_classPrivateFieldInitSpec(this, _dblClickOrigin,
|
100
|
-
|
101
|
-
|
102
|
-
|
103
|
-
_classPrivateFieldSet(
|
104
|
-
_classPrivateFieldSet(
|
105
|
-
_classPrivateFieldSet(
|
106
|
-
_classPrivateFieldSet(
|
107
|
-
_classPrivateFieldSet(this, _parent, parent);
|
108
|
-
_classPrivateFieldSet(this, _eventManager, eventManager);
|
109
|
-
_classPrivateFieldSet(this, _facadeGetter, facadeGetter);
|
70
|
+
_classPrivateFieldInitSpec(this, _dblClickOrigin, [null, null]);
|
71
|
+
_classPrivateFieldSet(_wtSettings, this, wtSettings);
|
72
|
+
_classPrivateFieldSet(_domBindings, this, domBindings);
|
73
|
+
_classPrivateFieldSet(_wtTable, this, wtTable);
|
74
|
+
_classPrivateFieldSet(_selectionManager, this, selectionManager);
|
75
|
+
_classPrivateFieldSet(_parent, this, parent);
|
76
|
+
_classPrivateFieldSet(_eventManager, this, eventManager);
|
77
|
+
_classPrivateFieldSet(_facadeGetter, this, facadeGetter);
|
110
78
|
this.registerEvents();
|
111
79
|
}
|
112
80
|
|
@@ -116,32 +84,32 @@ class Event {
|
|
116
84
|
* @private
|
117
85
|
*/
|
118
86
|
registerEvents() {
|
119
|
-
_classPrivateFieldGet(
|
120
|
-
_classPrivateFieldGet(
|
121
|
-
_classPrivateFieldGet(
|
87
|
+
_classPrivateFieldGet(_eventManager, this).addEventListener(_classPrivateFieldGet(_wtTable, this).holder, 'contextmenu', event => this.onContextMenu(event));
|
88
|
+
_classPrivateFieldGet(_eventManager, this).addEventListener(_classPrivateFieldGet(_wtTable, this).TABLE, 'mouseover', event => this.onMouseOver(event));
|
89
|
+
_classPrivateFieldGet(_eventManager, this).addEventListener(_classPrivateFieldGet(_wtTable, this).TABLE, 'mouseout', event => this.onMouseOut(event));
|
122
90
|
const initTouchEvents = () => {
|
123
|
-
_classPrivateFieldGet(
|
124
|
-
_classPrivateFieldGet(
|
91
|
+
_classPrivateFieldGet(_eventManager, this).addEventListener(_classPrivateFieldGet(_wtTable, this).holder, 'touchstart', event => this.onTouchStart(event));
|
92
|
+
_classPrivateFieldGet(_eventManager, this).addEventListener(_classPrivateFieldGet(_wtTable, this).holder, 'touchend', event => this.onTouchEnd(event));
|
125
93
|
if (!this.momentumScrolling) {
|
126
94
|
this.momentumScrolling = {};
|
127
95
|
}
|
128
|
-
_classPrivateFieldGet(
|
96
|
+
_classPrivateFieldGet(_eventManager, this).addEventListener(_classPrivateFieldGet(_wtTable, this).holder, 'scroll', () => {
|
129
97
|
clearTimeout(this.momentumScrolling._timeout);
|
130
98
|
if (!this.momentumScrolling.ongoing) {
|
131
|
-
_classPrivateFieldGet(
|
99
|
+
_classPrivateFieldGet(_wtSettings, this).getSetting('onBeforeTouchScroll');
|
132
100
|
}
|
133
101
|
this.momentumScrolling.ongoing = true;
|
134
102
|
this.momentumScrolling._timeout = setTimeout(() => {
|
135
103
|
if (!this.touchApplied) {
|
136
104
|
this.momentumScrolling.ongoing = false;
|
137
|
-
_classPrivateFieldGet(
|
105
|
+
_classPrivateFieldGet(_wtSettings, this).getSetting('onAfterMomentumScroll');
|
138
106
|
}
|
139
107
|
}, 200);
|
140
108
|
});
|
141
109
|
};
|
142
110
|
const initMouseEvents = () => {
|
143
|
-
_classPrivateFieldGet(
|
144
|
-
_classPrivateFieldGet(
|
111
|
+
_classPrivateFieldGet(_eventManager, this).addEventListener(_classPrivateFieldGet(_wtTable, this).holder, 'mouseup', event => this.onMouseUp(event));
|
112
|
+
_classPrivateFieldGet(_eventManager, this).addEventListener(_classPrivateFieldGet(_wtTable, this).holder, 'mousedown', event => this.onMouseDown(event));
|
145
113
|
};
|
146
114
|
if (isMobileBrowser()) {
|
147
115
|
initTouchEvents();
|
@@ -164,9 +132,9 @@ class Event {
|
|
164
132
|
selectedCellWasTouched(touchTarget) {
|
165
133
|
const cellUnderFinger = this.parentCell(touchTarget);
|
166
134
|
const coordsOfCellUnderFinger = cellUnderFinger.coords;
|
167
|
-
if (_classPrivateFieldGet(
|
168
|
-
const [rowTouched, rowSelected] = [coordsOfCellUnderFinger.row, _classPrivateFieldGet(
|
169
|
-
const [colTouched, colSelected] = [coordsOfCellUnderFinger.col, _classPrivateFieldGet(
|
135
|
+
if (_classPrivateFieldGet(_selectedCellBeforeTouchEnd, this) && coordsOfCellUnderFinger) {
|
136
|
+
const [rowTouched, rowSelected] = [coordsOfCellUnderFinger.row, _classPrivateFieldGet(_selectedCellBeforeTouchEnd, this).from.row];
|
137
|
+
const [colTouched, colSelected] = [coordsOfCellUnderFinger.col, _classPrivateFieldGet(_selectedCellBeforeTouchEnd, this).from.col];
|
170
138
|
return rowTouched === rowSelected && colTouched === colSelected;
|
171
139
|
}
|
172
140
|
return false;
|
@@ -181,18 +149,18 @@ class Event {
|
|
181
149
|
*/
|
182
150
|
parentCell(elem) {
|
183
151
|
const cell = {};
|
184
|
-
const TABLE = _classPrivateFieldGet(
|
152
|
+
const TABLE = _classPrivateFieldGet(_wtTable, this).TABLE;
|
185
153
|
const TD = closestDown(elem, ['TD', 'TH'], TABLE);
|
186
154
|
if (TD) {
|
187
|
-
cell.coords = _classPrivateFieldGet(
|
155
|
+
cell.coords = _classPrivateFieldGet(_wtTable, this).getCoords(TD);
|
188
156
|
cell.TD = TD;
|
189
157
|
} else if (hasClass(elem, 'wtBorder') && hasClass(elem, 'current')) {
|
190
|
-
cell.coords = _classPrivateFieldGet(
|
191
|
-
cell.TD = _classPrivateFieldGet(
|
158
|
+
cell.coords = _classPrivateFieldGet(_selectionManager, this).getFocusSelection().cellRange.highlight;
|
159
|
+
cell.TD = _classPrivateFieldGet(_wtTable, this).getCell(cell.coords);
|
192
160
|
} else if (hasClass(elem, 'wtBorder') && hasClass(elem, 'area')) {
|
193
|
-
if (_classPrivateFieldGet(
|
194
|
-
cell.coords = _classPrivateFieldGet(
|
195
|
-
cell.TD = _classPrivateFieldGet(
|
161
|
+
if (_classPrivateFieldGet(_selectionManager, this).getAreaSelection().cellRange) {
|
162
|
+
cell.coords = _classPrivateFieldGet(_selectionManager, this).getAreaSelection().cellRange.to;
|
163
|
+
cell.TD = _classPrivateFieldGet(_wtTable, this).getCell(cell.coords);
|
196
164
|
}
|
197
165
|
}
|
198
166
|
return cell;
|
@@ -205,7 +173,7 @@ class Event {
|
|
205
173
|
* @param {MouseEvent} event The mouse event object.
|
206
174
|
*/
|
207
175
|
onMouseDown(event) {
|
208
|
-
const activeElement = _classPrivateFieldGet(
|
176
|
+
const activeElement = _classPrivateFieldGet(_domBindings, this).rootDocument.activeElement;
|
209
177
|
const getParentNode = partial(getParent, event.target);
|
210
178
|
const realTarget = event.target;
|
211
179
|
|
@@ -216,17 +184,17 @@ class Event {
|
|
216
184
|
}
|
217
185
|
const cell = this.parentCell(realTarget);
|
218
186
|
if (hasClass(realTarget, 'corner')) {
|
219
|
-
_classPrivateFieldGet(
|
220
|
-
} else if (cell.TD && _classPrivateFieldGet(
|
187
|
+
_classPrivateFieldGet(_wtSettings, this).getSetting('onCellCornerMouseDown', event, realTarget);
|
188
|
+
} else if (cell.TD && _classPrivateFieldGet(_wtSettings, this).has('onCellMouseDown')) {
|
221
189
|
this.callListener('onCellMouseDown', event, cell.coords, cell.TD);
|
222
190
|
}
|
223
191
|
|
224
192
|
// doubleclick reacts only for left mouse button or from touch events
|
225
193
|
if ((event.button === 0 || this.touchApplied) && cell.TD) {
|
226
|
-
_classPrivateFieldGet(
|
227
|
-
clearTimeout(_classPrivateFieldGet(
|
228
|
-
_classPrivateFieldGet(
|
229
|
-
_classPrivateFieldGet(
|
194
|
+
_classPrivateFieldGet(_dblClickOrigin, this)[0] = cell.TD;
|
195
|
+
clearTimeout(_classPrivateFieldGet(_dblClickTimeout, this)[0]);
|
196
|
+
_classPrivateFieldGet(_dblClickTimeout, this)[0] = setTimeout(() => {
|
197
|
+
_classPrivateFieldGet(_dblClickOrigin, this)[0] = null;
|
230
198
|
}, 1000);
|
231
199
|
}
|
232
200
|
}
|
@@ -238,7 +206,7 @@ class Event {
|
|
238
206
|
* @param {MouseEvent} event The mouse event object.
|
239
207
|
*/
|
240
208
|
onContextMenu(event) {
|
241
|
-
if (_classPrivateFieldGet(
|
209
|
+
if (_classPrivateFieldGet(_wtSettings, this).has('onCellContextMenu')) {
|
242
210
|
const cell = this.parentCell(event.target);
|
243
211
|
if (cell.TD) {
|
244
212
|
this.callListener('onCellContextMenu', event, cell.coords, cell.TD);
|
@@ -253,15 +221,15 @@ class Event {
|
|
253
221
|
* @param {MouseEvent} event The mouse event object.
|
254
222
|
*/
|
255
223
|
onMouseOver(event) {
|
256
|
-
if (!_classPrivateFieldGet(
|
224
|
+
if (!_classPrivateFieldGet(_wtSettings, this).has('onCellMouseOver')) {
|
257
225
|
return;
|
258
226
|
}
|
259
|
-
const table = _classPrivateFieldGet(
|
227
|
+
const table = _classPrivateFieldGet(_wtTable, this).TABLE;
|
260
228
|
const td = closestDown(event.target, ['TD', 'TH'], table);
|
261
|
-
const parent = _classPrivateFieldGet(
|
229
|
+
const parent = _classPrivateFieldGet(_parent, this) || this;
|
262
230
|
if (td && td !== parent.lastMouseOver && isChildOf(td, table)) {
|
263
231
|
parent.lastMouseOver = td;
|
264
|
-
this.callListener('onCellMouseOver', event, _classPrivateFieldGet(
|
232
|
+
this.callListener('onCellMouseOver', event, _classPrivateFieldGet(_wtTable, this).getCoords(td), td);
|
265
233
|
}
|
266
234
|
}
|
267
235
|
|
@@ -272,15 +240,15 @@ class Event {
|
|
272
240
|
* @param {MouseEvent} event The mouse event object.
|
273
241
|
*/
|
274
242
|
onMouseOut(event) {
|
275
|
-
if (!_classPrivateFieldGet(
|
243
|
+
if (!_classPrivateFieldGet(_wtSettings, this).has('onCellMouseOut')) {
|
276
244
|
return;
|
277
245
|
}
|
278
|
-
const table = _classPrivateFieldGet(
|
246
|
+
const table = _classPrivateFieldGet(_wtTable, this).TABLE;
|
279
247
|
const lastTD = closestDown(event.target, ['TD', 'TH'], table);
|
280
248
|
const nextTD = closestDown(event.relatedTarget, ['TD', 'TH'], table);
|
281
|
-
const parent = _classPrivateFieldGet(
|
249
|
+
const parent = _classPrivateFieldGet(_parent, this) || this;
|
282
250
|
if (lastTD && lastTD !== nextTD && isChildOf(lastTD, table)) {
|
283
|
-
this.callListener('onCellMouseOut', event, _classPrivateFieldGet(
|
251
|
+
this.callListener('onCellMouseOut', event, _classPrivateFieldGet(_wtTable, this).getCoords(lastTD), lastTD);
|
284
252
|
if (nextTD === null) {
|
285
253
|
parent.lastMouseOver = null;
|
286
254
|
}
|
@@ -295,7 +263,7 @@ class Event {
|
|
295
263
|
*/
|
296
264
|
onMouseUp(event) {
|
297
265
|
const cell = this.parentCell(event.target);
|
298
|
-
if (cell.TD && _classPrivateFieldGet(
|
266
|
+
if (cell.TD && _classPrivateFieldGet(_wtSettings, this).has('onCellMouseUp')) {
|
299
267
|
this.callListener('onCellMouseUp', event, cell.coords, cell.TD);
|
300
268
|
}
|
301
269
|
|
@@ -303,19 +271,19 @@ class Event {
|
|
303
271
|
if (event.button !== 0 && !this.touchApplied) {
|
304
272
|
return;
|
305
273
|
}
|
306
|
-
if (cell.TD === _classPrivateFieldGet(
|
274
|
+
if (cell.TD === _classPrivateFieldGet(_dblClickOrigin, this)[0] && cell.TD === _classPrivateFieldGet(_dblClickOrigin, this)[1]) {
|
307
275
|
if (hasClass(event.target, 'corner')) {
|
308
276
|
this.callListener('onCellCornerDblClick', event, cell.coords, cell.TD);
|
309
277
|
} else {
|
310
278
|
this.callListener('onCellDblClick', event, cell.coords, cell.TD);
|
311
279
|
}
|
312
|
-
_classPrivateFieldGet(
|
313
|
-
_classPrivateFieldGet(
|
314
|
-
} else if (cell.TD === _classPrivateFieldGet(
|
315
|
-
_classPrivateFieldGet(
|
316
|
-
clearTimeout(_classPrivateFieldGet(
|
317
|
-
_classPrivateFieldGet(
|
318
|
-
_classPrivateFieldGet(
|
280
|
+
_classPrivateFieldGet(_dblClickOrigin, this)[0] = null;
|
281
|
+
_classPrivateFieldGet(_dblClickOrigin, this)[1] = null;
|
282
|
+
} else if (cell.TD === _classPrivateFieldGet(_dblClickOrigin, this)[0]) {
|
283
|
+
_classPrivateFieldGet(_dblClickOrigin, this)[1] = cell.TD;
|
284
|
+
clearTimeout(_classPrivateFieldGet(_dblClickTimeout, this)[1]);
|
285
|
+
_classPrivateFieldGet(_dblClickTimeout, this)[1] = setTimeout(() => {
|
286
|
+
_classPrivateFieldGet(_dblClickOrigin, this)[1] = null;
|
319
287
|
}, 500);
|
320
288
|
}
|
321
289
|
}
|
@@ -327,7 +295,7 @@ class Event {
|
|
327
295
|
* @param {MouseEvent} event The mouse event object.
|
328
296
|
*/
|
329
297
|
onTouchStart(event) {
|
330
|
-
_classPrivateFieldSet(
|
298
|
+
_classPrivateFieldSet(_selectedCellBeforeTouchEnd, this, _classPrivateFieldGet(_selectionManager, this).getFocusSelection().cellRange);
|
331
299
|
this.touchApplied = true;
|
332
300
|
this.onMouseDown(event);
|
333
301
|
}
|
@@ -343,7 +311,7 @@ class Event {
|
|
343
311
|
const target = event.target;
|
344
312
|
const parentCellCoords = (_this$parentCell = this.parentCell(target)) === null || _this$parentCell === void 0 ? void 0 : _this$parentCell.coords;
|
345
313
|
const isCellsRange = isDefined(parentCellCoords) && parentCellCoords.row >= 0 && parentCellCoords.col >= 0;
|
346
|
-
const isEventCancelable = event.cancelable && isCellsRange && _classPrivateFieldGet(
|
314
|
+
const isEventCancelable = event.cancelable && isCellsRange && _classPrivateFieldGet(_wtSettings, this).getSetting('isDataViewInstance');
|
347
315
|
|
348
316
|
// To prevent accidental redirects or other actions that the interactive elements (e.q "A" link) do
|
349
317
|
// while the cell is highlighted, all touch events that are triggered on different cells are
|
@@ -379,9 +347,9 @@ class Event {
|
|
379
347
|
* @param {HTMLElement} target Event target.
|
380
348
|
*/
|
381
349
|
callListener(name, event, coords, target) {
|
382
|
-
const listener = _classPrivateFieldGet(
|
350
|
+
const listener = _classPrivateFieldGet(_wtSettings, this).getSettingPure(name);
|
383
351
|
if (listener) {
|
384
|
-
listener(event, coords, target, _classPrivateFieldGet(
|
352
|
+
listener(event, coords, target, _classPrivateFieldGet(_facadeGetter, this).call(this));
|
385
353
|
}
|
386
354
|
}
|
387
355
|
|
@@ -389,9 +357,9 @@ class Event {
|
|
389
357
|
* Clears double-click timeouts and destroys the internal eventManager instance.
|
390
358
|
*/
|
391
359
|
destroy() {
|
392
|
-
clearTimeout(_classPrivateFieldGet(
|
393
|
-
clearTimeout(_classPrivateFieldGet(
|
394
|
-
_classPrivateFieldGet(
|
360
|
+
clearTimeout(_classPrivateFieldGet(_dblClickTimeout, this)[0]);
|
361
|
+
clearTimeout(_classPrivateFieldGet(_dblClickTimeout, this)[1]);
|
362
|
+
_classPrivateFieldGet(_eventManager, this).destroy();
|
395
363
|
}
|
396
364
|
}
|
397
365
|
export default Event;
|
@@ -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 _element = require("../../../helpers/dom/element");
|
7
7
|
var _feature = require("../../../helpers/feature");
|
8
8
|
var _array = require("../../../helpers/array");
|
@@ -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); }
|
@@ -8,31 +8,23 @@ function _checkPrivateRedeclaration(obj, privateCollection) { if (privateCollect
|
|
8
8
|
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; }
|
9
9
|
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == typeof i ? i : String(i); }
|
10
10
|
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); }
|
11
|
-
function
|
11
|
+
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"); }
|
12
12
|
/**
|
13
13
|
* @class Scroll
|
14
14
|
*/
|
15
|
-
var
|
16
|
-
var _getLastRowIndex = /*#__PURE__*/new WeakSet();
|
15
|
+
var _Scroll_brand = /*#__PURE__*/new WeakSet();
|
17
16
|
class Scroll {
|
18
17
|
/**
|
19
18
|
* @param {ScrollDao} dataAccessObject Tha data access object.
|
20
19
|
*/
|
21
20
|
constructor(dataAccessObject) {
|
22
|
-
/**
|
23
|
-
* Get last visible row based on virtual dom and how table is visible in browser window viewport.
|
24
|
-
*
|
25
|
-
* @param {number} lastRowIndex The last visible row index.
|
26
|
-
* @returns {number}
|
27
|
-
*/
|
28
|
-
_classPrivateMethodInitSpec(this, _getLastRowIndex);
|
29
21
|
/**
|
30
22
|
* Get last visible column based on virtual dom and how table is visible in browser window viewport.
|
31
23
|
*
|
32
24
|
* @param {number} lastColumnIndex The last visible column index.
|
33
25
|
* @returns {number}
|
34
26
|
*/
|
35
|
-
_classPrivateMethodInitSpec(this,
|
27
|
+
_classPrivateMethodInitSpec(this, _Scroll_brand);
|
36
28
|
/**
|
37
29
|
* The data access object.
|
38
30
|
*
|
@@ -163,7 +155,7 @@ class Scroll {
|
|
163
155
|
* @returns {number}
|
164
156
|
*/
|
165
157
|
getLastVisibleRow() {
|
166
|
-
return
|
158
|
+
return _assertClassBrand(_Scroll_brand, this, _getLastRowIndex).call(this, this.dataAccessObject.wtTable.getLastVisibleRow());
|
167
159
|
}
|
168
160
|
|
169
161
|
/**
|
@@ -181,7 +173,7 @@ class Scroll {
|
|
181
173
|
* @returns {number}
|
182
174
|
*/
|
183
175
|
getLastPartiallyVisibleRow() {
|
184
|
-
return
|
176
|
+
return _assertClassBrand(_Scroll_brand, this, _getLastRowIndex).call(this, this.dataAccessObject.wtTable.getLastPartiallyVisibleRow());
|
185
177
|
}
|
186
178
|
|
187
179
|
/**
|
@@ -199,7 +191,7 @@ class Scroll {
|
|
199
191
|
* @returns {number}
|
200
192
|
*/
|
201
193
|
getLastVisibleColumn() {
|
202
|
-
return
|
194
|
+
return _assertClassBrand(_Scroll_brand, this, _getLastColumnIndex).call(this, this.dataAccessObject.wtTable.getLastVisibleColumn());
|
203
195
|
}
|
204
196
|
|
205
197
|
/**
|
@@ -217,10 +209,10 @@ class Scroll {
|
|
217
209
|
* @returns {number}
|
218
210
|
*/
|
219
211
|
getLastPartiallyVisibleColumn() {
|
220
|
-
return
|
212
|
+
return _assertClassBrand(_Scroll_brand, this, _getLastColumnIndex).call(this, this.dataAccessObject.wtTable.getLastPartiallyVisibleColumn());
|
221
213
|
}
|
222
214
|
}
|
223
|
-
function
|
215
|
+
function _getLastColumnIndex(lastColumnIndex) {
|
224
216
|
const {
|
225
217
|
wtSettings,
|
226
218
|
inlineStartOverlay,
|
@@ -259,7 +251,13 @@ function _getLastColumnIndex2(lastColumnIndex) {
|
|
259
251
|
}
|
260
252
|
return lastColumnIndex;
|
261
253
|
}
|
262
|
-
|
254
|
+
/**
|
255
|
+
* Get last visible row based on virtual dom and how table is visible in browser window viewport.
|
256
|
+
*
|
257
|
+
* @param {number} lastRowIndex The last visible row index.
|
258
|
+
* @returns {number}
|
259
|
+
*/
|
260
|
+
function _getLastRowIndex(lastRowIndex) {
|
263
261
|
const {
|
264
262
|
topOverlay,
|
265
263
|
wtTable,
|
@@ -4,32 +4,24 @@ function _checkPrivateRedeclaration(obj, privateCollection) { if (privateCollect
|
|
4
4
|
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; }
|
5
5
|
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == typeof i ? i : String(i); }
|
6
6
|
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); }
|
7
|
-
function
|
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"); }
|
8
8
|
import { innerHeight, innerWidth, getScrollLeft, getScrollTop, offset } from "../../../helpers/dom/element.mjs";
|
9
9
|
/**
|
10
10
|
* @class Scroll
|
11
11
|
*/
|
12
|
-
var
|
13
|
-
var _getLastRowIndex = /*#__PURE__*/new WeakSet();
|
12
|
+
var _Scroll_brand = /*#__PURE__*/new WeakSet();
|
14
13
|
class Scroll {
|
15
14
|
/**
|
16
15
|
* @param {ScrollDao} dataAccessObject Tha data access object.
|
17
16
|
*/
|
18
17
|
constructor(dataAccessObject) {
|
19
|
-
/**
|
20
|
-
* Get last visible row based on virtual dom and how table is visible in browser window viewport.
|
21
|
-
*
|
22
|
-
* @param {number} lastRowIndex The last visible row index.
|
23
|
-
* @returns {number}
|
24
|
-
*/
|
25
|
-
_classPrivateMethodInitSpec(this, _getLastRowIndex);
|
26
18
|
/**
|
27
19
|
* Get last visible column based on virtual dom and how table is visible in browser window viewport.
|
28
20
|
*
|
29
21
|
* @param {number} lastColumnIndex The last visible column index.
|
30
22
|
* @returns {number}
|
31
23
|
*/
|
32
|
-
_classPrivateMethodInitSpec(this,
|
24
|
+
_classPrivateMethodInitSpec(this, _Scroll_brand);
|
33
25
|
/**
|
34
26
|
* The data access object.
|
35
27
|
*
|
@@ -160,7 +152,7 @@ class Scroll {
|
|
160
152
|
* @returns {number}
|
161
153
|
*/
|
162
154
|
getLastVisibleRow() {
|
163
|
-
return
|
155
|
+
return _assertClassBrand(_Scroll_brand, this, _getLastRowIndex).call(this, this.dataAccessObject.wtTable.getLastVisibleRow());
|
164
156
|
}
|
165
157
|
|
166
158
|
/**
|
@@ -178,7 +170,7 @@ class Scroll {
|
|
178
170
|
* @returns {number}
|
179
171
|
*/
|
180
172
|
getLastPartiallyVisibleRow() {
|
181
|
-
return
|
173
|
+
return _assertClassBrand(_Scroll_brand, this, _getLastRowIndex).call(this, this.dataAccessObject.wtTable.getLastPartiallyVisibleRow());
|
182
174
|
}
|
183
175
|
|
184
176
|
/**
|
@@ -196,7 +188,7 @@ class Scroll {
|
|
196
188
|
* @returns {number}
|
197
189
|
*/
|
198
190
|
getLastVisibleColumn() {
|
199
|
-
return
|
191
|
+
return _assertClassBrand(_Scroll_brand, this, _getLastColumnIndex).call(this, this.dataAccessObject.wtTable.getLastVisibleColumn());
|
200
192
|
}
|
201
193
|
|
202
194
|
/**
|
@@ -214,10 +206,10 @@ class Scroll {
|
|
214
206
|
* @returns {number}
|
215
207
|
*/
|
216
208
|
getLastPartiallyVisibleColumn() {
|
217
|
-
return
|
209
|
+
return _assertClassBrand(_Scroll_brand, this, _getLastColumnIndex).call(this, this.dataAccessObject.wtTable.getLastPartiallyVisibleColumn());
|
218
210
|
}
|
219
211
|
}
|
220
|
-
function
|
212
|
+
function _getLastColumnIndex(lastColumnIndex) {
|
221
213
|
const {
|
222
214
|
wtSettings,
|
223
215
|
inlineStartOverlay,
|
@@ -256,7 +248,13 @@ function _getLastColumnIndex2(lastColumnIndex) {
|
|
256
248
|
}
|
257
249
|
return lastColumnIndex;
|
258
250
|
}
|
259
|
-
|
251
|
+
/**
|
252
|
+
* Get last visible row based on virtual dom and how table is visible in browser window viewport.
|
253
|
+
*
|
254
|
+
* @param {number} lastRowIndex The last visible row index.
|
255
|
+
* @returns {number}
|
256
|
+
*/
|
257
|
+
function _getLastRowIndex(lastRowIndex) {
|
260
258
|
const {
|
261
259
|
topOverlay,
|
262
260
|
wtTable,
|