handsontable 0.0.0-next-8d0643b-20230809 → 0.0.0-next-be16baf-20230809
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 +50 -11
- package/3rdparty/walkontable/src/cell/coords.mjs +50 -11
- package/3rdparty/walkontable/src/cell/range.d.ts +9 -2
- package/3rdparty/walkontable/src/cell/range.js +38 -7
- package/3rdparty/walkontable/src/cell/range.mjs +38 -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 -6
- package/3rdparty/walkontable/src/overlay/inlineStart.mjs +2 -6
- package/3rdparty/walkontable/src/overlay/top.js +2 -6
- package/3rdparty/walkontable/src/overlay/top.mjs +2 -6
- 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 +16 -0
- package/3rdparty/walkontable/src/selection/border/constants.mjs +12 -0
- package/3rdparty/walkontable/src/selection/constants.js +62 -0
- package/3rdparty/walkontable/src/selection/constants.mjs +51 -0
- package/3rdparty/walkontable/src/selection/index.js +26 -0
- package/3rdparty/walkontable/src/selection/index.mjs +5 -0
- package/3rdparty/walkontable/src/selection/manager.js +259 -0
- package/3rdparty/walkontable/src/selection/manager.mjs +254 -0
- package/3rdparty/walkontable/src/selection/scanner.js +270 -0
- package/3rdparty/walkontable/src/selection/scanner.mjs +267 -0
- package/3rdparty/walkontable/src/selection/selection.js +101 -0
- package/3rdparty/walkontable/src/selection/selection.mjs +96 -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 +6 -78
- package/3rdparty/walkontable/src/table.mjs +7 -79
- package/base.js +2 -2
- package/base.mjs +2 -2
- package/common.d.ts +1 -1
- package/core/focusCatcher/focusDetector.js +58 -0
- package/core/focusCatcher/focusDetector.mjs +54 -0
- package/core/focusCatcher/index.js +142 -0
- package/core/focusCatcher/index.mjs +138 -0
- package/core/index.js +9 -0
- package/core/index.mjs +1 -0
- package/core.d.ts +6 -3
- package/core.js +176 -293
- package/core.mjs +176 -293
- package/dataMap/metaManager/metaSchema.js +41 -0
- package/dataMap/metaManager/metaSchema.mjs +41 -0
- package/dist/handsontable.css +24 -4
- package/dist/handsontable.full.css +24 -4
- package/dist/handsontable.full.js +8682 -5378
- package/dist/handsontable.full.min.css +3 -3
- package/dist/handsontable.full.min.js +25 -25
- package/dist/handsontable.js +10989 -7685
- package/dist/handsontable.min.css +3 -3
- package/dist/handsontable.min.js +19 -19
- package/editorManager.js +11 -75
- package/editorManager.mjs +11 -74
- package/editors/baseEditor/baseEditor.d.ts +0 -1
- 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 +7 -1
- package/pluginHooks.js +106 -1
- package/pluginHooks.mjs +106 -1
- package/plugins/collapsibleColumns/collapsibleColumns.js +58 -4
- package/plugins/collapsibleColumns/collapsibleColumns.mjs +58 -4
- package/plugins/columnSorting/columnSorting.js +38 -0
- package/plugins/columnSorting/columnSorting.mjs +38 -2
- package/plugins/columnSorting/index.js +3 -1
- package/plugins/columnSorting/index.mjs +1 -1
- package/plugins/comments/commentEditor.js +1 -0
- package/plugins/comments/commentEditor.mjs +1 -0
- package/plugins/comments/comments.js +251 -189
- package/plugins/comments/comments.mjs +250 -190
- package/plugins/comments/contextMenuItem/addEditComment.js +41 -0
- package/plugins/comments/contextMenuItem/addEditComment.mjs +35 -0
- package/plugins/comments/contextMenuItem/readOnlyComment.js +49 -0
- package/plugins/comments/contextMenuItem/readOnlyComment.mjs +43 -0
- package/plugins/comments/contextMenuItem/removeComment.js +38 -0
- package/plugins/comments/contextMenuItem/removeComment.mjs +32 -0
- package/plugins/contextMenu/contextMenu.d.ts +1 -1
- package/plugins/contextMenu/contextMenu.js +72 -30
- package/plugins/contextMenu/contextMenu.mjs +73 -31
- 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 +28 -16
- package/plugins/contextMenu/utils.mjs +27 -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 +14 -10
- package/plugins/copyPaste/copyPaste.mjs +14 -10
- package/plugins/customBorders/customBorders.js +23 -20
- package/plugins/customBorders/customBorders.mjs +24 -21
- package/plugins/dropdownMenu/dropdownMenu.d.ts +1 -1
- package/plugins/dropdownMenu/dropdownMenu.js +89 -32
- package/plugins/dropdownMenu/dropdownMenu.mjs +89 -32
- package/plugins/filters/filters.js +31 -14
- package/plugins/filters/filters.mjs +30 -13
- package/plugins/mergeCells/mergeCells.js +5 -17
- package/plugins/mergeCells/mergeCells.mjs +5 -17
- package/plugins/multiColumnSorting/multiColumnSorting.js +37 -2
- package/plugins/multiColumnSorting/multiColumnSorting.mjs +37 -2
- package/plugins/nestedHeaders/nestedHeaders.js +121 -8
- package/plugins/nestedHeaders/nestedHeaders.mjs +121 -8
- package/plugins/nestedHeaders/stateManager/index.js +37 -0
- package/plugins/nestedHeaders/stateManager/index.mjs +37 -0
- package/plugins/nestedRows/nestedRows.js +41 -0
- package/plugins/nestedRows/nestedRows.mjs +41 -0
- package/renderers/checkboxRenderer/checkboxRenderer.js +2 -2
- package/renderers/checkboxRenderer/checkboxRenderer.mjs +1 -1
- package/selection/highlight/highlight.js +256 -71
- package/selection/highlight/highlight.mjs +250 -71
- package/selection/highlight/types/activeHeader.js +10 -8
- package/selection/highlight/types/activeHeader.mjs +10 -8
- package/selection/highlight/types/area.js +6 -18
- package/selection/highlight/types/area.mjs +6 -18
- package/selection/highlight/types/areaLayered.js +31 -0
- package/selection/highlight/types/areaLayered.mjs +26 -0
- package/selection/highlight/types/column.js +27 -0
- package/selection/highlight/types/column.mjs +22 -0
- package/selection/highlight/types/customSelection.js +7 -9
- package/selection/highlight/types/customSelection.mjs +7 -9
- package/selection/highlight/types/fill.js +5 -7
- package/selection/highlight/types/fill.mjs +5 -7
- package/selection/highlight/types/{cell.js → focus.js} +5 -7
- package/selection/highlight/types/{cell.mjs → focus.mjs} +5 -7
- package/selection/highlight/types/header.js +9 -18
- package/selection/highlight/types/header.mjs +9 -18
- package/selection/highlight/types/row.js +27 -0
- package/selection/highlight/types/row.mjs +22 -0
- 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 +293 -154
- package/selection/selection.mjs +290 -153
- package/selection/transformation.js +232 -90
- package/selection/transformation.mjs +232 -90
- package/selection/utils.js +15 -21
- package/selection/utils.mjs +16 -21
- package/settings.d.ts +2 -0
- package/shortcutContexts/commands/editor/closeAndSave.js +12 -0
- package/shortcutContexts/commands/editor/closeAndSave.mjs +8 -0
- package/shortcutContexts/commands/editor/closeWithoutSaving.js +12 -0
- package/shortcutContexts/commands/editor/closeWithoutSaving.mjs +8 -0
- package/shortcutContexts/commands/editor/fastOpen.js +16 -0
- package/shortcutContexts/commands/editor/fastOpen.mjs +12 -0
- package/shortcutContexts/commands/editor/index.js +16 -0
- package/shortcutContexts/commands/editor/index.mjs +12 -0
- package/shortcutContexts/commands/editor/open.js +27 -0
- package/shortcutContexts/commands/editor/open.mjs +23 -0
- package/shortcutContexts/commands/emptySelectedCells.js +11 -0
- package/shortcutContexts/commands/emptySelectedCells.mjs +7 -0
- package/shortcutContexts/commands/extendCellsSelection/down.js +15 -0
- package/shortcutContexts/commands/extendCellsSelection/down.mjs +11 -0
- package/shortcutContexts/commands/extendCellsSelection/downByViewportHeight.js +21 -0
- package/shortcutContexts/commands/extendCellsSelection/downByViewportHeight.mjs +17 -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 +11 -0
- package/shortcutContexts/commands/extendCellsSelection/right.js +15 -0
- package/shortcutContexts/commands/extendCellsSelection/right.mjs +11 -0
- package/shortcutContexts/commands/extendCellsSelection/toColumns.js +19 -0
- package/shortcutContexts/commands/extendCellsSelection/toColumns.mjs +15 -0
- package/shortcutContexts/commands/extendCellsSelection/toMostBottom.js +29 -0
- package/shortcutContexts/commands/extendCellsSelection/toMostBottom.mjs +25 -0
- package/shortcutContexts/commands/extendCellsSelection/toMostInlineEnd.js +19 -0
- package/shortcutContexts/commands/extendCellsSelection/toMostInlineEnd.mjs +15 -0
- package/shortcutContexts/commands/extendCellsSelection/toMostInlineStart.js +19 -0
- package/shortcutContexts/commands/extendCellsSelection/toMostInlineStart.mjs +15 -0
- package/shortcutContexts/commands/extendCellsSelection/toMostLeft.js +29 -0
- package/shortcutContexts/commands/extendCellsSelection/toMostLeft.mjs +25 -0
- package/shortcutContexts/commands/extendCellsSelection/toMostRight.js +29 -0
- package/shortcutContexts/commands/extendCellsSelection/toMostRight.mjs +25 -0
- package/shortcutContexts/commands/extendCellsSelection/toMostTop.js +29 -0
- package/shortcutContexts/commands/extendCellsSelection/toMostTop.mjs +25 -0
- package/shortcutContexts/commands/extendCellsSelection/toRows.js +19 -0
- package/shortcutContexts/commands/extendCellsSelection/toRows.mjs +15 -0
- package/shortcutContexts/commands/extendCellsSelection/up.js +15 -0
- package/shortcutContexts/commands/extendCellsSelection/up.mjs +11 -0
- package/shortcutContexts/commands/extendCellsSelection/upByViewportHeight.js +21 -0
- package/shortcutContexts/commands/extendCellsSelection/upByViewportHeight.mjs +17 -0
- package/shortcutContexts/commands/index.js +35 -0
- package/shortcutContexts/commands/index.mjs +31 -0
- package/shortcutContexts/commands/moveCellSelection/down.js +13 -0
- package/shortcutContexts/commands/moveCellSelection/down.mjs +9 -0
- package/shortcutContexts/commands/moveCellSelection/downByViewportHeight.js +31 -0
- package/shortcutContexts/commands/moveCellSelection/downByViewportHeight.mjs +27 -0
- package/shortcutContexts/commands/moveCellSelection/index.js +28 -0
- package/shortcutContexts/commands/moveCellSelection/index.mjs +24 -0
- package/shortcutContexts/commands/moveCellSelection/inlineEnd.js +12 -0
- package/shortcutContexts/commands/moveCellSelection/inlineEnd.mjs +8 -0
- package/shortcutContexts/commands/moveCellSelection/inlineStart.js +12 -0
- package/shortcutContexts/commands/moveCellSelection/inlineStart.mjs +8 -0
- package/shortcutContexts/commands/moveCellSelection/left.js +10 -0
- package/shortcutContexts/commands/moveCellSelection/left.mjs +6 -0
- package/shortcutContexts/commands/moveCellSelection/right.js +10 -0
- package/shortcutContexts/commands/moveCellSelection/right.mjs +6 -0
- package/shortcutContexts/commands/moveCellSelection/toMostBottom.js +17 -0
- package/shortcutContexts/commands/moveCellSelection/toMostBottom.mjs +13 -0
- package/shortcutContexts/commands/moveCellSelection/toMostBottomInlineEnd.js +18 -0
- package/shortcutContexts/commands/moveCellSelection/toMostBottomInlineEnd.mjs +14 -0
- package/shortcutContexts/commands/moveCellSelection/toMostInlineEnd.js +14 -0
- package/shortcutContexts/commands/moveCellSelection/toMostInlineEnd.mjs +10 -0
- package/shortcutContexts/commands/moveCellSelection/toMostInlineStart.js +17 -0
- package/shortcutContexts/commands/moveCellSelection/toMostInlineStart.mjs +13 -0
- package/shortcutContexts/commands/moveCellSelection/toMostLeft.js +19 -0
- package/shortcutContexts/commands/moveCellSelection/toMostLeft.mjs +15 -0
- package/shortcutContexts/commands/moveCellSelection/toMostRight.js +21 -0
- package/shortcutContexts/commands/moveCellSelection/toMostRight.mjs +17 -0
- package/shortcutContexts/commands/moveCellSelection/toMostTop.js +17 -0
- package/shortcutContexts/commands/moveCellSelection/toMostTop.mjs +13 -0
- package/shortcutContexts/commands/moveCellSelection/toMostTopInlineStart.js +19 -0
- package/shortcutContexts/commands/moveCellSelection/toMostTopInlineStart.mjs +15 -0
- package/shortcutContexts/commands/moveCellSelection/up.js +13 -0
- package/shortcutContexts/commands/moveCellSelection/up.mjs +9 -0
- package/shortcutContexts/commands/moveCellSelection/upByViewportHeight.js +31 -0
- package/shortcutContexts/commands/moveCellSelection/upByViewportHeight.mjs +27 -0
- package/shortcutContexts/commands/populateSelectedCellsData.js +29 -0
- package/shortcutContexts/commands/populateSelectedCellsData.mjs +25 -0
- package/shortcutContexts/commands/scrollToFocusedCell.js +36 -0
- package/shortcutContexts/commands/scrollToFocusedCell.mjs +32 -0
- package/shortcutContexts/commands/selectAll.js +10 -0
- package/shortcutContexts/commands/selectAll.mjs +6 -0
- package/shortcutContexts/constants.js +13 -0
- package/shortcutContexts/constants.mjs +8 -0
- package/shortcutContexts/editor.js +25 -0
- package/shortcutContexts/editor.mjs +21 -0
- package/shortcutContexts/grid.js +163 -0
- package/shortcutContexts/grid.mjs +159 -0
- package/shortcutContexts/index.js +24 -0
- package/shortcutContexts/index.mjs +11 -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 +19 -5
- package/shortcuts/utils.mjs +18 -4
- package/tableView.js +67 -13
- package/tableView.mjs +67 -13
- package/3rdparty/walkontable/src/selection.js +0 -295
- package/3rdparty/walkontable/src/selection.mjs +0 -290
- package/selection/highlight/constants.js +0 -15
- package/selection/highlight/constants.mjs +0 -6
- package/selection/highlight/types/index.js +0 -35
- package/selection/highlight/types/index.mjs +0 -31
package/pluginHooks.mjs
CHANGED
@@ -552,6 +552,13 @@ const REGISTERED_HOOKS = [/* eslint-disable jsdoc/require-description-complete-s
|
|
552
552
|
* @event Hooks#afterScrollVertically
|
553
553
|
*/
|
554
554
|
'afterScrollVertically',
|
555
|
+
/**
|
556
|
+
* Fired after the vertical or horizontal scroll event.
|
557
|
+
*
|
558
|
+
* @since 14.0.0
|
559
|
+
* @event Hooks#afterScroll
|
560
|
+
*/
|
561
|
+
'afterScroll',
|
555
562
|
/**
|
556
563
|
* Fired after one or more cells are selected (e.g. During mouse move).
|
557
564
|
*
|
@@ -655,6 +662,94 @@ const REGISTERED_HOOKS = [/* eslint-disable jsdoc/require-description-complete-s
|
|
655
662
|
* @param {number} selectionLayerLevel The number which indicates what selection layer is currently modified.
|
656
663
|
*/
|
657
664
|
'afterSelectionEndByProp',
|
665
|
+
/**
|
666
|
+
* Fired before one or more columns are selected (e.g. During mouse header click or {@link Core#selectColumns} API call).
|
667
|
+
*
|
668
|
+
* @since 14.0.0
|
669
|
+
* @event Hooks#beforeSelectColumns
|
670
|
+
* @param {CellCoords} from Selection start coords object.
|
671
|
+
* @param {CellCoords} to Selection end coords object.
|
672
|
+
* @param {CellCoords} highlight Selection cell focus coords object.
|
673
|
+
* @example
|
674
|
+
* ::: only-for javascript
|
675
|
+
* ```js
|
676
|
+
* new Handsontable(element, {
|
677
|
+
* beforeSelectColumns: (from, to, highlight) => {
|
678
|
+
* // Extend the column selection by one column left and one column right.
|
679
|
+
* from.col = Math.max(from.col - 1, 0);
|
680
|
+
* to.col = Math.min(to.col + 1, this.countCols() - 1);
|
681
|
+
* }
|
682
|
+
* })
|
683
|
+
* ```
|
684
|
+
* :::
|
685
|
+
*
|
686
|
+
* ::: only-for react
|
687
|
+
* ```jsx
|
688
|
+
* <HotTable
|
689
|
+
* beforeSelectColumns={(from, to, highlight) => {
|
690
|
+
* // Extend the column selection by one column left and one column right.
|
691
|
+
* from.col = Math.max(from.col - 1, 0);
|
692
|
+
* to.col = Math.min(to.col + 1, this.countCols() - 1);
|
693
|
+
* }}
|
694
|
+
* />
|
695
|
+
* ```
|
696
|
+
* :::
|
697
|
+
*/
|
698
|
+
'beforeSelectColumns',
|
699
|
+
/**
|
700
|
+
* Fired after one or more columns are selected (e.g. During mouse header click or {@link Core#selectColumns} API call).
|
701
|
+
*
|
702
|
+
* @since 14.0.0
|
703
|
+
* @event Hooks#afterSelectColumns
|
704
|
+
* @param {CellCoords} from Selection start coords object.
|
705
|
+
* @param {CellCoords} to Selection end coords object.
|
706
|
+
* @param {CellCoords} highlight Selection cell focus coords object.
|
707
|
+
*/
|
708
|
+
'afterSelectColumns',
|
709
|
+
/**
|
710
|
+
* Fired before one or more rows are selected (e.g. During mouse header click or {@link Core#selectRows} API call).
|
711
|
+
*
|
712
|
+
* @since 14.0.0
|
713
|
+
* @event Hooks#beforeSelectRows
|
714
|
+
* @param {CellCoords} from Selection start coords object.
|
715
|
+
* @param {CellCoords} to Selection end coords object.
|
716
|
+
* @param {CellCoords} highlight Selection cell focus coords object.
|
717
|
+
* @example
|
718
|
+
* ::: only-for javascript
|
719
|
+
* ```js
|
720
|
+
* new Handsontable(element, {
|
721
|
+
* beforeSelectRows: (from, to, highlight) => {
|
722
|
+
* // Extend the row selection by one row up and one row bottom more.
|
723
|
+
* from.row = Math.max(from.row - 1, 0);
|
724
|
+
* to.row = Math.min(to.row + 1, this.countRows() - 1);
|
725
|
+
* }
|
726
|
+
* })
|
727
|
+
* ```
|
728
|
+
* :::
|
729
|
+
*
|
730
|
+
* ::: only-for react
|
731
|
+
* ```jsx
|
732
|
+
* <HotTable
|
733
|
+
* beforeSelectRows={(from, to, highlight) => {
|
734
|
+
* // Extend the row selection by one row up and one row bottom more.
|
735
|
+
* from.row = Math.max(from.row - 1, 0);
|
736
|
+
* to.row = Math.min(to.row + 1, this.countRows() - 1);
|
737
|
+
* }}
|
738
|
+
* />
|
739
|
+
* ```
|
740
|
+
* :::
|
741
|
+
*/
|
742
|
+
'beforeSelectRows',
|
743
|
+
/**
|
744
|
+
* Fired after one or more rows are selected (e.g. During mouse header click or {@link Core#selectRows} API call).
|
745
|
+
*
|
746
|
+
* @since 14.0.0
|
747
|
+
* @event Hooks#afterSelectRows
|
748
|
+
* @param {CellCoords} from Selection start coords object.
|
749
|
+
* @param {CellCoords} to Selection end coords object.
|
750
|
+
* @param {CellCoords} highlight Selection cell focus coords object.
|
751
|
+
*/
|
752
|
+
'afterSelectRows',
|
658
753
|
/**
|
659
754
|
* Fired after cell meta is changed.
|
660
755
|
*
|
@@ -1223,6 +1318,16 @@ const REGISTERED_HOOKS = [/* eslint-disable jsdoc/require-description-complete-s
|
|
1223
1318
|
* @returns {undefined|number[]}
|
1224
1319
|
*/
|
1225
1320
|
'modifyGetCellCoords',
|
1321
|
+
/**
|
1322
|
+
* Used to modify the cell coordinates when the table is activated (going into the listen mode).
|
1323
|
+
*
|
1324
|
+
* @event Hooks#modifyFocusOnTabNavigation
|
1325
|
+
* @since 14.0.0
|
1326
|
+
* @param {'from_above' | 'from_below'} tabActivationDir The browsers Tab navigation direction. Depending on
|
1327
|
+
* whether the user activated the table from the element above or below, another cell can be selected.
|
1328
|
+
* @param {CellCoords} visualCoords The coords that will be used to select a cell.
|
1329
|
+
*/
|
1330
|
+
'modifyFocusOnTabNavigation',
|
1226
1331
|
/**
|
1227
1332
|
* Allows modify the visual row index that is used to retrieve the row header element (TH) before it's
|
1228
1333
|
* highlighted (proper CSS class names are added). Modifying the visual row index allows building a custom
|
@@ -2380,7 +2485,7 @@ const REMOVED_HOOKS = new Map([['modifyRow', '8.0.0'], ['modifyCol', '8.0.0'], [
|
|
2380
2485
|
* @type {Map<string, string>}
|
2381
2486
|
*/
|
2382
2487
|
/* eslint-enable jsdoc/require-description-complete-sentence */
|
2383
|
-
const DEPRECATED_HOOKS = new Map([]);
|
2488
|
+
const DEPRECATED_HOOKS = new Map([['beforeRemoveCellClassNames', 'The hook "beforeRemoveCellClassNames" is deprecated and will be removed in the next major release.']]);
|
2384
2489
|
class Hooks {
|
2385
2490
|
static getSingleton() {
|
2386
2491
|
return getGlobalSingleton();
|
@@ -27,6 +27,7 @@ const PLUGIN_PRIORITY = 290;
|
|
27
27
|
exports.PLUGIN_PRIORITY = PLUGIN_PRIORITY;
|
28
28
|
const SETTING_KEYS = ['nestedHeaders'];
|
29
29
|
const COLLAPSIBLE_ELEMENT_CLASS = 'collapsibleIndicator';
|
30
|
+
const SHORTCUTS_GROUP = PLUGIN_KEY;
|
30
31
|
const actionDictionary = new Map([['collapse', {
|
31
32
|
hideColumn: true,
|
32
33
|
beforeHook: 'beforeColumnCollapse',
|
@@ -191,6 +192,7 @@ class CollapsibleColumns extends _base.BasePlugin {
|
|
191
192
|
return _this.onAfterGetColHeader(...arguments);
|
192
193
|
});
|
193
194
|
this.addHook('beforeOnCellMouseDown', (event, coords, TD) => this.onBeforeOnCellMouseDown(event, coords, TD));
|
195
|
+
this.registerShortcuts();
|
194
196
|
super.enablePlugin();
|
195
197
|
// @TODO: Workaround for broken plugin initialization abstraction (#6806).
|
196
198
|
this.updatePlugin();
|
@@ -238,10 +240,62 @@ class CollapsibleColumns extends _base.BasePlugin {
|
|
238
240
|
this.hot.columnIndexMapper.unregisterMap(this.pluginName);
|
239
241
|
_classPrivateFieldSet(this, _collapsedColumnsMap, null);
|
240
242
|
this.nestedHeadersPlugin = null;
|
243
|
+
this.unregisterShortcuts();
|
241
244
|
this.clearButtons();
|
242
245
|
super.disablePlugin();
|
243
246
|
}
|
244
247
|
|
248
|
+
/**
|
249
|
+
* Register shortcuts responsible for toggling collapsible columns.
|
250
|
+
*
|
251
|
+
* @private
|
252
|
+
*/
|
253
|
+
registerShortcuts() {
|
254
|
+
this.hot.getShortcutManager().getContext('grid').addShortcut({
|
255
|
+
keys: [['Enter']],
|
256
|
+
callback: () => {
|
257
|
+
var _this$headerStateMana;
|
258
|
+
const {
|
259
|
+
row,
|
260
|
+
col
|
261
|
+
} = this.hot.getSelectedRangeLast().highlight;
|
262
|
+
const {
|
263
|
+
collapsible,
|
264
|
+
isCollapsed,
|
265
|
+
columnIndex
|
266
|
+
} = (_this$headerStateMana = this.headerStateManager.getHeaderTreeNodeData(row, col)) !== null && _this$headerStateMana !== void 0 ? _this$headerStateMana : {};
|
267
|
+
if (!collapsible) {
|
268
|
+
return;
|
269
|
+
}
|
270
|
+
if (isCollapsed) {
|
271
|
+
this.expandSection({
|
272
|
+
row,
|
273
|
+
col: columnIndex
|
274
|
+
});
|
275
|
+
} else {
|
276
|
+
this.collapseSection({
|
277
|
+
row,
|
278
|
+
col: columnIndex
|
279
|
+
});
|
280
|
+
}
|
281
|
+
},
|
282
|
+
runOnlyIf: () => {
|
283
|
+
var _this$hot$getSelected;
|
284
|
+
return (_this$hot$getSelected = this.hot.getSelectedRangeLast()) === null || _this$hot$getSelected === void 0 ? void 0 : _this$hot$getSelected.highlight.isHeader();
|
285
|
+
},
|
286
|
+
group: SHORTCUTS_GROUP
|
287
|
+
});
|
288
|
+
}
|
289
|
+
|
290
|
+
/**
|
291
|
+
* Unregister shortcuts responsible for toggling collapsible columns.
|
292
|
+
*
|
293
|
+
* @private
|
294
|
+
*/
|
295
|
+
unregisterShortcuts() {
|
296
|
+
this.hot.getShortcutManager().getContext('grid').removeShortcutsByGroup(SHORTCUTS_GROUP);
|
297
|
+
}
|
298
|
+
|
245
299
|
/**
|
246
300
|
* Clears the expand/collapse buttons.
|
247
301
|
*
|
@@ -362,7 +416,7 @@ class CollapsibleColumns extends _base.BasePlugin {
|
|
362
416
|
});
|
363
417
|
let isActionPossible = filteredCoords.length > 0;
|
364
418
|
(0, _array.arrayEach)(filteredCoords, _ref2 => {
|
365
|
-
var _this$
|
419
|
+
var _this$headerStateMana2;
|
366
420
|
let {
|
367
421
|
row,
|
368
422
|
col: column
|
@@ -370,7 +424,7 @@ class CollapsibleColumns extends _base.BasePlugin {
|
|
370
424
|
const {
|
371
425
|
collapsible,
|
372
426
|
isCollapsed
|
373
|
-
} = (_this$
|
427
|
+
} = (_this$headerStateMana2 = this.headerStateManager.getHeaderSettings(row, column)) !== null && _this$headerStateMana2 !== void 0 ? _this$headerStateMana2 : {};
|
374
428
|
if (!collapsible || isCollapsed && action === 'collapse' || !isCollapsed && action === 'expand') {
|
375
429
|
isActionPossible = false;
|
376
430
|
return false;
|
@@ -442,12 +496,12 @@ class CollapsibleColumns extends _base.BasePlugin {
|
|
442
496
|
* values counting from 0 to N).
|
443
497
|
*/
|
444
498
|
onAfterGetColHeader(column, TH, headerLevel) {
|
445
|
-
var _this$
|
499
|
+
var _this$headerStateMana3;
|
446
500
|
const {
|
447
501
|
collapsible,
|
448
502
|
origColspan,
|
449
503
|
isCollapsed
|
450
|
-
} = (_this$
|
504
|
+
} = (_this$headerStateMana3 = this.headerStateManager.getHeaderSettings(headerLevel, column)) !== null && _this$headerStateMana3 !== void 0 ? _this$headerStateMana3 : {};
|
451
505
|
const isNodeCollapsible = collapsible && origColspan > 1 && column >= this.hot.getSettings().fixedColumnsStart;
|
452
506
|
let collapsibleElement = TH.querySelector(`.${COLLAPSIBLE_ELEMENT_CLASS}`);
|
453
507
|
if (isNodeCollapsible) {
|
@@ -21,6 +21,7 @@ export const PLUGIN_KEY = 'collapsibleColumns';
|
|
21
21
|
export const PLUGIN_PRIORITY = 290;
|
22
22
|
const SETTING_KEYS = ['nestedHeaders'];
|
23
23
|
const COLLAPSIBLE_ELEMENT_CLASS = 'collapsibleIndicator';
|
24
|
+
const SHORTCUTS_GROUP = PLUGIN_KEY;
|
24
25
|
const actionDictionary = new Map([['collapse', {
|
25
26
|
hideColumn: true,
|
26
27
|
beforeHook: 'beforeColumnCollapse',
|
@@ -185,6 +186,7 @@ export class CollapsibleColumns extends BasePlugin {
|
|
185
186
|
return _this.onAfterGetColHeader(...arguments);
|
186
187
|
});
|
187
188
|
this.addHook('beforeOnCellMouseDown', (event, coords, TD) => this.onBeforeOnCellMouseDown(event, coords, TD));
|
189
|
+
this.registerShortcuts();
|
188
190
|
super.enablePlugin();
|
189
191
|
// @TODO: Workaround for broken plugin initialization abstraction (#6806).
|
190
192
|
this.updatePlugin();
|
@@ -232,10 +234,62 @@ export class CollapsibleColumns extends BasePlugin {
|
|
232
234
|
this.hot.columnIndexMapper.unregisterMap(this.pluginName);
|
233
235
|
_classPrivateFieldSet(this, _collapsedColumnsMap, null);
|
234
236
|
this.nestedHeadersPlugin = null;
|
237
|
+
this.unregisterShortcuts();
|
235
238
|
this.clearButtons();
|
236
239
|
super.disablePlugin();
|
237
240
|
}
|
238
241
|
|
242
|
+
/**
|
243
|
+
* Register shortcuts responsible for toggling collapsible columns.
|
244
|
+
*
|
245
|
+
* @private
|
246
|
+
*/
|
247
|
+
registerShortcuts() {
|
248
|
+
this.hot.getShortcutManager().getContext('grid').addShortcut({
|
249
|
+
keys: [['Enter']],
|
250
|
+
callback: () => {
|
251
|
+
var _this$headerStateMana;
|
252
|
+
const {
|
253
|
+
row,
|
254
|
+
col
|
255
|
+
} = this.hot.getSelectedRangeLast().highlight;
|
256
|
+
const {
|
257
|
+
collapsible,
|
258
|
+
isCollapsed,
|
259
|
+
columnIndex
|
260
|
+
} = (_this$headerStateMana = this.headerStateManager.getHeaderTreeNodeData(row, col)) !== null && _this$headerStateMana !== void 0 ? _this$headerStateMana : {};
|
261
|
+
if (!collapsible) {
|
262
|
+
return;
|
263
|
+
}
|
264
|
+
if (isCollapsed) {
|
265
|
+
this.expandSection({
|
266
|
+
row,
|
267
|
+
col: columnIndex
|
268
|
+
});
|
269
|
+
} else {
|
270
|
+
this.collapseSection({
|
271
|
+
row,
|
272
|
+
col: columnIndex
|
273
|
+
});
|
274
|
+
}
|
275
|
+
},
|
276
|
+
runOnlyIf: () => {
|
277
|
+
var _this$hot$getSelected;
|
278
|
+
return (_this$hot$getSelected = this.hot.getSelectedRangeLast()) === null || _this$hot$getSelected === void 0 ? void 0 : _this$hot$getSelected.highlight.isHeader();
|
279
|
+
},
|
280
|
+
group: SHORTCUTS_GROUP
|
281
|
+
});
|
282
|
+
}
|
283
|
+
|
284
|
+
/**
|
285
|
+
* Unregister shortcuts responsible for toggling collapsible columns.
|
286
|
+
*
|
287
|
+
* @private
|
288
|
+
*/
|
289
|
+
unregisterShortcuts() {
|
290
|
+
this.hot.getShortcutManager().getContext('grid').removeShortcutsByGroup(SHORTCUTS_GROUP);
|
291
|
+
}
|
292
|
+
|
239
293
|
/**
|
240
294
|
* Clears the expand/collapse buttons.
|
241
295
|
*
|
@@ -356,7 +410,7 @@ export class CollapsibleColumns extends BasePlugin {
|
|
356
410
|
});
|
357
411
|
let isActionPossible = filteredCoords.length > 0;
|
358
412
|
arrayEach(filteredCoords, _ref2 => {
|
359
|
-
var _this$
|
413
|
+
var _this$headerStateMana2;
|
360
414
|
let {
|
361
415
|
row,
|
362
416
|
col: column
|
@@ -364,7 +418,7 @@ export class CollapsibleColumns extends BasePlugin {
|
|
364
418
|
const {
|
365
419
|
collapsible,
|
366
420
|
isCollapsed
|
367
|
-
} = (_this$
|
421
|
+
} = (_this$headerStateMana2 = this.headerStateManager.getHeaderSettings(row, column)) !== null && _this$headerStateMana2 !== void 0 ? _this$headerStateMana2 : {};
|
368
422
|
if (!collapsible || isCollapsed && action === 'collapse' || !isCollapsed && action === 'expand') {
|
369
423
|
isActionPossible = false;
|
370
424
|
return false;
|
@@ -436,12 +490,12 @@ export class CollapsibleColumns extends BasePlugin {
|
|
436
490
|
* values counting from 0 to N).
|
437
491
|
*/
|
438
492
|
onAfterGetColHeader(column, TH, headerLevel) {
|
439
|
-
var _this$
|
493
|
+
var _this$headerStateMana3;
|
440
494
|
const {
|
441
495
|
collapsible,
|
442
496
|
origColspan,
|
443
497
|
isCollapsed
|
444
|
-
} = (_this$
|
498
|
+
} = (_this$headerStateMana3 = this.headerStateManager.getHeaderSettings(headerLevel, column)) !== null && _this$headerStateMana3 !== void 0 ? _this$headerStateMana3 : {};
|
445
499
|
const isNodeCollapsible = collapsible && origColspan > 1 && column >= this.hot.getSettings().fixedColumnsStart;
|
446
500
|
let collapsibleElement = TH.querySelector(`.${COLLAPSIBLE_ELEMENT_CLASS}`);
|
447
501
|
if (isNodeCollapsible) {
|
@@ -21,7 +21,10 @@ exports.PLUGIN_KEY = PLUGIN_KEY;
|
|
21
21
|
const PLUGIN_PRIORITY = 50;
|
22
22
|
exports.PLUGIN_PRIORITY = PLUGIN_PRIORITY;
|
23
23
|
const APPEND_COLUMN_CONFIG_STRATEGY = 'append';
|
24
|
+
exports.APPEND_COLUMN_CONFIG_STRATEGY = APPEND_COLUMN_CONFIG_STRATEGY;
|
24
25
|
const REPLACE_COLUMN_CONFIG_STRATEGY = 'replace';
|
26
|
+
exports.REPLACE_COLUMN_CONFIG_STRATEGY = REPLACE_COLUMN_CONFIG_STRATEGY;
|
27
|
+
const SHORTCUTS_GROUP = PLUGIN_KEY;
|
25
28
|
(0, _sortService.registerRootComparator)(PLUGIN_KEY, _rootComparator.rootComparator);
|
26
29
|
_pluginHooks.default.getSingleton().register('beforeColumnSort');
|
27
30
|
_pluginHooks.default.getSingleton().register('afterColumnSort');
|
@@ -156,6 +159,7 @@ class ColumnSorting extends _base.BasePlugin {
|
|
156
159
|
if (this.hot.view) {
|
157
160
|
this.loadOrSortBySettings();
|
158
161
|
}
|
162
|
+
this.registerShortcuts();
|
159
163
|
super.enablePlugin();
|
160
164
|
}
|
161
165
|
|
@@ -186,9 +190,43 @@ class ColumnSorting extends _base.BasePlugin {
|
|
186
190
|
this.columnStatesManager.destroy();
|
187
191
|
this.columnMetaCache = null;
|
188
192
|
this.columnStatesManager = null;
|
193
|
+
this.unregisterShortcuts();
|
189
194
|
super.disablePlugin();
|
190
195
|
}
|
191
196
|
|
197
|
+
/**
|
198
|
+
* Register shortcuts responsible for toggling column sorting functionality.
|
199
|
+
*
|
200
|
+
* @private
|
201
|
+
*/
|
202
|
+
registerShortcuts() {
|
203
|
+
this.hot.getShortcutManager().getContext('grid').addShortcut({
|
204
|
+
keys: [['Enter']],
|
205
|
+
callback: () => {
|
206
|
+
const {
|
207
|
+
highlight
|
208
|
+
} = this.hot.getSelectedRangeLast();
|
209
|
+
if (highlight.row === -1 && highlight.col >= 0) {
|
210
|
+
this.sort(this.getColumnNextConfig(highlight.col));
|
211
|
+
}
|
212
|
+
},
|
213
|
+
runOnlyIf: () => {
|
214
|
+
var _this$hot$getSelected;
|
215
|
+
return (_this$hot$getSelected = this.hot.getSelectedRangeLast()) === null || _this$hot$getSelected === void 0 ? void 0 : _this$hot$getSelected.highlight.isHeader();
|
216
|
+
},
|
217
|
+
group: SHORTCUTS_GROUP
|
218
|
+
});
|
219
|
+
}
|
220
|
+
|
221
|
+
/**
|
222
|
+
* Unregister shortcuts responsible for toggling column sorting functionality.
|
223
|
+
*
|
224
|
+
* @private
|
225
|
+
*/
|
226
|
+
unregisterShortcuts() {
|
227
|
+
this.hot.getShortcutManager().getContext('grid').removeShortcutsByGroup(SHORTCUTS_GROUP);
|
228
|
+
}
|
229
|
+
|
192
230
|
// DIFF - MultiColumnSorting & ColumnSorting: changed function documentation.
|
193
231
|
/**
|
194
232
|
* Sorts the table by chosen columns and orders.
|
@@ -14,8 +14,9 @@ import { rootComparator } from "./rootComparator.mjs";
|
|
14
14
|
import { registerRootComparator, sort } from "./sortService/index.mjs";
|
15
15
|
export const PLUGIN_KEY = 'columnSorting';
|
16
16
|
export const PLUGIN_PRIORITY = 50;
|
17
|
-
const APPEND_COLUMN_CONFIG_STRATEGY = 'append';
|
18
|
-
const REPLACE_COLUMN_CONFIG_STRATEGY = 'replace';
|
17
|
+
export const APPEND_COLUMN_CONFIG_STRATEGY = 'append';
|
18
|
+
export const REPLACE_COLUMN_CONFIG_STRATEGY = 'replace';
|
19
|
+
const SHORTCUTS_GROUP = PLUGIN_KEY;
|
19
20
|
registerRootComparator(PLUGIN_KEY, rootComparator);
|
20
21
|
Hooks.getSingleton().register('beforeColumnSort');
|
21
22
|
Hooks.getSingleton().register('afterColumnSort');
|
@@ -150,6 +151,7 @@ export class ColumnSorting extends BasePlugin {
|
|
150
151
|
if (this.hot.view) {
|
151
152
|
this.loadOrSortBySettings();
|
152
153
|
}
|
154
|
+
this.registerShortcuts();
|
153
155
|
super.enablePlugin();
|
154
156
|
}
|
155
157
|
|
@@ -180,9 +182,43 @@ export class ColumnSorting extends BasePlugin {
|
|
180
182
|
this.columnStatesManager.destroy();
|
181
183
|
this.columnMetaCache = null;
|
182
184
|
this.columnStatesManager = null;
|
185
|
+
this.unregisterShortcuts();
|
183
186
|
super.disablePlugin();
|
184
187
|
}
|
185
188
|
|
189
|
+
/**
|
190
|
+
* Register shortcuts responsible for toggling column sorting functionality.
|
191
|
+
*
|
192
|
+
* @private
|
193
|
+
*/
|
194
|
+
registerShortcuts() {
|
195
|
+
this.hot.getShortcutManager().getContext('grid').addShortcut({
|
196
|
+
keys: [['Enter']],
|
197
|
+
callback: () => {
|
198
|
+
const {
|
199
|
+
highlight
|
200
|
+
} = this.hot.getSelectedRangeLast();
|
201
|
+
if (highlight.row === -1 && highlight.col >= 0) {
|
202
|
+
this.sort(this.getColumnNextConfig(highlight.col));
|
203
|
+
}
|
204
|
+
},
|
205
|
+
runOnlyIf: () => {
|
206
|
+
var _this$hot$getSelected;
|
207
|
+
return (_this$hot$getSelected = this.hot.getSelectedRangeLast()) === null || _this$hot$getSelected === void 0 ? void 0 : _this$hot$getSelected.highlight.isHeader();
|
208
|
+
},
|
209
|
+
group: SHORTCUTS_GROUP
|
210
|
+
});
|
211
|
+
}
|
212
|
+
|
213
|
+
/**
|
214
|
+
* Unregister shortcuts responsible for toggling column sorting functionality.
|
215
|
+
*
|
216
|
+
* @private
|
217
|
+
*/
|
218
|
+
unregisterShortcuts() {
|
219
|
+
this.hot.getShortcutManager().getContext('grid').removeShortcutsByGroup(SHORTCUTS_GROUP);
|
220
|
+
}
|
221
|
+
|
186
222
|
// DIFF - MultiColumnSorting & ColumnSorting: changed function documentation.
|
187
223
|
/**
|
188
224
|
* Sorts the table by chosen columns and orders.
|
@@ -4,4 +4,6 @@ exports.__esModule = true;
|
|
4
4
|
var _columnSorting = require("./columnSorting");
|
5
5
|
exports.PLUGIN_KEY = _columnSorting.PLUGIN_KEY;
|
6
6
|
exports.PLUGIN_PRIORITY = _columnSorting.PLUGIN_PRIORITY;
|
7
|
-
exports.ColumnSorting = _columnSorting.ColumnSorting;
|
7
|
+
exports.ColumnSorting = _columnSorting.ColumnSorting;
|
8
|
+
exports.APPEND_COLUMN_CONFIG_STRATEGY = _columnSorting.APPEND_COLUMN_CONFIG_STRATEGY;
|
9
|
+
exports.REPLACE_COLUMN_CONFIG_STRATEGY = _columnSorting.REPLACE_COLUMN_CONFIG_STRATEGY;
|
@@ -1 +1 @@
|
|
1
|
-
export { PLUGIN_KEY, PLUGIN_PRIORITY, ColumnSorting } from "./columnSorting.mjs";
|
1
|
+
export { PLUGIN_KEY, PLUGIN_PRIORITY, ColumnSorting, APPEND_COLUMN_CONFIG_STRATEGY, REPLACE_COLUMN_CONFIG_STRATEGY } from "./columnSorting.mjs";
|
@@ -165,6 +165,7 @@ class CommentEditor {
|
|
165
165
|
this.rootDocument.body.appendChild(this.container);
|
166
166
|
(0, _element.addClass)(editor, CommentEditor.CLASS_EDITOR);
|
167
167
|
(0, _element.addClass)(textArea, CommentEditor.CLASS_INPUT);
|
168
|
+
textArea.setAttribute('data-hot-input', true);
|
168
169
|
editor.appendChild(textArea);
|
169
170
|
this.container.appendChild(editor);
|
170
171
|
return editor;
|
@@ -162,6 +162,7 @@ class CommentEditor {
|
|
162
162
|
this.rootDocument.body.appendChild(this.container);
|
163
163
|
addClass(editor, CommentEditor.CLASS_EDITOR);
|
164
164
|
addClass(textArea, CommentEditor.CLASS_INPUT);
|
165
|
+
textArea.setAttribute('data-hot-input', true);
|
165
166
|
editor.appendChild(textArea);
|
166
167
|
this.container.appendChild(editor);
|
167
168
|
return editor;
|