@aparajita/capacitor-biometric-auth 2.0.2 → 2.0.5
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
|
@@ -1,11 +1,19 @@
|
|
|
1
1
|
<div class="markdown-body">
|
|
2
2
|
|
|
3
|
-
# capacitor-biometric-auth
|
|
3
|
+
# capacitor-biometric-auth [](https://badge.fury.io/js/@aparajita%2Fcapacitor-biometric-auth)
|
|
4
4
|
|
|
5
5
|
This plugin for [Capacitor 3](https://capacitorjs.com) provides access to native biometry on iOS and Android. It supports every type of biometry and every configuration option on both platforms. In addition, biometry is simulated on the web so you can test your logic without making any changes to your code.
|
|
6
6
|
|
|
7
7
|
👉 **NOTE:** This plugin only works with Capacitor 3. If you are upgrading from the Capacitor 2 version, note that the plugin name has changed to `BiometricAuth`.
|
|
8
8
|
|
|
9
|
+
## Demos
|
|
10
|
+
|
|
11
|
+
Here is `capacitor-biometric-auth` running on the [demo app](https://github.com/aparajita/capacitor-biometric-auth-demo) on both iOS and Android.
|
|
12
|
+
|
|
13
|
+
|iOS|Android|
|
|
14
|
+
|---|-------|
|
|
15
|
+
|<video src="https://user-images.githubusercontent.com/22218/177023147-1f9abce4-2dc3-4157-8bf1-d8d9fdba3977.mp4" width="352" />|<video src="https://user-images.githubusercontent.com/22218/177023168-d7c18a4b-a2f9-49f9-ae39-40884219c128.mp4" width="365" />|
|
|
16
|
+
|
|
9
17
|
## Installation
|
|
10
18
|
|
|
11
19
|
```sh
|
|
@@ -110,12 +110,12 @@ public class AuthActivity extends AppCompatActivity {
|
|
|
110
110
|
|
|
111
111
|
// When allowDeviceCredential is true, I can't seem to force the prompt
|
|
112
112
|
// to go away, so skip attempt counting.
|
|
113
|
-
if (!allowDeviceCredential && attemptCount
|
|
113
|
+
if (!allowDeviceCredential && attemptCount >= maxAttempts) {
|
|
114
114
|
finishActivity(
|
|
115
115
|
BiometryResultType.FAILURE,
|
|
116
116
|
0,
|
|
117
117
|
String.format(
|
|
118
|
-
"The user
|
|
118
|
+
"The user reached the maximum of %d attempt(s)",
|
|
119
119
|
maxAttempts
|
|
120
120
|
)
|
|
121
121
|
);
|
package/dist/esm/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@aparajita/capacitor-biometric-auth",
|
|
3
|
-
"version": "2.0.
|
|
3
|
+
"version": "2.0.4",
|
|
4
4
|
"description": "Provides access to the native biometric auth APIs for Capacitor apps",
|
|
5
5
|
"author": "Aparajita Fishman",
|
|
6
6
|
"license": "MIT",
|
|
@@ -43,8 +43,8 @@
|
|
|
43
43
|
"verify:android": "cd android && ./gradlew clean build test && cd ..",
|
|
44
44
|
"verify:web": "pnpm build",
|
|
45
45
|
"push": "git push --follow-tags origin main",
|
|
46
|
-
"release.check": "commit-and-tag-version $VERSION --dry-run",
|
|
47
|
-
"release": "commit-and-tag-version $VERSION && pnpm push && pnpm publish"
|
|
46
|
+
"release.check": "commit-and-tag-version ${VERSION:+-r $VERSION} --dry-run",
|
|
47
|
+
"release": "commit-and-tag-version ${VERSION:+-r $VERSION} && pnpm push && pnpm publish"
|
|
48
48
|
},
|
|
49
49
|
"keywords": [
|
|
50
50
|
"capacitor",
|
|
@@ -67,7 +67,7 @@
|
|
|
67
67
|
"swiftlint": "@ionic/swiftlint-config",
|
|
68
68
|
"repository": {
|
|
69
69
|
"type": "git",
|
|
70
|
-
"url": "https://github.com/aparajita/capacitor-biometric-auth"
|
|
70
|
+
"url": "https://github.com/aparajita/capacitor-biometric-auth.git"
|
|
71
71
|
},
|
|
72
72
|
"bugs": {
|
|
73
73
|
"url": "https://github.com/aparajita/capacitor-biometric-auth/issues"
|
|
@@ -77,21 +77,21 @@
|
|
|
77
77
|
"@aparajita/capacitor-docgen-format": "github:aparajita/capacitor-docgen-format",
|
|
78
78
|
"@aparajita/eslint-config-base": "^1.1.2",
|
|
79
79
|
"@aparajita/prettier-config": "^1.0.0",
|
|
80
|
-
"@aparajita/swiftly": "^1.0.
|
|
80
|
+
"@aparajita/swiftly": "^1.0.1",
|
|
81
81
|
"@capacitor/core": "^3.6.0",
|
|
82
82
|
"@ionic/swiftlint-config": "^1.1.2",
|
|
83
83
|
"@rollup/plugin-json": "^4.1.0",
|
|
84
|
-
"@types/node": "^18.0.
|
|
85
|
-
"@typescript-eslint/eslint-plugin": "^5.30.
|
|
86
|
-
"@typescript-eslint/parser": "^5.30.
|
|
84
|
+
"@types/node": "^18.0.1",
|
|
85
|
+
"@typescript-eslint/eslint-plugin": "^5.30.5",
|
|
86
|
+
"@typescript-eslint/parser": "^5.30.5",
|
|
87
87
|
"chalk": "^5.0.1",
|
|
88
88
|
"commit-and-tag-version": "^10.0.1",
|
|
89
89
|
"eslint": "^8.19.0",
|
|
90
90
|
"eslint-config-prettier": "^8.5.0",
|
|
91
91
|
"eslint-config-standard": "^17.0.0",
|
|
92
|
-
"eslint-import-resolver-typescript": "^3.1
|
|
92
|
+
"eslint-import-resolver-typescript": "^3.2.1",
|
|
93
93
|
"eslint-plugin-import": "^2.26.0",
|
|
94
|
-
"eslint-plugin-n": "^15.2.
|
|
94
|
+
"eslint-plugin-n": "^15.2.4",
|
|
95
95
|
"eslint-plugin-prettier": "^4.2.1",
|
|
96
96
|
"eslint-plugin-promise": "^6.0.0",
|
|
97
97
|
"nodemon": "^2.0.18",
|
|
@@ -102,7 +102,7 @@
|
|
|
102
102
|
"typescript": "~4.7.4"
|
|
103
103
|
},
|
|
104
104
|
"dependencies": {
|
|
105
|
-
"@aparajita/capacitor-native-decorator": "
|
|
105
|
+
"@aparajita/capacitor-native-decorator": "^2.0.4",
|
|
106
106
|
"@capacitor/android": "^3.6.0",
|
|
107
107
|
"@capacitor/app": "^1.1.1",
|
|
108
108
|
"@capacitor/ios": "^3.6.0"
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@aparajita/capacitor-biometric-auth",
|
|
3
|
-
"version": "2.0.
|
|
3
|
+
"version": "2.0.5",
|
|
4
4
|
"description": "Provides access to the native biometric auth APIs for Capacitor apps",
|
|
5
5
|
"author": "Aparajita Fishman",
|
|
6
6
|
"license": "MIT",
|
|
@@ -40,7 +40,7 @@
|
|
|
40
40
|
"swiftlint": "@ionic/swiftlint-config",
|
|
41
41
|
"repository": {
|
|
42
42
|
"type": "git",
|
|
43
|
-
"url": "https://github.com/aparajita/capacitor-biometric-auth"
|
|
43
|
+
"url": "https://github.com/aparajita/capacitor-biometric-auth.git"
|
|
44
44
|
},
|
|
45
45
|
"bugs": {
|
|
46
46
|
"url": "https://github.com/aparajita/capacitor-biometric-auth/issues"
|
|
@@ -50,21 +50,21 @@
|
|
|
50
50
|
"@aparajita/capacitor-docgen-format": "github:aparajita/capacitor-docgen-format",
|
|
51
51
|
"@aparajita/eslint-config-base": "^1.1.2",
|
|
52
52
|
"@aparajita/prettier-config": "^1.0.0",
|
|
53
|
-
"@aparajita/swiftly": "^1.0.
|
|
53
|
+
"@aparajita/swiftly": "^1.0.1",
|
|
54
54
|
"@capacitor/core": "^3.6.0",
|
|
55
55
|
"@ionic/swiftlint-config": "^1.1.2",
|
|
56
56
|
"@rollup/plugin-json": "^4.1.0",
|
|
57
|
-
"@types/node": "^18.0.
|
|
58
|
-
"@typescript-eslint/eslint-plugin": "^5.30.
|
|
59
|
-
"@typescript-eslint/parser": "^5.30.
|
|
57
|
+
"@types/node": "^18.0.1",
|
|
58
|
+
"@typescript-eslint/eslint-plugin": "^5.30.5",
|
|
59
|
+
"@typescript-eslint/parser": "^5.30.5",
|
|
60
60
|
"chalk": "^5.0.1",
|
|
61
61
|
"commit-and-tag-version": "^10.0.1",
|
|
62
62
|
"eslint": "^8.19.0",
|
|
63
63
|
"eslint-config-prettier": "^8.5.0",
|
|
64
64
|
"eslint-config-standard": "^17.0.0",
|
|
65
|
-
"eslint-import-resolver-typescript": "^3.1
|
|
65
|
+
"eslint-import-resolver-typescript": "^3.2.1",
|
|
66
66
|
"eslint-plugin-import": "^2.26.0",
|
|
67
|
-
"eslint-plugin-n": "^15.2.
|
|
67
|
+
"eslint-plugin-n": "^15.2.4",
|
|
68
68
|
"eslint-plugin-prettier": "^4.2.1",
|
|
69
69
|
"eslint-plugin-promise": "^6.0.0",
|
|
70
70
|
"nodemon": "^2.0.18",
|
|
@@ -75,7 +75,7 @@
|
|
|
75
75
|
"typescript": "~4.7.4"
|
|
76
76
|
},
|
|
77
77
|
"dependencies": {
|
|
78
|
-
"@aparajita/capacitor-native-decorator": "^2.0.
|
|
78
|
+
"@aparajita/capacitor-native-decorator": "^2.0.4",
|
|
79
79
|
"@capacitor/android": "^3.6.0",
|
|
80
80
|
"@capacitor/app": "^1.1.1",
|
|
81
81
|
"@capacitor/ios": "^3.6.0"
|
|
@@ -107,7 +107,7 @@
|
|
|
107
107
|
"verify:android": "cd android && ./gradlew clean build test && cd ..",
|
|
108
108
|
"verify:web": "pnpm build",
|
|
109
109
|
"push": "git push --follow-tags origin main",
|
|
110
|
-
"release.check": "commit-and-tag-version $VERSION --dry-run",
|
|
111
|
-
"release": "commit-and-tag-version $VERSION && pnpm push && pnpm publish"
|
|
110
|
+
"release.check": "commit-and-tag-version ${VERSION:+-r $VERSION} --dry-run",
|
|
111
|
+
"release": "commit-and-tag-version ${VERSION:+-r $VERSION} && pnpm push && pnpm publish"
|
|
112
112
|
}
|
|
113
113
|
}
|