handsontable 0.0.0-next-bfb0e3a-20240403 → 0.0.0-next-5a535ed-20240403

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 (280) hide show
  1. package/3rdparty/walkontable/src/calculator/viewportColumns.js +17 -12
  2. package/3rdparty/walkontable/src/calculator/viewportColumns.mjs +17 -12
  3. package/3rdparty/walkontable/src/calculator/viewportRows.js +15 -10
  4. package/3rdparty/walkontable/src/calculator/viewportRows.mjs +15 -10
  5. package/3rdparty/walkontable/src/cell/coords.js +17 -12
  6. package/3rdparty/walkontable/src/cell/coords.mjs +17 -12
  7. package/3rdparty/walkontable/src/cell/range.d.ts +1 -2
  8. package/3rdparty/walkontable/src/cell/range.js +28 -40
  9. package/3rdparty/walkontable/src/cell/range.mjs +28 -40
  10. package/3rdparty/walkontable/src/core/_base.js +1 -1
  11. package/3rdparty/walkontable/src/core/_base.mjs +1 -1
  12. package/3rdparty/walkontable/src/event.js +104 -72
  13. package/3rdparty/walkontable/src/event.mjs +104 -72
  14. package/3rdparty/walkontable/src/overlays.js +1 -1
  15. package/3rdparty/walkontable/src/overlays.mjs +1 -1
  16. package/3rdparty/walkontable/src/scroll.js +17 -15
  17. package/3rdparty/walkontable/src/scroll.mjs +17 -15
  18. package/3rdparty/walkontable/src/selection/manager.js +69 -48
  19. package/3rdparty/walkontable/src/selection/manager.mjs +69 -48
  20. package/3rdparty/walkontable/src/selection/scanner.js +42 -33
  21. package/3rdparty/walkontable/src/selection/scanner.mjs +42 -33
  22. package/3rdparty/walkontable/src/utils/columnStretching.js +44 -27
  23. package/3rdparty/walkontable/src/utils/columnStretching.mjs +44 -27
  24. package/3rdparty/walkontable/src/utils/orderView/view.js +1 -1
  25. package/3rdparty/walkontable/src/utils/orderView/view.mjs +1 -1
  26. package/base.js +2 -2
  27. package/base.mjs +2 -2
  28. package/core/viewportScroll/index.js +1 -4
  29. package/core/viewportScroll/index.mjs +1 -4
  30. package/core.d.ts +3 -4
  31. package/core.js +22 -77
  32. package/core.mjs +22 -77
  33. package/dataMap/dataSource.js +1 -1
  34. package/dataMap/dataSource.mjs +1 -1
  35. package/dataMap/metaManager/metaLayers/cellMeta.js +1 -1
  36. package/dataMap/metaManager/metaLayers/cellMeta.mjs +1 -1
  37. package/dataMap/metaManager/metaSchema.js +1 -1
  38. package/dataMap/metaManager/metaSchema.mjs +1 -1
  39. package/dataMap/replaceData.js +1 -1
  40. package/dataMap/replaceData.mjs +1 -1
  41. package/dist/handsontable.css +4 -4
  42. package/dist/handsontable.full.css +4 -4
  43. package/dist/handsontable.full.js +9117 -8969
  44. package/dist/handsontable.full.min.css +3 -3
  45. package/dist/handsontable.full.min.js +292 -292
  46. package/dist/handsontable.js +6569 -6874
  47. package/dist/handsontable.min.css +3 -3
  48. package/dist/handsontable.min.js +25 -25
  49. package/dist/languages/all.min.js +1 -1
  50. package/dist/languages/ar-AR.min.js +1 -1
  51. package/dist/languages/cs-CZ.min.js +1 -1
  52. package/dist/languages/de-CH.min.js +1 -1
  53. package/dist/languages/de-DE.min.js +1 -1
  54. package/dist/languages/en-US.min.js +1 -1
  55. package/dist/languages/es-MX.min.js +1 -1
  56. package/dist/languages/fr-FR.min.js +1 -1
  57. package/dist/languages/hr-HR.min.js +1 -1
  58. package/dist/languages/it-IT.min.js +1 -1
  59. package/dist/languages/ja-JP.min.js +1 -1
  60. package/dist/languages/ko-KR.min.js +1 -1
  61. package/dist/languages/lv-LV.min.js +1 -1
  62. package/dist/languages/nb-NO.min.js +1 -1
  63. package/dist/languages/nl-NL.min.js +1 -1
  64. package/dist/languages/pl-PL.min.js +1 -1
  65. package/dist/languages/pt-BR.min.js +1 -1
  66. package/dist/languages/ru-RU.min.js +1 -1
  67. package/dist/languages/sr-SP.min.js +1 -1
  68. package/dist/languages/zh-CN.min.js +1 -1
  69. package/dist/languages/zh-TW.min.js +1 -1
  70. package/editorManager.js +23 -25
  71. package/editorManager.mjs +23 -25
  72. package/editors/autocompleteEditor/autocompleteEditor.js +10 -6
  73. package/editors/autocompleteEditor/autocompleteEditor.mjs +10 -6
  74. package/editors/selectEditor/selectEditor.js +19 -20
  75. package/editors/selectEditor/selectEditor.mjs +19 -20
  76. package/eventManager.js +1 -1
  77. package/eventManager.mjs +1 -1
  78. package/focusManager.js +82 -64
  79. package/focusManager.mjs +82 -64
  80. package/helpers/dom/element.js +1 -1
  81. package/helpers/dom/element.mjs +1 -1
  82. package/helpers/mixed.js +1 -1
  83. package/helpers/mixed.mjs +1 -1
  84. package/helpers/object.js +2 -2
  85. package/helpers/object.mjs +2 -2
  86. package/index.d.ts +0 -10
  87. package/package.json +2 -7
  88. package/pluginHooks.d.ts +3 -4
  89. package/pluginHooks.js +38 -99
  90. package/pluginHooks.mjs +38 -99
  91. package/plugins/autoColumnSize/autoColumnSize.js +65 -49
  92. package/plugins/autoColumnSize/autoColumnSize.mjs +65 -49
  93. package/plugins/autoRowSize/autoRowSize.js +34 -28
  94. package/plugins/autoRowSize/autoRowSize.mjs +34 -28
  95. package/plugins/autofill/autofill.js +38 -30
  96. package/plugins/autofill/autofill.mjs +38 -30
  97. package/plugins/base/base.js +17 -12
  98. package/plugins/base/base.mjs +17 -12
  99. package/plugins/bindRowsWithHeaders/bindRowsWithHeaders.js +5 -5
  100. package/plugins/bindRowsWithHeaders/bindRowsWithHeaders.mjs +5 -5
  101. package/plugins/collapsibleColumns/collapsibleColumns.js +50 -59
  102. package/plugins/collapsibleColumns/collapsibleColumns.mjs +50 -59
  103. package/plugins/columnSorting/columnSorting.js +45 -49
  104. package/plugins/columnSorting/columnSorting.mjs +45 -49
  105. package/plugins/columnSummary/columnSummary.js +26 -22
  106. package/plugins/columnSummary/columnSummary.mjs +26 -22
  107. package/plugins/comments/comments.js +158 -116
  108. package/plugins/comments/comments.mjs +158 -116
  109. package/plugins/contextMenu/contextMenu.js +26 -20
  110. package/plugins/contextMenu/contextMenu.mjs +26 -20
  111. package/plugins/contextMenu/itemsFactory.js +1 -1
  112. package/plugins/contextMenu/itemsFactory.mjs +1 -1
  113. package/plugins/contextMenu/menu/defaultShortcutsList.js +10 -26
  114. package/plugins/contextMenu/menu/defaultShortcutsList.mjs +10 -26
  115. package/plugins/contextMenu/menu/menu.js +21 -13
  116. package/plugins/contextMenu/menu/menu.mjs +21 -13
  117. package/plugins/contextMenu/menu/positioner.js +58 -41
  118. package/plugins/contextMenu/menu/positioner.mjs +58 -41
  119. package/plugins/copyPaste/copyPaste.js +157 -116
  120. package/plugins/copyPaste/copyPaste.mjs +157 -116
  121. package/plugins/copyPaste/copyableRanges.js +66 -43
  122. package/plugins/copyPaste/copyableRanges.mjs +66 -43
  123. package/plugins/customBorders/customBorders.js +13 -11
  124. package/plugins/customBorders/customBorders.mjs +13 -11
  125. package/plugins/dragToScroll/dragToScroll.js +6 -6
  126. package/plugins/dragToScroll/dragToScroll.mjs +6 -6
  127. package/plugins/dropdownMenu/dropdownMenu.js +106 -80
  128. package/plugins/dropdownMenu/dropdownMenu.mjs +106 -80
  129. package/plugins/exportFile/dataProvider.js +1 -1
  130. package/plugins/exportFile/dataProvider.mjs +1 -1
  131. package/plugins/filters/component/actionBar.js +9 -9
  132. package/plugins/filters/component/actionBar.mjs +8 -8
  133. package/plugins/filters/component/condition.js +15 -13
  134. package/plugins/filters/component/condition.mjs +15 -13
  135. package/plugins/filters/component/operators.js +6 -6
  136. package/plugins/filters/component/operators.mjs +6 -6
  137. package/plugins/filters/component/value.js +28 -24
  138. package/plugins/filters/component/value.mjs +28 -24
  139. package/plugins/filters/conditionUpdateObserver.js +24 -22
  140. package/plugins/filters/conditionUpdateObserver.mjs +24 -22
  141. package/plugins/filters/dataFilter.js +1 -1
  142. package/plugins/filters/dataFilter.mjs +1 -1
  143. package/plugins/filters/filters.js +95 -81
  144. package/plugins/filters/filters.mjs +95 -81
  145. package/plugins/filters/ui/input.js +19 -13
  146. package/plugins/filters/ui/input.mjs +19 -13
  147. package/plugins/filters/ui/link.js +13 -8
  148. package/plugins/filters/ui/link.mjs +13 -8
  149. package/plugins/filters/ui/multipleSelect.js +112 -85
  150. package/plugins/filters/ui/multipleSelect.mjs +112 -85
  151. package/plugins/filters/ui/radioInput.js +20 -12
  152. package/plugins/filters/ui/radioInput.mjs +20 -12
  153. package/plugins/filters/ui/select.js +72 -50
  154. package/plugins/filters/ui/select.mjs +71 -49
  155. package/plugins/formulas/formulas.js +326 -268
  156. package/plugins/formulas/formulas.mjs +327 -269
  157. package/plugins/formulas/indexSyncer/axisSyncer.js +61 -38
  158. package/plugins/formulas/indexSyncer/axisSyncer.mjs +61 -38
  159. package/plugins/formulas/indexSyncer/index.js +48 -25
  160. package/plugins/formulas/indexSyncer/index.mjs +48 -25
  161. package/plugins/hiddenColumns/hiddenColumns.js +83 -64
  162. package/plugins/hiddenColumns/hiddenColumns.mjs +83 -64
  163. package/plugins/hiddenRows/hiddenRows.js +82 -63
  164. package/plugins/hiddenRows/hiddenRows.mjs +82 -63
  165. package/plugins/manualColumnFreeze/manualColumnFreeze.js +32 -24
  166. package/plugins/manualColumnFreeze/manualColumnFreeze.mjs +33 -25
  167. package/plugins/manualColumnMove/manualColumnMove.js +170 -126
  168. package/plugins/manualColumnMove/manualColumnMove.mjs +170 -126
  169. package/plugins/manualColumnResize/manualColumnResize.js +230 -169
  170. package/plugins/manualColumnResize/manualColumnResize.mjs +230 -169
  171. package/plugins/manualRowMove/manualRowMove.js +128 -99
  172. package/plugins/manualRowMove/manualRowMove.mjs +128 -99
  173. package/plugins/manualRowResize/manualRowResize.js +209 -150
  174. package/plugins/manualRowResize/manualRowResize.mjs +209 -150
  175. package/plugins/mergeCells/calculations/selection.js +71 -2
  176. package/plugins/mergeCells/calculations/selection.mjs +71 -2
  177. package/plugins/mergeCells/cellsCollection.js +1 -117
  178. package/plugins/mergeCells/cellsCollection.mjs +1 -117
  179. package/plugins/mergeCells/contextMenuItem/toggleMerge.js +1 -11
  180. package/plugins/mergeCells/contextMenuItem/toggleMerge.mjs +1 -11
  181. package/plugins/mergeCells/mergeCells.js +397 -499
  182. package/plugins/mergeCells/mergeCells.mjs +397 -499
  183. package/plugins/multiColumnSorting/multiColumnSorting.js +2 -8
  184. package/plugins/multiColumnSorting/multiColumnSorting.mjs +2 -8
  185. package/plugins/multipleSelectionHandles/multipleSelectionHandles.js +1 -1
  186. package/plugins/multipleSelectionHandles/multipleSelectionHandles.mjs +1 -1
  187. package/plugins/nestedHeaders/nestedHeaders.js +253 -205
  188. package/plugins/nestedHeaders/nestedHeaders.mjs +254 -206
  189. package/plugins/nestedHeaders/stateManager/headersTree.js +32 -21
  190. package/plugins/nestedHeaders/stateManager/headersTree.mjs +32 -21
  191. package/plugins/nestedHeaders/stateManager/index.js +41 -30
  192. package/plugins/nestedHeaders/stateManager/index.mjs +41 -30
  193. package/plugins/nestedHeaders/stateManager/sourceSettings.js +30 -19
  194. package/plugins/nestedHeaders/stateManager/sourceSettings.mjs +30 -19
  195. package/plugins/nestedRows/data/dataManager.js +1 -1
  196. package/plugins/nestedRows/data/dataManager.mjs +1 -1
  197. package/plugins/nestedRows/nestedRows.js +182 -151
  198. package/plugins/nestedRows/nestedRows.mjs +183 -152
  199. package/plugins/nestedRows/ui/contextMenu.js +15 -11
  200. package/plugins/nestedRows/ui/contextMenu.mjs +14 -10
  201. package/plugins/nestedRows/utils/rowMoveController.js +1 -1
  202. package/plugins/nestedRows/utils/rowMoveController.mjs +1 -1
  203. package/plugins/persistentState/storage.js +2 -2
  204. package/plugins/persistentState/storage.mjs +2 -2
  205. package/plugins/search/search.js +7 -7
  206. package/plugins/search/search.mjs +7 -7
  207. package/plugins/touchScroll/touchScroll.js +19 -15
  208. package/plugins/touchScroll/touchScroll.mjs +20 -16
  209. package/plugins/trimRows/trimRows.js +6 -6
  210. package/plugins/trimRows/trimRows.mjs +6 -6
  211. package/renderers/checkboxRenderer/checkboxRenderer.js +5 -8
  212. package/renderers/checkboxRenderer/checkboxRenderer.mjs +5 -8
  213. package/selection/highlight/highlight.js +14 -14
  214. package/selection/highlight/highlight.mjs +13 -13
  215. package/selection/highlight/visualSelection.js +0 -2
  216. package/selection/highlight/visualSelection.mjs +0 -2
  217. package/selection/selection.js +67 -225
  218. package/selection/selection.mjs +66 -224
  219. package/selection/transformation.js +118 -149
  220. package/selection/transformation.mjs +118 -149
  221. package/shortcutContexts/commands/editor/closeAndSave.js +2 -2
  222. package/shortcutContexts/commands/editor/closeAndSave.mjs +2 -2
  223. package/shortcutContexts/commands/editor/open.js +3 -18
  224. package/shortcutContexts/commands/editor/open.mjs +3 -18
  225. package/shortcutContexts/commands/extendCellsSelection/down.js +1 -1
  226. package/shortcutContexts/commands/extendCellsSelection/down.mjs +1 -1
  227. package/shortcutContexts/commands/extendCellsSelection/left.js +1 -1
  228. package/shortcutContexts/commands/extendCellsSelection/left.mjs +1 -1
  229. package/shortcutContexts/commands/extendCellsSelection/right.js +1 -1
  230. package/shortcutContexts/commands/extendCellsSelection/right.mjs +1 -1
  231. package/shortcutContexts/commands/extendCellsSelection/toColumns.js +1 -1
  232. package/shortcutContexts/commands/extendCellsSelection/toColumns.mjs +1 -1
  233. package/shortcutContexts/commands/extendCellsSelection/toMostBottom.js +1 -3
  234. package/shortcutContexts/commands/extendCellsSelection/toMostBottom.mjs +1 -3
  235. package/shortcutContexts/commands/extendCellsSelection/toMostInlineEnd.js +3 -9
  236. package/shortcutContexts/commands/extendCellsSelection/toMostInlineEnd.mjs +3 -9
  237. package/shortcutContexts/commands/extendCellsSelection/toMostInlineStart.js +3 -10
  238. package/shortcutContexts/commands/extendCellsSelection/toMostInlineStart.mjs +3 -10
  239. package/shortcutContexts/commands/extendCellsSelection/toMostLeft.js +1 -3
  240. package/shortcutContexts/commands/extendCellsSelection/toMostLeft.mjs +1 -3
  241. package/shortcutContexts/commands/extendCellsSelection/toMostRight.js +1 -3
  242. package/shortcutContexts/commands/extendCellsSelection/toMostRight.mjs +1 -3
  243. package/shortcutContexts/commands/extendCellsSelection/toMostTop.js +1 -3
  244. package/shortcutContexts/commands/extendCellsSelection/toMostTop.mjs +1 -3
  245. package/shortcutContexts/commands/extendCellsSelection/toRows.js +1 -1
  246. package/shortcutContexts/commands/extendCellsSelection/toRows.mjs +1 -1
  247. package/shortcutContexts/commands/extendCellsSelection/up.js +1 -1
  248. package/shortcutContexts/commands/extendCellsSelection/up.mjs +1 -1
  249. package/shortcutContexts/commands/moveCellSelection/inlineEnd.js +1 -6
  250. package/shortcutContexts/commands/moveCellSelection/inlineEnd.mjs +1 -6
  251. package/shortcutContexts/commands/moveCellSelection/inlineStart.js +1 -6
  252. package/shortcutContexts/commands/moveCellSelection/inlineStart.mjs +1 -6
  253. package/shortcutContexts/grid.js +3 -9
  254. package/shortcutContexts/grid.mjs +3 -9
  255. package/shortcuts/context.js +1 -2
  256. package/shortcuts/context.mjs +1 -2
  257. package/tableView.js +78 -52
  258. package/tableView.mjs +78 -52
  259. package/translations/changesObservable/observable.js +38 -21
  260. package/translations/changesObservable/observable.mjs +38 -21
  261. package/translations/changesObservable/observer.js +12 -7
  262. package/translations/changesObservable/observer.mjs +11 -6
  263. package/translations/mapCollections/aggregatedCollection.js +1 -1
  264. package/translations/mapCollections/aggregatedCollection.mjs +1 -1
  265. package/translations/maps/indexMap.js +1 -1
  266. package/translations/maps/indexMap.mjs +1 -1
  267. package/utils/dataStructures/linkedList.js +1 -6
  268. package/utils/dataStructures/linkedList.mjs +1 -6
  269. package/utils/dataStructures/tree.js +1 -1
  270. package/utils/dataStructures/tree.mjs +1 -1
  271. package/utils/interval.js +44 -26
  272. package/utils/interval.mjs +44 -26
  273. package/core/viewportScroll/scrollStrategies/focusScroll.js +0 -15
  274. package/core/viewportScroll/scrollStrategies/focusScroll.mjs +0 -11
  275. package/i18n/languages/ar-AR.d.ts +0 -5
  276. package/i18n/languages/cs-CZ.d.ts +0 -5
  277. package/i18n/languages/hr-HR.d.ts +0 -5
  278. package/i18n/languages/sr-SP.d.ts +0 -5
  279. package/plugins/mergeCells/focusOrder.js +0 -305
  280. package/plugins/mergeCells/focusOrder.mjs +0 -300
@@ -20,9 +20,12 @@ function _checkPrivateRedeclaration(obj, privateCollection) { if (privateCollect
20
20
  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; }
21
21
  function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == typeof i ? i : String(i); }
22
22
  function _toPrimitive(t, r) { if ("object" != typeof t || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != typeof i) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
23
- function _classPrivateFieldSet(s, a, r) { return s.set(_assertClassBrand(s, a), r), r; }
24
- function _classPrivateFieldGet(s, a) { return s.get(_assertClassBrand(s, a)); }
25
- function _assertClassBrand(e, t, n) { if ("function" == typeof e ? e === t : e.has(t)) return arguments.length < 3 ? t : n; throw new TypeError("Private element is not present on this object"); }
23
+ function _classPrivateMethodGet(receiver, privateSet, fn) { if (!privateSet.has(receiver)) { throw new TypeError("attempted to get private field on non-instance"); } return fn; }
24
+ function _classPrivateFieldSet(receiver, privateMap, value) { var descriptor = _classExtractFieldDescriptor(receiver, privateMap, "set"); _classApplyDescriptorSet(receiver, descriptor, value); return value; }
25
+ function _classApplyDescriptorSet(receiver, descriptor, value) { if (descriptor.set) { descriptor.set.call(receiver, value); } else { if (!descriptor.writable) { throw new TypeError("attempted to set read only private field"); } descriptor.value = value; } }
26
+ function _classPrivateFieldGet(receiver, privateMap) { var descriptor = _classExtractFieldDescriptor(receiver, privateMap, "get"); return _classApplyDescriptorGet(receiver, descriptor); }
27
+ function _classExtractFieldDescriptor(receiver, privateMap, action) { if (!privateMap.has(receiver)) { throw new TypeError("attempted to " + action + " private field on non-instance"); } return privateMap.get(receiver); }
28
+ function _classApplyDescriptorGet(receiver, descriptor) { if (descriptor.get) { return descriptor.get.call(receiver); } return descriptor.value; }
26
29
  const PLUGIN_KEY = exports.PLUGIN_KEY = 'comments';
27
30
  const PLUGIN_PRIORITY = exports.PLUGIN_PRIORITY = 60;
28
31
  const META_COMMENT = exports.META_COMMENT = 'comment';
@@ -129,16 +132,75 @@ var _preventEditorHiding = /*#__PURE__*/new WeakMap();
129
132
  var _tempEditorDimensions = /*#__PURE__*/new WeakMap();
130
133
  var _cellBelowCursor = /*#__PURE__*/new WeakMap();
131
134
  var _commentValueBeforeSave = /*#__PURE__*/new WeakMap();
132
- var _Comments_brand = /*#__PURE__*/new WeakSet();
135
+ var _onMouseDown = /*#__PURE__*/new WeakSet();
136
+ var _onMouseOver = /*#__PURE__*/new WeakSet();
137
+ var _onMouseUp = /*#__PURE__*/new WeakSet();
138
+ var _onAfterRenderer = /*#__PURE__*/new WeakSet();
139
+ var _onEditorBlur = /*#__PURE__*/new WeakSet();
140
+ var _onEditorFocus = /*#__PURE__*/new WeakSet();
141
+ var _onEditorMouseDown = /*#__PURE__*/new WeakSet();
142
+ var _onEditorMouseUp = /*#__PURE__*/new WeakSet();
143
+ var _onAfterDocumentKeyDown = /*#__PURE__*/new WeakSet();
144
+ var _onAfterScroll = /*#__PURE__*/new WeakSet();
133
145
  class Comments extends _base.BasePlugin {
134
146
  constructor() {
135
147
  super(...arguments);
148
+ /**
149
+ * Observes the changes in the scroll position if triggered it hides the comment editor.
150
+ */
151
+ _classPrivateMethodInitSpec(this, _onAfterScroll);
152
+ /**
153
+ * Observes the pressed keys and if there is already opened the comment editor prevents open
154
+ * the table editor into the fast edit mode.
155
+ *
156
+ * @param {Event} event The keydown event.
157
+ */
158
+ _classPrivateMethodInitSpec(this, _onAfterDocumentKeyDown);
159
+ /**
160
+ * `mouseup` hook. Along with `onEditorMouseDown` used to simulate the textarea resizing event.
161
+ *
162
+ * @param {MouseEvent} event The `mouseup` event.
163
+ */
164
+ _classPrivateMethodInitSpec(this, _onEditorMouseUp);
165
+ /**
166
+ * `mousedown` hook. Along with `onEditorMouseUp` used to simulate the textarea resizing event.
167
+ *
168
+ * @param {MouseEvent} event The `mousedown` event.
169
+ */
170
+ _classPrivateMethodInitSpec(this, _onEditorMouseDown);
171
+ /**
172
+ * Hook observer the "focus" event from the comments editor element. The hook takes the control of
173
+ * the keyboard shortcuts by switching the context to plugins one.
174
+ */
175
+ _classPrivateMethodInitSpec(this, _onEditorFocus);
176
+ /**
177
+ * Hook observer the "blur" event from the comments editor element. The hook clears the
178
+ * editor content and gives back the keyboard shortcuts control by switching to the "grid" context.
179
+ */
180
+ _classPrivateMethodInitSpec(this, _onEditorBlur);
181
+ /**
182
+ * The `afterRenderer` hook callback.
183
+ *
184
+ * @param {HTMLTableCellElement} TD The rendered `TD` element.
185
+ * @param {object} cellProperties The rendered cell's property object.
186
+ */
187
+ _classPrivateMethodInitSpec(this, _onAfterRenderer);
188
+ /**
189
+ * `mouseup` event callback.
190
+ */
191
+ _classPrivateMethodInitSpec(this, _onMouseUp);
192
+ /**
193
+ * `mouseover` event callback.
194
+ *
195
+ * @param {MouseEvent} event The `mouseover` event.
196
+ */
197
+ _classPrivateMethodInitSpec(this, _onMouseOver);
136
198
  /**
137
199
  * `mousedown` event callback.
138
200
  *
139
201
  * @param {MouseEvent} event The `mousedown` event.
140
202
  */
141
- _classPrivateMethodInitSpec(this, _Comments_brand);
203
+ _classPrivateMethodInitSpec(this, _onMouseDown);
142
204
  /**
143
205
  * Current cell range, an object with `from` property, with `row` and `col` properties (e.q. `{from: {row: 1, col: 6}}`).
144
206
  *
@@ -151,21 +213,30 @@ class Comments extends _base.BasePlugin {
151
213
  * @private
152
214
  * @type {CommentEditor}
153
215
  */
154
- _classPrivateFieldInitSpec(this, _editor, null);
216
+ _classPrivateFieldInitSpec(this, _editor, {
217
+ writable: true,
218
+ value: null
219
+ });
155
220
  /**
156
221
  * Instance of {@link DisplaySwitch}.
157
222
  *
158
223
  * @private
159
224
  * @type {DisplaySwitch}
160
225
  */
161
- _classPrivateFieldInitSpec(this, _displaySwitch, null);
226
+ _classPrivateFieldInitSpec(this, _displaySwitch, {
227
+ writable: true,
228
+ value: null
229
+ });
162
230
  /**
163
231
  * Prevents showing/hiding editor that reacts on the logic triggered by the "mouseover" events.
164
232
  *
165
233
  * @private
166
234
  * @type {boolean}
167
235
  */
168
- _classPrivateFieldInitSpec(this, _preventEditorAutoSwitch, false);
236
+ _classPrivateFieldInitSpec(this, _preventEditorAutoSwitch, {
237
+ writable: true,
238
+ value: false
239
+ });
169
240
  /**
170
241
  * Prevents hiding editor when the table viewport is scrolled and that scroll is triggered by the
171
242
  * keyboard shortcut that insert or edits the comment.
@@ -173,28 +244,40 @@ class Comments extends _base.BasePlugin {
173
244
  * @private
174
245
  * @type {boolean}
175
246
  */
176
- _classPrivateFieldInitSpec(this, _preventEditorHiding, false);
247
+ _classPrivateFieldInitSpec(this, _preventEditorHiding, {
248
+ writable: true,
249
+ value: false
250
+ });
177
251
  /**
178
252
  * The property for holding editor dimensions for further processing.
179
253
  *
180
254
  * @private
181
255
  * @type {object}
182
256
  */
183
- _classPrivateFieldInitSpec(this, _tempEditorDimensions, {});
257
+ _classPrivateFieldInitSpec(this, _tempEditorDimensions, {
258
+ writable: true,
259
+ value: {}
260
+ });
184
261
  /**
185
262
  * The flag that allows processing mousedown event correctly when comments editor is triggered.
186
263
  *
187
264
  * @private
188
265
  * @type {boolean}
189
266
  */
190
- _classPrivateFieldInitSpec(this, _cellBelowCursor, null);
267
+ _classPrivateFieldInitSpec(this, _cellBelowCursor, {
268
+ writable: true,
269
+ value: null
270
+ });
191
271
  /**
192
272
  * Holds the comment value before it's actually saved to the cell meta.
193
273
  *
194
274
  * @private
195
275
  * @type {string}
196
276
  */
197
- _classPrivateFieldInitSpec(this, _commentValueBeforeSave, '');
277
+ _classPrivateFieldInitSpec(this, _commentValueBeforeSave, {
278
+ writable: true,
279
+ value: ''
280
+ });
198
281
  }
199
282
  static get PLUGIN_KEY() {
200
283
  return PLUGIN_KEY;
@@ -219,19 +302,19 @@ class Comments extends _base.BasePlugin {
219
302
  if (this.enabled) {
220
303
  return;
221
304
  }
222
- if (!_classPrivateFieldGet(_editor, this)) {
223
- _classPrivateFieldSet(_editor, this, new _commentEditor.default(this.hot.rootDocument, this.hot.isRtl()));
305
+ if (!_classPrivateFieldGet(this, _editor)) {
306
+ _classPrivateFieldSet(this, _editor, new _commentEditor.default(this.hot.rootDocument, this.hot.isRtl()));
224
307
  }
225
- if (!_classPrivateFieldGet(_displaySwitch, this)) {
226
- _classPrivateFieldSet(_displaySwitch, this, new _displaySwitch2.default(this.getDisplayDelaySetting()));
308
+ if (!_classPrivateFieldGet(this, _displaySwitch)) {
309
+ _classPrivateFieldSet(this, _displaySwitch, new _displaySwitch2.default(this.getDisplayDelaySetting()));
227
310
  }
228
311
  this.addHook('afterContextMenuDefaultOptions', options => this.addToContextMenu(options));
229
- this.addHook('afterRenderer', (TD, row, col, prop, value, cellProperties) => _assertClassBrand(_Comments_brand, this, _onAfterRenderer).call(this, TD, cellProperties));
230
- this.addHook('afterScroll', () => _assertClassBrand(_Comments_brand, this, _onAfterScroll).call(this));
312
+ this.addHook('afterRenderer', (TD, row, col, prop, value, cellProperties) => _classPrivateMethodGet(this, _onAfterRenderer, _onAfterRenderer2).call(this, TD, cellProperties));
313
+ this.addHook('afterScroll', () => _classPrivateMethodGet(this, _onAfterScroll, _onAfterScroll2).call(this));
231
314
  this.addHook('afterBeginEditing', () => this.hide());
232
- this.addHook('afterDocumentKeyDown', event => _assertClassBrand(_Comments_brand, this, _onAfterDocumentKeyDown).call(this, event));
233
- _classPrivateFieldGet(_displaySwitch, this).addLocalHook('hide', () => this.hide());
234
- _classPrivateFieldGet(_displaySwitch, this).addLocalHook('show', (row, col) => this.showAtCell(row, col));
315
+ this.addHook('afterDocumentKeyDown', event => _classPrivateMethodGet(this, _onAfterDocumentKeyDown, _onAfterDocumentKeyDown2).call(this, event));
316
+ _classPrivateFieldGet(this, _displaySwitch).addLocalHook('hide', () => this.hide());
317
+ _classPrivateFieldGet(this, _displaySwitch).addLocalHook('show', (row, col) => this.showAtCell(row, col));
235
318
  this.registerShortcuts();
236
319
  this.registerListeners();
237
320
  super.enablePlugin();
@@ -244,7 +327,7 @@ class Comments extends _base.BasePlugin {
244
327
  * - [`comments`](@/api/options.md#comments)
245
328
  */
246
329
  updatePlugin() {
247
- _classPrivateFieldGet(_displaySwitch, this).updateDelay(this.getDisplayDelaySetting());
330
+ _classPrivateFieldGet(this, _displaySwitch).updateDelay(this.getDisplayDelaySetting());
248
331
  super.updatePlugin();
249
332
  }
250
333
 
@@ -269,34 +352,34 @@ class Comments extends _base.BasePlugin {
269
352
  keys: [['Control', 'Alt', 'M']],
270
353
  callback: () => {
271
354
  const range = this.hot.getSelectedRangeLast();
272
- _classPrivateFieldSet(_preventEditorHiding, this, true);
355
+ _classPrivateFieldSet(this, _preventEditorHiding, true);
273
356
  this.hot.scrollToFocusedCell(() => {
274
357
  this.setRange(range);
275
358
  this.show();
276
359
  this.focusEditor();
277
360
  manager.setActiveContextName(SHORTCUTS_CONTEXT_NAME);
278
361
  this.hot._registerTimeout(() => {
279
- _classPrivateFieldSet(_preventEditorHiding, this, false);
362
+ _classPrivateFieldSet(this, _preventEditorHiding, false);
280
363
  });
281
364
  });
282
365
  },
283
366
  stopPropagation: true,
284
367
  runOnlyIf: () => {
285
368
  var _this$hot$getSelected;
286
- return ((_this$hot$getSelected = this.hot.getSelectedRangeLast()) === null || _this$hot$getSelected === void 0 ? void 0 : _this$hot$getSelected.highlight.isCell()) && !_classPrivateFieldGet(_editor, this).isVisible();
369
+ return ((_this$hot$getSelected = this.hot.getSelectedRangeLast()) === null || _this$hot$getSelected === void 0 ? void 0 : _this$hot$getSelected.highlight.isCell()) && !_classPrivateFieldGet(this, _editor).isVisible();
287
370
  },
288
371
  group: SHORTCUTS_GROUP
289
372
  });
290
373
  pluginContext.addShortcut({
291
374
  keys: [['Escape']],
292
375
  callback: () => {
293
- _classPrivateFieldGet(_editor, this).setValue(_classPrivateFieldGet(_commentValueBeforeSave, this));
376
+ _classPrivateFieldGet(this, _editor).setValue(_classPrivateFieldGet(this, _commentValueBeforeSave));
294
377
  this.hide();
295
378
  manager.setActiveContextName('grid');
296
379
  },
297
380
  runOnlyIf: () => {
298
381
  var _this$hot$getSelected2;
299
- return ((_this$hot$getSelected2 = this.hot.getSelectedRangeLast()) === null || _this$hot$getSelected2 === void 0 ? void 0 : _this$hot$getSelected2.highlight.isCell()) && _classPrivateFieldGet(_editor, this).isVisible();
382
+ return ((_this$hot$getSelected2 = this.hot.getSelectedRangeLast()) === null || _this$hot$getSelected2 === void 0 ? void 0 : _this$hot$getSelected2.highlight.isCell()) && _classPrivateFieldGet(this, _editor).isVisible();
300
383
  },
301
384
  group: SHORTCUTS_GROUP
302
385
  });
@@ -308,7 +391,7 @@ class Comments extends _base.BasePlugin {
308
391
  },
309
392
  runOnlyIf: () => {
310
393
  var _this$hot$getSelected3;
311
- return ((_this$hot$getSelected3 = this.hot.getSelectedRangeLast()) === null || _this$hot$getSelected3 === void 0 ? void 0 : _this$hot$getSelected3.highlight.isCell()) && _classPrivateFieldGet(_editor, this).isVisible();
394
+ return ((_this$hot$getSelected3 = this.hot.getSelectedRangeLast()) === null || _this$hot$getSelected3 === void 0 ? void 0 : _this$hot$getSelected3.highlight.isCell()) && _classPrivateFieldGet(this, _editor).isVisible();
312
395
  },
313
396
  group: SHORTCUTS_GROUP
314
397
  });
@@ -333,13 +416,13 @@ class Comments extends _base.BasePlugin {
333
416
  rootDocument
334
417
  } = this.hot;
335
418
  const editorElement = this.getEditorInputElement();
336
- this.eventManager.addEventListener(rootDocument, 'mouseover', event => _assertClassBrand(_Comments_brand, this, _onMouseOver).call(this, event));
337
- this.eventManager.addEventListener(rootDocument, 'mousedown', event => _assertClassBrand(_Comments_brand, this, _onMouseDown).call(this, event));
338
- this.eventManager.addEventListener(rootDocument, 'mouseup', () => _assertClassBrand(_Comments_brand, this, _onMouseUp).call(this));
339
- this.eventManager.addEventListener(editorElement, 'focus', () => _assertClassBrand(_Comments_brand, this, _onEditorFocus).call(this));
340
- this.eventManager.addEventListener(editorElement, 'blur', () => _assertClassBrand(_Comments_brand, this, _onEditorBlur).call(this));
341
- this.eventManager.addEventListener(editorElement, 'mousedown', event => _assertClassBrand(_Comments_brand, this, _onEditorMouseDown).call(this, event));
342
- this.eventManager.addEventListener(editorElement, 'mouseup', event => _assertClassBrand(_Comments_brand, this, _onEditorMouseUp).call(this, event));
419
+ this.eventManager.addEventListener(rootDocument, 'mouseover', event => _classPrivateMethodGet(this, _onMouseOver, _onMouseOver2).call(this, event));
420
+ this.eventManager.addEventListener(rootDocument, 'mousedown', event => _classPrivateMethodGet(this, _onMouseDown, _onMouseDown2).call(this, event));
421
+ this.eventManager.addEventListener(rootDocument, 'mouseup', () => _classPrivateMethodGet(this, _onMouseUp, _onMouseUp2).call(this));
422
+ this.eventManager.addEventListener(editorElement, 'focus', () => _classPrivateMethodGet(this, _onEditorFocus, _onEditorFocus2).call(this));
423
+ this.eventManager.addEventListener(editorElement, 'blur', () => _classPrivateMethodGet(this, _onEditorBlur, _onEditorBlur2).call(this));
424
+ this.eventManager.addEventListener(editorElement, 'mousedown', event => _classPrivateMethodGet(this, _onEditorMouseDown, _onEditorMouseDown2).call(this, event));
425
+ this.eventManager.addEventListener(editorElement, 'mouseup', event => _classPrivateMethodGet(this, _onEditorMouseUp, _onEditorMouseUp2).call(this, event));
343
426
  }
344
427
 
345
428
  /**
@@ -390,7 +473,7 @@ class Comments extends _base.BasePlugin {
390
473
  if (!this.range.from) {
391
474
  throw new Error('Before using this method, first set cell range (hot.getPlugin("comment").setRange())');
392
475
  }
393
- const editorValue = _classPrivateFieldGet(_editor, this).getValue();
476
+ const editorValue = _classPrivateFieldGet(this, _editor).getValue();
394
477
  let comment = '';
395
478
  if (value !== null && value !== undefined) {
396
479
  comment = value;
@@ -493,9 +576,9 @@ class Comments extends _base.BasePlugin {
493
576
  return false;
494
577
  }
495
578
  const meta = this.hot.getCellMeta(this.range.from.row, this.range.from.col);
496
- _classPrivateFieldGet(_displaySwitch, this).cancelHiding();
497
- _classPrivateFieldGet(_editor, this).setValue((_ref = meta[META_COMMENT] ? meta[META_COMMENT][META_COMMENT_VALUE] : null) !== null && _ref !== void 0 ? _ref : '');
498
- _classPrivateFieldGet(_editor, this).show();
579
+ _classPrivateFieldGet(this, _displaySwitch).cancelHiding();
580
+ _classPrivateFieldGet(this, _editor).setValue((_ref = meta[META_COMMENT] ? meta[META_COMMENT][META_COMMENT_VALUE] : null) !== null && _ref !== void 0 ? _ref : '');
581
+ _classPrivateFieldGet(this, _editor).show();
499
582
  this.refreshEditor(true);
500
583
  return true;
501
584
  }
@@ -518,7 +601,7 @@ class Comments extends _base.BasePlugin {
518
601
  * Hides the comment editor.
519
602
  */
520
603
  hide() {
521
- _classPrivateFieldGet(_editor, this).hide();
604
+ _classPrivateFieldGet(this, _editor).hide();
522
605
  }
523
606
 
524
607
  /**
@@ -529,7 +612,7 @@ class Comments extends _base.BasePlugin {
529
612
  refreshEditor() {
530
613
  var _renderableRow, _renderableColumn;
531
614
  let force = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : false;
532
- if (!force && (!this.range.from || !_classPrivateFieldGet(_editor, this).isVisible())) {
615
+ if (!force && (!this.range.from || !_classPrivateFieldGet(this, _editor).isVisible())) {
533
616
  return;
534
617
  }
535
618
  const {
@@ -547,7 +630,7 @@ class Comments extends _base.BasePlugin {
547
630
 
548
631
  // Reset the editor position to (0, 0) so the opening direction calculation wouldn't be influenced by its
549
632
  // previous position
550
- _classPrivateFieldGet(_editor, this).setPosition(0, 0);
633
+ _classPrivateFieldGet(this, _editor).setPosition(0, 0);
551
634
  if (renderableRow === null) {
552
635
  renderableRow = rowIndexMapper.getRenderableFromVisualIndex(rowIndexMapper.getNearestNotHiddenIndex(visualRow, -1));
553
636
  }
@@ -575,9 +658,9 @@ class Comments extends _base.BasePlugin {
575
658
  }, true);
576
659
  const commentStyle = this.getCommentMeta(visualRow, visualColumn, META_STYLE);
577
660
  if (commentStyle) {
578
- _classPrivateFieldGet(_editor, this).setSize(commentStyle.width, commentStyle.height);
661
+ _classPrivateFieldGet(this, _editor).setSize(commentStyle.width, commentStyle.height);
579
662
  } else {
580
- _classPrivateFieldGet(_editor, this).resetSize();
663
+ _classPrivateFieldGet(this, _editor).resetSize();
581
664
  }
582
665
  const lastColWidth = isBeforeRenderedColumns ? 0 : wtTable.getStretchedColumnWidth(renderableColumn);
583
666
  const lastRowHeight = targetingPreviousRow && !isBeforeRenderedRows ? (0, _element.outerHeight)(TD) : 0;
@@ -590,7 +673,7 @@ class Comments extends _base.BasePlugin {
590
673
  const {
591
674
  width: editorWidth,
592
675
  height: editorHeight
593
- } = _classPrivateFieldGet(_editor, this).getSize();
676
+ } = _classPrivateFieldGet(this, _editor).getSize();
594
677
  const {
595
678
  innerWidth,
596
679
  innerHeight
@@ -611,15 +694,15 @@ class Comments extends _base.BasePlugin {
611
694
  if (top + editorHeight > innerHeight) {
612
695
  y -= editorHeight - cellHeight + 1;
613
696
  }
614
- _classPrivateFieldGet(_editor, this).setPosition(x, y);
615
- _classPrivateFieldGet(_editor, this).setReadOnlyState(this.getCommentMeta(visualRow, visualColumn, META_READONLY));
697
+ _classPrivateFieldGet(this, _editor).setPosition(x, y);
698
+ _classPrivateFieldGet(this, _editor).setReadOnlyState(this.getCommentMeta(visualRow, visualColumn, META_READONLY));
616
699
  }
617
700
 
618
701
  /**
619
702
  * Focuses the comments editor element.
620
703
  */
621
704
  focusEditor() {
622
- _classPrivateFieldGet(_editor, this).focus();
705
+ _classPrivateFieldGet(this, _editor).focus();
623
706
  }
624
707
 
625
708
  /**
@@ -688,28 +771,28 @@ class Comments extends _base.BasePlugin {
688
771
  * @returns {HTMLTextAreaElement}
689
772
  */
690
773
  getEditorInputElement() {
691
- return _classPrivateFieldGet(_editor, this).getInputElement();
774
+ return _classPrivateFieldGet(this, _editor).getInputElement();
692
775
  }
693
776
 
694
777
  /**
695
778
  * Destroys the plugin instance.
696
779
  */
697
780
  destroy() {
698
- if (_classPrivateFieldGet(_editor, this)) {
699
- _classPrivateFieldGet(_editor, this).destroy();
781
+ if (_classPrivateFieldGet(this, _editor)) {
782
+ _classPrivateFieldGet(this, _editor).destroy();
700
783
  }
701
- if (_classPrivateFieldGet(_displaySwitch, this)) {
702
- _classPrivateFieldGet(_displaySwitch, this).destroy();
784
+ if (_classPrivateFieldGet(this, _displaySwitch)) {
785
+ _classPrivateFieldGet(this, _displaySwitch).destroy();
703
786
  }
704
787
  super.destroy();
705
788
  }
706
789
  }
707
790
  exports.Comments = Comments;
708
- function _onMouseDown(event) {
791
+ function _onMouseDown2(event) {
709
792
  if (!this.hot.view || !this.hot.view._wt) {
710
793
  return;
711
794
  }
712
- if (!_classPrivateFieldGet(_preventEditorAutoSwitch, this) && !this.targetIsCommentTextArea(event)) {
795
+ if (!_classPrivateFieldGet(this, _preventEditorAutoSwitch) && !this.targetIsCommentTextArea(event)) {
713
796
  const eventCell = (0, _element.closest)(event.target, 'TD', 'TBODY');
714
797
  let coordinates = null;
715
798
  if (eventCell) {
@@ -720,81 +803,49 @@ function _onMouseDown(event) {
720
803
  }
721
804
  }
722
805
  }
723
- /**
724
- * `mouseover` event callback.
725
- *
726
- * @param {MouseEvent} event The `mouseover` event.
727
- */
728
- function _onMouseOver(event) {
806
+ function _onMouseOver2(event) {
729
807
  const {
730
808
  rootDocument
731
809
  } = this.hot;
732
- if (_classPrivateFieldGet(_preventEditorAutoSwitch, this) || _classPrivateFieldGet(_editor, this).isFocused() || (0, _element.hasClass)(event.target, 'wtBorder') || _classPrivateFieldGet(_cellBelowCursor, this) === event.target || !_classPrivateFieldGet(_editor, this)) {
810
+ if (_classPrivateFieldGet(this, _preventEditorAutoSwitch) || _classPrivateFieldGet(this, _editor).isFocused() || (0, _element.hasClass)(event.target, 'wtBorder') || _classPrivateFieldGet(this, _cellBelowCursor) === event.target || !_classPrivateFieldGet(this, _editor)) {
733
811
  return;
734
812
  }
735
- _classPrivateFieldSet(_cellBelowCursor, this, rootDocument.elementFromPoint(event.clientX, event.clientY));
813
+ _classPrivateFieldSet(this, _cellBelowCursor, rootDocument.elementFromPoint(event.clientX, event.clientY));
736
814
  if (this.targetIsCellWithComment(event)) {
737
815
  const range = this.hot._createCellRange(this.hot.getCoords(event.target));
738
- _classPrivateFieldGet(_displaySwitch, this).show(range);
816
+ _classPrivateFieldGet(this, _displaySwitch).show(range);
739
817
  } else if ((0, _element.isChildOf)(event.target, rootDocument) && !this.targetIsCommentTextArea(event)) {
740
- _classPrivateFieldGet(_displaySwitch, this).hide();
818
+ _classPrivateFieldGet(this, _displaySwitch).hide();
741
819
  }
742
820
  }
743
- /**
744
- * `mouseup` event callback.
745
- */
746
- function _onMouseUp() {
747
- _classPrivateFieldSet(_preventEditorAutoSwitch, this, false);
821
+ function _onMouseUp2() {
822
+ _classPrivateFieldSet(this, _preventEditorAutoSwitch, false);
748
823
  }
749
- /**
750
- * The `afterRenderer` hook callback.
751
- *
752
- * @param {HTMLTableCellElement} TD The rendered `TD` element.
753
- * @param {object} cellProperties The rendered cell's property object.
754
- */
755
- function _onAfterRenderer(TD, cellProperties) {
824
+ function _onAfterRenderer2(TD, cellProperties) {
756
825
  if (cellProperties[META_COMMENT] && cellProperties[META_COMMENT][META_COMMENT_VALUE]) {
757
826
  (0, _element.addClass)(TD, cellProperties.commentedCellClassName);
758
827
  }
759
828
  }
760
- /**
761
- * Hook observer the "blur" event from the comments editor element. The hook clears the
762
- * editor content and gives back the keyboard shortcuts control by switching to the "grid" context.
763
- */
764
- function _onEditorBlur() {
765
- _classPrivateFieldSet(_commentValueBeforeSave, this, '');
829
+ function _onEditorBlur2() {
830
+ _classPrivateFieldSet(this, _commentValueBeforeSave, '');
766
831
  this.hot.getShortcutManager().setActiveContextName('grid');
767
832
  this.setComment();
768
833
  }
769
- /**
770
- * Hook observer the "focus" event from the comments editor element. The hook takes the control of
771
- * the keyboard shortcuts by switching the context to plugins one.
772
- */
773
- function _onEditorFocus() {
774
- _classPrivateFieldSet(_commentValueBeforeSave, this, this.getComment());
834
+ function _onEditorFocus2() {
835
+ _classPrivateFieldSet(this, _commentValueBeforeSave, this.getComment());
775
836
  this.hot.listen();
776
837
  this.hot.getShortcutManager().setActiveContextName(SHORTCUTS_CONTEXT_NAME);
777
838
  }
778
- /**
779
- * `mousedown` hook. Along with `onEditorMouseUp` used to simulate the textarea resizing event.
780
- *
781
- * @param {MouseEvent} event The `mousedown` event.
782
- */
783
- function _onEditorMouseDown(event) {
784
- _classPrivateFieldSet(_tempEditorDimensions, this, {
839
+ function _onEditorMouseDown2(event) {
840
+ _classPrivateFieldSet(this, _tempEditorDimensions, {
785
841
  width: (0, _element.outerWidth)(event.target),
786
842
  height: (0, _element.outerHeight)(event.target)
787
843
  });
788
844
  }
789
- /**
790
- * `mouseup` hook. Along with `onEditorMouseDown` used to simulate the textarea resizing event.
791
- *
792
- * @param {MouseEvent} event The `mouseup` event.
793
- */
794
- function _onEditorMouseUp(event) {
845
+ function _onEditorMouseUp2(event) {
795
846
  const currentWidth = (0, _element.outerWidth)(event.target);
796
847
  const currentHeight = (0, _element.outerHeight)(event.target);
797
- if (currentWidth !== _classPrivateFieldGet(_tempEditorDimensions, this).width + 1 || currentHeight !== _classPrivateFieldGet(_tempEditorDimensions, this).height + 2) {
848
+ if (currentWidth !== _classPrivateFieldGet(this, _tempEditorDimensions).width + 1 || currentHeight !== _classPrivateFieldGet(this, _tempEditorDimensions).height + 2) {
798
849
  this.updateCommentMeta(this.range.from.row, this.range.from.col, {
799
850
  [META_STYLE]: {
800
851
  width: currentWidth,
@@ -803,22 +854,13 @@ function _onEditorMouseUp(event) {
803
854
  });
804
855
  }
805
856
  }
806
- /**
807
- * Observes the pressed keys and if there is already opened the comment editor prevents open
808
- * the table editor into the fast edit mode.
809
- *
810
- * @param {Event} event The keydown event.
811
- */
812
- function _onAfterDocumentKeyDown(event) {
813
- if (_classPrivateFieldGet(_editor, this).isVisible()) {
857
+ function _onAfterDocumentKeyDown2(event) {
858
+ if (_classPrivateFieldGet(this, _editor).isVisible()) {
814
859
  (0, _event.stopImmediatePropagation)(event);
815
860
  }
816
861
  }
817
- /**
818
- * Observes the changes in the scroll position if triggered it hides the comment editor.
819
- */
820
- function _onAfterScroll() {
821
- if (!_classPrivateFieldGet(_preventEditorHiding, this)) {
862
+ function _onAfterScroll2() {
863
+ if (!_classPrivateFieldGet(this, _preventEditorHiding)) {
822
864
  this.hide();
823
865
  }
824
866
  }