handsontable 0.0.0-next-6129043-20241108 → 0.0.0-next-4b40c99-20241108
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/index.js +2 -1
- package/3rdparty/walkontable/src/calculator/index.mjs +2 -2
- package/3rdparty/walkontable/src/calculator/viewportBase.js +2 -0
- package/3rdparty/walkontable/src/calculator/viewportBase.mjs +2 -0
- package/3rdparty/walkontable/src/calculator/viewportRows.js +3 -3
- package/3rdparty/walkontable/src/calculator/viewportRows.mjs +3 -3
- package/3rdparty/walkontable/src/core/_base.js +0 -3
- package/3rdparty/walkontable/src/core/_base.mjs +0 -3
- package/3rdparty/walkontable/src/core/clone.js +0 -1
- package/3rdparty/walkontable/src/core/clone.mjs +0 -1
- package/3rdparty/walkontable/src/core/core.js +0 -2
- package/3rdparty/walkontable/src/core/core.mjs +0 -2
- package/3rdparty/walkontable/src/facade/core.js +0 -3
- package/3rdparty/walkontable/src/facade/core.mjs +0 -3
- package/3rdparty/walkontable/src/index.js +1 -0
- package/3rdparty/walkontable/src/index.mjs +2 -2
- package/3rdparty/walkontable/src/overlay/_base.js +3 -3
- package/3rdparty/walkontable/src/overlay/_base.mjs +3 -3
- package/3rdparty/walkontable/src/overlay/bottom.js +2 -2
- package/3rdparty/walkontable/src/overlay/bottom.mjs +2 -2
- package/3rdparty/walkontable/src/overlay/index.js +2 -0
- package/3rdparty/walkontable/src/overlay/top.js +1 -1
- package/3rdparty/walkontable/src/overlay/top.mjs +1 -1
- package/3rdparty/walkontable/src/overlays.js +3 -0
- package/3rdparty/walkontable/src/overlays.mjs +3 -0
- package/3rdparty/walkontable/src/renderer/index.js +2 -4
- package/3rdparty/walkontable/src/renderer/index.mjs +2 -4
- package/3rdparty/walkontable/src/renderer/table.js +3 -12
- package/3rdparty/walkontable/src/renderer/table.mjs +3 -12
- package/3rdparty/walkontable/src/selection/index.js +2 -0
- package/3rdparty/walkontable/src/selection/manager.js +3 -0
- package/3rdparty/walkontable/src/selection/manager.mjs +3 -0
- package/3rdparty/walkontable/src/settings.js +2 -0
- package/3rdparty/walkontable/src/settings.mjs +2 -0
- package/3rdparty/walkontable/src/table.js +11 -15
- package/3rdparty/walkontable/src/table.mjs +11 -15
- package/3rdparty/walkontable/src/types.js +0 -1
- package/3rdparty/walkontable/src/types.mjs +0 -1
- package/3rdparty/walkontable/src/utils/column.js +1 -1
- package/3rdparty/walkontable/src/utils/column.mjs +1 -1
- package/3rdparty/walkontable/src/viewport.js +1 -1
- package/3rdparty/walkontable/src/viewport.mjs +1 -1
- package/base.js +2 -2
- package/base.mjs +2 -2
- package/core/hooks/bucket.js +4 -0
- package/core/hooks/bucket.mjs +4 -0
- package/core/index.js +2 -0
- package/core.d.ts +0 -2
- package/core.js +4 -46
- package/core.mjs +4 -46
- package/dataMap/dataMap.js +3 -0
- package/dataMap/dataMap.mjs +3 -0
- package/dataMap/dataSource.js +2 -0
- package/dataMap/dataSource.mjs +2 -0
- package/dataMap/metaManager/index.js +2 -0
- package/dataMap/metaManager/index.mjs +2 -0
- package/dataMap/metaManager/metaSchema.js +3 -23
- package/dataMap/metaManager/metaSchema.mjs +3 -23
- package/dataMap/metaManager/mods/extendMetaProperties.js +2 -0
- package/dataMap/metaManager/mods/extendMetaProperties.mjs +2 -0
- package/dist/handsontable.css +9 -17
- package/dist/handsontable.full.css +240 -249
- package/dist/handsontable.full.js +11151 -4977
- package/dist/handsontable.full.min.css +9 -11
- package/dist/handsontable.full.min.js +242 -50
- package/dist/handsontable.js +4804 -4121
- package/dist/handsontable.min.css +4 -5
- package/dist/handsontable.min.js +33 -33
- package/dist/languages/all.js +1 -1
- package/dist/languages/ar-AR.js +1 -1
- package/dist/languages/cs-CZ.js +1 -1
- package/dist/languages/de-CH.js +1 -1
- package/dist/languages/de-DE.js +1 -1
- package/dist/languages/en-US.js +1 -1
- package/dist/languages/es-MX.js +1 -1
- package/dist/languages/fr-FR.js +1 -1
- package/dist/languages/hr-HR.js +1 -1
- package/dist/languages/it-IT.js +1 -1
- package/dist/languages/ja-JP.js +1 -1
- package/dist/languages/ko-KR.js +1 -1
- package/dist/languages/lv-LV.js +1 -1
- package/dist/languages/nb-NO.js +1 -1
- package/dist/languages/nl-NL.js +1 -1
- package/dist/languages/pl-PL.js +1 -1
- package/dist/languages/pt-BR.js +1 -1
- package/dist/languages/ru-RU.js +1 -1
- package/dist/languages/sr-SP.js +1 -1
- package/dist/languages/zh-CN.js +1 -1
- package/dist/languages/zh-TW.js +1 -1
- package/editors/autocompleteEditor/autocompleteEditor.js +5 -1
- package/editors/autocompleteEditor/autocompleteEditor.mjs +5 -1
- package/editors/baseEditor/baseEditor.js +1 -1
- package/editors/baseEditor/baseEditor.mjs +1 -1
- package/editors/dateEditor/dateEditor.js +0 -2
- package/editors/dateEditor/dateEditor.mjs +0 -2
- package/editors/dropdownEditor/dropdownEditor.js +2 -0
- package/editors/dropdownEditor/dropdownEditor.mjs +2 -0
- package/editors/handsontableEditor/handsontableEditor.js +8 -5
- package/editors/handsontableEditor/handsontableEditor.mjs +8 -5
- package/editors/selectEditor/selectEditor.js +9 -20
- package/editors/selectEditor/selectEditor.mjs +9 -20
- package/editors/textEditor/textEditor.js +11 -4
- package/editors/textEditor/textEditor.mjs +11 -4
- package/helpers/array.js +2 -0
- package/helpers/array.mjs +2 -0
- package/helpers/data.js +3 -0
- package/helpers/data.mjs +3 -0
- package/helpers/dom/element.js +3 -31
- package/helpers/dom/element.mjs +3 -30
- package/helpers/mixed.js +2 -2
- package/helpers/mixed.mjs +2 -2
- package/helpers/moves.js +3 -0
- package/helpers/moves.mjs +3 -0
- package/helpers/number.js +1 -0
- package/helpers/number.mjs +1 -0
- package/helpers/object.js +2 -0
- package/helpers/object.mjs +2 -0
- package/i18n/index.js +2 -0
- package/i18n/phraseFormatters/substituteVariables.js +1 -0
- package/i18n/phraseFormatters/substituteVariables.mjs +1 -0
- package/languages/all.js +1 -1
- package/languages/ar-AR.js +1 -1
- package/languages/cs-CZ.js +1 -1
- package/languages/de-CH.js +1 -1
- package/languages/de-DE.js +1 -1
- package/languages/en-US.js +1 -1
- package/languages/es-MX.js +1 -1
- package/languages/fr-FR.js +1 -1
- package/languages/hr-HR.js +1 -1
- package/languages/index.js +1 -1
- package/languages/it-IT.js +1 -1
- package/languages/ja-JP.js +1 -1
- package/languages/ko-KR.js +1 -1
- package/languages/lv-LV.js +1 -1
- package/languages/nb-NO.js +1 -1
- package/languages/nl-NL.js +1 -1
- package/languages/pl-PL.js +1 -1
- package/languages/pt-BR.js +1 -1
- package/languages/ru-RU.js +1 -1
- package/languages/sr-SP.js +1 -1
- package/languages/zh-CN.js +1 -1
- package/languages/zh-TW.js +1 -1
- package/package.json +5 -14
- package/plugins/autoColumnSize/autoColumnSize.js +4 -0
- package/plugins/autoColumnSize/autoColumnSize.mjs +4 -0
- package/plugins/autoRowSize/autoRowSize.js +4 -0
- package/plugins/autoRowSize/autoRowSize.mjs +4 -0
- package/plugins/base/base.js +2 -0
- package/plugins/base/base.mjs +2 -0
- package/plugins/columnSorting/columnSorting.js +2 -0
- package/plugins/columnSorting/columnSorting.mjs +2 -0
- package/plugins/columnSorting/columnStatesManager.js +1 -0
- package/plugins/columnSorting/columnStatesManager.mjs +1 -0
- package/plugins/columnSorting/utils.js +3 -0
- package/plugins/columnSorting/utils.mjs +3 -0
- package/plugins/columnSummary/endpoints.js +3 -0
- package/plugins/columnSummary/endpoints.mjs +3 -0
- package/plugins/comments/commentEditor.js +0 -9
- package/plugins/comments/commentEditor.mjs +0 -9
- package/plugins/comments/comments.js +0 -8
- package/plugins/comments/comments.mjs +0 -8
- package/plugins/comments/editorResizeObserver.js +2 -0
- package/plugins/comments/editorResizeObserver.mjs +2 -0
- package/plugins/contextMenu/menu/index.js +2 -0
- package/plugins/contextMenu/menu/menu.js +4 -3
- package/plugins/contextMenu/menu/menu.mjs +4 -3
- package/plugins/contextMenu/menu/shortcuts.js +2 -0
- package/plugins/contextMenu/menu/shortcuts.mjs +2 -0
- package/plugins/copyPaste/copyPaste.js +3 -0
- package/plugins/copyPaste/copyPaste.mjs +3 -0
- package/plugins/customBorders/utils.js +2 -0
- package/plugins/customBorders/utils.mjs +2 -0
- package/plugins/exportFile/types/csv.js +1 -0
- package/plugins/exportFile/types/csv.mjs +1 -0
- package/plugins/filters/component/condition.js +2 -0
- package/plugins/filters/component/condition.mjs +2 -0
- package/plugins/filters/component/operators.js +2 -0
- package/plugins/filters/component/operators.mjs +2 -0
- package/plugins/filters/component/value.js +3 -0
- package/plugins/filters/component/value.mjs +3 -0
- package/plugins/filters/conditionCollection.js +3 -0
- package/plugins/filters/conditionCollection.mjs +3 -0
- package/plugins/filters/conditionUpdateObserver.js +2 -0
- package/plugins/filters/conditionUpdateObserver.mjs +2 -0
- package/plugins/filters/filters.js +4 -0
- package/plugins/filters/filters.mjs +4 -0
- package/plugins/filters/logicalOperations/conjunction.js +2 -0
- package/plugins/filters/logicalOperations/conjunction.mjs +2 -0
- package/plugins/filters/logicalOperations/disjunction.js +2 -0
- package/plugins/filters/logicalOperations/disjunction.mjs +2 -0
- package/plugins/filters/logicalOperations/disjunctionWithExtraCondition.js +2 -0
- package/plugins/filters/logicalOperations/disjunctionWithExtraCondition.mjs +2 -0
- package/plugins/filters/menu/focusController.js +2 -0
- package/plugins/filters/menu/focusController.mjs +2 -0
- package/plugins/filters/ui/multipleSelect.js +4 -0
- package/plugins/filters/ui/multipleSelect.mjs +4 -0
- package/plugins/formulas/engine/register.js +3 -0
- package/plugins/formulas/engine/register.mjs +3 -0
- package/plugins/formulas/engine/settings.js +3 -0
- package/plugins/formulas/engine/settings.mjs +3 -0
- package/plugins/formulas/formulas.js +5 -0
- package/plugins/formulas/formulas.mjs +5 -0
- package/plugins/formulas/indexSyncer/axisSyncer.js +3 -0
- package/plugins/formulas/indexSyncer/axisSyncer.mjs +3 -0
- package/plugins/hiddenColumns/contextMenuItem/showColumn.js +2 -0
- package/plugins/hiddenColumns/contextMenuItem/showColumn.mjs +2 -0
- package/plugins/hiddenColumns/hiddenColumns.js +3 -0
- package/plugins/hiddenColumns/hiddenColumns.mjs +3 -0
- package/plugins/hiddenRows/contextMenuItem/showRow.js +2 -0
- package/plugins/hiddenRows/contextMenuItem/showRow.mjs +2 -0
- package/plugins/hiddenRows/hiddenRows.js +3 -0
- package/plugins/hiddenRows/hiddenRows.mjs +3 -0
- package/plugins/manualColumnFreeze/manualColumnFreeze.js +2 -0
- package/plugins/manualColumnFreeze/manualColumnFreeze.mjs +2 -0
- package/plugins/manualColumnMove/manualColumnMove.js +2 -0
- package/plugins/manualColumnMove/manualColumnMove.mjs +2 -0
- package/plugins/manualColumnResize/manualColumnResize.js +2 -0
- package/plugins/manualColumnResize/manualColumnResize.mjs +2 -0
- package/plugins/manualRowMove/manualRowMove.js +3 -1
- package/plugins/manualRowMove/manualRowMove.mjs +3 -1
- package/plugins/manualRowResize/manualRowResize.js +4 -1
- package/plugins/manualRowResize/manualRowResize.mjs +5 -2
- package/plugins/mergeCells/cellsCollection.js +4 -0
- package/plugins/mergeCells/cellsCollection.mjs +4 -0
- package/plugins/mergeCells/mergeCells.js +6 -1
- package/plugins/mergeCells/mergeCells.mjs +6 -1
- package/plugins/multiColumnSorting/domHelpers.js +2 -0
- package/plugins/multiColumnSorting/domHelpers.mjs +2 -0
- package/plugins/nestedHeaders/nestedHeaders.js +2 -0
- package/plugins/nestedHeaders/nestedHeaders.mjs +2 -0
- package/plugins/nestedHeaders/stateManager/index.js +1 -0
- package/plugins/nestedHeaders/stateManager/index.mjs +1 -0
- package/plugins/nestedRows/nestedRows.js +3 -0
- package/plugins/nestedRows/nestedRows.mjs +3 -0
- package/plugins/nestedRows/ui/headers.js +1 -7
- package/plugins/nestedRows/ui/headers.mjs +1 -7
- package/plugins/nestedRows/utils/rowMoveController.js +4 -0
- package/plugins/nestedRows/utils/rowMoveController.mjs +4 -0
- package/plugins/stretchColumns/calculator.js +3 -2
- package/plugins/stretchColumns/calculator.mjs +4 -3
- package/plugins/stretchColumns/strategies/all.js +3 -0
- package/plugins/stretchColumns/strategies/all.mjs +3 -0
- package/plugins/stretchColumns/strategies/last.js +2 -0
- package/plugins/stretchColumns/strategies/last.mjs +2 -0
- package/plugins/stretchColumns/stretchColumns.js +2 -0
- package/plugins/stretchColumns/stretchColumns.mjs +2 -0
- package/plugins/trimRows/trimRows.js +2 -0
- package/plugins/trimRows/trimRows.mjs +2 -0
- package/plugins/undoRedo/undoRedo.js +5 -0
- package/plugins/undoRedo/undoRedo.mjs +5 -0
- package/renderers/checkboxRenderer/checkboxRenderer.js +3 -0
- package/renderers/checkboxRenderer/checkboxRenderer.mjs +3 -0
- package/selection/index.js +2 -0
- package/selection/range.js +2 -0
- package/selection/range.mjs +2 -0
- package/selection/selection.js +3 -0
- package/selection/selection.mjs +3 -0
- package/selection/utils.js +2 -0
- package/selection/utils.mjs +2 -0
- package/settings.d.ts +0 -1
- package/shortcutContexts/commands/index.js +2 -0
- package/shortcutContexts/commands/index.mjs +2 -0
- package/shortcutContexts/index.js +2 -0
- package/shortcutContexts/index.mjs +2 -0
- package/shortcuts/context.js +3 -0
- package/shortcuts/context.mjs +3 -0
- package/shortcuts/utils.js +1 -0
- package/shortcuts/utils.mjs +1 -0
- package/tableView.js +0 -46
- package/tableView.mjs +1 -47
- package/translations/changesObservable/observable.js +2 -0
- package/translations/changesObservable/observable.mjs +2 -0
- package/translations/index.js +2 -0
- package/translations/indexMapper.js +4 -0
- package/translations/indexMapper.mjs +4 -0
- package/translations/mapCollections/index.js +2 -0
- package/translations/mapCollections/mapCollection.js +2 -0
- package/translations/mapCollections/mapCollection.mjs +2 -0
- package/translations/maps/index.js +2 -0
- package/translations/maps/linkedPhysicalIndexToValueMap.js +1 -0
- package/translations/maps/linkedPhysicalIndexToValueMap.mjs +1 -0
- package/translations/maps/utils/actionsOnIndexes.js +2 -0
- package/translations/maps/utils/actionsOnIndexes.mjs +2 -0
- package/translations/maps/utils/physicallyIndexed.js +1 -0
- package/translations/maps/utils/physicallyIndexed.mjs +1 -0
- package/utils/autoResize.js +1 -4
- package/utils/autoResize.mjs +1 -4
- package/utils/dataStructures/priorityMap.js +1 -0
- package/utils/dataStructures/priorityMap.mjs +1 -0
- package/utils/dataStructures/uniqueMap.js +2 -0
- package/utils/dataStructures/uniqueMap.mjs +2 -0
- package/utils/ghostTable.js +5 -5
- package/utils/ghostTable.mjs +5 -5
- package/utils/parseTable.js +4 -0
- package/utils/parseTable.mjs +4 -0
- package/3rdparty/walkontable/src/utils/stylesHandler.js +0 -271
- package/3rdparty/walkontable/src/utils/stylesHandler.mjs +0 -267
- package/helpers/themes.js +0 -17
- package/helpers/themes.mjs +0 -13
- package/styles/handsontable.css +0 -2053
- package/styles/handsontable.min.css +0 -30
- package/styles/ht-theme-horizon.css +0 -571
- package/styles/ht-theme-horizon.min.css +0 -30
- package/styles/ht-theme-main.css +0 -575
- package/styles/ht-theme-main.min.css +0 -30
@@ -21,4 +21,5 @@ var _viewportColumns = require("./viewportColumns");
|
|
21
21
|
exports.ViewportColumnsCalculator = _viewportColumns.ViewportColumnsCalculator;
|
22
22
|
exports.DEFAULT_COLUMN_WIDTH = _viewportColumns.DEFAULT_WIDTH;
|
23
23
|
var _viewportRows = require("./viewportRows");
|
24
|
-
exports.ViewportRowsCalculator = _viewportRows.ViewportRowsCalculator;
|
24
|
+
exports.ViewportRowsCalculator = _viewportRows.ViewportRowsCalculator;
|
25
|
+
exports.DEFAULT_ROW_HEIGHT = _viewportRows.DEFAULT_HEIGHT;
|
@@ -7,5 +7,5 @@ import { RenderedAllRowsCalculationType } from "./calculationType/renderedAllRow
|
|
7
7
|
import { RenderedColumnsCalculationType } from "./calculationType/renderedColumns.mjs";
|
8
8
|
import { RenderedRowsCalculationType } from "./calculationType/renderedRows.mjs";
|
9
9
|
import { ViewportColumnsCalculator, DEFAULT_WIDTH } from "./viewportColumns.mjs";
|
10
|
-
import { ViewportRowsCalculator } from "./viewportRows.mjs";
|
11
|
-
export { DEFAULT_WIDTH as DEFAULT_COLUMN_WIDTH, FullyVisibleColumnsCalculationType, FullyVisibleRowsCalculationType, PartiallyVisibleColumnsCalculationType, PartiallyVisibleRowsCalculationType, RenderedAllColumnsCalculationType, RenderedAllRowsCalculationType, RenderedColumnsCalculationType, RenderedRowsCalculationType, ViewportColumnsCalculator, ViewportRowsCalculator };
|
10
|
+
import { ViewportRowsCalculator, DEFAULT_HEIGHT } from "./viewportRows.mjs";
|
11
|
+
export { DEFAULT_HEIGHT as DEFAULT_ROW_HEIGHT, DEFAULT_WIDTH as DEFAULT_COLUMN_WIDTH, FullyVisibleColumnsCalculationType, FullyVisibleRowsCalculationType, PartiallyVisibleColumnsCalculationType, PartiallyVisibleRowsCalculationType, RenderedAllColumnsCalculationType, RenderedAllRowsCalculationType, RenderedColumnsCalculationType, RenderedRowsCalculationType, ViewportColumnsCalculator, ViewportRowsCalculator };
|
@@ -2,6 +2,8 @@
|
|
2
2
|
|
3
3
|
exports.__esModule = true;
|
4
4
|
require("core-js/modules/es.error.cause.js");
|
5
|
+
require("core-js/modules/esnext.iterator.constructor.js");
|
6
|
+
require("core-js/modules/esnext.iterator.for-each.js");
|
5
7
|
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; }
|
6
8
|
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == typeof i ? i : i + ""; }
|
7
9
|
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); }
|
@@ -1,4 +1,6 @@
|
|
1
1
|
import "core-js/modules/es.error.cause.js";
|
2
|
+
import "core-js/modules/esnext.iterator.constructor.js";
|
3
|
+
import "core-js/modules/esnext.iterator.for-each.js";
|
2
4
|
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; }
|
3
5
|
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == typeof i ? i : i + ""; }
|
4
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,6 +7,8 @@ var _viewportBase = require("./viewportBase");
|
|
7
7
|
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; }
|
8
8
|
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == typeof i ? i : i + ""; }
|
9
9
|
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); }
|
10
|
+
const DEFAULT_HEIGHT = exports.DEFAULT_HEIGHT = 23;
|
11
|
+
|
10
12
|
/**
|
11
13
|
* @typedef {object} ViewportRowsCalculatorOptions
|
12
14
|
* @property {Map<string, ViewportBaseCalculator>} calculationTypes The calculation types to be performed.
|
@@ -32,7 +34,6 @@ class ViewportRowsCalculator extends _viewportBase.ViewportBaseCalculator {
|
|
32
34
|
viewportHeight,
|
33
35
|
scrollOffset,
|
34
36
|
totalRows,
|
35
|
-
defaultRowHeight,
|
36
37
|
rowHeightFn,
|
37
38
|
overrideFn,
|
38
39
|
horizontalScrollbarHeight
|
@@ -50,7 +51,6 @@ class ViewportRowsCalculator extends _viewportBase.ViewportBaseCalculator {
|
|
50
51
|
_defineProperty(this, "totalCalculatedHeight", 0);
|
51
52
|
_defineProperty(this, "startPositions", []);
|
52
53
|
_defineProperty(this, "needReverse", true);
|
53
|
-
this.defaultHeight = defaultRowHeight;
|
54
54
|
this.viewportHeight = viewportHeight;
|
55
55
|
this.scrollOffset = scrollOffset;
|
56
56
|
this.zeroBasedScrollOffset = Math.max(scrollOffset, 0);
|
@@ -89,7 +89,7 @@ class ViewportRowsCalculator extends _viewportBase.ViewportBaseCalculator {
|
|
89
89
|
getRowHeight(row) {
|
90
90
|
const rowHeight = this.rowHeightFn(row);
|
91
91
|
if (isNaN(rowHeight)) {
|
92
|
-
return
|
92
|
+
return DEFAULT_HEIGHT;
|
93
93
|
}
|
94
94
|
return rowHeight;
|
95
95
|
}
|
@@ -4,6 +4,8 @@ function _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object
|
|
4
4
|
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == typeof i ? i : 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); }
|
6
6
|
import { ViewportBaseCalculator } from "./viewportBase.mjs";
|
7
|
+
export const DEFAULT_HEIGHT = 23;
|
8
|
+
|
7
9
|
/**
|
8
10
|
* @typedef {object} ViewportRowsCalculatorOptions
|
9
11
|
* @property {Map<string, ViewportBaseCalculator>} calculationTypes The calculation types to be performed.
|
@@ -29,7 +31,6 @@ export class ViewportRowsCalculator extends ViewportBaseCalculator {
|
|
29
31
|
viewportHeight,
|
30
32
|
scrollOffset,
|
31
33
|
totalRows,
|
32
|
-
defaultRowHeight,
|
33
34
|
rowHeightFn,
|
34
35
|
overrideFn,
|
35
36
|
horizontalScrollbarHeight
|
@@ -47,7 +48,6 @@ export class ViewportRowsCalculator extends ViewportBaseCalculator {
|
|
47
48
|
_defineProperty(this, "totalCalculatedHeight", 0);
|
48
49
|
_defineProperty(this, "startPositions", []);
|
49
50
|
_defineProperty(this, "needReverse", true);
|
50
|
-
this.defaultHeight = defaultRowHeight;
|
51
51
|
this.viewportHeight = viewportHeight;
|
52
52
|
this.scrollOffset = scrollOffset;
|
53
53
|
this.zeroBasedScrollOffset = Math.max(scrollOffset, 0);
|
@@ -86,7 +86,7 @@ export class ViewportRowsCalculator extends ViewportBaseCalculator {
|
|
86
86
|
getRowHeight(row) {
|
87
87
|
const rowHeight = this.rowHeightFn(row);
|
88
88
|
if (isNaN(rowHeight)) {
|
89
|
-
return
|
89
|
+
return DEFAULT_HEIGHT;
|
90
90
|
}
|
91
91
|
return rowHeight;
|
92
92
|
}
|
@@ -305,9 +305,6 @@ export default class CoreAbstract {
|
|
305
305
|
get selectionManager() {
|
306
306
|
return wot.selectionManager; // TODO refactoring: move outside dao, use IOC
|
307
307
|
},
|
308
|
-
get stylesHandler() {
|
309
|
-
return wot.stylesHandler;
|
310
|
-
},
|
311
308
|
get drawn() {
|
312
309
|
return wot.drawn;
|
313
310
|
},
|
@@ -30,7 +30,6 @@ class Clone extends _base.default {
|
|
30
30
|
const facadeGetter = this.wtSettings.getSetting('facade', this);
|
31
31
|
this.cloneSource = clone.source;
|
32
32
|
this.cloneOverlay = clone.overlay;
|
33
|
-
this.stylesHandler = clone.stylesHandler;
|
34
33
|
this.wtTable = this.cloneOverlay.createTable(this.getTableDao(), facadeGetter, this.domBindings, this.wtSettings);
|
35
34
|
this.wtViewport = clone.viewport;
|
36
35
|
this.selectionManager = clone.selectionManager;
|
@@ -26,7 +26,6 @@ export default class Clone extends CoreAbstract {
|
|
26
26
|
const facadeGetter = this.wtSettings.getSetting('facade', this);
|
27
27
|
this.cloneSource = clone.source;
|
28
28
|
this.cloneOverlay = clone.overlay;
|
29
|
-
this.stylesHandler = clone.stylesHandler;
|
30
29
|
this.wtTable = this.cloneOverlay.createTable(this.getTableDao(), facadeGetter, this.domBindings, this.wtSettings);
|
31
30
|
this.wtViewport = clone.viewport;
|
32
31
|
this.selectionManager = clone.selectionManager;
|
@@ -12,7 +12,6 @@ var _base = _interopRequireDefault(require("./_base"));
|
|
12
12
|
var _manager = require("../selection/manager");
|
13
13
|
var _object = require("../../../../helpers/object");
|
14
14
|
var _element = require("../../../../helpers/dom/element");
|
15
|
-
var _stylesHandler = require("../utils/stylesHandler");
|
16
15
|
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
17
16
|
/**
|
18
17
|
* @class Walkontable
|
@@ -24,7 +23,6 @@ class Walkontable extends _base.default {
|
|
24
23
|
*/
|
25
24
|
constructor(table, settings) {
|
26
25
|
super(table, new _settings.default(settings));
|
27
|
-
this.stylesHandler = new _stylesHandler.StylesHandler(this.domBindings);
|
28
26
|
const facadeGetter = this.wtSettings.getSetting('facade', this); // todo rethink. I would like to have no access to facade from the internal scope.
|
29
27
|
|
30
28
|
this.wtTable = new _master.default(this.getTableDao(), facadeGetter, this.domBindings, this.wtSettings);
|
@@ -9,7 +9,6 @@ import CoreAbstract from "./_base.mjs";
|
|
9
9
|
import { SelectionManager } from "../selection/manager.mjs";
|
10
10
|
import { objectEach } from "../../../../helpers/object.mjs";
|
11
11
|
import { addClass, removeClass } from "../../../../helpers/dom/element.mjs";
|
12
|
-
import { StylesHandler } from "../utils/stylesHandler.mjs";
|
13
12
|
/**
|
14
13
|
* @class Walkontable
|
15
14
|
*/
|
@@ -20,7 +19,6 @@ export default class Walkontable extends CoreAbstract {
|
|
20
19
|
*/
|
21
20
|
constructor(table, settings) {
|
22
21
|
super(table, new Settings(settings));
|
23
|
-
this.stylesHandler = new StylesHandler(this.domBindings);
|
24
22
|
const facadeGetter = this.wtSettings.getSetting('facade', this); // todo rethink. I would like to have no access to facade from the internal scope.
|
25
23
|
|
26
24
|
this.wtTable = new MasterTable(this.getTableDao(), facadeGetter, this.domBindings, this.wtSettings);
|
@@ -110,9 +110,6 @@ class WalkontableFacade {
|
|
110
110
|
get eventManager() {
|
111
111
|
return this._wot.eventManager;
|
112
112
|
}
|
113
|
-
get stylesHandler() {
|
114
|
-
return this._wot.stylesHandler;
|
115
|
-
}
|
116
113
|
createCellCoords(row, column) {
|
117
114
|
return this._wot.createCellCoords(row, column);
|
118
115
|
}
|
@@ -106,9 +106,6 @@ export default class WalkontableFacade {
|
|
106
106
|
get eventManager() {
|
107
107
|
return this._wot.eventManager;
|
108
108
|
}
|
109
|
-
get stylesHandler() {
|
110
|
-
return this._wot.stylesHandler;
|
111
|
-
}
|
112
109
|
createCellCoords(row, column) {
|
113
110
|
return this._wot.createCellCoords(row, column);
|
114
111
|
}
|
@@ -4,6 +4,7 @@ exports.__esModule = true;
|
|
4
4
|
var _calculator = require("./calculator");
|
5
5
|
exports.ViewportColumnsCalculator = _calculator.ViewportColumnsCalculator;
|
6
6
|
exports.ViewportRowsCalculator = _calculator.ViewportRowsCalculator;
|
7
|
+
exports.DEFAULT_ROW_HEIGHT = _calculator.DEFAULT_ROW_HEIGHT;
|
7
8
|
exports.DEFAULT_COLUMN_WIDTH = _calculator.DEFAULT_COLUMN_WIDTH;
|
8
9
|
var _coords = _interopRequireDefault(require("./cell/coords"));
|
9
10
|
exports.CellCoords = _coords.default;
|
@@ -1,4 +1,4 @@
|
|
1
|
-
import { ViewportColumnsCalculator, ViewportRowsCalculator, DEFAULT_COLUMN_WIDTH } from "./calculator/index.mjs";
|
1
|
+
import { ViewportColumnsCalculator, ViewportRowsCalculator, DEFAULT_ROW_HEIGHT, DEFAULT_COLUMN_WIDTH } from "./calculator/index.mjs";
|
2
2
|
import CellCoords from "./cell/coords.mjs";
|
3
3
|
import CellRange from "./cell/range.mjs";
|
4
4
|
import Walkontable from "./facade/core.mjs";
|
@@ -6,4 +6,4 @@ import { Selection, ACTIVE_HEADER_TYPE, AREA_TYPE, FOCUS_TYPE, FILL_TYPE, HEADER
|
|
6
6
|
import * as Renderer from "./renderer/index.mjs";
|
7
7
|
import { OrderView, SharedOrderView } from "./utils/orderView/index.mjs";
|
8
8
|
import { getListenersCounter } from "../../../eventManager.mjs";
|
9
|
-
export { DEFAULT_COLUMN_WIDTH, ViewportColumnsCalculator, ViewportRowsCalculator, CellCoords, CellRange, Walkontable as default, Walkontable as Core, Selection, ACTIVE_HEADER_TYPE as HIGHLIGHT_ACTIVE_HEADER_TYPE, AREA_TYPE as HIGHLIGHT_AREA_TYPE, FOCUS_TYPE as HIGHLIGHT_FOCUS_TYPE, FILL_TYPE as HIGHLIGHT_FILL_TYPE, HEADER_TYPE as HIGHLIGHT_HEADER_TYPE, ROW_TYPE as HIGHLIGHT_ROW_TYPE, COLUMN_TYPE as HIGHLIGHT_COLUMN_TYPE, CUSTOM_SELECTION_TYPE as HIGHLIGHT_CUSTOM_SELECTION_TYPE, Renderer, OrderView, SharedOrderView, getListenersCounter };
|
9
|
+
export { DEFAULT_ROW_HEIGHT, DEFAULT_COLUMN_WIDTH, ViewportColumnsCalculator, ViewportRowsCalculator, CellCoords, CellRange, Walkontable as default, Walkontable as Core, Selection, ACTIVE_HEADER_TYPE as HIGHLIGHT_ACTIVE_HEADER_TYPE, AREA_TYPE as HIGHLIGHT_AREA_TYPE, FOCUS_TYPE as HIGHLIGHT_FOCUS_TYPE, FILL_TYPE as HIGHLIGHT_FILL_TYPE, HEADER_TYPE as HIGHLIGHT_HEADER_TYPE, ROW_TYPE as HIGHLIGHT_ROW_TYPE, COLUMN_TYPE as HIGHLIGHT_COLUMN_TYPE, CUSTOM_SELECTION_TYPE as HIGHLIGHT_CUSTOM_SELECTION_TYPE, Renderer, OrderView, SharedOrderView, getListenersCounter };
|
@@ -2,6 +2,8 @@
|
|
2
2
|
|
3
3
|
exports.__esModule = true;
|
4
4
|
require("core-js/modules/es.error.cause.js");
|
5
|
+
require("core-js/modules/esnext.iterator.constructor.js");
|
6
|
+
require("core-js/modules/esnext.iterator.for-each.js");
|
5
7
|
var _element = require("../../../../helpers/dom/element");
|
6
8
|
var _object = require("../../../../helpers/object");
|
7
9
|
var _console = require("../../../../helpers/console");
|
@@ -302,9 +304,7 @@ class Overlay {
|
|
302
304
|
// todo ioc , or factor func if used only here
|
303
305
|
event: this.wot.wtEvent,
|
304
306
|
// todo ioc , or factory func if used only here
|
305
|
-
selectionManager: this.wot.selectionManager,
|
306
|
-
// todo ioc , or factory func if used only here
|
307
|
-
stylesHandler: this.wot.stylesHandler
|
307
|
+
selectionManager: this.wot.selectionManager // todo ioc , or factory func if used only here
|
308
308
|
});
|
309
309
|
}
|
310
310
|
|
@@ -1,4 +1,6 @@
|
|
1
1
|
import "core-js/modules/es.error.cause.js";
|
2
|
+
import "core-js/modules/esnext.iterator.constructor.js";
|
3
|
+
import "core-js/modules/esnext.iterator.for-each.js";
|
2
4
|
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; }
|
3
5
|
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == typeof i ? i : i + ""; }
|
4
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); }
|
@@ -298,9 +300,7 @@ export class Overlay {
|
|
298
300
|
// todo ioc , or factor func if used only here
|
299
301
|
event: this.wot.wtEvent,
|
300
302
|
// todo ioc , or factory func if used only here
|
301
|
-
selectionManager: this.wot.selectionManager,
|
302
|
-
// todo ioc , or factory func if used only here
|
303
|
-
stylesHandler: this.wot.stylesHandler
|
303
|
+
selectionManager: this.wot.selectionManager // todo ioc , or factory func if used only here
|
304
304
|
});
|
305
305
|
}
|
306
306
|
|
@@ -144,9 +144,9 @@ class BottomOverlay extends _base.Overlay {
|
|
144
144
|
sumCellSizes(from, to) {
|
145
145
|
const {
|
146
146
|
wtTable,
|
147
|
-
|
147
|
+
wtSettings
|
148
148
|
} = this.wot;
|
149
|
-
const defaultRowHeight =
|
149
|
+
const defaultRowHeight = wtSettings.getSetting('defaultRowHeight');
|
150
150
|
let row = from;
|
151
151
|
let sum = 0;
|
152
152
|
while (row < to) {
|
@@ -140,9 +140,9 @@ export class BottomOverlay extends Overlay {
|
|
140
140
|
sumCellSizes(from, to) {
|
141
141
|
const {
|
142
142
|
wtTable,
|
143
|
-
|
143
|
+
wtSettings
|
144
144
|
} = this.wot;
|
145
|
-
const defaultRowHeight =
|
145
|
+
const defaultRowHeight = wtSettings.getSetting('defaultRowHeight');
|
146
146
|
let row = from;
|
147
147
|
let sum = 0;
|
148
148
|
while (row < to) {
|
@@ -138,7 +138,7 @@ class TopOverlay extends _base.Overlay {
|
|
138
138
|
* @returns {number} Height sum.
|
139
139
|
*/
|
140
140
|
sumCellSizes(from, to) {
|
141
|
-
const defaultRowHeight = this.
|
141
|
+
const defaultRowHeight = this.wtSettings.getSetting('defaultRowHeight');
|
142
142
|
let row = from;
|
143
143
|
let sum = 0;
|
144
144
|
while (row < to) {
|
@@ -134,7 +134,7 @@ export class TopOverlay extends Overlay {
|
|
134
134
|
* @returns {number} Height sum.
|
135
135
|
*/
|
136
136
|
sumCellSizes(from, to) {
|
137
|
-
const defaultRowHeight = this.
|
137
|
+
const defaultRowHeight = this.wtSettings.getSetting('defaultRowHeight');
|
138
138
|
let row = from;
|
139
139
|
let sum = 0;
|
140
140
|
while (row < to) {
|
@@ -3,6 +3,9 @@
|
|
3
3
|
exports.__esModule = true;
|
4
4
|
require("core-js/modules/es.error.cause.js");
|
5
5
|
require("core-js/modules/es.array.push.js");
|
6
|
+
require("core-js/modules/esnext.iterator.constructor.js");
|
7
|
+
require("core-js/modules/esnext.iterator.for-each.js");
|
8
|
+
require("core-js/modules/esnext.iterator.reduce.js");
|
6
9
|
var _element = require("../../../helpers/dom/element");
|
7
10
|
var _feature = require("../../../helpers/feature");
|
8
11
|
var _array = require("../../../helpers/array");
|
@@ -1,5 +1,8 @@
|
|
1
1
|
import "core-js/modules/es.error.cause.js";
|
2
2
|
import "core-js/modules/es.array.push.js";
|
3
|
+
import "core-js/modules/esnext.iterator.constructor.js";
|
4
|
+
import "core-js/modules/esnext.iterator.for-each.js";
|
5
|
+
import "core-js/modules/esnext.iterator.reduce.js";
|
3
6
|
function _classPrivateFieldInitSpec(e, t, a) { _checkPrivateRedeclaration(e, t), t.set(e, a); }
|
4
7
|
function _checkPrivateRedeclaration(e, t) { if (t.has(e)) throw new TypeError("Cannot initialize the same private elements twice on an object"); }
|
5
8
|
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; }
|
@@ -28,8 +28,7 @@ class Renderer {
|
|
28
28
|
TBODY,
|
29
29
|
rowUtils,
|
30
30
|
columnUtils,
|
31
|
-
cellRenderer
|
32
|
-
stylesHandler
|
31
|
+
cellRenderer
|
33
32
|
} = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
34
33
|
/**
|
35
34
|
* General renderer class used to render Walkontable content on screen.
|
@@ -37,8 +36,7 @@ class Renderer {
|
|
37
36
|
* @type {TableRenderer}
|
38
37
|
*/
|
39
38
|
this.renderer = new _table.default(TABLE, {
|
40
|
-
cellRenderer
|
41
|
-
stylesHandler
|
39
|
+
cellRenderer
|
42
40
|
});
|
43
41
|
this.renderer.setRenderers({
|
44
42
|
rowHeaders: new _rowHeaders.default(),
|
@@ -18,8 +18,7 @@ class Renderer {
|
|
18
18
|
TBODY,
|
19
19
|
rowUtils,
|
20
20
|
columnUtils,
|
21
|
-
cellRenderer
|
22
|
-
stylesHandler
|
21
|
+
cellRenderer
|
23
22
|
} = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
24
23
|
/**
|
25
24
|
* General renderer class used to render Walkontable content on screen.
|
@@ -27,8 +26,7 @@ class Renderer {
|
|
27
26
|
* @type {TableRenderer}
|
28
27
|
*/
|
29
28
|
this.renderer = new TableRenderer(TABLE, {
|
30
|
-
cellRenderer
|
31
|
-
stylesHandler
|
29
|
+
cellRenderer
|
32
30
|
});
|
33
31
|
this.renderer.setRenderers({
|
34
32
|
rowHeaders: new RowHeadersRenderer(),
|
@@ -52,8 +52,7 @@ function _toPrimitive(t, r) { if ("object" != typeof t || !t) return t; var e =
|
|
52
52
|
class TableRenderer {
|
53
53
|
constructor(rootNode) {
|
54
54
|
let {
|
55
|
-
cellRenderer
|
56
|
-
stylesHandler
|
55
|
+
cellRenderer
|
57
56
|
} = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
|
58
57
|
/**
|
59
58
|
* Table element which will be used to render the children element.
|
@@ -169,14 +168,9 @@ class TableRenderer {
|
|
169
168
|
* @type {'inline_start'|'top'|'top_inline_start_corner'|'bottom'|'bottom_inline_start_corner'|'master'}
|
170
169
|
*/
|
171
170
|
_defineProperty(this, "activeOverlayName", void 0);
|
172
|
-
/**
|
173
|
-
* Styles handler instance.
|
174
|
-
*/
|
175
|
-
_defineProperty(this, "stylesHandler", void 0);
|
176
171
|
this.rootNode = rootNode;
|
177
172
|
this.rootDocument = this.rootNode.ownerDocument;
|
178
173
|
this.cellRenderer = cellRenderer;
|
179
|
-
this.stylesHandler = stylesHandler;
|
180
174
|
}
|
181
175
|
|
182
176
|
/**
|
@@ -319,15 +313,12 @@ class TableRenderer {
|
|
319
313
|
// Fix for multi-line content and for supporting `rowHeights` option.
|
320
314
|
for (let visibleRowIndex = 0; visibleRowIndex < rowsToRender; visibleRowIndex++) {
|
321
315
|
const TR = rows.getRenderedNode(visibleRowIndex);
|
322
|
-
const rowUtils = this.rowUtils;
|
323
316
|
if (TR.firstChild) {
|
324
317
|
const sourceRowIndex = this.renderedRowToSource(visibleRowIndex);
|
325
|
-
const rowHeight = rowUtils.getHeightByOverlayName(sourceRowIndex, this.activeOverlayName);
|
326
|
-
const isBorderBoxSizing = this.stylesHandler.areCellsBorderBox();
|
327
|
-
const borderCompensation = isBorderBoxSizing ? 0 : 1;
|
318
|
+
const rowHeight = this.rowUtils.getHeightByOverlayName(sourceRowIndex, this.activeOverlayName);
|
328
319
|
if (rowHeight) {
|
329
320
|
// Decrease height. 1 pixel will be "replaced" by 1px border top
|
330
|
-
TR.firstChild.style.height = `${rowHeight -
|
321
|
+
TR.firstChild.style.height = `${rowHeight - 1}px`;
|
331
322
|
} else {
|
332
323
|
TR.firstChild.style.height = '';
|
333
324
|
}
|
@@ -49,8 +49,7 @@ function _toPrimitive(t, r) { if ("object" != typeof t || !t) return t; var e =
|
|
49
49
|
export default class TableRenderer {
|
50
50
|
constructor(rootNode) {
|
51
51
|
let {
|
52
|
-
cellRenderer
|
53
|
-
stylesHandler
|
52
|
+
cellRenderer
|
54
53
|
} = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
|
55
54
|
/**
|
56
55
|
* Table element which will be used to render the children element.
|
@@ -166,14 +165,9 @@ export default class TableRenderer {
|
|
166
165
|
* @type {'inline_start'|'top'|'top_inline_start_corner'|'bottom'|'bottom_inline_start_corner'|'master'}
|
167
166
|
*/
|
168
167
|
_defineProperty(this, "activeOverlayName", void 0);
|
169
|
-
/**
|
170
|
-
* Styles handler instance.
|
171
|
-
*/
|
172
|
-
_defineProperty(this, "stylesHandler", void 0);
|
173
168
|
this.rootNode = rootNode;
|
174
169
|
this.rootDocument = this.rootNode.ownerDocument;
|
175
170
|
this.cellRenderer = cellRenderer;
|
176
|
-
this.stylesHandler = stylesHandler;
|
177
171
|
}
|
178
172
|
|
179
173
|
/**
|
@@ -316,15 +310,12 @@ export default class TableRenderer {
|
|
316
310
|
// Fix for multi-line content and for supporting `rowHeights` option.
|
317
311
|
for (let visibleRowIndex = 0; visibleRowIndex < rowsToRender; visibleRowIndex++) {
|
318
312
|
const TR = rows.getRenderedNode(visibleRowIndex);
|
319
|
-
const rowUtils = this.rowUtils;
|
320
313
|
if (TR.firstChild) {
|
321
314
|
const sourceRowIndex = this.renderedRowToSource(visibleRowIndex);
|
322
|
-
const rowHeight = rowUtils.getHeightByOverlayName(sourceRowIndex, this.activeOverlayName);
|
323
|
-
const isBorderBoxSizing = this.stylesHandler.areCellsBorderBox();
|
324
|
-
const borderCompensation = isBorderBoxSizing ? 0 : 1;
|
315
|
+
const rowHeight = this.rowUtils.getHeightByOverlayName(sourceRowIndex, this.activeOverlayName);
|
325
316
|
if (rowHeight) {
|
326
317
|
// Decrease height. 1 pixel will be "replaced" by 1px border top
|
327
|
-
TR.firstChild.style.height = `${rowHeight -
|
318
|
+
TR.firstChild.style.height = `${rowHeight - 1}px`;
|
328
319
|
} else {
|
329
320
|
TR.firstChild.style.height = '';
|
330
321
|
}
|
@@ -11,6 +11,9 @@ require("core-js/modules/es.set.is-subset-of.v2.js");
|
|
11
11
|
require("core-js/modules/es.set.is-superset-of.v2.js");
|
12
12
|
require("core-js/modules/es.set.symmetric-difference.v2.js");
|
13
13
|
require("core-js/modules/es.set.union.v2.js");
|
14
|
+
require("core-js/modules/esnext.iterator.constructor.js");
|
15
|
+
require("core-js/modules/esnext.iterator.for-each.js");
|
16
|
+
require("core-js/modules/esnext.iterator.map.js");
|
14
17
|
var _element = require("../../../../helpers/dom/element");
|
15
18
|
var _scanner2 = require("./scanner");
|
16
19
|
var _border = _interopRequireDefault(require("./border/border"));
|
@@ -8,6 +8,9 @@ import "core-js/modules/es.set.is-subset-of.v2.js";
|
|
8
8
|
import "core-js/modules/es.set.is-superset-of.v2.js";
|
9
9
|
import "core-js/modules/es.set.symmetric-difference.v2.js";
|
10
10
|
import "core-js/modules/es.set.union.v2.js";
|
11
|
+
import "core-js/modules/esnext.iterator.constructor.js";
|
12
|
+
import "core-js/modules/esnext.iterator.for-each.js";
|
13
|
+
import "core-js/modules/esnext.iterator.map.js";
|
11
14
|
function _classPrivateMethodInitSpec(e, a) { _checkPrivateRedeclaration(e, a), a.add(e); }
|
12
15
|
function _classPrivateFieldInitSpec(e, t, a) { _checkPrivateRedeclaration(e, t), t.set(e, a); }
|
13
16
|
function _checkPrivateRedeclaration(e, t) { if (t.has(e)) throw new TypeError("Cannot initialize the same private elements twice on an object"); }
|
@@ -19,6 +19,7 @@ function _toPrimitive(t, r) { if ("object" != typeof t || !t) return t; var e =
|
|
19
19
|
* @property {Option} currentRowClassName Option `currentRowClassName`.
|
20
20
|
* @property {Option} data Option `data`.
|
21
21
|
* @property {Option} defaultColumnWidth Option `defaultColumnWidth`.
|
22
|
+
* @property {Option} defaultRowHeight Option `defaultRowHeight`.
|
22
23
|
* @property {Option} externalRowCalculator Option `externalRowCalculator`.
|
23
24
|
* @property {Option} fixedColumnsStart Option `fixedColumnsStart`.
|
24
25
|
* @property {Option} fixedRowsBottom Option `fixedRowsBottom`.
|
@@ -184,6 +185,7 @@ class Settings {
|
|
184
185
|
rowHeightByOverlayName() {
|
185
186
|
// return undefined means use default size for the rendered cell content
|
186
187
|
},
|
188
|
+
defaultRowHeight: 23,
|
187
189
|
defaultColumnWidth: 50,
|
188
190
|
selections: null,
|
189
191
|
hideBorderOnMouseDownOver: false,
|
@@ -16,6 +16,7 @@ import { objectEach } from "../../../helpers/object.mjs";
|
|
16
16
|
* @property {Option} currentRowClassName Option `currentRowClassName`.
|
17
17
|
* @property {Option} data Option `data`.
|
18
18
|
* @property {Option} defaultColumnWidth Option `defaultColumnWidth`.
|
19
|
+
* @property {Option} defaultRowHeight Option `defaultRowHeight`.
|
19
20
|
* @property {Option} externalRowCalculator Option `externalRowCalculator`.
|
20
21
|
* @property {Option} fixedColumnsStart Option `fixedColumnsStart`.
|
21
22
|
* @property {Option} fixedRowsBottom Option `fixedRowsBottom`.
|
@@ -179,6 +180,7 @@ export default class Settings {
|
|
179
180
|
rowHeightByOverlayName() {
|
180
181
|
// return undefined means use default size for the rendered cell content
|
181
182
|
},
|
183
|
+
defaultRowHeight: 23,
|
182
184
|
defaultColumnWidth: 50,
|
183
185
|
selections: null,
|
184
186
|
hideBorderOnMouseDownOver: false,
|
@@ -3,6 +3,8 @@
|
|
3
3
|
exports.__esModule = true;
|
4
4
|
require("core-js/modules/es.error.cause.js");
|
5
5
|
require("core-js/modules/es.array.push.js");
|
6
|
+
require("core-js/modules/esnext.iterator.constructor.js");
|
7
|
+
require("core-js/modules/esnext.iterator.for-each.js");
|
6
8
|
var _element = require("../../../helpers/dom/element");
|
7
9
|
var _function = require("../../../helpers/function");
|
8
10
|
var _column = _interopRequireDefault(require("./filter/column"));
|
@@ -115,8 +117,7 @@ class Table {
|
|
115
117
|
TBODY: this.TBODY,
|
116
118
|
rowUtils: this.rowUtils,
|
117
119
|
columnUtils: this.columnUtils,
|
118
|
-
cellRenderer: this.wtSettings.getSettingPure('cellRenderer')
|
119
|
-
stylesHandler: this.dataAccessObject.stylesHandler
|
120
|
+
cellRenderer: this.wtSettings.getSettingPure('cellRenderer')
|
120
121
|
});
|
121
122
|
}
|
122
123
|
|
@@ -352,7 +353,7 @@ class Table {
|
|
352
353
|
markIfOversizedColumnHeader(col) {
|
353
354
|
const sourceColIndex = this.columnFilter.renderedToSource(col);
|
354
355
|
let level = this.wtSettings.getSetting('columnHeaders').length;
|
355
|
-
const defaultRowHeight = this.
|
356
|
+
const defaultRowHeight = this.wtSettings.getSetting('defaultRowHeight');
|
356
357
|
let previousColHeaderHeight;
|
357
358
|
let currentHeader;
|
358
359
|
let currentHeaderHeight;
|
@@ -630,13 +631,10 @@ class Table {
|
|
630
631
|
return;
|
631
632
|
}
|
632
633
|
let rowCount = this.TBODY.childNodes.length;
|
633
|
-
const expectedTableHeight = rowCount * this.
|
634
|
+
const expectedTableHeight = rowCount * this.wtSettings.getSetting('defaultRowHeight');
|
634
635
|
const actualTableHeight = (0, _element.innerHeight)(this.TBODY) - 1;
|
635
|
-
const borderBoxSizing = this.wot.stylesHandler.areCellsBorderBox();
|
636
|
-
const rowHeightFn = borderBoxSizing ? _element.outerHeight : _element.innerHeight;
|
637
|
-
const borderCompensation = borderBoxSizing ? 0 : 1;
|
638
636
|
let previousRowHeight;
|
639
|
-
let
|
637
|
+
let rowInnerHeight;
|
640
638
|
let sourceRowIndex;
|
641
639
|
let currentTr;
|
642
640
|
let rowHeader;
|
@@ -651,15 +649,13 @@ class Table {
|
|
651
649
|
currentTr = this.getTrForRow(sourceRowIndex);
|
652
650
|
rowHeader = currentTr.querySelector('th');
|
653
651
|
if (rowHeader) {
|
654
|
-
|
652
|
+
rowInnerHeight = (0, _element.innerHeight)(rowHeader);
|
655
653
|
} else {
|
656
|
-
|
654
|
+
rowInnerHeight = (0, _element.innerHeight)(currentTr) - 1;
|
657
655
|
}
|
658
|
-
if (!previousRowHeight && this.
|
659
|
-
|
660
|
-
|
661
|
-
}
|
662
|
-
this.dataAccessObject.wtViewport.oversizedRows[sourceRowIndex] = rowCurrentHeight;
|
656
|
+
if (!previousRowHeight && this.wtSettings.getSetting('defaultRowHeight') < rowInnerHeight || previousRowHeight < rowInnerHeight) {
|
657
|
+
rowInnerHeight += 1;
|
658
|
+
this.dataAccessObject.wtViewport.oversizedRows[sourceRowIndex] = rowInnerHeight;
|
663
659
|
}
|
664
660
|
}
|
665
661
|
}
|