@plusscommunities/pluss-core-web 1.1.9 → 1.1.13
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.cjs.js +26 -9
- package/dist/index.esm.js +26 -9
- package/dist/index.umd.js +26 -9
- package/package.json +2 -2
- package/src/components/FileInput.js +2 -1
package/dist/index.cjs.js
CHANGED
|
@@ -4801,34 +4801,51 @@ var FileInputComponent = /*#__PURE__*/function (_Component) {
|
|
|
4801
4801
|
|
|
4802
4802
|
_this.checkRefreshCallback(newInputs);
|
|
4803
4803
|
|
|
4804
|
-
|
|
4804
|
+
if (!_this.props.handleFile) {
|
|
4805
|
+
_context.next = 12;
|
|
4806
|
+
break;
|
|
4807
|
+
}
|
|
4808
|
+
|
|
4809
|
+
_context.next = 9;
|
|
4810
|
+
return _this.props.handleFile(file, newInputs);
|
|
4811
|
+
|
|
4812
|
+
case 9:
|
|
4813
|
+
_this.setState({
|
|
4814
|
+
uploadingFile: false
|
|
4815
|
+
});
|
|
4816
|
+
|
|
4817
|
+
_context.next = 24;
|
|
4818
|
+
break;
|
|
4819
|
+
|
|
4820
|
+
case 12:
|
|
4821
|
+
_context.prev = 12;
|
|
4805
4822
|
uploadFile = file;
|
|
4806
|
-
_context.next =
|
|
4823
|
+
_context.next = 16;
|
|
4807
4824
|
return fileActions.uploadMediaAsync(uploadFile, uploadFile.name);
|
|
4808
4825
|
|
|
4809
|
-
case
|
|
4826
|
+
case 16:
|
|
4810
4827
|
url = _context.sent;
|
|
4811
4828
|
|
|
4812
4829
|
_this.checkSetDisplayValue(input, url);
|
|
4813
4830
|
|
|
4814
|
-
_context.next =
|
|
4831
|
+
_context.next = 24;
|
|
4815
4832
|
break;
|
|
4816
4833
|
|
|
4817
|
-
case
|
|
4818
|
-
_context.prev =
|
|
4819
|
-
_context.t0 = _context["catch"](
|
|
4834
|
+
case 20:
|
|
4835
|
+
_context.prev = 20;
|
|
4836
|
+
_context.t0 = _context["catch"](12);
|
|
4820
4837
|
console.log('handleFile error', _context.t0);
|
|
4821
4838
|
|
|
4822
4839
|
_this.setState({
|
|
4823
4840
|
uploadingFile: false
|
|
4824
4841
|
});
|
|
4825
4842
|
|
|
4826
|
-
case
|
|
4843
|
+
case 24:
|
|
4827
4844
|
case "end":
|
|
4828
4845
|
return _context.stop();
|
|
4829
4846
|
}
|
|
4830
4847
|
}
|
|
4831
|
-
}, _callee, null, [[
|
|
4848
|
+
}, _callee, null, [[12, 20]]);
|
|
4832
4849
|
}));
|
|
4833
4850
|
|
|
4834
4851
|
return function (_x, _x2) {
|
package/dist/index.esm.js
CHANGED
|
@@ -4774,34 +4774,51 @@ var FileInputComponent = /*#__PURE__*/function (_Component) {
|
|
|
4774
4774
|
|
|
4775
4775
|
_this.checkRefreshCallback(newInputs);
|
|
4776
4776
|
|
|
4777
|
-
|
|
4777
|
+
if (!_this.props.handleFile) {
|
|
4778
|
+
_context.next = 12;
|
|
4779
|
+
break;
|
|
4780
|
+
}
|
|
4781
|
+
|
|
4782
|
+
_context.next = 9;
|
|
4783
|
+
return _this.props.handleFile(file, newInputs);
|
|
4784
|
+
|
|
4785
|
+
case 9:
|
|
4786
|
+
_this.setState({
|
|
4787
|
+
uploadingFile: false
|
|
4788
|
+
});
|
|
4789
|
+
|
|
4790
|
+
_context.next = 24;
|
|
4791
|
+
break;
|
|
4792
|
+
|
|
4793
|
+
case 12:
|
|
4794
|
+
_context.prev = 12;
|
|
4778
4795
|
uploadFile = file;
|
|
4779
|
-
_context.next =
|
|
4796
|
+
_context.next = 16;
|
|
4780
4797
|
return fileActions.uploadMediaAsync(uploadFile, uploadFile.name);
|
|
4781
4798
|
|
|
4782
|
-
case
|
|
4799
|
+
case 16:
|
|
4783
4800
|
url = _context.sent;
|
|
4784
4801
|
|
|
4785
4802
|
_this.checkSetDisplayValue(input, url);
|
|
4786
4803
|
|
|
4787
|
-
_context.next =
|
|
4804
|
+
_context.next = 24;
|
|
4788
4805
|
break;
|
|
4789
4806
|
|
|
4790
|
-
case
|
|
4791
|
-
_context.prev =
|
|
4792
|
-
_context.t0 = _context["catch"](
|
|
4807
|
+
case 20:
|
|
4808
|
+
_context.prev = 20;
|
|
4809
|
+
_context.t0 = _context["catch"](12);
|
|
4793
4810
|
console.log('handleFile error', _context.t0);
|
|
4794
4811
|
|
|
4795
4812
|
_this.setState({
|
|
4796
4813
|
uploadingFile: false
|
|
4797
4814
|
});
|
|
4798
4815
|
|
|
4799
|
-
case
|
|
4816
|
+
case 24:
|
|
4800
4817
|
case "end":
|
|
4801
4818
|
return _context.stop();
|
|
4802
4819
|
}
|
|
4803
4820
|
}
|
|
4804
|
-
}, _callee, null, [[
|
|
4821
|
+
}, _callee, null, [[12, 20]]);
|
|
4805
4822
|
}));
|
|
4806
4823
|
|
|
4807
4824
|
return function (_x, _x2) {
|
package/dist/index.umd.js
CHANGED
|
@@ -4777,34 +4777,51 @@
|
|
|
4777
4777
|
|
|
4778
4778
|
_this.checkRefreshCallback(newInputs);
|
|
4779
4779
|
|
|
4780
|
-
|
|
4780
|
+
if (!_this.props.handleFile) {
|
|
4781
|
+
_context.next = 12;
|
|
4782
|
+
break;
|
|
4783
|
+
}
|
|
4784
|
+
|
|
4785
|
+
_context.next = 9;
|
|
4786
|
+
return _this.props.handleFile(file, newInputs);
|
|
4787
|
+
|
|
4788
|
+
case 9:
|
|
4789
|
+
_this.setState({
|
|
4790
|
+
uploadingFile: false
|
|
4791
|
+
});
|
|
4792
|
+
|
|
4793
|
+
_context.next = 24;
|
|
4794
|
+
break;
|
|
4795
|
+
|
|
4796
|
+
case 12:
|
|
4797
|
+
_context.prev = 12;
|
|
4781
4798
|
uploadFile = file;
|
|
4782
|
-
_context.next =
|
|
4799
|
+
_context.next = 16;
|
|
4783
4800
|
return fileActions.uploadMediaAsync(uploadFile, uploadFile.name);
|
|
4784
4801
|
|
|
4785
|
-
case
|
|
4802
|
+
case 16:
|
|
4786
4803
|
url = _context.sent;
|
|
4787
4804
|
|
|
4788
4805
|
_this.checkSetDisplayValue(input, url);
|
|
4789
4806
|
|
|
4790
|
-
_context.next =
|
|
4807
|
+
_context.next = 24;
|
|
4791
4808
|
break;
|
|
4792
4809
|
|
|
4793
|
-
case
|
|
4794
|
-
_context.prev =
|
|
4795
|
-
_context.t0 = _context["catch"](
|
|
4810
|
+
case 20:
|
|
4811
|
+
_context.prev = 20;
|
|
4812
|
+
_context.t0 = _context["catch"](12);
|
|
4796
4813
|
console.log('handleFile error', _context.t0);
|
|
4797
4814
|
|
|
4798
4815
|
_this.setState({
|
|
4799
4816
|
uploadingFile: false
|
|
4800
4817
|
});
|
|
4801
4818
|
|
|
4802
|
-
case
|
|
4819
|
+
case 24:
|
|
4803
4820
|
case "end":
|
|
4804
4821
|
return _context.stop();
|
|
4805
4822
|
}
|
|
4806
4823
|
}
|
|
4807
|
-
}, _callee, null, [[
|
|
4824
|
+
}, _callee, null, [[12, 20]]);
|
|
4808
4825
|
}));
|
|
4809
4826
|
|
|
4810
4827
|
return function (_x, _x2) {
|
package/package.json
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@plusscommunities/pluss-core-web",
|
|
3
|
-
"version": "1.1.
|
|
3
|
+
"version": "1.1.13",
|
|
4
4
|
"description": "Core extension package for Pluss Communities platform",
|
|
5
5
|
"main": "dist/index.cjs.js",
|
|
6
6
|
"scripts": {
|
|
7
7
|
"build": "npm i && rollup -c",
|
|
8
8
|
"patch": "npm version patch",
|
|
9
|
-
"upload": "npm build && npm publish --access public && rm -rf node_modules",
|
|
9
|
+
"upload": "npm run build && npm publish --access public && rm -rf node_modules",
|
|
10
10
|
"upload:p": "npm run patch && npm run upload"
|
|
11
11
|
},
|
|
12
12
|
"author": "Phillip Suh",
|
|
@@ -151,7 +151,8 @@ class FileInputComponent extends Component {
|
|
|
151
151
|
});
|
|
152
152
|
this.checkRefreshCallback(newInputs);
|
|
153
153
|
if (this.props.handleFile) {
|
|
154
|
-
this.props.handleFile(file, newInputs);
|
|
154
|
+
await this.props.handleFile(file, newInputs);
|
|
155
|
+
this.setState({ uploadingFile: false });
|
|
155
156
|
} else {
|
|
156
157
|
try {
|
|
157
158
|
let uploadFile = file;
|