@linzjs/step-ag-grid 29.2.1 → 29.2.2
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/dist/src/components/Grid.d.ts +1 -2
- package/dist/step-ag-grid.cjs +3 -3
- package/dist/step-ag-grid.cjs.map +1 -1
- package/dist/step-ag-grid.esm.js +3 -3
- package/dist/step-ag-grid.esm.js.map +1 -1
- package/package.json +1 -1
- package/src/components/Grid.tsx +2 -4
- package/src/stories/grid/gridAutosize/ShowPanelResizingAgGrid/ShowPanelResizingStepAgGrid.tsx +1 -1
|
@@ -84,9 +84,8 @@ export interface GridProps<TData extends GridBaseRow = GridBaseRow> {
|
|
|
84
84
|
pinnedBottomRowData?: GridOptions['pinnedBottomRowData'];
|
|
85
85
|
onRowClicked?: (event: RowClickedEvent) => void;
|
|
86
86
|
onRowDoubleClicked?: (event: RowDoubleClickedEvent) => void;
|
|
87
|
-
allowResizeInStorybook?: boolean;
|
|
88
87
|
}
|
|
89
88
|
/**
|
|
90
89
|
* Wrapper for AgGrid to add commonly used functionality.
|
|
91
90
|
*/
|
|
92
|
-
export declare const Grid: <TData extends GridBaseRow = GridBaseRow>({ "data-testid": dataTestId, defaultPostSort, rowSelection, suppressColumnVirtualization, theme, sizeColumns, selectColumnPinned, contextMenuSelectRow, singleClickEdit, rowData, rowHeight, selectable,
|
|
91
|
+
export declare const Grid: <TData extends GridBaseRow = GridBaseRow>({ "data-testid": dataTestId, defaultPostSort, rowSelection, suppressColumnVirtualization, theme, sizeColumns, selectColumnPinned, contextMenuSelectRow, singleClickEdit, rowData, rowHeight, selectable, onCellFocused: paramsOnCellFocused, ...params }: GridProps<TData>) => ReactElement;
|
package/dist/step-ag-grid.cjs
CHANGED
|
@@ -2762,7 +2762,7 @@ agGridCommunity.ModuleRegistry.registerModules([agGridCommunity.AllCommunityModu
|
|
|
2762
2762
|
/**
|
|
2763
2763
|
* Wrapper for AgGrid to add commonly used functionality.
|
|
2764
2764
|
*/
|
|
2765
|
-
const Grid = ({ 'data-testid': dataTestId, defaultPostSort = true, rowSelection = 'multiple', suppressColumnVirtualization = true, theme = 'ag-theme-step-default', sizeColumns = 'auto', selectColumnPinned = 'left', contextMenuSelectRow = false, singleClickEdit = false, rowData, rowHeight = theme === 'ag-theme-step-default' ? 40 : theme === 'ag-theme-step-compact' ? 36 : 40, selectable,
|
|
2765
|
+
const Grid = ({ 'data-testid': dataTestId, defaultPostSort = true, rowSelection = 'multiple', suppressColumnVirtualization = true, theme = 'ag-theme-step-default', sizeColumns = 'auto', selectColumnPinned = 'left', contextMenuSelectRow = false, singleClickEdit = false, rowData, rowHeight = theme === 'ag-theme-step-default' ? 40 : theme === 'ag-theme-step-compact' ? 36 : 40, selectable, onCellFocused: paramsOnCellFocused, ...params }) => {
|
|
2766
2766
|
const { gridReady, gridRenderState, setApis, ensureRowVisible, getFirstRowId, selectRowsById, focusByRowById, ensureSelectedRowIsVisible, autoSizeColumns, sizeColumnsToFit, externallySelectedItemsAreInSync, setExternallySelectedItemsAreInSync, isExternalFilterPresent, doesExternalFilterPass, setOnBulkEditingComplete, getColDef, showNoRowsOverlay, prePopupOps, startCellEditing, } = useGridContext();
|
|
2767
2767
|
const { updatedDep, updatingCols } = React.useContext(GridUpdatingContext);
|
|
2768
2768
|
const gridDivRef = React.useRef(null);
|
|
@@ -3125,7 +3125,7 @@ const Grid = ({ 'data-testid': dataTestId, defaultPostSort = true, rowSelection
|
|
|
3125
3125
|
* Resize columns to fit if required on window/container resize
|
|
3126
3126
|
*/
|
|
3127
3127
|
const onGridSizeChanged = React.useCallback((event) => {
|
|
3128
|
-
if (sizeColumns !== 'none'
|
|
3128
|
+
if (sizeColumns !== 'none') {
|
|
3129
3129
|
const columnLimits = [
|
|
3130
3130
|
...userSizedColIds.current.entries().map(([c, w]) => ({
|
|
3131
3131
|
key: c,
|
|
@@ -3134,7 +3134,7 @@ const Grid = ({ 'data-testid': dataTestId, defaultPostSort = true, rowSelection
|
|
|
3134
3134
|
];
|
|
3135
3135
|
event.api.sizeColumnsToFit({ columnLimits });
|
|
3136
3136
|
}
|
|
3137
|
-
}, [
|
|
3137
|
+
}, [sizeColumns]);
|
|
3138
3138
|
/**
|
|
3139
3139
|
* Set of column I'd's that are prevented from auto-sizing as they are user set
|
|
3140
3140
|
*/
|