@novastera-oss/nitro-metamask 0.7.0 → 0.7.2

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
@@ -63,9 +63,11 @@ No extra Android configuration is required for consumers of this package.
63
63
  For app developers, the expected upgrade path is:
64
64
 
65
65
  1. Update to the new npm version.
66
- 2. Clean install + clean Android build.
66
+ 2. Clean install + clean Android build (if you ever hit CMake / `react_codegen_*` / missing `codegen/jni` errors for this package, delete `android/app/.cxx` and `android/app/build`, then rebuild so autolinking regenerates).
67
67
  3. Rebuild release AAB/APK.
68
68
 
69
+ **New Architecture:** this library is intended for apps with `newArchEnabled=true` (Nitro + Nitrogen); it does not register React Native’s Codegen `react_codegen_*` target.
70
+
69
71
  No manual Gradle dependency override should be needed in the consuming app.
70
72
 
71
73
  ### iOS Configuration
@@ -18,15 +18,14 @@ def isNewArchitectureEnabled() {
18
18
  return rootProject.hasProperty("newArchEnabled") && rootProject.getProperty("newArchEnabled") == "true"
19
19
  }
20
20
 
21
+ // Nitro hybrid module: native bindings come from nitrogen/generated (NitroMetamask+autolinking.gradle + CMake).
22
+ // Do not apply com.facebook.react / react { libraryName } here — that registers RN New-Arch Codegen (react_codegen_*)
23
+ // and breaks consumers (CMake expects android/build/generated/source/codegen/jni/ which this package never ships).
21
24
  apply plugin: "com.android.library"
22
25
  apply plugin: 'org.jetbrains.kotlin.android'
23
26
  apply from: '../nitrogen/generated/android/NitroMetamask+autolinking.gradle'
24
27
  apply from: "./fix-prefab.gradle"
25
28
 
26
- if (isNewArchitectureEnabled()) {
27
- apply plugin: "com.facebook.react"
28
- }
29
-
30
29
  def getExtOrDefault(name) {
31
30
  return rootProject.ext.has(name) ? rootProject.ext.get(name) : project.properties["NitroMetamask_" + name]
32
31
  }
@@ -122,12 +121,6 @@ android {
122
121
  // npm consumers: libecies.so shipped as prebuilt in android/src/main/jniLibs
123
122
  jniLibs.srcDirs += ["${buildDir}/intermediates/rust-ecies-jni", "src/main/jniLibs"]
124
123
  aidl.srcDirs += ["src/main/aidl"]
125
- if (isNewArchitectureEnabled()) {
126
- java.srcDirs += [
127
- // React Codegen files
128
- "${project.buildDir}/generated/source/codegen/java"
129
- ]
130
- }
131
124
  }
132
125
  }
133
126
  }
@@ -157,12 +150,4 @@ dependencies {
157
150
  implementation "androidx.lifecycle:lifecycle-process:2.10.0"
158
151
  }
159
152
 
160
- apply from: "./cargo-ecies.gradle"
161
-
162
- if (isNewArchitectureEnabled()) {
163
- react {
164
- jsRootDir = file("../src/")
165
- libraryName = "NitroMetamask"
166
- codegenJavaPackageName = "com.margelo.nitro.nitrometamask"
167
- }
168
- }
153
+ apply from: "./cargo-ecies.gradle"
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@novastera-oss/nitro-metamask",
3
- "version": "0.7.0",
3
+ "version": "0.7.2",
4
4
  "description": "Native mobile MetaMask wallet integration for React Native. Part of Novastera CRM/ERP platform ecosystem. Provides secure authentication and message signing for Web3 mobile applications.",
5
5
  "main": "./lib/commonjs/index.js",
6
6
  "module": "./lib/module/index.js",
@@ -13,6 +13,11 @@ module.exports = {
13
13
  android: {
14
14
  packageImportPath: 'import com.margelo.nitro.nitrometamask.NitroMetamaskPackage;',
15
15
  packageInstance: 'new NitroMetamaskPackage()',
16
+ // New Arch: do not register RN Codegen + app CMake `react_codegen_*` for this dep.
17
+ // Native code is built via this library’s Gradle+CMake+JNI (Nitrogen), packaged in the AAR;
18
+ // autolink is only for Java Package / Gradle project inclusion.
19
+ libraryName: null,
20
+ cmakeListsPath: null,
16
21
  },
17
22
  },
18
23
  },