optimized-react-component-library-xyz123 0.19.10 → 0.19.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.
- package/dist/index.js +6 -4
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +6 -4
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -906,17 +906,19 @@ var AddFiles = ({
|
|
|
906
906
|
});
|
|
907
907
|
};
|
|
908
908
|
useEffect5(() => {
|
|
909
|
+
let e;
|
|
909
910
|
if (newFiles.length > 0) {
|
|
910
911
|
const currentFiles = questionObject.files ? questionObject.files : [];
|
|
911
|
-
|
|
912
|
+
e = {
|
|
912
913
|
target: {
|
|
913
914
|
value: currentFiles.length + newFiles.length > 0 ? `${currentFiles.length + newFiles.length} files` : "",
|
|
914
915
|
files: [...currentFiles, ...newFiles]
|
|
915
916
|
}
|
|
916
917
|
};
|
|
917
|
-
|
|
918
|
-
|
|
919
|
-
}
|
|
918
|
+
console.log("Files added 1:", JSON.stringify(e));
|
|
919
|
+
const targetValue = e.target.value === "0 files" ? "" : e.target.value;
|
|
920
|
+
e = { ...e, target: { ...e.target, value: targetValue } };
|
|
921
|
+
console.log("Files added 2:", JSON.stringify(e));
|
|
920
922
|
handleQuestionInputChange(e, questionObject);
|
|
921
923
|
setNumberOfFiles(currentFiles.length + newFiles.length);
|
|
922
924
|
setNewFiles([]);
|