react-native-face-match-sdk 1.0.1 → 1.0.4

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/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 androidmasterid
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md CHANGED
@@ -48,7 +48,7 @@ Installing the packed tarball avoids this, because it is copied into
48
48
 
49
49
  ```bash
50
50
  cd ../react-native-face-match-sdk && npm pack
51
- cd ../your-app && npm install ../react-native-face-match-sdk/react-native-face-match-sdk-1.0.1.tgz
51
+ cd ../your-app && npm install ../react-native-face-match-sdk/react-native-face-match-sdk-1.0.3.tgz
52
52
  ```
53
53
 
54
54
  ### Android
@@ -165,11 +165,27 @@ the same scores.
165
165
 
166
166
  ## Publishing
167
167
 
168
- `publishConfig.access` is `restricted`, so `npm publish` creates a **private**
169
- package. That needs a paid npm plan. Before making it public, check the licence
170
- of both model files and choose a licence for the code.
168
+ The package is published publicly on npm. To release a new version:
171
169
 
172
170
  ```bash
173
- npm pack --dry-run # check exactly which files will be published
171
+ npm version patch # bumps package.json and creates a git tag
172
+ git push origin main --tags
173
+ npm pack --dry-run # check exactly which files will be published
174
174
  npm publish
175
175
  ```
176
+
177
+ ## License
178
+
179
+ The SDK source code is released under the [MIT License](LICENSE).
180
+
181
+ The bundled model files in `models/` are third-party works and keep their own
182
+ licenses. The MIT License does not apply to them:
183
+
184
+ | File | Origin | License |
185
+ |------|--------|---------|
186
+ | `anti_spoof_minifasnet_v2.onnx` | MiniVision [Silent-Face-Anti-Spoofing](https://github.com/minivision-ai/Silent-Face-Anti-Spoofing) (`2.7_80x80_MiniFASNetV2`, converted to ONNX) | Apache-2.0 |
187
+ | `w600k_mbf.onnx` | [InsightFace](https://github.com/deepinsight/insightface) WebFace600K MobileFaceNet | InsightFace states its pretrained models are for **non-commercial research purposes only** |
188
+
189
+ If you use this SDK in a commercial product, check the InsightFace terms and get
190
+ a commercial license from InsightFace, or replace `w600k_mbf.onnx` with a face
191
+ embedding model whose license allows commercial use.
@@ -49,7 +49,7 @@ class FaceMatchModule(private val reactContext: ReactApplicationContext) :
49
49
 
50
50
  @ReactMethod
51
51
  fun pickImage(promise: Promise) {
52
- val activity = currentActivity
52
+ val activity = reactContext.currentActivity
53
53
  if (activity == null) {
54
54
  promise.reject("E_NO_ACTIVITY", "No foreground Activity is available")
55
55
  return
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "react-native-face-match-sdk",
3
- "version": "1.0.1",
3
+ "version": "1.0.4",
4
4
  "description": "Offline on-device face liveness, anti-spoofing and face matching for React Native (Android and iOS).",
5
5
  "main": "src/index.ts",
6
6
  "types": "src/index.ts",
@@ -16,7 +16,8 @@
16
16
  "ios/onnxruntime-c.podspec",
17
17
  "FaceMatch.podspec",
18
18
  "react-native.config.js",
19
- "README.md"
19
+ "README.md",
20
+ "LICENSE"
20
21
  ],
21
22
  "keywords": [
22
23
  "react-native",
@@ -28,7 +29,7 @@
28
29
  "ios"
29
30
  ],
30
31
  "author": "androidmasterid",
31
- "license": "UNLICENSED",
32
+ "license": "MIT",
32
33
  "private": false,
33
34
  "publishConfig": {
34
35
  "access": "public"
@@ -36,5 +37,13 @@
36
37
  "peerDependencies": {
37
38
  "react": "*",
38
39
  "react-native": ">=0.76.0"
40
+ },
41
+ "repository": {
42
+ "type": "git",
43
+ "url": "git+https://github.com/androidmasterid/react-native-face-match-sdk.git"
44
+ },
45
+ "homepage": "https://github.com/androidmasterid/react-native-face-match-sdk#readme",
46
+ "bugs": {
47
+ "url": "https://github.com/androidmasterid/react-native-face-match-sdk/issues"
39
48
  }
40
49
  }