@etsoo/materialui 1.6.9 → 1.6.11

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.
@@ -28,6 +28,9 @@ function TagList(props) {
28
28
  const [options, setOptions] = react_1.default.useState([]);
29
29
  const [loading, setLoading] = react_1.default.useState(false);
30
30
  const [valueState, setValueState] = react_1.default.useState(value ?? []);
31
+ react_1.default.useEffect(() => {
32
+ setValueState(value ?? []);
33
+ }, [value]);
31
34
  const loadDataLocal = async (keyword) => {
32
35
  setLoading(true);
33
36
  const result = (await loadData(keyword, maxItems)) ?? [];
@@ -22,6 +22,9 @@ export function TagList(props) {
22
22
  const [options, setOptions] = React.useState([]);
23
23
  const [loading, setLoading] = React.useState(false);
24
24
  const [valueState, setValueState] = React.useState(value ?? []);
25
+ React.useEffect(() => {
26
+ setValueState(value ?? []);
27
+ }, [value]);
25
28
  const loadDataLocal = async (keyword) => {
26
29
  setLoading(true);
27
30
  const result = (await loadData(keyword, maxItems)) ?? [];
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@etsoo/materialui",
3
- "version": "1.6.9",
3
+ "version": "1.6.11",
4
4
  "description": "TypeScript Material-UI Implementation",
5
5
  "main": "lib/cjs/index.js",
6
6
  "module": "lib/mjs/index.js",
@@ -42,11 +42,11 @@
42
42
  "@emotion/styled": "^11.14.1",
43
43
  "@etsoo/appscript": "^1.6.53",
44
44
  "@etsoo/notificationbase": "^1.1.66",
45
- "@etsoo/react": "^1.8.72",
45
+ "@etsoo/react": "^1.8.74",
46
46
  "@etsoo/shared": "^1.2.80",
47
- "@mui/icons-material": "^7.3.7",
48
- "@mui/material": "^7.3.7",
49
- "@mui/x-data-grid": "^8.26.0",
47
+ "@mui/icons-material": "^7.3.8",
48
+ "@mui/material": "^7.3.8",
49
+ "@mui/x-data-grid": "^8.27.1",
50
50
  "chart.js": "^4.5.1",
51
51
  "chartjs-plugin-datalabels": "^2.2.0",
52
52
  "dompurify": "^3.3.1",
@@ -65,22 +65,21 @@
65
65
  "react-dom": "$react-dom"
66
66
  },
67
67
  "devDependencies": {
68
- "@babel/cli": "^7.28.6",
69
- "@babel/core": "^7.28.6",
70
- "@babel/plugin-transform-runtime": "^7.28.5",
71
- "@babel/preset-env": "^7.28.6",
68
+ "@babel/core": "^7.29.0",
69
+ "@babel/plugin-transform-runtime": "^7.29.0",
70
+ "@babel/preset-env": "^7.29.0",
72
71
  "@babel/preset-react": "^7.28.5",
73
72
  "@babel/preset-typescript": "^7.28.5",
74
- "@babel/runtime-corejs3": "^7.28.6",
73
+ "@babel/runtime-corejs3": "^7.29.0",
75
74
  "@testing-library/react": "^16.3.2",
76
75
  "@types/pica": "^9.0.5",
77
76
  "@types/pulltorefreshjs": "^0.1.7",
78
- "@types/react": "^19.2.10",
77
+ "@types/react": "^19.2.14",
79
78
  "@types/react-avatar-editor": "^13.0.4",
80
79
  "@types/react-dom": "^19.2.3",
81
80
  "@types/react-input-mask": "^3.0.6",
82
- "@vitejs/plugin-react": "^5.1.2",
83
- "jsdom": "^27.4.0",
81
+ "@vitejs/plugin-react": "^5.1.4",
82
+ "jsdom": "^28.1.0",
84
83
  "typescript": "^5.9.3",
85
84
  "vitest": "^4.0.18"
86
85
  }
package/src/TagList.tsx CHANGED
@@ -87,6 +87,10 @@ export function TagList(props: TagListProps) {
87
87
  const [loading, setLoading] = React.useState(false);
88
88
  const [valueState, setValueState] = React.useState<string[]>(value ?? []);
89
89
 
90
+ React.useEffect(() => {
91
+ setValueState(value ?? []);
92
+ }, [value]);
93
+
90
94
  const loadDataLocal = async (keyword?: string) => {
91
95
  setLoading(true);
92
96
  const result = (await loadData(keyword, maxItems)) ?? [];