@patternfly/react-table 5.0.0-alpha.95 → 5.0.0-alpha.97

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.
Files changed (29) hide show
  1. package/CHANGELOG.md +11 -0
  2. package/components/package.json +1 -1
  3. package/deprecated/package.json +1 -1
  4. package/dist/esm/components/Table/EditableSelectInputCell.d.ts +2 -2
  5. package/dist/esm/components/Table/EditableSelectInputCell.d.ts.map +1 -1
  6. package/dist/esm/components/Table/EditableSelectInputCell.js +2 -2
  7. package/dist/esm/components/Table/EditableSelectInputCell.js.map +1 -1
  8. package/dist/esm/components/Table/EditableTextCell.js +1 -1
  9. package/dist/esm/components/Table/EditableTextCell.js.map +1 -1
  10. package/dist/js/components/Table/EditableSelectInputCell.d.ts +2 -2
  11. package/dist/js/components/Table/EditableSelectInputCell.d.ts.map +1 -1
  12. package/dist/js/components/Table/EditableSelectInputCell.js +2 -2
  13. package/dist/js/components/Table/EditableSelectInputCell.js.map +1 -1
  14. package/dist/js/components/Table/EditableTextCell.js +1 -1
  15. package/dist/js/components/Table/EditableTextCell.js.map +1 -1
  16. package/dist/js/components/Table/package.json +1 -1
  17. package/dist/js/components/Table/utils/decorators/package.json +1 -1
  18. package/dist/js/components/Table/utils/package.json +1 -1
  19. package/dist/js/components/package.json +1 -1
  20. package/dist/js/deprecated/components/Table/base/package.json +1 -1
  21. package/dist/js/deprecated/components/Table/package.json +1 -1
  22. package/dist/js/deprecated/components/package.json +1 -1
  23. package/dist/js/deprecated/package.json +1 -1
  24. package/dist/js/package.json +1 -1
  25. package/dist/umd/react-table.min.js +1 -1
  26. package/package.json +3 -3
  27. package/src/components/Table/EditableSelectInputCell.tsx +4 -4
  28. package/src/components/Table/EditableTextCell.tsx +1 -1
  29. package/src/deprecated/components/Table/examples/Table.md +2 -2
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@patternfly/react-table",
3
- "version": "5.0.0-alpha.95",
3
+ "version": "5.0.0-alpha.97",
4
4
  "description": "This library provides a set of React table components for use with the PatternFly 4",
5
5
  "main": "dist/js/index.js",
6
6
  "module": "dist/esm/index.js",
@@ -40,7 +40,7 @@
40
40
  "subpaths": "node scripts/createSubpaths.js"
41
41
  },
42
42
  "dependencies": {
43
- "@patternfly/react-core": "^5.0.0-alpha.93",
43
+ "@patternfly/react-core": "^5.0.0-alpha.95",
44
44
  "@patternfly/react-icons": "^5.0.0-alpha.14",
45
45
  "@patternfly/react-styles": "^5.0.0-alpha.10",
46
46
  "@patternfly/react-tokens": "^5.0.0-alpha.9",
@@ -55,5 +55,5 @@
55
55
  "react": "^17 || ^18",
56
56
  "react-dom": "^17 || ^18"
57
57
  },
58
- "gitHead": "b0075afbde3a8f5bb474179578d432291dc3109e"
58
+ "gitHead": "90ba49c9bb04467b5482738c8102546ad70c662f"
59
59
  }
@@ -17,8 +17,8 @@ export interface IEditableSelectInputCell extends Omit<React.HTMLProps<HTMLEleme
17
17
  props: EditableSelectInputProps;
18
18
  /** Event handler which fires when user selects an option in this cell */
19
19
  onSelect: (
20
- newValue: string | SelectOptionObject,
21
20
  event: React.MouseEvent | React.ChangeEvent,
21
+ newValue: string | SelectOptionObject,
22
22
  rowIndex: number,
23
23
  cellIndex: number,
24
24
  isPlaceholder?: boolean
@@ -34,7 +34,7 @@ export interface IEditableSelectInputCell extends Omit<React.HTMLProps<HTMLEleme
34
34
  /** Event handler which fires when the select toggle is toggled */
35
35
  onToggle?: (event: React.MouseEvent | React.ChangeEvent | React.KeyboardEvent | Event, isExpanded: boolean) => void;
36
36
  /** Event handler which fires when the user clears the selections */
37
- clearSelection?: (rowIndex: number, cellIndex: number, event?: React.MouseEvent) => void;
37
+ clearSelection?: (event: React.MouseEvent, rowIndex: number, cellIndex: number) => void;
38
38
  }
39
39
 
40
40
  export const EditableSelectInputCell: React.FunctionComponent<IEditableSelectInputCell> = ({
@@ -54,11 +54,11 @@ export const EditableSelectInputCell: React.FunctionComponent<IEditableSelectInp
54
54
  newValue: string | SelectOptionObject,
55
55
  isPlaceholder: boolean
56
56
  ) => {
57
- onSelect(newValue, event, rowIndex, cellIndex, isPlaceholder);
57
+ onSelect(event, newValue, rowIndex, cellIndex, isPlaceholder);
58
58
  };
59
59
 
60
60
  const onClear = (event: React.MouseEvent) => {
61
- clearSelection(rowIndex, cellIndex, event);
61
+ clearSelection(event, rowIndex, cellIndex);
62
62
  };
63
63
 
64
64
  const select = (
@@ -44,7 +44,7 @@ export const EditableTextCell: React.FunctionComponent<IEditableTextCell> = ({
44
44
  value={props.editableValue !== undefined ? props.editableValue : value}
45
45
  validated={props.isValid !== false ? 'default' : 'error'}
46
46
  type="text"
47
- onChange={(newValue, event) => {
47
+ onChange={(event, newValue) => {
48
48
  handleTextInputChange(newValue, event, rowIndex, cellIndex);
49
49
  }}
50
50
  aria-label={inputAriaLabel}
@@ -679,7 +679,7 @@ class EditableRowsTable extends React.Component {
679
679
  });
680
680
  };
681
681
 
682
- this.onSelect = (newValue, evt, rowIndex, cellIndex, isPlaceholder) => {
682
+ this.onSelect = (_event, newValue, rowIndex, cellIndex, isPlaceholder) => {
683
683
  const newRows = Array.from(this.state.rows);
684
684
  const newCellProps = newRows[rowIndex].cells[cellIndex].props;
685
685
 
@@ -720,7 +720,7 @@ class EditableRowsTable extends React.Component {
720
720
  });
721
721
  };
722
722
 
723
- this.clearSelection = (rowIndex, cellIndex) => {
723
+ this.clearSelection = (_event, rowIndex, cellIndex) => {
724
724
  const newRows = Array.from(this.state.rows);
725
725
  const newCellProps = newRows[rowIndex].cells[cellIndex].props;
726
726
  newCellProps.editableValue = [];