@nethru/ui 1.0.7 → 1.0.9

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/ListItem.js CHANGED
@@ -13,11 +13,6 @@ export default function ListItem({
13
13
  children: [grid && /*#__PURE__*/_jsx(Grid, {
14
14
  container: true,
15
15
  columnSpacing: spacing,
16
- sx: {
17
- '&': {
18
- alignItems: 'center'
19
- }
20
- },
21
16
  children: children
22
17
  }), !grid && children]
23
18
  });
@@ -3,22 +3,27 @@ import CheckCircleIcon from "@mui/icons-material/CheckCircle";
3
3
  import ErrorIcon from "@mui/icons-material/Error";
4
4
  import { jsx as _jsx } from "react/jsx-runtime";
5
5
  export default function StatusChip({
6
+ id,
6
7
  label,
7
8
  status,
8
- onClick,
9
+ onOperate,
9
10
  ...props
10
11
  }) {
11
12
  const styles = {
12
13
  '&': {
13
14
  bgcolor: status === 'normal' ? '#4caf50' : '#fff'
15
+ },
16
+ '.MuiSvgIcon-root.MuiChip-deleteIcon': {
17
+ cursor: onOperate ? 'pointer' : 'default'
14
18
  }
15
19
  };
16
20
  return /*#__PURE__*/_jsx(Chip, {
21
+ id: id,
17
22
  label: label,
18
23
  variant: status === 'normal' ? 'filled' : 'outlined',
19
24
  color: status === 'normal' ? 'success' : 'default',
20
25
  deleteIcon: status === 'normal' ? /*#__PURE__*/_jsx(CheckCircleIcon, {}) : /*#__PURE__*/_jsx(ErrorIcon, {}),
21
- onDelete: _ => onClick && onClick(status),
26
+ onDelete: _ => onOperate && onOperate(id, status),
22
27
  sx: styles,
23
28
  ...props
24
29
  });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@nethru/ui",
3
- "version": "1.0.7",
3
+ "version": "1.0.9",
4
4
  "main": "dist/index.js",
5
5
  "files": [
6
6
  "/dist"