esoftplay 0.0.113-b → 0.0.113-e

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/bin/build.js CHANGED
@@ -213,29 +213,6 @@ yarn-error.log\n\
213
213
  console.log('.gitignore has been created');
214
214
  });
215
215
 
216
- // const AppJS = `import { esp, LibNotification } from 'esoftplay';
217
- // import * as ErrorReport from 'esoftplay/error';
218
- // import * as Notifications from 'expo-notifications';
219
- // import React, { useEffect, useRef } from 'react';
220
- // import { enableFreeze, enableScreens } from 'react-native-screens';
221
- // const { globalIdx } = require('esoftplay/global')
222
- // enableScreens();
223
- // enableFreeze(true);
224
-
225
- // Notifications.addNotificationResponseReceivedListener(x => LibNotification.onAction(x))
226
-
227
- // export default function App() {
228
- // const Home = useRef(esp.home()).current
229
-
230
- // useEffect(() => {
231
- // globalIdx.reset()
232
- // ErrorReport.getError()
233
- // }, [])
234
-
235
- // return <Home />
236
- // }`;
237
-
238
-
239
216
  const AppJS = `import { esp, LibNotification } from 'esoftplay';
240
217
  import * as ErrorReport from 'esoftplay/error';
241
218
  import * as Notifications from 'expo-notifications';
package/bin/cli.js CHANGED
@@ -1,6 +1,4 @@
1
1
  #!/usr/bin/env node
2
-
3
- const { spawn } = require('child_process');
4
2
  const fs = require('fs');
5
3
  const exec = require('child_process').execSync;
6
4
  const path = require('path');
@@ -312,13 +310,15 @@ function createMaster(module_name) {
312
310
  if (fs.existsSync("./assets"))
313
311
  shell("rm -r ./assets")
314
312
  shell("mkdir -p assets")
315
- shell("cp -r ../mobile/" + assetsModule + "/* ./assets/")
313
+ if (fs.existsSync('../mobile/' + assetsModule + '/*'))
314
+ shell("cp -r ../mobile/" + assetsModule + "/* ./assets/")
316
315
 
317
316
  /* copy fonts */
318
317
  if (fs.existsSync("./fonts"))
319
318
  shell("rm -r ./fonts")
320
319
  shell("mkdir -p fonts")
321
- shell("cp -r ../mobile/" + assetsFonts + "/* ./fonts/")
320
+ if (fs.existsSync('../mobile/' + assetsFonts + '/*'))
321
+ shell("cp -r ../mobile/" + assetsFonts + "/* ./assets/")
322
322
 
323
323
  /* copy lang */
324
324
  if (fs.existsSync("../mobile/assets/locale/id.json")) {
@@ -338,7 +338,7 @@ function createMaster(module_name) {
338
338
 
339
339
  if (fs.existsSync("./package.json")) {
340
340
  const packJson = require("./package.json")
341
- const letterVersion = ["abcdefghijklmnopqrstuvwxyz"]
341
+ const letterVersion = "abcdefghijklmnopqrstuvwxyz"
342
342
  const version = packJson.version
343
343
  const letter = version.match(/([a-z])/g)
344
344
  const number = version.replace(/-/g, "").replace(letter, "")
@@ -357,10 +357,11 @@ function createMaster(module_name) {
357
357
  nextNumber = Number(nextNumber) + 1
358
358
  nextVersion += nextNumber
359
359
  }
360
+
360
361
  const newPackJson = { ...packJson, version: nextVersion }
361
362
  fs.writeFileSync("./package.json", JSON.stringify(newPackJson, undefined, 2))
362
363
  shell("npm publish")
363
- console.log("\\nnpm install --save esoftplay-" + moduleName + "@" + nextVersion + "\\n")
364
+ console.log("\nnpm install --save esoftplay-" + moduleName + "@" + nextVersion + "\n")
364
365
  }`
365
366
  if (!fs.existsSync(PATH + "master/")) {
366
367
  fs.mkdirSync(PATH + "master")
@@ -29,7 +29,7 @@ export default class m {
29
29
  },
30
30
  (msg) => {
31
31
  LibProgress.hide()
32
- esp.log('Document Gagal di Upload', msg.msg)
32
+ esp.log('Document Gagal di Upload', msg.message)
33
33
  }
34
34
  )
35
35
  })
@@ -222,7 +222,7 @@ class m extends LibComponent<LibImageProps, LibImageState> {
222
222
  }
223
223
  },
224
224
  (msg: any) => {
225
- console.log(msg.msg, "NOOO")
225
+ console.log(msg.message, "NOOO")
226
226
  if (x.length - 1 == i)
227
227
  LibProgress.hide()
228
228
  }, 1)
@@ -261,7 +261,7 @@ class m extends LibComponent<LibImageProps, LibImageState> {
261
261
  },
262
262
  (msg: any) => {
263
263
  LibProgress.hide()
264
- r(msg.msg);
264
+ r(msg.message);
265
265
  }, 1)
266
266
  }, 1);
267
267
  }
@@ -134,12 +134,12 @@ export default class m extends LibComponent<LibInfiniteProps, LibInfiniteState>{
134
134
  },
135
135
  (msg) => {
136
136
  if (this.props.isDebug) {
137
- esp.log(msg.msg)
137
+ esp.log(msg.message)
138
138
  }
139
139
  this.page = page
140
140
  this.isStop = true
141
141
  this.setState({
142
- error: msg.msg,
142
+ error: msg.message,
143
143
  })
144
144
  }, this.props.isDebug
145
145
  )
@@ -74,7 +74,7 @@ export default class m extends LibComponent<LibRollProps, LibRollState>{
74
74
  })
75
75
  },
76
76
  (_msg) => {
77
- this.setState({ msg: _msg.msg })
77
+ this.setState({ msg: _msg.message })
78
78
  }
79
79
  )
80
80
  else
@@ -16,7 +16,7 @@ export default function m(initialWithLoading?: boolean, withProgressText?: strin
16
16
  }, (msg) => {
17
17
  LibProgress.hide()
18
18
  setLoading(false)
19
- setError(msg.msg)
19
+ setError(msg.message)
20
20
  }, debug)
21
21
  }
22
22
  return [curl, loading, error]
@@ -111,7 +111,7 @@ export default class eclass {
111
111
  AsyncStorage.setItem("token", String(token))
112
112
  resolve(res)
113
113
  }, (msg) => {
114
- resolve(msg.msg)
114
+ resolve(msg.message)
115
115
  })
116
116
  })
117
117
  }
@@ -90,7 +90,7 @@ export default class euserLogin extends LibComponent<UserLoginProps, UserLoginSt
90
90
  },
91
91
  (msg) => {
92
92
  // console.log("gagal => " + msg, email)
93
- this.onFailedLogin(msg.msg)
93
+ this.onFailedLogin(msg.message)
94
94
  this.setState({ isLoading: false, email: "" })
95
95
  }, 1
96
96
  )
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "esoftplay",
3
- "version": "0.0.113-b",
3
+ "version": "0.0.113-e",
4
4
  "description": "embedding data from esoftplay framework (web based) into mobile app",
5
5
  "main": "cache/index.js",
6
6
  "types": "../../index.d.ts",