@apexcura/ui-components 0.0.13-Beta58 → 0.0.13-Beta59

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 CHANGED
@@ -830,6 +830,13 @@ var UploadElement = (props) => {
830
830
  value: newFileList
831
831
  });
832
832
  };
833
+ const uploadChange2 = ({ file, fileList }) => {
834
+ const newFileList = fileList.filter((f) => f.name !== file.name);
835
+ props.onChange && props.onChange({
836
+ name: props.name,
837
+ value: newFileList
838
+ });
839
+ };
833
840
  const handlePreview = async (file) => {
834
841
  if (!file.url && !file.preview) {
835
842
  file.preview = await URL.createObjectURL(file.originFileObj);
@@ -865,6 +872,7 @@ var UploadElement = (props) => {
865
872
  listType: props.list_type,
866
873
  maxCount: props.max_count,
867
874
  multiple: true,
875
+ onChange: uploadChange2,
868
876
  onPreview: handlePreview,
869
877
  showUploadList: true
870
878
  },
package/dist/index.mjs CHANGED
@@ -774,6 +774,13 @@ var UploadElement = (props) => {
774
774
  value: newFileList
775
775
  });
776
776
  };
777
+ const uploadChange2 = ({ file, fileList }) => {
778
+ const newFileList = fileList.filter((f) => f.name !== file.name);
779
+ props.onChange && props.onChange({
780
+ name: props.name,
781
+ value: newFileList
782
+ });
783
+ };
777
784
  const handlePreview = async (file) => {
778
785
  if (!file.url && !file.preview) {
779
786
  file.preview = await URL.createObjectURL(file.originFileObj);
@@ -809,6 +816,7 @@ var UploadElement = (props) => {
809
816
  listType: props.list_type,
810
817
  maxCount: props.max_count,
811
818
  multiple: true,
819
+ onChange: uploadChange2,
812
820
  onPreview: handlePreview,
813
821
  showUploadList: true
814
822
  },
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@apexcura/ui-components",
3
- "version": "0.0.13-Beta58",
3
+ "version": "0.0.13-Beta59",
4
4
  "description": "Apex cura React components library",
5
5
  "keywords": [
6
6
  "apex cura",