@idpass/smartscanner-capacitor 0.5.0-beta.3 → 0.5.0-beta.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.
package/README.md CHANGED
@@ -16,12 +16,11 @@ yarn add @idpass/smartscanner-capacitor
16
16
 
17
17
  ## Usage
18
18
 
19
- The plugin can be used through Capacitor's `Plugins` object, which is the registry of all available plugins.
19
+ The plugin can be used by accessing SmartScannerPlugin from @idpass/smartscanner-capacitor directly.
20
20
 
21
21
  ```js
22
- import { Plugins } from '@capacitor/core';
22
+ import { SmartScannerPlugin } from '@idpass/smartscanner-capacitor';
23
23
 
24
- const { SmartScannerPlugin } = Plugins;
25
24
  ```
26
25
 
27
26
  MRZ scanning example:
Binary file
@@ -1,5 +1,6 @@
1
1
  <?xml version="1.0" encoding="UTF-8"?>
2
2
  <project version="4">
3
+ <component name="GradleMigrationSettings" migrationVersion="1" />
3
4
  <component name="GradleSettings">
4
5
  <option name="linkedExternalProjectsSettings">
5
6
  <GradleProjectSettings>
@@ -35,6 +35,7 @@
35
35
  <sourceFolder url="file://$MODULE_DIR$/../../../../node_modules/@capacitor/android/capacitor/src/androidTest/java" isTestSource="true" />
36
36
  <sourceFolder url="file://$MODULE_DIR$/../../../../node_modules/@capacitor/android/capacitor/src/test/java" isTestSource="true" />
37
37
  <sourceFolder url="file://$MODULE_DIR$/../../../../node_modules/@capacitor/android/capacitor/src/main/res" type="java-resource" />
38
+ <sourceFolder url="file://$MODULE_DIR$/../../../../node_modules/@capacitor/android/capacitor/src/main/assets" type="java-resource" />
38
39
  <excludeFolder url="file://$MODULE_DIR$/../../../../node_modules/@capacitor/android/capacitor/.gradle" />
39
40
  <excludeFolder url="file://$MODULE_DIR$/../../../../node_modules/@capacitor/android/capacitor/build" />
40
41
  </content>
@@ -60,6 +60,8 @@
60
60
  <sourceFolder url="file://$MODULE_DIR$/../../src/androidTest/java" isTestSource="true" />
61
61
  <sourceFolder url="file://$MODULE_DIR$/../../src/test/java" isTestSource="true" />
62
62
  <sourceFolder url="file://$MODULE_DIR$/../../src/main/res" type="java-resource" />
63
+ <sourceFolder url="file://$MODULE_DIR$/../../build/generated/ap_generated_sources/debug/out" isTestSource="false" generated="true" />
64
+ <sourceFolder url="file://$MODULE_DIR$/../../build/generated/source/buildConfig/debug" isTestSource="false" generated="true" />
63
65
  <excludeFolder url="file://$MODULE_DIR$/../../.gradle" />
64
66
  <excludeFolder url="file://$MODULE_DIR$/../../build" />
65
67
  </content>
@@ -120,6 +120,7 @@
120
120
  </entry>
121
121
  </map>
122
122
  </option>
123
+ <option name="oldMeFiltersMigrated" value="true" />
123
124
  </component>
124
125
  <component name="VcsManagerConfiguration">
125
126
  <option name="CHECK_CODE_SMELLS_BEFORE_PROJECT_COMMIT" value="false" />
@@ -2,12 +2,13 @@ package org.idpass.smartscanner.capacitor
2
2
 
3
3
  import android.app.Activity
4
4
  import android.content.Intent
5
- import com.getcapacitor.JSObject;
6
- import com.getcapacitor.Plugin;
7
- import com.getcapacitor.PluginCall;
8
- import com.getcapacitor.PluginMethod;
9
- import com.getcapacitor.annotation.CapacitorPlugin;
10
- import com.getcapacitor.annotation.Permission;
5
+ import androidx.activity.result.ActivityResult
6
+ import com.getcapacitor.JSObject
7
+ import com.getcapacitor.Plugin
8
+ import com.getcapacitor.PluginCall
9
+ import com.getcapacitor.PluginMethod
10
+ import com.getcapacitor.annotation.ActivityCallback
11
+ import com.getcapacitor.annotation.CapacitorPlugin
11
12
  import com.google.gson.Gson
12
13
  import org.idpass.smartscanner.lib.SmartScannerActivity
13
14
  import org.idpass.smartscanner.lib.scanner.config.ScannerOptions
@@ -15,76 +16,50 @@ import org.json.JSONException
15
16
  import org.json.JSONObject
16
17
  import timber.log.Timber
17
18
 
18
- @CapacitorPlugin(
19
- name = "SmartScanner",
20
- requestCodes = [SmartScannerPlugin.REQUEST_OP_SCANNER],
21
- permissions = {
22
- @Permission(
23
- strings = { Manifest.permission.ACCESS_NETWORK_STATE },
24
- alias = "network"
25
- ),
26
- @Permission(strings = { Manifest.permission.INTERNET }, alias = "internet"),
27
- @Permission(
28
- strings = { Manifest.permission.CAMERA },
29
- alias = "camera"
30
- )
31
- }
32
- )
19
+ @CapacitorPlugin(name = "SmartScanner")
33
20
  class SmartScannerPlugin : Plugin() {
34
21
 
35
- companion object {
36
- const val REQUEST_OP_SCANNER = 1001
37
- }
38
-
39
22
  @PluginMethod
40
23
  fun executeScanner(call: PluginCall) {
41
24
  val action = call.getString("action")
42
25
  val options: JSONObject = call.getObject("options")
43
- saveCall(call)
44
26
  if (action == "START_SCANNER") {
45
27
  Timber.d("executeScanner %s", action)
46
28
  val intent = Intent(context, SmartScannerActivity::class.java)
47
29
  val scannerOptions = Gson().fromJson(options.toString(), ScannerOptions::class.java)
48
30
  intent.putExtra(SmartScannerActivity.SCANNER_OPTIONS, scannerOptions)
49
- startActivityForResult(call, intent, REQUEST_OP_SCANNER)
31
+ startActivityForResult(call, intent, "requestScannerResult")
50
32
  } else {
51
33
  call.reject("\"$action\" is not a recognized action.")
52
34
  }
53
35
  }
54
36
 
55
- override fun handleOnActivityResult(requestCode: Int, resultCode: Int, data: Intent?) {
56
- super.handleOnActivityResult(requestCode, resultCode, data)
57
- val savedCall = savedCall ?: return
58
- if (requestCode == REQUEST_OP_SCANNER) {
59
- try {
60
- Timber.d("Plugin post SmartScannerActivity resultCode %d", resultCode)
61
- if (resultCode == Activity.RESULT_OK) {
62
- val returnedResult = data?.getStringExtra(SmartScannerActivity.SCANNER_RESULT)
63
- Timber.d("Plugin post SmartScannerActivity result %s", returnedResult)
64
- try {
65
- if (returnedResult != null) {
66
- val result = JSONObject(returnedResult)
67
- val ret = JSObject()
68
- ret.put(SmartScannerActivity.SCANNER_RESULT, result)
69
- savedCall.resolve(ret)
70
- } else {
71
- savedCall.reject("Scanning result is null.")
72
- }
73
- } catch (e: JSONException) {
74
- e.printStackTrace()
37
+ @ActivityCallback
38
+ private fun requestScannerResult(call: PluginCall, result: ActivityResult) {
39
+ if (result.resultCode == Activity.RESULT_CANCELED) {
40
+ Timber.d("SmartScanner: RESULT CANCELLED")
41
+ call.reject("Scanning Cancelled.")
42
+ } else {
43
+ if (result.resultCode == Activity.RESULT_OK) {
44
+ val returnedResult = result.data?.getStringExtra(SmartScannerActivity.SCANNER_RESULT)
45
+ try {
46
+ if (returnedResult != null) {
47
+ Timber.d("SmartScanner: RESULT OK -- $returnedResult")
48
+ val scannerResult = JSONObject(returnedResult)
49
+ val ret = JSObject()
50
+ ret.put(SmartScannerActivity.SCANNER_RESULT, scannerResult)
51
+ call.resolve(ret)
52
+ } else {
53
+ Timber.d("SmartScanner: RESULT SCANNING NULL")
54
+ call.reject("Scanning result is null.")
75
55
  }
76
- } else if (resultCode == Activity.RESULT_CANCELED) {
77
- Timber.d("Plugin post SmartScannerActivity RESULT CANCELLED")
78
- savedCall.reject("Scanning Cancelled.")
79
- } else {
80
- savedCall.reject("Scanning Failed.")
56
+ } catch (e: JSONException) {
57
+ e.printStackTrace()
81
58
  }
82
- } catch (exception: Exception) {
83
- Timber.e(exception)
84
- exception.printStackTrace()
59
+ } else {
60
+ Timber.d("SmartScanner: RESULT SCANNING FAILED")
61
+ call.reject("Scanning Failed.")
85
62
  }
86
- } else {
87
- savedCall.reject("Unknown Request Code!")
88
63
  }
89
64
  }
90
- }
65
+ }
@@ -1 +1,2 @@
1
+ export {};
1
2
  //# sourceMappingURL=definitions.js.map
@@ -1,4 +1,4 @@
1
1
  import type { SmartScannerPlugin } from "./definitions";
2
- declare const SmartScannerPlugin: SmartScannerPlugin;
2
+ declare const SmartScanner: SmartScannerPlugin;
3
3
  export * from "./definitions";
4
- export { SmartScannerPlugin };
4
+ export { SmartScanner };
package/dist/esm/index.js CHANGED
@@ -1,5 +1,7 @@
1
1
  import { registerPlugin } from "@capacitor/core";
2
- const SmartScannerPlugin = registerPlugin("SmartScanner", {
3
- web: () => import("./web").then((m) => new m.SmartScannerPluginWeb()),
2
+ const SmartScanner = registerPlugin('SmartScanner', {
3
+ web: () => import("./web").then((m) => new m.SmartScannerPluginWeb())
4
4
  });
5
+ export * from "./definitions";
6
+ export { SmartScanner };
5
7
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,MAAM,iBAAiB,CAAC;AAGjD,MAAM,kBAAkB,GAAG,cAAc,CACvC,cAAc,EACd;IACE,GAAG,EAAE,GAAG,EAAE,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,IAAI,CAAC,CAAC,qBAAqB,EAAE,CAAC;CACtE,CACF,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,MAAM,iBAAiB,CAAC;AAGjD,MAAM,YAAY,GAAG,cAAc,CACjC,cAAc,EACd;IACE,GAAG,EAAE,GAAG,EAAE,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,IAAI,CAAC,CAAC,qBAAqB,EAAE,CAAC;CACtE,CACF,CAAC;AAEF,cAAc,eAAe,CAAC;AAC9B,OAAO,EAAE,YAAY,EAAE,CAAC"}
package/dist/esm/web.js CHANGED
@@ -2,10 +2,7 @@ import { WebPlugin } from '@capacitor/core';
2
2
  export * from './web';
3
3
  export class SmartScannerPluginWeb extends WebPlugin {
4
4
  constructor() {
5
- super({
6
- name: 'SmartScannerPlugin',
7
- platforms: ['web'],
8
- });
5
+ super();
9
6
  }
10
7
  async echo(options) {
11
8
  console.log('ECHO', options);
@@ -1 +1 @@
1
- {"version":3,"file":"web.js","sourceRoot":"","sources":["../../src/web.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAG5C,cAAc,OAAO,CAAC;AAEtB,MAAM,OAAO,qBAAsB,SAAQ,SAAS;IAClD;QACE,KAAK,CAAC;YACJ,IAAI,EAAE,oBAAoB;YAC1B,SAAS,EAAE,CAAC,KAAK,CAAC;SACnB,CAAC,CAAC;IACL,CAAC;IAED,KAAK,CAAC,IAAI,CAAC,OAA0B;QACnC,OAAO,CAAC,GAAG,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;QAC7B,OAAO,OAAO,CAAC;IACjB,CAAC;IAED,KAAK,CAAC,cAAc,CAAC,OAAyC;QAC5D,OAAO,CAAC,GAAG,CAAC,gBAAgB,EAAE,OAAO,CAAC,CAAC;IACzC,CAAC;CACF"}
1
+ {"version":3,"file":"web.js","sourceRoot":"","sources":["../../src/web.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAG5C,cAAc,OAAO,CAAC;AAEtB,MAAM,OAAO,qBAAsB,SAAQ,SAAS;IAClD;QACE,KAAK,EAAE,CAAC;IACV,CAAC;IAEM,KAAK,CAAC,IAAI,CAAC,OAA0B;QAC1C,OAAO,CAAC,GAAG,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;QAC7B,OAAO,OAAO,CAAC;IACjB,CAAC;IAEM,KAAK,CAAC,cAAc,CAAC,OAAyC;QACnE,OAAO,CAAC,GAAG,CAAC,gBAAgB,EAAE,OAAO,CAAC,CAAC;IACzC,CAAC;CACF"}
@@ -1,17 +1,16 @@
1
1
  'use strict';
2
2
 
3
+ Object.defineProperty(exports, '__esModule', { value: true });
4
+
3
5
  var core = require('@capacitor/core');
4
6
 
5
- const SmartScannerPlugin = core.registerPlugin("SmartScanner", {
6
- web: () => Promise.resolve().then(function () { return web; }).then((m) => new m.SmartScannerPluginWeb()),
7
+ const SmartScanner = core.registerPlugin('SmartScanner', {
8
+ web: () => Promise.resolve().then(function () { return web; }).then((m) => new m.SmartScannerPluginWeb())
7
9
  });
8
10
 
9
11
  class SmartScannerPluginWeb extends core.WebPlugin {
10
12
  constructor() {
11
- super({
12
- name: 'SmartScannerPlugin',
13
- platforms: ['web'],
14
- });
13
+ super();
15
14
  }
16
15
  async echo(options) {
17
16
  console.log('ECHO', options);
@@ -26,4 +25,6 @@ var web = /*#__PURE__*/Object.freeze({
26
25
  __proto__: null,
27
26
  SmartScannerPluginWeb: SmartScannerPluginWeb
28
27
  });
28
+
29
+ exports.SmartScanner = SmartScanner;
29
30
  //# sourceMappingURL=plugin.cjs.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"plugin.cjs.js","sources":["esm/index.js","esm/web.js"],"sourcesContent":["import { registerPlugin } from \"@capacitor/core\";\nconst SmartScannerPlugin = registerPlugin(\"SmartScanner\", {\n web: () => import(\"./web\").then((m) => new m.SmartScannerPluginWeb()),\n});\n//# sourceMappingURL=index.js.map","import { WebPlugin } from '@capacitor/core';\nexport * from './web';\nexport class SmartScannerPluginWeb extends WebPlugin {\n constructor() {\n super({\n name: 'SmartScannerPlugin',\n platforms: ['web'],\n });\n }\n async echo(options) {\n console.log('ECHO', options);\n return options;\n }\n async executeScanner(options) {\n console.log('executeScanner', options);\n }\n}\n//# sourceMappingURL=web.js.map"],"names":["registerPlugin","WebPlugin"],"mappings":";;;;AACA,MAAM,kBAAkB,GAAGA,mBAAc,CAAC,cAAc,EAAE;AAC1D,IAAI,GAAG,EAAE,MAAM,mDAAe,CAAC,IAAI,CAAC,CAAC,CAAC,KAAK,IAAI,CAAC,CAAC,qBAAqB,EAAE,CAAC;AACzE,CAAC,CAAC;;ACDK,MAAM,qBAAqB,SAASC,cAAS,CAAC;AACrD,IAAI,WAAW,GAAG;AAClB,QAAQ,KAAK,CAAC;AACd,YAAY,IAAI,EAAE,oBAAoB;AACtC,YAAY,SAAS,EAAE,CAAC,KAAK,CAAC;AAC9B,SAAS,CAAC,CAAC;AACX,KAAK;AACL,IAAI,MAAM,IAAI,CAAC,OAAO,EAAE;AACxB,QAAQ,OAAO,CAAC,GAAG,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;AACrC,QAAQ,OAAO,OAAO,CAAC;AACvB,KAAK;AACL,IAAI,MAAM,cAAc,CAAC,OAAO,EAAE;AAClC,QAAQ,OAAO,CAAC,GAAG,CAAC,gBAAgB,EAAE,OAAO,CAAC,CAAC;AAC/C,KAAK;AACL;;;;;;;"}
1
+ {"version":3,"file":"plugin.cjs.js","sources":["esm/index.js","esm/web.js"],"sourcesContent":["import { registerPlugin } from \"@capacitor/core\";\nconst SmartScanner = registerPlugin('SmartScanner', {\n web: () => import(\"./web\").then((m) => new m.SmartScannerPluginWeb())\n});\nexport * from \"./definitions\";\nexport { SmartScanner };\n//# sourceMappingURL=index.js.map","import { WebPlugin } from '@capacitor/core';\nexport * from './web';\nexport class SmartScannerPluginWeb extends WebPlugin {\n constructor() {\n super();\n }\n async echo(options) {\n console.log('ECHO', options);\n return options;\n }\n async executeScanner(options) {\n console.log('executeScanner', options);\n }\n}\n//# sourceMappingURL=web.js.map"],"names":["registerPlugin","WebPlugin"],"mappings":";;;;;;AACK,MAAC,YAAY,GAAGA,mBAAc,CAAC,cAAc,EAAE;AACpD,IAAI,GAAG,EAAE,MAAM,mDAAe,CAAC,IAAI,CAAC,CAAC,CAAC,KAAK,IAAI,CAAC,CAAC,qBAAqB,EAAE,CAAC;AACzE,CAAC;;ACDM,MAAM,qBAAqB,SAASC,cAAS,CAAC;AACrD,IAAI,WAAW,GAAG;AAClB,QAAQ,KAAK,EAAE,CAAC;AAChB,KAAK;AACL,IAAI,MAAM,IAAI,CAAC,OAAO,EAAE;AACxB,QAAQ,OAAO,CAAC,GAAG,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;AACrC,QAAQ,OAAO,OAAO,CAAC;AACvB,KAAK;AACL,IAAI,MAAM,cAAc,CAAC,OAAO,EAAE;AAClC,QAAQ,OAAO,CAAC,GAAG,CAAC,gBAAgB,EAAE,OAAO,CAAC,CAAC;AAC/C,KAAK;AACL;;;;;;;;;"}
package/dist/plugin.js CHANGED
@@ -1,16 +1,13 @@
1
- (function (core) {
1
+ var IdpassSmartscannerCapacitor = (function (exports, core) {
2
2
  'use strict';
3
3
 
4
- const SmartScannerPlugin = core.registerPlugin("SmartScanner", {
5
- web: () => Promise.resolve().then(function () { return web; }).then((m) => new m.SmartScannerPluginWeb()),
4
+ const SmartScanner = core.registerPlugin('SmartScanner', {
5
+ web: () => Promise.resolve().then(function () { return web; }).then((m) => new m.SmartScannerPluginWeb())
6
6
  });
7
7
 
8
8
  class SmartScannerPluginWeb extends core.WebPlugin {
9
9
  constructor() {
10
- super({
11
- name: 'SmartScannerPlugin',
12
- platforms: ['web'],
13
- });
10
+ super();
14
11
  }
15
12
  async echo(options) {
16
13
  console.log('ECHO', options);
@@ -26,5 +23,11 @@
26
23
  SmartScannerPluginWeb: SmartScannerPluginWeb
27
24
  });
28
25
 
29
- }(capacitorExports));
26
+ exports.SmartScanner = SmartScanner;
27
+
28
+ Object.defineProperty(exports, '__esModule', { value: true });
29
+
30
+ return exports;
31
+
32
+ })({}, capacitorExports);
30
33
  //# sourceMappingURL=plugin.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"plugin.js","sources":["esm/index.js","esm/web.js"],"sourcesContent":["import { registerPlugin } from \"@capacitor/core\";\nconst SmartScannerPlugin = registerPlugin(\"SmartScanner\", {\n web: () => import(\"./web\").then((m) => new m.SmartScannerPluginWeb()),\n});\n//# sourceMappingURL=index.js.map","import { WebPlugin } from '@capacitor/core';\nexport * from './web';\nexport class SmartScannerPluginWeb extends WebPlugin {\n constructor() {\n super({\n name: 'SmartScannerPlugin',\n platforms: ['web'],\n });\n }\n async echo(options) {\n console.log('ECHO', options);\n return options;\n }\n async executeScanner(options) {\n console.log('executeScanner', options);\n }\n}\n//# sourceMappingURL=web.js.map"],"names":["registerPlugin","WebPlugin"],"mappings":";;;IACA,MAAM,kBAAkB,GAAGA,mBAAc,CAAC,cAAc,EAAE;IAC1D,IAAI,GAAG,EAAE,MAAM,mDAAe,CAAC,IAAI,CAAC,CAAC,CAAC,KAAK,IAAI,CAAC,CAAC,qBAAqB,EAAE,CAAC;IACzE,CAAC,CAAC;;ICDK,MAAM,qBAAqB,SAASC,cAAS,CAAC;IACrD,IAAI,WAAW,GAAG;IAClB,QAAQ,KAAK,CAAC;IACd,YAAY,IAAI,EAAE,oBAAoB;IACtC,YAAY,SAAS,EAAE,CAAC,KAAK,CAAC;IAC9B,SAAS,CAAC,CAAC;IACX,KAAK;IACL,IAAI,MAAM,IAAI,CAAC,OAAO,EAAE;IACxB,QAAQ,OAAO,CAAC,GAAG,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IACrC,QAAQ,OAAO,OAAO,CAAC;IACvB,KAAK;IACL,IAAI,MAAM,cAAc,CAAC,OAAO,EAAE;IAClC,QAAQ,OAAO,CAAC,GAAG,CAAC,gBAAgB,EAAE,OAAO,CAAC,CAAC;IAC/C,KAAK;IACL;;;;;;;;;;;"}
1
+ {"version":3,"file":"plugin.js","sources":["esm/index.js","esm/web.js"],"sourcesContent":["import { registerPlugin } from \"@capacitor/core\";\nconst SmartScanner = registerPlugin('SmartScanner', {\n web: () => import(\"./web\").then((m) => new m.SmartScannerPluginWeb())\n});\nexport * from \"./definitions\";\nexport { SmartScanner };\n//# sourceMappingURL=index.js.map","import { WebPlugin } from '@capacitor/core';\nexport * from './web';\nexport class SmartScannerPluginWeb extends WebPlugin {\n constructor() {\n super();\n }\n async echo(options) {\n console.log('ECHO', options);\n return options;\n }\n async executeScanner(options) {\n console.log('executeScanner', options);\n }\n}\n//# sourceMappingURL=web.js.map"],"names":["registerPlugin","WebPlugin"],"mappings":";;;AACK,UAAC,YAAY,GAAGA,mBAAc,CAAC,cAAc,EAAE;IACpD,IAAI,GAAG,EAAE,MAAM,mDAAe,CAAC,IAAI,CAAC,CAAC,CAAC,KAAK,IAAI,CAAC,CAAC,qBAAqB,EAAE,CAAC;IACzE,CAAC;;ICDM,MAAM,qBAAqB,SAASC,cAAS,CAAC;IACrD,IAAI,WAAW,GAAG;IAClB,QAAQ,KAAK,EAAE,CAAC;IAChB,KAAK;IACL,IAAI,MAAM,IAAI,CAAC,OAAO,EAAE;IACxB,QAAQ,OAAO,CAAC,GAAG,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IACrC,QAAQ,OAAO,OAAO,CAAC;IACvB,KAAK;IACL,IAAI,MAAM,cAAc,CAAC,OAAO,EAAE;IAClC,QAAQ,OAAO,CAAC,GAAG,CAAC,gBAAgB,EAAE,OAAO,CAAC,CAAC;IAC/C,KAAK;IACL;;;;;;;;;;;;;;;;;"}
package/package.json CHANGED
@@ -1,8 +1,8 @@
1
1
  {
2
2
  "name": "@idpass/smartscanner-capacitor",
3
- "version": "0.5.0-beta.3",
3
+ "version": "0.5.0-beta.6",
4
4
  "description": "Capacitor plugin for the SmartScanner Core library to scan MRZ, NFC and barcodes",
5
- "main": "dist/plugin.js",
5
+ "main": "dist/plugin.cjs.js",
6
6
  "module": "dist/esm/index.js",
7
7
  "types": "dist/esm/index.d.ts",
8
8
  "scripts": {
@@ -16,23 +16,23 @@
16
16
  },
17
17
  "author": "NewLogic",
18
18
  "license": "Apache-2.0",
19
- "devDependencies": {
19
+ "dependencies": {
20
20
  "@capacitor/android": "^4.0.1",
21
21
  "@capacitor/cli": "^4.0.1",
22
22
  "@capacitor/core": "^4.0.1",
23
- "@capacitor/ios": "^4.0.1",
24
- "@ionic/prettier-config": "^1.0.0",
25
- "@ionic/swiftlint-config": "^1.0.0",
23
+ "@capacitor/ios": "^4.0.1"
24
+ },
25
+ "devDependencies": {
26
+ "@ionic/eslint-config": "^0.3.0",
27
+ "@ionic/prettier-config": "^1.0.1",
28
+ "@ionic/swiftlint-config": "^1.1.2",
26
29
  "@rollup/plugin-node-resolve": "^8.1.0",
27
- "prettier": "^2.0.5",
28
- "prettier-plugin-java": "^0.8.0",
29
- "rimraf": "^3.0.0",
30
- "rollup": "^2.21.0",
30
+ "eslint": "^7.11.0",
31
+ "prettier": "~2.2.0",
32
+ "rimraf": "^3.0.2",
33
+ "rollup": "^2.32.0",
31
34
  "swiftlint": "^1.0.1",
32
- "typescript": "~3.8.3"
33
- },
34
- "peerDependencies": {
35
- "@capacitor/core": "^4.0.1"
35
+ "typescript": "~4.0.3"
36
36
  },
37
37
  "files": [
38
38
  "dist/",
@@ -56,6 +56,9 @@
56
56
  },
57
57
  "prettier": "@ionic/prettier-config",
58
58
  "swiftlint": "@ionic/swiftlint-config",
59
+ "eslintConfig": {
60
+ "extends": "@ionic/eslint-config/recommended"
61
+ },
59
62
  "repository": {
60
63
  "type": "git",
61
64
  "url": "https://github.com/idpass/smartscanner-capacitor.git"
@@ -65,8 +68,5 @@
65
68
  },
66
69
  "publishConfig": {
67
70
  "access": "public"
68
- },
69
- "dependencies": {
70
- "np": "^7.6.2"
71
71
  }
72
72
  }