@widergy/energy-ui 3.10.2 → 3.10.3

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/CHANGELOG.md CHANGED
@@ -1,3 +1,10 @@
1
+ ## [3.10.3](https://github.com/widergy/energy-ui/compare/v3.10.2...v3.10.3) (2024-06-25)
2
+
3
+
4
+ ### Bug Fixes
5
+
6
+ * fix attachment list preview building with external value changing ([#461](https://github.com/widergy/energy-ui/issues/461)) ([84beb3b](https://github.com/widergy/energy-ui/commit/84beb3bff5d3d2df1ea64b756c38eb21de6569ad))
7
+
1
8
  ## [3.10.2](https://github.com/widergy/energy-ui/compare/v3.10.1...v3.10.2) (2024-06-19)
2
9
 
3
10
 
@@ -192,9 +192,9 @@ const AttachmentContainer = _ref => {
192
192
  });
193
193
  };
194
194
  (0, _react.useEffect)(() => {
195
- if (!(0, _isEmpty.default)(updatedFiles)) buildPreviews(updatedFiles);
195
+ if (!(0, _isEmpty.default)(updatedFiles)) buildPreviews(updatedFiles);else if (!(0, _isEmpty.default)(input.value)) buildPreviews(input.value.files);
196
196
  if (Array.isArray(input.value) && !(0, _isEmpty.default)(input.value) || input.value && typeof input.value === 'string') loadDefaultValues();
197
- }, []);
197
+ }, [input]);
198
198
  return /*#__PURE__*/_react.default.createElement(_layout.default, {
199
199
  acceptedFileTypes: acceptedFileTypes,
200
200
  classes: classes,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@widergy/energy-ui",
3
- "version": "3.10.2",
3
+ "version": "3.10.3",
4
4
  "description": "Widergy Web Components",
5
5
  "author": "widergy",
6
6
  "license": "MIT",