handsontable 0.0.0-next-9ec04ce-20221121

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 (1232) hide show
  1. package/3rdparty/SheetClip/SheetClip.js +128 -0
  2. package/3rdparty/SheetClip/SheetClip.mjs +123 -0
  3. package/3rdparty/SheetClip/index.js +7 -0
  4. package/3rdparty/SheetClip/index.mjs +1 -0
  5. package/3rdparty/autoResize/autoResize.js +164 -0
  6. package/3rdparty/autoResize/autoResize.mjs +160 -0
  7. package/3rdparty/autoResize/index.js +6 -0
  8. package/3rdparty/autoResize/index.mjs +1 -0
  9. package/3rdparty/walkontable/src/border.js +746 -0
  10. package/3rdparty/walkontable/src/border.mjs +741 -0
  11. package/3rdparty/walkontable/src/calculator/constants.js +30 -0
  12. package/3rdparty/walkontable/src/calculator/constants.mjs +23 -0
  13. package/3rdparty/walkontable/src/calculator/index.js +22 -0
  14. package/3rdparty/walkontable/src/calculator/index.mjs +4 -0
  15. package/3rdparty/walkontable/src/calculator/viewportColumns.d.ts +18 -0
  16. package/3rdparty/walkontable/src/calculator/viewportColumns.js +297 -0
  17. package/3rdparty/walkontable/src/calculator/viewportColumns.mjs +292 -0
  18. package/3rdparty/walkontable/src/calculator/viewportRows.js +175 -0
  19. package/3rdparty/walkontable/src/calculator/viewportRows.mjs +170 -0
  20. package/3rdparty/walkontable/src/cell/coords.d.ts +16 -0
  21. package/3rdparty/walkontable/src/cell/coords.js +185 -0
  22. package/3rdparty/walkontable/src/cell/coords.mjs +180 -0
  23. package/3rdparty/walkontable/src/cell/range.d.ts +59 -0
  24. package/3rdparty/walkontable/src/cell/range.js +888 -0
  25. package/3rdparty/walkontable/src/cell/range.mjs +882 -0
  26. package/3rdparty/walkontable/src/core/_base.js +395 -0
  27. package/3rdparty/walkontable/src/core/_base.mjs +390 -0
  28. package/3rdparty/walkontable/src/core/clone.js +59 -0
  29. package/3rdparty/walkontable/src/core/clone.mjs +54 -0
  30. package/3rdparty/walkontable/src/core/core.js +130 -0
  31. package/3rdparty/walkontable/src/core/core.mjs +125 -0
  32. package/3rdparty/walkontable/src/event.js +401 -0
  33. package/3rdparty/walkontable/src/event.mjs +396 -0
  34. package/3rdparty/walkontable/src/facade/core.js +236 -0
  35. package/3rdparty/walkontable/src/facade/core.mjs +231 -0
  36. package/3rdparty/walkontable/src/filter/column.js +107 -0
  37. package/3rdparty/walkontable/src/filter/column.mjs +102 -0
  38. package/3rdparty/walkontable/src/filter/row.js +107 -0
  39. package/3rdparty/walkontable/src/filter/row.mjs +102 -0
  40. package/3rdparty/walkontable/src/index.d.ts +1 -0
  41. package/3rdparty/walkontable/src/index.js +37 -0
  42. package/3rdparty/walkontable/src/index.mjs +10 -0
  43. package/3rdparty/walkontable/src/overlay/_base.js +363 -0
  44. package/3rdparty/walkontable/src/overlay/_base.mjs +357 -0
  45. package/3rdparty/walkontable/src/overlay/bottom.js +397 -0
  46. package/3rdparty/walkontable/src/overlay/bottom.mjs +391 -0
  47. package/3rdparty/walkontable/src/overlay/bottomInlineStartCorner.js +140 -0
  48. package/3rdparty/walkontable/src/overlay/bottomInlineStartCorner.mjs +134 -0
  49. package/3rdparty/walkontable/src/overlay/constants.js +26 -0
  50. package/3rdparty/walkontable/src/overlay/constants.mjs +15 -0
  51. package/3rdparty/walkontable/src/overlay/index.js +34 -0
  52. package/3rdparty/walkontable/src/overlay/index.mjs +7 -0
  53. package/3rdparty/walkontable/src/overlay/inlineStart.js +385 -0
  54. package/3rdparty/walkontable/src/overlay/inlineStart.mjs +379 -0
  55. package/3rdparty/walkontable/src/overlay/top.js +415 -0
  56. package/3rdparty/walkontable/src/overlay/top.mjs +409 -0
  57. package/3rdparty/walkontable/src/overlay/topInlineStartCorner.js +130 -0
  58. package/3rdparty/walkontable/src/overlay/topInlineStartCorner.mjs +124 -0
  59. package/3rdparty/walkontable/src/overlays.js +675 -0
  60. package/3rdparty/walkontable/src/overlays.mjs +670 -0
  61. package/3rdparty/walkontable/src/renderer/_base.js +83 -0
  62. package/3rdparty/walkontable/src/renderer/_base.mjs +78 -0
  63. package/3rdparty/walkontable/src/renderer/cells.js +127 -0
  64. package/3rdparty/walkontable/src/renderer/cells.mjs +122 -0
  65. package/3rdparty/walkontable/src/renderer/colGroup.js +101 -0
  66. package/3rdparty/walkontable/src/renderer/colGroup.mjs +96 -0
  67. package/3rdparty/walkontable/src/renderer/columnHeaders.js +115 -0
  68. package/3rdparty/walkontable/src/renderer/columnHeaders.mjs +110 -0
  69. package/3rdparty/walkontable/src/renderer/index.js +118 -0
  70. package/3rdparty/walkontable/src/renderer/index.mjs +107 -0
  71. package/3rdparty/walkontable/src/renderer/rowHeaders.js +119 -0
  72. package/3rdparty/walkontable/src/renderer/rowHeaders.mjs +114 -0
  73. package/3rdparty/walkontable/src/renderer/rows.js +99 -0
  74. package/3rdparty/walkontable/src/renderer/rows.mjs +94 -0
  75. package/3rdparty/walkontable/src/renderer/table.js +317 -0
  76. package/3rdparty/walkontable/src/renderer/table.mjs +313 -0
  77. package/3rdparty/walkontable/src/scroll.js +316 -0
  78. package/3rdparty/walkontable/src/scroll.mjs +311 -0
  79. package/3rdparty/walkontable/src/selection.js +349 -0
  80. package/3rdparty/walkontable/src/selection.mjs +343 -0
  81. package/3rdparty/walkontable/src/settings.js +306 -0
  82. package/3rdparty/walkontable/src/settings.mjs +302 -0
  83. package/3rdparty/walkontable/src/table/bottom.js +56 -0
  84. package/3rdparty/walkontable/src/table/bottom.mjs +50 -0
  85. package/3rdparty/walkontable/src/table/bottomInlineStartCorner.js +57 -0
  86. package/3rdparty/walkontable/src/table/bottomInlineStartCorner.mjs +51 -0
  87. package/3rdparty/walkontable/src/table/inlineStart.js +53 -0
  88. package/3rdparty/walkontable/src/table/inlineStart.mjs +47 -0
  89. package/3rdparty/walkontable/src/table/master.js +132 -0
  90. package/3rdparty/walkontable/src/table/master.mjs +126 -0
  91. package/3rdparty/walkontable/src/table/mixin/calculatedColumns.js +93 -0
  92. package/3rdparty/walkontable/src/table/mixin/calculatedColumns.mjs +88 -0
  93. package/3rdparty/walkontable/src/table/mixin/calculatedRows.js +93 -0
  94. package/3rdparty/walkontable/src/table/mixin/calculatedRows.mjs +88 -0
  95. package/3rdparty/walkontable/src/table/mixin/stickyColumnsStart.js +85 -0
  96. package/3rdparty/walkontable/src/table/mixin/stickyColumnsStart.mjs +80 -0
  97. package/3rdparty/walkontable/src/table/mixin/stickyRowsBottom.js +90 -0
  98. package/3rdparty/walkontable/src/table/mixin/stickyRowsBottom.mjs +85 -0
  99. package/3rdparty/walkontable/src/table/mixin/stickyRowsTop.js +85 -0
  100. package/3rdparty/walkontable/src/table/mixin/stickyRowsTop.mjs +80 -0
  101. package/3rdparty/walkontable/src/table/top.js +56 -0
  102. package/3rdparty/walkontable/src/table/top.mjs +50 -0
  103. package/3rdparty/walkontable/src/table/topInlineStartCorner.js +57 -0
  104. package/3rdparty/walkontable/src/table/topInlineStartCorner.mjs +51 -0
  105. package/3rdparty/walkontable/src/table.js +1171 -0
  106. package/3rdparty/walkontable/src/table.mjs +1165 -0
  107. package/3rdparty/walkontable/src/types.js +98 -0
  108. package/3rdparty/walkontable/src/types.mjs +97 -0
  109. package/3rdparty/walkontable/src/utils/column.js +121 -0
  110. package/3rdparty/walkontable/src/utils/column.mjs +117 -0
  111. package/3rdparty/walkontable/src/utils/nodesPool.js +48 -0
  112. package/3rdparty/walkontable/src/utils/nodesPool.mjs +44 -0
  113. package/3rdparty/walkontable/src/utils/orderView/constants.js +30 -0
  114. package/3rdparty/walkontable/src/utils/orderView/constants.mjs +23 -0
  115. package/3rdparty/walkontable/src/utils/orderView/index.js +8 -0
  116. package/3rdparty/walkontable/src/utils/orderView/index.mjs +3 -0
  117. package/3rdparty/walkontable/src/utils/orderView/sharedView.js +81 -0
  118. package/3rdparty/walkontable/src/utils/orderView/sharedView.mjs +76 -0
  119. package/3rdparty/walkontable/src/utils/orderView/view.js +216 -0
  120. package/3rdparty/walkontable/src/utils/orderView/view.mjs +211 -0
  121. package/3rdparty/walkontable/src/utils/orderView/viewSize.js +68 -0
  122. package/3rdparty/walkontable/src/utils/orderView/viewSize.mjs +64 -0
  123. package/3rdparty/walkontable/src/utils/orderView/viewSizeSet.js +137 -0
  124. package/3rdparty/walkontable/src/utils/orderView/viewSizeSet.mjs +132 -0
  125. package/3rdparty/walkontable/src/utils/row.js +43 -0
  126. package/3rdparty/walkontable/src/utils/row.mjs +39 -0
  127. package/3rdparty/walkontable/src/viewport.js +491 -0
  128. package/3rdparty/walkontable/src/viewport.mjs +486 -0
  129. package/CHANGELOG.md +716 -0
  130. package/LICENSE.txt +25 -0
  131. package/README.md +140 -0
  132. package/base.d.ts +3 -0
  133. package/base.js +54 -0
  134. package/base.mjs +44 -0
  135. package/cellTypes/autocompleteType/autocompleteType.d.ts +17 -0
  136. package/cellTypes/autocompleteType/autocompleteType.js +16 -0
  137. package/cellTypes/autocompleteType/autocompleteType.mjs +10 -0
  138. package/cellTypes/autocompleteType/index.d.ts +1 -0
  139. package/cellTypes/autocompleteType/index.js +7 -0
  140. package/cellTypes/autocompleteType/index.mjs +1 -0
  141. package/cellTypes/base.d.ts +14 -0
  142. package/cellTypes/checkboxType/checkboxType.d.ts +14 -0
  143. package/cellTypes/checkboxType/checkboxType.js +14 -0
  144. package/cellTypes/checkboxType/checkboxType.mjs +8 -0
  145. package/cellTypes/checkboxType/index.d.ts +1 -0
  146. package/cellTypes/checkboxType/index.js +7 -0
  147. package/cellTypes/checkboxType/index.mjs +1 -0
  148. package/cellTypes/dateType/dateType.d.ts +17 -0
  149. package/cellTypes/dateType/dateType.js +17 -0
  150. package/cellTypes/dateType/dateType.mjs +11 -0
  151. package/cellTypes/dateType/index.d.ts +1 -0
  152. package/cellTypes/dateType/index.js +7 -0
  153. package/cellTypes/dateType/index.mjs +1 -0
  154. package/cellTypes/dropdownType/dropdownType.d.ts +17 -0
  155. package/cellTypes/dropdownType/dropdownType.js +17 -0
  156. package/cellTypes/dropdownType/dropdownType.mjs +11 -0
  157. package/cellTypes/dropdownType/index.d.ts +1 -0
  158. package/cellTypes/dropdownType/index.js +7 -0
  159. package/cellTypes/dropdownType/index.mjs +1 -0
  160. package/cellTypes/handsontableType/handsontableType.d.ts +14 -0
  161. package/cellTypes/handsontableType/handsontableType.js +15 -0
  162. package/cellTypes/handsontableType/handsontableType.mjs +9 -0
  163. package/cellTypes/handsontableType/index.d.ts +1 -0
  164. package/cellTypes/handsontableType/index.js +7 -0
  165. package/cellTypes/handsontableType/index.mjs +1 -0
  166. package/cellTypes/index.d.ts +47 -0
  167. package/cellTypes/index.js +52 -0
  168. package/cellTypes/index.mjs +26 -0
  169. package/cellTypes/numericType/index.d.ts +1 -0
  170. package/cellTypes/numericType/index.js +7 -0
  171. package/cellTypes/numericType/index.mjs +1 -0
  172. package/cellTypes/numericType/numericType.d.ts +17 -0
  173. package/cellTypes/numericType/numericType.js +17 -0
  174. package/cellTypes/numericType/numericType.mjs +11 -0
  175. package/cellTypes/passwordType/index.d.ts +1 -0
  176. package/cellTypes/passwordType/index.js +7 -0
  177. package/cellTypes/passwordType/index.mjs +1 -0
  178. package/cellTypes/passwordType/passwordType.d.ts +14 -0
  179. package/cellTypes/passwordType/passwordType.js +15 -0
  180. package/cellTypes/passwordType/passwordType.mjs +9 -0
  181. package/cellTypes/registry.d.ts +18 -0
  182. package/cellTypes/registry.js +60 -0
  183. package/cellTypes/registry.mjs +51 -0
  184. package/cellTypes/textType/index.d.ts +1 -0
  185. package/cellTypes/textType/index.js +7 -0
  186. package/cellTypes/textType/index.mjs +1 -0
  187. package/cellTypes/textType/textType.d.ts +14 -0
  188. package/cellTypes/textType/textType.js +14 -0
  189. package/cellTypes/textType/textType.mjs +8 -0
  190. package/cellTypes/timeType/index.d.ts +1 -0
  191. package/cellTypes/timeType/index.js +7 -0
  192. package/cellTypes/timeType/index.mjs +1 -0
  193. package/cellTypes/timeType/timeType.d.ts +17 -0
  194. package/cellTypes/timeType/timeType.js +16 -0
  195. package/cellTypes/timeType/timeType.mjs +10 -0
  196. package/common.d.ts +74 -0
  197. package/core.d.ts +167 -0
  198. package/core.js +4684 -0
  199. package/core.mjs +4679 -0
  200. package/dataMap/dataMap.js +975 -0
  201. package/dataMap/dataMap.mjs +970 -0
  202. package/dataMap/dataSource.js +325 -0
  203. package/dataMap/dataSource.mjs +320 -0
  204. package/dataMap/index.js +16 -0
  205. package/dataMap/index.mjs +7 -0
  206. package/dataMap/metaManager/index.js +339 -0
  207. package/dataMap/metaManager/index.mjs +334 -0
  208. package/dataMap/metaManager/lazyFactoryMap.js +370 -0
  209. package/dataMap/metaManager/lazyFactoryMap.mjs +366 -0
  210. package/dataMap/metaManager/metaLayers/cellMeta.js +275 -0
  211. package/dataMap/metaManager/metaLayers/cellMeta.mjs +270 -0
  212. package/dataMap/metaManager/metaLayers/columnMeta.js +153 -0
  213. package/dataMap/metaManager/metaLayers/columnMeta.mjs +148 -0
  214. package/dataMap/metaManager/metaLayers/globalMeta.js +103 -0
  215. package/dataMap/metaManager/metaLayers/globalMeta.mjs +98 -0
  216. package/dataMap/metaManager/metaLayers/tableMeta.js +73 -0
  217. package/dataMap/metaManager/metaLayers/tableMeta.mjs +69 -0
  218. package/dataMap/metaManager/metaSchema.js +4610 -0
  219. package/dataMap/metaManager/metaSchema.mjs +4605 -0
  220. package/dataMap/metaManager/mods/dynamicCellMeta.js +107 -0
  221. package/dataMap/metaManager/mods/dynamicCellMeta.mjs +101 -0
  222. package/dataMap/metaManager/mods/extendMetaProperties.js +104 -0
  223. package/dataMap/metaManager/mods/extendMetaProperties.mjs +99 -0
  224. package/dataMap/metaManager/utils.js +99 -0
  225. package/dataMap/metaManager/utils.mjs +91 -0
  226. package/dataMap/replaceData.js +119 -0
  227. package/dataMap/replaceData.mjs +115 -0
  228. package/dist/README.md +54 -0
  229. package/dist/handsontable.css +1941 -0
  230. package/dist/handsontable.full.css +2172 -0
  231. package/dist/handsontable.full.js +150392 -0
  232. package/dist/handsontable.full.min.css +47 -0
  233. package/dist/handsontable.full.min.js +869 -0
  234. package/dist/handsontable.js +94075 -0
  235. package/dist/handsontable.min.css +43 -0
  236. package/dist/handsontable.min.js +31 -0
  237. package/dist/languages/all.js +583 -0
  238. package/dist/languages/all.min.js +1 -0
  239. package/dist/languages/ar-AR.js +157 -0
  240. package/dist/languages/ar-AR.min.js +1 -0
  241. package/dist/languages/cs-CZ.js +157 -0
  242. package/dist/languages/cs-CZ.min.js +1 -0
  243. package/dist/languages/de-CH.js +158 -0
  244. package/dist/languages/de-CH.min.js +1 -0
  245. package/dist/languages/de-DE.js +159 -0
  246. package/dist/languages/de-DE.min.js +1 -0
  247. package/dist/languages/en-US.js +160 -0
  248. package/dist/languages/en-US.min.js +1 -0
  249. package/dist/languages/es-MX.js +161 -0
  250. package/dist/languages/es-MX.min.js +1 -0
  251. package/dist/languages/fr-FR.js +162 -0
  252. package/dist/languages/fr-FR.min.js +1 -0
  253. package/dist/languages/it-IT.js +164 -0
  254. package/dist/languages/it-IT.min.js +1 -0
  255. package/dist/languages/ja-JP.js +161 -0
  256. package/dist/languages/ja-JP.min.js +1 -0
  257. package/dist/languages/ko-KR.js +161 -0
  258. package/dist/languages/ko-KR.min.js +1 -0
  259. package/dist/languages/lv-LV.js +161 -0
  260. package/dist/languages/lv-LV.min.js +1 -0
  261. package/dist/languages/nb-NO.js +161 -0
  262. package/dist/languages/nb-NO.min.js +1 -0
  263. package/dist/languages/nl-NL.js +161 -0
  264. package/dist/languages/nl-NL.min.js +1 -0
  265. package/dist/languages/pl-PL.js +161 -0
  266. package/dist/languages/pl-PL.min.js +1 -0
  267. package/dist/languages/pt-BR.js +161 -0
  268. package/dist/languages/pt-BR.min.js +1 -0
  269. package/dist/languages/ru-RU.js +161 -0
  270. package/dist/languages/ru-RU.min.js +1 -0
  271. package/dist/languages/sr-SP.js +161 -0
  272. package/dist/languages/sr-SP.min.js +1 -0
  273. package/dist/languages/zh-CN.js +161 -0
  274. package/dist/languages/zh-CN.min.js +1 -0
  275. package/dist/languages/zh-TW.js +161 -0
  276. package/dist/languages/zh-TW.min.js +1 -0
  277. package/editorManager.js +522 -0
  278. package/editorManager.mjs +514 -0
  279. package/editors/autocompleteEditor/autocompleteEditor.d.ts +29 -0
  280. package/editors/autocompleteEditor/autocompleteEditor.js +584 -0
  281. package/editors/autocompleteEditor/autocompleteEditor.mjs +578 -0
  282. package/editors/autocompleteEditor/index.d.ts +1 -0
  283. package/editors/autocompleteEditor/index.js +7 -0
  284. package/editors/autocompleteEditor/index.mjs +1 -0
  285. package/editors/baseEditor/baseEditor.d.ts +45 -0
  286. package/editors/baseEditor/baseEditor.js +688 -0
  287. package/editors/baseEditor/baseEditor.mjs +679 -0
  288. package/editors/baseEditor/index.d.ts +1 -0
  289. package/editors/baseEditor/index.js +8 -0
  290. package/editors/baseEditor/index.mjs +1 -0
  291. package/editors/checkboxEditor/checkboxEditor.d.ts +12 -0
  292. package/editors/checkboxEditor/checkboxEditor.js +85 -0
  293. package/editors/checkboxEditor/checkboxEditor.mjs +79 -0
  294. package/editors/checkboxEditor/index.d.ts +1 -0
  295. package/editors/checkboxEditor/index.js +7 -0
  296. package/editors/checkboxEditor/index.mjs +1 -0
  297. package/editors/dateEditor/dateEditor.d.ts +18 -0
  298. package/editors/dateEditor/dateEditor.js +325 -0
  299. package/editors/dateEditor/dateEditor.mjs +318 -0
  300. package/editors/dateEditor/index.d.ts +1 -0
  301. package/editors/dateEditor/index.js +7 -0
  302. package/editors/dateEditor/index.mjs +1 -0
  303. package/editors/dropdownEditor/dropdownEditor.d.ts +7 -0
  304. package/editors/dropdownEditor/dropdownEditor.js +81 -0
  305. package/editors/dropdownEditor/dropdownEditor.mjs +74 -0
  306. package/editors/dropdownEditor/index.d.ts +1 -0
  307. package/editors/dropdownEditor/index.js +7 -0
  308. package/editors/dropdownEditor/index.mjs +1 -0
  309. package/editors/handsontableEditor/handsontableEditor.d.ts +10 -0
  310. package/editors/handsontableEditor/handsontableEditor.js +306 -0
  311. package/editors/handsontableEditor/handsontableEditor.mjs +300 -0
  312. package/editors/handsontableEditor/index.d.ts +1 -0
  313. package/editors/handsontableEditor/index.js +7 -0
  314. package/editors/handsontableEditor/index.mjs +1 -0
  315. package/editors/index.d.ts +56 -0
  316. package/editors/index.js +63 -0
  317. package/editors/index.mjs +30 -0
  318. package/editors/numericEditor/index.d.ts +1 -0
  319. package/editors/numericEditor/index.js +7 -0
  320. package/editors/numericEditor/index.mjs +1 -0
  321. package/editors/numericEditor/numericEditor.d.ts +7 -0
  322. package/editors/numericEditor/numericEditor.js +49 -0
  323. package/editors/numericEditor/numericEditor.mjs +43 -0
  324. package/editors/passwordEditor/index.d.ts +1 -0
  325. package/editors/passwordEditor/index.js +7 -0
  326. package/editors/passwordEditor/index.mjs +1 -0
  327. package/editors/passwordEditor/passwordEditor.d.ts +7 -0
  328. package/editors/passwordEditor/passwordEditor.js +68 -0
  329. package/editors/passwordEditor/passwordEditor.mjs +62 -0
  330. package/editors/registry.d.ts +29 -0
  331. package/editors/registry.js +106 -0
  332. package/editors/registry.mjs +94 -0
  333. package/editors/selectEditor/index.d.ts +1 -0
  334. package/editors/selectEditor/index.js +7 -0
  335. package/editors/selectEditor/index.mjs +1 -0
  336. package/editors/selectEditor/selectEditor.d.ts +16 -0
  337. package/editors/selectEditor/selectEditor.js +302 -0
  338. package/editors/selectEditor/selectEditor.mjs +296 -0
  339. package/editors/textEditor/caretPositioner.js +37 -0
  340. package/editors/textEditor/caretPositioner.mjs +33 -0
  341. package/editors/textEditor/index.d.ts +1 -0
  342. package/editors/textEditor/index.js +7 -0
  343. package/editors/textEditor/index.mjs +1 -0
  344. package/editors/textEditor/textEditor.d.ts +24 -0
  345. package/editors/textEditor/textEditor.js +612 -0
  346. package/editors/textEditor/textEditor.mjs +605 -0
  347. package/editors/timeEditor/index.d.ts +1 -0
  348. package/editors/timeEditor/index.js +7 -0
  349. package/editors/timeEditor/index.mjs +1 -0
  350. package/editors/timeEditor/timeEditor.d.ts +7 -0
  351. package/editors/timeEditor/timeEditor.js +70 -0
  352. package/editors/timeEditor/timeEditor.mjs +64 -0
  353. package/eventManager.d.ts +13 -0
  354. package/eventManager.js +236 -0
  355. package/eventManager.mjs +231 -0
  356. package/handsontable-non-commercial-license.pdf +0 -0
  357. package/helpers/array.d.ts +18 -0
  358. package/helpers/array.js +353 -0
  359. package/helpers/array.mjs +333 -0
  360. package/helpers/browser.d.ts +25 -0
  361. package/helpers/browser.js +231 -0
  362. package/helpers/browser.mjs +210 -0
  363. package/helpers/console.d.ts +4 -0
  364. package/helpers/console.js +65 -0
  365. package/helpers/console.mjs +56 -0
  366. package/helpers/data.d.ts +12 -0
  367. package/helpers/data.js +247 -0
  368. package/helpers/data.mjs +234 -0
  369. package/helpers/date.d.ts +1 -0
  370. package/helpers/date.js +22 -0
  371. package/helpers/date.mjs +18 -0
  372. package/helpers/dom/element.d.ts +49 -0
  373. package/helpers/dom/element.js +1117 -0
  374. package/helpers/dom/element.mjs +1064 -0
  375. package/helpers/dom/event.d.ts +4 -0
  376. package/helpers/dom/event.js +46 -0
  377. package/helpers/dom/event.mjs +39 -0
  378. package/helpers/dom/index.d.ts +2 -0
  379. package/helpers/feature.d.ts +11 -0
  380. package/helpers/feature.js +184 -0
  381. package/helpers/feature.mjs +172 -0
  382. package/helpers/function.d.ts +10 -0
  383. package/helpers/function.js +319 -0
  384. package/helpers/function.mjs +307 -0
  385. package/helpers/index.d.ts +14 -0
  386. package/helpers/mixed.d.ts +5 -0
  387. package/helpers/mixed.js +230 -0
  388. package/helpers/mixed.mjs +220 -0
  389. package/helpers/number.d.ts +5 -0
  390. package/helpers/number.js +142 -0
  391. package/helpers/number.mjs +134 -0
  392. package/helpers/object.d.ts +16 -0
  393. package/helpers/object.js +371 -0
  394. package/helpers/object.mjs +352 -0
  395. package/helpers/string.d.ts +7 -0
  396. package/helpers/string.js +115 -0
  397. package/helpers/string.mjs +104 -0
  398. package/helpers/templateLiteralTag.d.ts +1 -0
  399. package/helpers/templateLiteralTag.js +26 -0
  400. package/helpers/templateLiteralTag.mjs +22 -0
  401. package/helpers/unicode.d.ts +73 -0
  402. package/helpers/unicode.js +158 -0
  403. package/helpers/unicode.mjs +148 -0
  404. package/helpers/wrappers/jquery.js +50 -0
  405. package/helpers/wrappers/jquery.mjs +46 -0
  406. package/i18n/constants.js +162 -0
  407. package/i18n/constants.mjs +82 -0
  408. package/i18n/index.d.ts +2 -0
  409. package/i18n/index.js +18 -0
  410. package/i18n/index.mjs +2 -0
  411. package/i18n/languages/ar-AR.js +25 -0
  412. package/i18n/languages/ar-AR.mjs +15 -0
  413. package/i18n/languages/cs-CZ.js +24 -0
  414. package/i18n/languages/cs-CZ.mjs +14 -0
  415. package/i18n/languages/de-CH.d.ts +5 -0
  416. package/i18n/languages/de-CH.js +24 -0
  417. package/i18n/languages/de-CH.mjs +14 -0
  418. package/i18n/languages/de-DE.d.ts +5 -0
  419. package/i18n/languages/de-DE.js +24 -0
  420. package/i18n/languages/de-DE.mjs +14 -0
  421. package/i18n/languages/en-US.d.ts +5 -0
  422. package/i18n/languages/en-US.js +24 -0
  423. package/i18n/languages/en-US.mjs +14 -0
  424. package/i18n/languages/es-MX.d.ts +5 -0
  425. package/i18n/languages/es-MX.js +24 -0
  426. package/i18n/languages/es-MX.mjs +13 -0
  427. package/i18n/languages/fr-FR.d.ts +5 -0
  428. package/i18n/languages/fr-FR.js +24 -0
  429. package/i18n/languages/fr-FR.mjs +14 -0
  430. package/i18n/languages/index.d.ts +35 -0
  431. package/i18n/languages/index.js +42 -0
  432. package/i18n/languages/index.mjs +20 -0
  433. package/i18n/languages/it-IT.d.ts +5 -0
  434. package/i18n/languages/it-IT.js +24 -0
  435. package/i18n/languages/it-IT.mjs +14 -0
  436. package/i18n/languages/ja-JP.d.ts +5 -0
  437. package/i18n/languages/ja-JP.js +24 -0
  438. package/i18n/languages/ja-JP.mjs +14 -0
  439. package/i18n/languages/ko-KR.d.ts +5 -0
  440. package/i18n/languages/ko-KR.js +24 -0
  441. package/i18n/languages/ko-KR.mjs +14 -0
  442. package/i18n/languages/lv-LV.d.ts +5 -0
  443. package/i18n/languages/lv-LV.js +24 -0
  444. package/i18n/languages/lv-LV.mjs +14 -0
  445. package/i18n/languages/nb-NO.d.ts +5 -0
  446. package/i18n/languages/nb-NO.js +24 -0
  447. package/i18n/languages/nb-NO.mjs +14 -0
  448. package/i18n/languages/nl-NL.d.ts +5 -0
  449. package/i18n/languages/nl-NL.js +24 -0
  450. package/i18n/languages/nl-NL.mjs +14 -0
  451. package/i18n/languages/pl-PL.d.ts +5 -0
  452. package/i18n/languages/pl-PL.js +24 -0
  453. package/i18n/languages/pl-PL.mjs +14 -0
  454. package/i18n/languages/pt-BR.d.ts +5 -0
  455. package/i18n/languages/pt-BR.js +24 -0
  456. package/i18n/languages/pt-BR.mjs +14 -0
  457. package/i18n/languages/ru-RU.d.ts +5 -0
  458. package/i18n/languages/ru-RU.js +24 -0
  459. package/i18n/languages/ru-RU.mjs +14 -0
  460. package/i18n/languages/sr-SP.js +24 -0
  461. package/i18n/languages/sr-SP.mjs +14 -0
  462. package/i18n/languages/zh-CN.d.ts +5 -0
  463. package/i18n/languages/zh-CN.js +24 -0
  464. package/i18n/languages/zh-CN.mjs +14 -0
  465. package/i18n/languages/zh-TW.d.ts +5 -0
  466. package/i18n/languages/zh-TW.js +24 -0
  467. package/i18n/languages/zh-TW.mjs +14 -0
  468. package/i18n/phraseFormatters/index.js +31 -0
  469. package/i18n/phraseFormatters/index.mjs +26 -0
  470. package/i18n/phraseFormatters/pluralize.js +21 -0
  471. package/i18n/phraseFormatters/pluralize.mjs +17 -0
  472. package/i18n/phraseFormatters/substituteVariables.js +22 -0
  473. package/i18n/phraseFormatters/substituteVariables.mjs +18 -0
  474. package/i18n/registry.d.ts +13 -0
  475. package/i18n/registry.js +180 -0
  476. package/i18n/registry.mjs +155 -0
  477. package/i18n/utils.js +90 -0
  478. package/i18n/utils.mjs +83 -0
  479. package/index.d.ts +520 -0
  480. package/index.js +130 -0
  481. package/index.mjs +112 -0
  482. package/languages/all.js +583 -0
  483. package/languages/ar-AR.js +157 -0
  484. package/languages/ar-AR.mjs +17 -0
  485. package/languages/cs-CZ.js +157 -0
  486. package/languages/cs-CZ.mjs +16 -0
  487. package/languages/de-CH.js +158 -0
  488. package/languages/de-CH.mjs +16 -0
  489. package/languages/de-DE.js +159 -0
  490. package/languages/de-DE.mjs +16 -0
  491. package/languages/en-US.js +160 -0
  492. package/languages/en-US.mjs +16 -0
  493. package/languages/es-MX.js +161 -0
  494. package/languages/es-MX.mjs +15 -0
  495. package/languages/fr-FR.js +162 -0
  496. package/languages/fr-FR.mjs +16 -0
  497. package/languages/index.js +583 -0
  498. package/languages/index.mjs +20 -0
  499. package/languages/it-IT.js +164 -0
  500. package/languages/it-IT.mjs +16 -0
  501. package/languages/ja-JP.js +161 -0
  502. package/languages/ja-JP.mjs +16 -0
  503. package/languages/ko-KR.js +161 -0
  504. package/languages/ko-KR.mjs +16 -0
  505. package/languages/lv-LV.js +161 -0
  506. package/languages/lv-LV.mjs +16 -0
  507. package/languages/nb-NO.js +161 -0
  508. package/languages/nb-NO.mjs +16 -0
  509. package/languages/nl-NL.js +161 -0
  510. package/languages/nl-NL.mjs +16 -0
  511. package/languages/pl-PL.js +161 -0
  512. package/languages/pl-PL.mjs +16 -0
  513. package/languages/pt-BR.js +161 -0
  514. package/languages/pt-BR.mjs +16 -0
  515. package/languages/ru-RU.js +161 -0
  516. package/languages/ru-RU.mjs +16 -0
  517. package/languages/sr-SP.js +161 -0
  518. package/languages/sr-SP.mjs +16 -0
  519. package/languages/zh-CN.js +161 -0
  520. package/languages/zh-CN.mjs +16 -0
  521. package/languages/zh-TW.js +161 -0
  522. package/languages/zh-TW.mjs +16 -0
  523. package/mixins/hooksRefRegisterer.js +61 -0
  524. package/mixins/hooksRefRegisterer.mjs +56 -0
  525. package/mixins/localHooks.js +71 -0
  526. package/mixins/localHooks.mjs +66 -0
  527. package/package.json +751 -0
  528. package/pluginHooks.d.ts +256 -0
  529. package/pluginHooks.js +2750 -0
  530. package/pluginHooks.mjs +2744 -0
  531. package/plugins/autoColumnSize/autoColumnSize.d.ts +27 -0
  532. package/plugins/autoColumnSize/autoColumnSize.js +796 -0
  533. package/plugins/autoColumnSize/autoColumnSize.mjs +788 -0
  534. package/plugins/autoColumnSize/index.d.ts +1 -0
  535. package/plugins/autoColumnSize/index.js +8 -0
  536. package/plugins/autoColumnSize/index.mjs +1 -0
  537. package/plugins/autoRowSize/autoRowSize.d.ts +27 -0
  538. package/plugins/autoRowSize/autoRowSize.js +735 -0
  539. package/plugins/autoRowSize/autoRowSize.mjs +727 -0
  540. package/plugins/autoRowSize/index.d.ts +1 -0
  541. package/plugins/autoRowSize/index.js +8 -0
  542. package/plugins/autoRowSize/index.mjs +1 -0
  543. package/plugins/autofill/autofill.d.ts +18 -0
  544. package/plugins/autofill/autofill.js +694 -0
  545. package/plugins/autofill/autofill.mjs +687 -0
  546. package/plugins/autofill/index.d.ts +1 -0
  547. package/plugins/autofill/index.js +8 -0
  548. package/plugins/autofill/index.mjs +1 -0
  549. package/plugins/autofill/utils.js +134 -0
  550. package/plugins/autofill/utils.mjs +126 -0
  551. package/plugins/base/base.d.ts +27 -0
  552. package/plugins/base/base.js +345 -0
  553. package/plugins/base/base.mjs +339 -0
  554. package/plugins/base/index.d.ts +1 -0
  555. package/plugins/base/index.js +7 -0
  556. package/plugins/base/index.mjs +1 -0
  557. package/plugins/bindRowsWithHeaders/bindRowsWithHeaders.d.ts +9 -0
  558. package/plugins/bindRowsWithHeaders/bindRowsWithHeaders.js +169 -0
  559. package/plugins/bindRowsWithHeaders/bindRowsWithHeaders.mjs +161 -0
  560. package/plugins/bindRowsWithHeaders/index.d.ts +1 -0
  561. package/plugins/bindRowsWithHeaders/index.js +8 -0
  562. package/plugins/bindRowsWithHeaders/index.mjs +1 -0
  563. package/plugins/bindRowsWithHeaders/maps/looseBindsMap.js +80 -0
  564. package/plugins/bindRowsWithHeaders/maps/looseBindsMap.mjs +75 -0
  565. package/plugins/bindRowsWithHeaders/maps/strictBindsMap.js +103 -0
  566. package/plugins/bindRowsWithHeaders/maps/strictBindsMap.mjs +98 -0
  567. package/plugins/collapsibleColumns/collapsibleColumns.d.ts +22 -0
  568. package/plugins/collapsibleColumns/collapsibleColumns.js +592 -0
  569. package/plugins/collapsibleColumns/collapsibleColumns.mjs +584 -0
  570. package/plugins/collapsibleColumns/index.d.ts +1 -0
  571. package/plugins/collapsibleColumns/index.js +8 -0
  572. package/plugins/collapsibleColumns/index.mjs +1 -0
  573. package/plugins/columnSorting/columnSorting.d.ts +30 -0
  574. package/plugins/columnSorting/columnSorting.js +865 -0
  575. package/plugins/columnSorting/columnSorting.mjs +857 -0
  576. package/plugins/columnSorting/columnStatesManager.js +273 -0
  577. package/plugins/columnSorting/columnStatesManager.mjs +268 -0
  578. package/plugins/columnSorting/domHelpers.js +54 -0
  579. package/plugins/columnSorting/domHelpers.mjs +49 -0
  580. package/plugins/columnSorting/index.d.ts +1 -0
  581. package/plugins/columnSorting/index.js +8 -0
  582. package/plugins/columnSorting/index.mjs +1 -0
  583. package/plugins/columnSorting/rootComparator.js +52 -0
  584. package/plugins/columnSorting/rootComparator.mjs +48 -0
  585. package/plugins/columnSorting/sortFunction/checkbox.js +64 -0
  586. package/plugins/columnSorting/sortFunction/checkbox.mjs +58 -0
  587. package/plugins/columnSorting/sortFunction/date.js +61 -0
  588. package/plugins/columnSorting/sortFunction/date.mjs +54 -0
  589. package/plugins/columnSorting/sortFunction/default.js +65 -0
  590. package/plugins/columnSorting/sortFunction/default.mjs +59 -0
  591. package/plugins/columnSorting/sortFunction/numeric.js +49 -0
  592. package/plugins/columnSorting/sortFunction/numeric.mjs +43 -0
  593. package/plugins/columnSorting/sortService/engine.js +26 -0
  594. package/plugins/columnSorting/sortService/engine.mjs +18 -0
  595. package/plugins/columnSorting/sortService/index.js +13 -0
  596. package/plugins/columnSorting/sortService/index.mjs +3 -0
  597. package/plugins/columnSorting/sortService/registry.js +37 -0
  598. package/plugins/columnSorting/sortService/registry.mjs +30 -0
  599. package/plugins/columnSorting/utils.js +122 -0
  600. package/plugins/columnSorting/utils.mjs +110 -0
  601. package/plugins/columnSummary/columnSummary.d.ts +72 -0
  602. package/plugins/columnSummary/columnSummary.js +544 -0
  603. package/plugins/columnSummary/columnSummary.mjs +536 -0
  604. package/plugins/columnSummary/endpoints.js +557 -0
  605. package/plugins/columnSummary/endpoints.mjs +552 -0
  606. package/plugins/columnSummary/index.d.ts +1 -0
  607. package/plugins/columnSummary/index.js +8 -0
  608. package/plugins/columnSummary/index.mjs +1 -0
  609. package/plugins/columnSummary/utils.js +13 -0
  610. package/plugins/columnSummary/utils.mjs +9 -0
  611. package/plugins/comments/commentEditor.js +241 -0
  612. package/plugins/comments/commentEditor.mjs +236 -0
  613. package/plugins/comments/comments.d.ts +50 -0
  614. package/plugins/comments/comments.js +942 -0
  615. package/plugins/comments/comments.mjs +932 -0
  616. package/plugins/comments/displaySwitch.js +115 -0
  617. package/plugins/comments/displaySwitch.mjs +109 -0
  618. package/plugins/comments/index.d.ts +1 -0
  619. package/plugins/comments/index.js +8 -0
  620. package/plugins/comments/index.mjs +1 -0
  621. package/plugins/contextMenu/commandExecutor.js +113 -0
  622. package/plugins/contextMenu/commandExecutor.mjs +108 -0
  623. package/plugins/contextMenu/contextMenu.d.ts +65 -0
  624. package/plugins/contextMenu/contextMenu.js +445 -0
  625. package/plugins/contextMenu/contextMenu.mjs +437 -0
  626. package/plugins/contextMenu/cursor.js +126 -0
  627. package/plugins/contextMenu/cursor.mjs +121 -0
  628. package/plugins/contextMenu/index.d.ts +1 -0
  629. package/plugins/contextMenu/index.js +8 -0
  630. package/plugins/contextMenu/index.mjs +1 -0
  631. package/plugins/contextMenu/itemsFactory.js +136 -0
  632. package/plugins/contextMenu/itemsFactory.mjs +131 -0
  633. package/plugins/contextMenu/menu.js +1003 -0
  634. package/plugins/contextMenu/menu.mjs +997 -0
  635. package/plugins/contextMenu/predefinedItems/alignment.js +277 -0
  636. package/plugins/contextMenu/predefinedItems/alignment.mjs +259 -0
  637. package/plugins/contextMenu/predefinedItems/clearColumn.js +47 -0
  638. package/plugins/contextMenu/predefinedItems/clearColumn.mjs +29 -0
  639. package/plugins/contextMenu/predefinedItems/columnLeft.js +57 -0
  640. package/plugins/contextMenu/predefinedItems/columnLeft.mjs +39 -0
  641. package/plugins/contextMenu/predefinedItems/columnRight.js +55 -0
  642. package/plugins/contextMenu/predefinedItems/columnRight.mjs +37 -0
  643. package/plugins/contextMenu/predefinedItems/noItems.js +22 -0
  644. package/plugins/contextMenu/predefinedItems/noItems.mjs +16 -0
  645. package/plugins/contextMenu/predefinedItems/readOnly.js +69 -0
  646. package/plugins/contextMenu/predefinedItems/readOnly.mjs +51 -0
  647. package/plugins/contextMenu/predefinedItems/redo.js +42 -0
  648. package/plugins/contextMenu/predefinedItems/redo.mjs +24 -0
  649. package/plugins/contextMenu/predefinedItems/removeColumn.js +79 -0
  650. package/plugins/contextMenu/predefinedItems/removeColumn.mjs +68 -0
  651. package/plugins/contextMenu/predefinedItems/removeRow.js +78 -0
  652. package/plugins/contextMenu/predefinedItems/removeRow.mjs +67 -0
  653. package/plugins/contextMenu/predefinedItems/rowAbove.js +53 -0
  654. package/plugins/contextMenu/predefinedItems/rowAbove.mjs +35 -0
  655. package/plugins/contextMenu/predefinedItems/rowBelow.js +51 -0
  656. package/plugins/contextMenu/predefinedItems/rowBelow.mjs +33 -0
  657. package/plugins/contextMenu/predefinedItems/separator.js +16 -0
  658. package/plugins/contextMenu/predefinedItems/separator.mjs +10 -0
  659. package/plugins/contextMenu/predefinedItems/undo.js +42 -0
  660. package/plugins/contextMenu/predefinedItems/undo.mjs +24 -0
  661. package/plugins/contextMenu/predefinedItems.js +76 -0
  662. package/plugins/contextMenu/predefinedItems.mjs +57 -0
  663. package/plugins/contextMenu/utils.js +278 -0
  664. package/plugins/contextMenu/utils.mjs +261 -0
  665. package/plugins/copyPaste/clipboardData.js +29 -0
  666. package/plugins/copyPaste/clipboardData.mjs +25 -0
  667. package/plugins/copyPaste/contextMenuItem/copy.js +45 -0
  668. package/plugins/copyPaste/contextMenuItem/copy.mjs +29 -0
  669. package/plugins/copyPaste/contextMenuItem/cut.js +45 -0
  670. package/plugins/copyPaste/contextMenuItem/cut.mjs +29 -0
  671. package/plugins/copyPaste/copyPaste.d.ts +35 -0
  672. package/plugins/copyPaste/copyPaste.js +721 -0
  673. package/plugins/copyPaste/copyPaste.mjs +713 -0
  674. package/plugins/copyPaste/focusableElement.js +210 -0
  675. package/plugins/copyPaste/focusableElement.mjs +204 -0
  676. package/plugins/copyPaste/index.d.ts +1 -0
  677. package/plugins/copyPaste/index.js +8 -0
  678. package/plugins/copyPaste/index.mjs +1 -0
  679. package/plugins/copyPaste/pasteEvent.js +17 -0
  680. package/plugins/copyPaste/pasteEvent.mjs +12 -0
  681. package/plugins/customBorders/contextMenuItem/bottom.js +39 -0
  682. package/plugins/customBorders/contextMenuItem/bottom.mjs +23 -0
  683. package/plugins/customBorders/contextMenuItem/index.js +14 -0
  684. package/plugins/customBorders/contextMenuItem/index.mjs +6 -0
  685. package/plugins/customBorders/contextMenuItem/left.js +40 -0
  686. package/plugins/customBorders/contextMenuItem/left.mjs +24 -0
  687. package/plugins/customBorders/contextMenuItem/noBorders.js +36 -0
  688. package/plugins/customBorders/contextMenuItem/noBorders.mjs +20 -0
  689. package/plugins/customBorders/contextMenuItem/right.js +40 -0
  690. package/plugins/customBorders/contextMenuItem/right.mjs +24 -0
  691. package/plugins/customBorders/contextMenuItem/top.js +39 -0
  692. package/plugins/customBorders/contextMenuItem/top.mjs +23 -0
  693. package/plugins/customBorders/customBorders.d.ts +38 -0
  694. package/plugins/customBorders/customBorders.js +887 -0
  695. package/plugins/customBorders/customBorders.mjs +877 -0
  696. package/plugins/customBorders/index.d.ts +1 -0
  697. package/plugins/customBorders/index.js +8 -0
  698. package/plugins/customBorders/index.mjs +1 -0
  699. package/plugins/customBorders/utils.js +265 -0
  700. package/plugins/customBorders/utils.mjs +249 -0
  701. package/plugins/dragToScroll/dragToScroll.d.ts +15 -0
  702. package/plugins/dragToScroll/dragToScroll.js +335 -0
  703. package/plugins/dragToScroll/dragToScroll.mjs +327 -0
  704. package/plugins/dragToScroll/index.d.ts +1 -0
  705. package/plugins/dragToScroll/index.js +8 -0
  706. package/plugins/dragToScroll/index.mjs +1 -0
  707. package/plugins/dropdownMenu/dropdownMenu.d.ts +24 -0
  708. package/plugins/dropdownMenu/dropdownMenu.js +511 -0
  709. package/plugins/dropdownMenu/dropdownMenu.mjs +504 -0
  710. package/plugins/dropdownMenu/index.d.ts +1 -0
  711. package/plugins/dropdownMenu/index.js +8 -0
  712. package/plugins/dropdownMenu/index.mjs +1 -0
  713. package/plugins/exportFile/dataProvider.js +200 -0
  714. package/plugins/exportFile/dataProvider.mjs +195 -0
  715. package/plugins/exportFile/exportFile.d.ts +12 -0
  716. package/plugins/exportFile/exportFile.js +262 -0
  717. package/plugins/exportFile/exportFile.mjs +250 -0
  718. package/plugins/exportFile/index.d.ts +1 -0
  719. package/plugins/exportFile/index.js +8 -0
  720. package/plugins/exportFile/index.mjs +1 -0
  721. package/plugins/exportFile/typeFactory.js +30 -0
  722. package/plugins/exportFile/typeFactory.mjs +21 -0
  723. package/plugins/exportFile/types/_base.js +78 -0
  724. package/plugins/exportFile/types/_base.mjs +73 -0
  725. package/plugins/exportFile/types/csv.js +131 -0
  726. package/plugins/exportFile/types/csv.mjs +125 -0
  727. package/plugins/filters/component/_base.js +169 -0
  728. package/plugins/filters/component/_base.mjs +163 -0
  729. package/plugins/filters/component/actionBar.js +161 -0
  730. package/plugins/filters/component/actionBar.mjs +151 -0
  731. package/plugins/filters/component/condition.js +325 -0
  732. package/plugins/filters/component/condition.mjs +316 -0
  733. package/plugins/filters/component/operators.js +222 -0
  734. package/plugins/filters/component/operators.mjs +216 -0
  735. package/plugins/filters/component/value.js +278 -0
  736. package/plugins/filters/component/value.mjs +269 -0
  737. package/plugins/filters/condition/beginsWith.js +50 -0
  738. package/plugins/filters/condition/beginsWith.mjs +39 -0
  739. package/plugins/filters/condition/between.js +64 -0
  740. package/plugins/filters/condition/between.mjs +53 -0
  741. package/plugins/filters/condition/byValue.js +48 -0
  742. package/plugins/filters/condition/byValue.mjs +42 -0
  743. package/plugins/filters/condition/contains.js +50 -0
  744. package/plugins/filters/condition/contains.mjs +39 -0
  745. package/plugins/filters/condition/date/after.js +55 -0
  746. package/plugins/filters/condition/date/after.mjs +43 -0
  747. package/plugins/filters/condition/date/before.js +55 -0
  748. package/plugins/filters/condition/date/before.mjs +43 -0
  749. package/plugins/filters/condition/date/today.js +39 -0
  750. package/plugins/filters/condition/date/today.mjs +20 -0
  751. package/plugins/filters/condition/date/tomorrow.js +39 -0
  752. package/plugins/filters/condition/date/tomorrow.mjs +20 -0
  753. package/plugins/filters/condition/date/yesterday.js +39 -0
  754. package/plugins/filters/condition/date/yesterday.mjs +20 -0
  755. package/plugins/filters/condition/empty.js +35 -0
  756. package/plugins/filters/condition/empty.mjs +17 -0
  757. package/plugins/filters/condition/endsWith.js +50 -0
  758. package/plugins/filters/condition/endsWith.mjs +39 -0
  759. package/plugins/filters/condition/equal.js +49 -0
  760. package/plugins/filters/condition/equal.mjs +38 -0
  761. package/plugins/filters/condition/false.js +18 -0
  762. package/plugins/filters/condition/false.mjs +12 -0
  763. package/plugins/filters/condition/greaterThan.js +52 -0
  764. package/plugins/filters/condition/greaterThan.mjs +41 -0
  765. package/plugins/filters/condition/greaterThanOrEqual.js +52 -0
  766. package/plugins/filters/condition/greaterThanOrEqual.mjs +41 -0
  767. package/plugins/filters/condition/lessThan.js +52 -0
  768. package/plugins/filters/condition/lessThan.mjs +41 -0
  769. package/plugins/filters/condition/lessThanOrEqual.js +52 -0
  770. package/plugins/filters/condition/lessThanOrEqual.mjs +41 -0
  771. package/plugins/filters/condition/none.js +33 -0
  772. package/plugins/filters/condition/none.mjs +15 -0
  773. package/plugins/filters/condition/notBetween.js +36 -0
  774. package/plugins/filters/condition/notBetween.mjs +18 -0
  775. package/plugins/filters/condition/notContains.js +36 -0
  776. package/plugins/filters/condition/notContains.mjs +18 -0
  777. package/plugins/filters/condition/notEmpty.js +36 -0
  778. package/plugins/filters/condition/notEmpty.mjs +18 -0
  779. package/plugins/filters/condition/notEqual.js +36 -0
  780. package/plugins/filters/condition/notEqual.mjs +18 -0
  781. package/plugins/filters/condition/true.js +18 -0
  782. package/plugins/filters/condition/true.mjs +12 -0
  783. package/plugins/filters/conditionCollection.d.ts +32 -0
  784. package/plugins/filters/conditionCollection.js +343 -0
  785. package/plugins/filters/conditionCollection.mjs +337 -0
  786. package/plugins/filters/conditionRegisterer.js +61 -0
  787. package/plugins/filters/conditionRegisterer.mjs +53 -0
  788. package/plugins/filters/conditionUpdateObserver.d.ts +10 -0
  789. package/plugins/filters/conditionUpdateObserver.js +248 -0
  790. package/plugins/filters/conditionUpdateObserver.mjs +242 -0
  791. package/plugins/filters/constants.js +103 -0
  792. package/plugins/filters/constants.mjs +69 -0
  793. package/plugins/filters/dataFilter.js +98 -0
  794. package/plugins/filters/dataFilter.mjs +93 -0
  795. package/plugins/filters/filters.d.ts +56 -0
  796. package/plugins/filters/filters.js +1037 -0
  797. package/plugins/filters/filters.mjs +1026 -0
  798. package/plugins/filters/index.d.ts +1 -0
  799. package/plugins/filters/index.js +8 -0
  800. package/plugins/filters/index.mjs +1 -0
  801. package/plugins/filters/logicalOperationRegisterer.js +50 -0
  802. package/plugins/filters/logicalOperationRegisterer.mjs +42 -0
  803. package/plugins/filters/logicalOperations/conjunction.js +36 -0
  804. package/plugins/filters/logicalOperations/conjunction.mjs +18 -0
  805. package/plugins/filters/logicalOperations/disjunction.js +36 -0
  806. package/plugins/filters/logicalOperations/disjunction.mjs +18 -0
  807. package/plugins/filters/logicalOperations/disjunctionWithExtraCondition.js +40 -0
  808. package/plugins/filters/logicalOperations/disjunctionWithExtraCondition.mjs +22 -0
  809. package/plugins/filters/ui/_base.js +249 -0
  810. package/plugins/filters/ui/_base.mjs +231 -0
  811. package/plugins/filters/ui/input.js +140 -0
  812. package/plugins/filters/ui/input.mjs +134 -0
  813. package/plugins/filters/ui/link.js +86 -0
  814. package/plugins/filters/ui/link.mjs +80 -0
  815. package/plugins/filters/ui/multipleSelect.js +441 -0
  816. package/plugins/filters/ui/multipleSelect.mjs +434 -0
  817. package/plugins/filters/ui/radioInput.js +130 -0
  818. package/plugins/filters/ui/radioInput.mjs +124 -0
  819. package/plugins/filters/ui/select.js +269 -0
  820. package/plugins/filters/ui/select.mjs +261 -0
  821. package/plugins/filters/utils.js +143 -0
  822. package/plugins/filters/utils.mjs +134 -0
  823. package/plugins/formulas/engine/register.js +259 -0
  824. package/plugins/formulas/engine/register.mjs +247 -0
  825. package/plugins/formulas/engine/settings.js +115 -0
  826. package/plugins/formulas/engine/settings.mjs +107 -0
  827. package/plugins/formulas/formulas.d.ts +31 -0
  828. package/plugins/formulas/formulas.js +1229 -0
  829. package/plugins/formulas/formulas.mjs +1221 -0
  830. package/plugins/formulas/index.d.ts +1 -0
  831. package/plugins/formulas/index.js +8 -0
  832. package/plugins/formulas/index.mjs +1 -0
  833. package/plugins/formulas/utils.js +24 -0
  834. package/plugins/formulas/utils.mjs +19 -0
  835. package/plugins/hiddenColumns/contextMenuItem/hideColumn.js +76 -0
  836. package/plugins/hiddenColumns/contextMenuItem/hideColumn.mjs +67 -0
  837. package/plugins/hiddenColumns/contextMenuItem/showColumn.js +124 -0
  838. package/plugins/hiddenColumns/contextMenuItem/showColumn.mjs +115 -0
  839. package/plugins/hiddenColumns/hiddenColumns.d.ts +21 -0
  840. package/plugins/hiddenColumns/hiddenColumns.js +620 -0
  841. package/plugins/hiddenColumns/hiddenColumns.mjs +612 -0
  842. package/plugins/hiddenColumns/index.d.ts +1 -0
  843. package/plugins/hiddenColumns/index.js +8 -0
  844. package/plugins/hiddenColumns/index.mjs +1 -0
  845. package/plugins/hiddenRows/contextMenuItem/hideRow.js +76 -0
  846. package/plugins/hiddenRows/contextMenuItem/hideRow.mjs +67 -0
  847. package/plugins/hiddenRows/contextMenuItem/showRow.js +124 -0
  848. package/plugins/hiddenRows/contextMenuItem/showRow.mjs +115 -0
  849. package/plugins/hiddenRows/hiddenRows.d.ts +21 -0
  850. package/plugins/hiddenRows/hiddenRows.js +612 -0
  851. package/plugins/hiddenRows/hiddenRows.mjs +604 -0
  852. package/plugins/hiddenRows/index.d.ts +1 -0
  853. package/plugins/hiddenRows/index.js +8 -0
  854. package/plugins/hiddenRows/index.mjs +1 -0
  855. package/plugins/index.d.ts +111 -0
  856. package/plugins/index.js +115 -0
  857. package/plugins/index.mjs +75 -0
  858. package/plugins/manualColumnFreeze/contextMenuItem/freezeColumn.js +58 -0
  859. package/plugins/manualColumnFreeze/contextMenuItem/freezeColumn.mjs +49 -0
  860. package/plugins/manualColumnFreeze/contextMenuItem/unfreezeColumn.js +58 -0
  861. package/plugins/manualColumnFreeze/contextMenuItem/unfreezeColumn.mjs +49 -0
  862. package/plugins/manualColumnFreeze/index.d.ts +1 -0
  863. package/plugins/manualColumnFreeze/index.js +8 -0
  864. package/plugins/manualColumnFreeze/index.mjs +1 -0
  865. package/plugins/manualColumnFreeze/manualColumnFreeze.d.ts +11 -0
  866. package/plugins/manualColumnFreeze/manualColumnFreeze.js +250 -0
  867. package/plugins/manualColumnFreeze/manualColumnFreeze.mjs +242 -0
  868. package/plugins/manualColumnMove/index.d.ts +1 -0
  869. package/plugins/manualColumnMove/index.js +8 -0
  870. package/plugins/manualColumnMove/index.mjs +1 -0
  871. package/plugins/manualColumnMove/manualColumnMove.d.ts +14 -0
  872. package/plugins/manualColumnMove/manualColumnMove.js +775 -0
  873. package/plugins/manualColumnMove/manualColumnMove.mjs +767 -0
  874. package/plugins/manualColumnMove/ui/_base.js +209 -0
  875. package/plugins/manualColumnMove/ui/_base.mjs +204 -0
  876. package/plugins/manualColumnMove/ui/backlight.js +60 -0
  877. package/plugins/manualColumnMove/ui/backlight.mjs +54 -0
  878. package/plugins/manualColumnMove/ui/guideline.js +60 -0
  879. package/plugins/manualColumnMove/ui/guideline.mjs +54 -0
  880. package/plugins/manualColumnResize/index.d.ts +1 -0
  881. package/plugins/manualColumnResize/index.js +8 -0
  882. package/plugins/manualColumnResize/index.mjs +1 -0
  883. package/plugins/manualColumnResize/manualColumnResize.d.ts +30 -0
  884. package/plugins/manualColumnResize/manualColumnResize.js +690 -0
  885. package/plugins/manualColumnResize/manualColumnResize.mjs +680 -0
  886. package/plugins/manualRowMove/index.d.ts +1 -0
  887. package/plugins/manualRowMove/index.js +8 -0
  888. package/plugins/manualRowMove/index.mjs +1 -0
  889. package/plugins/manualRowMove/manualRowMove.d.ts +14 -0
  890. package/plugins/manualRowMove/manualRowMove.js +757 -0
  891. package/plugins/manualRowMove/manualRowMove.mjs +749 -0
  892. package/plugins/manualRowMove/ui/_base.js +196 -0
  893. package/plugins/manualRowMove/ui/_base.mjs +191 -0
  894. package/plugins/manualRowMove/ui/backlight.js +60 -0
  895. package/plugins/manualRowMove/ui/backlight.mjs +54 -0
  896. package/plugins/manualRowMove/ui/guideline.js +60 -0
  897. package/plugins/manualRowMove/ui/guideline.mjs +54 -0
  898. package/plugins/manualRowResize/index.d.ts +1 -0
  899. package/plugins/manualRowResize/index.js +8 -0
  900. package/plugins/manualRowResize/index.mjs +1 -0
  901. package/plugins/manualRowResize/manualRowResize.d.ts +29 -0
  902. package/plugins/manualRowResize/manualRowResize.js +652 -0
  903. package/plugins/manualRowResize/manualRowResize.mjs +642 -0
  904. package/plugins/mergeCells/calculations/autofill.js +464 -0
  905. package/plugins/mergeCells/calculations/autofill.mjs +459 -0
  906. package/plugins/mergeCells/calculations/selection.js +204 -0
  907. package/plugins/mergeCells/calculations/selection.mjs +199 -0
  908. package/plugins/mergeCells/cellCoords.js +347 -0
  909. package/plugins/mergeCells/cellCoords.mjs +342 -0
  910. package/plugins/mergeCells/cellsCollection.js +344 -0
  911. package/plugins/mergeCells/cellsCollection.mjs +338 -0
  912. package/plugins/mergeCells/contextMenuItem/toggleMerge.js +55 -0
  913. package/plugins/mergeCells/contextMenuItem/toggleMerge.mjs +38 -0
  914. package/plugins/mergeCells/index.d.ts +1 -0
  915. package/plugins/mergeCells/index.js +8 -0
  916. package/plugins/mergeCells/index.mjs +1 -0
  917. package/plugins/mergeCells/mergeCells.d.ts +22 -0
  918. package/plugins/mergeCells/mergeCells.js +1290 -0
  919. package/plugins/mergeCells/mergeCells.mjs +1282 -0
  920. package/plugins/mergeCells/utils.js +30 -0
  921. package/plugins/mergeCells/utils.mjs +26 -0
  922. package/plugins/multiColumnSorting/domHelpers.js +44 -0
  923. package/plugins/multiColumnSorting/domHelpers.mjs +39 -0
  924. package/plugins/multiColumnSorting/index.d.ts +1 -0
  925. package/plugins/multiColumnSorting/index.js +8 -0
  926. package/plugins/multiColumnSorting/index.mjs +1 -0
  927. package/plugins/multiColumnSorting/multiColumnSorting.d.ts +8 -0
  928. package/plugins/multiColumnSorting/multiColumnSorting.js +336 -0
  929. package/plugins/multiColumnSorting/multiColumnSorting.mjs +329 -0
  930. package/plugins/multiColumnSorting/rootComparator.js +55 -0
  931. package/plugins/multiColumnSorting/rootComparator.mjs +51 -0
  932. package/plugins/multiColumnSorting/utils.js +16 -0
  933. package/plugins/multiColumnSorting/utils.mjs +12 -0
  934. package/plugins/multipleSelectionHandles/index.d.ts +1 -0
  935. package/plugins/multipleSelectionHandles/index.js +8 -0
  936. package/plugins/multipleSelectionHandles/index.mjs +1 -0
  937. package/plugins/multipleSelectionHandles/multipleSelectionHandles.d.ts +21 -0
  938. package/plugins/multipleSelectionHandles/multipleSelectionHandles.js +394 -0
  939. package/plugins/multipleSelectionHandles/multipleSelectionHandles.mjs +386 -0
  940. package/plugins/nestedHeaders/index.d.ts +1 -0
  941. package/plugins/nestedHeaders/index.js +8 -0
  942. package/plugins/nestedHeaders/index.mjs +1 -0
  943. package/plugins/nestedHeaders/nestedHeaders.d.ts +17 -0
  944. package/plugins/nestedHeaders/nestedHeaders.js +666 -0
  945. package/plugins/nestedHeaders/nestedHeaders.mjs +658 -0
  946. package/plugins/nestedHeaders/stateManager/headersTree.js +288 -0
  947. package/plugins/nestedHeaders/stateManager/headersTree.mjs +283 -0
  948. package/plugins/nestedHeaders/stateManager/index.js +417 -0
  949. package/plugins/nestedHeaders/stateManager/index.mjs +412 -0
  950. package/plugins/nestedHeaders/stateManager/matrixGenerator.js +102 -0
  951. package/plugins/nestedHeaders/stateManager/matrixGenerator.mjs +99 -0
  952. package/plugins/nestedHeaders/stateManager/nodeModifiers/collapse.js +98 -0
  953. package/plugins/nestedHeaders/stateManager/nodeModifiers/collapse.mjs +94 -0
  954. package/plugins/nestedHeaders/stateManager/nodeModifiers/expand.js +95 -0
  955. package/plugins/nestedHeaders/stateManager/nodeModifiers/expand.mjs +91 -0
  956. package/plugins/nestedHeaders/stateManager/nodeModifiers/hideColumn.js +54 -0
  957. package/plugins/nestedHeaders/stateManager/nodeModifiers/hideColumn.mjs +50 -0
  958. package/plugins/nestedHeaders/stateManager/nodeModifiers/index.js +40 -0
  959. package/plugins/nestedHeaders/stateManager/nodeModifiers/index.mjs +35 -0
  960. package/plugins/nestedHeaders/stateManager/nodeModifiers/showColumn.js +55 -0
  961. package/plugins/nestedHeaders/stateManager/nodeModifiers/showColumn.mjs +51 -0
  962. package/plugins/nestedHeaders/stateManager/nodeModifiers/utils/tree.js +61 -0
  963. package/plugins/nestedHeaders/stateManager/nodeModifiers/utils/tree.mjs +55 -0
  964. package/plugins/nestedHeaders/stateManager/settingsNormalizer.js +122 -0
  965. package/plugins/nestedHeaders/stateManager/settingsNormalizer.mjs +119 -0
  966. package/plugins/nestedHeaders/stateManager/sourceSettings.js +250 -0
  967. package/plugins/nestedHeaders/stateManager/sourceSettings.mjs +245 -0
  968. package/plugins/nestedHeaders/stateManager/utils.js +75 -0
  969. package/plugins/nestedHeaders/stateManager/utils.mjs +70 -0
  970. package/plugins/nestedHeaders/utils/ghostTable.js +167 -0
  971. package/plugins/nestedHeaders/utils/ghostTable.mjs +162 -0
  972. package/plugins/nestedRows/data/dataManager.js +809 -0
  973. package/plugins/nestedRows/data/dataManager.mjs +804 -0
  974. package/plugins/nestedRows/index.d.ts +1 -0
  975. package/plugins/nestedRows/index.js +8 -0
  976. package/plugins/nestedRows/index.mjs +1 -0
  977. package/plugins/nestedRows/nestedRows.d.ts +12 -0
  978. package/plugins/nestedRows/nestedRows.js +592 -0
  979. package/plugins/nestedRows/nestedRows.mjs +584 -0
  980. package/plugins/nestedRows/ui/_base.js +28 -0
  981. package/plugins/nestedRows/ui/_base.mjs +23 -0
  982. package/plugins/nestedRows/ui/collapsing.js +562 -0
  983. package/plugins/nestedRows/ui/collapsing.mjs +556 -0
  984. package/plugins/nestedRows/ui/contextMenu.js +147 -0
  985. package/plugins/nestedRows/ui/contextMenu.mjs +138 -0
  986. package/plugins/nestedRows/ui/headers.js +157 -0
  987. package/plugins/nestedRows/ui/headers.mjs +151 -0
  988. package/plugins/nestedRows/utils/rowMoveController.js +331 -0
  989. package/plugins/nestedRows/utils/rowMoveController.mjs +327 -0
  990. package/plugins/persistentState/index.d.ts +1 -0
  991. package/plugins/persistentState/index.js +8 -0
  992. package/plugins/persistentState/index.mjs +1 -0
  993. package/plugins/persistentState/persistentState.d.ts +13 -0
  994. package/plugins/persistentState/persistentState.js +207 -0
  995. package/plugins/persistentState/persistentState.mjs +199 -0
  996. package/plugins/persistentState/storage.js +138 -0
  997. package/plugins/persistentState/storage.mjs +133 -0
  998. package/plugins/registry.d.ts +9 -0
  999. package/plugins/registry.js +150 -0
  1000. package/plugins/registry.mjs +146 -0
  1001. package/plugins/search/index.d.ts +1 -0
  1002. package/plugins/search/index.js +8 -0
  1003. package/plugins/search/index.mjs +1 -0
  1004. package/plugins/search/search.d.ts +28 -0
  1005. package/plugins/search/search.js +377 -0
  1006. package/plugins/search/search.mjs +370 -0
  1007. package/plugins/touchScroll/index.d.ts +1 -0
  1008. package/plugins/touchScroll/index.js +8 -0
  1009. package/plugins/touchScroll/index.mjs +1 -0
  1010. package/plugins/touchScroll/touchScroll.d.ts +13 -0
  1011. package/plugins/touchScroll/touchScroll.js +250 -0
  1012. package/plugins/touchScroll/touchScroll.mjs +243 -0
  1013. package/plugins/trimRows/index.d.ts +1 -0
  1014. package/plugins/trimRows/index.js +8 -0
  1015. package/plugins/trimRows/index.mjs +1 -0
  1016. package/plugins/trimRows/trimRows.d.ts +17 -0
  1017. package/plugins/trimRows/trimRows.js +393 -0
  1018. package/plugins/trimRows/trimRows.mjs +386 -0
  1019. package/plugins/undoRedo/index.d.ts +1 -0
  1020. package/plugins/undoRedo/index.js +18 -0
  1021. package/plugins/undoRedo/index.mjs +2 -0
  1022. package/plugins/undoRedo/undoRedo.d.ts +49 -0
  1023. package/plugins/undoRedo/undoRedo.js +935 -0
  1024. package/plugins/undoRedo/undoRedo.mjs +928 -0
  1025. package/registry.d.ts +6 -0
  1026. package/registry.js +35 -0
  1027. package/registry.mjs +26 -0
  1028. package/renderers/autocompleteRenderer/autocompleteRenderer.d.ts +5 -0
  1029. package/renderers/autocompleteRenderer/autocompleteRenderer.js +59 -0
  1030. package/renderers/autocompleteRenderer/autocompleteRenderer.mjs +52 -0
  1031. package/renderers/autocompleteRenderer/index.d.ts +1 -0
  1032. package/renderers/autocompleteRenderer/index.js +7 -0
  1033. package/renderers/autocompleteRenderer/index.mjs +1 -0
  1034. package/renderers/base.d.ts +3 -0
  1035. package/renderers/baseRenderer/baseRenderer.d.ts +5 -0
  1036. package/renderers/baseRenderer/baseRenderer.js +46 -0
  1037. package/renderers/baseRenderer/baseRenderer.mjs +39 -0
  1038. package/renderers/baseRenderer/index.d.ts +1 -0
  1039. package/renderers/baseRenderer/index.js +7 -0
  1040. package/renderers/baseRenderer/index.mjs +1 -0
  1041. package/renderers/checkboxRenderer/checkboxRenderer.d.ts +5 -0
  1042. package/renderers/checkboxRenderer/checkboxRenderer.js +398 -0
  1043. package/renderers/checkboxRenderer/checkboxRenderer.mjs +391 -0
  1044. package/renderers/checkboxRenderer/index.d.ts +1 -0
  1045. package/renderers/checkboxRenderer/index.js +7 -0
  1046. package/renderers/checkboxRenderer/index.mjs +1 -0
  1047. package/renderers/htmlRenderer/htmlRenderer.d.ts +5 -0
  1048. package/renderers/htmlRenderer/htmlRenderer.js +25 -0
  1049. package/renderers/htmlRenderer/htmlRenderer.mjs +19 -0
  1050. package/renderers/htmlRenderer/index.d.ts +1 -0
  1051. package/renderers/htmlRenderer/index.js +7 -0
  1052. package/renderers/htmlRenderer/index.mjs +1 -0
  1053. package/renderers/index.d.ts +45 -0
  1054. package/renderers/index.js +48 -0
  1055. package/renderers/index.mjs +24 -0
  1056. package/renderers/numericRenderer/index.d.ts +1 -0
  1057. package/renderers/numericRenderer/index.js +7 -0
  1058. package/renderers/numericRenderer/index.mjs +1 -0
  1059. package/renderers/numericRenderer/numericRenderer.d.ts +5 -0
  1060. package/renderers/numericRenderer/numericRenderer.js +57 -0
  1061. package/renderers/numericRenderer/numericRenderer.mjs +50 -0
  1062. package/renderers/passwordRenderer/index.d.ts +1 -0
  1063. package/renderers/passwordRenderer/index.js +7 -0
  1064. package/renderers/passwordRenderer/index.mjs +1 -0
  1065. package/renderers/passwordRenderer/passwordRenderer.d.ts +5 -0
  1066. package/renderers/passwordRenderer/passwordRenderer.js +32 -0
  1067. package/renderers/passwordRenderer/passwordRenderer.mjs +26 -0
  1068. package/renderers/registry.d.ts +18 -0
  1069. package/renderers/registry.js +48 -0
  1070. package/renderers/registry.mjs +38 -0
  1071. package/renderers/textRenderer/index.d.ts +1 -0
  1072. package/renderers/textRenderer/index.js +7 -0
  1073. package/renderers/textRenderer/index.mjs +1 -0
  1074. package/renderers/textRenderer/textRenderer.d.ts +5 -0
  1075. package/renderers/textRenderer/textRenderer.js +48 -0
  1076. package/renderers/textRenderer/textRenderer.mjs +42 -0
  1077. package/renderers/timeRenderer/index.d.ts +1 -0
  1078. package/renderers/timeRenderer/index.js +7 -0
  1079. package/renderers/timeRenderer/index.mjs +1 -0
  1080. package/renderers/timeRenderer/timeRenderer.d.ts +5 -0
  1081. package/renderers/timeRenderer/timeRenderer.js +26 -0
  1082. package/renderers/timeRenderer/timeRenderer.mjs +20 -0
  1083. package/selection/highlight/constants.js +16 -0
  1084. package/selection/highlight/constants.mjs +6 -0
  1085. package/selection/highlight/highlight.js +330 -0
  1086. package/selection/highlight/highlight.mjs +325 -0
  1087. package/selection/highlight/types/activeHeader.js +38 -0
  1088. package/selection/highlight/types/activeHeader.mjs +32 -0
  1089. package/selection/highlight/types/area.js +49 -0
  1090. package/selection/highlight/types/area.mjs +43 -0
  1091. package/selection/highlight/types/cell.js +46 -0
  1092. package/selection/highlight/types/cell.mjs +40 -0
  1093. package/selection/highlight/types/customSelection.js +41 -0
  1094. package/selection/highlight/types/customSelection.mjs +35 -0
  1095. package/selection/highlight/types/fill.js +41 -0
  1096. package/selection/highlight/types/fill.mjs +35 -0
  1097. package/selection/highlight/types/header.js +49 -0
  1098. package/selection/highlight/types/header.mjs +43 -0
  1099. package/selection/highlight/types/index.js +43 -0
  1100. package/selection/highlight/types/index.mjs +39 -0
  1101. package/selection/highlight/visualSelection.js +277 -0
  1102. package/selection/highlight/visualSelection.mjs +272 -0
  1103. package/selection/index.d.ts +5 -0
  1104. package/selection/index.js +30 -0
  1105. package/selection/index.mjs +6 -0
  1106. package/selection/mouseEventHandler.js +135 -0
  1107. package/selection/mouseEventHandler.mjs +129 -0
  1108. package/selection/range.js +173 -0
  1109. package/selection/range.mjs +168 -0
  1110. package/selection/selection.js +802 -0
  1111. package/selection/selection.mjs +796 -0
  1112. package/selection/transformation.js +169 -0
  1113. package/selection/transformation.mjs +163 -0
  1114. package/selection/utils.js +256 -0
  1115. package/selection/utils.mjs +242 -0
  1116. package/settings.d.ts +210 -0
  1117. package/shortcuts/context.d.ts +20 -0
  1118. package/shortcuts/context.js +241 -0
  1119. package/shortcuts/context.mjs +236 -0
  1120. package/shortcuts/index.d.ts +1 -0
  1121. package/shortcuts/index.js +6 -0
  1122. package/shortcuts/index.mjs +1 -0
  1123. package/shortcuts/keyObserver.js +58 -0
  1124. package/shortcuts/keyObserver.mjs +54 -0
  1125. package/shortcuts/manager.d.ts +10 -0
  1126. package/shortcuts/manager.js +165 -0
  1127. package/shortcuts/manager.mjs +159 -0
  1128. package/shortcuts/recorder.js +165 -0
  1129. package/shortcuts/recorder.mjs +161 -0
  1130. package/shortcuts/utils.js +58 -0
  1131. package/shortcuts/utils.mjs +51 -0
  1132. package/tableView.js +1313 -0
  1133. package/tableView.mjs +1307 -0
  1134. package/translations/changesObservable/observable.js +175 -0
  1135. package/translations/changesObservable/observable.mjs +170 -0
  1136. package/translations/changesObservable/observer.js +100 -0
  1137. package/translations/changesObservable/observer.mjs +94 -0
  1138. package/translations/changesObservable/utils.js +50 -0
  1139. package/translations/changesObservable/utils.mjs +46 -0
  1140. package/translations/index.d.ts +1 -0
  1141. package/translations/index.js +29 -0
  1142. package/translations/index.mjs +4 -0
  1143. package/translations/indexMapper.d.ts +48 -0
  1144. package/translations/indexMapper.js +865 -0
  1145. package/translations/indexMapper.mjs +859 -0
  1146. package/translations/mapCollections/aggregatedCollection.js +139 -0
  1147. package/translations/mapCollections/aggregatedCollection.mjs +134 -0
  1148. package/translations/mapCollections/index.js +18 -0
  1149. package/translations/mapCollections/index.mjs +2 -0
  1150. package/translations/mapCollections/mapCollection.js +164 -0
  1151. package/translations/mapCollections/mapCollection.mjs +156 -0
  1152. package/translations/maps/hidingMap.js +63 -0
  1153. package/translations/maps/hidingMap.mjs +58 -0
  1154. package/translations/maps/index.js +59 -0
  1155. package/translations/maps/index.mjs +29 -0
  1156. package/translations/maps/indexMap.d.ts +10 -0
  1157. package/translations/maps/indexMap.js +203 -0
  1158. package/translations/maps/indexMap.mjs +197 -0
  1159. package/translations/maps/indexesSequence.js +82 -0
  1160. package/translations/maps/indexesSequence.mjs +77 -0
  1161. package/translations/maps/linkedPhysicalIndexToValueMap.js +216 -0
  1162. package/translations/maps/linkedPhysicalIndexToValueMap.mjs +211 -0
  1163. package/translations/maps/physicalIndexToValueMap.js +76 -0
  1164. package/translations/maps/physicalIndexToValueMap.mjs +71 -0
  1165. package/translations/maps/trimmingMap.js +63 -0
  1166. package/translations/maps/trimmingMap.mjs +58 -0
  1167. package/translations/maps/utils/actionsOnIndexes.js +42 -0
  1168. package/translations/maps/utils/actionsOnIndexes.mjs +37 -0
  1169. package/translations/maps/utils/index.js +28 -0
  1170. package/translations/maps/utils/index.mjs +22 -0
  1171. package/translations/maps/utils/indexesSequence.js +52 -0
  1172. package/translations/maps/utils/indexesSequence.mjs +47 -0
  1173. package/translations/maps/utils/physicallyIndexed.js +61 -0
  1174. package/translations/maps/utils/physicallyIndexed.mjs +56 -0
  1175. package/utils/dataStructures/linkedList.js +263 -0
  1176. package/utils/dataStructures/linkedList.mjs +258 -0
  1177. package/utils/dataStructures/priorityMap.js +106 -0
  1178. package/utils/dataStructures/priorityMap.mjs +99 -0
  1179. package/utils/dataStructures/queue.js +83 -0
  1180. package/utils/dataStructures/queue.mjs +78 -0
  1181. package/utils/dataStructures/stack.js +83 -0
  1182. package/utils/dataStructures/stack.mjs +78 -0
  1183. package/utils/dataStructures/tree.js +254 -0
  1184. package/utils/dataStructures/tree.mjs +246 -0
  1185. package/utils/dataStructures/uniqueMap.js +144 -0
  1186. package/utils/dataStructures/uniqueMap.mjs +140 -0
  1187. package/utils/dataStructures/uniqueSet.js +78 -0
  1188. package/utils/dataStructures/uniqueSet.mjs +74 -0
  1189. package/utils/ghostTable.js +536 -0
  1190. package/utils/ghostTable.mjs +531 -0
  1191. package/utils/interval.js +134 -0
  1192. package/utils/interval.mjs +129 -0
  1193. package/utils/parseTable.d.ts +5 -0
  1194. package/utils/parseTable.js +305 -0
  1195. package/utils/parseTable.mjs +299 -0
  1196. package/utils/rootInstance.js +48 -0
  1197. package/utils/rootInstance.mjs +38 -0
  1198. package/utils/samplesGenerator.js +210 -0
  1199. package/utils/samplesGenerator.mjs +205 -0
  1200. package/utils/staticRegister.js +92 -0
  1201. package/utils/staticRegister.mjs +86 -0
  1202. package/validators/autocompleteValidator/autocompleteValidator.d.ts +5 -0
  1203. package/validators/autocompleteValidator/autocompleteValidator.js +56 -0
  1204. package/validators/autocompleteValidator/autocompleteValidator.mjs +50 -0
  1205. package/validators/autocompleteValidator/index.d.ts +1 -0
  1206. package/validators/autocompleteValidator/index.js +7 -0
  1207. package/validators/autocompleteValidator/index.mjs +1 -0
  1208. package/validators/base.d.ts +6 -0
  1209. package/validators/dateValidator/dateValidator.d.ts +5 -0
  1210. package/validators/dateValidator/dateValidator.js +77 -0
  1211. package/validators/dateValidator/dateValidator.mjs +69 -0
  1212. package/validators/dateValidator/index.d.ts +1 -0
  1213. package/validators/dateValidator/index.js +8 -0
  1214. package/validators/dateValidator/index.mjs +1 -0
  1215. package/validators/index.d.ts +33 -0
  1216. package/validators/index.js +32 -0
  1217. package/validators/index.mjs +16 -0
  1218. package/validators/numericValidator/index.d.ts +1 -0
  1219. package/validators/numericValidator/index.js +7 -0
  1220. package/validators/numericValidator/index.mjs +1 -0
  1221. package/validators/numericValidator/numericValidator.d.ts +5 -0
  1222. package/validators/numericValidator/numericValidator.js +30 -0
  1223. package/validators/numericValidator/numericValidator.mjs +24 -0
  1224. package/validators/registry.d.ts +18 -0
  1225. package/validators/registry.js +48 -0
  1226. package/validators/registry.mjs +38 -0
  1227. package/validators/timeValidator/index.d.ts +1 -0
  1228. package/validators/timeValidator/index.js +7 -0
  1229. package/validators/timeValidator/index.mjs +1 -0
  1230. package/validators/timeValidator/timeValidator.d.ts +5 -0
  1231. package/validators/timeValidator/timeValidator.js +66 -0
  1232. package/validators/timeValidator/timeValidator.mjs +60 -0
package/pluginHooks.js ADDED
@@ -0,0 +1,2750 @@
1
+ "use strict";
2
+
3
+ require("core-js/modules/es.array.slice.js");
4
+ require("core-js/modules/es.object.freeze.js");
5
+ exports.__esModule = true;
6
+ exports.default = void 0;
7
+ require("core-js/modules/es.array.iterator.js");
8
+ require("core-js/modules/es.map.js");
9
+ require("core-js/modules/es.object.to-string.js");
10
+ require("core-js/modules/es.string.iterator.js");
11
+ require("core-js/modules/web.dom-collections.iterator.js");
12
+ require("core-js/modules/es.array.index-of.js");
13
+ require("core-js/modules/es.array.splice.js");
14
+ var _array = require("./helpers/array");
15
+ var _object = require("./helpers/object");
16
+ var _string = require("./helpers/string");
17
+ var _console = require("./helpers/console");
18
+ var _templateLiteralTag = require("./helpers/templateLiteralTag");
19
+ var _function = require("./helpers/function");
20
+ var _templateObject;
21
+ function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
22
+ function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
23
+ function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
24
+ function _taggedTemplateLiteral(strings, raw) { if (!raw) { raw = strings.slice(0); } return Object.freeze(Object.defineProperties(strings, { raw: { value: Object.freeze(raw) } })); }
25
+ /* eslint-disable jsdoc/require-description-complete-sentence */
26
+ /**
27
+ * @description
28
+ *
29
+ * ::: only-for javascript
30
+ * Handsontable events are the common interface that function in 2 ways: as __callbacks__ and as __hooks__.
31
+ * :::
32
+ *
33
+ * ::: only-for react
34
+ * This page lists all the **Handsontable hooks** – callbacks that let you react before or after an action occurs.
35
+ *
36
+ * Read more on the [Events and hooks](@/guides/getting-started/events-and-hooks.md) page.
37
+ * :::
38
+ *
39
+ * @example
40
+ *
41
+ * ::: only-for javascript
42
+ * ```js
43
+ * // using events as callbacks
44
+ * ...
45
+ * const hot1 = new Handsontable(document.getElementById('example1'), {
46
+ * afterChange: function(changes, source) {
47
+ * $.ajax({
48
+ * url: "save.php',
49
+ * data: change
50
+ * });
51
+ * }
52
+ * });
53
+ * ...
54
+ * ```
55
+ * :::
56
+ *
57
+ * ::: only-for react
58
+ * ```jsx
59
+ * <HotTable
60
+ * afterChange={(changes, source) => {
61
+ * fetch('save.php', {
62
+ * method: 'POST',
63
+ * headers: {
64
+ * 'Accept': 'application/json',
65
+ * 'Content-Type': 'application/json'
66
+ * },
67
+ * body: JSON.stringify(changes)
68
+ * });
69
+ * }}
70
+ * />
71
+ * :::
72
+ *
73
+ * ::: only-for javascript
74
+ * ```js
75
+ * // using events as plugin hooks
76
+ * ...
77
+ * const hot1 = new Handsontable(document.getElementById('example1'), {
78
+ * myPlugin: true
79
+ * });
80
+ *
81
+ * const hot2 = new Handsontable(document.getElementById('example2'), {
82
+ * myPlugin: false
83
+ * });
84
+ *
85
+ * // global hook
86
+ * Handsontable.hooks.add('afterChange', function() {
87
+ * // Fired twice - for hot1 and hot2
88
+ * if (this.getSettings().myPlugin) {
89
+ * // function body - will only run for hot1
90
+ * }
91
+ * });
92
+ *
93
+ * // local hook (has same effect as a callback)
94
+ * hot2.addHook('afterChange', function() {
95
+ * // function body - will only run in #example2
96
+ * });
97
+ * ```
98
+ * :::
99
+ *
100
+ * ::: only-for react
101
+ * ```jsx
102
+ * const hotRef1 = useRef(null);
103
+ * const hotRef2 = useRef(null);
104
+ *
105
+ * // Using events as plugin hooks:
106
+ * ...
107
+ *
108
+ * <HotTable
109
+ * ref={hotRef1}
110
+ * myPlugin={true}
111
+ * });
112
+ *
113
+ * <HotTable
114
+ * ref={hotRef2}
115
+ * myPlugin={false}
116
+ * });
117
+ *
118
+ * ...
119
+ *
120
+ * const hot2 = hotRef2.current.hotInstance;
121
+ * // local hook (has same effect as a callback)
122
+ * hot2.addHook('afterChange', function() {
123
+ * // function body - will only run in #example2
124
+ * });
125
+ *
126
+ * // global hook
127
+ * Handsontable.hooks.add('afterChange', function() {
128
+ * // Fired twice - for hot1 and hot2
129
+ * if (this.getSettings().myPlugin) {
130
+ * // function body - will only run for first instance
131
+ * }
132
+ * });
133
+ * :::
134
+ * ...
135
+ */
136
+
137
+ // @TODO: Move plugin description hooks to plugin?
138
+ var REGISTERED_HOOKS = [/* eslint-disable jsdoc/require-description-complete-sentence */
139
+ /**
140
+ * Fired after resetting a cell's meta. This happens when the {@link Core#updateSettings} method is called.
141
+ *
142
+ * @event Hooks#afterCellMetaReset
143
+ */
144
+ 'afterCellMetaReset',
145
+ /**
146
+ * Fired after one or more cells has been changed. The changes are triggered in any situation when the
147
+ * value is entered using an editor or changed using API (e.q setDataAtCell).
148
+ *
149
+ * __Note:__ For performance reasons, the `changes` array is null for `"loadData"` source.
150
+ *
151
+ * @event Hooks#afterChange
152
+ * @param {Array[]} changes 2D array containing information about each of the edited cells `[[row, prop, oldVal, newVal], ...]`. `row` is a visual row index.
153
+ * @param {string} [source] String that identifies source of hook call ([list of all available sources](@/guides/getting-started/events-and-hooks.md#definition-for-source-argument)).
154
+ * @example
155
+ * ::: only-for javascript
156
+ * ```js
157
+ * new Handsontable(element, {
158
+ * afterChange: (changes) => {
159
+ * changes?.forEach(([row, prop, oldValue, newValue]) => {
160
+ * // Some logic...
161
+ * });
162
+ * }
163
+ * })
164
+ * ```
165
+ * :::
166
+ *
167
+ * ::: only-for react
168
+ * ```jsx
169
+ * <HotTable
170
+ * afterChange={(changes, source) => {
171
+ * changes?.forEach(([row, prop, oldValue, newValue]) => {
172
+ * // Some logic...
173
+ * });
174
+ * }}
175
+ * />
176
+ * ```
177
+ * :::
178
+ */
179
+ 'afterChange',
180
+ /**
181
+ * Fired each time user opens {@link ContextMenu} and after setting up the Context Menu's default options. These options are a collection
182
+ * which user can select by setting an array of keys or an array of objects in {@link Options#contextMenu} option.
183
+ *
184
+ * @event Hooks#afterContextMenuDefaultOptions
185
+ * @param {Array} predefinedItems An array of objects containing information about the pre-defined Context Menu items.
186
+ */
187
+ 'afterContextMenuDefaultOptions',
188
+ /**
189
+ * Fired each time user opens {@link ContextMenu} plugin before setting up the Context Menu's items but after filtering these options by
190
+ * user (`contextMenu` option). This hook can by helpful to determine if user use specified menu item or to set up
191
+ * one of the menu item to by always visible.
192
+ *
193
+ * @event Hooks#beforeContextMenuSetItems
194
+ * @param {object[]} menuItems An array of objects containing information about to generated Context Menu items.
195
+ */
196
+ 'beforeContextMenuSetItems',
197
+ /**
198
+ * Fired by {@link DropdownMenu} plugin after setting up the Dropdown Menu's default options. These options are a
199
+ * collection which user can select by setting an array of keys or an array of objects in {@link Options#dropdownMenu}
200
+ * option.
201
+ *
202
+ * @event Hooks#afterDropdownMenuDefaultOptions
203
+ * @param {object[]} predefinedItems An array of objects containing information about the pre-defined Context Menu items.
204
+ */
205
+ 'afterDropdownMenuDefaultOptions',
206
+ /**
207
+ * Fired by {@link DropdownMenu} plugin before setting up the Dropdown Menu's items but after filtering these options
208
+ * by user (`dropdownMenu` option). This hook can by helpful to determine if user use specified menu item or to set
209
+ * up one of the menu item to by always visible.
210
+ *
211
+ * @event Hooks#beforeDropdownMenuSetItems
212
+ * @param {object[]} menuItems An array of objects containing information about to generated Dropdown Menu items.
213
+ */
214
+ 'beforeDropdownMenuSetItems',
215
+ /**
216
+ * Fired by {@link ContextMenu} plugin after hiding the Context Menu. This hook is fired when {@link Options#contextMenu}
217
+ * option is enabled.
218
+ *
219
+ * @event Hooks#afterContextMenuHide
220
+ * @param {object} context The Context Menu plugin instance.
221
+ */
222
+ 'afterContextMenuHide',
223
+ /**
224
+ * Fired by {@link ContextMenu} plugin before opening the Context Menu. This hook is fired when {@link Options#contextMenu}
225
+ * option is enabled.
226
+ *
227
+ * @event Hooks#beforeContextMenuShow
228
+ * @param {object} context The Context Menu instance.
229
+ */
230
+ 'beforeContextMenuShow',
231
+ /**
232
+ * Fired by {@link ContextMenu} plugin after opening the Context Menu. This hook is fired when {@link Options#contextMenu}
233
+ * option is enabled.
234
+ *
235
+ * @event Hooks#afterContextMenuShow
236
+ * @param {object} context The Context Menu plugin instance.
237
+ */
238
+ 'afterContextMenuShow',
239
+ /**
240
+ * Fired by {@link CopyPaste} plugin after reaching the copy limit while copying data. This hook is fired when
241
+ * {@link Options#copyPaste} option is enabled.
242
+ *
243
+ * @event Hooks#afterCopyLimit
244
+ * @param {number} selectedRows Count of selected copyable rows.
245
+ * @param {number} selectedColumns Count of selected copyable columns.
246
+ * @param {number} copyRowsLimit Current copy rows limit.
247
+ * @param {number} copyColumnsLimit Current copy columns limit.
248
+ */
249
+ 'afterCopyLimit',
250
+ /**
251
+ * Fired before created a new column.
252
+ *
253
+ * @event Hooks#beforeCreateCol
254
+ * @param {number} index Represents the visual index of first newly created column in the data source array.
255
+ * @param {number} amount Number of newly created columns in the data source array.
256
+ * @param {string} [source] String that identifies source of hook call
257
+ * ([list of all available sources](@/guides/getting-started/events-and-hooks.md#definition-for-source-argument)).
258
+ * @returns {*} If `false` then creating columns is cancelled.
259
+ * @example
260
+ * ::: only-for javascript
261
+ * ```js
262
+ * // Return `false` to cancel column inserting.
263
+ * new Handsontable(element, {
264
+ * beforeCreateCol: function(data, coords) {
265
+ * return false;
266
+ * }
267
+ * });
268
+ * ```
269
+ * :::
270
+ *
271
+ * ::: only-for react
272
+ * ```jsx
273
+ * // Return `false` to cancel column inserting.
274
+ * <HotTable
275
+ * beforeCreateCol={(data, coords) => {
276
+ * return false;
277
+ * }}
278
+ * />
279
+ * ```
280
+ * :::
281
+ */
282
+ 'beforeCreateCol',
283
+ /**
284
+ * Fired after created a new column.
285
+ *
286
+ * @event Hooks#afterCreateCol
287
+ * @param {number} index Represents the visual index of first newly created column in the data source.
288
+ * @param {number} amount Number of newly created columns in the data source.
289
+ * @param {string} [source] String that identifies source of hook call
290
+ * ([list of all available sources](@/guides/getting-started/events-and-hooks.md#definition-for-source-argument)).
291
+ */
292
+ 'afterCreateCol',
293
+ /**
294
+ * Fired before created a new row.
295
+ *
296
+ * @event Hooks#beforeCreateRow
297
+ * @param {number} index Represents the visual index of first newly created row in the data source array.
298
+ * @param {number} amount Number of newly created rows in the data source array.
299
+ * @param {string} [source] String that identifies source of hook call
300
+ * ([list of all available sources](@/guides/getting-started/events-and-hooks.md#definition-for-source-argument)).
301
+ * @returns {*|boolean} If false is returned the action is canceled.
302
+ */
303
+ 'beforeCreateRow',
304
+ /**
305
+ * Fired after created a new row.
306
+ *
307
+ * @event Hooks#afterCreateRow
308
+ * @param {number} index Represents the visual index of first newly created row in the data source array.
309
+ * @param {number} amount Number of newly created rows in the data source array.
310
+ * @param {string} [source] String that identifies source of hook call
311
+ * ([list of all available sources](@/guides/getting-started/events-and-hooks.md#definition-for-source-argument)).
312
+ */
313
+ 'afterCreateRow',
314
+ /**
315
+ * Fired after all selected cells are deselected.
316
+ *
317
+ * @event Hooks#afterDeselect
318
+ */
319
+ 'afterDeselect',
320
+ /**
321
+ * Fired after destroying the Handsontable instance.
322
+ *
323
+ * @event Hooks#afterDestroy
324
+ */
325
+ 'afterDestroy',
326
+ /**
327
+ * Hook fired after keydown event is handled.
328
+ *
329
+ * @event Hooks#afterDocumentKeyDown
330
+ * @param {Event} event A native `keydown` event object.
331
+ */
332
+ 'afterDocumentKeyDown',
333
+ /**
334
+ * Fired inside the Walkontable's selection `draw` method. Can be used to add additional class names to cells, depending on the current selection.
335
+ *
336
+ * @event Hooks#afterDrawSelection
337
+ * @param {number} currentRow Row index of the currently processed cell.
338
+ * @param {number} currentColumn Column index of the currently cell.
339
+ * @param {number[]} cornersOfSelection Array of the current selection in a form of `[startRow, startColumn, endRow, endColumn]`.
340
+ * @param {number|undefined} layerLevel Number indicating which layer of selection is currently processed.
341
+ * @since 0.38.1
342
+ * @returns {string|undefined} Can return a `String`, which will act as an additional `className` to be added to the currently processed cell.
343
+ */
344
+ 'afterDrawSelection',
345
+ /**
346
+ * Fired inside the Walkontable's `refreshSelections` method. Can be used to remove additional class names from all cells in the table.
347
+ *
348
+ * @event Hooks#beforeRemoveCellClassNames
349
+ * @since 0.38.1
350
+ * @returns {string[]|undefined} Can return an `Array` of `String`s. Each of these strings will act like class names to be removed from all the cells in the table.
351
+ */
352
+ 'beforeRemoveCellClassNames',
353
+ /**
354
+ * Fired after getting the cell settings.
355
+ *
356
+ * @event Hooks#afterGetCellMeta
357
+ * @param {number} row Visual row index.
358
+ * @param {number} column Visual column index.
359
+ * @param {object} cellProperties Object containing the cell properties.
360
+ */
361
+ 'afterGetCellMeta',
362
+ /**
363
+ * Fired after retrieving information about a column header and appending it to the table header.
364
+ *
365
+ * Since the 12.2 the hook is triggered with the 3rd `headerLevel` argument.
366
+ *
367
+ * @event Hooks#afterGetColHeader
368
+ * @param {number} column Visual column index.
369
+ * @param {HTMLTableCellElement} TH Header's TH element.
370
+ * @param {number} [headerLevel=0] The index of header level counting from the top (positive
371
+ * values counting from 0 to N).
372
+ */
373
+ 'afterGetColHeader',
374
+ /**
375
+ * Fired after retrieving information about a row header and appending it to the table header.
376
+ *
377
+ * @event Hooks#afterGetRowHeader
378
+ * @param {number} row Visual row index.
379
+ * @param {HTMLTableCellElement} TH Header's TH element.
380
+ */
381
+ 'afterGetRowHeader',
382
+ /**
383
+ * Fired after the Handsontable instance is initiated.
384
+ *
385
+ * @event Hooks#afterInit
386
+ */
387
+ 'afterInit',
388
+ /**
389
+ * Fired after Handsontable's [`data`](@/api/options.md#data)
390
+ * gets modified by the [`loadData()`](@/api/core.md#loaddata) method
391
+ * or the [`updateSettings()`](@/api/core.md#updatesettings) method.
392
+ *
393
+ * Read more:
394
+ * - [Binding to data](@/guides/getting-started/binding-to-data.md)
395
+ * - [Saving data](@/guides/getting-started/saving-data.md)
396
+ *
397
+ * @event Hooks#afterLoadData
398
+ * @param {Array} sourceData An [array of arrays](@/guides/getting-started/binding-to-data.md#array-of-arrays), or an [array of objects](@/guides/getting-started/binding-to-data.md#array-of-objects), that contains Handsontable's data
399
+ * @param {boolean} initialLoad A flag that indicates whether the data was loaded at Handsontable's initialization (`true`) or later (`false`)
400
+ * @param {string} source The source of the call
401
+ */
402
+ 'afterLoadData',
403
+ /**
404
+ * Fired after the [`updateData()`](@/api/core.md#updatedata) method
405
+ * modifies Handsontable's [`data`](@/api/options.md#data).
406
+ *
407
+ * Read more:
408
+ * - [Binding to data](@/guides/getting-started/binding-to-data.md)
409
+ * - [Saving data](@/guides/getting-started/saving-data.md)
410
+ *
411
+ * @event Hooks#afterUpdateData
412
+ * @since 11.1.0
413
+ * @param {Array} sourceData An [array of arrays](@/guides/getting-started/binding-to-data.md#array-of-arrays), or an [array of objects](@/guides/getting-started/binding-to-data.md#array-of-objects), that contains Handsontable's data
414
+ * @param {boolean} initialLoad A flag that indicates whether the data was loaded at Handsontable's initialization (`true`) or later (`false`)
415
+ * @param {string} source The source of the call
416
+ */
417
+ 'afterUpdateData',
418
+ /**
419
+ * Fired after a scroll event, which is identified as a momentum scroll (e.g. On an iPad).
420
+ *
421
+ * @event Hooks#afterMomentumScroll
422
+ */
423
+ 'afterMomentumScroll',
424
+ /**
425
+ * Fired after a `mousedown` event is triggered on the cell corner (the drag handle).
426
+ *
427
+ * @event Hooks#afterOnCellCornerMouseDown
428
+ * @param {Event} event `mousedown` event object.
429
+ */
430
+ 'afterOnCellCornerMouseDown',
431
+ /**
432
+ * Fired after a `dblclick` event is triggered on the cell corner (the drag handle).
433
+ *
434
+ * @event Hooks#afterOnCellCornerDblClick
435
+ * @param {Event} event `dblclick` event object.
436
+ */
437
+ 'afterOnCellCornerDblClick',
438
+ /**
439
+ * Fired after clicking on a cell or row/column header. In case the row/column header was clicked, the coordinate
440
+ * indexes are negative.
441
+ *
442
+ * For example clicking on the row header of cell (0, 0) results with `afterOnCellMouseDown` called
443
+ * with coordinates `{row: 0, col: -1}`.
444
+ *
445
+ * @event Hooks#afterOnCellMouseDown
446
+ * @param {Event} event `mousedown` event object.
447
+ * @param {CellCoords} coords Coordinates object containing the visual row and visual column indexes of the clicked cell.
448
+ * @param {HTMLTableCellElement} TD Cell's TD (or TH) element.
449
+ */
450
+ 'afterOnCellMouseDown',
451
+ /**
452
+ * Fired after clicking on a cell or row/column header. In case the row/column header was clicked, the coordinate
453
+ * indexes are negative.
454
+ *
455
+ * For example clicking on the row header of cell (0, 0) results with `afterOnCellMouseUp` called
456
+ * with coordinates `{row: 0, col: -1}`.
457
+ *
458
+ * @event Hooks#afterOnCellMouseUp
459
+ * @param {Event} event `mouseup` event object.
460
+ * @param {CellCoords} coords Coordinates object containing the visual row and visual column indexes of the clicked cell.
461
+ * @param {HTMLTableCellElement} TD Cell's TD (or TH) element.
462
+ */
463
+ 'afterOnCellMouseUp',
464
+ /**
465
+ * Fired after clicking right mouse button on a cell or row/column header.
466
+ *
467
+ * For example clicking on the row header of cell (0, 0) results with `afterOnCellContextMenu` called
468
+ * with coordinates `{row: 0, col: -1}`.
469
+ *
470
+ * @event Hooks#afterOnCellContextMenu
471
+ * @since 4.1.0
472
+ * @param {Event} event `contextmenu` event object.
473
+ * @param {CellCoords} coords Coordinates object containing the visual row and visual column indexes of the clicked cell.
474
+ * @param {HTMLTableCellElement} TD Cell's TD (or TH) element.
475
+ */
476
+ 'afterOnCellContextMenu',
477
+ /**
478
+ * Fired after hovering a cell or row/column header with the mouse cursor. In case the row/column header was
479
+ * hovered, the index is negative.
480
+ *
481
+ * For example, hovering over the row header of cell (0, 0) results with `afterOnCellMouseOver` called
482
+ * with coords `{row: 0, col: -1}`.
483
+ *
484
+ * @event Hooks#afterOnCellMouseOver
485
+ * @param {Event} event `mouseover` event object.
486
+ * @param {CellCoords} coords Hovered cell's visual coordinate object.
487
+ * @param {HTMLTableCellElement} TD Cell's TD (or TH) element.
488
+ */
489
+ 'afterOnCellMouseOver',
490
+ /**
491
+ * Fired after leaving a cell or row/column header with the mouse cursor.
492
+ *
493
+ * @event Hooks#afterOnCellMouseOut
494
+ * @param {Event} event `mouseout` event object.
495
+ * @param {CellCoords} coords Leaved cell's visual coordinate object.
496
+ * @param {HTMLTableCellElement} TD Cell's TD (or TH) element.
497
+ */
498
+ 'afterOnCellMouseOut',
499
+ /**
500
+ * Fired after one or more columns are removed.
501
+ *
502
+ * @event Hooks#afterRemoveCol
503
+ * @param {number} index Visual index of starter column.
504
+ * @param {number} amount An amount of removed columns.
505
+ * @param {number[]} physicalColumns An array of physical columns removed from the data source.
506
+ * @param {string} [source] String that identifies source of hook call
507
+ * ([list of all available sources](@/guides/getting-started/events-and-hooks.md#definition-for-source-argument)).
508
+ */
509
+ 'afterRemoveCol',
510
+ /**
511
+ * Fired after one or more rows are removed.
512
+ *
513
+ * @event Hooks#afterRemoveRow
514
+ * @param {number} index Visual index of starter row.
515
+ * @param {number} amount An amount of removed rows.
516
+ * @param {number[]} physicalRows An array of physical rows removed from the data source.
517
+ * @param {string} [source] String that identifies source of hook call
518
+ * ([list of all available sources](@/guides/getting-started/events-and-hooks.md#definition-for-source-argument)).
519
+ */
520
+ 'afterRemoveRow',
521
+ /**
522
+ * Fired before starting rendering the cell.
523
+ *
524
+ * @event Hooks#beforeRenderer
525
+ * @param {HTMLTableCellElement} TD Currently rendered cell's TD element.
526
+ * @param {number} row Visual row index.
527
+ * @param {number} column Visual column index.
528
+ * @param {string|number} prop Column property name or a column index, if datasource is an array of arrays.
529
+ * @param {*} value Value of the rendered cell.
530
+ * @param {object} cellProperties Object containing the cell's properties.
531
+ */
532
+ 'beforeRenderer',
533
+ /**
534
+ * Fired after finishing rendering the cell (after the renderer finishes).
535
+ *
536
+ * @event Hooks#afterRenderer
537
+ * @param {HTMLTableCellElement} TD Currently rendered cell's TD element.
538
+ * @param {number} row Visual row index.
539
+ * @param {number} column Visual column index.
540
+ * @param {string|number} prop Column property name or a column index, if datasource is an array of arrays.
541
+ * @param {*} value Value of the rendered cell.
542
+ * @param {object} cellProperties Object containing the cell's properties.
543
+ */
544
+ 'afterRenderer',
545
+ /**
546
+ * Fired after the horizontal scroll event.
547
+ *
548
+ * @event Hooks#afterScrollHorizontally
549
+ */
550
+ 'afterScrollHorizontally',
551
+ /**
552
+ * Fired after the vertical scroll event.
553
+ *
554
+ * @event Hooks#afterScrollVertically
555
+ */
556
+ 'afterScrollVertically',
557
+ /**
558
+ * Fired after one or more cells are selected (e.g. During mouse move).
559
+ *
560
+ * @event Hooks#afterSelection
561
+ * @param {number} row Selection start visual row index.
562
+ * @param {number} column Selection start visual column index.
563
+ * @param {number} row2 Selection end visual row index.
564
+ * @param {number} column2 Selection end visual column index.
565
+ * @param {object} preventScrolling A reference to the observable object with the `value` property.
566
+ * Property `preventScrolling.value` expects a boolean value that
567
+ * Handsontable uses to control scroll behavior after selection.
568
+ * @param {object} preventScrolling Object with `value` property where its value change will be observed.
569
+ * @param {number} selectionLayerLevel The number which indicates what selection layer is currently modified.
570
+ * @example
571
+ * ::: only-for javascript
572
+ * ```js
573
+ * new Handsontable(element, {
574
+ * afterSelection: (row, column, row2, column2, preventScrolling, selectionLayerLevel) => {
575
+ * // If set to `false` (default): when cell selection is outside the viewport,
576
+ * // Handsontable scrolls the viewport to cell selection's end corner.
577
+ * // If set to `true`: when cell selection is outside the viewport,
578
+ * // Handsontable doesn't scroll to cell selection's end corner.
579
+ * preventScrolling.value = true;
580
+ * }
581
+ * })
582
+ * ```
583
+ * :::
584
+ *
585
+ * ::: only-for react
586
+ * ```jsx
587
+ * <HotTable
588
+ * afterSelection={(row, column, row2, column2, preventScrolling, selectionLayerLevel) => {
589
+ * // If set to `false` (default): when cell selection is outside the viewport,
590
+ * // Handsontable scrolls the viewport to cell selection's end corner.
591
+ * // If set to `true`: when cell selection is outside the viewport,
592
+ * // Handsontable doesn't scroll to cell selection's end corner.
593
+ * preventScrolling.value = true;
594
+ * }}
595
+ * />
596
+ * ```
597
+ * :::
598
+ */
599
+ 'afterSelection',
600
+ /**
601
+ * Fired after one or more cells are selected.
602
+ *
603
+ * The `prop` and `prop2` arguments represent the source object property name instead of the column number.
604
+ *
605
+ * @event Hooks#afterSelectionByProp
606
+ * @param {number} row Selection start visual row index.
607
+ * @param {string} prop Selection start data source object property name.
608
+ * @param {number} row2 Selection end visual row index.
609
+ * @param {string} prop2 Selection end data source object property name.
610
+ * @param {object} preventScrolling Object with `value` property where its value change will be observed.
611
+ * @param {number} selectionLayerLevel The number which indicates what selection layer is currently modified.
612
+ * @example
613
+ * ```js
614
+ * ::: only-for javascript
615
+ * new Handsontable(element, {
616
+ * afterSelectionByProp: (row, column, row2, column2, preventScrolling, selectionLayerLevel) => {
617
+ * // setting if prevent scrolling after selection
618
+ * preventScrolling.value = true;
619
+ * }
620
+ * })
621
+ * ```
622
+ * :::
623
+ *
624
+ * ::: only-for react
625
+ * ```jsx
626
+ * <HotTable
627
+ * afterSelectionByProp={(row, column, row2, column2, preventScrolling, selectionLayerLevel) => {
628
+ * // setting if prevent scrolling after selection
629
+ * preventScrolling.value = true;
630
+ * }}
631
+ * />
632
+ * ```
633
+ * :::
634
+ */
635
+ 'afterSelectionByProp',
636
+ /**
637
+ * Fired after one or more cells are selected (e.g. On mouse up).
638
+ *
639
+ * @event Hooks#afterSelectionEnd
640
+ * @param {number} row Selection start visual row index.
641
+ * @param {number} column Selection start visual column index.
642
+ * @param {number} row2 Selection end visual row index.
643
+ * @param {number} column2 Selection end visual column index.
644
+ * @param {number} selectionLayerLevel The number which indicates what selection layer is currently modified.
645
+ */
646
+ 'afterSelectionEnd',
647
+ /**
648
+ * Fired after one or more cells are selected (e.g. On mouse up).
649
+ *
650
+ * The `prop` and `prop2` arguments represent the source object property name instead of the column number.
651
+ *
652
+ * @event Hooks#afterSelectionEndByProp
653
+ * @param {number} row Selection start visual row index.
654
+ * @param {string} prop Selection start data source object property index.
655
+ * @param {number} row2 Selection end visual row index.
656
+ * @param {string} prop2 Selection end data source object property index.
657
+ * @param {number} selectionLayerLevel The number which indicates what selection layer is currently modified.
658
+ */
659
+ 'afterSelectionEndByProp',
660
+ /**
661
+ * Fired after cell meta is changed.
662
+ *
663
+ * @event Hooks#afterSetCellMeta
664
+ * @param {number} row Visual row index.
665
+ * @param {number} column Visual column index.
666
+ * @param {string} key The updated meta key.
667
+ * @param {*} value The updated meta value.
668
+ */
669
+ 'afterSetCellMeta',
670
+ /**
671
+ * Fired after cell meta is removed.
672
+ *
673
+ * @event Hooks#afterRemoveCellMeta
674
+ * @param {number} row Visual row index.
675
+ * @param {number} column Visual column index.
676
+ * @param {string} key The removed meta key.
677
+ * @param {*} value Value which was under removed key of cell meta.
678
+ */
679
+ 'afterRemoveCellMeta',
680
+ /**
681
+ * Fired after cell data was changed.
682
+ *
683
+ * @event Hooks#afterSetDataAtCell
684
+ * @param {Array} changes An array of changes in format `[[row, column, oldValue, value], ...]`.
685
+ * @param {string} [source] String that identifies source of hook call
686
+ * ([list of all available sources](@/guides/getting-started/events-and-hooks.md#definition-for-source-argument)).
687
+ */
688
+ 'afterSetDataAtCell',
689
+ /**
690
+ * Fired after cell data was changed.
691
+ * Called only when `setDataAtRowProp` was executed.
692
+ *
693
+ * @event Hooks#afterSetDataAtRowProp
694
+ * @param {Array} changes An array of changes in format `[[row, prop, oldValue, value], ...]`.
695
+ * @param {string} [source] String that identifies source of hook call
696
+ * ([list of all available sources](@/guides/getting-started/events-and-hooks.md#definition-for-source-argument)).
697
+ */
698
+ 'afterSetDataAtRowProp',
699
+ /**
700
+ * Fired after cell source data was changed.
701
+ *
702
+ * @event Hooks#afterSetSourceDataAtCell
703
+ * @since 8.0.0
704
+ * @param {Array} changes An array of changes in format `[[row, column, oldValue, value], ...]`.
705
+ * @param {string} [source] String that identifies source of hook call.
706
+ */
707
+ 'afterSetSourceDataAtCell',
708
+ /**
709
+ * Fired after calling the `updateSettings` method.
710
+ *
711
+ * @event Hooks#afterUpdateSettings
712
+ * @param {object} newSettings New settings object.
713
+ */
714
+ 'afterUpdateSettings',
715
+ /**
716
+ * @description
717
+ * A plugin hook executed after validator function, only if validator function is defined.
718
+ * Validation result is the first parameter. This can be used to determinate if validation passed successfully or not.
719
+ *
720
+ * __Returning false from the callback will mark the cell as invalid__.
721
+ *
722
+ * @event Hooks#afterValidate
723
+ * @param {boolean} isValid `true` if valid, `false` if not.
724
+ * @param {*} value The value in question.
725
+ * @param {number} row Visual row index.
726
+ * @param {string|number} prop Property name / visual column index.
727
+ * @param {string} [source] String that identifies source of hook call
728
+ * ([list of all available sources](@/guides/getting-started/events-and-hooks.md#definition-for-source-argument)).
729
+ * @returns {undefined | boolean} If `false` the cell will be marked as invalid, `true` otherwise.
730
+ */
731
+ 'afterValidate',
732
+ /**
733
+ * Fired before successful change of language (when proper language code was set).
734
+ *
735
+ * @event Hooks#beforeLanguageChange
736
+ * @since 0.35.0
737
+ * @param {string} languageCode New language code.
738
+ */
739
+ 'beforeLanguageChange',
740
+ /**
741
+ * Fired after successful change of language (when proper language code was set).
742
+ *
743
+ * @event Hooks#afterLanguageChange
744
+ * @since 0.35.0
745
+ * @param {string} languageCode New language code.
746
+ */
747
+ 'afterLanguageChange',
748
+ /**
749
+ * Fired by {@link Autofill} plugin before populating the data in the autofill feature. This hook is fired when
750
+ * {@link Options#fillHandle} option is enabled.
751
+ *
752
+ * @event Hooks#beforeAutofill
753
+ * @param {Array[]} selectionData Data the autofill operation will start from.
754
+ * @param {CellRange} sourceRange The range values will be filled from.
755
+ * @param {CellRange} targetRange The range new values will be filled into.
756
+ * @param {string} direction Declares the direction of the autofill. Possible values: `up`, `down`, `left`, `right`.
757
+ *
758
+ * @returns {boolean|Array[]} If false, the operation is cancelled. If array of arrays, the returned data
759
+ * will be passed into `populateFromArray` instead of the default autofill
760
+ * algorithm's result.
761
+ */
762
+ 'beforeAutofill',
763
+ /**
764
+ * Fired by {@link Autofill} plugin after populating the data in the autofill feature. This hook is fired when
765
+ * {@link Options#fillHandle} option is enabled.
766
+ *
767
+ * @event Hooks#afterAutofill
768
+ * @since 8.0.0
769
+ * @param {Array[]} fillData The data that was used to fill the `targetRange`. If `beforeAutofill` was used
770
+ * and returned `[[]]`, this will be the same object that was returned from `beforeAutofill`.
771
+ * @param {CellRange} sourceRange The range values will be filled from.
772
+ * @param {CellRange} targetRange The range new values will be filled into.
773
+ * @param {string} direction Declares the direction of the autofill. Possible values: `up`, `down`, `left`, `right`.
774
+ */
775
+ 'afterAutofill',
776
+ /**
777
+ * Fired before aligning the cell contents.
778
+ *
779
+ * @event Hooks#beforeCellAlignment
780
+ * @param {object} stateBefore An object with class names defining the cell alignment.
781
+ * @param {CellRange[]} range An array of CellRange coordinates where the alignment will be applied.
782
+ * @param {string} type Type of the alignment - either `horizontal` or `vertical`.
783
+ * @param {string} alignmentClass String defining the alignment class added to the cell.
784
+ * Possible values:
785
+ * * `htLeft`
786
+ * * `htCenter`
787
+ * * `htRight`
788
+ * * `htJustify`
789
+ * * `htTop`
790
+ * * `htMiddle`
791
+ * * `htBottom`.
792
+ */
793
+ 'beforeCellAlignment',
794
+ /**
795
+ * Fired before one or more cells are changed.
796
+ *
797
+ * Use this hook to silently alter the user's changes before Handsontable re-renders.
798
+ *
799
+ * To ignore the user's changes, use a nullified array or return `false`.
800
+ *
801
+ * @event Hooks#beforeChange
802
+ * @param {Array[]} changes 2D array containing information about each of the edited cells `[[row, prop, oldVal, newVal], ...]`. `row` is a visual row index.
803
+ * @param {string} [source] String that identifies source of hook call
804
+ * ([list of all available sources](@/guides/getting-started/events-and-hooks.md#definition-for-source-argument)).
805
+ * @returns {undefined | boolean} If `false` all changes were cancelled, `true` otherwise.
806
+ * @example
807
+ * ::: only-for javascript
808
+ * ```js
809
+ * // to alter a single change, overwrite the value with `changes[i][3]`
810
+ * new Handsontable(element, {
811
+ * beforeChange: (changes, source) => {
812
+ * // [[row, prop, oldVal, newVal], ...]
813
+ * changes[0][3] = 10;
814
+ * }
815
+ * });
816
+ *
817
+ * // to ignore a single change, set `changes[i]` to `null`
818
+ * // or remove `changes[i]` from the array, by using `changes.splice(i, 1)`
819
+ * new Handsontable(element, {
820
+ * beforeChange: (changes, source) => {
821
+ * // [[row, prop, oldVal, newVal], ...]
822
+ * changes[0] = null;
823
+ * }
824
+ * });
825
+ *
826
+ * // to ignore all changes, return `false`
827
+ * // or set the array's length to 0, by using `changes.length = 0`
828
+ * new Handsontable(element, {
829
+ * beforeChange: (changes, source) => {
830
+ * // [[row, prop, oldVal, newVal], ...]
831
+ * return false;
832
+ * }
833
+ * });
834
+ * ```
835
+ * :::
836
+ *
837
+ * ::: only-for react
838
+ * ```jsx
839
+ * // to alter a single change, overwrite the desired value with `changes[i][3]`
840
+ * <HotTable
841
+ * beforeChange={(changes, source) => {
842
+ * // [[row, prop, oldVal, newVal], ...]
843
+ * changes[0][3] = 10;
844
+ * }}
845
+ * />
846
+ *
847
+ * // to ignore a single change, set `changes[i]` to `null`
848
+ * // or remove `changes[i]` from the array, by using changes.splice(i, 1).
849
+ * <HotTable
850
+ * beforeChange={(changes, source) => {
851
+ * // [[row, prop, oldVal, newVal], ...]
852
+ * changes[0] = null;
853
+ * }}
854
+ * />
855
+ *
856
+ * // to ignore all changes, return `false`
857
+ * // or set the array's length to 0 (`changes.length = 0`)
858
+ * <HotTable
859
+ * beforeChange={(changes, source) => {
860
+ * // [[row, prop, oldVal, newVal], ...]
861
+ * return false;
862
+ * }}
863
+ * />
864
+ * ```
865
+ * :::
866
+ */
867
+ 'beforeChange',
868
+ /**
869
+ * Fired right before rendering the changes.
870
+ *
871
+ * @event Hooks#beforeChangeRender
872
+ * @param {Array[]} changes Array in form of `[row, prop, oldValue, newValue]`.
873
+ * @param {string} [source] String that identifies source of hook call
874
+ * ([list of all available sources](@/guides/getting-started/events-and-hooks.md#definition-for-source-argument)).
875
+ */
876
+ 'beforeChangeRender',
877
+ /**
878
+ * Fired before drawing the borders.
879
+ *
880
+ * @event Hooks#beforeDrawBorders
881
+ * @param {Array} corners Array specifying the current selection borders.
882
+ * @param {string} borderClassName Specifies the border class name.
883
+ */
884
+ 'beforeDrawBorders',
885
+ /**
886
+ * Fired before getting cell settings.
887
+ *
888
+ * @event Hooks#beforeGetCellMeta
889
+ * @param {number} row Visual row index.
890
+ * @param {number} column Visual column index.
891
+ * @param {object} cellProperties Object containing the cell's properties.
892
+ */
893
+ 'beforeGetCellMeta',
894
+ /**
895
+ * Fired before cell meta is removed.
896
+ *
897
+ * @event Hooks#beforeRemoveCellMeta
898
+ * @param {number} row Visual row index.
899
+ * @param {number} column Visual column index.
900
+ * @param {string} key The removed meta key.
901
+ * @param {*} value Value which is under removed key of cell meta.
902
+ * @returns {*|boolean} If false is returned the action is canceled.
903
+ */
904
+ 'beforeRemoveCellMeta',
905
+ /**
906
+ * Fired before the Handsontable instance is initiated.
907
+ *
908
+ * @event Hooks#beforeInit
909
+ */
910
+ 'beforeInit',
911
+ /**
912
+ * Fired before the Walkontable instance is initiated.
913
+ *
914
+ * @event Hooks#beforeInitWalkontable
915
+ * @param {object} walkontableConfig Walkontable configuration object.
916
+ */
917
+ 'beforeInitWalkontable',
918
+ /**
919
+ * Fired before Handsontable's [`data`](@/api/options.md#data)
920
+ * gets modified by the [`loadData()`](@/api/core.md#loaddata) method
921
+ * or the [`updateSettings()`](@/api/core.md#updatesettings) method.
922
+ *
923
+ * Read more:
924
+ * - [Binding to data](@/guides/getting-started/binding-to-data.md)
925
+ * - [Saving data](@/guides/getting-started/saving-data.md)
926
+ *
927
+ * @event Hooks#beforeLoadData
928
+ * @since 8.0.0
929
+ * @param {Array} sourceData An [array of arrays](@/guides/getting-started/binding-to-data.md#array-of-arrays), or an [array of objects](@/guides/getting-started/binding-to-data.md#array-of-objects), that contains Handsontable's data
930
+ * @param {boolean} initialLoad A flag that indicates whether the data was loaded at Handsontable's initialization (`true`) or later (`false`)
931
+ * @param {string} source The source of the call
932
+ * @returns {Array} The returned array will be used as Handsontable's new dataset.
933
+ */
934
+ 'beforeLoadData',
935
+ /**
936
+ * Fired before the [`updateData()`](@/api/core.md#updatedata) method
937
+ * modifies Handsontable's [`data`](@/api/options.md#data).
938
+ *
939
+ * Read more:
940
+ * - [Binding to data](@/guides/getting-started/binding-to-data.md)
941
+ * - [Saving data](@/guides/getting-started/saving-data.md)
942
+ *
943
+ * @event Hooks#beforeUpdateData
944
+ * @since 11.1.0
945
+ * @param {Array} sourceData An [array of arrays](@/guides/getting-started/binding-to-data.md#array-of-arrays), or an [array of objects](@/guides/getting-started/binding-to-data.md#array-of-objects), that contains Handsontable's data
946
+ * @param {boolean} initialLoad A flag that indicates whether the data was loaded at Handsontable's initialization (`true`) or later (`false`)
947
+ * @param {string} source The source of the call
948
+ * @returns {Array} The returned array will be used as Handsontable's new dataset.
949
+ */
950
+ 'beforeUpdateData',
951
+ /**
952
+ * Hook fired before keydown event is handled. It can be used to stop default key bindings.
953
+ *
954
+ * __Note__: To prevent default behavior you need to call `false` in your `beforeKeyDown` handler.
955
+ *
956
+ * @event Hooks#beforeKeyDown
957
+ * @param {Event} event Original DOM event.
958
+ */
959
+ 'beforeKeyDown',
960
+ /**
961
+ * Fired after the user clicked a cell, but before all the calculations related with it.
962
+ *
963
+ * @event Hooks#beforeOnCellMouseDown
964
+ * @param {Event} event The `mousedown` event object.
965
+ * @param {CellCoords} coords Cell coords object containing the visual coordinates of the clicked cell.
966
+ * @param {HTMLTableCellElement} TD TD element.
967
+ * @param {object} controller An object with properties `row`, `column` and `cell`. Each property contains
968
+ * a boolean value that allows or disallows changing the selection for that particular area.
969
+ */
970
+ 'beforeOnCellMouseDown',
971
+ /**
972
+ * Fired after the user clicked a cell.
973
+ *
974
+ * @event Hooks#beforeOnCellMouseUp
975
+ * @param {Event} event The `mouseup` event object.
976
+ * @param {CellCoords} coords Cell coords object containing the visual coordinates of the clicked cell.
977
+ * @param {HTMLTableCellElement} TD TD element.
978
+ */
979
+ 'beforeOnCellMouseUp',
980
+ /**
981
+ * Fired after the user clicked a cell, but before all the calculations related with it.
982
+ *
983
+ * @event Hooks#beforeOnCellContextMenu
984
+ * @since 4.1.0
985
+ * @param {Event} event The `contextmenu` event object.
986
+ * @param {CellCoords} coords Cell coords object containing the visual coordinates of the clicked cell.
987
+ * @param {HTMLTableCellElement} TD TD element.
988
+ */
989
+ 'beforeOnCellContextMenu',
990
+ /**
991
+ * Fired after the user moved cursor over a cell, but before all the calculations related with it.
992
+ *
993
+ * @event Hooks#beforeOnCellMouseOver
994
+ * @param {Event} event The `mouseover` event object.
995
+ * @param {CellCoords} coords CellCoords object containing the visual coordinates of the clicked cell.
996
+ * @param {HTMLTableCellElement} TD TD element.
997
+ * @param {object} controller An object with properties `row`, `column` and `cell`. Each property contains
998
+ * a boolean value that allows or disallows changing the selection for that particular area.
999
+ */
1000
+ 'beforeOnCellMouseOver',
1001
+ /**
1002
+ * Fired after the user moved cursor out from a cell, but before all the calculations related with it.
1003
+ *
1004
+ * @event Hooks#beforeOnCellMouseOut
1005
+ * @param {Event} event The `mouseout` event object.
1006
+ * @param {CellCoords} coords CellCoords object containing the visual coordinates of the leaved cell.
1007
+ * @param {HTMLTableCellElement} TD TD element.
1008
+ */
1009
+ 'beforeOnCellMouseOut',
1010
+ /**
1011
+ * Fired before one or more columns are about to be removed.
1012
+ *
1013
+ * @event Hooks#beforeRemoveCol
1014
+ * @param {number} index Visual index of starter column.
1015
+ * @param {number} amount Amount of columns to be removed.
1016
+ * @param {number[]} physicalColumns An array of physical columns removed from the data source.
1017
+ * @param {string} [source] String that identifies source of hook call
1018
+ * ([list of all available sources](@/guides/getting-started/events-and-hooks.md#definition-for-source-argument)).
1019
+ * @returns {*|boolean} If false is returned the action is canceled.
1020
+ */
1021
+ 'beforeRemoveCol',
1022
+ /**
1023
+ * Fired when one or more rows are about to be removed.
1024
+ *
1025
+ * @event Hooks#beforeRemoveRow
1026
+ * @param {number} index Visual index of starter row.
1027
+ * @param {number} amount Amount of rows to be removed.
1028
+ * @param {number[]} physicalRows An array of physical rows removed from the data source.
1029
+ * @param {string} [source] String that identifies source of hook call
1030
+ * ([list of all available sources](@/guides/getting-started/events-and-hooks.md#definition-for-source-argument)).
1031
+ * @returns {*|boolean} If false is returned the action is canceled.
1032
+ */
1033
+ 'beforeRemoveRow',
1034
+ /**
1035
+ * Fired before Handsontable's view-rendering engine is rendered.
1036
+ *
1037
+ * __Note:__ In Handsontable 9.x and earlier, the `beforeViewRender` hook was named `beforeRender`.
1038
+ *
1039
+ * @event Hooks#beforeViewRender
1040
+ * @since 10.0.0
1041
+ * @param {boolean} isForced If set to `true`, the rendering gets triggered by a change of settings, a change of
1042
+ * data, or a logic that needs a full Handsontable render cycle.
1043
+ * If set to `false`, the rendering gets triggered by scrolling or moving the selection.
1044
+ * @param {object} skipRender Object with `skipRender` property, if it is set to `true ` the next rendering cycle will be skipped.
1045
+ */
1046
+ 'beforeViewRender',
1047
+ /**
1048
+ * Fired after Handsontable's view-rendering engine is rendered,
1049
+ * but before redrawing the selection borders and before scroll syncing.
1050
+ *
1051
+ * __Note:__ In Handsontable 9.x and earlier, the `afterViewRender` hook was named `afterRender`.
1052
+ *
1053
+ * @event Hooks#afterViewRender
1054
+ * @since 10.0.0
1055
+ * @param {boolean} isForced If set to `true`, the rendering gets triggered by a change of settings, a change of
1056
+ * data, or a logic that needs a full Handsontable render cycle.
1057
+ * If set to `false`, the rendering gets triggered by scrolling or moving the selection.
1058
+ */
1059
+ 'afterViewRender',
1060
+ /**
1061
+ * Fired before Handsontable's view-rendering engine updates the view.
1062
+ *
1063
+ * The `beforeRender` event is fired right after the Handsontable
1064
+ * business logic is executed and right before the rendering engine starts calling
1065
+ * the Core logic, renderers, cell meta objects etc. to update the view.
1066
+ *
1067
+ * @event Hooks#beforeRender
1068
+ * @param {boolean} isForced If set to `true`, the rendering gets triggered by a change of settings, a change of
1069
+ * data, or a logic that needs a full Handsontable render cycle.
1070
+ * If set to `false`, the rendering gets triggered by scrolling or moving the selection.
1071
+ */
1072
+ 'beforeRender',
1073
+ /**
1074
+ * Fired after Handsontable's view-rendering engine updates the view.
1075
+ *
1076
+ * @event Hooks#afterRender
1077
+ * @param {boolean} isForced If set to `true`, the rendering gets triggered by a change of settings, a change of
1078
+ * data, or a logic that needs a full Handsontable render cycle.
1079
+ * If set to `false`, the rendering gets triggered by scrolling or moving the selection.
1080
+ */
1081
+ 'afterRender',
1082
+ /**
1083
+ * Fired before cell meta is changed.
1084
+ *
1085
+ * @event Hooks#beforeSetCellMeta
1086
+ * @since 8.0.0
1087
+ * @param {number} row Visual row index.
1088
+ * @param {number} column Visual column index.
1089
+ * @param {string} key The updated meta key.
1090
+ * @param {*} value The updated meta value.
1091
+ * @returns {boolean|undefined} If false is returned the action is canceled.
1092
+ */
1093
+ 'beforeSetCellMeta',
1094
+ /**
1095
+ * Fired before setting range is started but not finished yet.
1096
+ *
1097
+ * @event Hooks#beforeSetRangeStartOnly
1098
+ * @param {CellCoords} coords CellCoords instance.
1099
+ */
1100
+ 'beforeSetRangeStartOnly',
1101
+ /**
1102
+ * Fired before setting range is started.
1103
+ *
1104
+ * @event Hooks#beforeSetRangeStart
1105
+ * @param {CellCoords} coords CellCoords instance.
1106
+ */
1107
+ 'beforeSetRangeStart',
1108
+ /**
1109
+ * Fired before setting range is ended.
1110
+ *
1111
+ * @event Hooks#beforeSetRangeEnd
1112
+ * @param {CellCoords} coords CellCoords instance.
1113
+ */
1114
+ 'beforeSetRangeEnd',
1115
+ /**
1116
+ * Fired before the logic of handling a touch scroll, when user started scrolling on a touch-enabled device.
1117
+ *
1118
+ * @event Hooks#beforeTouchScroll
1119
+ */
1120
+ 'beforeTouchScroll',
1121
+ /**
1122
+ * Fired before cell validation, only if validator function is defined. This can be used to manipulate the value
1123
+ * of changed cell before it is applied to the validator function.
1124
+ *
1125
+ * __Note:__ this will not affect values of changes. This will change value *ONLY* for validation.
1126
+ *
1127
+ * @event Hooks#beforeValidate
1128
+ * @param {*} value Value of the cell.
1129
+ * @param {number} row Visual row index.
1130
+ * @param {string|number} prop Property name / column index.
1131
+ * @param {string} [source] String that identifies source of hook call
1132
+ * ([list of all available sources](@/guides/getting-started/events-and-hooks.md#definition-for-source-argument)).
1133
+ */
1134
+ 'beforeValidate',
1135
+ /**
1136
+ * Fired before cell value is rendered into the DOM (through renderer function). This can be used to manipulate the
1137
+ * value which is passed to the renderer without modifying the renderer itself.
1138
+ *
1139
+ * @event Hooks#beforeValueRender
1140
+ * @param {*} value Cell value to render.
1141
+ * @param {object} cellProperties An object containing the cell properties.
1142
+ */
1143
+ 'beforeValueRender',
1144
+ /**
1145
+ * Fired after Handsontable instance is constructed (using `new` operator).
1146
+ *
1147
+ * @event Hooks#construct
1148
+ */
1149
+ 'construct',
1150
+ /**
1151
+ * Fired after Handsontable instance is initiated but before table is rendered.
1152
+ *
1153
+ * @event Hooks#init
1154
+ */
1155
+ 'init',
1156
+ /**
1157
+ * Fired when a column header index is about to be modified by a callback function.
1158
+ *
1159
+ * @event Hooks#modifyColHeader
1160
+ * @param {number} column Visual column header index.
1161
+ */
1162
+ 'modifyColHeader',
1163
+ /**
1164
+ * Fired when a column width is about to be modified by a callback function.
1165
+ *
1166
+ * @event Hooks#modifyColWidth
1167
+ * @param {number} width Current column width.
1168
+ * @param {number} column Visual column index.
1169
+ */
1170
+ 'modifyColWidth',
1171
+ /**
1172
+ * Fired when a row header index is about to be modified by a callback function.
1173
+ *
1174
+ * @event Hooks#modifyRowHeader
1175
+ * @param {number} row Visual row header index.
1176
+ */
1177
+ 'modifyRowHeader',
1178
+ /**
1179
+ * Fired when a row height is about to be modified by a callback function.
1180
+ *
1181
+ * @event Hooks#modifyRowHeight
1182
+ * @param {number} height Row height.
1183
+ * @param {number} row Visual row index.
1184
+ */
1185
+ 'modifyRowHeight',
1186
+ /**
1187
+ * Fired when a data was retrieved or modified.
1188
+ *
1189
+ * @event Hooks#modifyData
1190
+ * @param {number} row Physical row height.
1191
+ * @param {number} column Physical column index.
1192
+ * @param {object} valueHolder Object which contains original value which can be modified by overwriting `.value` property.
1193
+ * @param {string} ioMode String which indicates for what operation hook is fired (`get` or `set`).
1194
+ */
1195
+ 'modifyData',
1196
+ /**
1197
+ * Fired when a data was retrieved or modified from the source data set.
1198
+ *
1199
+ * @event Hooks#modifySourceData
1200
+ * @since 8.0.0
1201
+ * @param {number} row Physical row index.
1202
+ * @param {number} column Physical column index.
1203
+ * @param {object} valueHolder Object which contains original value which can be modified by overwriting `.value` property.
1204
+ * @param {string} ioMode String which indicates for what operation hook is fired (`get` or `set`).
1205
+ */
1206
+ 'modifySourceData',
1207
+ /**
1208
+ * Fired when a data was retrieved or modified.
1209
+ *
1210
+ * @event Hooks#modifyRowData
1211
+ * @param {number} row Physical row index.
1212
+ */
1213
+ 'modifyRowData',
1214
+ /**
1215
+ * Used to modify the cell coordinates when using the `getCell` method, opening editor, getting value from the editor
1216
+ * and saving values from the closed editor.
1217
+ *
1218
+ * @event Hooks#modifyGetCellCoords
1219
+ * @since 0.36.0
1220
+ * @param {number} row Visual row index.
1221
+ * @param {number} column Visual column index.
1222
+ * @param {boolean} topmost If set to `true`, it returns the TD element from the topmost overlay. For example,
1223
+ * if the wanted cell is in the range of fixed rows, it will return a TD element
1224
+ * from the `top` overlay.
1225
+ * @returns {undefined|number[]}
1226
+ */
1227
+ 'modifyGetCellCoords',
1228
+ /**
1229
+ * Allows modify the visual row index that is used to retrieve the row header element (TH) before it's
1230
+ * highlighted (proper CSS class names are added). Modifying the visual row index allows building a custom
1231
+ * implementation of the nested headers feature or other features that require highlighting other DOM
1232
+ * elements than that the rendering engine, by default, would have highlighted.
1233
+ *
1234
+ * @event Hooks#beforeHighlightingRowHeader
1235
+ * @since 8.4.0
1236
+ * @param {number} row Visual row index.
1237
+ * @param {number} headerLevel Column header level (0 = most distant to the table).
1238
+ * @param {object} highlightMeta An object that contains additional information about processed selection.
1239
+ * @returns {number|undefined}
1240
+ */
1241
+ 'beforeHighlightingRowHeader',
1242
+ /**
1243
+ * Allows modify the visual column index that is used to retrieve the column header element (TH) before it's
1244
+ * highlighted (proper CSS class names are added). Modifying the visual column index allows building a custom
1245
+ * implementation of the nested headers feature or other features that require highlighting other DOM
1246
+ * elements than that the rendering engine, by default, would have highlighted.
1247
+ *
1248
+ * @event Hooks#beforeHighlightingColumnHeader
1249
+ * @since 8.4.0
1250
+ * @param {number} column Visual column index.
1251
+ * @param {number} headerLevel Row header level (0 = most distant to the table).
1252
+ * @param {object} highlightMeta An object that contains additional information about processed selection.
1253
+ * @returns {number|undefined}
1254
+ */
1255
+ 'beforeHighlightingColumnHeader',
1256
+ /**
1257
+ * Fired by {@link PersistentState} plugin, after loading value, saved under given key, from browser local storage.
1258
+ *
1259
+ * The `persistentStateLoad` hook is fired even when the {@link Options#persistentState} option is disabled.
1260
+ *
1261
+ * @event Hooks#persistentStateLoad
1262
+ * @param {string} key Key.
1263
+ * @param {object} valuePlaceholder Object containing the loaded value under `valuePlaceholder.value` (if no value have been saved, `value` key will be undefined).
1264
+ */
1265
+ 'persistentStateLoad',
1266
+ /**
1267
+ * Fired by {@link PersistentState} plugin after resetting data from local storage. If no key is given, all values associated with table will be cleared.
1268
+ * This hook is fired when {@link Options#persistentState} option is enabled.
1269
+ *
1270
+ * @event Hooks#persistentStateReset
1271
+ * @param {string} [key] Key.
1272
+ */
1273
+ 'persistentStateReset',
1274
+ /**
1275
+ * Fired by {@link PersistentState} plugin, after saving value under given key in browser local storage.
1276
+ *
1277
+ * The `persistentStateSave` hook is fired even when the {@link Options#persistentState} option is disabled.
1278
+ *
1279
+ * @event Hooks#persistentStateSave
1280
+ * @param {string} key Key.
1281
+ * @param {Mixed} value Value to save.
1282
+ */
1283
+ 'persistentStateSave',
1284
+ /**
1285
+ * Fired by {@link ColumnSorting} and {@link MultiColumnSorting} plugins before sorting the column. If you return `false` value inside callback for hook, then sorting
1286
+ * will be not applied by the Handsontable (useful for server-side sorting).
1287
+ *
1288
+ * This hook is fired when {@link Options#columnSorting} or {@link Options#multiColumnSorting} option is enabled.
1289
+ *
1290
+ * @event Hooks#beforeColumnSort
1291
+ * @param {Array} currentSortConfig Current sort configuration (for all sorted columns).
1292
+ * @param {Array} destinationSortConfigs Destination sort configuration (for all sorted columns).
1293
+ * @returns {boolean | undefined} If `false` the column will not be sorted, `true` otherwise.
1294
+ */
1295
+ 'beforeColumnSort',
1296
+ /**
1297
+ * Fired by {@link ColumnSorting} and {@link MultiColumnSorting} plugins after sorting the column. This hook is fired when {@link Options#columnSorting}
1298
+ * or {@link Options#multiColumnSorting} option is enabled.
1299
+ *
1300
+ * @event Hooks#afterColumnSort
1301
+ * @param {Array} currentSortConfig Current sort configuration (for all sorted columns).
1302
+ * @param {Array} destinationSortConfigs Destination sort configuration (for all sorted columns).
1303
+ */
1304
+ 'afterColumnSort',
1305
+ /**
1306
+ * Fired by {@link Autofill} plugin after setting range of autofill. This hook is fired when {@link Options#fillHandle}
1307
+ * option is enabled.
1308
+ *
1309
+ * @event Hooks#modifyAutofillRange
1310
+ * @param {Array} startArea Array of visual coordinates of the starting point for the drag-down operation (`[startRow, startColumn, endRow, endColumn]`).
1311
+ * @param {Array} entireArea Array of visual coordinates of the entire area of the drag-down operation (`[startRow, startColumn, endRow, endColumn]`).
1312
+ */
1313
+ 'modifyAutofillRange',
1314
+ /**
1315
+ * Fired to allow modifying the copyable range with a callback function.
1316
+ *
1317
+ * @event Hooks#modifyCopyableRange
1318
+ * @param {Array[]} copyableRanges Array of objects defining copyable cells.
1319
+ */
1320
+ 'modifyCopyableRange',
1321
+ /**
1322
+ * Fired by {@link CopyPaste} plugin before copying the values into clipboard and before clearing values of
1323
+ * the selected cells. This hook is fired when {@link Options#copyPaste} option is enabled.
1324
+ *
1325
+ * @event Hooks#beforeCut
1326
+ * @param {Array[]} data An array of arrays which contains data to cut.
1327
+ * @param {object[]} coords An array of objects with ranges of the visual indexes (`startRow`, `startCol`, `endRow`, `endCol`)
1328
+ * which will be cut out.
1329
+ * @returns {*} If returns `false` then operation of the cutting out is canceled.
1330
+ * @example
1331
+ * ::: only-for javascript
1332
+ * ```js
1333
+ * // To disregard a single row, remove it from the array using data.splice(i, 1).
1334
+ * new Handsontable(element, {
1335
+ * beforeCut: function(data, coords) {
1336
+ * // data -> [[1, 2, 3], [4, 5, 6]]
1337
+ * data.splice(0, 1);
1338
+ * // data -> [[4, 5, 6]]
1339
+ * // coords -> [{startRow: 0, startCol: 0, endRow: 1, endCol: 2}]
1340
+ * }
1341
+ * });
1342
+ * // To cancel a cutting action, just return `false`.
1343
+ * new Handsontable(element, {
1344
+ * beforeCut: function(data, coords) {
1345
+ * return false;
1346
+ * }
1347
+ * });
1348
+ * ```
1349
+ * :::
1350
+ *
1351
+ * ::: only-for react
1352
+ * ```jsx
1353
+ * // To disregard a single row, remove it from the array using data.splice(i, 1).
1354
+ * <HotTable
1355
+ * beforeCut={(data, coords) => {
1356
+ * // data -> [[1, 2, 3], [4, 5, 6]]
1357
+ * data.splice(0, 1);
1358
+ * // data -> [[4, 5, 6]]
1359
+ * // coords -> [{startRow: 0, startCol: 0, endRow: 1, endCol: 2}]
1360
+ * }}
1361
+ * />
1362
+ * // To cancel a cutting action, just return `false`.
1363
+ * <HotTable
1364
+ * beforeCut={(data, coords) => {
1365
+ * return false;
1366
+ * }}
1367
+ * />
1368
+ * ```
1369
+ * :::
1370
+ */
1371
+ 'beforeCut',
1372
+ /**
1373
+ * Fired by {@link CopyPaste} plugin after data was cut out from the table. This hook is fired when
1374
+ * {@link Options#copyPaste} option is enabled.
1375
+ *
1376
+ * @event Hooks#afterCut
1377
+ * @param {Array[]} data An array of arrays which contains the cutted out data.
1378
+ * @param {object[]} coords An array of objects with ranges of the visual indexes (`startRow`, `startCol`, `endRow`, `endCol`)
1379
+ * which was cut out.
1380
+ */
1381
+ 'afterCut',
1382
+ /**
1383
+ * Fired before values are copied into clipboard.
1384
+ *
1385
+ * @event Hooks#beforeCopy
1386
+ * @param {Array[]} data An array of arrays which contains data to copied.
1387
+ * @param {object[]} coords An array of objects with ranges of the visual indexes (`startRow`, `startCol`, `endRow`, `endCol`)
1388
+ * which will copied.
1389
+ * @returns {*} If returns `false` then copying is canceled.
1390
+ *
1391
+ * @example
1392
+ * ::: only-for javascript
1393
+ * ```js
1394
+ * // To disregard a single row, remove it from array using data.splice(i, 1).
1395
+ * ...
1396
+ * new Handsontable(document.getElementById('example'), {
1397
+ * beforeCopy: (data, coords) => {
1398
+ * // data -> [[1, 2, 3], [4, 5, 6]]
1399
+ * data.splice(0, 1);
1400
+ * // data -> [[4, 5, 6]]
1401
+ * // coords -> [{startRow: 0, startCol: 0, endRow: 1, endCol: 2}]
1402
+ * }
1403
+ * });
1404
+ * ...
1405
+ *
1406
+ * // To cancel copying, return false from the callback.
1407
+ * ...
1408
+ * new Handsontable(document.getElementById('example'), {
1409
+ * beforeCopy: (data, coords) => {
1410
+ * return false;
1411
+ * }
1412
+ * });
1413
+ * ...
1414
+ * ```
1415
+ * :::
1416
+ *
1417
+ * ::: only-for react
1418
+ * ```jsx
1419
+ * // To disregard a single row, remove it from array using data.splice(i, 1).
1420
+ * ...
1421
+ * <HotTable
1422
+ * beforeCopy={(data, coords) => {
1423
+ * // data -> [[1, 2, 3], [4, 5, 6]]
1424
+ * data.splice(0, 1);
1425
+ * // data -> [[4, 5, 6]]
1426
+ * // coords -> [{startRow: 0, startCol: 0, endRow: 1, endCol: 2}]
1427
+ * }}
1428
+ * />
1429
+ * ...
1430
+ *
1431
+ * // To cancel copying, return false from the callback.
1432
+ * ...
1433
+ * <HotTable
1434
+ * beforeCopy={(data, coords) => {
1435
+ * return false;
1436
+ * }}
1437
+ * />
1438
+ * ...
1439
+ * ```
1440
+ * :::
1441
+ */
1442
+ 'beforeCopy',
1443
+ /**
1444
+ * Fired by {@link CopyPaste} plugin after data are pasted into table. This hook is fired when {@link Options#copyPaste}
1445
+ * option is enabled.
1446
+ *
1447
+ * @event Hooks#afterCopy
1448
+ * @param {Array[]} data An array of arrays which contains the copied data.
1449
+ * @param {object[]} coords An array of objects with ranges of the visual indexes (`startRow`, `startCol`, `endRow`, `endCol`)
1450
+ * which was copied.
1451
+ */
1452
+ 'afterCopy',
1453
+ /**
1454
+ * Fired by {@link CopyPaste} plugin before values are pasted into table. This hook is fired when
1455
+ * {@link Options#copyPaste} option is enabled.
1456
+ *
1457
+ * @event Hooks#beforePaste
1458
+ * @param {Array[]} data An array of arrays which contains data to paste.
1459
+ * @param {object[]} coords An array of objects with ranges of the visual indexes (`startRow`, `startCol`, `endRow`, `endCol`)
1460
+ * that correspond to the previously selected area.
1461
+ * @returns {*} If returns `false` then pasting is canceled.
1462
+ * @example
1463
+ * ```js
1464
+ * ::: only-for javascript
1465
+ * // To disregard a single row, remove it from array using data.splice(i, 1).
1466
+ * new Handsontable(example, {
1467
+ * beforePaste: (data, coords) => {
1468
+ * // data -> [[1, 2, 3], [4, 5, 6]]
1469
+ * data.splice(0, 1);
1470
+ * // data -> [[4, 5, 6]]
1471
+ * // coords -> [{startRow: 0, startCol: 0, endRow: 1, endCol: 2}]
1472
+ * }
1473
+ * });
1474
+ * // To cancel pasting, return false from the callback.
1475
+ * new Handsontable(example, {
1476
+ * beforePaste: (data, coords) => {
1477
+ * return false;
1478
+ * }
1479
+ * });
1480
+ * ```
1481
+ * :::
1482
+ *
1483
+ * ::: only-for react
1484
+ * ```jsx
1485
+ * // To disregard a single row, remove it from array using data.splice(i, 1).
1486
+ * <HotTable
1487
+ * beforePaste={(data, coords) => {
1488
+ * // data -> [[1, 2, 3], [4, 5, 6]]
1489
+ * data.splice(0, 1);
1490
+ * // data -> [[4, 5, 6]]
1491
+ * // coords -> [{startRow: 0, startCol: 0, endRow: 1, endCol: 2}]
1492
+ * }}
1493
+ * />
1494
+ * // To cancel pasting, return false from the callback.
1495
+ * <HotTable
1496
+ * beforePaste={(data, coords) => {
1497
+ * return false;
1498
+ * }}
1499
+ * />
1500
+ * ```
1501
+ * :::
1502
+ */
1503
+ 'beforePaste',
1504
+ /**
1505
+ * Fired by {@link CopyPaste} plugin after values are pasted into table. This hook is fired when
1506
+ * {@link Options#copyPaste} option is enabled.
1507
+ *
1508
+ * @event Hooks#afterPaste
1509
+ * @param {Array[]} data An array of arrays which contains the pasted data.
1510
+ * @param {object[]} coords An array of objects with ranges of the visual indexes (`startRow`, `startCol`, `endRow`, `endCol`)
1511
+ * that correspond to the previously selected area.
1512
+ */
1513
+ 'afterPaste',
1514
+ /**
1515
+ * Fired by the {@link ManualColumnFreeze} plugin, before freezing a column.
1516
+ *
1517
+ * @event Hooks#beforeColumnFreeze
1518
+ * @since 12.1.0
1519
+ * @param {number} column The visual index of the column that is going to freeze.
1520
+ * @param {boolean} freezePerformed If `true`: the column is going to freeze. If `false`: the column is not going to freeze (which might happen if the column is already frozen).
1521
+ * @returns {boolean|undefined} If `false`: the column is not going to freeze, and the `afterColumnFreeze` hook won't fire.
1522
+ */
1523
+ 'beforeColumnFreeze',
1524
+ /**
1525
+ * Fired by the {@link ManualColumnFreeze} plugin, right after freezing a column.
1526
+ *
1527
+ * @event Hooks#afterColumnFreeze
1528
+ * @since 12.1.0
1529
+ * @param {number} column The visual index of the frozen column.
1530
+ * @param {boolean} freezePerformed If `true`: the column got successfully frozen. If `false`: the column didn't get frozen.
1531
+ */
1532
+ 'afterColumnFreeze',
1533
+ /**
1534
+ * Fired by {@link ManualColumnMove} plugin before change order of the visual indexes. This hook is fired when
1535
+ * {@link Options#manualColumnMove} option is enabled.
1536
+ *
1537
+ * @event Hooks#beforeColumnMove
1538
+ * @param {Array} movedColumns Array of visual column indexes to be moved.
1539
+ * @param {number} finalIndex Visual column index, being a start index for the moved columns.
1540
+ * Points to where the elements will be placed after the moving action.
1541
+ * To check visualization of final index please take a look at
1542
+ * [documentation](@/guides/columns/column-moving.md).
1543
+ * @param {number|undefined} dropIndex Visual column index, being a drop index for the moved columns.
1544
+ * Points to where we are going to drop the moved elements. To check
1545
+ * visualization of drop index please take a look at
1546
+ * [documentation](@/guides/columns/column-moving.md).
1547
+ * It's `undefined` when `dragColumns` function wasn't called.
1548
+ * @param {boolean} movePossible Indicates if it's possible to move rows to the desired position.
1549
+ * @returns {undefined | boolean} If `false` the column will not be moved, `true` otherwise.
1550
+ */
1551
+ 'beforeColumnMove',
1552
+ /**
1553
+ * Fired by {@link ManualColumnMove} plugin after changing order of the visual indexes.
1554
+ * This hook is fired when {@link Options#manualColumnMove} option is enabled.
1555
+ *
1556
+ * @event Hooks#afterColumnMove
1557
+ * @param {Array} movedColumns Array of visual column indexes to be moved.
1558
+ * @param {number} finalIndex Visual column index, being a start index for the moved columns.
1559
+ * Points to where the elements will be placed after the moving action.
1560
+ * To check visualization of final index please take a look at
1561
+ * [documentation](@/guides/columns/column-moving.md).
1562
+ * @param {number|undefined} dropIndex Visual column index, being a drop index for the moved columns.
1563
+ * Points to where we are going to drop the moved elements.
1564
+ * To check visualization of drop index please take a look at
1565
+ * [documentation](@/guides/columns/column-moving.md).
1566
+ * It's `undefined` when `dragColumns` function wasn't called.
1567
+ * @param {boolean} movePossible Indicates if it was possible to move columns to the desired position.
1568
+ * @param {boolean} orderChanged Indicates if order of columns was changed by move.
1569
+ */
1570
+ 'afterColumnMove',
1571
+ /**
1572
+ * Fired by the {@link ManualColumnFreeze} plugin, before unfreezing a column.
1573
+ *
1574
+ * @event Hooks#beforeColumnUnfreeze
1575
+ * @since 12.1.0
1576
+ * @param {number} column The visual index of the column that is going to unfreeze.
1577
+ * @param {boolean} unfreezePerformed If `true`: the column is going to unfreeze. If `false`: the column is not going to unfreeze (which might happen if the column is already unfrozen).
1578
+ * @returns {boolean|undefined} If `false`: the column is not going to unfreeze, and the `afterColumnUnfreeze` hook won't fire.
1579
+ */
1580
+ 'beforeColumnUnfreeze',
1581
+ /**
1582
+ * Fired by the {@link ManualColumnFreeze} plugin, right after unfreezing a column.
1583
+ *
1584
+ * @event Hooks#afterColumnUnfreeze
1585
+ * @since 12.1.0
1586
+ * @param {number} column The visual index of the unfrozen column.
1587
+ * @param {boolean} unfreezePerformed If `true`: the column got successfully unfrozen. If `false`: the column didn't get unfrozen.
1588
+ */
1589
+ 'afterColumnUnfreeze',
1590
+ /**
1591
+ * Fired by {@link ManualRowMove} plugin before changing the order of the visual indexes. This hook is fired when
1592
+ * {@link Options#manualRowMove} option is enabled.
1593
+ *
1594
+ * @event Hooks#beforeRowMove
1595
+ * @param {Array} movedRows Array of visual row indexes to be moved.
1596
+ * @param {number} finalIndex Visual row index, being a start index for the moved rows.
1597
+ * Points to where the elements will be placed after the moving action.
1598
+ * To check visualization of final index please take a look at
1599
+ * [documentation](@/guides/rows/row-moving.md).
1600
+ * @param {number|undefined} dropIndex Visual row index, being a drop index for the moved rows.
1601
+ * Points to where we are going to drop the moved elements.
1602
+ * To check visualization of drop index please take a look at
1603
+ * [documentation](@/guides/rows/row-moving.md).
1604
+ * It's `undefined` when `dragRows` function wasn't called.
1605
+ * @param {boolean} movePossible Indicates if it's possible to move rows to the desired position.
1606
+ * @returns {*|boolean} If false is returned the action is canceled.
1607
+ */
1608
+ 'beforeRowMove',
1609
+ /**
1610
+ * Fired by {@link ManualRowMove} plugin after changing the order of the visual indexes.
1611
+ * This hook is fired when {@link Options#manualRowMove} option is enabled.
1612
+ *
1613
+ * @event Hooks#afterRowMove
1614
+ * @param {Array} movedRows Array of visual row indexes to be moved.
1615
+ * @param {number} finalIndex Visual row index, being a start index for the moved rows.
1616
+ * Points to where the elements will be placed after the moving action.
1617
+ * To check visualization of final index please take a look at
1618
+ * [documentation](@/guides/rows/row-moving.md).
1619
+ * @param {number|undefined} dropIndex Visual row index, being a drop index for the moved rows.
1620
+ * Points to where we are going to drop the moved elements.
1621
+ * To check visualization of drop index please take a look at
1622
+ * [documentation](@/guides/rows/row-moving.md).
1623
+ * It's `undefined` when `dragRows` function wasn't called.
1624
+ * @param {boolean} movePossible Indicates if it was possible to move rows to the desired position.
1625
+ * @param {boolean} orderChanged Indicates if order of rows was changed by move.
1626
+ */
1627
+ 'afterRowMove',
1628
+ /**
1629
+ * Fired by {@link ManualColumnResize} plugin before rendering the table with modified column sizes. This hook is
1630
+ * fired when {@link Options#manualColumnResize} option is enabled.
1631
+ *
1632
+ * @event Hooks#beforeColumnResize
1633
+ * @param {number} newSize Calculated new column width.
1634
+ * @param {number} column Visual index of the resized column.
1635
+ * @param {boolean} isDoubleClick Flag that determines whether there was a double-click.
1636
+ * @returns {number} Returns a new column size or `undefined`, if column size should be calculated automatically.
1637
+ */
1638
+ 'beforeColumnResize',
1639
+ /**
1640
+ * Fired by {@link ManualColumnResize} plugin after rendering the table with modified column sizes. This hook is
1641
+ * fired when {@link Options#manualColumnResize} option is enabled.
1642
+ *
1643
+ * @event Hooks#afterColumnResize
1644
+ * @param {number} newSize Calculated new column width.
1645
+ * @param {number} column Visual index of the resized column.
1646
+ * @param {boolean} isDoubleClick Flag that determines whether there was a double-click.
1647
+ */
1648
+ 'afterColumnResize',
1649
+ /**
1650
+ * Fired by {@link ManualRowResize} plugin before rendering the table with modified row sizes. This hook is
1651
+ * fired when {@link Options#manualRowResize} option is enabled.
1652
+ *
1653
+ * @event Hooks#beforeRowResize
1654
+ * @param {number} newSize Calculated new row height.
1655
+ * @param {number} row Visual index of the resized row.
1656
+ * @param {boolean} isDoubleClick Flag that determines whether there was a double-click.
1657
+ * @returns {number|undefined} Returns the new row size or `undefined` if row size should be calculated automatically.
1658
+ */
1659
+ 'beforeRowResize',
1660
+ /**
1661
+ * Fired by {@link ManualRowResize} plugin after rendering the table with modified row sizes. This hook is
1662
+ * fired when {@link Options#manualRowResize} option is enabled.
1663
+ *
1664
+ * @event Hooks#afterRowResize
1665
+ * @param {number} newSize Calculated new row height.
1666
+ * @param {number} row Visual index of the resized row.
1667
+ * @param {boolean} isDoubleClick Flag that determines whether there was a double-click.
1668
+ */
1669
+ 'afterRowResize',
1670
+ /**
1671
+ * Fired after getting the column header renderers.
1672
+ *
1673
+ * @event Hooks#afterGetColumnHeaderRenderers
1674
+ * @param {Function[]} renderers An array of the column header renderers.
1675
+ */
1676
+ 'afterGetColumnHeaderRenderers',
1677
+ /**
1678
+ * Fired after getting the row header renderers.
1679
+ *
1680
+ * @event Hooks#afterGetRowHeaderRenderers
1681
+ * @param {Function[]} renderers An array of the row header renderers.
1682
+ */
1683
+ 'afterGetRowHeaderRenderers',
1684
+ /**
1685
+ * Fired before applying stretched column width to column.
1686
+ *
1687
+ * @event Hooks#beforeStretchingColumnWidth
1688
+ * @param {number} stretchedWidth Calculated width.
1689
+ * @param {number} column Visual column index.
1690
+ * @returns {number|undefined} Returns new width which will be applied to the column element.
1691
+ */
1692
+ 'beforeStretchingColumnWidth',
1693
+ /**
1694
+ * Fired by {@link Filters} plugin before applying [filtering](@/guides/columns/column-filter.md).
1695
+ * This hook is fired when {@link Options#filters} option is enabled.
1696
+ *
1697
+ * @event Hooks#beforeFilter
1698
+ * @param {object[]} conditionsStack An array of objects with added formulas.
1699
+ * ```js
1700
+ * // Example format of the conditionsStack argument:
1701
+ * [
1702
+ * {
1703
+ * column: 2,
1704
+ * conditions: [
1705
+ * {name: 'begins_with', args: [['S']]}
1706
+ * ],
1707
+ * operation: 'conjunction'
1708
+ * },
1709
+ * {
1710
+ * column: 4,
1711
+ * conditions: [
1712
+ * {name: 'not_empty', args: []}
1713
+ * ],
1714
+ * operation: 'conjunction'
1715
+ * },
1716
+ * ]
1717
+ * ```
1718
+ * @returns {boolean} If hook returns `false` value then filtering won't be applied on the UI side (server-side filtering).
1719
+ */
1720
+ 'beforeFilter',
1721
+ /**
1722
+ * Fired by {@link Filters} plugin after applying [filtering](@/guides/columns/column-filter.md).
1723
+ * This hook is fired when {@link Options#filters} option is enabled.
1724
+ *
1725
+ * @event Hooks#afterFilter
1726
+ * @param {object[]} conditionsStack An array of objects with added conditions.
1727
+ * ```js
1728
+ * // Example format of the conditionsStack argument:
1729
+ * [
1730
+ * {
1731
+ * column: 2,
1732
+ * conditions: [
1733
+ * {name: 'begins_with', args: [['S']]}
1734
+ * ],
1735
+ * operation: 'conjunction'
1736
+ * },
1737
+ * {
1738
+ * column: 4,
1739
+ * conditions: [
1740
+ * {name: 'not_empty', args: []}
1741
+ * ],
1742
+ * operation: 'conjunction'
1743
+ * },
1744
+ * ]
1745
+ * ```
1746
+ */
1747
+ 'afterFilter',
1748
+ /**
1749
+ * Fired by the {@link Formulas} plugin, when any cell value changes.
1750
+ *
1751
+ * Returns an array of objects that contains:
1752
+ * - The addresses (`sheet`, `row`, `col`) and new values (`newValue`) of the changed cells.
1753
+ * - The addresses and new values of any cells that had to be recalculated (because their formulas depend on the cells that changed).
1754
+ *
1755
+ * This hook gets also fired on Handsontable's initialization, returning the addresses and values of all cells.
1756
+ *
1757
+ * Read more:
1758
+ * - [Guides: Formula calculation](@/guides/formulas/formula-calculation.md)
1759
+ * - [HyperFormula documentation: `valuesUpdated`](https://hyperformula.handsontable.com/api/interfaces/listeners.html#valuesupdated)
1760
+ *
1761
+ * @since 9.0.0
1762
+ * @event Hooks#afterFormulasValuesUpdate
1763
+ * @param {Array} changes The addresses and new values of all the changed and recalculated cells.
1764
+ */
1765
+ 'afterFormulasValuesUpdate',
1766
+ /**
1767
+ * Fired when a named expression is added to the Formulas' engine instance.
1768
+ *
1769
+ * @since 9.0.0
1770
+ * @event Hooks#afterNamedExpressionAdded
1771
+ * @param {string} namedExpressionName The name of the added expression.
1772
+ * @param {Array} changes The values and location of applied changes.
1773
+ */
1774
+ 'afterNamedExpressionAdded',
1775
+ /**
1776
+ * Fired when a named expression is removed from the Formulas' engine instance.
1777
+ *
1778
+ * @since 9.0.0
1779
+ * @event Hooks#afterNamedExpressionRemoved
1780
+ * @param {string} namedExpressionName The name of the removed expression.
1781
+ * @param {Array} changes The values and location of applied changes.
1782
+ */
1783
+ 'afterNamedExpressionRemoved',
1784
+ /**
1785
+ * Fired when a new sheet is added to the Formulas' engine instance.
1786
+ *
1787
+ * @since 9.0.0
1788
+ * @event Hooks#afterSheetAdded
1789
+ * @param {string} addedSheetDisplayName The name of the added sheet.
1790
+ */
1791
+ 'afterSheetAdded',
1792
+ /**
1793
+ * Fired when a sheet in the Formulas' engine instance is renamed.
1794
+ *
1795
+ * @since 9.0.0
1796
+ * @event Hooks#afterSheetRenamed
1797
+ * @param {string} oldDisplayName The old name of the sheet.
1798
+ * @param {string} newDisplayName The new name of the sheet.
1799
+ */
1800
+ 'afterSheetRenamed',
1801
+ /**
1802
+ * Fired when a sheet is removed from the Formulas' engine instance.
1803
+ *
1804
+ * @since 9.0.0
1805
+ * @event Hooks#afterSheetRemoved
1806
+ * @param {string} removedSheetDisplayName The removed sheet name.
1807
+ * @param {Array} changes The values and location of applied changes.
1808
+ */
1809
+ 'afterSheetRemoved',
1810
+ /**
1811
+ * Fired while retrieving the column header height.
1812
+ *
1813
+ * @event Hooks#modifyColumnHeaderHeight
1814
+ */
1815
+ 'modifyColumnHeaderHeight',
1816
+ /**
1817
+ * Fired by {@link UndoRedo} plugin before the undo action. Contains information about the action that is being undone.
1818
+ * This hook is fired when {@link Options#undo} option is enabled.
1819
+ *
1820
+ * @event Hooks#beforeUndo
1821
+ * @param {object} action The action object. Contains information about the action being undone. The `actionType`
1822
+ * property of the object specifies the type of the action in a String format. (e.g. `'remove_row'`).
1823
+ * @returns {*|boolean} If false is returned the action is canceled.
1824
+ */
1825
+ 'beforeUndo',
1826
+ /**
1827
+ * Fired by {@link UndoRedo} plugin before changing undo stack.
1828
+ *
1829
+ * @event Hooks#beforeUndoStackChange
1830
+ * @since 8.4.0
1831
+ * @param {Array} doneActions Stack of actions which may be undone.
1832
+ * @param {string} [source] String that identifies source of action
1833
+ * ([list of all available sources](@/guides/getting-started/events-and-hooks.md#definition-for-source-argument)).
1834
+ * @returns {*|boolean} If false is returned the action of changing undo stack is canceled.
1835
+ */
1836
+ 'beforeUndoStackChange',
1837
+ /**
1838
+ * Fired by {@link UndoRedo} plugin after the undo action. Contains information about the action that is being undone.
1839
+ * This hook is fired when {@link Options#undo} option is enabled.
1840
+ *
1841
+ * @event Hooks#afterUndo
1842
+ * @param {object} action The action object. Contains information about the action being undone. The `actionType`
1843
+ * property of the object specifies the type of the action in a String format. (e.g. `'remove_row'`).
1844
+ */
1845
+ 'afterUndo',
1846
+ /**
1847
+ * Fired by {@link UndoRedo} plugin after changing undo stack.
1848
+ *
1849
+ * @event Hooks#afterUndoStackChange
1850
+ * @since 8.4.0
1851
+ * @param {Array} doneActionsBefore Stack of actions which could be undone before performing new action.
1852
+ * @param {Array} doneActionsAfter Stack of actions which can be undone after performing new action.
1853
+ */
1854
+ 'afterUndoStackChange',
1855
+ /**
1856
+ * Fired by {@link UndoRedo} plugin before the redo action. Contains information about the action that is being redone.
1857
+ * This hook is fired when {@link Options#undo} option is enabled.
1858
+ *
1859
+ * @event Hooks#beforeRedo
1860
+ * @param {object} action The action object. Contains information about the action being redone. The `actionType`
1861
+ * property of the object specifies the type of the action in a String format (e.g. `'remove_row'`).
1862
+ * @returns {*|boolean} If false is returned the action is canceled.
1863
+ */
1864
+ 'beforeRedo',
1865
+ /**
1866
+ * Fired by {@link UndoRedo} plugin before changing redo stack.
1867
+ *
1868
+ * @event Hooks#beforeRedoStackChange
1869
+ * @since 8.4.0
1870
+ * @param {Array} undoneActions Stack of actions which may be redone.
1871
+ */
1872
+ 'beforeRedoStackChange',
1873
+ /**
1874
+ * Fired by {@link UndoRedo} plugin after the redo action. Contains information about the action that is being redone.
1875
+ * This hook is fired when {@link Options#undo} option is enabled.
1876
+ *
1877
+ * @event Hooks#afterRedo
1878
+ * @param {object} action The action object. Contains information about the action being redone. The `actionType`
1879
+ * property of the object specifies the type of the action in a String format (e.g. `'remove_row'`).
1880
+ */
1881
+ 'afterRedo',
1882
+ /**
1883
+ * Fired by {@link UndoRedo} plugin after changing redo stack.
1884
+ *
1885
+ * @event Hooks#afterRedoStackChange
1886
+ * @since 8.4.0
1887
+ * @param {Array} undoneActionsBefore Stack of actions which could be redone before performing new action.
1888
+ * @param {Array} undoneActionsAfter Stack of actions which can be redone after performing new action.
1889
+ */
1890
+ 'afterRedoStackChange',
1891
+ /**
1892
+ * Fired while retrieving the row header width.
1893
+ *
1894
+ * @event Hooks#modifyRowHeaderWidth
1895
+ * @param {number} rowHeaderWidth Row header width.
1896
+ */
1897
+ 'modifyRowHeaderWidth',
1898
+ /**
1899
+ * Fired from the `populateFromArray` method during the `autofill` process. Fired for each "autofilled" cell individually.
1900
+ *
1901
+ * @deprecated
1902
+ * @event Hooks#beforeAutofillInsidePopulate
1903
+ * @param {object} index Object containing `row` and `col` properties, defining the number of rows/columns from the initial cell of the autofill.
1904
+ * @param {string} direction Declares the direction of the autofill. Possible values: `up`, `down`, `left`, `right`.
1905
+ * @param {Array[]} input Contains an array of rows with data being used in the autofill.
1906
+ * @param {Array} deltas The deltas array passed to the `populateFromArray` method.
1907
+ */
1908
+ 'beforeAutofillInsidePopulate',
1909
+ /**
1910
+ * Fired when the start of the selection is being modified (e.g. Moving the selection with the arrow keys).
1911
+ *
1912
+ * @event Hooks#modifyTransformStart
1913
+ * @param {CellCoords} delta Cell coords object declaring the delta of the new selection relative to the previous one.
1914
+ */
1915
+ 'modifyTransformStart',
1916
+ /**
1917
+ * Fired when the end of the selection is being modified (e.g. Moving the selection with the arrow keys).
1918
+ *
1919
+ * @event Hooks#modifyTransformEnd
1920
+ * @param {CellCoords} delta Cell coords object declaring the delta of the new selection relative to the previous one.
1921
+ */
1922
+ 'modifyTransformEnd',
1923
+ /**
1924
+ * Fired after the start of the selection is being modified (e.g. Moving the selection with the arrow keys).
1925
+ *
1926
+ * @event Hooks#afterModifyTransformStart
1927
+ * @param {CellCoords} coords Coords of the freshly selected cell.
1928
+ * @param {number} rowTransformDir `-1` if trying to select a cell with a negative row index. `0` otherwise.
1929
+ * @param {number} colTransformDir `-1` if trying to select a cell with a negative column index. `0` otherwise.
1930
+ */
1931
+ 'afterModifyTransformStart',
1932
+ /**
1933
+ * Fired after the end of the selection is being modified (e.g. Moving the selection with the arrow keys).
1934
+ *
1935
+ * @event Hooks#afterModifyTransformEnd
1936
+ * @param {CellCoords} coords Visual coords of the freshly selected cell.
1937
+ * @param {number} rowTransformDir `-1` if trying to select a cell with a negative row index. `0` otherwise.
1938
+ * @param {number} colTransformDir `-1` if trying to select a cell with a negative column index. `0` otherwise.
1939
+ */
1940
+ 'afterModifyTransformEnd',
1941
+ /**
1942
+ * Fired inside the `viewportRowCalculatorOverride` method. Allows modifying the row calculator parameters.
1943
+ *
1944
+ * @event Hooks#afterViewportRowCalculatorOverride
1945
+ * @param {object} calc The row calculator.
1946
+ */
1947
+ 'afterViewportRowCalculatorOverride',
1948
+ /**
1949
+ * Fired inside the `viewportColumnCalculatorOverride` method. Allows modifying the row calculator parameters.
1950
+ *
1951
+ * @event Hooks#afterViewportColumnCalculatorOverride
1952
+ * @param {object} calc The row calculator.
1953
+ */
1954
+ 'afterViewportColumnCalculatorOverride',
1955
+ /**
1956
+ * Fired after initializing all the plugins.
1957
+ * This hook should be added before Handsontable is initialized.
1958
+ *
1959
+ * @event Hooks#afterPluginsInitialized
1960
+ *
1961
+ * @example
1962
+ * ```js
1963
+ * Handsontable.hooks.add('afterPluginsInitialized', myCallback);
1964
+ * ```
1965
+ */
1966
+ 'afterPluginsInitialized',
1967
+ /**
1968
+ * Fired by {@link HiddenRows} plugin before marking the rows as hidden. Fired only if the {@link Options#hiddenRows} option is enabled.
1969
+ * Returning `false` in the callback will prevent the hiding action from completing.
1970
+ *
1971
+ * @event Hooks#beforeHideRows
1972
+ * @param {Array} currentHideConfig Current hide configuration - a list of hidden physical row indexes.
1973
+ * @param {Array} destinationHideConfig Destination hide configuration - a list of hidden physical row indexes.
1974
+ * @param {boolean} actionPossible `true`, if provided row indexes are valid, `false` otherwise.
1975
+ * @returns {undefined|boolean} If the callback returns `false`, the hiding action will not be completed.
1976
+ */
1977
+ 'beforeHideRows',
1978
+ /**
1979
+ * Fired by {@link HiddenRows} plugin after marking the rows as hidden. Fired only if the {@link Options#hiddenRows} option is enabled.
1980
+ *
1981
+ * @event Hooks#afterHideRows
1982
+ * @param {Array} currentHideConfig Current hide configuration - a list of hidden physical row indexes.
1983
+ * @param {Array} destinationHideConfig Destination hide configuration - a list of hidden physical row indexes.
1984
+ * @param {boolean} actionPossible `true`, if provided row indexes are valid, `false` otherwise.
1985
+ * @param {boolean} stateChanged `true`, if the action affected any non-hidden rows, `false` otherwise.
1986
+ */
1987
+ 'afterHideRows',
1988
+ /**
1989
+ * Fired by {@link HiddenRows} plugin before marking the rows as not hidden. Fired only if the {@link Options#hiddenRows} option is enabled.
1990
+ * Returning `false` in the callback will prevent the row revealing action from completing.
1991
+ *
1992
+ * @event Hooks#beforeUnhideRows
1993
+ * @param {Array} currentHideConfig Current hide configuration - a list of hidden physical row indexes.
1994
+ * @param {Array} destinationHideConfig Destination hide configuration - a list of hidden physical row indexes.
1995
+ * @param {boolean} actionPossible `true`, if provided row indexes are valid, `false` otherwise.
1996
+ * @returns {undefined|boolean} If the callback returns `false`, the revealing action will not be completed.
1997
+ */
1998
+ 'beforeUnhideRows',
1999
+ /**
2000
+ * Fired by {@link HiddenRows} plugin after marking the rows as not hidden. Fired only if the {@link Options#hiddenRows} option is enabled.
2001
+ *
2002
+ * @event Hooks#afterUnhideRows
2003
+ * @param {Array} currentHideConfig Current hide configuration - a list of hidden physical row indexes.
2004
+ * @param {Array} destinationHideConfig Destination hide configuration - a list of hidden physical row indexes.
2005
+ * @param {boolean} actionPossible `true`, if provided row indexes are valid, `false` otherwise.
2006
+ * @param {boolean} stateChanged `true`, if the action affected any hidden rows, `false` otherwise.
2007
+ */
2008
+ 'afterUnhideRows',
2009
+ /**
2010
+ * Fired by {@link HiddenColumns} plugin before marking the columns as hidden. Fired only if the {@link Options#hiddenColumns} option is enabled.
2011
+ * Returning `false` in the callback will prevent the hiding action from completing.
2012
+ *
2013
+ * @event Hooks#beforeHideColumns
2014
+ * @param {Array} currentHideConfig Current hide configuration - a list of hidden physical column indexes.
2015
+ * @param {Array} destinationHideConfig Destination hide configuration - a list of hidden physical column indexes.
2016
+ * @param {boolean} actionPossible `true`, if the provided column indexes are valid, `false` otherwise.
2017
+ * @returns {undefined|boolean} If the callback returns `false`, the hiding action will not be completed.
2018
+ */
2019
+ 'beforeHideColumns',
2020
+ /**
2021
+ * Fired by {@link HiddenColumns} plugin after marking the columns as hidden. Fired only if the {@link Options#hiddenColumns} option is enabled.
2022
+ *
2023
+ * @event Hooks#afterHideColumns
2024
+ * @param {Array} currentHideConfig Current hide configuration - a list of hidden physical column indexes.
2025
+ * @param {Array} destinationHideConfig Destination hide configuration - a list of hidden physical column indexes.
2026
+ * @param {boolean} actionPossible `true`, if the provided column indexes are valid, `false` otherwise.
2027
+ * @param {boolean} stateChanged `true`, if the action affected any non-hidden columns, `false` otherwise.
2028
+ */
2029
+ 'afterHideColumns',
2030
+ /**
2031
+ * Fired by {@link HiddenColumns} plugin before marking the columns as not hidden. Fired only if the {@link Options#hiddenColumns} option is enabled.
2032
+ * Returning `false` in the callback will prevent the column revealing action from completing.
2033
+ *
2034
+ * @event Hooks#beforeUnhideColumns
2035
+ * @param {Array} currentHideConfig Current hide configuration - a list of hidden physical column indexes.
2036
+ * @param {Array} destinationHideConfig Destination hide configuration - a list of hidden physical column indexes.
2037
+ * @param {boolean} actionPossible `true`, if the provided column indexes are valid, `false` otherwise.
2038
+ * @returns {undefined|boolean} If the callback returns `false`, the hiding action will not be completed.
2039
+ */
2040
+ 'beforeUnhideColumns',
2041
+ /**
2042
+ * Fired by {@link HiddenColumns} plugin after marking the columns as not hidden. Fired only if the {@link Options#hiddenColumns} option is enabled.
2043
+ *
2044
+ * @event Hooks#afterUnhideColumns
2045
+ * @param {Array} currentHideConfig Current hide configuration - a list of hidden physical column indexes.
2046
+ * @param {Array} destinationHideConfig Destination hide configuration - a list of hidden physical column indexes.
2047
+ * @param {boolean} actionPossible `true`, if the provided column indexes are valid, `false` otherwise.
2048
+ * @param {boolean} stateChanged `true`, if the action affected any hidden columns, `false` otherwise.
2049
+ */
2050
+ 'afterUnhideColumns',
2051
+ /**
2052
+ * Fired by {@link TrimRows} plugin before trimming rows. This hook is fired when {@link Options#trimRows} option is enabled.
2053
+ *
2054
+ * @event Hooks#beforeTrimRow
2055
+ * @param {Array} currentTrimConfig Current trim configuration - a list of trimmed physical row indexes.
2056
+ * @param {Array} destinationTrimConfig Destination trim configuration - a list of trimmed physical row indexes.
2057
+ * @param {boolean} actionPossible `true`, if all of the row indexes are withing the bounds of the table, `false` otherwise.
2058
+ * @returns {undefined|boolean} If the callback returns `false`, the trimming action will not be completed.
2059
+ */
2060
+ 'beforeTrimRow',
2061
+ /**
2062
+ * Fired by {@link TrimRows} plugin after trimming rows. This hook is fired when {@link Options#trimRows} option is enabled.
2063
+ *
2064
+ * @event Hooks#afterTrimRow
2065
+ * @param {Array} currentTrimConfig Current trim configuration - a list of trimmed physical row indexes.
2066
+ * @param {Array} destinationTrimConfig Destination trim configuration - a list of trimmed physical row indexes.
2067
+ * @param {boolean} actionPossible `true`, if all of the row indexes are withing the bounds of the table, `false` otherwise.
2068
+ * @param {boolean} stateChanged `true`, if the action affected any non-trimmed rows, `false` otherwise.
2069
+ * @returns {undefined|boolean} If the callback returns `false`, the trimming action will not be completed.
2070
+ */
2071
+ 'afterTrimRow',
2072
+ /**
2073
+ * Fired by {@link TrimRows} plugin before untrimming rows. This hook is fired when {@link Options#trimRows} option is enabled.
2074
+ *
2075
+ * @event Hooks#beforeUntrimRow
2076
+ * @param {Array} currentTrimConfig Current trim configuration - a list of trimmed physical row indexes.
2077
+ * @param {Array} destinationTrimConfig Destination trim configuration - a list of trimmed physical row indexes.
2078
+ * @param {boolean} actionPossible `true`, if all of the row indexes are withing the bounds of the table, `false` otherwise.
2079
+ * @returns {undefined|boolean} If the callback returns `false`, the untrimming action will not be completed.
2080
+ */
2081
+ 'beforeUntrimRow',
2082
+ /**
2083
+ * Fired by {@link TrimRows} plugin after untrimming rows. This hook is fired when {@link Options#trimRows} option is enabled.
2084
+ *
2085
+ * @event Hooks#afterUntrimRow
2086
+ * @param {Array} currentTrimConfig Current trim configuration - a list of trimmed physical row indexes.
2087
+ * @param {Array} destinationTrimConfig Destination trim configuration - a list of trimmed physical row indexes.
2088
+ * @param {boolean} actionPossible `true`, if all of the row indexes are withing the bounds of the table, `false` otherwise.
2089
+ * @param {boolean} stateChanged `true`, if the action affected any trimmed rows, `false` otherwise.
2090
+ * @returns {undefined|boolean} If the callback returns `false`, the untrimming action will not be completed.
2091
+ */
2092
+ 'afterUntrimRow',
2093
+ /**
2094
+ * Fired by {@link DropdownMenu} plugin before opening the dropdown menu. This hook is fired when {@link Options#dropdownMenu}
2095
+ * option is enabled.
2096
+ *
2097
+ * @event Hooks#beforeDropdownMenuShow
2098
+ * @param {DropdownMenu} dropdownMenu The DropdownMenu instance.
2099
+ */
2100
+ 'beforeDropdownMenuShow',
2101
+ /**
2102
+ * Fired by {@link DropdownMenu} plugin after opening the Dropdown Menu. This hook is fired when {@link Options#dropdownMenu}
2103
+ * option is enabled.
2104
+ *
2105
+ * @event Hooks#afterDropdownMenuShow
2106
+ * @param {DropdownMenu} dropdownMenu The DropdownMenu instance.
2107
+ */
2108
+ 'afterDropdownMenuShow',
2109
+ /**
2110
+ * Fired by {@link DropdownMenu} plugin after hiding the Dropdown Menu. This hook is fired when {@link Options#dropdownMenu}
2111
+ * option is enabled.
2112
+ *
2113
+ * @event Hooks#afterDropdownMenuHide
2114
+ * @param {DropdownMenu} instance The DropdownMenu instance.
2115
+ */
2116
+ 'afterDropdownMenuHide',
2117
+ /**
2118
+ * Fired by {@link NestedRows} plugin before adding a children to the NestedRows structure. This hook is fired when
2119
+ * {@link Options#nestedRows} option is enabled.
2120
+ *
2121
+ * @event Hooks#beforeAddChild
2122
+ * @param {object} parent The parent object.
2123
+ * @param {object|undefined} element The element added as a child. If `undefined`, a blank child was added.
2124
+ * @param {number|undefined} index The index within the parent where the new child was added. If `undefined`, the element was added as the last child.
2125
+ */
2126
+ 'beforeAddChild',
2127
+ /**
2128
+ * Fired by {@link NestedRows} plugin after adding a children to the NestedRows structure. This hook is fired when
2129
+ * {@link Options#nestedRows} option is enabled.
2130
+ *
2131
+ * @event Hooks#afterAddChild
2132
+ * @param {object} parent The parent object.
2133
+ * @param {object|undefined} element The element added as a child. If `undefined`, a blank child was added.
2134
+ * @param {number|undefined} index The index within the parent where the new child was added. If `undefined`, the element was added as the last child.
2135
+ */
2136
+ 'afterAddChild',
2137
+ /**
2138
+ * Fired by {@link NestedRows} plugin before detaching a child from its parent. This hook is fired when
2139
+ * {@link Options#nestedRows} option is enabled.
2140
+ *
2141
+ * @event Hooks#beforeDetachChild
2142
+ * @param {object} parent An object representing the parent from which the element is to be detached.
2143
+ * @param {object} element The detached element.
2144
+ */
2145
+ 'beforeDetachChild',
2146
+ /**
2147
+ * Fired by {@link NestedRows} plugin after detaching a child from its parent. This hook is fired when
2148
+ * {@link Options#nestedRows} option is enabled.
2149
+ *
2150
+ * @event Hooks#afterDetachChild
2151
+ * @param {object} parent An object representing the parent from which the element was detached.
2152
+ * @param {object} element The detached element.
2153
+ * @param {number} finalElementPosition The final row index of the detached element.
2154
+ */
2155
+ 'afterDetachChild',
2156
+ /**
2157
+ * Fired after the editor is opened and rendered.
2158
+ *
2159
+ * @event Hooks#afterBeginEditing
2160
+ * @param {number} row Visual row index of the edited cell.
2161
+ * @param {number} column Visual column index of the edited cell.
2162
+ */
2163
+ 'afterBeginEditing',
2164
+ /**
2165
+ * Fired by {@link MergeCells} plugin before cell merging. This hook is fired when {@link Options#mergeCells}
2166
+ * option is enabled.
2167
+ *
2168
+ * @event Hooks#beforeMergeCells
2169
+ * @param {CellRange} cellRange Selection cell range.
2170
+ * @param {boolean} [auto=false] `true` if called automatically by the plugin.
2171
+ */
2172
+ 'beforeMergeCells',
2173
+ /**
2174
+ * Fired by {@link MergeCells} plugin after cell merging. This hook is fired when {@link Options#mergeCells}
2175
+ * option is enabled.
2176
+ *
2177
+ * @event Hooks#afterMergeCells
2178
+ * @param {CellRange} cellRange Selection cell range.
2179
+ * @param {object} mergeParent The parent collection of the provided cell range.
2180
+ * @param {boolean} [auto=false] `true` if called automatically by the plugin.
2181
+ */
2182
+ 'afterMergeCells',
2183
+ /**
2184
+ * Fired by {@link MergeCells} plugin before unmerging the cells. This hook is fired when {@link Options#mergeCells}
2185
+ * option is enabled.
2186
+ *
2187
+ * @event Hooks#beforeUnmergeCells
2188
+ * @param {CellRange} cellRange Selection cell range.
2189
+ * @param {boolean} [auto=false] `true` if called automatically by the plugin.
2190
+ */
2191
+ 'beforeUnmergeCells',
2192
+ /**
2193
+ * Fired by {@link MergeCells} plugin after unmerging the cells. This hook is fired when {@link Options#mergeCells}
2194
+ * option is enabled.
2195
+ *
2196
+ * @event Hooks#afterUnmergeCells
2197
+ * @param {CellRange} cellRange Selection cell range.
2198
+ * @param {boolean} [auto=false] `true` if called automatically by the plugin.
2199
+ */
2200
+ 'afterUnmergeCells',
2201
+ /**
2202
+ * Fired after the table was switched into listening mode. This allows Handsontable to capture keyboard events and
2203
+ * respond in the right way.
2204
+ *
2205
+ * @event Hooks#afterListen
2206
+ */
2207
+ 'afterListen',
2208
+ /**
2209
+ * Fired after the table was switched off from the listening mode. This makes the Handsontable inert for any
2210
+ * keyboard events.
2211
+ *
2212
+ * @event Hooks#afterUnlisten
2213
+ */
2214
+ 'afterUnlisten',
2215
+ /**
2216
+ * Fired after the window was resized or the size of the Handsontable root element was changed.
2217
+ *
2218
+ * @event Hooks#afterRefreshDimensions
2219
+ * @param {object} previousDimensions Previous dimensions of the container.
2220
+ * @param {object} currentDimensions Current dimensions of the container.
2221
+ * @param {boolean} stateChanged `true`, if the container was re-render, `false` otherwise.
2222
+ */
2223
+ 'afterRefreshDimensions',
2224
+ /**
2225
+ * Cancellable hook, called after resizing a window or after detecting size change of the
2226
+ * Handsontable root element, but before redrawing a table.
2227
+ *
2228
+ * @event Hooks#beforeRefreshDimensions
2229
+ * @param {object} previousDimensions Previous dimensions of the container.
2230
+ * @param {object} currentDimensions Current dimensions of the container.
2231
+ * @param {boolean} actionPossible `true`, if current and previous dimensions are different, `false` otherwise.
2232
+ * @returns {undefined|boolean} If the callback returns `false`, the refresh action will not be completed.
2233
+ */
2234
+ 'beforeRefreshDimensions',
2235
+ /**
2236
+ * Fired by {@link CollapsibleColumns} plugin before columns collapse. This hook is fired when {@link Options#collapsibleColumns} option is enabled.
2237
+ *
2238
+ * @event Hooks#beforeColumnCollapse
2239
+ * @since 8.0.0
2240
+ * @param {Array} currentCollapsedColumns Current collapsible configuration - a list of collapsible physical column indexes.
2241
+ * @param {Array} destinationCollapsedColumns Destination collapsible configuration - a list of collapsible physical column indexes.
2242
+ * @param {boolean} collapsePossible `true`, if all of the column indexes are withing the bounds of the collapsed sections, `false` otherwise.
2243
+ * @returns {undefined|boolean} If the callback returns `false`, the collapsing action will not be completed.
2244
+ */
2245
+ 'beforeColumnCollapse',
2246
+ /**
2247
+ * Fired by {@link CollapsibleColumns} plugin before columns collapse. This hook is fired when {@link Options#collapsibleColumns} option is enabled.
2248
+ *
2249
+ * @event Hooks#afterColumnCollapse
2250
+ * @since 8.0.0
2251
+ * @param {Array} currentCollapsedColumns Current collapsible configuration - a list of collapsible physical column indexes.
2252
+ * @param {Array} destinationCollapsedColumns Destination collapsible configuration - a list of collapsible physical column indexes.
2253
+ * @param {boolean} collapsePossible `true`, if all of the column indexes are withing the bounds of the collapsed sections, `false` otherwise.
2254
+ * @param {boolean} successfullyCollapsed `true`, if the action affected any non-collapsible column, `false` otherwise.
2255
+ */
2256
+ 'afterColumnCollapse',
2257
+ /**
2258
+ * Fired by {@link CollapsibleColumns} plugin before columns expand. This hook is fired when {@link Options#collapsibleColumns} option is enabled.
2259
+ *
2260
+ * @event Hooks#beforeColumnExpand
2261
+ * @since 8.0.0
2262
+ * @param {Array} currentCollapsedColumns Current collapsible configuration - a list of collapsible physical column indexes.
2263
+ * @param {Array} destinationCollapsedColumns Destination collapsible configuration - a list of collapsible physical column indexes.
2264
+ * @param {boolean} expandPossible `true`, if all of the column indexes are withing the bounds of the collapsed sections, `false` otherwise.
2265
+ * @returns {undefined|boolean} If the callback returns `false`, the expanding action will not be completed.
2266
+ */
2267
+ 'beforeColumnExpand',
2268
+ /**
2269
+ * Fired by {@link CollapsibleColumns} plugin before columns expand. This hook is fired when {@link Options#collapsibleColumns} option is enabled.
2270
+ *
2271
+ * @event Hooks#afterColumnExpand
2272
+ * @since 8.0.0
2273
+ * @param {Array} currentCollapsedColumns Current collapsible configuration - a list of collapsible physical column indexes.
2274
+ * @param {Array} destinationCollapsedColumns Destination collapsible configuration - a list of collapsible physical column indexes.
2275
+ * @param {boolean} expandPossible `true`, if all of the column indexes are withing the bounds of the collapsed sections, `false` otherwise.
2276
+ * @param {boolean} successfullyExpanded `true`, if the action affected any non-collapsible column, `false` otherwise.
2277
+ */
2278
+ 'afterColumnExpand',
2279
+ /**
2280
+ * Fired by {@link AutoColumnSize} plugin within SampleGenerator utility.
2281
+ *
2282
+ * @event Hooks#modifyAutoColumnSizeSeed
2283
+ * @since 8.4.0
2284
+ * @param {string|undefined} seed Seed ID, unique name to categorize samples.
2285
+ * @param {object} cellProperties Object containing the cell properties.
2286
+ * @param {*} cellValue Value of the cell.
2287
+ */
2288
+ 'modifyAutoColumnSizeSeed'];
2289
+
2290
+ /**
2291
+ * Template warning message for removed hooks.
2292
+ *
2293
+ * @type {string}
2294
+ */
2295
+ var REMOVED_MESSAGE = (0, _templateLiteralTag.toSingleLine)(_templateObject || (_templateObject = _taggedTemplateLiteral(["The plugin hook \"[hookName]\" was removed in Handsontable [removedInVersion]. \n Please consult release notes https://github.com/handsontable/handsontable/releases/tag/[removedInVersion] to \n learn about the migration path."], ["The plugin hook \"[hookName]\" was removed in Handsontable [removedInVersion].\\x20\n Please consult release notes https://github.com/handsontable/handsontable/releases/tag/[removedInVersion] to\\x20\n learn about the migration path."])));
2296
+
2297
+ /**
2298
+ * The list of the hooks which are removed from the API. The warning message is printed out in
2299
+ * the developer console when the hook is used.
2300
+ *
2301
+ * The Map key is represented by hook name and its value points to the Handsontable version
2302
+ * in which it was removed.
2303
+ *
2304
+ * @type {Map<string, string>}
2305
+ */
2306
+ var REMOVED_HOOKS = new Map([['modifyRow', '8.0.0'], ['modifyCol', '8.0.0'], ['unmodifyRow', '8.0.0'], ['unmodifyCol', '8.0.0'], ['skipLengthCache', '8.0.0'], ['hiddenColumn', '8.0.0'], ['hiddenRow', '8.0.0']]);
2307
+
2308
+ /* eslint-disable jsdoc/require-description-complete-sentence */
2309
+ /**
2310
+ * The list of the hooks which are deprecated. The warning message is printed out in
2311
+ * the developer console when the hook is used.
2312
+ *
2313
+ * The Map key is represented by hook name and its value keeps message which whould be
2314
+ * printed out when the hook is used.
2315
+ *
2316
+ * Usage:
2317
+ * ```js
2318
+ * ...
2319
+ * New Map([
2320
+ * ['beforeColumnExpand', 'The plugin hook "beforeColumnExpand" is deprecated. Use "beforeColumnExpand2" instead.'],
2321
+ * ])
2322
+ * ...
2323
+ * ```
2324
+ *
2325
+ *
2326
+ * @type {Map<string, string>}
2327
+ */
2328
+ /* eslint-enable jsdoc/require-description-complete-sentence */
2329
+ var DEPRECATED_HOOKS = new Map([['beforeAutofillInsidePopulate', 'The plugin hook "beforeAutofillInsidePopulate" is deprecated and will be removed in the next major release.']]);
2330
+ var Hooks = /*#__PURE__*/function () {
2331
+ /**
2332
+ *
2333
+ */
2334
+ function Hooks() {
2335
+ _classCallCheck(this, Hooks);
2336
+ this.globalBucket = this.createEmptyBucket();
2337
+ }
2338
+
2339
+ /**
2340
+ * Returns a new object with empty handlers related to every registered hook name.
2341
+ *
2342
+ * @returns {object} The empty bucket object.
2343
+ *
2344
+ * @example
2345
+ * ```js
2346
+ * Handsontable.hooks.createEmptyBucket();
2347
+ * // Results:
2348
+ * {
2349
+ * ...
2350
+ * afterCreateCol: [],
2351
+ * afterCreateRow: [],
2352
+ * beforeInit: [],
2353
+ * ...
2354
+ * }
2355
+ * ```
2356
+ */
2357
+ _createClass(Hooks, [{
2358
+ key: "createEmptyBucket",
2359
+ value: function createEmptyBucket() {
2360
+ var bucket = Object.create(null);
2361
+
2362
+ // eslint-disable-next-line no-return-assign
2363
+ (0, _array.arrayEach)(REGISTERED_HOOKS, function (hook) {
2364
+ return bucket[hook] = [];
2365
+ });
2366
+ return bucket;
2367
+ }
2368
+
2369
+ /**
2370
+ * Get hook bucket based on the context of the object or if argument is `undefined`, get the global hook bucket.
2371
+ *
2372
+ * @param {object} [context=null] A Handsontable instance.
2373
+ * @returns {object} Returns a global or Handsontable instance bucket.
2374
+ */
2375
+ }, {
2376
+ key: "getBucket",
2377
+ value: function getBucket() {
2378
+ var context = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : null;
2379
+ if (context) {
2380
+ if (!context.pluginHookBucket) {
2381
+ context.pluginHookBucket = this.createEmptyBucket();
2382
+ }
2383
+ return context.pluginHookBucket;
2384
+ }
2385
+ return this.globalBucket;
2386
+ }
2387
+
2388
+ /**
2389
+ * Adds a listener (globally or locally) to a specified hook name.
2390
+ * If the `context` parameter is provided, the hook will be added only to the instance it references.
2391
+ * Otherwise, the callback will be used everytime the hook fires on any Handsontable instance.
2392
+ * You can provide an array of callback functions as the `callback` argument, this way they will all be fired
2393
+ * once the hook is triggered.
2394
+ *
2395
+ * @see Core#addHook
2396
+ * @param {string} key Hook name.
2397
+ * @param {Function|Array} callback Callback function or an array of functions.
2398
+ * @param {object} [context=null] The context for the hook callback to be added - a Handsontable instance or leave empty.
2399
+ * @returns {Hooks} Instance of Hooks.
2400
+ *
2401
+ * @example
2402
+ * ```js
2403
+ * // single callback, added locally
2404
+ * Handsontable.hooks.add('beforeInit', myCallback, hotInstance);
2405
+ *
2406
+ * // single callback, added globally
2407
+ * Handsontable.hooks.add('beforeInit', myCallback);
2408
+ *
2409
+ * // multiple callbacks, added locally
2410
+ * Handsontable.hooks.add('beforeInit', [myCallback, anotherCallback], hotInstance);
2411
+ *
2412
+ * // multiple callbacks, added globally
2413
+ * Handsontable.hooks.add('beforeInit', [myCallback, anotherCallback]);
2414
+ * ```
2415
+ */
2416
+ }, {
2417
+ key: "add",
2418
+ value: function add(key, callback) {
2419
+ var _this = this;
2420
+ var context = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : null;
2421
+ if (Array.isArray(callback)) {
2422
+ (0, _array.arrayEach)(callback, function (c) {
2423
+ return _this.add(key, c, context);
2424
+ });
2425
+ } else {
2426
+ if (REMOVED_HOOKS.has(key)) {
2427
+ (0, _console.warn)((0, _string.substitute)(REMOVED_MESSAGE, {
2428
+ hookName: key,
2429
+ removedInVersion: REMOVED_HOOKS.get(key)
2430
+ }));
2431
+ }
2432
+ if (DEPRECATED_HOOKS.has(key)) {
2433
+ (0, _console.warn)(DEPRECATED_HOOKS.get(key));
2434
+ }
2435
+ var bucket = this.getBucket(context);
2436
+ if (typeof bucket[key] === 'undefined') {
2437
+ this.register(key);
2438
+ bucket[key] = [];
2439
+ }
2440
+ callback.skip = false;
2441
+ if (bucket[key].indexOf(callback) === -1) {
2442
+ // only add a hook if it has not already been added (adding the same hook twice is now silently ignored)
2443
+ var foundInitialHook = false;
2444
+ if (callback.initialHook) {
2445
+ (0, _array.arrayEach)(bucket[key], function (cb, i) {
2446
+ if (cb.initialHook) {
2447
+ bucket[key][i] = callback;
2448
+ foundInitialHook = true;
2449
+ return false;
2450
+ }
2451
+ });
2452
+ }
2453
+ if (!foundInitialHook) {
2454
+ bucket[key].push(callback);
2455
+ }
2456
+ }
2457
+ }
2458
+ return this;
2459
+ }
2460
+
2461
+ /**
2462
+ * Adds a listener to a specified hook. After the hook runs this listener will be automatically removed from the bucket.
2463
+ *
2464
+ * @see Core#addHookOnce
2465
+ * @param {string} key Hook/Event name.
2466
+ * @param {Function|Array} callback Callback function.
2467
+ * @param {object} [context=null] A Handsontable instance.
2468
+ *
2469
+ * @example
2470
+ * ```js
2471
+ * Handsontable.hooks.once('beforeInit', myCallback, hotInstance);
2472
+ * ```
2473
+ */
2474
+ }, {
2475
+ key: "once",
2476
+ value: function once(key, callback) {
2477
+ var _this2 = this;
2478
+ var context = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : null;
2479
+ if (Array.isArray(callback)) {
2480
+ (0, _array.arrayEach)(callback, function (c) {
2481
+ return _this2.once(key, c, context);
2482
+ });
2483
+ } else {
2484
+ callback.runOnce = true;
2485
+ this.add(key, callback, context);
2486
+ }
2487
+ }
2488
+
2489
+ /**
2490
+ * Removes a listener from a hook with a given name. If the `context` argument is provided, it removes a listener from a local hook assigned to the given Handsontable instance.
2491
+ *
2492
+ * @see Core#removeHook
2493
+ * @param {string} key Hook/Event name.
2494
+ * @param {Function} callback Callback function (needs the be the function that was previously added to the hook).
2495
+ * @param {object} [context=null] Handsontable instance.
2496
+ * @returns {boolean} Returns `true` if hook was removed, `false` otherwise.
2497
+ *
2498
+ * @example
2499
+ * ```js
2500
+ * Handsontable.hooks.remove('beforeInit', myCallback);
2501
+ * ```
2502
+ */
2503
+ }, {
2504
+ key: "remove",
2505
+ value: function remove(key, callback) {
2506
+ var context = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : null;
2507
+ var bucket = this.getBucket(context);
2508
+ if (typeof bucket[key] !== 'undefined') {
2509
+ if (bucket[key].indexOf(callback) >= 0) {
2510
+ callback.skip = true;
2511
+ return true;
2512
+ }
2513
+ }
2514
+ return false;
2515
+ }
2516
+
2517
+ /**
2518
+ * Checks whether there are any registered listeners for the provided hook name.
2519
+ * If the `context` parameter is provided, it only checks for listeners assigned to the given Handsontable instance.
2520
+ *
2521
+ * @param {string} key Hook name.
2522
+ * @param {object} [context=null] A Handsontable instance.
2523
+ * @returns {boolean} `true` for success, `false` otherwise.
2524
+ */
2525
+ }, {
2526
+ key: "has",
2527
+ value: function has(key) {
2528
+ var context = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : null;
2529
+ var bucket = this.getBucket(context);
2530
+ return !!(bucket[key] !== void 0 && bucket[key].length);
2531
+ }
2532
+
2533
+ /**
2534
+ * Runs all local and global callbacks assigned to the hook identified by the `key` parameter.
2535
+ * It returns either a return value from the last called callback or the first parameter (`p1`) passed to the `run` function.
2536
+ *
2537
+ * @see Core#runHooks
2538
+ * @param {object} context Handsontable instance.
2539
+ * @param {string} key Hook/Event name.
2540
+ * @param {*} [p1] Parameter to be passed as an argument to the callback function.
2541
+ * @param {*} [p2] Parameter to be passed as an argument to the callback function.
2542
+ * @param {*} [p3] Parameter to be passed as an argument to the callback function.
2543
+ * @param {*} [p4] Parameter to be passed as an argument to the callback function.
2544
+ * @param {*} [p5] Parameter to be passed as an argument to the callback function.
2545
+ * @param {*} [p6] Parameter to be passed as an argument to the callback function.
2546
+ * @returns {*} Either a return value from the last called callback or `p1`.
2547
+ *
2548
+ * @example
2549
+ * ```js
2550
+ * Handsontable.hooks.run(hot, 'beforeInit');
2551
+ * ```
2552
+ */
2553
+ }, {
2554
+ key: "run",
2555
+ value: function run(context, key, p1, p2, p3, p4, p5, p6) {
2556
+ {
2557
+ var globalHandlers = this.globalBucket[key];
2558
+ var length = globalHandlers ? globalHandlers.length : 0;
2559
+ var index = 0;
2560
+ if (length) {
2561
+ // Do not optimise this loop with arrayEach or arrow function! If you do You'll decrease perf because of GC.
2562
+ while (index < length) {
2563
+ if (!globalHandlers[index] || globalHandlers[index].skip) {
2564
+ index += 1;
2565
+ /* eslint-disable no-continue */
2566
+ continue;
2567
+ }
2568
+ var res = (0, _function.fastCall)(globalHandlers[index], context, p1, p2, p3, p4, p5, p6);
2569
+ if (res !== void 0) {
2570
+ // eslint-disable-next-line no-param-reassign
2571
+ p1 = res;
2572
+ }
2573
+ if (globalHandlers[index] && globalHandlers[index].runOnce) {
2574
+ this.remove(key, globalHandlers[index]);
2575
+ }
2576
+ index += 1;
2577
+ }
2578
+ }
2579
+ }
2580
+ {
2581
+ var localHandlers = this.getBucket(context)[key];
2582
+ var _length = localHandlers ? localHandlers.length : 0;
2583
+ var _index = 0;
2584
+ if (_length) {
2585
+ // Do not optimise this loop with arrayEach or arrow function! If you do You'll decrease perf because of GC.
2586
+ while (_index < _length) {
2587
+ if (!localHandlers[_index] || localHandlers[_index].skip) {
2588
+ _index += 1;
2589
+ /* eslint-disable no-continue */
2590
+ continue;
2591
+ }
2592
+ var _res = (0, _function.fastCall)(localHandlers[_index], context, p1, p2, p3, p4, p5, p6);
2593
+ if (_res !== void 0) {
2594
+ // eslint-disable-next-line no-param-reassign
2595
+ p1 = _res;
2596
+ }
2597
+ if (localHandlers[_index] && localHandlers[_index].runOnce) {
2598
+ this.remove(key, localHandlers[_index], context);
2599
+ }
2600
+ _index += 1;
2601
+ }
2602
+ }
2603
+ }
2604
+ return p1;
2605
+ }
2606
+
2607
+ /**
2608
+ * Destroy all listeners connected to the context. If no context is provided, the global listeners will be destroyed.
2609
+ *
2610
+ * @param {object} [context=null] A Handsontable instance.
2611
+ * @example
2612
+ * ```js
2613
+ * // destroy the global listeners
2614
+ * Handsontable.hooks.destroy();
2615
+ *
2616
+ * // destroy the local listeners
2617
+ * Handsontable.hooks.destroy(hotInstance);
2618
+ * ```
2619
+ */
2620
+ }, {
2621
+ key: "destroy",
2622
+ value: function destroy() {
2623
+ var context = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : null;
2624
+ // eslint-disable-next-line no-return-assign
2625
+ (0, _object.objectEach)(this.getBucket(context), function (value, key, bucket) {
2626
+ return bucket[key].length = 0;
2627
+ });
2628
+ }
2629
+
2630
+ /**
2631
+ * Registers a hook name (adds it to the list of the known hook names). Used by plugins.
2632
+ * It is not necessary to call register, but if you use it, your plugin hook will be used returned by
2633
+ * the `getRegistered` method. (which itself is used in the [demo](@/guides/getting-started/events-and-hooks.md)).
2634
+ *
2635
+ * @param {string} key The hook name.
2636
+ *
2637
+ * @example
2638
+ * ```js
2639
+ * Handsontable.hooks.register('myHook');
2640
+ * ```
2641
+ */
2642
+ }, {
2643
+ key: "register",
2644
+ value: function register(key) {
2645
+ if (!this.isRegistered(key)) {
2646
+ REGISTERED_HOOKS.push(key);
2647
+ }
2648
+ }
2649
+
2650
+ /**
2651
+ * Deregisters a hook name (removes it from the list of known hook names).
2652
+ *
2653
+ * @param {string} key The hook name.
2654
+ *
2655
+ * @example
2656
+ * ```js
2657
+ * Handsontable.hooks.deregister('myHook');
2658
+ * ```
2659
+ */
2660
+ }, {
2661
+ key: "deregister",
2662
+ value: function deregister(key) {
2663
+ if (this.isRegistered(key)) {
2664
+ REGISTERED_HOOKS.splice(REGISTERED_HOOKS.indexOf(key), 1);
2665
+ }
2666
+ }
2667
+
2668
+ /**
2669
+ * Returns a boolean value depending on if a hook by such name has been removed or deprecated.
2670
+ *
2671
+ * @param {string} hookName The hook name to check.
2672
+ * @returns {boolean} Returns `true` if the provided hook name was marked as deprecated or
2673
+ * removed from API, `false` otherwise.
2674
+ * @example
2675
+ * ```js
2676
+ * Handsontable.hooks.isDeprecated('skipLengthCache');
2677
+ *
2678
+ * // Results:
2679
+ * true
2680
+ * ```
2681
+ */
2682
+ }, {
2683
+ key: "isDeprecated",
2684
+ value: function isDeprecated(hookName) {
2685
+ return DEPRECATED_HOOKS.has(hookName) || REMOVED_HOOKS.has(hookName);
2686
+ }
2687
+
2688
+ /**
2689
+ * Returns a boolean depending on if a hook by such name has been registered.
2690
+ *
2691
+ * @param {string} hookName The hook name to check.
2692
+ * @returns {boolean} `true` for success, `false` otherwise.
2693
+ * @example
2694
+ * ```js
2695
+ * Handsontable.hooks.isRegistered('beforeInit');
2696
+ *
2697
+ * // Results:
2698
+ * true
2699
+ * ```
2700
+ */
2701
+ }, {
2702
+ key: "isRegistered",
2703
+ value: function isRegistered(hookName) {
2704
+ return REGISTERED_HOOKS.indexOf(hookName) >= 0;
2705
+ }
2706
+
2707
+ /**
2708
+ * Returns an array of registered hooks.
2709
+ *
2710
+ * @returns {Array} An array of registered hooks.
2711
+ *
2712
+ * @example
2713
+ * ```js
2714
+ * Handsontable.hooks.getRegistered();
2715
+ *
2716
+ * // Results:
2717
+ * [
2718
+ * ...
2719
+ * 'beforeInit',
2720
+ * 'beforeRender',
2721
+ * 'beforeSetRangeEnd',
2722
+ * 'beforeDrawBorders',
2723
+ * 'beforeChange',
2724
+ * ...
2725
+ * ]
2726
+ * ```
2727
+ */
2728
+ }, {
2729
+ key: "getRegistered",
2730
+ value: function getRegistered() {
2731
+ return REGISTERED_HOOKS;
2732
+ }
2733
+ }], [{
2734
+ key: "getSingleton",
2735
+ value: function getSingleton() {
2736
+ return getGlobalSingleton();
2737
+ }
2738
+ }]);
2739
+ return Hooks;
2740
+ }();
2741
+ var globalSingleton = new Hooks();
2742
+
2743
+ /**
2744
+ * @returns {Hooks}
2745
+ */
2746
+ function getGlobalSingleton() {
2747
+ return globalSingleton;
2748
+ }
2749
+ var _default = Hooks;
2750
+ exports.default = _default;