@linzjs/step-ag-grid 13.1.3 → 13.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.
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "@linzjs/step-ag-grid",
3
3
  "repository": "github:linz/step-ag-grid.git",
4
4
  "license": "MIT",
5
- "version": "13.1.3",
5
+ "version": "13.2.0",
6
6
  "keywords": [
7
7
  "aggrid",
8
8
  "ag-grid",
@@ -36,12 +36,20 @@ export interface GridProps {
36
36
  autoSelectFirstRow?: boolean;
37
37
  onColumnMoved?: GridOptions["onColumnMoved"];
38
38
  alwaysShowVerticalScroll?: boolean;
39
+ onGridSizeChanged: GridOptions["onGridSizeChanged"];
40
+ onFirstDataRendered: GridOptions["onFirstDataRendered"];
41
+ suppressColumnVirtualization: GridOptions["suppressColumnVirtualisation"];
39
42
  }
40
43
 
41
44
  /**
42
45
  * Wrapper for AgGrid to add commonly used functionality.
43
46
  */
44
- export const Grid = ({ rowSelection = "multiple", "data-testid": dataTestId, ...params }: GridProps): JSX.Element => {
47
+ export const Grid = ({
48
+ "data-testid": dataTestId,
49
+ rowSelection = "multiple",
50
+ suppressColumnVirtualization = true,
51
+ ...params
52
+ }: GridProps): JSX.Element => {
45
53
  const {
46
54
  gridReady,
47
55
  setApis,
@@ -312,8 +320,9 @@ export const Grid = ({ rowSelection = "multiple", "data-testid": dataTestId, ...
312
320
  rowSelection={rowSelection}
313
321
  suppressBrowserResizeObserver={true}
314
322
  colResizeDefault={"shift"}
315
- onFirstDataRendered={sizeColumnsToFit}
316
- onGridSizeChanged={sizeColumnsToFit}
323
+ onFirstDataRendered={params.onFirstDataRendered ?? sizeColumnsToFit}
324
+ onGridSizeChanged={params.onGridSizeChanged ?? sizeColumnsToFit}
325
+ suppressColumnVirtualisation={suppressColumnVirtualization}
317
326
  suppressClickEdit={true}
318
327
  onCellKeyPress={onCellKeyPress}
319
328
  onCellClicked={onCellClicked}