muba-posting 4.0.5 → 4.0.6

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.
Files changed (2) hide show
  1. package/Posting.js +7 -2
  2. package/package.json +1 -1
package/Posting.js CHANGED
@@ -400,14 +400,19 @@ export default class Posting extends React.Component {
400
400
  }
401
401
  }
402
402
 
403
- _showLoading() {
403
+ async _showLoading() {
404
404
  this.setState({ isLoading: true });
405
405
  }
406
406
 
407
- _hideLoading() {
407
+ async _hideLoading() {
408
+ await this.sleep(500);
408
409
  this.setState({ isLoading: false });
409
410
  }
410
411
 
412
+ sleep = (ms) => {
413
+ return new Promise(resolve => setTimeout(resolve, ms));
414
+ }
415
+
411
416
  _openPictureSelector() {
412
417
  this.setState({ showImageBrowser: true })
413
418
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "muba-posting",
3
- "version": "4.0.5",
3
+ "version": "4.0.6",
4
4
  "description": "Posting",
5
5
  "main": "Posting.js",
6
6
  "scripts": {