handsontable 0.0.0-next-fad35d5-20240924 → 0.0.0-next-ffdf116-20240926
Sign up to get free protection for your applications and to get access to all the features.
Potentially problematic release.
This version of handsontable might be problematic. Click here for more details.
- package/3rdparty/walkontable/src/calculator/calculationType/renderedColumns.js +0 -23
- package/3rdparty/walkontable/src/calculator/calculationType/renderedColumns.mjs +0 -23
- package/3rdparty/walkontable/src/calculator/calculationType/renderedRows.js +0 -23
- package/3rdparty/walkontable/src/calculator/calculationType/renderedRows.mjs +0 -23
- package/3rdparty/walkontable/src/core/_base.js +0 -7
- package/3rdparty/walkontable/src/core/_base.mjs +0 -7
- package/3rdparty/walkontable/src/facade/core.js +0 -3
- package/3rdparty/walkontable/src/facade/core.mjs +0 -3
- package/3rdparty/walkontable/src/overlay/_base.js +0 -3
- package/3rdparty/walkontable/src/overlay/_base.mjs +0 -3
- package/3rdparty/walkontable/src/selection/border/border.js +45 -33
- package/3rdparty/walkontable/src/selection/border/border.mjs +46 -34
- package/3rdparty/walkontable/src/selection/scanner.js +11 -46
- package/3rdparty/walkontable/src/selection/scanner.mjs +11 -46
- package/3rdparty/walkontable/src/settings.js +0 -8
- package/3rdparty/walkontable/src/settings.mjs +0 -8
- package/3rdparty/walkontable/src/table/master.js +1 -1
- package/3rdparty/walkontable/src/table/master.mjs +2 -2
- package/3rdparty/walkontable/src/table.js +3 -6
- package/3rdparty/walkontable/src/table.mjs +3 -6
- package/3rdparty/walkontable/src/viewport.js +4 -26
- package/3rdparty/walkontable/src/viewport.mjs +4 -26
- package/base.js +4 -4
- package/base.mjs +3 -3
- package/core.d.ts +1 -1
- package/core.js +12 -13
- package/core.mjs +4 -5
- package/dataMap/metaManager/metaSchema.js +2 -68
- package/dataMap/metaManager/metaSchema.mjs +2 -68
- package/dataMap/metaManager/mods/dynamicCellMeta.js +3 -2
- package/dataMap/metaManager/mods/dynamicCellMeta.mjs +1 -1
- package/dist/handsontable.css +2 -2
- package/dist/handsontable.full.css +2 -2
- package/dist/handsontable.full.js +2685 -3046
- package/dist/handsontable.full.min.css +2 -2
- package/dist/handsontable.full.min.js +60 -60
- package/dist/handsontable.js +2687 -3048
- package/dist/handsontable.min.css +2 -2
- package/dist/handsontable.min.js +18 -18
- package/editorManager.js +2 -2
- package/editorManager.mjs +2 -2
- package/editors/autocompleteEditor/autocompleteEditor.js +31 -14
- package/editors/autocompleteEditor/autocompleteEditor.mjs +31 -14
- package/editors/baseEditor/baseEditor.js +17 -24
- package/editors/baseEditor/baseEditor.mjs +18 -25
- package/editors/dropdownEditor/dropdownEditor.js +3 -2
- package/editors/dropdownEditor/dropdownEditor.mjs +1 -1
- package/editors/handsontableEditor/handsontableEditor.js +24 -0
- package/editors/handsontableEditor/handsontableEditor.mjs +24 -0
- package/editors/registry.js +2 -2
- package/editors/registry.mjs +1 -1
- package/editors/textEditor/textEditor.js +2 -2
- package/editors/textEditor/textEditor.mjs +3 -3
- package/helpers/dom/element.js +4 -17
- package/helpers/dom/element.mjs +4 -16
- package/helpers/mixed.js +1 -1
- package/helpers/mixed.mjs +1 -1
- package/index.d.ts +1 -2
- package/package.json +1 -1
- package/{core/hooks/index.d.ts → pluginHooks.d.ts} +21 -17
- package/{core/hooks/constants.mjs → pluginHooks.js} +489 -16
- package/{core/hooks/constants.js → pluginHooks.mjs} +486 -20
- package/plugins/autoColumnSize/autoColumnSize.js +27 -18
- package/plugins/autoColumnSize/autoColumnSize.mjs +27 -18
- package/plugins/autoRowSize/autoRowSize.js +22 -16
- package/plugins/autoRowSize/autoRowSize.mjs +23 -17
- package/plugins/autofill/autofill.js +5 -4
- package/plugins/autofill/autofill.mjs +1 -1
- package/plugins/base/base.d.ts +1 -1
- package/plugins/base/base.js +0 -39
- package/plugins/base/base.mjs +1 -40
- package/plugins/base/index.js +1 -2
- package/plugins/base/index.mjs +1 -1
- package/plugins/bindRowsWithHeaders/bindRowsWithHeaders.js +5 -2
- package/plugins/bindRowsWithHeaders/bindRowsWithHeaders.mjs +5 -2
- package/plugins/columnSorting/columnSorting.js +4 -3
- package/plugins/columnSorting/columnSorting.mjs +1 -1
- package/plugins/comments/comments.js +15 -7
- package/plugins/comments/comments.mjs +16 -8
- package/plugins/contextMenu/contextMenu.js +7 -6
- package/plugins/contextMenu/contextMenu.mjs +1 -1
- package/plugins/contextMenu/menu/menu.js +1 -1
- package/plugins/contextMenu/menu/menu.mjs +2 -2
- package/plugins/contextMenu/menu/positioner.js +4 -2
- package/plugins/contextMenu/menu/positioner.mjs +4 -2
- package/plugins/copyPaste/copyPaste.js +23 -29
- package/plugins/copyPaste/copyPaste.mjs +15 -21
- package/plugins/dropdownMenu/dropdownMenu.js +7 -6
- package/plugins/dropdownMenu/dropdownMenu.mjs +1 -1
- package/plugins/formulas/formulas.js +7 -7
- package/plugins/formulas/formulas.mjs +1 -1
- package/plugins/hiddenColumns/hiddenColumns.js +30 -19
- package/plugins/hiddenColumns/hiddenColumns.mjs +26 -15
- package/plugins/hiddenRows/hiddenRows.js +29 -18
- package/plugins/hiddenRows/hiddenRows.mjs +25 -14
- package/plugins/manualColumnFreeze/manualColumnFreeze.js +5 -5
- package/plugins/manualColumnFreeze/manualColumnFreeze.mjs +1 -1
- package/plugins/manualColumnMove/manualColumnMove.js +3 -3
- package/plugins/manualColumnMove/manualColumnMove.mjs +1 -1
- package/plugins/manualRowMove/manualRowMove.js +5 -5
- package/plugins/manualRowMove/manualRowMove.mjs +3 -3
- package/plugins/mergeCells/cellsCollection.js +3 -15
- package/plugins/mergeCells/cellsCollection.mjs +4 -16
- package/plugins/mergeCells/mergeCells.d.ts +2 -6
- package/plugins/mergeCells/mergeCells.js +55 -78
- package/plugins/mergeCells/mergeCells.mjs +53 -76
- package/plugins/mergeCells/renderer.js +3 -13
- package/plugins/mergeCells/renderer.mjs +3 -13
- package/plugins/persistentState/persistentState.js +4 -4
- package/plugins/persistentState/persistentState.mjs +1 -1
- package/plugins/undoRedo/undoRedo.js +5 -4
- package/plugins/undoRedo/undoRedo.mjs +3 -3
- package/renderers/checkboxRenderer/checkboxRenderer.js +2 -2
- package/renderers/checkboxRenderer/checkboxRenderer.mjs +1 -1
- package/settings.d.ts +1 -3
- package/shortcutContexts/commands/extendCellsSelection/downByViewportHeight.js +1 -1
- package/shortcutContexts/commands/extendCellsSelection/downByViewportHeight.mjs +1 -1
- package/shortcutContexts/commands/extendCellsSelection/upByViewportHeight.js +1 -1
- package/shortcutContexts/commands/extendCellsSelection/upByViewportHeight.mjs +1 -1
- package/shortcutContexts/commands/scrollToFocusedCell.js +4 -4
- package/shortcutContexts/commands/scrollToFocusedCell.mjs +4 -4
- package/tableView.js +43 -38
- package/tableView.mjs +43 -38
- package/core/hooks/bucket.js +0 -180
- package/core/hooks/bucket.mjs +0 -176
- package/core/hooks/index.js +0 -385
- package/core/hooks/index.mjs +0 -381
@@ -27,7 +27,7 @@ export function createMergeCellRenderer(plugin) {
|
|
27
27
|
*
|
28
28
|
* @private
|
29
29
|
* @param {HTMLElement} TD The cell to be modified.
|
30
|
-
* @param {number} row
|
30
|
+
* @param {number} row Row index.
|
31
31
|
* @param {number} col Visual column index.
|
32
32
|
*/
|
33
33
|
function after(TD, row, col) {
|
@@ -45,23 +45,13 @@ export function createMergeCellRenderer(plugin) {
|
|
45
45
|
rowspan: origRowspan
|
46
46
|
} = mergedCell;
|
47
47
|
const [lastMergedRowIndex, lastMergedColumnIndex] = plugin.translateMergedCellToRenderable(origRow, origRowspan, origColumn, origColspan);
|
48
|
-
const isVirtualRenderingEnabled = plugin.getSetting('virtualized');
|
49
48
|
const renderedRowIndex = rowMapper.getRenderableFromVisualIndex(row);
|
50
49
|
const renderedColumnIndex = columnMapper.getRenderableFromVisualIndex(col);
|
51
50
|
const maxRowSpan = lastMergedRowIndex - renderedRowIndex + 1; // Number of rendered columns.
|
52
51
|
const maxColSpan = lastMergedColumnIndex - renderedColumnIndex + 1; // Number of rendered columns.
|
53
52
|
|
54
|
-
|
55
|
-
|
56
|
-
if (isVirtualRenderingEnabled) {
|
57
|
-
const overlayName = hot.view.getActiveOverlayName();
|
58
|
-
if (!['top', 'top_inline_start_corner'].includes(overlayName)) {
|
59
|
-
notHiddenRow = Math.max(notHiddenRow, hot.getFirstRenderedVisibleRow());
|
60
|
-
}
|
61
|
-
if (!['inline_start', 'top_inline_start_corner', 'bottom_inline_start_corner'].includes(overlayName)) {
|
62
|
-
notHiddenColumn = Math.max(notHiddenColumn, hot.getFirstRenderedVisibleColumn());
|
63
|
-
}
|
64
|
-
}
|
53
|
+
const notHiddenRow = rowMapper.getNearestNotHiddenIndex(origRow, 1);
|
54
|
+
const notHiddenColumn = columnMapper.getNearestNotHiddenIndex(origColumn, 1);
|
65
55
|
const notHiddenRowspan = Math.min(origRowspan, maxRowSpan);
|
66
56
|
const notHiddenColspan = Math.min(origColspan, maxColSpan);
|
67
57
|
if (notHiddenRow === row && notHiddenColumn === col) {
|
@@ -4,14 +4,14 @@ exports.__esModule = true;
|
|
4
4
|
require("core-js/modules/es.error.cause.js");
|
5
5
|
var _base = require("../base");
|
6
6
|
var _storage = _interopRequireDefault(require("./storage"));
|
7
|
-
var
|
7
|
+
var _pluginHooks = _interopRequireDefault(require("../../pluginHooks"));
|
8
8
|
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
9
9
|
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; }
|
10
10
|
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == typeof i ? i : i + ""; }
|
11
11
|
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); }
|
12
|
-
|
13
|
-
|
14
|
-
|
12
|
+
_pluginHooks.default.getSingleton().register('persistentStateSave');
|
13
|
+
_pluginHooks.default.getSingleton().register('persistentStateLoad');
|
14
|
+
_pluginHooks.default.getSingleton().register('persistentStateReset');
|
15
15
|
const PLUGIN_KEY = exports.PLUGIN_KEY = 'persistentState';
|
16
16
|
const PLUGIN_PRIORITY = exports.PLUGIN_PRIORITY = 0;
|
17
17
|
|
@@ -4,7 +4,7 @@ function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol"
|
|
4
4
|
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); }
|
5
5
|
import { BasePlugin } from "../base/index.mjs";
|
6
6
|
import Storage from "./storage.mjs";
|
7
|
-
import
|
7
|
+
import Hooks from "../../pluginHooks.mjs";
|
8
8
|
Hooks.getSingleton().register('persistentStateSave');
|
9
9
|
Hooks.getSingleton().register('persistentStateLoad');
|
10
10
|
Hooks.getSingleton().register('persistentStateReset');
|
@@ -3,12 +3,13 @@
|
|
3
3
|
exports.__esModule = true;
|
4
4
|
require("core-js/modules/es.array.push.js");
|
5
5
|
require("core-js/modules/es.object.from-entries.js");
|
6
|
-
var
|
6
|
+
var _pluginHooks = _interopRequireDefault(require("../../pluginHooks"));
|
7
7
|
var _array = require("../../helpers/array");
|
8
8
|
var _number = require("../../helpers/number");
|
9
9
|
var _object = require("../../helpers/object");
|
10
10
|
var _utils = require("../contextMenu/utils");
|
11
11
|
var _moves = require("../../helpers/moves");
|
12
|
+
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
12
13
|
const SHORTCUTS_GROUP = 'undoRedo';
|
13
14
|
const PLUGIN_KEY = exports.PLUGIN_KEY = 'undoRedo';
|
14
15
|
|
@@ -400,8 +401,8 @@ UndoRedo.ChangeAction.prototype.undo = function (instance, undoneCallback) {
|
|
400
401
|
if (selectedLast !== undefined) {
|
401
402
|
const [changedRow, changedColumn] = data[0];
|
402
403
|
const [selectedRow, selectedColumn] = selectedLast;
|
403
|
-
const firstFullyVisibleRow = instance.getFirstFullyVisibleRow();
|
404
|
-
const firstFullyVisibleColumn = instance.getFirstFullyVisibleColumn();
|
404
|
+
const firstFullyVisibleRow = instance.view.getFirstFullyVisibleRow();
|
405
|
+
const firstFullyVisibleColumn = instance.view.getFirstFullyVisibleColumn();
|
405
406
|
const isInVerticalViewPort = changedRow >= firstFullyVisibleRow;
|
406
407
|
const isInHorizontalViewPort = changedColumn >= firstFullyVisibleColumn;
|
407
408
|
const isInViewport = isInVerticalViewPort && isInHorizontalViewPort;
|
@@ -971,7 +972,7 @@ function removeExposedUndoRedoMethods(instance) {
|
|
971
972
|
delete instance.isRedoAvailable;
|
972
973
|
delete instance.clearUndo;
|
973
974
|
}
|
974
|
-
const hook =
|
975
|
+
const hook = _pluginHooks.default.getSingleton();
|
975
976
|
hook.add('afterUpdateSettings', function () {
|
976
977
|
var _this$getPlugin;
|
977
978
|
(_this$getPlugin = this.getPlugin('undoRedo')) === null || _this$getPlugin === void 0 || _this$getPlugin.init();
|
@@ -1,6 +1,6 @@
|
|
1
1
|
import "core-js/modules/es.array.push.js";
|
2
2
|
import "core-js/modules/es.object.from-entries.js";
|
3
|
-
import
|
3
|
+
import Hooks from "../../pluginHooks.mjs";
|
4
4
|
import { arrayMap, arrayEach } from "../../helpers/array.mjs";
|
5
5
|
import { rangeEach } from "../../helpers/number.mjs";
|
6
6
|
import { inherit, deepClone } from "../../helpers/object.mjs";
|
@@ -397,8 +397,8 @@ UndoRedo.ChangeAction.prototype.undo = function (instance, undoneCallback) {
|
|
397
397
|
if (selectedLast !== undefined) {
|
398
398
|
const [changedRow, changedColumn] = data[0];
|
399
399
|
const [selectedRow, selectedColumn] = selectedLast;
|
400
|
-
const firstFullyVisibleRow = instance.getFirstFullyVisibleRow();
|
401
|
-
const firstFullyVisibleColumn = instance.getFirstFullyVisibleColumn();
|
400
|
+
const firstFullyVisibleRow = instance.view.getFirstFullyVisibleRow();
|
401
|
+
const firstFullyVisibleColumn = instance.view.getFirstFullyVisibleColumn();
|
402
402
|
const isInVerticalViewPort = changedRow >= firstFullyVisibleRow;
|
403
403
|
const isInHorizontalViewPort = changedColumn >= firstFullyVisibleColumn;
|
404
404
|
const isInViewport = isInVerticalViewPort && isInHorizontalViewPort;
|
@@ -8,7 +8,7 @@ var _eventManager = _interopRequireDefault(require("../../eventManager"));
|
|
8
8
|
var _element = require("../../helpers/dom/element");
|
9
9
|
var _mixed = require("../../helpers/mixed");
|
10
10
|
var _shortcutContexts = require("../../shortcutContexts");
|
11
|
-
var
|
11
|
+
var _pluginHooks = _interopRequireDefault(require("../../pluginHooks"));
|
12
12
|
var _a11y = require("../../helpers/a11y");
|
13
13
|
var _constants = require("../../i18n/constants");
|
14
14
|
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
@@ -19,7 +19,7 @@ const ATTR_ROW = 'data-row';
|
|
19
19
|
const ATTR_COLUMN = 'data-col';
|
20
20
|
const SHORTCUTS_GROUP = 'checkboxRenderer';
|
21
21
|
const RENDERER_TYPE = exports.RENDERER_TYPE = 'checkbox';
|
22
|
-
|
22
|
+
_pluginHooks.default.getSingleton().add('modifyAutoColumnSizeSeed', function (bundleSeed, cellMeta, cellValue) {
|
23
23
|
const {
|
24
24
|
label,
|
25
25
|
type,
|
@@ -4,7 +4,7 @@ import EventManager from "../../eventManager.mjs";
|
|
4
4
|
import { empty, addClass, setAttribute } from "../../helpers/dom/element.mjs";
|
5
5
|
import { isEmpty, stringify } from "../../helpers/mixed.mjs";
|
6
6
|
import { EDITOR_EDIT_GROUP as SHORTCUTS_GROUP_EDITOR } from "../../shortcutContexts/index.mjs";
|
7
|
-
import
|
7
|
+
import Hooks from "../../pluginHooks.mjs";
|
8
8
|
import { A11Y_CHECKBOX, A11Y_CHECKED, A11Y_LABEL } from "../../helpers/a11y.mjs";
|
9
9
|
import { CHECKBOX_CHECKED, CHECKBOX_UNCHECKED } from "../../i18n/constants.mjs";
|
10
10
|
const isListeningKeyDownEvent = new WeakMap();
|
package/settings.d.ts
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
import { PikadayOptions } from '@handsontable/pikaday';
|
2
2
|
import Core from './core';
|
3
|
-
import { Events } from './
|
3
|
+
import { Events } from './pluginHooks';
|
4
4
|
import {
|
5
5
|
CellValue,
|
6
6
|
ColumnDataGetterSetterFunction,
|
@@ -224,8 +224,6 @@ export interface GridSettings extends Events {
|
|
224
224
|
validator?: BaseValidator | RegExp | ValidatorType | string;
|
225
225
|
viewportColumnRenderingOffset?: number | 'auto';
|
226
226
|
viewportRowRenderingOffset?: number | 'auto';
|
227
|
-
viewportColumnRenderingThreshold?: number | 'auto';
|
228
|
-
viewportRowRenderingThreshold?: number | 'auto';
|
229
227
|
visibleRows?: number;
|
230
228
|
width?: number | string | (() => number | string);
|
231
229
|
wordWrap?: boolean;
|
@@ -11,7 +11,7 @@ const command = exports.command = {
|
|
11
11
|
const row = hot.rowIndexMapper.getNearestNotHiddenIndex(nextRowIndexToSelect, -1);
|
12
12
|
if (row !== null) {
|
13
13
|
const coords = hot._createCellCoords(row, to.col);
|
14
|
-
const scrollPadding = to.row - hot.getFirstFullyVisibleRow();
|
14
|
+
const scrollPadding = to.row - hot.view.getFirstFullyVisibleRow();
|
15
15
|
const nextVerticalScroll = Math.min(coords.row - scrollPadding, hot.countRows() - 1);
|
16
16
|
hot.selection.setRangeEnd(coords);
|
17
17
|
hot.scrollViewportTo({
|
@@ -8,7 +8,7 @@ export const command = {
|
|
8
8
|
const row = hot.rowIndexMapper.getNearestNotHiddenIndex(nextRowIndexToSelect, -1);
|
9
9
|
if (row !== null) {
|
10
10
|
const coords = hot._createCellCoords(row, to.col);
|
11
|
-
const scrollPadding = to.row - hot.getFirstFullyVisibleRow();
|
11
|
+
const scrollPadding = to.row - hot.view.getFirstFullyVisibleRow();
|
12
12
|
const nextVerticalScroll = Math.min(coords.row - scrollPadding, hot.countRows() - 1);
|
13
13
|
hot.selection.setRangeEnd(coords);
|
14
14
|
hot.scrollViewportTo({
|
@@ -11,7 +11,7 @@ const command = exports.command = {
|
|
11
11
|
const row = hot.rowIndexMapper.getNearestNotHiddenIndex(nextRowIndexToSelect, 1);
|
12
12
|
if (row !== null) {
|
13
13
|
const coords = hot._createCellCoords(row, to.col);
|
14
|
-
const scrollPadding = to.row - hot.getFirstFullyVisibleRow();
|
14
|
+
const scrollPadding = to.row - hot.view.getFirstFullyVisibleRow();
|
15
15
|
const nextVerticalScroll = Math.max(coords.row - scrollPadding, 0);
|
16
16
|
hot.selection.setRangeEnd(coords);
|
17
17
|
hot.scrollViewportTo({
|
@@ -8,7 +8,7 @@ export const command = {
|
|
8
8
|
const row = hot.rowIndexMapper.getNearestNotHiddenIndex(nextRowIndexToSelect, 1);
|
9
9
|
if (row !== null) {
|
10
10
|
const coords = hot._createCellCoords(row, to.col);
|
11
|
-
const scrollPadding = to.row - hot.getFirstFullyVisibleRow();
|
11
|
+
const scrollPadding = to.row - hot.view.getFirstFullyVisibleRow();
|
12
12
|
const nextVerticalScroll = Math.max(coords.row - scrollPadding, 0);
|
13
13
|
hot.selection.setRangeEnd(coords);
|
14
14
|
hot.scrollViewportTo({
|
@@ -7,10 +7,10 @@ const command = exports.command = {
|
|
7
7
|
const {
|
8
8
|
highlight
|
9
9
|
} = hot.getSelectedRangeLast();
|
10
|
-
const firstVisibleRow = hot.getFirstFullyVisibleRow() - 1;
|
11
|
-
const firstVisibleColumn = hot.getFirstFullyVisibleColumn() - 1;
|
12
|
-
const lastVisibleRow = hot.getLastFullyVisibleRow() + 1;
|
13
|
-
const lastVisibleColumn = hot.getLastFullyVisibleColumn() + 1;
|
10
|
+
const firstVisibleRow = hot.view.getFirstFullyVisibleRow() - 1;
|
11
|
+
const firstVisibleColumn = hot.view.getFirstFullyVisibleColumn() - 1;
|
12
|
+
const lastVisibleRow = hot.view.getLastFullyVisibleRow() + 1;
|
13
|
+
const lastVisibleColumn = hot.view.getLastFullyVisibleColumn() + 1;
|
14
14
|
const visibleCoordsFrom = hot._createCellCoords(firstVisibleRow, firstVisibleColumn);
|
15
15
|
const visibleCoordsTo = hot._createCellCoords(lastVisibleRow, lastVisibleColumn);
|
16
16
|
const visibleRange = hot._createCellRange(visibleCoordsFrom, visibleCoordsFrom, visibleCoordsTo);
|
@@ -4,10 +4,10 @@ export const command = {
|
|
4
4
|
const {
|
5
5
|
highlight
|
6
6
|
} = hot.getSelectedRangeLast();
|
7
|
-
const firstVisibleRow = hot.getFirstFullyVisibleRow() - 1;
|
8
|
-
const firstVisibleColumn = hot.getFirstFullyVisibleColumn() - 1;
|
9
|
-
const lastVisibleRow = hot.getLastFullyVisibleRow() + 1;
|
10
|
-
const lastVisibleColumn = hot.getLastFullyVisibleColumn() + 1;
|
7
|
+
const firstVisibleRow = hot.view.getFirstFullyVisibleRow() - 1;
|
8
|
+
const firstVisibleColumn = hot.view.getFirstFullyVisibleColumn() - 1;
|
9
|
+
const lastVisibleRow = hot.view.getLastFullyVisibleRow() + 1;
|
10
|
+
const lastVisibleColumn = hot.view.getLastFullyVisibleColumn() + 1;
|
11
11
|
const visibleCoordsFrom = hot._createCellCoords(firstVisibleRow, firstVisibleColumn);
|
12
12
|
const visibleCoordsTo = hot._createCellCoords(lastVisibleRow, lastVisibleColumn);
|
13
13
|
const visibleRange = hot._createCellRange(visibleCoordsFrom, visibleCoordsFrom, visibleCoordsTo);
|
package/tableView.js
CHANGED
@@ -614,8 +614,6 @@ class TableView {
|
|
614
614
|
preventOverflow: () => this.settings.preventOverflow,
|
615
615
|
preventWheel: () => this.settings.preventWheel,
|
616
616
|
stretchH: () => this.settings.stretchH,
|
617
|
-
viewportColumnRenderingThreshold: () => this.settings.viewportColumnRenderingThreshold,
|
618
|
-
viewportRowRenderingThreshold: () => this.settings.viewportRowRenderingThreshold,
|
619
617
|
data: (renderableRow, renderableColumn) => {
|
620
618
|
return this.hot.getDataAtCell(...this.translateFromRenderableToVisualIndex(renderableRow, renderableColumn));
|
621
619
|
},
|
@@ -698,7 +696,7 @@ class TableView {
|
|
698
696
|
const [visualRowIndex, visualColumnIndex] = this.translateFromRenderableToVisualIndex(renderedRowIndex, renderedColumnIndex);
|
699
697
|
|
700
698
|
// Coords may be modified. For example, by the `MergeCells` plugin. It should affect cell value and cell meta.
|
701
|
-
const modifiedCellCoords = this.hot.runHooks('modifyGetCellCoords', visualRowIndex, visualColumnIndex
|
699
|
+
const modifiedCellCoords = this.hot.runHooks('modifyGetCellCoords', visualRowIndex, visualColumnIndex);
|
702
700
|
let visualRowToCheck = visualRowIndex;
|
703
701
|
let visualColumnToCheck = visualColumnIndex;
|
704
702
|
if (Array.isArray(modifiedCellCoords)) {
|
@@ -917,14 +915,14 @@ class TableView {
|
|
917
915
|
return this.hot.runHooks('beforeStretchingColumnWidth', stretchedWidth, visualColumnIndex);
|
918
916
|
},
|
919
917
|
onModifyRowHeaderWidth: rowHeaderWidth => this.hot.runHooks('modifyRowHeaderWidth', rowHeaderWidth),
|
920
|
-
onModifyGetCellCoords: (renderableRowIndex, renderableColumnIndex, topmost
|
918
|
+
onModifyGetCellCoords: (renderableRowIndex, renderableColumnIndex, topmost) => {
|
921
919
|
const rowMapper = this.hot.rowIndexMapper;
|
922
920
|
const columnMapper = this.hot.columnIndexMapper;
|
923
921
|
|
924
922
|
// Callback handle also headers. We shouldn't translate them.
|
925
923
|
const visualColumnIndex = renderableColumnIndex >= 0 ? columnMapper.getVisualFromRenderableIndex(renderableColumnIndex) : renderableColumnIndex;
|
926
924
|
const visualRowIndex = renderableRowIndex >= 0 ? rowMapper.getVisualFromRenderableIndex(renderableRowIndex) : renderableRowIndex;
|
927
|
-
const visualIndexes = this.hot.runHooks('modifyGetCellCoords', visualRowIndex, visualColumnIndex, topmost
|
925
|
+
const visualIndexes = this.hot.runHooks('modifyGetCellCoords', visualRowIndex, visualColumnIndex, topmost);
|
928
926
|
if (Array.isArray(visualIndexes)) {
|
929
927
|
const [visualRowFrom, visualColumnFrom, visualRowTo, visualColumnTo] = visualIndexes;
|
930
928
|
|
@@ -932,17 +930,6 @@ class TableView {
|
|
932
930
|
return [visualRowFrom >= 0 ? rowMapper.getRenderableFromVisualIndex(rowMapper.getNearestNotHiddenIndex(visualRowFrom, 1)) : visualRowFrom, visualColumnFrom >= 0 ? columnMapper.getRenderableFromVisualIndex(columnMapper.getNearestNotHiddenIndex(visualColumnFrom, 1)) : visualColumnFrom, visualRowTo >= 0 ? rowMapper.getRenderableFromVisualIndex(rowMapper.getNearestNotHiddenIndex(visualRowTo, -1)) : visualRowTo, visualColumnTo >= 0 ? columnMapper.getRenderableFromVisualIndex(columnMapper.getNearestNotHiddenIndex(visualColumnTo, -1)) : visualColumnTo];
|
933
931
|
}
|
934
932
|
},
|
935
|
-
onModifyGetCoordsElement: (renderableRowIndex, renderableColumnIndex) => {
|
936
|
-
const rowMapper = this.hot.rowIndexMapper;
|
937
|
-
const columnMapper = this.hot.columnIndexMapper;
|
938
|
-
const visualColumnIndex = renderableColumnIndex >= 0 ? columnMapper.getVisualFromRenderableIndex(renderableColumnIndex) : renderableColumnIndex;
|
939
|
-
const visualRowIndex = renderableRowIndex >= 0 ? rowMapper.getVisualFromRenderableIndex(renderableRowIndex) : renderableRowIndex;
|
940
|
-
const visualIndexes = this.hot.runHooks('modifyGetCoordsElement', visualRowIndex, visualColumnIndex);
|
941
|
-
if (Array.isArray(visualIndexes)) {
|
942
|
-
const [visualRow, visualColumn] = visualIndexes;
|
943
|
-
return [visualRow >= 0 ? rowMapper.getRenderableFromVisualIndex(rowMapper.getNearestNotHiddenIndex(visualRow, 1)) : visualRow, visualColumn >= 0 ? columnMapper.getRenderableFromVisualIndex(columnMapper.getNearestNotHiddenIndex(visualColumn, 1)) : visualColumn];
|
944
|
-
}
|
945
|
-
},
|
946
933
|
viewportRowCalculatorOverride: calc => {
|
947
934
|
let viewportOffset = this.settings.viewportRowRenderingOffset;
|
948
935
|
if (viewportOffset === 'auto' && this.settings.fixedRowsTop) {
|
@@ -956,7 +943,7 @@ class TableView {
|
|
956
943
|
calc.startRow = Math.max(firstRenderedRow - viewportOffset, 0);
|
957
944
|
calc.endRow = Math.min(lastRenderedRow + viewportOffset, renderableRows - 1);
|
958
945
|
} else if (viewportOffset === 'auto') {
|
959
|
-
const offset = Math.
|
946
|
+
const offset = Math.ceil(lastRenderedRow / renderableRows * 12);
|
960
947
|
calc.startRow = Math.max(firstRenderedRow - offset, 0);
|
961
948
|
calc.endRow = Math.min(lastRenderedRow + offset, renderableRows - 1);
|
962
949
|
}
|
@@ -977,7 +964,7 @@ class TableView {
|
|
977
964
|
calc.endColumn = Math.min(lastRenderedColumn + viewportOffset, renderableColumns - 1);
|
978
965
|
}
|
979
966
|
if (viewportOffset === 'auto') {
|
980
|
-
const offset = Math.
|
967
|
+
const offset = Math.ceil(lastRenderedColumn / renderableColumns * 6);
|
981
968
|
calc.startColumn = Math.max(firstRenderedColumn - offset, 0);
|
982
969
|
calc.endColumn = Math.min(lastRenderedColumn + offset, renderableColumns - 1);
|
983
970
|
}
|
@@ -1279,9 +1266,7 @@ class TableView {
|
|
1279
1266
|
if (!this._wt.wtViewport.rowsRenderCalculator) {
|
1280
1267
|
return null;
|
1281
1268
|
}
|
1282
|
-
|
1283
|
-
const visualRowIndex = indexMapper.getVisualFromRenderableIndex(this._wt.wtTable.getFirstRenderedRow());
|
1284
|
-
return indexMapper.getNearestNotHiddenIndex(visualRowIndex !== null && visualRowIndex !== void 0 ? visualRowIndex : 0, 1);
|
1269
|
+
return this.hot.rowIndexMapper.getNearestNotHiddenIndex(this._wt.wtTable.getFirstRenderedRow(), 1);
|
1285
1270
|
}
|
1286
1271
|
|
1287
1272
|
/**
|
@@ -1293,9 +1278,7 @@ class TableView {
|
|
1293
1278
|
if (!this._wt.wtViewport.rowsRenderCalculator) {
|
1294
1279
|
return null;
|
1295
1280
|
}
|
1296
|
-
|
1297
|
-
const visualRowIndex = indexMapper.getVisualFromRenderableIndex(this._wt.wtTable.getLastRenderedRow());
|
1298
|
-
return indexMapper.getNearestNotHiddenIndex(visualRowIndex !== null && visualRowIndex !== void 0 ? visualRowIndex : this.hot.countRows() - 1, -1);
|
1281
|
+
return this.hot.rowIndexMapper.getNearestNotHiddenIndex(this._wt.wtTable.getLastRenderedRow(), -1);
|
1299
1282
|
}
|
1300
1283
|
|
1301
1284
|
/**
|
@@ -1307,9 +1290,7 @@ class TableView {
|
|
1307
1290
|
if (!this._wt.wtViewport.columnsRenderCalculator) {
|
1308
1291
|
return null;
|
1309
1292
|
}
|
1310
|
-
|
1311
|
-
const visualColumnIndex = indexMapper.getVisualFromRenderableIndex(this._wt.wtTable.getFirstRenderedColumn());
|
1312
|
-
return indexMapper.getNearestNotHiddenIndex(visualColumnIndex !== null && visualColumnIndex !== void 0 ? visualColumnIndex : 0, 1);
|
1293
|
+
return this.hot.columnIndexMapper.getNearestNotHiddenIndex(this._wt.wtTable.getFirstRenderedColumn(), 1);
|
1313
1294
|
}
|
1314
1295
|
|
1315
1296
|
/**
|
@@ -1321,9 +1302,7 @@ class TableView {
|
|
1321
1302
|
if (!this._wt.wtViewport.columnsRenderCalculator) {
|
1322
1303
|
return null;
|
1323
1304
|
}
|
1324
|
-
|
1325
|
-
const visualColumnIndex = indexMapper.getVisualFromRenderableIndex(this._wt.wtTable.getLastRenderedColumn());
|
1326
|
-
return indexMapper.getNearestNotHiddenIndex(visualColumnIndex !== null && visualColumnIndex !== void 0 ? visualColumnIndex : this.hot.countCols() - 1, -1);
|
1305
|
+
return this.hot.columnIndexMapper.getNearestNotHiddenIndex(this._wt.wtTable.getLastRenderedColumn(), -1);
|
1327
1306
|
}
|
1328
1307
|
|
1329
1308
|
/**
|
@@ -1486,22 +1465,48 @@ class TableView {
|
|
1486
1465
|
}
|
1487
1466
|
|
1488
1467
|
/**
|
1489
|
-
*
|
1490
|
-
* the 'master' name is returned.
|
1468
|
+
* Checks if the table is visible or not.
|
1491
1469
|
*
|
1492
|
-
* @returns {
|
1470
|
+
* @returns {boolean}
|
1493
1471
|
*/
|
1494
|
-
|
1495
|
-
return this._wt.
|
1472
|
+
isVisible() {
|
1473
|
+
return this._wt.wtTable.isVisible();
|
1496
1474
|
}
|
1497
1475
|
|
1498
1476
|
/**
|
1499
|
-
* Checks if the table
|
1477
|
+
* Checks if the table has a horizontal scrollbar.
|
1500
1478
|
*
|
1501
1479
|
* @returns {boolean}
|
1502
1480
|
*/
|
1503
|
-
|
1504
|
-
return this._wt.
|
1481
|
+
hasVerticalScroll() {
|
1482
|
+
return this._wt.wtViewport.hasVerticalScroll();
|
1483
|
+
}
|
1484
|
+
|
1485
|
+
/**
|
1486
|
+
* Checks if the table has a vertical scrollbar.
|
1487
|
+
*
|
1488
|
+
* @returns {boolean}
|
1489
|
+
*/
|
1490
|
+
hasHorizontalScroll() {
|
1491
|
+
return this._wt.wtViewport.hasHorizontalScroll();
|
1492
|
+
}
|
1493
|
+
|
1494
|
+
/**
|
1495
|
+
* Gets the table's width.
|
1496
|
+
*
|
1497
|
+
* @returns {boolean}
|
1498
|
+
*/
|
1499
|
+
getTableWidth() {
|
1500
|
+
return this._wt.wtTable.getWidth();
|
1501
|
+
}
|
1502
|
+
|
1503
|
+
/**
|
1504
|
+
* Gets the table's height.
|
1505
|
+
*
|
1506
|
+
* @returns {boolean}
|
1507
|
+
*/
|
1508
|
+
getTableHeight() {
|
1509
|
+
return this._wt.wtTable.getHeight();
|
1505
1510
|
}
|
1506
1511
|
/**
|
1507
1512
|
* Destroys internal WalkOnTable's instance. Detaches all of the bonded listeners.
|
package/tableView.mjs
CHANGED
@@ -610,8 +610,6 @@ class TableView {
|
|
610
610
|
preventOverflow: () => this.settings.preventOverflow,
|
611
611
|
preventWheel: () => this.settings.preventWheel,
|
612
612
|
stretchH: () => this.settings.stretchH,
|
613
|
-
viewportColumnRenderingThreshold: () => this.settings.viewportColumnRenderingThreshold,
|
614
|
-
viewportRowRenderingThreshold: () => this.settings.viewportRowRenderingThreshold,
|
615
613
|
data: (renderableRow, renderableColumn) => {
|
616
614
|
return this.hot.getDataAtCell(...this.translateFromRenderableToVisualIndex(renderableRow, renderableColumn));
|
617
615
|
},
|
@@ -694,7 +692,7 @@ class TableView {
|
|
694
692
|
const [visualRowIndex, visualColumnIndex] = this.translateFromRenderableToVisualIndex(renderedRowIndex, renderedColumnIndex);
|
695
693
|
|
696
694
|
// Coords may be modified. For example, by the `MergeCells` plugin. It should affect cell value and cell meta.
|
697
|
-
const modifiedCellCoords = this.hot.runHooks('modifyGetCellCoords', visualRowIndex, visualColumnIndex
|
695
|
+
const modifiedCellCoords = this.hot.runHooks('modifyGetCellCoords', visualRowIndex, visualColumnIndex);
|
698
696
|
let visualRowToCheck = visualRowIndex;
|
699
697
|
let visualColumnToCheck = visualColumnIndex;
|
700
698
|
if (Array.isArray(modifiedCellCoords)) {
|
@@ -913,14 +911,14 @@ class TableView {
|
|
913
911
|
return this.hot.runHooks('beforeStretchingColumnWidth', stretchedWidth, visualColumnIndex);
|
914
912
|
},
|
915
913
|
onModifyRowHeaderWidth: rowHeaderWidth => this.hot.runHooks('modifyRowHeaderWidth', rowHeaderWidth),
|
916
|
-
onModifyGetCellCoords: (renderableRowIndex, renderableColumnIndex, topmost
|
914
|
+
onModifyGetCellCoords: (renderableRowIndex, renderableColumnIndex, topmost) => {
|
917
915
|
const rowMapper = this.hot.rowIndexMapper;
|
918
916
|
const columnMapper = this.hot.columnIndexMapper;
|
919
917
|
|
920
918
|
// Callback handle also headers. We shouldn't translate them.
|
921
919
|
const visualColumnIndex = renderableColumnIndex >= 0 ? columnMapper.getVisualFromRenderableIndex(renderableColumnIndex) : renderableColumnIndex;
|
922
920
|
const visualRowIndex = renderableRowIndex >= 0 ? rowMapper.getVisualFromRenderableIndex(renderableRowIndex) : renderableRowIndex;
|
923
|
-
const visualIndexes = this.hot.runHooks('modifyGetCellCoords', visualRowIndex, visualColumnIndex, topmost
|
921
|
+
const visualIndexes = this.hot.runHooks('modifyGetCellCoords', visualRowIndex, visualColumnIndex, topmost);
|
924
922
|
if (Array.isArray(visualIndexes)) {
|
925
923
|
const [visualRowFrom, visualColumnFrom, visualRowTo, visualColumnTo] = visualIndexes;
|
926
924
|
|
@@ -928,17 +926,6 @@ class TableView {
|
|
928
926
|
return [visualRowFrom >= 0 ? rowMapper.getRenderableFromVisualIndex(rowMapper.getNearestNotHiddenIndex(visualRowFrom, 1)) : visualRowFrom, visualColumnFrom >= 0 ? columnMapper.getRenderableFromVisualIndex(columnMapper.getNearestNotHiddenIndex(visualColumnFrom, 1)) : visualColumnFrom, visualRowTo >= 0 ? rowMapper.getRenderableFromVisualIndex(rowMapper.getNearestNotHiddenIndex(visualRowTo, -1)) : visualRowTo, visualColumnTo >= 0 ? columnMapper.getRenderableFromVisualIndex(columnMapper.getNearestNotHiddenIndex(visualColumnTo, -1)) : visualColumnTo];
|
929
927
|
}
|
930
928
|
},
|
931
|
-
onModifyGetCoordsElement: (renderableRowIndex, renderableColumnIndex) => {
|
932
|
-
const rowMapper = this.hot.rowIndexMapper;
|
933
|
-
const columnMapper = this.hot.columnIndexMapper;
|
934
|
-
const visualColumnIndex = renderableColumnIndex >= 0 ? columnMapper.getVisualFromRenderableIndex(renderableColumnIndex) : renderableColumnIndex;
|
935
|
-
const visualRowIndex = renderableRowIndex >= 0 ? rowMapper.getVisualFromRenderableIndex(renderableRowIndex) : renderableRowIndex;
|
936
|
-
const visualIndexes = this.hot.runHooks('modifyGetCoordsElement', visualRowIndex, visualColumnIndex);
|
937
|
-
if (Array.isArray(visualIndexes)) {
|
938
|
-
const [visualRow, visualColumn] = visualIndexes;
|
939
|
-
return [visualRow >= 0 ? rowMapper.getRenderableFromVisualIndex(rowMapper.getNearestNotHiddenIndex(visualRow, 1)) : visualRow, visualColumn >= 0 ? columnMapper.getRenderableFromVisualIndex(columnMapper.getNearestNotHiddenIndex(visualColumn, 1)) : visualColumn];
|
940
|
-
}
|
941
|
-
},
|
942
929
|
viewportRowCalculatorOverride: calc => {
|
943
930
|
let viewportOffset = this.settings.viewportRowRenderingOffset;
|
944
931
|
if (viewportOffset === 'auto' && this.settings.fixedRowsTop) {
|
@@ -952,7 +939,7 @@ class TableView {
|
|
952
939
|
calc.startRow = Math.max(firstRenderedRow - viewportOffset, 0);
|
953
940
|
calc.endRow = Math.min(lastRenderedRow + viewportOffset, renderableRows - 1);
|
954
941
|
} else if (viewportOffset === 'auto') {
|
955
|
-
const offset = Math.
|
942
|
+
const offset = Math.ceil(lastRenderedRow / renderableRows * 12);
|
956
943
|
calc.startRow = Math.max(firstRenderedRow - offset, 0);
|
957
944
|
calc.endRow = Math.min(lastRenderedRow + offset, renderableRows - 1);
|
958
945
|
}
|
@@ -973,7 +960,7 @@ class TableView {
|
|
973
960
|
calc.endColumn = Math.min(lastRenderedColumn + viewportOffset, renderableColumns - 1);
|
974
961
|
}
|
975
962
|
if (viewportOffset === 'auto') {
|
976
|
-
const offset = Math.
|
963
|
+
const offset = Math.ceil(lastRenderedColumn / renderableColumns * 6);
|
977
964
|
calc.startColumn = Math.max(firstRenderedColumn - offset, 0);
|
978
965
|
calc.endColumn = Math.min(lastRenderedColumn + offset, renderableColumns - 1);
|
979
966
|
}
|
@@ -1275,9 +1262,7 @@ class TableView {
|
|
1275
1262
|
if (!this._wt.wtViewport.rowsRenderCalculator) {
|
1276
1263
|
return null;
|
1277
1264
|
}
|
1278
|
-
|
1279
|
-
const visualRowIndex = indexMapper.getVisualFromRenderableIndex(this._wt.wtTable.getFirstRenderedRow());
|
1280
|
-
return indexMapper.getNearestNotHiddenIndex(visualRowIndex !== null && visualRowIndex !== void 0 ? visualRowIndex : 0, 1);
|
1265
|
+
return this.hot.rowIndexMapper.getNearestNotHiddenIndex(this._wt.wtTable.getFirstRenderedRow(), 1);
|
1281
1266
|
}
|
1282
1267
|
|
1283
1268
|
/**
|
@@ -1289,9 +1274,7 @@ class TableView {
|
|
1289
1274
|
if (!this._wt.wtViewport.rowsRenderCalculator) {
|
1290
1275
|
return null;
|
1291
1276
|
}
|
1292
|
-
|
1293
|
-
const visualRowIndex = indexMapper.getVisualFromRenderableIndex(this._wt.wtTable.getLastRenderedRow());
|
1294
|
-
return indexMapper.getNearestNotHiddenIndex(visualRowIndex !== null && visualRowIndex !== void 0 ? visualRowIndex : this.hot.countRows() - 1, -1);
|
1277
|
+
return this.hot.rowIndexMapper.getNearestNotHiddenIndex(this._wt.wtTable.getLastRenderedRow(), -1);
|
1295
1278
|
}
|
1296
1279
|
|
1297
1280
|
/**
|
@@ -1303,9 +1286,7 @@ class TableView {
|
|
1303
1286
|
if (!this._wt.wtViewport.columnsRenderCalculator) {
|
1304
1287
|
return null;
|
1305
1288
|
}
|
1306
|
-
|
1307
|
-
const visualColumnIndex = indexMapper.getVisualFromRenderableIndex(this._wt.wtTable.getFirstRenderedColumn());
|
1308
|
-
return indexMapper.getNearestNotHiddenIndex(visualColumnIndex !== null && visualColumnIndex !== void 0 ? visualColumnIndex : 0, 1);
|
1289
|
+
return this.hot.columnIndexMapper.getNearestNotHiddenIndex(this._wt.wtTable.getFirstRenderedColumn(), 1);
|
1309
1290
|
}
|
1310
1291
|
|
1311
1292
|
/**
|
@@ -1317,9 +1298,7 @@ class TableView {
|
|
1317
1298
|
if (!this._wt.wtViewport.columnsRenderCalculator) {
|
1318
1299
|
return null;
|
1319
1300
|
}
|
1320
|
-
|
1321
|
-
const visualColumnIndex = indexMapper.getVisualFromRenderableIndex(this._wt.wtTable.getLastRenderedColumn());
|
1322
|
-
return indexMapper.getNearestNotHiddenIndex(visualColumnIndex !== null && visualColumnIndex !== void 0 ? visualColumnIndex : this.hot.countCols() - 1, -1);
|
1301
|
+
return this.hot.columnIndexMapper.getNearestNotHiddenIndex(this._wt.wtTable.getLastRenderedColumn(), -1);
|
1323
1302
|
}
|
1324
1303
|
|
1325
1304
|
/**
|
@@ -1482,22 +1461,48 @@ class TableView {
|
|
1482
1461
|
}
|
1483
1462
|
|
1484
1463
|
/**
|
1485
|
-
*
|
1486
|
-
* the 'master' name is returned.
|
1464
|
+
* Checks if the table is visible or not.
|
1487
1465
|
*
|
1488
|
-
* @returns {
|
1466
|
+
* @returns {boolean}
|
1489
1467
|
*/
|
1490
|
-
|
1491
|
-
return this._wt.
|
1468
|
+
isVisible() {
|
1469
|
+
return this._wt.wtTable.isVisible();
|
1492
1470
|
}
|
1493
1471
|
|
1494
1472
|
/**
|
1495
|
-
* Checks if the table
|
1473
|
+
* Checks if the table has a horizontal scrollbar.
|
1496
1474
|
*
|
1497
1475
|
* @returns {boolean}
|
1498
1476
|
*/
|
1499
|
-
|
1500
|
-
return this._wt.
|
1477
|
+
hasVerticalScroll() {
|
1478
|
+
return this._wt.wtViewport.hasVerticalScroll();
|
1479
|
+
}
|
1480
|
+
|
1481
|
+
/**
|
1482
|
+
* Checks if the table has a vertical scrollbar.
|
1483
|
+
*
|
1484
|
+
* @returns {boolean}
|
1485
|
+
*/
|
1486
|
+
hasHorizontalScroll() {
|
1487
|
+
return this._wt.wtViewport.hasHorizontalScroll();
|
1488
|
+
}
|
1489
|
+
|
1490
|
+
/**
|
1491
|
+
* Gets the table's width.
|
1492
|
+
*
|
1493
|
+
* @returns {boolean}
|
1494
|
+
*/
|
1495
|
+
getTableWidth() {
|
1496
|
+
return this._wt.wtTable.getWidth();
|
1497
|
+
}
|
1498
|
+
|
1499
|
+
/**
|
1500
|
+
* Gets the table's height.
|
1501
|
+
*
|
1502
|
+
* @returns {boolean}
|
1503
|
+
*/
|
1504
|
+
getTableHeight() {
|
1505
|
+
return this._wt.wtTable.getHeight();
|
1501
1506
|
}
|
1502
1507
|
/**
|
1503
1508
|
* Destroys internal WalkOnTable's instance. Detaches all of the bonded listeners.
|