handsontable 0.0.0-next-2b3d6d8-20230623 → 0.0.0-next-74a68c1-20230627
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/cell/coords.d.ts +6 -1
- package/3rdparty/walkontable/src/cell/coords.js +61 -12
- package/3rdparty/walkontable/src/cell/coords.mjs +61 -12
- package/3rdparty/walkontable/src/cell/range.d.ts +9 -2
- package/3rdparty/walkontable/src/cell/range.js +44 -7
- package/3rdparty/walkontable/src/cell/range.mjs +44 -7
- package/3rdparty/walkontable/src/core/_base.js +9 -3
- package/3rdparty/walkontable/src/core/_base.mjs +9 -3
- package/3rdparty/walkontable/src/core/clone.js +2 -2
- package/3rdparty/walkontable/src/core/clone.mjs +2 -2
- package/3rdparty/walkontable/src/core/core.js +3 -2
- package/3rdparty/walkontable/src/core/core.mjs +3 -2
- package/3rdparty/walkontable/src/event.js +7 -7
- package/3rdparty/walkontable/src/event.mjs +7 -7
- package/3rdparty/walkontable/src/facade/core.js +2 -2
- package/3rdparty/walkontable/src/facade/core.mjs +2 -2
- package/3rdparty/walkontable/src/index.js +10 -2
- package/3rdparty/walkontable/src/index.mjs +2 -2
- package/3rdparty/walkontable/src/overlay/_base.js +1 -1
- package/3rdparty/walkontable/src/overlay/_base.mjs +1 -1
- package/3rdparty/walkontable/src/overlay/inlineStart.js +2 -4
- package/3rdparty/walkontable/src/overlay/inlineStart.mjs +2 -4
- package/3rdparty/walkontable/src/overlay/top.js +2 -4
- package/3rdparty/walkontable/src/overlay/top.mjs +2 -4
- package/3rdparty/walkontable/src/{border.js → selection/border/border.js} +7 -12
- package/3rdparty/walkontable/src/{border.mjs → selection/border/border.mjs} +7 -12
- package/3rdparty/walkontable/src/selection/border/constants.js +18 -0
- package/3rdparty/walkontable/src/selection/border/constants.mjs +13 -0
- package/3rdparty/walkontable/src/selection/constants.js +63 -0
- package/3rdparty/walkontable/src/selection/constants.mjs +51 -0
- package/3rdparty/walkontable/src/selection/index.js +30 -0
- package/3rdparty/walkontable/src/selection/index.mjs +5 -0
- package/3rdparty/walkontable/src/selection/manager.js +329 -0
- package/3rdparty/walkontable/src/selection/manager.mjs +323 -0
- package/3rdparty/walkontable/src/selection/scanner.js +364 -0
- package/3rdparty/walkontable/src/selection/scanner.mjs +360 -0
- package/3rdparty/walkontable/src/selection/selection.js +133 -0
- package/3rdparty/walkontable/src/selection/selection.mjs +127 -0
- package/3rdparty/walkontable/src/table/mixin/calculatedColumns.js +9 -0
- package/3rdparty/walkontable/src/table/mixin/calculatedColumns.mjs +9 -0
- package/3rdparty/walkontable/src/table/mixin/calculatedRows.js +9 -0
- package/3rdparty/walkontable/src/table/mixin/calculatedRows.mjs +9 -0
- package/3rdparty/walkontable/src/table/mixin/stickyColumnsStart.js +9 -0
- package/3rdparty/walkontable/src/table/mixin/stickyColumnsStart.mjs +9 -0
- package/3rdparty/walkontable/src/table/mixin/stickyRowsBottom.js +9 -0
- package/3rdparty/walkontable/src/table/mixin/stickyRowsBottom.mjs +9 -0
- package/3rdparty/walkontable/src/table/mixin/stickyRowsTop.js +9 -0
- package/3rdparty/walkontable/src/table/mixin/stickyRowsTop.mjs +9 -0
- package/3rdparty/walkontable/src/table.js +7 -79
- package/3rdparty/walkontable/src/table.mjs +8 -80
- package/base.js +2 -2
- package/base.mjs +2 -2
- package/core.d.ts +5 -3
- package/core.js +127 -309
- package/core.mjs +127 -309
- package/dataMap/metaManager/metaSchema.js +19 -0
- package/dataMap/metaManager/metaSchema.mjs +19 -0
- package/dist/handsontable.css +8 -3
- package/dist/handsontable.full.css +8 -3
- package/dist/handsontable.full.js +13762 -10716
- package/dist/handsontable.full.min.css +3 -3
- package/dist/handsontable.full.min.js +115 -115
- package/dist/handsontable.js +16626 -13580
- package/dist/handsontable.min.css +3 -3
- package/dist/handsontable.min.js +4 -4
- package/editorManager.js +21 -94
- package/editorManager.mjs +26 -98
- package/editors/textEditor/textEditor.js +3 -11
- package/editors/textEditor/textEditor.mjs +4 -12
- package/helpers/mixed.js +1 -1
- package/helpers/mixed.mjs +1 -1
- package/helpers/number.d.ts +1 -0
- package/helpers/number.js +18 -0
- package/helpers/number.mjs +17 -0
- package/package.json +1 -1
- package/pluginHooks.d.ts +5 -1
- package/pluginHooks.js +89 -1
- package/pluginHooks.mjs +89 -1
- package/plugins/collapsibleColumns/collapsibleColumns.js +81 -24
- package/plugins/collapsibleColumns/collapsibleColumns.mjs +81 -24
- package/plugins/columnSorting/columnSorting.js +50 -8
- package/plugins/columnSorting/columnSorting.mjs +49 -9
- package/plugins/columnSorting/index.js +4 -2
- package/plugins/columnSorting/index.mjs +1 -1
- package/plugins/comments/comments.js +11 -4
- package/plugins/comments/comments.mjs +11 -4
- package/plugins/contextMenu/contextMenu.d.ts +1 -1
- package/plugins/contextMenu/contextMenu.js +80 -29
- package/plugins/contextMenu/contextMenu.mjs +81 -30
- package/plugins/contextMenu/predefinedItems/alignment.js +7 -0
- package/plugins/contextMenu/predefinedItems/alignment.mjs +7 -0
- package/plugins/contextMenu/predefinedItems/clearColumn.js +5 -3
- package/plugins/contextMenu/predefinedItems/clearColumn.mjs +5 -3
- package/plugins/contextMenu/predefinedItems/columnLeft.js +5 -3
- package/plugins/contextMenu/predefinedItems/columnLeft.mjs +5 -3
- package/plugins/contextMenu/predefinedItems/columnRight.js +5 -3
- package/plugins/contextMenu/predefinedItems/columnRight.mjs +5 -3
- package/plugins/contextMenu/predefinedItems/readOnly.js +7 -0
- package/plugins/contextMenu/predefinedItems/readOnly.mjs +7 -0
- package/plugins/contextMenu/predefinedItems/removeColumn.js +7 -5
- package/plugins/contextMenu/predefinedItems/removeColumn.mjs +5 -3
- package/plugins/contextMenu/predefinedItems/removeRow.js +7 -5
- package/plugins/contextMenu/predefinedItems/removeRow.mjs +5 -3
- package/plugins/contextMenu/predefinedItems/rowAbove.js +5 -3
- package/plugins/contextMenu/predefinedItems/rowAbove.mjs +5 -3
- package/plugins/contextMenu/predefinedItems/rowBelow.js +5 -3
- package/plugins/contextMenu/predefinedItems/rowBelow.mjs +5 -3
- package/plugins/contextMenu/utils.js +25 -16
- package/plugins/contextMenu/utils.mjs +24 -15
- package/plugins/copyPaste/contextMenuItem/copy.js +7 -0
- package/plugins/copyPaste/contextMenuItem/copy.mjs +7 -0
- package/plugins/copyPaste/contextMenuItem/copyColumnHeadersOnly.js +9 -1
- package/plugins/copyPaste/contextMenuItem/copyColumnHeadersOnly.mjs +9 -1
- package/plugins/copyPaste/contextMenuItem/copyWithColumnGroupHeaders.js +9 -1
- package/plugins/copyPaste/contextMenuItem/copyWithColumnGroupHeaders.mjs +9 -1
- package/plugins/copyPaste/contextMenuItem/copyWithColumnHeaders.js +9 -1
- package/plugins/copyPaste/contextMenuItem/copyWithColumnHeaders.mjs +9 -1
- package/plugins/copyPaste/contextMenuItem/cut.js +7 -0
- package/plugins/copyPaste/contextMenuItem/cut.mjs +7 -0
- package/plugins/copyPaste/copyPaste.js +5 -1
- package/plugins/copyPaste/copyPaste.mjs +5 -1
- package/plugins/customBorders/customBorders.js +25 -53
- package/plugins/customBorders/customBorders.mjs +26 -54
- package/plugins/dropdownMenu/dropdownMenu.d.ts +1 -1
- package/plugins/dropdownMenu/dropdownMenu.js +94 -30
- package/plugins/dropdownMenu/dropdownMenu.mjs +94 -30
- package/plugins/filters/filters.js +62 -42
- package/plugins/filters/filters.mjs +61 -41
- package/plugins/mergeCells/mergeCells.js +5 -18
- package/plugins/mergeCells/mergeCells.mjs +5 -18
- package/plugins/multiColumnSorting/multiColumnSorting.js +42 -3
- package/plugins/multiColumnSorting/multiColumnSorting.mjs +42 -3
- package/plugins/nestedHeaders/nestedHeaders.js +132 -10
- package/plugins/nestedHeaders/nestedHeaders.mjs +132 -10
- package/plugins/nestedHeaders/stateManager/index.js +37 -0
- package/plugins/nestedHeaders/stateManager/index.mjs +37 -0
- package/plugins/nestedRows/nestedRows.js +52 -7
- package/plugins/nestedRows/nestedRows.mjs +52 -7
- package/renderers/checkboxRenderer/checkboxRenderer.js +2 -2
- package/renderers/checkboxRenderer/checkboxRenderer.mjs +1 -1
- package/selection/highlight/highlight.js +312 -89
- package/selection/highlight/highlight.mjs +302 -85
- package/selection/highlight/types/activeHeader.js +10 -9
- package/selection/highlight/types/activeHeader.mjs +10 -8
- package/selection/highlight/types/area.js +12 -27
- package/selection/highlight/types/area.mjs +16 -30
- package/selection/highlight/types/areaLayered.js +54 -0
- package/selection/highlight/types/areaLayered.mjs +49 -0
- package/selection/highlight/types/column.js +50 -0
- package/selection/highlight/types/column.mjs +45 -0
- package/selection/highlight/types/customSelection.js +7 -10
- package/selection/highlight/types/customSelection.mjs +7 -9
- package/selection/highlight/types/fill.js +5 -8
- package/selection/highlight/types/fill.mjs +5 -7
- package/selection/highlight/types/{cell.js → focus.js} +5 -8
- package/selection/highlight/types/{cell.mjs → focus.mjs} +5 -7
- package/selection/highlight/types/header.js +10 -20
- package/selection/highlight/types/header.mjs +10 -19
- package/selection/highlight/types/{index.js → row.js} +27 -31
- package/selection/highlight/types/{index.mjs → row.mjs} +24 -29
- package/selection/highlight/visualSelection.js +31 -27
- package/selection/highlight/visualSelection.mjs +31 -27
- package/selection/index.js +4 -7
- package/selection/index.mjs +2 -3
- package/selection/mouseEventHandler.js +1 -1
- package/selection/mouseEventHandler.mjs +1 -1
- package/selection/range.js +8 -8
- package/selection/range.mjs +8 -8
- package/selection/selection.js +315 -181
- package/selection/selection.mjs +310 -180
- package/selection/transformation.js +233 -96
- package/selection/transformation.mjs +230 -93
- package/selection/utils.js +12 -36
- package/selection/utils.mjs +13 -36
- package/settings.d.ts +1 -0
- package/shortcutContexts/commands/editor/closeAndSave.js +15 -0
- package/shortcutContexts/commands/editor/closeAndSave.mjs +10 -0
- package/shortcutContexts/commands/editor/closeWithoutSaving.js +13 -0
- package/shortcutContexts/commands/editor/closeWithoutSaving.mjs +8 -0
- package/shortcutContexts/commands/editor/fastOpen.js +16 -0
- package/shortcutContexts/commands/editor/fastOpen.mjs +11 -0
- package/shortcutContexts/commands/editor/index.js +16 -0
- package/shortcutContexts/commands/editor/index.mjs +12 -0
- package/shortcutContexts/commands/editor/open.js +29 -0
- package/shortcutContexts/commands/editor/open.mjs +24 -0
- package/shortcutContexts/commands/emptySelectedCells.js +12 -0
- package/shortcutContexts/commands/emptySelectedCells.mjs +7 -0
- package/shortcutContexts/commands/extendCellsSelection/down.js +15 -0
- package/shortcutContexts/commands/extendCellsSelection/down.mjs +10 -0
- package/shortcutContexts/commands/extendCellsSelection/downByViewportHeight.js +21 -0
- package/shortcutContexts/commands/extendCellsSelection/downByViewportHeight.mjs +16 -0
- package/shortcutContexts/commands/extendCellsSelection/index.js +26 -0
- package/shortcutContexts/commands/extendCellsSelection/index.mjs +22 -0
- package/shortcutContexts/commands/extendCellsSelection/left.js +15 -0
- package/shortcutContexts/commands/extendCellsSelection/left.mjs +10 -0
- package/shortcutContexts/commands/extendCellsSelection/right.js +15 -0
- package/shortcutContexts/commands/extendCellsSelection/right.mjs +10 -0
- package/shortcutContexts/commands/extendCellsSelection/toColumns.js +19 -0
- package/shortcutContexts/commands/extendCellsSelection/toColumns.mjs +14 -0
- package/shortcutContexts/commands/extendCellsSelection/toMostBottom.js +22 -0
- package/shortcutContexts/commands/extendCellsSelection/toMostBottom.mjs +17 -0
- package/shortcutContexts/commands/extendCellsSelection/toMostInlineEnd.js +17 -0
- package/shortcutContexts/commands/extendCellsSelection/toMostInlineEnd.mjs +12 -0
- package/shortcutContexts/commands/extendCellsSelection/toMostInlineStart.js +17 -0
- package/shortcutContexts/commands/extendCellsSelection/toMostInlineStart.mjs +12 -0
- package/shortcutContexts/commands/extendCellsSelection/toMostLeft.js +40 -0
- package/shortcutContexts/commands/extendCellsSelection/toMostLeft.mjs +35 -0
- package/shortcutContexts/commands/extendCellsSelection/toMostRight.js +40 -0
- package/shortcutContexts/commands/extendCellsSelection/toMostRight.mjs +35 -0
- package/shortcutContexts/commands/extendCellsSelection/toMostTop.js +22 -0
- package/shortcutContexts/commands/extendCellsSelection/toMostTop.mjs +17 -0
- package/shortcutContexts/commands/extendCellsSelection/toRows.js +19 -0
- package/shortcutContexts/commands/extendCellsSelection/toRows.mjs +14 -0
- package/shortcutContexts/commands/extendCellsSelection/up.js +15 -0
- package/shortcutContexts/commands/extendCellsSelection/up.mjs +10 -0
- package/shortcutContexts/commands/extendCellsSelection/upByViewportHeight.js +21 -0
- package/shortcutContexts/commands/extendCellsSelection/upByViewportHeight.mjs +16 -0
- package/shortcutContexts/commands/index.js +53 -0
- package/shortcutContexts/commands/index.mjs +49 -0
- package/shortcutContexts/commands/moveCellSelection/down.js +12 -0
- package/shortcutContexts/commands/moveCellSelection/down.mjs +7 -0
- package/shortcutContexts/commands/moveCellSelection/downByViewportHeight.js +29 -0
- package/shortcutContexts/commands/moveCellSelection/downByViewportHeight.mjs +24 -0
- package/shortcutContexts/commands/moveCellSelection/index.js +28 -0
- package/shortcutContexts/commands/moveCellSelection/index.mjs +24 -0
- package/shortcutContexts/commands/moveCellSelection/inlineEnd.js +13 -0
- package/shortcutContexts/commands/moveCellSelection/inlineEnd.mjs +8 -0
- package/shortcutContexts/commands/moveCellSelection/inlineStart.js +13 -0
- package/shortcutContexts/commands/moveCellSelection/inlineStart.mjs +8 -0
- package/shortcutContexts/commands/moveCellSelection/left.js +11 -0
- package/shortcutContexts/commands/moveCellSelection/left.mjs +6 -0
- package/shortcutContexts/commands/moveCellSelection/right.js +11 -0
- package/shortcutContexts/commands/moveCellSelection/right.mjs +6 -0
- package/shortcutContexts/commands/moveCellSelection/toMostBottom.js +16 -0
- package/shortcutContexts/commands/moveCellSelection/toMostBottom.mjs +11 -0
- package/shortcutContexts/commands/moveCellSelection/toMostBottomInlineEnd.js +17 -0
- package/shortcutContexts/commands/moveCellSelection/toMostBottomInlineEnd.mjs +12 -0
- package/shortcutContexts/commands/moveCellSelection/toMostInlineEnd.js +13 -0
- package/shortcutContexts/commands/moveCellSelection/toMostInlineEnd.mjs +8 -0
- package/shortcutContexts/commands/moveCellSelection/toMostInlineStart.js +16 -0
- package/shortcutContexts/commands/moveCellSelection/toMostInlineStart.mjs +11 -0
- package/shortcutContexts/commands/moveCellSelection/toMostLeft.js +36 -0
- package/shortcutContexts/commands/moveCellSelection/toMostLeft.mjs +31 -0
- package/shortcutContexts/commands/moveCellSelection/toMostRight.js +36 -0
- package/shortcutContexts/commands/moveCellSelection/toMostRight.mjs +31 -0
- package/shortcutContexts/commands/moveCellSelection/toMostTop.js +16 -0
- package/shortcutContexts/commands/moveCellSelection/toMostTop.mjs +11 -0
- package/shortcutContexts/commands/moveCellSelection/toMostTopInlineStart.js +18 -0
- package/shortcutContexts/commands/moveCellSelection/toMostTopInlineStart.mjs +13 -0
- package/shortcutContexts/commands/moveCellSelection/up.js +12 -0
- package/shortcutContexts/commands/moveCellSelection/up.mjs +7 -0
- package/shortcutContexts/commands/moveCellSelection/upByViewportHeight.js +29 -0
- package/shortcutContexts/commands/moveCellSelection/upByViewportHeight.mjs +24 -0
- package/shortcutContexts/commands/populateSelectedCellsData.js +35 -0
- package/shortcutContexts/commands/populateSelectedCellsData.mjs +30 -0
- package/shortcutContexts/commands/scrollToFocusedCell.js +38 -0
- package/shortcutContexts/commands/scrollToFocusedCell.mjs +33 -0
- package/shortcutContexts/commands/selectAll.js +11 -0
- package/shortcutContexts/commands/selectAll.mjs +6 -0
- package/shortcutContexts/constants.js +19 -0
- package/shortcutContexts/constants.mjs +12 -0
- package/shortcutContexts/editor.js +29 -0
- package/shortcutContexts/editor.mjs +25 -0
- package/shortcutContexts/grid.js +252 -0
- package/shortcutContexts/grid.mjs +248 -0
- package/shortcutContexts/index.js +29 -0
- package/shortcutContexts/index.mjs +15 -0
- package/shortcuts/manager.js +2 -0
- package/shortcuts/manager.mjs +2 -0
- package/shortcuts/recorder.js +2 -2
- package/shortcuts/recorder.mjs +2 -2
- package/shortcuts/utils.js +21 -5
- package/shortcuts/utils.mjs +20 -4
- package/tableView.js +58 -9
- package/tableView.mjs +58 -9
- package/3rdparty/walkontable/src/selection.js +0 -355
- package/3rdparty/walkontable/src/selection.mjs +0 -349
- package/selection/highlight/constants.js +0 -16
- package/selection/highlight/constants.mjs +0 -6
@@ -1,50 +1,71 @@
|
|
1
1
|
"use strict";
|
2
2
|
|
3
|
-
require("core-js/modules/es.
|
4
|
-
require("core-js/modules/es.
|
5
|
-
require("core-js/modules/es.
|
6
|
-
require("core-js/modules/web.dom-collections.for-each.js");
|
7
|
-
require("core-js/modules/es.object.get-own-property-descriptors.js");
|
3
|
+
require("core-js/modules/es.symbol.to-primitive.js");
|
4
|
+
require("core-js/modules/es.date.to-primitive.js");
|
5
|
+
require("core-js/modules/es.number.constructor.js");
|
8
6
|
require("core-js/modules/es.array.from.js");
|
9
7
|
require("core-js/modules/es.array.slice.js");
|
10
8
|
require("core-js/modules/es.regexp.to-string.js");
|
11
9
|
require("core-js/modules/es.function.name.js");
|
12
10
|
require("core-js/modules/es.regexp.exec.js");
|
11
|
+
require("core-js/modules/es.object.keys.js");
|
12
|
+
require("core-js/modules/es.array.filter.js");
|
13
|
+
require("core-js/modules/es.object.get-own-property-descriptor.js");
|
14
|
+
require("core-js/modules/web.dom-collections.for-each.js");
|
15
|
+
require("core-js/modules/es.object.get-own-property-descriptors.js");
|
16
|
+
function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
|
13
17
|
exports.__esModule = true;
|
14
18
|
exports.default = void 0;
|
15
|
-
require("core-js/modules/es.array.fill.js");
|
16
19
|
require("core-js/modules/es.array.iterator.js");
|
17
20
|
require("core-js/modules/es.map.js");
|
18
21
|
require("core-js/modules/es.object.to-string.js");
|
19
22
|
require("core-js/modules/es.string.iterator.js");
|
20
23
|
require("core-js/modules/web.dom-collections.iterator.js");
|
24
|
+
require("core-js/modules/es.array.fill.js");
|
21
25
|
require("core-js/modules/es.array.includes.js");
|
22
26
|
require("core-js/modules/es.string.includes.js");
|
23
27
|
require("core-js/modules/es.array.concat.js");
|
24
28
|
require("core-js/modules/es.symbol.iterator.js");
|
25
29
|
require("core-js/modules/es.symbol.js");
|
26
30
|
require("core-js/modules/es.symbol.description.js");
|
27
|
-
require("core-js/modules/es.
|
28
|
-
require("
|
29
|
-
require("
|
30
|
-
var
|
31
|
-
var
|
31
|
+
require("core-js/modules/es.weak-set.js");
|
32
|
+
var _activeHeader = require("./types/activeHeader");
|
33
|
+
var _areaLayered = require("./types/areaLayered");
|
34
|
+
var _area = require("./types/area");
|
35
|
+
var _column = require("./types/column");
|
36
|
+
var _focus = require("./types/focus");
|
37
|
+
var _customSelection = require("./types/customSelection");
|
38
|
+
var _fill = require("./types/fill");
|
39
|
+
var _header = require("./types/header");
|
40
|
+
var _row = require("./types/row");
|
41
|
+
var _src = require("../../3rdparty/walkontable/src");
|
42
|
+
exports.ACTIVE_HEADER_TYPE = _src.HIGHLIGHT_ACTIVE_HEADER_TYPE;
|
43
|
+
exports.AREA_TYPE = _src.HIGHLIGHT_AREA_TYPE;
|
44
|
+
exports.FOCUS_TYPE = _src.HIGHLIGHT_FOCUS_TYPE;
|
45
|
+
exports.CUSTOM_SELECTION_TYPE = _src.HIGHLIGHT_CUSTOM_SELECTION_TYPE;
|
46
|
+
exports.FILL_TYPE = _src.HIGHLIGHT_FILL_TYPE;
|
47
|
+
exports.HEADER_TYPE = _src.HIGHLIGHT_HEADER_TYPE;
|
48
|
+
exports.ROW_TYPE = _src.HIGHLIGHT_ROW_TYPE;
|
49
|
+
exports.COLUMN_TYPE = _src.HIGHLIGHT_COLUMN_TYPE;
|
32
50
|
var _array = require("./../../helpers/array");
|
33
|
-
|
51
|
+
var _Symbol$iterator;
|
52
|
+
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
53
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
34
54
|
function _toConsumableArray(arr) { return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableSpread(); }
|
35
55
|
function _nonIterableSpread() { throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
36
56
|
function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
|
37
57
|
function _iterableToArray(iter) { if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter); }
|
38
58
|
function _arrayWithoutHoles(arr) { if (Array.isArray(arr)) return _arrayLikeToArray(arr); }
|
39
59
|
function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
|
40
|
-
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
41
|
-
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
42
|
-
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; }
|
43
60
|
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
44
61
|
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, _toPropertyKey(descriptor.key), descriptor); } }
|
45
62
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
|
63
|
+
function _classPrivateMethodInitSpec(obj, privateSet) { _checkPrivateRedeclaration(obj, privateSet); privateSet.add(obj); }
|
64
|
+
function _checkPrivateRedeclaration(obj, privateCollection) { if (privateCollection.has(obj)) { throw new TypeError("Cannot initialize the same private elements twice on an object"); } }
|
65
|
+
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; }
|
46
66
|
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _typeof(key) === "symbol" ? key : String(key); }
|
47
67
|
function _toPrimitive(input, hint) { if (_typeof(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
68
|
+
function _classPrivateMethodGet(receiver, privateSet, fn) { if (!privateSet.has(receiver)) { throw new TypeError("attempted to get private field on non-instance"); } return fn; }
|
48
69
|
/**
|
49
70
|
* Highlight class responsible for managing Walkontable Selection classes.
|
50
71
|
*
|
@@ -60,15 +81,25 @@ function _toPrimitive(input, hint) { if (_typeof(input) !== "object" || input ==
|
|
60
81
|
* @class Highlight
|
61
82
|
* @util
|
62
83
|
*/
|
63
|
-
var
|
84
|
+
var _createHighlight = /*#__PURE__*/new WeakSet();
|
85
|
+
_Symbol$iterator = Symbol.iterator;
|
86
|
+
var Highlight = /*#__PURE__*/function () {
|
64
87
|
function Highlight(options) {
|
65
88
|
_classCallCheck(this, Highlight);
|
89
|
+
/**
|
90
|
+
* Creates (if not exist in the cache) Walkontable Selection instance.
|
91
|
+
*
|
92
|
+
* @param {Map} cacheMap The map where the instance will be cached.
|
93
|
+
* @param {Function} highlightFactory The function factory.
|
94
|
+
* @returns {VisualSelection}
|
95
|
+
*/
|
96
|
+
_classPrivateMethodInitSpec(this, _createHighlight);
|
66
97
|
/**
|
67
98
|
* Options consumed by Highlight class and Walkontable Selection classes.
|
68
99
|
*
|
69
100
|
* @type {object}
|
70
101
|
*/
|
71
|
-
this
|
102
|
+
_defineProperty(this, "options", void 0);
|
72
103
|
/**
|
73
104
|
* The property which describes which layer level of the visual selection will be modified.
|
74
105
|
* This option is valid only for `area` and `header` highlight types which occurs multiple times on
|
@@ -79,49 +110,96 @@ var Highlight = /*#__PURE__*/function (_Symbol$iterator) {
|
|
79
110
|
* @type {number}
|
80
111
|
* @default 0
|
81
112
|
*/
|
82
|
-
this
|
113
|
+
_defineProperty(this, "layerLevel", 0);
|
83
114
|
/**
|
84
115
|
* `cell` highlight object which describes attributes for the currently selected cell.
|
85
116
|
* It can only occur only once on the table.
|
86
117
|
*
|
87
118
|
* @type {Selection}
|
88
119
|
*/
|
89
|
-
this
|
120
|
+
_defineProperty(this, "focus", void 0);
|
90
121
|
/**
|
91
122
|
* `fill` highlight object which describes attributes for the borders for autofill functionality.
|
92
123
|
* It can only occur only once on the table.
|
93
124
|
*
|
94
125
|
* @type {Selection}
|
95
126
|
*/
|
96
|
-
this
|
127
|
+
_defineProperty(this, "fill", void 0);
|
97
128
|
/**
|
98
129
|
* Collection of the `area` highlights. That objects describes attributes for the borders and selection of
|
99
130
|
* the multiple selected cells. It can occur multiple times on the table.
|
100
131
|
*
|
101
132
|
* @type {Map.<number, Selection>}
|
102
133
|
*/
|
103
|
-
this
|
134
|
+
_defineProperty(this, "layeredAreas", new Map());
|
135
|
+
/**
|
136
|
+
* Collection of the `highlight` highlights. That objects describes attributes for the borders and selection of
|
137
|
+
* the multiple selected cells. It can occur multiple times on the table.
|
138
|
+
*
|
139
|
+
* @type {Map.<number, Selection>}
|
140
|
+
*/
|
141
|
+
_defineProperty(this, "areas", new Map());
|
142
|
+
/**
|
143
|
+
* Collection of the `header` highlights. That objects describes attributes for the selection of
|
144
|
+
* the multiple selected rows in the table header. It can occur multiple times on the table.
|
145
|
+
*
|
146
|
+
* @type {Map.<number, Selection>}
|
147
|
+
*/
|
148
|
+
_defineProperty(this, "rowHeaders", new Map());
|
104
149
|
/**
|
105
150
|
* Collection of the `header` highlights. That objects describes attributes for the selection of
|
106
|
-
* the multiple selected
|
151
|
+
* the multiple selected columns in the table header. It can occur multiple times on the table.
|
107
152
|
*
|
108
153
|
* @type {Map.<number, Selection>}
|
109
154
|
*/
|
110
|
-
this
|
155
|
+
_defineProperty(this, "columnHeaders", new Map());
|
111
156
|
/**
|
112
157
|
* Collection of the `active-header` highlights. That objects describes attributes for the selection of
|
113
|
-
* the multiple selected rows
|
158
|
+
* the multiple selected rows in the table header. The table headers which have selected all items in
|
114
159
|
* a row will be marked as `active-header`.
|
115
160
|
*
|
116
161
|
* @type {Map.<number, Selection>}
|
117
162
|
*/
|
118
|
-
this
|
163
|
+
_defineProperty(this, "activeRowHeaders", new Map());
|
164
|
+
/**
|
165
|
+
* Collection of the `active-header` highlights. That objects describes attributes for the selection of
|
166
|
+
* the multiple selected columns in the table header. The table headers which have selected all items in
|
167
|
+
* a row will be marked as `active-header`.
|
168
|
+
*
|
169
|
+
* @type {Map.<number, Selection>}
|
170
|
+
*/
|
171
|
+
_defineProperty(this, "activeColumnHeaders", new Map());
|
172
|
+
/**
|
173
|
+
* Collection of the `active-header` highlights. That objects describes attributes for the selection of
|
174
|
+
* the selected corner in the table header. The table headers which have selected all items in
|
175
|
+
* a row will be marked as `active-header`.
|
176
|
+
*
|
177
|
+
* @type {Map.<number, Selection>}
|
178
|
+
*/
|
179
|
+
_defineProperty(this, "activeCornerHeaders", new Map());
|
180
|
+
/**
|
181
|
+
* Collection of the `rows` highlights. That objects describes attributes for the selection of
|
182
|
+
* the multiple selected cells in a row. It can occur multiple times on the table.
|
183
|
+
*
|
184
|
+
* @type {Map.<number, Selection>}
|
185
|
+
*/
|
186
|
+
_defineProperty(this, "rowHighlights", new Map());
|
187
|
+
/**
|
188
|
+
* Collection of the `columns` highlights. That objects describes attributes for the selection of
|
189
|
+
* the multiple selected cells in a column. It can occur multiple times on the table.
|
190
|
+
*
|
191
|
+
* @type {Map.<number, Selection>}
|
192
|
+
*/
|
193
|
+
_defineProperty(this, "columnHighlights", new Map());
|
119
194
|
/**
|
120
195
|
* Collection of the `custom-selection`, holder for example borders added through CustomBorders plugin.
|
121
196
|
*
|
122
197
|
* @type {Selection[]}
|
123
198
|
*/
|
124
|
-
this
|
199
|
+
_defineProperty(this, "customSelections", []);
|
200
|
+
this.options = options;
|
201
|
+
this.focus = (0, _focus.createHighlight)(options);
|
202
|
+
this.fill = (0, _fill.createHighlight)(options);
|
125
203
|
}
|
126
204
|
|
127
205
|
/**
|
@@ -137,11 +215,14 @@ var Highlight = /*#__PURE__*/function (_Symbol$iterator) {
|
|
137
215
|
var type = highlightType;
|
138
216
|
|
139
217
|
// Legacy compatibility.
|
140
|
-
if (highlightType ===
|
218
|
+
if (highlightType === _src.HIGHLIGHT_FOCUS_TYPE) {
|
141
219
|
type = 'current'; // One from settings for `disableVisualSelection` up to Handsontable 0.36/Handsontable Pro 1.16.0.
|
142
220
|
}
|
143
221
|
|
144
|
-
var disableHighlight =
|
222
|
+
var disableHighlight = false;
|
223
|
+
if (coords.isCell()) {
|
224
|
+
disableHighlight = this.options.disabledCellSelection(coords.row, coords.col);
|
225
|
+
}
|
145
226
|
if (typeof disableHighlight === 'string') {
|
146
227
|
disableHighlight = [disableHighlight];
|
147
228
|
}
|
@@ -163,14 +244,15 @@ var Highlight = /*#__PURE__*/function (_Symbol$iterator) {
|
|
163
244
|
}
|
164
245
|
|
165
246
|
/**
|
166
|
-
* Get Walkontable Selection instance created for controlling highlight of the currently
|
247
|
+
* Get Walkontable Selection instance created for controlling highlight of the currently
|
248
|
+
* focused cell (or header).
|
167
249
|
*
|
168
250
|
* @returns {Selection}
|
169
251
|
*/
|
170
252
|
}, {
|
171
|
-
key: "
|
172
|
-
value: function
|
173
|
-
return this.
|
253
|
+
key: "getFocus",
|
254
|
+
value: function getFocus() {
|
255
|
+
return this.focus;
|
174
256
|
}
|
175
257
|
|
176
258
|
/**
|
@@ -185,25 +267,38 @@ var Highlight = /*#__PURE__*/function (_Symbol$iterator) {
|
|
185
267
|
}
|
186
268
|
|
187
269
|
/**
|
188
|
-
*
|
189
|
-
*
|
270
|
+
* Creates (if not exist in the cache) Walkontable Selection instance created for controlling
|
271
|
+
* `area` highlights.
|
190
272
|
*
|
191
273
|
* @returns {Selection}
|
192
274
|
*/
|
193
275
|
}, {
|
194
|
-
key: "
|
195
|
-
value: function
|
196
|
-
|
197
|
-
|
198
|
-
|
199
|
-
|
200
|
-
|
201
|
-
|
202
|
-
|
203
|
-
|
204
|
-
|
205
|
-
|
206
|
-
|
276
|
+
key: "createLayeredArea",
|
277
|
+
value: function createLayeredArea() {
|
278
|
+
return _classPrivateMethodGet(this, _createHighlight, _createHighlight2).call(this, this.layeredAreas, _areaLayered.createHighlight);
|
279
|
+
}
|
280
|
+
|
281
|
+
/**
|
282
|
+
* Get all Walkontable Selection instances which describes the state of the visual highlight of the cells.
|
283
|
+
*
|
284
|
+
* @returns {Selection[]}
|
285
|
+
*/
|
286
|
+
}, {
|
287
|
+
key: "getLayeredAreas",
|
288
|
+
value: function getLayeredAreas() {
|
289
|
+
return _toConsumableArray(this.layeredAreas.values());
|
290
|
+
}
|
291
|
+
|
292
|
+
/**
|
293
|
+
* Creates (if not exist in the cache) Walkontable Selection instance created for controlling
|
294
|
+
* `highlight` highlights.
|
295
|
+
*
|
296
|
+
* @returns {Selection}
|
297
|
+
*/
|
298
|
+
}, {
|
299
|
+
key: "createArea",
|
300
|
+
value: function createArea() {
|
301
|
+
return _classPrivateMethodGet(this, _createHighlight, _createHighlight2).call(this, this.areas, _area.createHighlight);
|
207
302
|
}
|
208
303
|
|
209
304
|
/**
|
@@ -218,23 +313,15 @@ var Highlight = /*#__PURE__*/function (_Symbol$iterator) {
|
|
218
313
|
}
|
219
314
|
|
220
315
|
/**
|
221
|
-
*
|
222
|
-
*
|
316
|
+
* Creates (if not exist in the cache) Walkontable Selection instance created for controlling
|
317
|
+
* header highlight for rows.
|
223
318
|
*
|
224
319
|
* @returns {Selection}
|
225
320
|
*/
|
226
321
|
}, {
|
227
|
-
key: "
|
228
|
-
value: function
|
229
|
-
|
230
|
-
var header;
|
231
|
-
if (this.headers.has(layerLevel)) {
|
232
|
-
header = this.headers.get(layerLevel);
|
233
|
-
} else {
|
234
|
-
header = (0, _types.createHighlight)(_constants.HEADER_TYPE, _objectSpread({}, this.options));
|
235
|
-
this.headers.set(layerLevel, header);
|
236
|
-
}
|
237
|
-
return header;
|
322
|
+
key: "createRowHeader",
|
323
|
+
value: function createRowHeader() {
|
324
|
+
return _classPrivateMethodGet(this, _createHighlight, _createHighlight2).call(this, this.rowHeaders, _header.createHighlight);
|
238
325
|
}
|
239
326
|
|
240
327
|
/**
|
@@ -243,29 +330,44 @@ var Highlight = /*#__PURE__*/function (_Symbol$iterator) {
|
|
243
330
|
* @returns {Selection[]}
|
244
331
|
*/
|
245
332
|
}, {
|
246
|
-
key: "
|
247
|
-
value: function
|
248
|
-
return _toConsumableArray(this.
|
333
|
+
key: "getRowHeaders",
|
334
|
+
value: function getRowHeaders() {
|
335
|
+
return _toConsumableArray(this.rowHeaders.values());
|
249
336
|
}
|
250
337
|
|
251
338
|
/**
|
252
|
-
*
|
253
|
-
*
|
339
|
+
* Creates (if not exist in the cache) Walkontable Selection instance created for controlling
|
340
|
+
* header highlight for columns.
|
254
341
|
*
|
255
342
|
* @returns {Selection}
|
256
343
|
*/
|
257
344
|
}, {
|
258
|
-
key: "
|
259
|
-
value: function
|
260
|
-
|
261
|
-
|
262
|
-
|
263
|
-
|
264
|
-
|
265
|
-
|
266
|
-
|
267
|
-
|
268
|
-
|
345
|
+
key: "createColumnHeader",
|
346
|
+
value: function createColumnHeader() {
|
347
|
+
return _classPrivateMethodGet(this, _createHighlight, _createHighlight2).call(this, this.columnHeaders, _header.createHighlight);
|
348
|
+
}
|
349
|
+
|
350
|
+
/**
|
351
|
+
* Get all Walkontable Selection instances which describes the state of the visual highlight of the headers.
|
352
|
+
*
|
353
|
+
* @returns {Selection[]}
|
354
|
+
*/
|
355
|
+
}, {
|
356
|
+
key: "getColumnHeaders",
|
357
|
+
value: function getColumnHeaders() {
|
358
|
+
return _toConsumableArray(this.columnHeaders.values());
|
359
|
+
}
|
360
|
+
|
361
|
+
/**
|
362
|
+
* Creates (if not exist in the cache) Walkontable Selection instance created for controlling
|
363
|
+
* highlight for active row headers.
|
364
|
+
*
|
365
|
+
* @returns {Selection}
|
366
|
+
*/
|
367
|
+
}, {
|
368
|
+
key: "createActiveRowHeader",
|
369
|
+
value: function createActiveRowHeader() {
|
370
|
+
return _classPrivateMethodGet(this, _createHighlight, _createHighlight2).call(this, this.activeRowHeaders, _activeHeader.createHighlight);
|
269
371
|
}
|
270
372
|
|
271
373
|
/**
|
@@ -274,9 +376,101 @@ var Highlight = /*#__PURE__*/function (_Symbol$iterator) {
|
|
274
376
|
* @returns {Selection[]}
|
275
377
|
*/
|
276
378
|
}, {
|
277
|
-
key: "
|
278
|
-
value: function
|
279
|
-
return _toConsumableArray(this.
|
379
|
+
key: "getActiveRowHeaders",
|
380
|
+
value: function getActiveRowHeaders() {
|
381
|
+
return _toConsumableArray(this.activeRowHeaders.values());
|
382
|
+
}
|
383
|
+
|
384
|
+
/**
|
385
|
+
* Creates (if not exist in the cache) Walkontable Selection instance created for controlling
|
386
|
+
* highlight for active column headers.
|
387
|
+
*
|
388
|
+
* @returns {Selection}
|
389
|
+
*/
|
390
|
+
}, {
|
391
|
+
key: "createActiveColumnHeader",
|
392
|
+
value: function createActiveColumnHeader() {
|
393
|
+
return _classPrivateMethodGet(this, _createHighlight, _createHighlight2).call(this, this.activeColumnHeaders, _activeHeader.createHighlight);
|
394
|
+
}
|
395
|
+
|
396
|
+
/**
|
397
|
+
* Get all Walkontable Selection instances which describes the state of the visual highlight of the active headers.
|
398
|
+
*
|
399
|
+
* @returns {Selection[]}
|
400
|
+
*/
|
401
|
+
}, {
|
402
|
+
key: "getActiveColumnHeaders",
|
403
|
+
value: function getActiveColumnHeaders() {
|
404
|
+
return _toConsumableArray(this.activeColumnHeaders.values());
|
405
|
+
}
|
406
|
+
|
407
|
+
/**
|
408
|
+
* Creates (if not exist in the cache) Walkontable Selection instance created for controlling
|
409
|
+
* highlight for the headers corner.
|
410
|
+
*
|
411
|
+
* @returns {Selection}
|
412
|
+
*/
|
413
|
+
}, {
|
414
|
+
key: "createActiveCornerHeader",
|
415
|
+
value: function createActiveCornerHeader() {
|
416
|
+
return _classPrivateMethodGet(this, _createHighlight, _createHighlight2).call(this, this.activeCornerHeaders, _activeHeader.createHighlight);
|
417
|
+
}
|
418
|
+
|
419
|
+
/**
|
420
|
+
* Get all Walkontable Selection instances which describes the state of the visual highlight of the headers corner.
|
421
|
+
*
|
422
|
+
* @returns {Selection[]}
|
423
|
+
*/
|
424
|
+
}, {
|
425
|
+
key: "getActiveCornerHeaders",
|
426
|
+
value: function getActiveCornerHeaders() {
|
427
|
+
return _toConsumableArray(this.activeCornerHeaders.values());
|
428
|
+
}
|
429
|
+
|
430
|
+
/**
|
431
|
+
* Creates (if not exist in the cache) Walkontable Selection instance created for controlling
|
432
|
+
* highlight cells in a row.
|
433
|
+
*
|
434
|
+
* @returns {Selection}
|
435
|
+
*/
|
436
|
+
}, {
|
437
|
+
key: "createRowHighlight",
|
438
|
+
value: function createRowHighlight() {
|
439
|
+
return _classPrivateMethodGet(this, _createHighlight, _createHighlight2).call(this, this.rowHighlights, _row.createHighlight);
|
440
|
+
}
|
441
|
+
|
442
|
+
/**
|
443
|
+
* Get all Walkontable Selection instances which describes the state of the rows highlighting.
|
444
|
+
*
|
445
|
+
* @returns {Selection[]}
|
446
|
+
*/
|
447
|
+
}, {
|
448
|
+
key: "getRowHighlights",
|
449
|
+
value: function getRowHighlights() {
|
450
|
+
return _toConsumableArray(this.rowHighlights.values());
|
451
|
+
}
|
452
|
+
|
453
|
+
/**
|
454
|
+
* Creates (if not exist in the cache) Walkontable Selection instance created for controlling
|
455
|
+
* highlight cells in a column.
|
456
|
+
*
|
457
|
+
* @returns {Selection}
|
458
|
+
*/
|
459
|
+
}, {
|
460
|
+
key: "createColumnHighlight",
|
461
|
+
value: function createColumnHighlight() {
|
462
|
+
return _classPrivateMethodGet(this, _createHighlight, _createHighlight2).call(this, this.columnHighlights, _column.createHighlight);
|
463
|
+
}
|
464
|
+
|
465
|
+
/**
|
466
|
+
* Get all Walkontable Selection instances which describes the state of the columns highlighting.
|
467
|
+
*
|
468
|
+
* @returns {Selection[]}
|
469
|
+
*/
|
470
|
+
}, {
|
471
|
+
key: "getColumnHighlights",
|
472
|
+
value: function getColumnHighlights() {
|
473
|
+
return _toConsumableArray(this.columnHighlights.values());
|
280
474
|
}
|
281
475
|
|
282
476
|
/**
|
@@ -298,7 +492,7 @@ var Highlight = /*#__PURE__*/function (_Symbol$iterator) {
|
|
298
492
|
}, {
|
299
493
|
key: "addCustomSelection",
|
300
494
|
value: function addCustomSelection(selectionInstance) {
|
301
|
-
this.customSelections.push((0,
|
495
|
+
this.customSelections.push((0, _customSelection.createHighlight)(_objectSpread(_objectSpread({}, this.options), selectionInstance)));
|
302
496
|
}
|
303
497
|
|
304
498
|
/**
|
@@ -307,31 +501,60 @@ var Highlight = /*#__PURE__*/function (_Symbol$iterator) {
|
|
307
501
|
}, {
|
308
502
|
key: "clear",
|
309
503
|
value: function clear() {
|
310
|
-
this.
|
504
|
+
this.focus.clear();
|
311
505
|
this.fill.clear();
|
312
506
|
(0, _array.arrayEach)(this.areas.values(), function (highlight) {
|
313
507
|
return void highlight.clear();
|
314
508
|
});
|
315
|
-
(0, _array.arrayEach)(this.
|
509
|
+
(0, _array.arrayEach)(this.layeredAreas.values(), function (highlight) {
|
510
|
+
return void highlight.clear();
|
511
|
+
});
|
512
|
+
(0, _array.arrayEach)(this.rowHeaders.values(), function (highlight) {
|
513
|
+
return void highlight.clear();
|
514
|
+
});
|
515
|
+
(0, _array.arrayEach)(this.columnHeaders.values(), function (highlight) {
|
516
|
+
return void highlight.clear();
|
517
|
+
});
|
518
|
+
(0, _array.arrayEach)(this.activeRowHeaders.values(), function (highlight) {
|
519
|
+
return void highlight.clear();
|
520
|
+
});
|
521
|
+
(0, _array.arrayEach)(this.activeColumnHeaders.values(), function (highlight) {
|
316
522
|
return void highlight.clear();
|
317
523
|
});
|
318
|
-
(0, _array.arrayEach)(this.
|
524
|
+
(0, _array.arrayEach)(this.activeCornerHeaders.values(), function (highlight) {
|
525
|
+
return void highlight.clear();
|
526
|
+
});
|
527
|
+
(0, _array.arrayEach)(this.rowHighlights.values(), function (highlight) {
|
528
|
+
return void highlight.clear();
|
529
|
+
});
|
530
|
+
(0, _array.arrayEach)(this.columnHighlights.values(), function (highlight) {
|
319
531
|
return void highlight.clear();
|
320
532
|
});
|
321
533
|
}
|
322
|
-
|
534
|
+
}, {
|
535
|
+
key: _Symbol$iterator,
|
536
|
+
value:
|
323
537
|
/**
|
324
538
|
* This object can be iterate over using `for of` syntax or using internal `arrayEach` helper.
|
325
539
|
*
|
326
540
|
* @returns {Selection[]}
|
327
541
|
*/
|
328
|
-
|
329
|
-
|
330
|
-
value: function value() {
|
331
|
-
return [this.cell, this.fill].concat(_toConsumableArray(this.areas.values()), _toConsumableArray(this.headers.values()), _toConsumableArray(this.activeHeaders.values()), _toConsumableArray(this.customSelections))[Symbol.iterator]();
|
542
|
+
function value() {
|
543
|
+
return [this.focus, this.fill].concat(_toConsumableArray(this.areas.values()), _toConsumableArray(this.layeredAreas.values()), _toConsumableArray(this.rowHeaders.values()), _toConsumableArray(this.columnHeaders.values()), _toConsumableArray(this.activeRowHeaders.values()), _toConsumableArray(this.activeColumnHeaders.values()), _toConsumableArray(this.activeCornerHeaders.values()), _toConsumableArray(this.rowHighlights.values()), _toConsumableArray(this.columnHighlights.values()), _toConsumableArray(this.customSelections))[Symbol.iterator]();
|
332
544
|
}
|
333
545
|
}]);
|
334
546
|
return Highlight;
|
335
|
-
}(
|
547
|
+
}();
|
548
|
+
function _createHighlight2(cacheMap, highlightFactory) {
|
549
|
+
var layerLevel = this.layerLevel;
|
550
|
+
if (cacheMap.has(layerLevel)) {
|
551
|
+
return cacheMap.get(layerLevel);
|
552
|
+
}
|
553
|
+
var highlight = highlightFactory(_objectSpread({
|
554
|
+
layerLevel: layerLevel
|
555
|
+
}, this.options));
|
556
|
+
cacheMap.set(layerLevel, highlight);
|
557
|
+
return highlight;
|
558
|
+
}
|
336
559
|
var _default = Highlight;
|
337
560
|
exports.default = _default;
|