@linzjs/step-ag-grid 26.0.1 → 27.0.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/dist/src/components/Grid.d.ts +1 -0
- package/dist/src/components/GridCell.d.ts +5 -28
- package/dist/step-ag-grid.cjs +5 -3
- package/dist/step-ag-grid.cjs.map +1 -1
- package/dist/step-ag-grid.esm.js +5 -3
- package/dist/step-ag-grid.esm.js.map +1 -1
- package/package.json +1 -1
- package/src/components/Grid.tsx +5 -2
- package/src/components/GridCell.test.tsx +3 -2
- package/src/components/GridCell.tsx +4 -38
- package/src/components/gridPopoverEdit/GridButton.tsx +4 -4
- package/src/react-menu3/components/ControlledMenu.tsx +1 -1
package/dist/step-ag-grid.esm.js
CHANGED
|
@@ -2064,7 +2064,7 @@ const ControlledMenuFr = ({ 'aria-label': ariaLabel, className, containerProps,
|
|
|
2064
2064
|
}
|
|
2065
2065
|
break;
|
|
2066
2066
|
}
|
|
2067
|
-
}, [anchorRef, saveButtonRef]);
|
|
2067
|
+
}, [anchorRef, onClose, saveButtonRef]);
|
|
2068
2068
|
const handleKeydownTabAndEnter = useMemo(() => handleKeyboardTabAndEnter(true), [handleKeyboardTabAndEnter]);
|
|
2069
2069
|
const handleKeyupTabAndEnter = useMemo(() => handleKeyboardTabAndEnter(false), [handleKeyboardTabAndEnter]);
|
|
2070
2070
|
useEffect(() => {
|
|
@@ -3178,6 +3178,7 @@ const Grid = ({ 'data-testid': dataTestId, defaultPostSort = true, rowSelection
|
|
|
3178
3178
|
}, [params, clearHighlightRowClasses]);
|
|
3179
3179
|
// This is setting a ref in the GridContext so won't be triggering an update loop
|
|
3180
3180
|
setOnCellEditingComplete(params.onCellEditingComplete);
|
|
3181
|
+
const selectWidth = params.hideSelectColumn ? 0 : selectable && params.onRowDragEnd ? 76 : 48;
|
|
3181
3182
|
const headerRowCount = columnDefs.some((c) => c.children) ? 2 : 1;
|
|
3182
3183
|
return (jsxs("div", { "data-testid": dataTestId, className: clsx('Grid-container', theme, 'theme-specific', staleGrid && 'Grid-sortIsStale', gridReady && rowData && autoSized && 'Grid-ready'), children: [gridContextMenu.component, jsx("div", { style: { flex: 1 }, ref: gridDivRef, children: jsx(AgGridReact, { theme: 'legacy', rowSelection: selectable
|
|
3183
3184
|
? {
|
|
@@ -3189,9 +3190,10 @@ const Grid = ({ 'data-testid': dataTestId, defaultPostSort = true, rowSelection
|
|
|
3189
3190
|
event.api.forEachNode(() => rowCount++);
|
|
3190
3191
|
return (jsx(GridNoRowsOverlay, { loading: !rowData || params.loading === true, rowCount: rowCount, headerRowHeight: headerRowCount * rowHeight, filteredRowCount: event.api.getDisplayedRowCount(), noRowsOverlayText: params.noRowsOverlayText, noRowsMatchingOverlayText: params.noRowsMatchingOverlayText }));
|
|
3191
3192
|
}, onModelUpdated: onModelUpdated, onGridReady: onGridReady, onSortChanged: ensureSelectedRowIsVisible, postSortRows: params.onRowDragEnd || !defaultPostSort ? undefined : postSortRows, onSelectionChanged: synchroniseExternalStateToGridSelection, onColumnMoved: params.onColumnMoved, alwaysShowVerticalScroll: params.alwaysShowVerticalScroll, isExternalFilterPresent: isExternalFilterPresent, doesExternalFilterPass: doesExternalFilterPass, maintainColumnOrder: true, preventDefaultOnContextMenu: true, onCellContextMenu: gridContextMenu.cellContextMenu, rowDragText: params.rowDragText, onRowDragCancel: clearHighlightRowClasses, onRowDragMove: onRowDragMove, onRowDragEnd: onRowDragEnd, suppressCellFocus: params.suppressCellFocus, pinnedTopRowData: params.pinnedTopRowData, pinnedBottomRowData: params.pinnedBottomRowData, selectionColumnDef: {
|
|
3193
|
+
suppressNavigable: params.hideSelectColumn,
|
|
3192
3194
|
rowDrag: !!params.onRowDragEnd,
|
|
3193
|
-
minWidth:
|
|
3194
|
-
maxWidth:
|
|
3195
|
+
minWidth: selectWidth,
|
|
3196
|
+
maxWidth: selectWidth,
|
|
3195
3197
|
pinned: selectColumnPinned,
|
|
3196
3198
|
headerComponentParams: {
|
|
3197
3199
|
exportable: false,
|