@highcharts/grid-pro 2.1.0 → 2.2.0

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.
Files changed (373) hide show
  1. package/css/grid-pro.css +428 -432
  2. package/es-modules/Accessibility/A11yI18n.js +3 -3
  3. package/es-modules/Accessibility/Accessibility.js +4 -3
  4. package/es-modules/Accessibility/AccessibilityComponent.d.ts +1 -1
  5. package/es-modules/Accessibility/AccessibilityComponent.js +4 -3
  6. package/es-modules/Accessibility/Components/AnnotationsA11y.js +4 -3
  7. package/es-modules/Accessibility/Components/ContainerComponent.js +4 -3
  8. package/es-modules/Accessibility/Components/InfoRegionsComponent.js +4 -3
  9. package/es-modules/Accessibility/Components/LegendComponent.js +4 -3
  10. package/es-modules/Accessibility/Components/MenuComponent.js +4 -3
  11. package/es-modules/Accessibility/Components/NavigatorComponent.js +3 -3
  12. package/es-modules/Accessibility/Components/RangeSelectorComponent.js +4 -3
  13. package/es-modules/Accessibility/Components/SeriesComponent/ForcedMarkers.js +14 -3
  14. package/es-modules/Accessibility/Components/SeriesComponent/NewDataAnnouncer.js +4 -3
  15. package/es-modules/Accessibility/Components/SeriesComponent/SeriesComponent.js +4 -3
  16. package/es-modules/Accessibility/Components/SeriesComponent/SeriesDescriber.js +4 -3
  17. package/es-modules/Accessibility/Components/SeriesComponent/SeriesKeyboardNavigation.js +4 -3
  18. package/es-modules/Accessibility/Components/ZoomComponent.js +4 -3
  19. package/es-modules/Accessibility/FocusBorder.js +4 -3
  20. package/es-modules/Accessibility/HighContrastMode.js +4 -3
  21. package/es-modules/Accessibility/HighContrastTheme.js +4 -3
  22. package/es-modules/Accessibility/KeyboardNavigation.js +4 -3
  23. package/es-modules/Accessibility/KeyboardNavigationHandler.js +4 -3
  24. package/es-modules/Accessibility/Options/A11yDefaults.js +4 -3
  25. package/es-modules/Accessibility/Options/DeprecatedOptions.js +4 -3
  26. package/es-modules/Accessibility/Options/LangDefaults.js +4 -3
  27. package/es-modules/Accessibility/ProxyElement.js +4 -3
  28. package/es-modules/Accessibility/ProxyProvider.js +4 -3
  29. package/es-modules/Accessibility/Utils/Announcer.js +4 -3
  30. package/es-modules/Accessibility/Utils/ChartUtilities.js +4 -3
  31. package/es-modules/Accessibility/Utils/DOMElementProvider.js +4 -3
  32. package/es-modules/Accessibility/Utils/EventProvider.d.ts +1 -1
  33. package/es-modules/Accessibility/Utils/EventProvider.js +4 -3
  34. package/es-modules/Accessibility/Utils/HTMLUtilities.js +4 -3
  35. package/es-modules/Core/Animation/AnimationOptions.d.ts +42 -0
  36. package/es-modules/Core/Animation/AnimationOptions.js +10 -0
  37. package/es-modules/Core/Animation/AnimationUtilities.js +39 -3
  38. package/es-modules/Core/Animation/Fx.d.ts +1 -130
  39. package/es-modules/Core/Animation/Fx.js +13 -6
  40. package/es-modules/Core/Animation/FxBase.d.ts +1 -0
  41. package/es-modules/Core/Animation/FxBase.js +11 -0
  42. package/es-modules/Core/Callback.d.ts +49 -0
  43. package/es-modules/Core/Callback.js +10 -0
  44. package/es-modules/Core/Chart/Chart.d.ts +659 -400
  45. package/es-modules/Core/Chart/Chart.js +64 -54
  46. package/es-modules/Core/Chart/Chart3D.d.ts +123 -233
  47. package/es-modules/Core/Chart/Chart3D.js +22 -35
  48. package/es-modules/Core/Chart/ChartBase.d.ts +3 -0
  49. package/es-modules/Core/Chart/ChartBase.js +11 -0
  50. package/es-modules/Core/Chart/ChartDefaults.js +7 -12
  51. package/es-modules/Core/Chart/ChartNavigationComposition.d.ts +1 -55
  52. package/es-modules/Core/Chart/ChartNavigationComposition.js +13 -13
  53. package/es-modules/Core/Chart/ChartOptions.d.ts +1217 -0
  54. package/es-modules/Core/Chart/ChartOptions.js +10 -0
  55. package/es-modules/Core/Chart/GanttChart.d.ts +0 -38
  56. package/es-modules/Core/Chart/GanttChart.js +4 -3
  57. package/es-modules/Core/Chart/MapChart.d.ts +9 -4
  58. package/es-modules/Core/Chart/MapChart.js +13 -3
  59. package/es-modules/Core/Chart/StockChart.d.ts +0 -85
  60. package/es-modules/Core/Chart/StockChart.js +33 -15
  61. package/es-modules/Core/Color/Color.d.ts +16 -24
  62. package/es-modules/Core/Color/Color.js +26 -8
  63. package/es-modules/Core/Color/ColorString.d.ts +0 -23
  64. package/es-modules/Core/Color/ColorString.js +11 -0
  65. package/es-modules/Core/Color/ColorType.d.ts +0 -33
  66. package/es-modules/Core/Color/ColorType.js +11 -0
  67. package/es-modules/Core/Color/GradientColor.d.ts +0 -33
  68. package/es-modules/Core/Color/GradientColor.js +11 -0
  69. package/es-modules/Core/Color/Palettes.d.ts +1 -84
  70. package/es-modules/Core/Color/Palettes.js +2 -1
  71. package/es-modules/Core/Defaults.d.ts +6 -0
  72. package/es-modules/Core/Defaults.js +30 -66
  73. package/es-modules/Core/Foundation.d.ts +1 -19
  74. package/es-modules/Core/Foundation.js +7 -4
  75. package/es-modules/Core/Geometry/CircleObject.d.ts +5 -0
  76. package/es-modules/Core/Geometry/CircleObject.js +10 -0
  77. package/es-modules/Core/Geometry/CircleUtilities.d.ts +1 -189
  78. package/es-modules/Core/Geometry/CircleUtilities.js +17 -15
  79. package/es-modules/Core/Geometry/GeometryObject.d.ts +7 -0
  80. package/es-modules/Core/Geometry/GeometryObject.js +10 -0
  81. package/es-modules/Core/Geometry/GeometryUtilities.d.ts +1 -48
  82. package/es-modules/Core/Geometry/GeometryUtilities.js +9 -7
  83. package/es-modules/Core/Geometry/IntersectionObject.d.ts +7 -0
  84. package/es-modules/Core/Geometry/IntersectionObject.js +10 -0
  85. package/es-modules/Core/Geometry/PolygonClip.d.ts +1 -19
  86. package/es-modules/Core/Geometry/PolygonClip.js +9 -7
  87. package/es-modules/Core/Globals.d.ts +9 -31
  88. package/es-modules/Core/Globals.js +9 -10
  89. package/es-modules/Core/GlobalsBase.d.ts +35 -0
  90. package/es-modules/Core/GlobalsBase.js +11 -0
  91. package/es-modules/Core/HttpUtilities.d.ts +54 -17
  92. package/es-modules/Core/HttpUtilities.js +15 -14
  93. package/es-modules/Core/JSON.d.ts +29 -0
  94. package/es-modules/Core/JSON.js +13 -0
  95. package/es-modules/Core/KeyboardEvent.d.ts +1 -0
  96. package/es-modules/Core/KeyboardEvent.js +11 -0
  97. package/es-modules/Core/MSPointer.d.ts +1 -74
  98. package/es-modules/Core/MSPointer.js +23 -13
  99. package/es-modules/Core/Math3D.d.ts +1 -117
  100. package/es-modules/Core/Math3D.js +13 -10
  101. package/es-modules/Core/Options.d.ts +334 -0
  102. package/es-modules/Core/Options.js +10 -0
  103. package/es-modules/Core/Pointer.d.ts +71 -445
  104. package/es-modules/Core/Pointer.js +51 -65
  105. package/es-modules/Core/PointerEvent.d.ts +18 -0
  106. package/es-modules/Core/PointerEvent.js +11 -0
  107. package/es-modules/Core/Renderer/AlignObject.d.ts +25 -27
  108. package/es-modules/Core/Renderer/AlignObject.js +11 -0
  109. package/es-modules/Core/Renderer/BBoxObject.d.ts +20 -31
  110. package/es-modules/Core/Renderer/BBoxObject.js +11 -0
  111. package/es-modules/Core/Renderer/CSSObject.d.ts +268 -59
  112. package/es-modules/Core/Renderer/CSSObject.js +10 -0
  113. package/es-modules/Core/Renderer/DOMElementType.d.ts +1 -33
  114. package/es-modules/Core/Renderer/DOMElementType.js +11 -0
  115. package/es-modules/Core/Renderer/DashStyleValue.d.ts +1 -27
  116. package/es-modules/Core/Renderer/DashStyleValue.js +11 -0
  117. package/es-modules/Core/Renderer/FontMetricsObject.d.ts +6 -26
  118. package/es-modules/Core/Renderer/FontMetricsObject.js +11 -0
  119. package/es-modules/Core/Renderer/HTML/AST.d.ts +3 -15
  120. package/es-modules/Core/Renderer/HTML/AST.js +22 -13
  121. package/es-modules/Core/Renderer/HTML/HTMLAttributes.d.ts +1 -25
  122. package/es-modules/Core/Renderer/HTML/HTMLAttributes.js +11 -0
  123. package/es-modules/Core/Renderer/HTML/HTMLElement.d.ts +0 -54
  124. package/es-modules/Core/Renderer/HTML/HTMLElement.js +27 -22
  125. package/es-modules/Core/Renderer/PolygonBoxObject.d.ts +15 -12
  126. package/es-modules/Core/Renderer/PolygonBoxObject.js +11 -0
  127. package/es-modules/Core/Renderer/Position3DObject.d.ts +6 -30
  128. package/es-modules/Core/Renderer/Position3DObject.js +11 -0
  129. package/es-modules/Core/Renderer/PositionObject.d.ts +9 -23
  130. package/es-modules/Core/Renderer/PositionObject.js +11 -0
  131. package/es-modules/Core/Renderer/RectangleObject.d.ts +6 -30
  132. package/es-modules/Core/Renderer/RectangleObject.js +11 -0
  133. package/es-modules/Core/Renderer/RendererRegistry.d.ts +1 -29
  134. package/es-modules/Core/Renderer/RendererRegistry.js +6 -3
  135. package/es-modules/Core/Renderer/RendererType.d.ts +1 -53
  136. package/es-modules/Core/Renderer/RendererType.js +11 -0
  137. package/es-modules/Core/Renderer/RendererUtilities.d.ts +1 -26
  138. package/es-modules/Core/Renderer/RendererUtilities.js +7 -4
  139. package/es-modules/Core/Renderer/SVG/ButtonThemeObject.d.ts +26 -31
  140. package/es-modules/Core/Renderer/SVG/SVGArc3D.d.ts +1 -44
  141. package/es-modules/Core/Renderer/SVG/SVGAttributes.d.ts +15 -51
  142. package/es-modules/Core/Renderer/SVG/SVGAttributes3D.d.ts +1 -42
  143. package/es-modules/Core/Renderer/SVG/SVGCuboid.d.ts +1 -42
  144. package/es-modules/Core/Renderer/SVG/SVGElement.d.ts +459 -0
  145. package/es-modules/Core/Renderer/SVG/SVGElement3D.d.ts +1 -0
  146. package/es-modules/Core/Renderer/SVG/SVGElementBase.d.ts +0 -23
  147. package/es-modules/Core/Renderer/SVG/SVGLabel.d.ts +14 -0
  148. package/es-modules/Core/Renderer/SVG/SVGPath.d.ts +18 -56
  149. package/es-modules/Core/Renderer/SVG/SVGPath3D.d.ts +0 -30
  150. package/es-modules/Core/Renderer/SVG/SVGRenderer.d.ts +652 -0
  151. package/es-modules/Core/Renderer/SVG/SVGRenderer3D.d.ts +1 -0
  152. package/es-modules/Core/Renderer/SVG/SVGRendererBase.d.ts +0 -24
  153. package/es-modules/Core/Renderer/SVG/SymbolOptions.d.ts +3 -26
  154. package/es-modules/Core/Renderer/SVG/SymbolType.d.ts +1 -41
  155. package/es-modules/Core/Renderer/SVG/Symbols.d.ts +146 -0
  156. package/es-modules/Core/Renderer/SVG/TextBuilder.d.ts +1 -0
  157. package/es-modules/Core/Renderer/ShadowOptionsObject.d.ts +21 -30
  158. package/es-modules/Core/Renderer/ShadowOptionsObject.js +11 -0
  159. package/es-modules/Core/Renderer/SizeObject.d.ts +0 -23
  160. package/es-modules/Core/Renderer/SizeObject.js +11 -0
  161. package/es-modules/Core/Responsive.d.ts +91 -28
  162. package/es-modules/Core/Responsive.js +7 -8
  163. package/es-modules/Core/Templating.d.ts +16 -0
  164. package/es-modules/Core/Templating.js +9 -4
  165. package/es-modules/Core/Time.d.ts +10 -1
  166. package/es-modules/Core/Time.js +4 -3
  167. package/es-modules/Core/Tooltip.d.ts +63 -115
  168. package/es-modules/Core/Tooltip.js +61 -27
  169. package/es-modules/Core/TooltipOptions.d.ts +681 -0
  170. package/es-modules/Core/TooltipOptions.js +10 -0
  171. package/es-modules/Core/Utilities.d.ts +75 -106
  172. package/es-modules/Core/Utilities.js +19 -53
  173. package/es-modules/Data/ColumnUtils.js +3 -3
  174. package/es-modules/Data/Connectors/CSVConnector.js +3 -3
  175. package/es-modules/Data/Connectors/CSVConnectorOptions.d.ts +3 -3
  176. package/es-modules/Data/Connectors/DataConnector.d.ts +12 -1
  177. package/es-modules/Data/Connectors/DataConnector.js +34 -4
  178. package/es-modules/Data/Connectors/DataConnectorOptions.d.ts +3 -3
  179. package/es-modules/Data/Connectors/DataConnectorType.d.ts +3 -3
  180. package/es-modules/Data/Connectors/GoogleSheetsConnector.js +3 -3
  181. package/es-modules/Data/Connectors/GoogleSheetsConnectorOptions.d.ts +3 -3
  182. package/es-modules/Data/Connectors/HTMLTableConnector.js +3 -3
  183. package/es-modules/Data/Connectors/HTMLTableConnectorOptions.d.ts +3 -3
  184. package/es-modules/Data/Connectors/JSONConnector.js +3 -3
  185. package/es-modules/Data/Connectors/JSONConnectorOptions.d.ts +3 -3
  186. package/es-modules/Data/Converters/CSVConverter.js +3 -3
  187. package/es-modules/Data/Converters/CSVConverterOptions.d.ts +3 -3
  188. package/es-modules/Data/Converters/DataConverter.js +3 -3
  189. package/es-modules/Data/Converters/DataConverterType.d.ts +3 -3
  190. package/es-modules/Data/Converters/DataConverterUtils.js +3 -3
  191. package/es-modules/Data/Converters/GoogleSheetsConverter.js +3 -3
  192. package/es-modules/Data/Converters/GoogleSheetsConverterOptions.d.ts +3 -3
  193. package/es-modules/Data/Converters/HTMLTableConverter.js +3 -3
  194. package/es-modules/Data/Converters/HTMLTableConverterOptions.d.ts +3 -3
  195. package/es-modules/Data/Converters/JSONConverter.js +3 -3
  196. package/es-modules/Data/Converters/JSONConverterOptions.d.ts +3 -3
  197. package/es-modules/Data/DataCursor.js +3 -3
  198. package/es-modules/Data/DataEvent.js +3 -3
  199. package/es-modules/Data/DataPool.js +3 -3
  200. package/es-modules/Data/DataPoolOptions.d.ts +3 -3
  201. package/es-modules/Data/DataTable.d.ts +6 -6
  202. package/es-modules/Data/DataTable.js +64 -30
  203. package/es-modules/Data/DataTableCore.d.ts +2 -2
  204. package/es-modules/Data/DataTableCore.js +5 -5
  205. package/es-modules/Data/DataTableOptions.js +3 -3
  206. package/es-modules/Data/Formula/Formula.js +3 -3
  207. package/es-modules/Data/Formula/FormulaParser.js +3 -3
  208. package/es-modules/Data/Formula/FormulaProcessor.js +3 -3
  209. package/es-modules/Data/Formula/FormulaTypes.js +3 -3
  210. package/es-modules/Data/Formula/Functions/ABS.js +3 -3
  211. package/es-modules/Data/Formula/Functions/AND.js +3 -3
  212. package/es-modules/Data/Formula/Functions/AVERAGE.js +3 -3
  213. package/es-modules/Data/Formula/Functions/AVERAGEA.js +3 -3
  214. package/es-modules/Data/Formula/Functions/COUNT.js +3 -3
  215. package/es-modules/Data/Formula/Functions/COUNTA.js +3 -3
  216. package/es-modules/Data/Formula/Functions/IF.js +3 -3
  217. package/es-modules/Data/Formula/Functions/ISNA.js +3 -3
  218. package/es-modules/Data/Formula/Functions/MAX.js +3 -3
  219. package/es-modules/Data/Formula/Functions/MEDIAN.js +3 -3
  220. package/es-modules/Data/Formula/Functions/MIN.js +3 -3
  221. package/es-modules/Data/Formula/Functions/MOD.js +3 -3
  222. package/es-modules/Data/Formula/Functions/MODE.js +3 -3
  223. package/es-modules/Data/Formula/Functions/NOT.js +3 -3
  224. package/es-modules/Data/Formula/Functions/OR.js +3 -3
  225. package/es-modules/Data/Formula/Functions/PRODUCT.js +3 -3
  226. package/es-modules/Data/Formula/Functions/SUM.js +3 -3
  227. package/es-modules/Data/Formula/Functions/XOR.js +3 -3
  228. package/es-modules/Data/Modifiers/ChainModifier.js +3 -3
  229. package/es-modules/Data/Modifiers/ChainModifierOptions.js +3 -3
  230. package/es-modules/Data/Modifiers/DataModifier.js +3 -3
  231. package/es-modules/Data/Modifiers/DataModifierEvent.js +3 -3
  232. package/es-modules/Data/Modifiers/DataModifierOptions.js +3 -3
  233. package/es-modules/Data/Modifiers/DataModifierType.d.ts +3 -3
  234. package/es-modules/Data/Modifiers/FilterModifier.js +3 -3
  235. package/es-modules/Data/Modifiers/FilterModifierOptions.js +3 -3
  236. package/es-modules/Data/Modifiers/InvertModifier.js +3 -3
  237. package/es-modules/Data/Modifiers/InvertModifierOptions.js +3 -3
  238. package/es-modules/Data/Modifiers/MathModifier.js +3 -3
  239. package/es-modules/Data/Modifiers/MathModifierOptions.js +3 -3
  240. package/es-modules/Data/Modifiers/RangeModifier.js +3 -3
  241. package/es-modules/Data/Modifiers/RangeModifierOptions.js +3 -3
  242. package/es-modules/Data/Modifiers/SortModifier.js +32 -6
  243. package/es-modules/Data/Modifiers/SortModifierOptions.d.ts +41 -4
  244. package/es-modules/Data/Modifiers/SortModifierOptions.js +3 -3
  245. package/es-modules/Grid/Core/Accessibility/A11yOptions.d.ts +77 -0
  246. package/es-modules/Grid/Core/Accessibility/A11yOptions.js +4 -3
  247. package/es-modules/Grid/Core/Accessibility/Accessibility.d.ts +67 -0
  248. package/es-modules/Grid/Core/Accessibility/Accessibility.js +176 -3
  249. package/es-modules/Grid/Core/Credits.js +3 -3
  250. package/es-modules/Grid/Core/Defaults.js +17 -5
  251. package/es-modules/Grid/Core/Globals.d.ts +4 -4
  252. package/es-modules/Grid/Core/Globals.js +5 -5
  253. package/es-modules/Grid/Core/Grid.d.ts +12 -1
  254. package/es-modules/Grid/Core/Grid.js +110 -8
  255. package/es-modules/Grid/Core/GridUtils.js +3 -3
  256. package/es-modules/Grid/Core/Options.d.ts +17 -1
  257. package/es-modules/Grid/Core/Options.js +3 -3
  258. package/es-modules/Grid/Core/Pagination/Pagination.js +3 -3
  259. package/es-modules/Grid/Core/Pagination/PaginationOptions.d.ts +0 -40
  260. package/es-modules/Grid/Core/Pagination/PaginationOptions.js +11 -0
  261. package/es-modules/Grid/Core/Querying/FilteringController.js +3 -3
  262. package/es-modules/Grid/Core/Querying/PaginationController.js +3 -3
  263. package/es-modules/Grid/Core/Querying/QueryingController.js +3 -3
  264. package/es-modules/Grid/Core/Querying/SortingController.d.ts +15 -0
  265. package/es-modules/Grid/Core/Querying/SortingController.js +89 -51
  266. package/es-modules/Grid/Core/Table/Actions/ColumnFiltering/ColumnFiltering.js +3 -3
  267. package/es-modules/Grid/Core/Table/Actions/ColumnFiltering/FilterCell.d.ts +2 -2
  268. package/es-modules/Grid/Core/Table/Actions/ColumnFiltering/FilterCell.js +3 -3
  269. package/es-modules/Grid/Core/Table/Actions/ColumnFiltering/FilterRow.js +3 -3
  270. package/es-modules/Grid/Core/Table/Actions/ColumnFiltering/FilteringTypes.js +3 -3
  271. package/es-modules/Grid/Core/Table/Actions/ColumnSorting.d.ts +12 -2
  272. package/es-modules/Grid/Core/Table/Actions/ColumnSorting.js +85 -18
  273. package/es-modules/Grid/Core/Table/Actions/ColumnsResizer.js +3 -3
  274. package/es-modules/Grid/Core/Table/Actions/RowsVirtualizer.d.ts +37 -0
  275. package/es-modules/Grid/Core/Table/Actions/RowsVirtualizer.js +137 -26
  276. package/es-modules/Grid/Core/Table/Body/TableCell.d.ts +9 -2
  277. package/es-modules/Grid/Core/Table/Body/TableCell.js +15 -8
  278. package/es-modules/Grid/Core/Table/Body/TableRow.d.ts +18 -0
  279. package/es-modules/Grid/Core/Table/Body/TableRow.js +56 -10
  280. package/es-modules/Grid/Core/Table/Cell.d.ts +0 -7
  281. package/es-modules/Grid/Core/Table/Cell.js +5 -3
  282. package/es-modules/Grid/Core/Table/CellContent/CellContent.js +3 -3
  283. package/es-modules/Grid/Core/Table/CellContent/TextContent.js +4 -4
  284. package/es-modules/Grid/Core/Table/Column.d.ts +1 -1
  285. package/es-modules/Grid/Core/Table/Column.js +3 -3
  286. package/es-modules/Grid/Core/Table/ColumnResizing/AdjacentResizingMode.js +3 -3
  287. package/es-modules/Grid/Core/Table/ColumnResizing/ColumnResizing.js +3 -3
  288. package/es-modules/Grid/Core/Table/ColumnResizing/DistributedResizingMode.js +3 -3
  289. package/es-modules/Grid/Core/Table/ColumnResizing/IndependentResizingMode.js +3 -3
  290. package/es-modules/Grid/Core/Table/ColumnResizing/ResizingMode.js +3 -3
  291. package/es-modules/Grid/Core/Table/Header/ColumnToolbar/ColumnToolbar.js +14 -5
  292. package/es-modules/Grid/Core/Table/Header/ColumnToolbar/FilterPopup.js +3 -3
  293. package/es-modules/Grid/Core/Table/Header/ColumnToolbar/MenuButtons/FilterMenuButton.js +3 -3
  294. package/es-modules/Grid/Core/Table/Header/ColumnToolbar/MenuButtons/SortMenuButton.d.ts +9 -0
  295. package/es-modules/Grid/Core/Table/Header/ColumnToolbar/MenuButtons/SortMenuButton.js +35 -6
  296. package/es-modules/Grid/Core/Table/Header/ColumnToolbar/MenuPopup.js +5 -4
  297. package/es-modules/Grid/Core/Table/Header/ColumnToolbar/StateHelpers.js +11 -7
  298. package/es-modules/Grid/Core/Table/Header/ColumnToolbar/ToolbarButtons/FilterToolbarButton.js +3 -3
  299. package/es-modules/Grid/Core/Table/Header/ColumnToolbar/ToolbarButtons/MenuToolbarButton.js +3 -3
  300. package/es-modules/Grid/Core/Table/Header/ColumnToolbar/ToolbarButtons/SortToolbarButton.d.ts +5 -1
  301. package/es-modules/Grid/Core/Table/Header/ColumnToolbar/ToolbarButtons/SortToolbarButton.js +92 -9
  302. package/es-modules/Grid/Core/Table/Header/HeaderCell.d.ts +2 -2
  303. package/es-modules/Grid/Core/Table/Header/HeaderCell.js +8 -7
  304. package/es-modules/Grid/Core/Table/Header/HeaderRow.js +3 -3
  305. package/es-modules/Grid/Core/Table/Header/TableHeader.js +3 -3
  306. package/es-modules/Grid/Core/Table/Row.js +3 -3
  307. package/es-modules/Grid/Core/Table/Table.d.ts +30 -0
  308. package/es-modules/Grid/Core/Table/Table.js +118 -7
  309. package/es-modules/Grid/Core/UI/Button.js +3 -3
  310. package/es-modules/Grid/Core/UI/ContextMenu.js +3 -3
  311. package/es-modules/Grid/Core/UI/ContextMenuButton.js +3 -3
  312. package/es-modules/Grid/Core/UI/Popup.js +3 -3
  313. package/es-modules/Grid/Core/UI/SvgIcons.js +3 -3
  314. package/es-modules/Grid/Core/UI/Toolbar.js +3 -3
  315. package/es-modules/Grid/Core/UI/ToolbarButton.js +3 -3
  316. package/es-modules/Grid/Pro/CellEditing/CellEditMode.d.ts +3 -44
  317. package/es-modules/Grid/Pro/CellEditing/CellEditMode.js +16 -0
  318. package/es-modules/Grid/Pro/CellEditing/CellEditing.js +3 -3
  319. package/es-modules/Grid/Pro/CellEditing/CellEditingComposition.js +3 -3
  320. package/es-modules/Grid/Pro/CellRendering/CellContentPro.js +3 -3
  321. package/es-modules/Grid/Pro/CellRendering/CellRenderer.js +3 -3
  322. package/es-modules/Grid/Pro/CellRendering/CellRendererRegistry.js +3 -3
  323. package/es-modules/Grid/Pro/CellRendering/CellRendererType.d.ts +1 -34
  324. package/es-modules/Grid/Pro/CellRendering/CellRendererType.js +15 -0
  325. package/es-modules/Grid/Pro/CellRendering/CellRenderersComposition.js +3 -3
  326. package/es-modules/Grid/Pro/CellRendering/ContentTypes/CheckboxContent.js +3 -3
  327. package/es-modules/Grid/Pro/CellRendering/ContentTypes/DateInputContent.js +3 -3
  328. package/es-modules/Grid/Pro/CellRendering/ContentTypes/DateInputContentBase.js +3 -3
  329. package/es-modules/Grid/Pro/CellRendering/ContentTypes/DateTimeInputContent.js +3 -3
  330. package/es-modules/Grid/Pro/CellRendering/ContentTypes/NumberInputContent.js +3 -3
  331. package/es-modules/Grid/Pro/CellRendering/ContentTypes/SelectContent.js +3 -3
  332. package/es-modules/Grid/Pro/CellRendering/ContentTypes/SparklineContent.d.ts +7 -5
  333. package/es-modules/Grid/Pro/CellRendering/ContentTypes/SparklineContent.js +3 -3
  334. package/es-modules/Grid/Pro/CellRendering/ContentTypes/TextInputContent.js +3 -3
  335. package/es-modules/Grid/Pro/CellRendering/ContentTypes/TimeInputContent.js +3 -3
  336. package/es-modules/Grid/Pro/CellRendering/Renderers/CheckboxRenderer.js +3 -3
  337. package/es-modules/Grid/Pro/CellRendering/Renderers/DateInputRenderer.js +3 -3
  338. package/es-modules/Grid/Pro/CellRendering/Renderers/DateInputRendererBase.js +3 -3
  339. package/es-modules/Grid/Pro/CellRendering/Renderers/DateTimeInputRenderer.js +3 -3
  340. package/es-modules/Grid/Pro/CellRendering/Renderers/NumberInputRenderer.js +3 -3
  341. package/es-modules/Grid/Pro/CellRendering/Renderers/SelectRenderer.js +3 -3
  342. package/es-modules/Grid/Pro/CellRendering/Renderers/SparklineRenderer.d.ts +3 -3
  343. package/es-modules/Grid/Pro/CellRendering/Renderers/SparklineRenderer.js +3 -3
  344. package/es-modules/Grid/Pro/CellRendering/Renderers/TextInputRenderer.js +3 -3
  345. package/es-modules/Grid/Pro/CellRendering/Renderers/TextRenderer.js +3 -3
  346. package/es-modules/Grid/Pro/CellRendering/Renderers/TimeInputRenderer.js +3 -3
  347. package/es-modules/Grid/Pro/ColumnTypes/Validator.d.ts +10 -1
  348. package/es-modules/Grid/Pro/ColumnTypes/Validator.js +50 -8
  349. package/es-modules/Grid/Pro/ColumnTypes/ValidatorComposition.js +3 -3
  350. package/es-modules/Grid/Pro/Credits/CreditsPro.js +3 -3
  351. package/es-modules/Grid/Pro/Credits/CreditsProComposition.js +3 -3
  352. package/es-modules/Grid/Pro/Export/Exporting.js +4 -5
  353. package/es-modules/Grid/Pro/Export/ExportingComposition.js +3 -3
  354. package/es-modules/Grid/Pro/GridEvents.d.ts +1 -0
  355. package/es-modules/Grid/Pro/GridEvents.js +3 -3
  356. package/es-modules/Grid/Pro/Pagination/PaginationComposition.js +3 -3
  357. package/es-modules/Grid/index.js +3 -3
  358. package/es-modules/Shared/BaseForm.js +3 -3
  359. package/es-modules/Shared/DownloadURL.d.ts +1 -85
  360. package/es-modules/Shared/DownloadURL.js +14 -11
  361. package/es-modules/Shared/LangOptionsCore.d.ts +4 -3
  362. package/es-modules/Shared/TimeBase.d.ts +1 -46
  363. package/es-modules/Shared/TimeBase.js +8 -7
  364. package/es-modules/Shared/Types.d.ts +4 -3
  365. package/es-modules/masters/grid-pro.src.d.ts +8 -13
  366. package/es-modules/masters/grid-pro.src.js +15 -7
  367. package/grid-pro.d.ts +8 -13
  368. package/grid-pro.js +6 -5
  369. package/grid-pro.js.map +1 -1
  370. package/grid-pro.src.d.ts +8 -13
  371. package/grid-pro.src.js +1923 -721
  372. package/package.json +1 -9
  373. package/es-modules/Grid/Pro/highcharts.d.ts +0 -7
@@ -2,11 +2,11 @@
2
2
  *
3
3
  * Grid ColumnSorting class
4
4
  *
5
- * (c) 2020-2025 Highsoft AS
5
+ * (c) 2020-2026 Highsoft AS
6
6
  *
7
- * License: www.highcharts.com/license
7
+ * A commercial license may be required depending on use.
8
+ * See www.highcharts.com/license
8
9
  *
9
- * !!!!!!! SOURCE GETS TRANSPILED BY TYPESCRIPT. EDIT TS FILE ONLY. !!!!!!!
10
10
  *
11
11
  * Authors:
12
12
  * - Dawid Dragula
@@ -43,24 +43,35 @@ class ColumnSorting {
43
43
  constructor(column, headerCellElement) {
44
44
  /**
45
45
  * Toggle sorting order for the column in the order: asc -> desc -> none
46
+ *
47
+ * @param e
48
+ * Optional mouse or keyboard event.
46
49
  */
47
- this.toggle = () => {
50
+ this.toggle = (e) => {
48
51
  const viewport = this.column.viewport;
49
52
  const querying = viewport.grid.querying;
50
53
  const sortingController = querying.sorting;
51
- const currentOrder = (sortingController.currentSorting?.columnId === this.column.id ?
52
- sortingController.currentSorting.order : null) || 'none';
54
+ const additive = !!e?.shiftKey;
55
+ const currentOrder = (additive ?
56
+ sortingController.currentSortings?.find((sorting) => sorting.columnId === this.column.id)?.order :
57
+ (sortingController.currentSorting?.columnId ===
58
+ this.column.id ?
59
+ sortingController.currentSorting.order :
60
+ null)) || 'none';
53
61
  const consequents = {
54
62
  none: 'asc',
55
63
  asc: 'desc',
56
64
  desc: null
57
65
  };
58
- void this.setOrder(consequents[currentOrder]);
66
+ void this.setOrder(consequents[currentOrder], additive);
59
67
  };
60
68
  this.column = column;
61
69
  this.headerCellElement = headerCellElement;
62
70
  this.addHeaderElementAttributes();
63
- if (column.options.sorting?.sortable) {
71
+ const sortingOptions = column.options.sorting;
72
+ const sortingEnabled = sortingOptions?.enabled ??
73
+ sortingOptions?.sortable;
74
+ if (sortingEnabled) {
64
75
  headerCellElement.classList.add(Globals.getClassName('columnSortable'));
65
76
  }
66
77
  }
@@ -76,19 +87,25 @@ class ColumnSorting {
76
87
  const col = this.column;
77
88
  const a11y = col.viewport.grid.accessibility;
78
89
  const sortingOptions = col.options.sorting;
79
- const { currentSorting } = col.viewport.grid.querying.sorting;
90
+ const { currentSorting, currentSortings } = col.viewport.grid.querying.sorting;
80
91
  const sortedAscClassName = Globals.getClassName('columnSortedAsc');
81
92
  const sortedDescClassName = Globals.getClassName('columnSortedDesc');
82
93
  const el = this.headerCellElement;
83
- if (currentSorting?.columnId !== col.id || !currentSorting?.order) {
94
+ const sortingEnabled = sortingOptions?.enabled ??
95
+ sortingOptions?.sortable;
96
+ const columnSorting = (currentSortings?.find((sorting) => sorting.columnId === col.id) ||
97
+ (currentSorting?.columnId === col.id ?
98
+ currentSorting :
99
+ void 0));
100
+ if (!columnSorting?.order) {
84
101
  el.classList.remove(sortedAscClassName);
85
102
  el.classList.remove(sortedDescClassName);
86
- if (sortingOptions?.sortable) {
103
+ if (sortingEnabled) {
87
104
  a11y?.setColumnSortState(el, 'none');
88
105
  }
89
106
  return;
90
107
  }
91
- switch (currentSorting?.order) {
108
+ switch (columnSorting.order) {
92
109
  case 'asc':
93
110
  el.classList.add(sortedAscClassName);
94
111
  el.classList.remove(sortedDescClassName);
@@ -101,6 +118,12 @@ class ColumnSorting {
101
118
  break;
102
119
  }
103
120
  }
121
+ /**
122
+ * Refreshes the sorting-related header attributes and classes.
123
+ */
124
+ refreshHeaderAttributes() {
125
+ this.addHeaderElementAttributes();
126
+ }
104
127
  /**
105
128
  * Updates the column options with the new sorting state.
106
129
  *
@@ -108,12 +131,24 @@ class ColumnSorting {
108
131
  * The column to update.
109
132
  */
110
133
  updateColumnOptions(col) {
111
- const order = col.viewport.grid.querying.sorting.currentSorting?.order;
112
- if (col.id === this.column.id && order) {
113
- col.setOptions({ sorting: { order } });
134
+ const sortings = col.viewport.grid.querying.sorting.currentSortings || [];
135
+ const sortingIndex = sortings.findIndex((sorting) => sorting.columnId === col.id);
136
+ if (sortingIndex !== -1 && sortings[sortingIndex].order) {
137
+ const sorting = sortings[sortingIndex];
138
+ const sortingOptions = {
139
+ order: sorting.order
140
+ };
141
+ if (sortings.length > 1) {
142
+ sortingOptions.priority = sortingIndex + 1;
143
+ }
144
+ col.setOptions({ sorting: sortingOptions });
145
+ if (sortings.length < 2) {
146
+ delete col.options.sorting?.priority;
147
+ }
114
148
  }
115
149
  else {
116
150
  delete col.options.sorting?.order;
151
+ delete col.options.sorting?.priority;
117
152
  if (col.options.sorting &&
118
153
  Object.keys(col.options.sorting).length < 1) {
119
154
  delete col.options.sorting;
@@ -127,8 +162,11 @@ class ColumnSorting {
127
162
  * @param order
128
163
  * The order of sorting. It can be `'asc'`, `'desc'` or `null` if the
129
164
  * sorting should be disabled.
165
+ *
166
+ * @param additive
167
+ * Whether to add this sort to existing sorts or replace them.
130
168
  */
131
- async setOrder(order) {
169
+ async setOrder(order, additive = false) {
132
170
  const viewport = this.column.viewport;
133
171
  // Do not call sorting when cell is currently edited and validated.
134
172
  if (viewport.validator?.errorCell) {
@@ -143,11 +181,40 @@ class ColumnSorting {
143
181
  order
144
182
  });
145
183
  });
146
- sortingController.setSorting(order, this.column.id);
184
+ if (additive) {
185
+ const baseSortings = (sortingController.currentSortings ||
186
+ (sortingController.currentSorting?.columnId &&
187
+ sortingController.currentSorting.order ?
188
+ [sortingController.currentSorting] :
189
+ [])).filter((sorting) => !!(sorting.columnId && sorting.order));
190
+ const sortings = baseSortings.slice();
191
+ const index = sortings.findIndex((sorting) => sorting.columnId === this.column.id);
192
+ if (!order) {
193
+ if (index !== -1) {
194
+ sortings.splice(index, 1);
195
+ }
196
+ }
197
+ else {
198
+ const sorting = {
199
+ columnId: this.column.id,
200
+ order
201
+ };
202
+ if (index !== -1) {
203
+ sortings[index] = sorting;
204
+ }
205
+ else {
206
+ sortings.push(sorting);
207
+ }
208
+ }
209
+ sortingController.setSorting(sortings);
210
+ }
211
+ else {
212
+ sortingController.setSorting(order, this.column.id);
213
+ }
147
214
  await viewport.updateRows();
148
215
  for (const col of viewport.columns) {
149
216
  this.updateColumnOptions(col);
150
- col.sorting?.addHeaderElementAttributes();
217
+ col.sorting?.refreshHeaderAttributes();
151
218
  }
152
219
  a11y?.userSortedColumn(order);
153
220
  [this.column, viewport.grid].forEach((source) => {
@@ -2,11 +2,11 @@
2
2
  *
3
3
  * Grid Columns Resizer class.
4
4
  *
5
- * (c) 2020-2025 Highsoft AS
5
+ * (c) 2020-2026 Highsoft AS
6
6
  *
7
- * License: www.highcharts.com/license
7
+ * A commercial license may be required depending on use.
8
+ * See www.highcharts.com/license
8
9
  *
9
- * !!!!!!! SOURCE GETS TRANSPILED BY TYPESCRIPT. EDIT TS FILE ONLY. !!!!!!!
10
10
  *
11
11
  * Authors:
12
12
  * - Dawid Dragula
@@ -35,6 +35,19 @@ declare class RowsVirtualizer {
35
35
  * Rendering row settings.
36
36
  */
37
37
  rowSettings?: RowsSettings;
38
+ /**
39
+ * Reuse pool for rows that are currently out of viewport.
40
+ */
41
+ private readonly rowPool;
42
+ /**
43
+ * Maximum number of rows to keep in the reuse pool.
44
+ */
45
+ private static readonly MAX_POOL_SIZE;
46
+ /**
47
+ * Flag indicating if a scroll update is queued for the next animation
48
+ * frame.
49
+ */
50
+ private scrollQueued;
38
51
  /**
39
52
  * Constructs an instance of the rows virtualizer.
40
53
  *
@@ -56,6 +69,10 @@ declare class RowsVirtualizer {
56
69
  * is enabled.
57
70
  */
58
71
  scroll(): void;
72
+ /**
73
+ * Applies the scroll logic for virtualized rows.
74
+ */
75
+ private applyScroll;
59
76
  /**
60
77
  * Adjusts the visible row heights from the bottom of the viewport.
61
78
  */
@@ -78,9 +95,29 @@ declare class RowsVirtualizer {
78
95
  * Reflow the rendered rows content dimensions.
79
96
  */
80
97
  reflowRows(): void;
98
+ /**
99
+ * Gets a row from the pool or creates a new one for the given index.
100
+ *
101
+ * @param index
102
+ * The row index in the data table.
103
+ *
104
+ * @returns
105
+ * A TableRow instance ready for use.
106
+ */
107
+ private getOrCreateRow;
108
+ /**
109
+ * Adds a row to the reuse pool, or destroys it if the pool is full.
110
+ *
111
+ * @param row
112
+ * The row to pool.
113
+ */
114
+ private poolRow;
81
115
  /**
82
116
  * Returns the default height of a row. This method should be called only
83
117
  * once on initialization.
118
+ *
119
+ * @returns
120
+ * The default height of a row.
84
121
  */
85
122
  private getDefaultRowHeight;
86
123
  }
@@ -2,11 +2,11 @@
2
2
  *
3
3
  * Grid Rows Renderer class.
4
4
  *
5
- * (c) 2020-2025 Highsoft AS
5
+ * (c) 2020-2026 Highsoft AS
6
6
  *
7
- * License: www.highcharts.com/license
7
+ * A commercial license may be required depending on use.
8
+ * See www.highcharts.com/license
8
9
  *
9
- * !!!!!!! SOURCE GETS TRANSPILED BY TYPESCRIPT. EDIT TS FILE ONLY. !!!!!!!
10
10
  *
11
11
  * Authors:
12
12
  * - Dawid Dragula
@@ -45,6 +45,15 @@ class RowsVirtualizer {
45
45
  * flickering loops when scrolling to the last row.
46
46
  */
47
47
  this.preventScroll = false;
48
+ /**
49
+ * Reuse pool for rows that are currently out of viewport.
50
+ */
51
+ this.rowPool = [];
52
+ /**
53
+ * Flag indicating if a scroll update is queued for the next animation
54
+ * frame.
55
+ */
56
+ this.scrollQueued = false;
48
57
  this.rowSettings =
49
58
  viewport.grid.options?.rendering?.rows;
50
59
  this.viewport = viewport;
@@ -81,6 +90,12 @@ class RowsVirtualizer {
81
90
  let rows = this.viewport.rows;
82
91
  const oldScrollLeft = tbody.scrollLeft;
83
92
  let oldScrollTop;
93
+ if (this.rowPool.length) {
94
+ for (let i = this.rowPool.length - 1; i >= 0; --i) {
95
+ this.rowPool[i].destroy();
96
+ }
97
+ this.rowPool.length = 0;
98
+ }
84
99
  if (rows.length) {
85
100
  oldScrollTop = tbody.scrollTop;
86
101
  for (let i = 0, iEnd = rows.length; i < iEnd; ++i) {
@@ -107,6 +122,19 @@ class RowsVirtualizer {
107
122
  * is enabled.
108
123
  */
109
124
  scroll() {
125
+ if (this.scrollQueued) {
126
+ return;
127
+ }
128
+ this.scrollQueued = true;
129
+ requestAnimationFrame(() => {
130
+ this.scrollQueued = false;
131
+ this.applyScroll();
132
+ });
133
+ }
134
+ /**
135
+ * Applies the scroll logic for virtualized rows.
136
+ */
137
+ applyScroll() {
110
138
  const target = this.viewport.tbodyElement;
111
139
  const { defaultRowHeight: rowHeight } = this;
112
140
  const lastScrollTop = target.scrollTop;
@@ -195,36 +223,70 @@ class RowsVirtualizer {
195
223
  const to = Math.min(rowCursor + rowsPerPage + buffer, rows[rows.length - 1].index - 1);
196
224
  const alwaysLastRow = rows.pop();
197
225
  const tempRows = [];
198
- // Remove rows that are out of the range except the last row.
199
- for (let i = 0, iEnd = rows.length; i < iEnd; ++i) {
200
- const row = rows[i];
201
- const rowIndex = row.index;
202
- if (rowIndex < from || rowIndex > to) {
203
- row.destroy();
226
+ const currentFrom = rows[0]?.index;
227
+ const currentTo = rows[rows.length - 1]?.index;
228
+ const hasOverlap = (rows.length > 0 &&
229
+ currentFrom !== void 0 &&
230
+ currentTo !== void 0 &&
231
+ !(to < currentFrom || from > currentTo));
232
+ if (!hasOverlap) {
233
+ // Remove rows that are out of the range except the last row.
234
+ for (let i = 0, iEnd = rows.length; i < iEnd; ++i) {
235
+ const row = rows[i];
236
+ const rowIndex = row.index;
237
+ if (rowIndex < from || rowIndex > to) {
238
+ this.poolRow(row);
239
+ }
240
+ else {
241
+ tempRows.push(row);
242
+ }
204
243
  }
205
- else {
206
- tempRows.push(row);
244
+ rows = tempRows;
245
+ vp.rows = rows;
246
+ for (let i = from; i <= to; ++i) {
247
+ const row = rows[i - (rows[0]?.index || 0)];
248
+ // Recreate row when it is destroyed and it is in the range.
249
+ if (!row) {
250
+ rows.push(this.getOrCreateRow(i));
251
+ }
207
252
  }
253
+ rows.sort((a, b) => a.index - b.index);
208
254
  }
209
- rows = tempRows;
210
- vp.rows = rows;
211
- for (let i = from; i <= to; ++i) {
212
- const row = rows[i - (rows[0]?.index || 0)];
213
- // Recreate row when it is destroyed and it is in the range.
214
- if (!row) {
215
- const newRow = new TableRow(vp, i);
216
- rows.push(newRow);
217
- newRow.rendered = false;
218
- if (isVirtualization) {
219
- newRow.setTranslateY(newRow.getDefaultTopOffset());
255
+ else {
256
+ // Remove rows outside the range from the start.
257
+ while (rows.length && rows[0].index < from) {
258
+ this.poolRow(rows.shift());
259
+ }
260
+ // Remove rows outside the range from the end.
261
+ while (rows.length && rows[rows.length - 1].index > to) {
262
+ this.poolRow(rows.pop());
263
+ }
264
+ if (!rows.length) {
265
+ for (let i = from; i <= to; ++i) {
266
+ rows.push(this.getOrCreateRow(i));
267
+ }
268
+ }
269
+ else {
270
+ // Add rows before the current range.
271
+ for (let i = rows[0].index - 1; i >= from; --i) {
272
+ rows.unshift(this.getOrCreateRow(i));
273
+ }
274
+ // Add rows after the current range.
275
+ for (let i = rows[rows.length - 1].index + 1; i <= to; ++i) {
276
+ rows.push(this.getOrCreateRow(i));
220
277
  }
221
278
  }
279
+ vp.rows = rows;
222
280
  }
223
- rows.sort((a, b) => a.index - b.index);
224
281
  for (let i = 0, iEnd = rows.length; i < iEnd; ++i) {
225
- if (!rows[i].rendered) {
226
- vp.tbodyElement.insertBefore(rows[i].htmlElement, vp.tbodyElement.lastChild);
227
- rows[i].render();
282
+ const row = rows[i];
283
+ if (!row.rendered) {
284
+ vp.tbodyElement.insertBefore(row.htmlElement, vp.tbodyElement.lastChild);
285
+ row.render();
286
+ continue;
287
+ }
288
+ if (!row.htmlElement.isConnected) {
289
+ vp.tbodyElement.insertBefore(row.htmlElement, vp.tbodyElement.lastChild);
228
290
  }
229
291
  }
230
292
  if (alwaysLastRow) {
@@ -322,9 +384,54 @@ class RowsVirtualizer {
322
384
  }
323
385
  this.adjustRowHeights();
324
386
  }
387
+ /**
388
+ * Gets a row from the pool or creates a new one for the given index.
389
+ *
390
+ * @param index
391
+ * The row index in the data table.
392
+ *
393
+ * @returns
394
+ * A TableRow instance ready for use.
395
+ */
396
+ getOrCreateRow(index) {
397
+ const vp = this.viewport;
398
+ const isVirtualization = vp.virtualRows;
399
+ const pooledRow = this.rowPool.pop();
400
+ if (pooledRow) {
401
+ pooledRow.reuse(index, false);
402
+ if (isVirtualization) {
403
+ pooledRow.setTranslateY(pooledRow.getDefaultTopOffset());
404
+ }
405
+ return pooledRow;
406
+ }
407
+ const newRow = new TableRow(vp, index);
408
+ newRow.rendered = false;
409
+ if (isVirtualization) {
410
+ newRow.setTranslateY(newRow.getDefaultTopOffset());
411
+ }
412
+ return newRow;
413
+ }
414
+ /**
415
+ * Adds a row to the reuse pool, or destroys it if the pool is full.
416
+ *
417
+ * @param row
418
+ * The row to pool.
419
+ */
420
+ poolRow(row) {
421
+ row.htmlElement.remove();
422
+ if (this.rowPool.length < RowsVirtualizer.MAX_POOL_SIZE) {
423
+ this.rowPool.push(row);
424
+ }
425
+ else {
426
+ row.destroy();
427
+ }
428
+ }
325
429
  /**
326
430
  * Returns the default height of a row. This method should be called only
327
431
  * once on initialization.
432
+ *
433
+ * @returns
434
+ * The default height of a row.
328
435
  */
329
436
  getDefaultRowHeight() {
330
437
  const vp = this.viewport;
@@ -338,6 +445,10 @@ class RowsVirtualizer {
338
445
  return defaultRowHeight;
339
446
  }
340
447
  }
448
+ /**
449
+ * Maximum number of rows to keep in the reuse pool.
450
+ */
451
+ RowsVirtualizer.MAX_POOL_SIZE = 100;
341
452
  /* *
342
453
  *
343
454
  * Default Export
@@ -63,13 +63,20 @@ declare class TableCell extends Cell {
63
63
  * the cell's content.
64
64
  */
65
65
  private updateDataTable;
66
+ /**
67
+ * Initialize event listeners for table body cells.
68
+ *
69
+ * Most events (click, dblclick, keydown, mousedown, mouseover, mouseout)
70
+ * are delegated to Table for better performance with virtualization.
71
+ * Only focus/blur remain on individual cells for focus management.
72
+ */
66
73
  initEvents(): void;
67
74
  /**
68
75
  * Handles the focus event on the cell.
69
76
  */
70
77
  protected onFocus(): void;
71
- protected onMouseOver(): void;
72
- protected onMouseOut(): void;
78
+ onMouseOver(): void;
79
+ onMouseOut(): void;
73
80
  /**
74
81
  * Handles the double click event on the cell.
75
82
  *
@@ -2,11 +2,11 @@
2
2
  *
3
3
  * Grid class
4
4
  *
5
- * (c) 2020-2025 Highsoft AS
5
+ * (c) 2020-2026 Highsoft AS
6
6
  *
7
- * License: www.highcharts.com/license
7
+ * A commercial license may be required depending on use.
8
+ * See www.highcharts.com/license
8
9
  *
9
- * !!!!!!! SOURCE GETS TRANSPILED BY TYPESCRIPT. EDIT TS FILE ONLY. !!!!!!!
10
10
  *
11
11
  * Authors:
12
12
  * - Dawid Dragula
@@ -133,12 +133,19 @@ class TableCell extends Cell {
133
133
  await vp.updateRows();
134
134
  return true;
135
135
  }
136
+ /**
137
+ * Initialize event listeners for table body cells.
138
+ *
139
+ * Most events (click, dblclick, keydown, mousedown, mouseover, mouseout)
140
+ * are delegated to Table for better performance with virtualization.
141
+ * Only focus/blur remain on individual cells for focus management.
142
+ */
136
143
  initEvents() {
137
- this.cellEvents.push(['dblclick', (e) => (this.onDblClick(e))]);
138
- this.cellEvents.push(['mousedown', (e) => {
139
- this.onMouseDown(e);
140
- }]);
141
- super.initEvents();
144
+ this.cellEvents.push(['blur', () => this.onBlur()]);
145
+ this.cellEvents.push(['focus', () => this.onFocus()]);
146
+ this.cellEvents.forEach((pair) => {
147
+ this.htmlElement.addEventListener(pair[0], pair[1]);
148
+ });
142
149
  }
143
150
  /**
144
151
  * Handles the focus event on the cell.
@@ -43,6 +43,16 @@ declare class TableRow extends Row {
43
43
  * table.
44
44
  */
45
45
  update(): void;
46
+ /**
47
+ * Reuses the row instance for a new index.
48
+ *
49
+ * @param index
50
+ * The index of the row in the data table.
51
+ *
52
+ * @param doReflow
53
+ * Whether to reflow the row after updating the cells.
54
+ */
55
+ reuse(index: number, doReflow?: boolean): void;
46
56
  /**
47
57
  * Adds or removes the hovered CSS class to the row element.
48
58
  *
@@ -66,6 +76,14 @@ declare class TableRow extends Row {
66
76
  * lifecycle.
67
77
  */
68
78
  updateRowAttributes(): void;
79
+ /**
80
+ * Updates the row parity class based on index.
81
+ */
82
+ private updateParityClass;
83
+ /**
84
+ * Updates the hovered and synced classes based on grid state.
85
+ */
86
+ private updateStateClasses;
69
87
  /**
70
88
  * Sets the vertical translation of the row. Used for virtual scrolling.
71
89
  *
@@ -2,11 +2,11 @@
2
2
  *
3
3
  * Grid TableRow class
4
4
  *
5
- * (c) 2020-2025 Highsoft AS
5
+ * (c) 2020-2026 Highsoft AS
6
6
  *
7
- * License: www.highcharts.com/license
7
+ * A commercial license may be required depending on use.
8
+ * See www.highcharts.com/license
8
9
  *
9
- * !!!!!!! SOURCE GETS TRANSPILED BY TYPESCRIPT. EDIT TS FILE ONLY. !!!!!!!
10
10
  *
11
11
  * Authors:
12
12
  * - Dawid Dragula
@@ -92,6 +92,35 @@ class TableRow extends Row {
92
92
  }
93
93
  this.reflow();
94
94
  }
95
+ /**
96
+ * Reuses the row instance for a new index.
97
+ *
98
+ * @param index
99
+ * The index of the row in the data table.
100
+ *
101
+ * @param doReflow
102
+ * Whether to reflow the row after updating the cells.
103
+ */
104
+ reuse(index, doReflow = true) {
105
+ if (this.index === index) {
106
+ this.update();
107
+ return;
108
+ }
109
+ this.index = index;
110
+ this.id = this.viewport.dataTable.getOriginalRowIndex(index);
111
+ this.htmlElement.setAttribute('data-row-index', index);
112
+ this.updateRowAttributes();
113
+ this.updateParityClass();
114
+ this.updateStateClasses();
115
+ this.loadData();
116
+ for (let i = 0, iEnd = this.cells.length; i < iEnd; ++i) {
117
+ const cell = this.cells[i];
118
+ void cell.setValue();
119
+ }
120
+ if (doReflow) {
121
+ this.reflow();
122
+ }
123
+ }
95
124
  /**
96
125
  * Adds or removes the hovered CSS class to the row element.
97
126
  *
@@ -127,13 +156,8 @@ class TableRow extends Row {
127
156
  el.setAttribute('data-row-index', idx);
128
157
  this.updateRowAttributes();
129
158
  // Indexing from 0, so rows with even index are odd.
130
- el.classList.add(Globals.getClassName(idx % 2 ? 'rowEven' : 'rowOdd'));
131
- if (this.viewport.grid.hoveredRowIndex === idx) {
132
- el.classList.add(Globals.getClassName('hoveredRow'));
133
- }
134
- if (this.viewport.grid.syncedRowIndex === idx) {
135
- el.classList.add(Globals.getClassName('syncedRow'));
136
- }
159
+ this.updateParityClass();
160
+ this.updateStateClasses();
137
161
  }
138
162
  /**
139
163
  * Sets the row HTML element attributes that are updateable in the row
@@ -151,6 +175,28 @@ class TableRow extends Row {
151
175
  // Calculate levels of header, 1 to avoid indexing from 0
152
176
  a11y?.setRowIndex(el, idx + (vp.header?.rows.length ?? 0) + 1);
153
177
  }
178
+ /**
179
+ * Updates the row parity class based on index.
180
+ */
181
+ updateParityClass() {
182
+ const el = this.htmlElement;
183
+ el.classList.remove(Globals.getClassName('rowEven'), Globals.getClassName('rowOdd'));
184
+ // Indexing from 0, so rows with even index are odd.
185
+ el.classList.add(Globals.getClassName(this.index % 2 ? 'rowEven' : 'rowOdd'));
186
+ }
187
+ /**
188
+ * Updates the hovered and synced classes based on grid state.
189
+ */
190
+ updateStateClasses() {
191
+ const el = this.htmlElement;
192
+ el.classList.remove(Globals.getClassName('hoveredRow'), Globals.getClassName('syncedRow'));
193
+ if (this.viewport.grid.hoveredRowIndex === this.index) {
194
+ el.classList.add(Globals.getClassName('hoveredRow'));
195
+ }
196
+ if (this.viewport.grid.syncedRowIndex === this.index) {
197
+ el.classList.add(Globals.getClassName('syncedRow'));
198
+ }
199
+ }
154
200
  /**
155
201
  * Sets the vertical translation of the row. Used for virtual scrolling.
156
202
  *
@@ -52,13 +52,6 @@ declare abstract class Cell {
52
52
  * Handles the blur event on the cell.
53
53
  */
54
54
  protected onBlur(): void;
55
- /**
56
- * Handles user keydown on the cell.
57
- *
58
- * @param e
59
- * Keyboard event object.
60
- */
61
- protected onKeyDown(e: KeyboardEvent): void;
62
55
  /**
63
56
  * Renders the cell by appending the HTML element to the row.
64
57
  */