handsontable 0.0.0-next-440bcae-20231107 → 0.0.0-next-dc2c114-20231107

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of handsontable might be problematic. Click here for more details.

Files changed (317) hide show
  1. package/3rdparty/SheetClip/SheetClip.js +2 -2
  2. package/3rdparty/SheetClip/SheetClip.mjs +2 -2
  3. package/3rdparty/autoResize/autoResize.js +2 -2
  4. package/3rdparty/autoResize/autoResize.mjs +2 -2
  5. package/3rdparty/walkontable/src/calculator/viewportColumns.js +108 -85
  6. package/3rdparty/walkontable/src/calculator/viewportColumns.mjs +108 -85
  7. package/3rdparty/walkontable/src/calculator/viewportRows.js +60 -52
  8. package/3rdparty/walkontable/src/calculator/viewportRows.mjs +60 -52
  9. package/3rdparty/walkontable/src/core/clone.js +6 -0
  10. package/3rdparty/walkontable/src/core/clone.mjs +6 -0
  11. package/3rdparty/walkontable/src/event.js +125 -74
  12. package/3rdparty/walkontable/src/event.mjs +125 -74
  13. package/3rdparty/walkontable/src/filter/column.js +16 -0
  14. package/3rdparty/walkontable/src/filter/column.mjs +16 -0
  15. package/3rdparty/walkontable/src/filter/row.js +16 -0
  16. package/3rdparty/walkontable/src/filter/row.mjs +16 -0
  17. package/3rdparty/walkontable/src/overlay/bottom.js +1 -1
  18. package/3rdparty/walkontable/src/overlay/bottom.mjs +1 -1
  19. package/3rdparty/walkontable/src/overlay/top.js +1 -1
  20. package/3rdparty/walkontable/src/overlay/top.mjs +1 -1
  21. package/3rdparty/walkontable/src/renderer/_base.js +12 -5
  22. package/3rdparty/walkontable/src/renderer/_base.mjs +12 -5
  23. package/3rdparty/walkontable/src/renderer/cells.js +6 -2
  24. package/3rdparty/walkontable/src/renderer/cells.mjs +6 -2
  25. package/3rdparty/walkontable/src/renderer/rowHeaders.js +6 -2
  26. package/3rdparty/walkontable/src/renderer/rowHeaders.mjs +6 -2
  27. package/3rdparty/walkontable/src/renderer/rows.js +5 -0
  28. package/3rdparty/walkontable/src/renderer/rows.mjs +5 -0
  29. package/3rdparty/walkontable/src/renderer/table.js +24 -17
  30. package/3rdparty/walkontable/src/renderer/table.mjs +24 -17
  31. package/3rdparty/walkontable/src/scroll.js +2 -2
  32. package/3rdparty/walkontable/src/scroll.mjs +2 -2
  33. package/3rdparty/walkontable/src/selection/border/border.js +1 -1
  34. package/3rdparty/walkontable/src/selection/border/border.mjs +1 -1
  35. package/3rdparty/walkontable/src/settings.js +10 -10
  36. package/3rdparty/walkontable/src/settings.mjs +10 -10
  37. package/3rdparty/walkontable/src/table.js +3 -3
  38. package/3rdparty/walkontable/src/table.mjs +3 -3
  39. package/3rdparty/walkontable/src/utils/column.js +19 -4
  40. package/3rdparty/walkontable/src/utils/column.mjs +19 -4
  41. package/3rdparty/walkontable/src/utils/nodesPool.js +5 -0
  42. package/3rdparty/walkontable/src/utils/nodesPool.mjs +5 -0
  43. package/3rdparty/walkontable/src/utils/orderView/view.js +13 -6
  44. package/3rdparty/walkontable/src/utils/orderView/view.mjs +13 -6
  45. package/3rdparty/walkontable/src/utils/orderView/viewSize.js +9 -6
  46. package/3rdparty/walkontable/src/utils/orderView/viewSize.mjs +9 -6
  47. package/3rdparty/walkontable/src/utils/orderView/viewSizeSet.js +7 -4
  48. package/3rdparty/walkontable/src/utils/orderView/viewSizeSet.mjs +7 -4
  49. package/3rdparty/walkontable/src/utils/row.js +14 -2
  50. package/3rdparty/walkontable/src/utils/row.mjs +14 -2
  51. package/3rdparty/walkontable/src/viewport.js +9 -9
  52. package/3rdparty/walkontable/src/viewport.mjs +9 -9
  53. package/base.js +2 -2
  54. package/base.mjs +2 -2
  55. package/core.js +31 -26
  56. package/core.mjs +31 -26
  57. package/dataMap/dataMap.js +99 -90
  58. package/dataMap/dataMap.mjs +99 -90
  59. package/dataMap/dataSource.js +14 -8
  60. package/dataMap/dataSource.mjs +14 -8
  61. package/dataMap/metaManager/lazyFactoryMap.js +19 -7
  62. package/dataMap/metaManager/lazyFactoryMap.mjs +19 -7
  63. package/dataMap/metaManager/metaLayers/cellMeta.js +8 -3
  64. package/dataMap/metaManager/metaLayers/cellMeta.mjs +8 -3
  65. package/dataMap/metaManager/metaLayers/columnMeta.js +7 -1
  66. package/dataMap/metaManager/metaLayers/columnMeta.mjs +7 -1
  67. package/dataMap/metaManager/metaLayers/globalMeta.js +6 -1
  68. package/dataMap/metaManager/metaLayers/globalMeta.mjs +6 -1
  69. package/dataMap/metaManager/metaLayers/tableMeta.js +6 -2
  70. package/dataMap/metaManager/metaLayers/tableMeta.mjs +6 -2
  71. package/dataMap/metaManager/metaSchema.js +55 -55
  72. package/dataMap/metaManager/metaSchema.mjs +55 -55
  73. package/dataMap/metaManager/mods/dynamicCellMeta.js +7 -2
  74. package/dataMap/metaManager/mods/dynamicCellMeta.mjs +7 -2
  75. package/dataMap/metaManager/mods/extendMetaProperties.js +8 -4
  76. package/dataMap/metaManager/mods/extendMetaProperties.mjs +8 -4
  77. package/dataMap/metaManager/utils.js +2 -2
  78. package/dataMap/metaManager/utils.mjs +2 -2
  79. package/dist/handsontable.css +2 -2
  80. package/dist/handsontable.full.css +2 -2
  81. package/dist/handsontable.full.js +7251 -6352
  82. package/dist/handsontable.full.min.css +2 -2
  83. package/dist/handsontable.full.min.js +120 -120
  84. package/dist/handsontable.js +7250 -6351
  85. package/dist/handsontable.min.css +2 -2
  86. package/dist/handsontable.min.js +28 -28
  87. package/editorManager.js +105 -95
  88. package/editorManager.mjs +105 -95
  89. package/editors/autocompleteEditor/autocompleteEditor.js +47 -46
  90. package/editors/autocompleteEditor/autocompleteEditor.mjs +46 -45
  91. package/editors/baseEditor/baseEditor.js +23 -26
  92. package/editors/baseEditor/baseEditor.mjs +23 -26
  93. package/editors/dateEditor/dateEditor.js +24 -15
  94. package/editors/dateEditor/dateEditor.mjs +24 -15
  95. package/editors/dropdownEditor/dropdownEditor.js +1 -1
  96. package/editors/dropdownEditor/dropdownEditor.mjs +1 -1
  97. package/editors/handsontableEditor/handsontableEditor.js +4 -4
  98. package/editors/handsontableEditor/handsontableEditor.mjs +4 -4
  99. package/editors/textEditor/textEditor.js +23 -17
  100. package/editors/textEditor/textEditor.mjs +24 -18
  101. package/eventManager.js +8 -0
  102. package/eventManager.mjs +8 -0
  103. package/helpers/array.js +2 -2
  104. package/helpers/array.mjs +2 -2
  105. package/helpers/dom/element.js +7 -7
  106. package/helpers/dom/element.mjs +7 -7
  107. package/helpers/function.js +1 -1
  108. package/helpers/function.mjs +1 -1
  109. package/helpers/mixed.js +1 -1
  110. package/helpers/mixed.mjs +1 -1
  111. package/helpers/object.js +4 -4
  112. package/helpers/object.mjs +4 -4
  113. package/helpers/string.js +1 -1
  114. package/helpers/string.mjs +1 -1
  115. package/package.json +1 -1
  116. package/pluginHooks.js +12 -3
  117. package/pluginHooks.mjs +12 -3
  118. package/plugins/autoColumnSize/autoColumnSize.js +141 -130
  119. package/plugins/autoColumnSize/autoColumnSize.mjs +140 -129
  120. package/plugins/autoRowSize/autoRowSize.js +112 -125
  121. package/plugins/autoRowSize/autoRowSize.mjs +110 -123
  122. package/plugins/autofill/autofill.js +97 -102
  123. package/plugins/autofill/autofill.mjs +96 -101
  124. package/plugins/base/base.js +57 -22
  125. package/plugins/base/base.mjs +56 -22
  126. package/plugins/bindRowsWithHeaders/bindRowsWithHeaders.js +29 -24
  127. package/plugins/bindRowsWithHeaders/bindRowsWithHeaders.mjs +28 -23
  128. package/plugins/collapsibleColumns/collapsibleColumns.js +104 -107
  129. package/plugins/collapsibleColumns/collapsibleColumns.mjs +102 -104
  130. package/plugins/columnSorting/columnSorting.js +105 -98
  131. package/plugins/columnSorting/columnSorting.mjs +104 -97
  132. package/plugins/columnSorting/columnStatesManager.js +12 -6
  133. package/plugins/columnSorting/columnStatesManager.mjs +12 -6
  134. package/plugins/columnSummary/columnSummary.js +71 -58
  135. package/plugins/columnSummary/columnSummary.mjs +70 -57
  136. package/plugins/columnSummary/endpoints.js +20 -14
  137. package/plugins/columnSummary/endpoints.mjs +20 -14
  138. package/plugins/comments/commentEditor.js +30 -2
  139. package/plugins/comments/commentEditor.mjs +30 -2
  140. package/plugins/comments/comments.js +158 -169
  141. package/plugins/comments/comments.mjs +157 -168
  142. package/plugins/comments/displaySwitch.js +7 -3
  143. package/plugins/comments/displaySwitch.mjs +7 -3
  144. package/plugins/contextMenu/commandExecutor.js +15 -2
  145. package/plugins/contextMenu/commandExecutor.mjs +15 -2
  146. package/plugins/contextMenu/contextMenu.js +91 -101
  147. package/plugins/contextMenu/contextMenu.mjs +90 -100
  148. package/plugins/contextMenu/itemsFactory.js +19 -4
  149. package/plugins/contextMenu/itemsFactory.mjs +19 -4
  150. package/plugins/contextMenu/menu/cursor.js +36 -0
  151. package/plugins/contextMenu/menu/cursor.mjs +36 -0
  152. package/plugins/contextMenu/menu/menu.js +57 -5
  153. package/plugins/contextMenu/menu/menu.mjs +57 -5
  154. package/plugins/copyPaste/copyPaste.js +74 -75
  155. package/plugins/copyPaste/copyPaste.mjs +74 -75
  156. package/plugins/customBorders/customBorders.js +49 -48
  157. package/plugins/customBorders/customBorders.mjs +48 -47
  158. package/plugins/dragToScroll/dragToScroll.js +50 -54
  159. package/plugins/dragToScroll/dragToScroll.mjs +49 -52
  160. package/plugins/dropdownMenu/dropdownMenu.js +132 -129
  161. package/plugins/dropdownMenu/dropdownMenu.mjs +132 -129
  162. package/plugins/exportFile/dataProvider.js +7 -2
  163. package/plugins/exportFile/dataProvider.mjs +7 -2
  164. package/plugins/exportFile/exportFile.js +1 -1
  165. package/plugins/exportFile/exportFile.mjs +1 -1
  166. package/plugins/exportFile/types/_base.js +14 -6
  167. package/plugins/exportFile/types/_base.mjs +14 -6
  168. package/plugins/filters/component/actionBar.js +9 -0
  169. package/plugins/filters/component/actionBar.mjs +9 -0
  170. package/plugins/filters/component/condition.js +13 -0
  171. package/plugins/filters/component/condition.mjs +13 -0
  172. package/plugins/filters/component/operators.js +9 -0
  173. package/plugins/filters/component/operators.mjs +9 -0
  174. package/plugins/filters/component/value.js +9 -0
  175. package/plugins/filters/component/value.mjs +9 -0
  176. package/plugins/filters/conditionCollection.js +9 -4
  177. package/plugins/filters/conditionCollection.mjs +9 -4
  178. package/plugins/filters/conditionUpdateObserver.js +53 -42
  179. package/plugins/filters/conditionUpdateObserver.mjs +53 -42
  180. package/plugins/filters/dataFilter.js +9 -3
  181. package/plugins/filters/dataFilter.mjs +9 -3
  182. package/plugins/filters/filters.js +184 -189
  183. package/plugins/filters/filters.mjs +182 -187
  184. package/plugins/filters/ui/_base.js +1 -1
  185. package/plugins/filters/ui/_base.mjs +1 -1
  186. package/plugins/filters/utils.js +1 -1
  187. package/plugins/filters/utils.mjs +1 -1
  188. package/plugins/formulas/engine/settings.js +1 -1
  189. package/plugins/formulas/engine/settings.mjs +1 -1
  190. package/plugins/formulas/formulas.js +684 -602
  191. package/plugins/formulas/formulas.mjs +682 -600
  192. package/plugins/hiddenColumns/hiddenColumns.js +174 -169
  193. package/plugins/hiddenColumns/hiddenColumns.mjs +173 -168
  194. package/plugins/hiddenRows/hiddenRows.js +170 -165
  195. package/plugins/hiddenRows/hiddenRows.mjs +169 -164
  196. package/plugins/manualColumnFreeze/contextMenuItem/freezeColumn.js +1 -1
  197. package/plugins/manualColumnFreeze/contextMenuItem/freezeColumn.mjs +1 -1
  198. package/plugins/manualColumnFreeze/contextMenuItem/unfreezeColumn.js +1 -1
  199. package/plugins/manualColumnFreeze/contextMenuItem/unfreezeColumn.mjs +1 -1
  200. package/plugins/manualColumnFreeze/manualColumnFreeze.js +67 -54
  201. package/plugins/manualColumnFreeze/manualColumnFreeze.mjs +64 -51
  202. package/plugins/manualColumnMove/manualColumnMove.js +287 -232
  203. package/plugins/manualColumnMove/manualColumnMove.mjs +286 -231
  204. package/plugins/manualColumnMove/ui/_base.js +9 -3
  205. package/plugins/manualColumnMove/ui/_base.mjs +9 -3
  206. package/plugins/manualColumnResize/manualColumnResize.js +291 -246
  207. package/plugins/manualColumnResize/manualColumnResize.mjs +290 -244
  208. package/plugins/manualRowMove/manualRowMove.js +223 -208
  209. package/plugins/manualRowMove/manualRowMove.mjs +222 -207
  210. package/plugins/manualRowMove/ui/_base.js +10 -5
  211. package/plugins/manualRowMove/ui/_base.mjs +10 -5
  212. package/plugins/manualRowResize/manualRowResize.js +254 -209
  213. package/plugins/manualRowResize/manualRowResize.mjs +253 -207
  214. package/plugins/mergeCells/calculations/autofill.js +9 -3
  215. package/plugins/mergeCells/calculations/autofill.mjs +9 -3
  216. package/plugins/mergeCells/calculations/selection.js +10 -4
  217. package/plugins/mergeCells/calculations/selection.mjs +10 -4
  218. package/plugins/mergeCells/cellCoords.js +16 -6
  219. package/plugins/mergeCells/cellCoords.mjs +16 -6
  220. package/plugins/mergeCells/cellsCollection.js +10 -4
  221. package/plugins/mergeCells/cellsCollection.mjs +10 -4
  222. package/plugins/mergeCells/mergeCells.js +582 -502
  223. package/plugins/mergeCells/mergeCells.mjs +580 -500
  224. package/plugins/multiColumnSorting/multiColumnSorting.js +13 -10
  225. package/plugins/multiColumnSorting/multiColumnSorting.mjs +13 -10
  226. package/plugins/multipleSelectionHandles/multipleSelectionHandles.js +16 -28
  227. package/plugins/multipleSelectionHandles/multipleSelectionHandles.mjs +16 -27
  228. package/plugins/nestedHeaders/nestedHeaders.js +542 -499
  229. package/plugins/nestedHeaders/nestedHeaders.mjs +554 -511
  230. package/plugins/nestedHeaders/stateManager/index.js +1 -1
  231. package/plugins/nestedHeaders/stateManager/index.mjs +1 -1
  232. package/plugins/nestedRows/data/dataManager.js +21 -15
  233. package/plugins/nestedRows/data/dataManager.mjs +21 -15
  234. package/plugins/nestedRows/nestedRows.js +326 -278
  235. package/plugins/nestedRows/nestedRows.mjs +325 -277
  236. package/plugins/nestedRows/ui/_base.js +7 -1
  237. package/plugins/nestedRows/ui/_base.mjs +7 -1
  238. package/plugins/nestedRows/ui/collapsing.js +2 -2
  239. package/plugins/nestedRows/ui/collapsing.mjs +2 -2
  240. package/plugins/nestedRows/ui/contextMenu.js +28 -18
  241. package/plugins/nestedRows/ui/contextMenu.mjs +28 -18
  242. package/plugins/nestedRows/utils/rowMoveController.js +12 -4
  243. package/plugins/nestedRows/utils/rowMoveController.mjs +12 -4
  244. package/plugins/persistentState/persistentState.js +14 -11
  245. package/plugins/persistentState/persistentState.mjs +14 -11
  246. package/plugins/persistentState/storage.js +11 -6
  247. package/plugins/persistentState/storage.mjs +11 -6
  248. package/plugins/registry.js +2 -2
  249. package/plugins/registry.mjs +2 -2
  250. package/plugins/search/search.js +57 -46
  251. package/plugins/search/search.mjs +56 -45
  252. package/plugins/touchScroll/touchScroll.js +102 -100
  253. package/plugins/touchScroll/touchScroll.mjs +100 -98
  254. package/plugins/trimRows/trimRows.js +33 -28
  255. package/plugins/trimRows/trimRows.mjs +32 -27
  256. package/plugins/undoRedo/undoRedo.js +2 -2
  257. package/plugins/undoRedo/undoRedo.mjs +2 -2
  258. package/renderers/autocompleteRenderer/autocompleteRenderer.js +11 -11
  259. package/renderers/autocompleteRenderer/autocompleteRenderer.mjs +11 -11
  260. package/renderers/baseRenderer/baseRenderer.js +2 -2
  261. package/renderers/baseRenderer/baseRenderer.mjs +2 -2
  262. package/renderers/checkboxRenderer/checkboxRenderer.js +23 -23
  263. package/renderers/checkboxRenderer/checkboxRenderer.mjs +23 -23
  264. package/renderers/dateRenderer/dateRenderer.js +4 -4
  265. package/renderers/dateRenderer/dateRenderer.mjs +4 -4
  266. package/renderers/handsontableRenderer/handsontableRenderer.js +4 -4
  267. package/renderers/handsontableRenderer/handsontableRenderer.mjs +4 -4
  268. package/renderers/htmlRenderer/htmlRenderer.js +4 -4
  269. package/renderers/htmlRenderer/htmlRenderer.mjs +4 -4
  270. package/renderers/numericRenderer/numericRenderer.js +3 -3
  271. package/renderers/numericRenderer/numericRenderer.mjs +3 -3
  272. package/renderers/passwordRenderer/passwordRenderer.js +3 -3
  273. package/renderers/passwordRenderer/passwordRenderer.mjs +3 -3
  274. package/renderers/selectRenderer/selectRenderer.js +4 -4
  275. package/renderers/selectRenderer/selectRenderer.mjs +4 -4
  276. package/renderers/textRenderer/textRenderer.js +5 -5
  277. package/renderers/textRenderer/textRenderer.mjs +5 -5
  278. package/renderers/timeRenderer/timeRenderer.js +3 -3
  279. package/renderers/timeRenderer/timeRenderer.mjs +3 -3
  280. package/selection/highlight/highlight.js +1 -4
  281. package/selection/highlight/highlight.mjs +1 -4
  282. package/selection/range.js +12 -2
  283. package/selection/range.mjs +12 -2
  284. package/selection/selection.js +3 -3
  285. package/selection/selection.mjs +3 -3
  286. package/tableView.js +208 -200
  287. package/tableView.mjs +208 -200
  288. package/translations/changesObservable/utils.js +2 -2
  289. package/translations/changesObservable/utils.mjs +2 -2
  290. package/translations/indexMapper.js +25 -22
  291. package/translations/indexMapper.mjs +25 -22
  292. package/translations/mapCollections/aggregatedCollection.js +8 -2
  293. package/translations/mapCollections/aggregatedCollection.mjs +8 -2
  294. package/translations/mapCollections/mapCollection.js +5 -2
  295. package/translations/mapCollections/mapCollection.mjs +5 -2
  296. package/translations/maps/indexMap.js +6 -1
  297. package/translations/maps/indexMap.mjs +6 -1
  298. package/translations/maps/utils/physicallyIndexed.js +2 -2
  299. package/translations/maps/utils/physicallyIndexed.mjs +2 -2
  300. package/utils/dataStructures/linkedList.js +10 -6
  301. package/utils/dataStructures/linkedList.mjs +10 -6
  302. package/utils/dataStructures/queue.js +1 -1
  303. package/utils/dataStructures/queue.mjs +1 -1
  304. package/utils/dataStructures/stack.js +1 -1
  305. package/utils/dataStructures/stack.mjs +1 -1
  306. package/utils/ghostTable.js +2 -2
  307. package/utils/ghostTable.mjs +2 -2
  308. package/utils/interval.js +73 -36
  309. package/utils/interval.mjs +73 -36
  310. package/utils/parseTable.js +1 -1
  311. package/utils/parseTable.mjs +1 -1
  312. package/validators/autocompleteValidator/autocompleteValidator.js +1 -1
  313. package/validators/autocompleteValidator/autocompleteValidator.mjs +1 -1
  314. package/validators/dateValidator/dateValidator.js +1 -1
  315. package/validators/dateValidator/dateValidator.mjs +1 -1
  316. package/validators/numericValidator/numericValidator.js +1 -1
  317. package/validators/numericValidator/numericValidator.mjs +1 -1
@@ -146,9 +146,55 @@ const BEFORE_INDICATOR_CLASSNAME = 'beforeHiddenRowIndicator';
146
146
  var _settings = /*#__PURE__*/new WeakMap();
147
147
  var _hiddenRowsMap = /*#__PURE__*/new WeakMap();
148
148
  var _clearIndicatorElements = /*#__PURE__*/new WeakSet();
149
+ var _onModifyRowHeight = /*#__PURE__*/new WeakSet();
150
+ var _onAfterGetCellMeta = /*#__PURE__*/new WeakSet();
151
+ var _onModifyCopyableRange = /*#__PURE__*/new WeakSet();
152
+ var _onAfterGetRowHeader = /*#__PURE__*/new WeakSet();
153
+ var _onAfterContextMenuDefaultOptions = /*#__PURE__*/new WeakSet();
154
+ var _onMapInit = /*#__PURE__*/new WeakSet();
149
155
  class HiddenRows extends _base.BasePlugin {
150
156
  constructor() {
151
157
  super(...arguments);
158
+ /**
159
+ * On map initialized hook callback.
160
+ */
161
+ _classPrivateMethodInitSpec(this, _onMapInit);
162
+ /**
163
+ * Add Show-hide rows to context menu.
164
+ *
165
+ * @param {object} options An array of objects containing information about the pre-defined Context Menu items.
166
+ */
167
+ _classPrivateMethodInitSpec(this, _onAfterContextMenuDefaultOptions);
168
+ /**
169
+ * Adds the needed classes to the headers.
170
+ *
171
+ * @param {number} row Visual row index.
172
+ * @param {HTMLElement} TH Header's TH element.
173
+ */
174
+ _classPrivateMethodInitSpec(this, _onAfterGetRowHeader);
175
+ /**
176
+ * Modifies the copyable range, accordingly to the provided config.
177
+ *
178
+ * @param {Array} ranges An array of objects defining copyable cells.
179
+ * @returns {Array}
180
+ */
181
+ _classPrivateMethodInitSpec(this, _onModifyCopyableRange);
182
+ /**
183
+ * Sets the copy-related cell meta.
184
+ *
185
+ * @param {number} row Visual row index.
186
+ * @param {number} column Visual column index.
187
+ * @param {object} cellProperties Object containing the cell properties.
188
+ */
189
+ _classPrivateMethodInitSpec(this, _onAfterGetCellMeta);
190
+ /**
191
+ * Adds the additional row height for the hidden row indicators.
192
+ *
193
+ * @param {number|undefined} height Row height.
194
+ * @param {number} row Visual row index.
195
+ * @returns {number}
196
+ */
197
+ _classPrivateMethodInitSpec(this, _onModifyRowHeight);
152
198
  /**
153
199
  * Remove the indicator elements from the provided row header element.
154
200
  *
@@ -208,17 +254,23 @@ class HiddenRows extends _base.BasePlugin {
208
254
  }
209
255
  }
210
256
  _classPrivateFieldSet(this, _hiddenRowsMap, new _translations.HidingMap());
211
- _classPrivateFieldGet(this, _hiddenRowsMap).addLocalHook('init', () => this.onMapInit());
257
+ _classPrivateFieldGet(this, _hiddenRowsMap).addLocalHook('init', () => _classPrivateMethodGet(this, _onMapInit, _onMapInit2).call(this));
212
258
  this.hot.rowIndexMapper.registerMap(this.pluginName, _classPrivateFieldGet(this, _hiddenRowsMap));
213
259
  this.addHook('afterContextMenuDefaultOptions', function () {
214
- return _this.onAfterContextMenuDefaultOptions(...arguments);
260
+ for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
261
+ args[_key] = arguments[_key];
262
+ }
263
+ return _classPrivateMethodGet(_this, _onAfterContextMenuDefaultOptions, _onAfterContextMenuDefaultOptions2).call(_this, ...args);
215
264
  });
216
- this.addHook('afterGetCellMeta', (row, col, cellProperties) => this.onAfterGetCellMeta(row, col, cellProperties));
217
- this.addHook('modifyRowHeight', (height, row) => this.onModifyRowHeight(height, row));
265
+ this.addHook('afterGetCellMeta', (row, col, cellProperties) => _classPrivateMethodGet(this, _onAfterGetCellMeta, _onAfterGetCellMeta2).call(this, row, col, cellProperties));
266
+ this.addHook('modifyRowHeight', (height, row) => _classPrivateMethodGet(this, _onModifyRowHeight, _onModifyRowHeight2).call(this, height, row));
218
267
  this.addHook('afterGetRowHeader', function () {
219
- return _this.onAfterGetRowHeader(...arguments);
268
+ for (var _len2 = arguments.length, args = new Array(_len2), _key2 = 0; _key2 < _len2; _key2++) {
269
+ args[_key2] = arguments[_key2];
270
+ }
271
+ return _classPrivateMethodGet(_this, _onAfterGetRowHeader, _onAfterGetRowHeader2).call(_this, ...args);
220
272
  });
221
- this.addHook('modifyCopyableRange', ranges => this.onModifyCopyableRange(ranges));
273
+ this.addHook('modifyCopyableRange', ranges => _classPrivateMethodGet(this, _onModifyCopyableRange, _onModifyCopyableRange2).call(this, ranges));
222
274
  super.enablePlugin();
223
275
  }
224
276
 
@@ -294,8 +346,8 @@ class HiddenRows extends _base.BasePlugin {
294
346
  * @param {...number} row Visual row index.
295
347
  */
296
348
  showRow() {
297
- for (var _len = arguments.length, row = new Array(_len), _key = 0; _key < _len; _key++) {
298
- row[_key] = arguments[_key];
349
+ for (var _len3 = arguments.length, row = new Array(_len3), _key3 = 0; _key3 < _len3; _key3++) {
350
+ row[_key3] = arguments[_key3];
299
351
  }
300
352
  this.showRows(row);
301
353
  }
@@ -332,8 +384,8 @@ class HiddenRows extends _base.BasePlugin {
332
384
  * @param {...number} row Visual row index.
333
385
  */
334
386
  hideRow() {
335
- for (var _len2 = arguments.length, row = new Array(_len2), _key2 = 0; _key2 < _len2; _key2++) {
336
- row[_key2] = arguments[_key2];
387
+ for (var _len4 = arguments.length, row = new Array(_len4), _key4 = 0; _key4 < _len4; _key4++) {
388
+ row[_key4] = arguments[_key4];
337
389
  }
338
390
  this.hideRows(row);
339
391
  }
@@ -386,173 +438,126 @@ class HiddenRows extends _base.BasePlugin {
386
438
  });
387
439
  }
388
440
  /**
389
- * Adds the additional row height for the hidden row indicators.
390
- *
391
- * @private
392
- * @param {number|undefined} height Row height.
393
- * @param {number} row Visual row index.
394
- * @returns {number}
441
+ * Destroys the plugin instance.
395
442
  */
396
- onModifyRowHeight(height, row) {
397
- // Hook is triggered internally only for the visible rows. Conditional will be handled for the API
398
- // calls of the `getRowHeight` function on not visible indexes.
399
- if (this.isHidden(row)) {
400
- return 0;
401
- }
402
- return height;
443
+ destroy() {
444
+ _classPrivateFieldSet(this, _settings, null);
445
+ _classPrivateFieldSet(this, _hiddenRowsMap, null);
446
+ super.destroy();
403
447
  }
404
-
405
- /**
406
- * Sets the copy-related cell meta.
407
- *
408
- * @private
409
- * @param {number} row Visual row index.
410
- * @param {number} column Visual column index.
411
- * @param {object} cellProperties Object containing the cell properties.
412
- */
413
- onAfterGetCellMeta(row, column, cellProperties) {
414
- if (_classPrivateFieldGet(this, _settings).copyPasteEnabled === false && this.isHidden(row)) {
415
- // Cell property handled by the `Autofill` and the `CopyPaste` plugins.
416
- cellProperties.skipRowOnPaste = true;
448
+ }
449
+ exports.HiddenRows = HiddenRows;
450
+ function _clearIndicatorElements2(TH) {
451
+ Array.from(TH.querySelectorAll(`.${AFTER_INDICATOR_CLASSNAME}, .${BEFORE_INDICATOR_CLASSNAME}`)).forEach(element => {
452
+ element.remove();
453
+ });
454
+ }
455
+ function _onModifyRowHeight2(height, row) {
456
+ // Hook is triggered internally only for the visible rows. Conditional will be handled for the API
457
+ // calls of the `getRowHeight` function on not visible indexes.
458
+ if (this.isHidden(row)) {
459
+ return 0;
460
+ }
461
+ return height;
462
+ }
463
+ function _onAfterGetCellMeta2(row, column, cellProperties) {
464
+ if (_classPrivateFieldGet(this, _settings).copyPasteEnabled === false && this.isHidden(row)) {
465
+ // Cell property handled by the `Autofill` and the `CopyPaste` plugins.
466
+ cellProperties.skipRowOnPaste = true;
467
+ }
468
+ if (this.isHidden(row - 1)) {
469
+ cellProperties.className = cellProperties.className || '';
470
+ if (cellProperties.className.indexOf('afterHiddenRow') === -1) {
471
+ cellProperties.className += ' afterHiddenRow';
417
472
  }
418
- if (this.isHidden(row - 1)) {
419
- cellProperties.className = cellProperties.className || '';
420
- if (cellProperties.className.indexOf('afterHiddenRow') === -1) {
421
- cellProperties.className += ' afterHiddenRow';
422
- }
423
- } else if (cellProperties.className) {
424
- const classArr = cellProperties.className.split(' ');
425
- if (classArr.length > 0) {
426
- const containAfterHiddenRow = classArr.indexOf('afterHiddenRow');
427
- if (containAfterHiddenRow > -1) {
428
- classArr.splice(containAfterHiddenRow, 1);
429
- }
430
- cellProperties.className = classArr.join(' ');
473
+ } else if (cellProperties.className) {
474
+ const classArr = cellProperties.className.split(' ');
475
+ if (classArr.length > 0) {
476
+ const containAfterHiddenRow = classArr.indexOf('afterHiddenRow');
477
+ if (containAfterHiddenRow > -1) {
478
+ classArr.splice(containAfterHiddenRow, 1);
431
479
  }
480
+ cellProperties.className = classArr.join(' ');
432
481
  }
433
482
  }
434
-
435
- /**
436
- * Modifies the copyable range, accordingly to the provided config.
437
- *
438
- * @private
439
- * @param {Array} ranges An array of objects defining copyable cells.
440
- * @returns {Array}
441
- */
442
- onModifyCopyableRange(ranges) {
443
- // Ranges shouldn't be modified when `copyPasteEnabled` option is set to `true` (by default).
444
- if (_classPrivateFieldGet(this, _settings).copyPasteEnabled) {
445
- return ranges;
446
- }
447
- const newRanges = [];
448
- const pushRange = (startRow, endRow, startCol, endCol) => {
449
- newRanges.push({
450
- startRow,
451
- endRow,
452
- startCol,
453
- endCol
454
- });
455
- };
456
- (0, _array.arrayEach)(ranges, range => {
457
- let isHidden = true;
458
- let rangeStart = 0;
459
- (0, _number.rangeEach)(range.startRow, range.endRow, visualRow => {
460
- if (this.isHidden(visualRow)) {
461
- if (!isHidden) {
462
- pushRange(rangeStart, visualRow - 1, range.startCol, range.endCol);
463
- }
464
- isHidden = true;
465
- } else {
466
- if (isHidden) {
467
- rangeStart = visualRow;
468
- }
469
- if (visualRow === range.endRow) {
470
- pushRange(rangeStart, visualRow, range.startCol, range.endCol);
471
- }
472
- isHidden = false;
483
+ }
484
+ function _onModifyCopyableRange2(ranges) {
485
+ // Ranges shouldn't be modified when `copyPasteEnabled` option is set to `true` (by default).
486
+ if (_classPrivateFieldGet(this, _settings).copyPasteEnabled) {
487
+ return ranges;
488
+ }
489
+ const newRanges = [];
490
+ const pushRange = (startRow, endRow, startCol, endCol) => {
491
+ newRanges.push({
492
+ startRow,
493
+ endRow,
494
+ startCol,
495
+ endCol
496
+ });
497
+ };
498
+ (0, _array.arrayEach)(ranges, range => {
499
+ let isHidden = true;
500
+ let rangeStart = 0;
501
+ (0, _number.rangeEach)(range.startRow, range.endRow, visualRow => {
502
+ if (this.isHidden(visualRow)) {
503
+ if (!isHidden) {
504
+ pushRange(rangeStart, visualRow - 1, range.startCol, range.endCol);
473
505
  }
474
- });
506
+ isHidden = true;
507
+ } else {
508
+ if (isHidden) {
509
+ rangeStart = visualRow;
510
+ }
511
+ if (visualRow === range.endRow) {
512
+ pushRange(rangeStart, visualRow, range.startCol, range.endCol);
513
+ }
514
+ isHidden = false;
515
+ }
475
516
  });
476
- return newRanges;
517
+ });
518
+ return newRanges;
519
+ }
520
+ function _onAfterGetRowHeader2(row, TH) {
521
+ const areAriaTagsEnabled = this.hot.getSettings().ariaTags;
522
+ const beforeHiddenRowIndicatorElement = TH.querySelector('.beforeHiddenRowIndicator');
523
+ const afterHiddenRowIndicatorElement = TH.querySelector('.afterHiddenRowIndicator');
524
+ if (!_classPrivateFieldGet(this, _settings).indicators || row < 0) {
525
+ beforeHiddenRowIndicatorElement === null || beforeHiddenRowIndicatorElement === void 0 || beforeHiddenRowIndicatorElement.remove();
526
+ afterHiddenRowIndicatorElement === null || afterHiddenRowIndicatorElement === void 0 || afterHiddenRowIndicatorElement.remove();
527
+ return;
477
528
  }
478
-
479
- /**
480
- * Adds the needed classes to the headers.
481
- *
482
- * @private
483
- * @param {number} row Visual row index.
484
- * @param {HTMLElement} TH Header's TH element.
485
- */
486
- onAfterGetRowHeader(row, TH) {
487
- const areAriaTagsEnabled = this.hot.getSettings().ariaTags;
488
- const beforeHiddenRowIndicatorElement = TH.querySelector('.beforeHiddenRowIndicator');
489
- const afterHiddenRowIndicatorElement = TH.querySelector('.afterHiddenRowIndicator');
490
- if (!_classPrivateFieldGet(this, _settings).indicators || row < 0) {
491
- beforeHiddenRowIndicatorElement === null || beforeHiddenRowIndicatorElement === void 0 || beforeHiddenRowIndicatorElement.remove();
492
- afterHiddenRowIndicatorElement === null || afterHiddenRowIndicatorElement === void 0 || afterHiddenRowIndicatorElement.remove();
493
- return;
494
- }
495
- const classList = [];
496
- if (row >= 1 && this.isHidden(row - 1)) {
497
- if (!afterHiddenRowIndicatorElement) {
498
- const attributesToAdd = areAriaTagsEnabled ? [(0, _a11y.A11Y_LABEL)(this.hot.getTranslatedPhrase(_constants.ROW_HEADER_LABEL_AFTER_HIDDEN_ROW))] : [];
499
- (0, _element.appendElement)(TH, {
500
- tagName: 'div',
501
- attributes: attributesToAdd,
502
- className: AFTER_INDICATOR_CLASSNAME
503
- });
504
- }
505
- classList.push('afterHiddenRow');
506
- }
507
- if (row < this.hot.countRows() - 1 && this.isHidden(row + 1)) {
508
- if (!beforeHiddenRowIndicatorElement) {
509
- const attributesToAdd = areAriaTagsEnabled ? [(0, _a11y.A11Y_LABEL)(this.hot.getTranslatedPhrase(_constants.ROW_HEADER_LABEL_BEFORE_HIDDEN_ROW))] : [];
510
- (0, _element.appendElement)(TH, {
511
- tagName: 'div',
512
- attributes: attributesToAdd,
513
- className: BEFORE_INDICATOR_CLASSNAME
514
- });
515
- }
516
- classList.push('beforeHiddenRow');
529
+ const classList = [];
530
+ if (row >= 1 && this.isHidden(row - 1)) {
531
+ if (!afterHiddenRowIndicatorElement) {
532
+ const attributesToAdd = areAriaTagsEnabled ? [(0, _a11y.A11Y_LABEL)(this.hot.getTranslatedPhrase(_constants.ROW_HEADER_LABEL_AFTER_HIDDEN_ROW))] : [];
533
+ (0, _element.appendElement)(TH, {
534
+ tagName: 'div',
535
+ attributes: attributesToAdd,
536
+ className: AFTER_INDICATOR_CLASSNAME
537
+ });
517
538
  }
518
- (0, _element.addClass)(TH, classList);
539
+ classList.push('afterHiddenRow');
519
540
  }
520
-
521
- /**
522
- * Add Show-hide rows to context menu.
523
- *
524
- * @private
525
- * @param {object} options An array of objects containing information about the pre-defined Context Menu items.
526
- */
527
- onAfterContextMenuDefaultOptions(options) {
528
- options.items.push({
529
- name: _predefinedItems.SEPARATOR
530
- }, (0, _hideRow.default)(this), (0, _showRow.default)(this));
531
- }
532
-
533
- /**
534
- * On map initialized hook callback.
535
- *
536
- * @private
537
- */
538
- onMapInit() {
539
- if (Array.isArray(_classPrivateFieldGet(this, _settings).rows)) {
540
- this.hideRows(_classPrivateFieldGet(this, _settings).rows);
541
+ if (row < this.hot.countRows() - 1 && this.isHidden(row + 1)) {
542
+ if (!beforeHiddenRowIndicatorElement) {
543
+ const attributesToAdd = areAriaTagsEnabled ? [(0, _a11y.A11Y_LABEL)(this.hot.getTranslatedPhrase(_constants.ROW_HEADER_LABEL_BEFORE_HIDDEN_ROW))] : [];
544
+ (0, _element.appendElement)(TH, {
545
+ tagName: 'div',
546
+ attributes: attributesToAdd,
547
+ className: BEFORE_INDICATOR_CLASSNAME
548
+ });
541
549
  }
550
+ classList.push('beforeHiddenRow');
542
551
  }
543
-
544
- /**
545
- * Destroys the plugin instance.
546
- */
547
- destroy() {
548
- _classPrivateFieldSet(this, _settings, null);
549
- _classPrivateFieldSet(this, _hiddenRowsMap, null);
550
- super.destroy();
551
- }
552
+ (0, _element.addClass)(TH, classList);
552
553
  }
553
- exports.HiddenRows = HiddenRows;
554
- function _clearIndicatorElements2(TH) {
555
- Array.from(TH.querySelectorAll(`.${AFTER_INDICATOR_CLASSNAME}, .${BEFORE_INDICATOR_CLASSNAME}`)).forEach(element => {
556
- element.remove();
557
- });
554
+ function _onAfterContextMenuDefaultOptions2(options) {
555
+ options.items.push({
556
+ name: _predefinedItems.SEPARATOR
557
+ }, (0, _hideRow.default)(this), (0, _showRow.default)(this));
558
+ }
559
+ function _onMapInit2() {
560
+ if (Array.isArray(_classPrivateFieldGet(this, _settings).rows)) {
561
+ this.hideRows(_classPrivateFieldGet(this, _settings).rows);
562
+ }
558
563
  }