@linzjs/step-ag-grid 8.2.0 → 8.2.1
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/step-ag-grid.esm.js +7 -10
- package/dist/step-ag-grid.esm.js.map +1 -1
- package/package.json +1 -1
- package/src/components/Grid.tsx +0 -11
- package/src/components/gridForm/GridFormPopoverMenu.tsx +2 -0
- package/src/stories/grid/GridReadOnly.stories.tsx +4 -0
- package/src/stories/grid/gridForm/GridFormMultiSelect.stories.tsx +2 -2
package/dist/step-ag-grid.esm.js
CHANGED
|
@@ -2932,12 +2932,6 @@ var Grid = function (params) {
|
|
|
2932
2932
|
startCellEditing(e);
|
|
2933
2933
|
}
|
|
2934
2934
|
}, [startCellEditing]);
|
|
2935
|
-
var onCellEditingStopped = useCallback(function (event) {
|
|
2936
|
-
refreshSelectedRows(event);
|
|
2937
|
-
// The grid loses cell focus after editing
|
|
2938
|
-
var cell = event.api.getFocusedCell();
|
|
2939
|
-
cell && event.api.setFocusedCell(cell.rowIndex, cell.column);
|
|
2940
|
-
}, [refreshSelectedRows]);
|
|
2941
2935
|
// When rows added or removed then resize columns
|
|
2942
2936
|
useEffect(function () {
|
|
2943
2937
|
if (columnDefs === null || columnDefs === void 0 ? void 0 : columnDefs.length) {
|
|
@@ -2946,7 +2940,7 @@ var Grid = function (params) {
|
|
|
2946
2940
|
}, [columnDefs === null || columnDefs === void 0 ? void 0 : columnDefs.length, sizeColumnsToFit]);
|
|
2947
2941
|
return (jsxs("div", __assign({ "data-testid": params["data-testid"], className: clsx("Grid-container", "ag-theme-alpine", staleGrid && "Grid-sortIsStale", gridReady && params.rowData && "Grid-ready") }, { children: [params.quickFilter && (jsx("div", __assign({ className: "Grid-quickFilter" }, { children: jsx("input", { "aria-label": "Search", className: "lui-margin-top-xxs lui-margin-bottom-xxs Grid-quickFilterBox", type: "text", placeholder: (_a = params.quickFilterPlaceholder) !== null && _a !== void 0 ? _a : "Search...", value: internalQuickFilter, onChange: function (event) {
|
|
2948
2942
|
setInternalQuickFilter(event.target.value);
|
|
2949
|
-
} }) }))), jsx(AgGridReact, { animateRows: params.animateRows, rowClassRules: params.rowClassRules, defaultColDef: params.defaultColDef, getRowId: function (params) { return "".concat(params.data.id); }, suppressRowClickSelection: true, rowSelection: (_b = params.rowSelection) !== null && _b !== void 0 ? _b : "multiple", suppressBrowserResizeObserver: true, colResizeDefault: "shift", onFirstDataRendered: sizeColumnsToFit, onGridSizeChanged: sizeColumnsToFit, suppressClickEdit: true, onCellKeyPress: onCellKeyPress, onCellClicked: onCellClicked, onCellDoubleClicked: onCellDoubleClick, onCellEditingStarted: refreshSelectedRows,
|
|
2943
|
+
} }) }))), jsx(AgGridReact, { animateRows: params.animateRows, rowClassRules: params.rowClassRules, defaultColDef: params.defaultColDef, getRowId: function (params) { return "".concat(params.data.id); }, suppressRowClickSelection: true, rowSelection: (_b = params.rowSelection) !== null && _b !== void 0 ? _b : "multiple", suppressBrowserResizeObserver: true, colResizeDefault: "shift", onFirstDataRendered: sizeColumnsToFit, onGridSizeChanged: sizeColumnsToFit, suppressClickEdit: true, onCellKeyPress: onCellKeyPress, onCellClicked: onCellClicked, onCellDoubleClicked: onCellDoubleClick, onCellEditingStarted: refreshSelectedRows, domLayout: params.domLayout, columnDefs: columnDefs, rowData: params.rowData, noRowsOverlayComponent: noRowsOverlayComponent, onGridReady: onGridReady, onSortChanged: ensureSelectedRowIsVisible, postSortRows: (_c = params.postSortRows) !== null && _c !== void 0 ? _c : postSortRows, onSelectionChanged: synchroniseExternalStateToGridSelection, onColumnMoved: params.onColumnMoved, alwaysShowVerticalScroll: params.alwaysShowVerticalScroll })] })));
|
|
2950
2944
|
};
|
|
2951
2945
|
|
|
2952
2946
|
var GridCellMultiSelectClassRules = {
|
|
@@ -3955,9 +3949,12 @@ var GridFormPopoverMenu = function (props) {
|
|
|
3955
3949
|
setSubComponentSelected(subComponentSelected === item ? null : item);
|
|
3956
3950
|
e.keepOpen = true;
|
|
3957
3951
|
return [3 /*break*/, 3];
|
|
3958
|
-
case 1:
|
|
3959
|
-
|
|
3960
|
-
|
|
3952
|
+
case 1:
|
|
3953
|
+
subComponentIsValid.current = true;
|
|
3954
|
+
setSubSelectedValue(null);
|
|
3955
|
+
return [4 /*yield*/, updateValue(function () { return __awaiter(void 0, void 0, void 0, function () { return __generator(this, function (_a) {
|
|
3956
|
+
return [2 /*return*/, actionClick(item)];
|
|
3957
|
+
}); }); }, e.key === "Tab" ? (e.shiftKey ? -1 : 1) : 0)];
|
|
3961
3958
|
case 2:
|
|
3962
3959
|
_a.sent();
|
|
3963
3960
|
_a.label = 3;
|