@linzjs/step-ag-grid 10.0.1 → 11.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/index.css +0 -4
- package/dist/src/components/GridCell.d.ts +1 -1
- package/dist/step-ag-grid.esm.js +51449 -53574
- package/dist/step-ag-grid.esm.js.map +1 -1
- package/package.json +3 -3
- package/src/components/Grid.tsx +0 -1
- package/src/react-menu3/components/ControlledMenu.tsx +1 -1
- package/src/styles/Grid.scss +0 -4
- package/src/utils/textValidator.test.ts +4 -0
- package/src/utils/textValidator.ts +1 -1
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": "
|
|
5
|
+
"version": "11.0.0",
|
|
6
6
|
"keywords": [
|
|
7
7
|
"aggrid",
|
|
8
8
|
"ag-grid",
|
|
@@ -34,8 +34,8 @@
|
|
|
34
34
|
},
|
|
35
35
|
"dependencies": {
|
|
36
36
|
"@linzjs/lui": ">=17",
|
|
37
|
-
"ag-grid-community": "
|
|
38
|
-
"ag-grid-react": "^
|
|
37
|
+
"ag-grid-community": "27.3.0",
|
|
38
|
+
"ag-grid-react": "^27.3.0",
|
|
39
39
|
"debounce-promise": "^3.1.2",
|
|
40
40
|
"lodash-es": ">=4",
|
|
41
41
|
"matcher": "^5.0.0",
|
package/src/components/Grid.tsx
CHANGED
|
@@ -344,7 +344,6 @@ export const Grid = (params: GridProps): JSX.Element => {
|
|
|
344
344
|
<AgGridReact
|
|
345
345
|
animateRows={params.animateRows}
|
|
346
346
|
rowClassRules={params.rowClassRules}
|
|
347
|
-
defaultColDef={params.defaultColDef}
|
|
348
347
|
getRowId={(params) => `${params.data.id}`}
|
|
349
348
|
suppressRowClickSelection={true}
|
|
350
349
|
rowSelection={params.rowSelection ?? "multiple"}
|
|
@@ -134,7 +134,7 @@ export const ControlledMenuFr = (
|
|
|
134
134
|
};
|
|
135
135
|
|
|
136
136
|
const allowTabToSave = activeElement.getAttribute("data-allowtabtosave") == "true";
|
|
137
|
-
if (allowTabToSave) {
|
|
137
|
+
if (allowTabToSave && ev.key === "Tab") {
|
|
138
138
|
if (isDown) {
|
|
139
139
|
ev.preventDefault();
|
|
140
140
|
ev.stopPropagation();
|
package/src/styles/Grid.scss
CHANGED
|
@@ -73,6 +73,10 @@ describe("TextInputValidator", () => {
|
|
|
73
73
|
tests: [
|
|
74
74
|
["xx", null],
|
|
75
75
|
["", "Must not be empty"],
|
|
76
|
+
["\t", "Must not be empty"],
|
|
77
|
+
["\n", "Must not be empty"],
|
|
78
|
+
["\r", "Must not be empty"],
|
|
79
|
+
[" ", "Must not be empty"],
|
|
76
80
|
],
|
|
77
81
|
},
|
|
78
82
|
] as (TextInputValidatorProps<GridBaseRow> & { tests: [string, string | undefined][] })[];
|
|
@@ -28,7 +28,7 @@ export const TextInputValidator = <RowType extends GridBaseRow>(
|
|
|
28
28
|
if (typeof value !== "string") {
|
|
29
29
|
return "Value is not a string";
|
|
30
30
|
}
|
|
31
|
-
if (props.required && value == "") {
|
|
31
|
+
if (props.required && value.trim() == "") {
|
|
32
32
|
return "Must not be empty";
|
|
33
33
|
}
|
|
34
34
|
if (props.maxLength && value.length > props.maxLength) {
|