react-native-legal 1.5.0 → 1.5.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.
Files changed (34) hide show
  1. package/android/src/main/java/com/reactnativelegal/ReactNativeLegalTurboPackage.kt +2 -2
  2. package/android/src/oldarch/java/com/reactnativelegal/ReactNativeLegalModule.kt +1 -0
  3. package/bare-plugin/build/android/addListActivity.js +1 -2
  4. package/bare-plugin/build/android/androidCommand.js +1 -2
  5. package/bare-plugin/build/android/applyAndConfigureAboutLibrariesPlugin.js +1 -2
  6. package/bare-plugin/build/android/declareAboutLibrariesPlugin.js +1 -2
  7. package/bare-plugin/build/android/utils.js +2 -3
  8. package/bare-plugin/build/ios/addSettingsBundle.js +12 -4
  9. package/bare-plugin/build/ios/iosCommand.js +1 -2
  10. package/bare-plugin/build/ios/registerLicensePlistBuildPhase.js +1 -2
  11. package/bare-plugin/build/ios/utils.js +5 -6
  12. package/bare-plugin/src/ios/addSettingsBundle.ts +14 -2
  13. package/lib/commonjs/NativeReactNativeLegal.js +1 -2
  14. package/lib/commonjs/NativeReactNativeLegal.js.map +1 -1
  15. package/lib/commonjs/ReactNativeLegal.android.js +2 -3
  16. package/lib/commonjs/ReactNativeLegal.android.js.map +1 -1
  17. package/lib/commonjs/ReactNativeLegal.ios.js +2 -3
  18. package/lib/commonjs/ReactNativeLegal.ios.js.map +1 -1
  19. package/lib/commonjs/ReactNativeLegal.js +1 -2
  20. package/lib/commonjs/ReactNativeLegal.js.map +1 -1
  21. package/lib/commonjs/index.js.map +1 -1
  22. package/lib/module/NativeReactNativeLegal.js.map +1 -1
  23. package/lib/module/ReactNativeLegal.android.js.map +1 -1
  24. package/lib/module/ReactNativeLegal.ios.js.map +1 -1
  25. package/lib/module/ReactNativeLegal.js.map +1 -1
  26. package/lib/module/index.js.map +1 -1
  27. package/package.json +5 -5
  28. package/plugin/build/android/addListActivity.js +1 -2
  29. package/plugin/build/android/applyAndConfigureAboutLibrariesPlugin.js +1 -2
  30. package/plugin/build/android/declareAboutLibrariesPlugin.js +1 -2
  31. package/plugin/build/ios/addSettingsBundle.js +1 -2
  32. package/plugin/build/ios/registerLicensePlistBuildPhase.js +1 -2
  33. package/plugin-utils/build/android.js +3 -4
  34. package/plugin-utils/build/ios.js +2 -3
@@ -1,6 +1,6 @@
1
1
  package com.reactnativelegal
2
2
 
3
- import com.facebook.react.TurboReactPackage
3
+ import com.facebook.react.BaseReactPackage
4
4
  import com.facebook.react.bridge.NativeModule
5
5
  import com.facebook.react.bridge.ReactApplicationContext
6
6
  import com.facebook.react.module.annotations.ReactModule
@@ -8,7 +8,7 @@ import com.facebook.react.module.model.ReactModuleInfo
8
8
  import com.facebook.react.module.model.ReactModuleInfoProvider
9
9
  import com.facebook.react.turbomodule.core.interfaces.TurboModule
10
10
 
11
- class ReactNativeLegalTurboPackage : TurboReactPackage() {
11
+ class ReactNativeLegalTurboPackage : BaseReactPackage() {
12
12
  override fun getModule(name: String, reactContext: ReactApplicationContext): NativeModule? {
13
13
  return when (name) {
14
14
  ReactNativeLegalModule.NAME -> ReactNativeLegalModule(reactContext)
@@ -1,5 +1,6 @@
1
1
  package com.reactnativelegal
2
2
 
3
+ import com.facebook.react.bridge.Promise
3
4
  import com.facebook.react.bridge.ReactApplicationContext
4
5
  import com.facebook.react.bridge.ReactContextBaseJavaModule
5
6
  import com.facebook.react.bridge.ReactMethod
@@ -3,7 +3,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
3
3
  return (mod && mod.__esModule) ? mod : { "default": mod };
4
4
  };
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
- exports.addListActivity = void 0;
6
+ exports.addListActivity = addListActivity;
7
7
  const path_1 = __importDefault(require("path"));
8
8
  const android_1 = require("../../../plugin-utils/build/android");
9
9
  const utils_1 = require("./utils");
@@ -19,4 +19,3 @@ async function addListActivity(androidProjectPath) {
19
19
  return manifestObj;
20
20
  });
21
21
  }
22
- exports.addListActivity = addListActivity;
@@ -3,7 +3,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
3
3
  return (mod && mod.__esModule) ? mod : { "default": mod };
4
4
  };
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
- exports.androidCommand = void 0;
6
+ exports.androidCommand = androidCommand;
7
7
  const node_path_1 = __importDefault(require("node:path"));
8
8
  const licenses_1 = require("@callstack/licenses");
9
9
  const addListActivity_1 = require("./addListActivity");
@@ -22,4 +22,3 @@ function androidCommand(androidProjectPath) {
22
22
  (0, applyAndConfigureAboutLibrariesPlugin_1.applyAndConfigureAboutLibrariesPlugin)(androidProjectPath);
23
23
  (0, addListActivity_1.addListActivity)(androidProjectPath);
24
24
  }
25
- exports.androidCommand = androidCommand;
@@ -3,7 +3,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
3
3
  return (mod && mod.__esModule) ? mod : { "default": mod };
4
4
  };
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
- exports.applyAndConfigureAboutLibrariesPlugin = void 0;
6
+ exports.applyAndConfigureAboutLibrariesPlugin = applyAndConfigureAboutLibrariesPlugin;
7
7
  const fs_1 = __importDefault(require("fs"));
8
8
  const path_1 = __importDefault(require("path"));
9
9
  const android_1 = require("../../../plugin-utils/build/android");
@@ -24,4 +24,3 @@ function applyAndConfigureAboutLibrariesPlugin(androidProjectPath) {
24
24
  console.warn('Cannot find app/build.gradle file');
25
25
  }
26
26
  }
27
- exports.applyAndConfigureAboutLibrariesPlugin = applyAndConfigureAboutLibrariesPlugin;
@@ -3,7 +3,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
3
3
  return (mod && mod.__esModule) ? mod : { "default": mod };
4
4
  };
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
- exports.declareAboutLibrariesPlugin = void 0;
6
+ exports.declareAboutLibrariesPlugin = declareAboutLibrariesPlugin;
7
7
  const fs_1 = __importDefault(require("fs"));
8
8
  const path_1 = __importDefault(require("path"));
9
9
  const android_1 = require("../../../plugin-utils/build/android");
@@ -24,4 +24,3 @@ function declareAboutLibrariesPlugin(androidProjectPath) {
24
24
  console.warn('Cannot find build.gradle file');
25
25
  }
26
26
  }
27
- exports.declareAboutLibrariesPlugin = declareAboutLibrariesPlugin;
@@ -3,7 +3,8 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
3
3
  return (mod && mod.__esModule) ? mod : { "default": mod };
4
4
  };
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
- exports.modifyXMLFileContent = exports.modifyFileContent = void 0;
6
+ exports.modifyFileContent = modifyFileContent;
7
+ exports.modifyXMLFileContent = modifyXMLFileContent;
7
8
  const node_fs_1 = __importDefault(require("node:fs"));
8
9
  const xml2js_1 = __importDefault(require("xml2js"));
9
10
  /**
@@ -17,7 +18,6 @@ function modifyFileContent(filepath, transformFile) {
17
18
  const modifiedContent = transformFile(content);
18
19
  node_fs_1.default.writeFileSync(filepath, modifiedContent);
19
20
  }
20
- exports.modifyFileContent = modifyFileContent;
21
21
  /**
22
22
  * Used to modify a XML file at a specified file path
23
23
  *
@@ -34,4 +34,3 @@ async function modifyXMLFileContent(filepath, transformXMLFile) {
34
34
  const modifiedContent = builder.buildObject(modifiedObj);
35
35
  node_fs_1.default.writeFileSync(filepath, modifiedContent);
36
36
  }
37
- exports.modifyXMLFileContent = modifyXMLFileContent;
@@ -3,7 +3,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
3
3
  return (mod && mod.__esModule) ? mod : { "default": mod };
4
4
  };
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
- exports.addSettingsBundle = void 0;
6
+ exports.addSettingsBundle = addSettingsBundle;
7
7
  const fs_1 = __importDefault(require("fs"));
8
8
  const ios_1 = require("../../../plugin-utils/build/ios");
9
9
  const utils_1 = require("./utils");
@@ -14,8 +14,17 @@ function addSettingsBundle(iosProjectPath) {
14
14
  (0, ios_1.addSettingsBundleUtil)(iosProjectPath, ({ settingsBundleFilename }) => {
15
15
  const projectName = (0, utils_1.getIOSProjectName)(iosProjectPath);
16
16
  const { pbxproj, pbxprojPath } = (0, utils_1.getIOSPbxProj)(iosProjectPath);
17
- pbxproj.removeFile(settingsBundleFilename, pbxproj.findPBXGroupKey({ name: projectName }));
18
- const settingsBundleFile = pbxproj.addFile(settingsBundleFilename, pbxproj.findPBXGroupKey({ name: projectName }));
17
+ let group = pbxproj.findPBXGroupKey({ name: projectName });
18
+ if (!group) {
19
+ // https://github.com/callstackincubator/react-native-legal/issues/81
20
+ // If the project name is wrapped in quotes inside pbxproj file, let's try to grab it
21
+ group = pbxproj.findPBXGroupKey({ name: `"${projectName}"` });
22
+ }
23
+ if (!group) {
24
+ throw new Error(`Could not find group named: ${projectName} in the pbxproj`);
25
+ }
26
+ pbxproj.removeFile(settingsBundleFilename, group);
27
+ const settingsBundleFile = pbxproj.addFile(settingsBundleFilename, group);
19
28
  if (!settingsBundleFile) {
20
29
  throw new Error('Could not add Settings.bundle file reference to xcode project');
21
30
  }
@@ -25,4 +34,3 @@ function addSettingsBundle(iosProjectPath) {
25
34
  fs_1.default.writeFileSync(pbxprojPath, pbxproj.writeSync());
26
35
  });
27
36
  }
28
- exports.addSettingsBundle = addSettingsBundle;
@@ -3,7 +3,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
3
3
  return (mod && mod.__esModule) ? mod : { "default": mod };
4
4
  };
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
- exports.iosCommand = void 0;
6
+ exports.iosCommand = iosCommand;
7
7
  const node_path_1 = __importDefault(require("node:path"));
8
8
  const licenses_1 = require("@callstack/licenses");
9
9
  const addSettingsBundle_1 = require("./addSettingsBundle");
@@ -20,4 +20,3 @@ function iosCommand(iosProjectPath) {
20
20
  (0, addSettingsBundle_1.addSettingsBundle)(iosProjectPath);
21
21
  (0, registerLicensePlistBuildPhase_1.registerLicensePlistBuildPhase)(iosProjectPath);
22
22
  }
23
- exports.iosCommand = iosCommand;
@@ -3,7 +3,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
3
3
  return (mod && mod.__esModule) ? mod : { "default": mod };
4
4
  };
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
- exports.registerLicensePlistBuildPhase = void 0;
6
+ exports.registerLicensePlistBuildPhase = registerLicensePlistBuildPhase;
7
7
  const fs_1 = __importDefault(require("fs"));
8
8
  const ios_1 = require("../../../plugin-utils/build/ios");
9
9
  const utils_1 = require("./utils");
@@ -21,4 +21,3 @@ function registerLicensePlistBuildPhase(iosProjectPath) {
21
21
  });
22
22
  fs_1.default.writeFileSync(pbxprojPath, pbxproj.writeSync());
23
23
  }
24
- exports.registerLicensePlistBuildPhase = registerLicensePlistBuildPhase;
@@ -3,7 +3,11 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
3
3
  return (mod && mod.__esModule) ? mod : { "default": mod };
4
4
  };
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
- exports.getIOSPbxProj = exports.getIOSProjectName = exports.addToAllPbxResourcesBuildPhases = exports.getAllApplicationNativeTargets = exports.getFirstApplicationNativeTarget = void 0;
6
+ exports.getFirstApplicationNativeTarget = getFirstApplicationNativeTarget;
7
+ exports.getAllApplicationNativeTargets = getAllApplicationNativeTargets;
8
+ exports.addToAllPbxResourcesBuildPhases = addToAllPbxResourcesBuildPhases;
9
+ exports.getIOSProjectName = getIOSProjectName;
10
+ exports.getIOSPbxProj = getIOSPbxProj;
7
11
  const node_path_1 = __importDefault(require("node:path"));
8
12
  const glob_1 = __importDefault(require("glob"));
9
13
  const xcode_1 = __importDefault(require("xcode"));
@@ -14,7 +18,6 @@ const ignoredPaths = ['**/@(Carthage|Pods|vendor|node_modules)/**'];
14
18
  function getFirstApplicationNativeTarget(pbxproj) {
15
19
  return pbxproj.getTarget('com.apple.product-type.application');
16
20
  }
17
- exports.getFirstApplicationNativeTarget = getFirstApplicationNativeTarget;
18
21
  /**
19
22
  * Used to get all targets of type "com.apple.product-type.application"
20
23
  */
@@ -29,7 +32,6 @@ function getAllApplicationNativeTargets(pbxproj) {
29
32
  return acc;
30
33
  }, []);
31
34
  }
32
- exports.getAllApplicationNativeTargets = getAllApplicationNativeTargets;
33
35
  /**
34
36
  * Used to add the file to all "Resources" build phases
35
37
  *
@@ -62,7 +64,6 @@ function addToAllPbxResourcesBuildPhases(pbxproj, pbxFile) {
62
64
  });
63
65
  });
64
66
  }
65
- exports.addToAllPbxResourcesBuildPhases = addToAllPbxResourcesBuildPhases;
66
67
  /**
67
68
  * Returns the name of the main group in the project (the main folder where `AppDelegate` usually lives)
68
69
  */
@@ -76,7 +77,6 @@ function getIOSProjectName(iosProjectPath) {
76
77
  });
77
78
  return node_path_1.default.basename(node_path_1.default.dirname(appDelegatePath));
78
79
  }
79
- exports.getIOSProjectName = getIOSProjectName;
80
80
  /**
81
81
  * Used to grab the XcodeProject instance
82
82
  */
@@ -93,6 +93,5 @@ function getIOSPbxProj(iosProjectPath) {
93
93
  pbxproj.parseSync();
94
94
  return { pbxproj, pbxprojPath };
95
95
  }
96
- exports.getIOSPbxProj = getIOSPbxProj;
97
96
  const RESOURCES_BUILD_PHASE_IDENTIFIER = 'Resources';
98
97
  const COMMENT_KEY = /_comment$/;
@@ -12,9 +12,21 @@ export function addSettingsBundle(iosProjectPath: string) {
12
12
  const projectName = getIOSProjectName(iosProjectPath);
13
13
  const { pbxproj, pbxprojPath } = getIOSPbxProj(iosProjectPath);
14
14
 
15
- pbxproj.removeFile(settingsBundleFilename, pbxproj.findPBXGroupKey({ name: projectName }));
15
+ let group: string | undefined = pbxproj.findPBXGroupKey({ name: projectName });
16
16
 
17
- const settingsBundleFile = pbxproj.addFile(settingsBundleFilename, pbxproj.findPBXGroupKey({ name: projectName }));
17
+ if (!group) {
18
+ // https://github.com/callstackincubator/react-native-legal/issues/81
19
+ // If the project name is wrapped in quotes inside pbxproj file, let's try to grab it
20
+ group = pbxproj.findPBXGroupKey({ name: `"${projectName}"` });
21
+ }
22
+
23
+ if (!group) {
24
+ throw new Error(`Could not find group named: ${projectName} in the pbxproj`);
25
+ }
26
+
27
+ pbxproj.removeFile(settingsBundleFilename, group);
28
+
29
+ const settingsBundleFile = pbxproj.addFile(settingsBundleFilename, group);
18
30
 
19
31
  if (!settingsBundleFile) {
20
32
  throw new Error('Could not add Settings.bundle file reference to xcode project');
@@ -5,6 +5,5 @@ Object.defineProperty(exports, "__esModule", {
5
5
  });
6
6
  exports.default = void 0;
7
7
  var _reactNative = require("react-native");
8
- var _default = _reactNative.TurboModuleRegistry.getEnforcing('ReactNativeLegalModule');
9
- exports.default = _default;
8
+ var _default = exports.default = _reactNative.TurboModuleRegistry.getEnforcing('ReactNativeLegalModule');
10
9
  //# sourceMappingURL=NativeReactNativeLegal.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["_reactNative","require","_default","TurboModuleRegistry","getEnforcing","exports","default"],"sourceRoot":"../../src","sources":["NativeReactNativeLegal.ts"],"mappings":";;;;;;AACA,IAAAA,YAAA,GAAAC,OAAA;AAAmD,IAAAC,QAAA,GAiDpCC,gCAAmB,CAACC,YAAY,CAAO,wBAAwB,CAAC;AAAAC,OAAA,CAAAC,OAAA,GAAAJ,QAAA"}
1
+ {"version":3,"names":["_reactNative","require","_default","exports","default","TurboModuleRegistry","getEnforcing"],"sourceRoot":"../../src","sources":["NativeReactNativeLegal.ts"],"mappings":";;;;;;AACA,IAAAA,YAAA,GAAAC,OAAA;AAAmD,IAAAC,QAAA,GAAAC,OAAA,CAAAC,OAAA,GAiDpCC,gCAAmB,CAACC,YAAY,CAAO,wBAAwB,CAAC","ignoreList":[]}
@@ -5,8 +5,8 @@ Object.defineProperty(exports, "__esModule", {
5
5
  });
6
6
  exports.ReactNativeLegal = void 0;
7
7
  var _NativeReactNativeLegal = _interopRequireDefault(require("./NativeReactNativeLegal"));
8
- function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
9
- const ReactNativeLegal = {
8
+ function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
9
+ const ReactNativeLegal = exports.ReactNativeLegal = {
10
10
  getLibrariesAsync: () => {
11
11
  return _NativeReactNativeLegal.default.getLibrariesAsync();
12
12
  },
@@ -17,5 +17,4 @@ const ReactNativeLegal = {
17
17
  _NativeReactNativeLegal.default.launchLicenseListScreen(licenseHeaderText ?? 'OSS Licenses');
18
18
  }
19
19
  };
20
- exports.ReactNativeLegal = ReactNativeLegal;
21
20
  //# sourceMappingURL=ReactNativeLegal.android.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["_NativeReactNativeLegal","_interopRequireDefault","require","obj","__esModule","default","ReactNativeLegal","getLibrariesAsync","NativeReactNativeLegal","launchLicenseListScreen","licenseHeaderText","exports"],"sourceRoot":"../../src","sources":["ReactNativeLegal.android.ts"],"mappings":";;;;;;AAAA,IAAAA,uBAAA,GAAAC,sBAAA,CAAAC,OAAA;AAA8D,SAAAD,uBAAAE,GAAA,WAAAA,GAAA,IAAAA,GAAA,CAAAC,UAAA,GAAAD,GAAA,KAAAE,OAAA,EAAAF,GAAA;AAEvD,MAAMG,gBAAgB,GAAG;EAC9BC,iBAAiB,EAAEA,CAAA,KAAM;IACvB,OAAOC,+BAAsB,CAACD,iBAAiB,CAAC,CAAC;EACnD,CAAC;EACDE,uBAAuB,EAAGC,iBAA0B,IAAK;IACvD;AACJ;AACA;IACIF,+BAAsB,CAACC,uBAAuB,CAACC,iBAAiB,IAAI,cAAc,CAAC;EACrF;AACF,CAAC;AAACC,OAAA,CAAAL,gBAAA,GAAAA,gBAAA"}
1
+ {"version":3,"names":["_NativeReactNativeLegal","_interopRequireDefault","require","e","__esModule","default","ReactNativeLegal","exports","getLibrariesAsync","NativeReactNativeLegal","launchLicenseListScreen","licenseHeaderText"],"sourceRoot":"../../src","sources":["ReactNativeLegal.android.ts"],"mappings":";;;;;;AAAA,IAAAA,uBAAA,GAAAC,sBAAA,CAAAC,OAAA;AAA8D,SAAAD,uBAAAE,CAAA,WAAAA,CAAA,IAAAA,CAAA,CAAAC,UAAA,GAAAD,CAAA,KAAAE,OAAA,EAAAF,CAAA;AAEvD,MAAMG,gBAAgB,GAAAC,OAAA,CAAAD,gBAAA,GAAG;EAC9BE,iBAAiB,EAAEA,CAAA,KAAM;IACvB,OAAOC,+BAAsB,CAACD,iBAAiB,CAAC,CAAC;EACnD,CAAC;EACDE,uBAAuB,EAAGC,iBAA0B,IAAK;IACvD;AACJ;AACA;IACIF,+BAAsB,CAACC,uBAAuB,CAACC,iBAAiB,IAAI,cAAc,CAAC;EACrF;AACF,CAAC","ignoreList":[]}
@@ -5,8 +5,8 @@ Object.defineProperty(exports, "__esModule", {
5
5
  });
6
6
  exports.ReactNativeLegal = void 0;
7
7
  var _NativeReactNativeLegal = _interopRequireDefault(require("./NativeReactNativeLegal"));
8
- function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
9
- const ReactNativeLegal = {
8
+ function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
9
+ const ReactNativeLegal = exports.ReactNativeLegal = {
10
10
  getLibrariesAsync: () => {
11
11
  return _NativeReactNativeLegal.default.getLibrariesAsync();
12
12
  },
@@ -17,5 +17,4 @@ const ReactNativeLegal = {
17
17
  _NativeReactNativeLegal.default.launchLicenseListScreen(licenseHeaderText ?? 'OSS Licenses');
18
18
  }
19
19
  };
20
- exports.ReactNativeLegal = ReactNativeLegal;
21
20
  //# sourceMappingURL=ReactNativeLegal.ios.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["_NativeReactNativeLegal","_interopRequireDefault","require","obj","__esModule","default","ReactNativeLegal","getLibrariesAsync","NativeReactNativeLegal","launchLicenseListScreen","licenseHeaderText","exports"],"sourceRoot":"../../src","sources":["ReactNativeLegal.ios.ts"],"mappings":";;;;;;AAAA,IAAAA,uBAAA,GAAAC,sBAAA,CAAAC,OAAA;AAA8D,SAAAD,uBAAAE,GAAA,WAAAA,GAAA,IAAAA,GAAA,CAAAC,UAAA,GAAAD,GAAA,KAAAE,OAAA,EAAAF,GAAA;AAEvD,MAAMG,gBAAgB,GAAG;EAC9BC,iBAAiB,EAAEA,CAAA,KAAM;IACvB,OAAOC,+BAAsB,CAACD,iBAAiB,CAAC,CAAC;EACnD,CAAC;EACDE,uBAAuB,EAAGC,iBAA0B,IAAK;IACvD;AACJ;AACA;IACIF,+BAAsB,CAACC,uBAAuB,CAACC,iBAAiB,IAAI,cAAc,CAAC;EACrF;AACF,CAAC;AAACC,OAAA,CAAAL,gBAAA,GAAAA,gBAAA"}
1
+ {"version":3,"names":["_NativeReactNativeLegal","_interopRequireDefault","require","e","__esModule","default","ReactNativeLegal","exports","getLibrariesAsync","NativeReactNativeLegal","launchLicenseListScreen","licenseHeaderText"],"sourceRoot":"../../src","sources":["ReactNativeLegal.ios.ts"],"mappings":";;;;;;AAAA,IAAAA,uBAAA,GAAAC,sBAAA,CAAAC,OAAA;AAA8D,SAAAD,uBAAAE,CAAA,WAAAA,CAAA,IAAAA,CAAA,CAAAC,UAAA,GAAAD,CAAA,KAAAE,OAAA,EAAAF,CAAA;AAEvD,MAAMG,gBAAgB,GAAAC,OAAA,CAAAD,gBAAA,GAAG;EAC9BE,iBAAiB,EAAEA,CAAA,KAAM;IACvB,OAAOC,+BAAsB,CAACD,iBAAiB,CAAC,CAAC;EACnD,CAAC;EACDE,uBAAuB,EAAGC,iBAA0B,IAAK;IACvD;AACJ;AACA;IACIF,+BAAsB,CAACC,uBAAuB,CAACC,iBAAiB,IAAI,cAAc,CAAC;EACrF;AACF,CAAC","ignoreList":[]}
@@ -4,7 +4,7 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.ReactNativeLegal = void 0;
7
- const ReactNativeLegal = {
7
+ const ReactNativeLegal = exports.ReactNativeLegal = {
8
8
  getLibrariesAsync: () => {
9
9
  return Promise.resolve({
10
10
  data: []
@@ -14,5 +14,4 @@ const ReactNativeLegal = {
14
14
  //
15
15
  }
16
16
  };
17
- exports.ReactNativeLegal = ReactNativeLegal;
18
17
  //# sourceMappingURL=ReactNativeLegal.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["ReactNativeLegal","getLibrariesAsync","Promise","resolve","data","launchLicenseListScreen","_licenseHeaderText","exports"],"sourceRoot":"../../src","sources":["ReactNativeLegal.ts"],"mappings":";;;;;;AAEO,MAAMA,gBAAgB,GAAG;EAC9BC,iBAAiB,EAAEA,CAAA,KAAM;IACvB,OAAOC,OAAO,CAACC,OAAO,CAAkB;MAAEC,IAAI,EAAE;IAAG,CAAC,CAAC;EACvD,CAAC;EACDC,uBAAuB,EAAGC,kBAA2B,IAAK;IACxD;EAAA;AAEJ,CAAC;AAACC,OAAA,CAAAP,gBAAA,GAAAA,gBAAA"}
1
+ {"version":3,"names":["ReactNativeLegal","exports","getLibrariesAsync","Promise","resolve","data","launchLicenseListScreen","_licenseHeaderText"],"sourceRoot":"../../src","sources":["ReactNativeLegal.ts"],"mappings":";;;;;;AAEO,MAAMA,gBAAgB,GAAAC,OAAA,CAAAD,gBAAA,GAAG;EAC9BE,iBAAiB,EAAEA,CAAA,KAAM;IACvB,OAAOC,OAAO,CAACC,OAAO,CAAkB;MAAEC,IAAI,EAAE;IAAG,CAAC,CAAC;EACvD,CAAC;EACDC,uBAAuB,EAAGC,kBAA2B,IAAK;IACxD;EAAA;AAEJ,CAAC","ignoreList":[]}
@@ -1 +1 @@
1
- {"version":3,"names":["_ReactNativeLegal","require"],"sourceRoot":"../../src","sources":["index.ts"],"mappings":";;;;;;;;;;;AAAA,IAAAA,iBAAA,GAAAC,OAAA"}
1
+ {"version":3,"names":["_ReactNativeLegal","require"],"sourceRoot":"../../src","sources":["index.ts"],"mappings":";;;;;;;;;;;AAAA,IAAAA,iBAAA,GAAAC,OAAA","ignoreList":[]}
@@ -1 +1 @@
1
- {"version":3,"names":["TurboModuleRegistry","getEnforcing"],"sourceRoot":"../../src","sources":["NativeReactNativeLegal.ts"],"mappings":"AACA,SAASA,mBAAmB,QAAQ,cAAc;AAiDlD,eAAeA,mBAAmB,CAACC,YAAY,CAAO,wBAAwB,CAAC"}
1
+ {"version":3,"names":["TurboModuleRegistry","getEnforcing"],"sourceRoot":"../../src","sources":["NativeReactNativeLegal.ts"],"mappings":"AACA,SAASA,mBAAmB,QAAQ,cAAc;AAiDlD,eAAeA,mBAAmB,CAACC,YAAY,CAAO,wBAAwB,CAAC","ignoreList":[]}
@@ -1 +1 @@
1
- {"version":3,"names":["NativeReactNativeLegal","ReactNativeLegal","getLibrariesAsync","launchLicenseListScreen","licenseHeaderText"],"sourceRoot":"../../src","sources":["ReactNativeLegal.android.ts"],"mappings":"AAAA,OAAOA,sBAAsB,MAAM,0BAA0B;AAE7D,OAAO,MAAMC,gBAAgB,GAAG;EAC9BC,iBAAiB,EAAEA,CAAA,KAAM;IACvB,OAAOF,sBAAsB,CAACE,iBAAiB,CAAC,CAAC;EACnD,CAAC;EACDC,uBAAuB,EAAGC,iBAA0B,IAAK;IACvD;AACJ;AACA;IACIJ,sBAAsB,CAACG,uBAAuB,CAACC,iBAAiB,IAAI,cAAc,CAAC;EACrF;AACF,CAAC"}
1
+ {"version":3,"names":["NativeReactNativeLegal","ReactNativeLegal","getLibrariesAsync","launchLicenseListScreen","licenseHeaderText"],"sourceRoot":"../../src","sources":["ReactNativeLegal.android.ts"],"mappings":"AAAA,OAAOA,sBAAsB,MAAM,0BAA0B;AAE7D,OAAO,MAAMC,gBAAgB,GAAG;EAC9BC,iBAAiB,EAAEA,CAAA,KAAM;IACvB,OAAOF,sBAAsB,CAACE,iBAAiB,CAAC,CAAC;EACnD,CAAC;EACDC,uBAAuB,EAAGC,iBAA0B,IAAK;IACvD;AACJ;AACA;IACIJ,sBAAsB,CAACG,uBAAuB,CAACC,iBAAiB,IAAI,cAAc,CAAC;EACrF;AACF,CAAC","ignoreList":[]}
@@ -1 +1 @@
1
- {"version":3,"names":["NativeReactNativeLegal","ReactNativeLegal","getLibrariesAsync","launchLicenseListScreen","licenseHeaderText"],"sourceRoot":"../../src","sources":["ReactNativeLegal.ios.ts"],"mappings":"AAAA,OAAOA,sBAAsB,MAAM,0BAA0B;AAE7D,OAAO,MAAMC,gBAAgB,GAAG;EAC9BC,iBAAiB,EAAEA,CAAA,KAAM;IACvB,OAAOF,sBAAsB,CAACE,iBAAiB,CAAC,CAAC;EACnD,CAAC;EACDC,uBAAuB,EAAGC,iBAA0B,IAAK;IACvD;AACJ;AACA;IACIJ,sBAAsB,CAACG,uBAAuB,CAACC,iBAAiB,IAAI,cAAc,CAAC;EACrF;AACF,CAAC"}
1
+ {"version":3,"names":["NativeReactNativeLegal","ReactNativeLegal","getLibrariesAsync","launchLicenseListScreen","licenseHeaderText"],"sourceRoot":"../../src","sources":["ReactNativeLegal.ios.ts"],"mappings":"AAAA,OAAOA,sBAAsB,MAAM,0BAA0B;AAE7D,OAAO,MAAMC,gBAAgB,GAAG;EAC9BC,iBAAiB,EAAEA,CAAA,KAAM;IACvB,OAAOF,sBAAsB,CAACE,iBAAiB,CAAC,CAAC;EACnD,CAAC;EACDC,uBAAuB,EAAGC,iBAA0B,IAAK;IACvD;AACJ;AACA;IACIJ,sBAAsB,CAACG,uBAAuB,CAACC,iBAAiB,IAAI,cAAc,CAAC;EACrF;AACF,CAAC","ignoreList":[]}
@@ -1 +1 @@
1
- {"version":3,"names":["ReactNativeLegal","getLibrariesAsync","Promise","resolve","data","launchLicenseListScreen","_licenseHeaderText"],"sourceRoot":"../../src","sources":["ReactNativeLegal.ts"],"mappings":"AAEA,OAAO,MAAMA,gBAAgB,GAAG;EAC9BC,iBAAiB,EAAEA,CAAA,KAAM;IACvB,OAAOC,OAAO,CAACC,OAAO,CAAkB;MAAEC,IAAI,EAAE;IAAG,CAAC,CAAC;EACvD,CAAC;EACDC,uBAAuB,EAAGC,kBAA2B,IAAK;IACxD;EAAA;AAEJ,CAAC"}
1
+ {"version":3,"names":["ReactNativeLegal","getLibrariesAsync","Promise","resolve","data","launchLicenseListScreen","_licenseHeaderText"],"sourceRoot":"../../src","sources":["ReactNativeLegal.ts"],"mappings":"AAEA,OAAO,MAAMA,gBAAgB,GAAG;EAC9BC,iBAAiB,EAAEA,CAAA,KAAM;IACvB,OAAOC,OAAO,CAACC,OAAO,CAAkB;MAAEC,IAAI,EAAE;IAAG,CAAC,CAAC;EACvD,CAAC;EACDC,uBAAuB,EAAGC,kBAA2B,IAAK;IACxD;EAAA;AAEJ,CAAC","ignoreList":[]}
@@ -1 +1 @@
1
- {"version":3,"names":["ReactNativeLegal"],"sourceRoot":"../../src","sources":["index.ts"],"mappings":"AAAA,SAASA,gBAAgB,QAAQ,oBAAoB"}
1
+ {"version":3,"names":["ReactNativeLegal"],"sourceRoot":"../../src","sources":["index.ts"],"mappings":"AAAA,SAASA,gBAAgB,QAAQ,oBAAoB","ignoreList":[]}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "react-native-legal",
3
- "version": "1.5.0",
3
+ "version": "1.5.2",
4
4
  "description": "Acknowledge OSS libraries used in your React Native app",
5
5
  "keywords": [
6
6
  "react-native",
@@ -51,10 +51,10 @@
51
51
  "devDependencies": {
52
52
  "@types/glob": "^8.1.0",
53
53
  "@types/xml2js": "^0.4.11",
54
- "expo": "~52.0.36",
55
- "expo-module-scripts": "^4.0.0",
56
- "react": "18.3.1",
57
- "react-native": "0.76.7",
54
+ "expo": "^53.0.0",
55
+ "expo-module-scripts": "^4.1.5",
56
+ "react": "19.0.0",
57
+ "react-native": "0.79.5",
58
58
  "react-native-builder-bob": "0.23.1"
59
59
  },
60
60
  "dependencies": {
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.addListActivity = void 0;
3
+ exports.addListActivity = addListActivity;
4
4
  const config_plugins_1 = require("expo/config-plugins");
5
5
  const android_1 = require("../../../plugin-utils/build/android");
6
6
  /**
@@ -14,4 +14,3 @@ function addListActivity(config) {
14
14
  return exportedConfig;
15
15
  });
16
16
  }
17
- exports.addListActivity = addListActivity;
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.applyAndConfigureAboutLibrariesPlugin = void 0;
3
+ exports.applyAndConfigureAboutLibrariesPlugin = applyAndConfigureAboutLibrariesPlugin;
4
4
  const config_plugins_1 = require("expo/config-plugins");
5
5
  const android_1 = require("../../../plugin-utils/build/android");
6
6
  /**
@@ -19,4 +19,3 @@ function applyAndConfigureAboutLibrariesPlugin(config) {
19
19
  return exportedConfig;
20
20
  });
21
21
  }
22
- exports.applyAndConfigureAboutLibrariesPlugin = applyAndConfigureAboutLibrariesPlugin;
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.declareAboutLibrariesPlugin = void 0;
3
+ exports.declareAboutLibrariesPlugin = declareAboutLibrariesPlugin;
4
4
  const config_plugins_1 = require("expo/config-plugins");
5
5
  const android_1 = require("../../../plugin-utils/build/android");
6
6
  /**
@@ -19,4 +19,3 @@ function declareAboutLibrariesPlugin(config) {
19
19
  return exportedConfig;
20
20
  });
21
21
  }
22
- exports.declareAboutLibrariesPlugin = declareAboutLibrariesPlugin;
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.addSettingsBundle = void 0;
3
+ exports.addSettingsBundle = addSettingsBundle;
4
4
  const config_plugins_1 = require("expo/config-plugins");
5
5
  const ios_1 = require("../../../plugin-utils/build/ios");
6
6
  /**
@@ -25,4 +25,3 @@ function addSettingsBundle(config) {
25
25
  return exportedConfig;
26
26
  });
27
27
  }
28
- exports.addSettingsBundle = addSettingsBundle;
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.registerLicensePlistBuildPhase = void 0;
3
+ exports.registerLicensePlistBuildPhase = registerLicensePlistBuildPhase;
4
4
  const config_plugins_1 = require("expo/config-plugins");
5
5
  const ios_1 = require("../../../plugin-utils/build/ios");
6
6
  /**
@@ -20,4 +20,3 @@ function registerLicensePlistBuildPhase(config) {
20
20
  return exportedConfig;
21
21
  });
22
22
  }
23
- exports.registerLicensePlistBuildPhase = registerLicensePlistBuildPhase;
@@ -1,6 +1,8 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.addListActivityUtil = exports.applyAndConfigureAboutLibrariesPluginUtil = exports.declareAboutLibrariesPluginUtil = void 0;
3
+ exports.declareAboutLibrariesPluginUtil = declareAboutLibrariesPluginUtil;
4
+ exports.applyAndConfigureAboutLibrariesPluginUtil = applyAndConfigureAboutLibrariesPluginUtil;
5
+ exports.addListActivityUtil = addListActivityUtil;
4
6
  const licenses_1 = require("@callstack/licenses");
5
7
  /**
6
8
  * Applies Gradle Plugin Portal & AboutLibraries Gradle plugin repositories (if needed) inside root build.gradle
@@ -24,7 +26,6 @@ function declareAboutLibrariesPluginUtil(androidBuildGradleContent) {
24
26
  }
25
27
  return androidBuildGradleContent;
26
28
  }
27
- exports.declareAboutLibrariesPluginUtil = declareAboutLibrariesPluginUtil;
28
29
  /**
29
30
  * Applies and configures AboutLibraries Grale plugin (if needed) inside app's build.gradle
30
31
  */
@@ -49,7 +50,6 @@ function applyAndConfigureAboutLibrariesPluginUtil(androidAppBuildGradleContent)
49
50
  }
50
51
  return androidAppBuildGradleContent;
51
52
  }
52
- exports.applyAndConfigureAboutLibrariesPluginUtil = applyAndConfigureAboutLibrariesPluginUtil;
53
53
  /**
54
54
  * adds a list activity to the list of application's activities
55
55
  */
@@ -64,7 +64,6 @@ function addListActivityUtil(activities) {
64
64
  }
65
65
  return activities;
66
66
  }
67
- exports.addListActivityUtil = addListActivityUtil;
68
67
  /**
69
68
  * This JS object will evaluate to the following XML content:
70
69
  *
@@ -3,7 +3,8 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
3
3
  return (mod && mod.__esModule) ? mod : { "default": mod };
4
4
  };
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
- exports.registerLicensePlistBuildPhaseUtil = exports.addSettingsBundleUtil = void 0;
6
+ exports.addSettingsBundleUtil = addSettingsBundleUtil;
7
+ exports.registerLicensePlistBuildPhaseUtil = registerLicensePlistBuildPhaseUtil;
7
8
  const node_fs_1 = __importDefault(require("node:fs"));
8
9
  const node_path_1 = __importDefault(require("node:path"));
9
10
  /**
@@ -29,7 +30,6 @@ function addSettingsBundleUtil(iosProjectPath, addResourceFileToGroup) {
29
30
  console.log('Settings.bundle/Root.plist already present - SKIP');
30
31
  }
31
32
  }
32
- exports.addSettingsBundleUtil = addSettingsBundleUtil;
33
33
  /**
34
34
  * Creates a shell script build phase (if needed) and links it to native targets build phases
35
35
  */
@@ -63,7 +63,6 @@ function registerLicensePlistBuildPhaseUtil(projectTargetId, pbxproj) {
63
63
  console.log(`LicensePlist buildPhase in nativeTarget "${nativeTarget.name}" - ADDED`);
64
64
  return pbxproj;
65
65
  }
66
- exports.registerLicensePlistBuildPhaseUtil = registerLicensePlistBuildPhaseUtil;
67
66
  const GENERATE_LICENSE_PLIST_BUILD_PHASE_COMMENT = 'Generate licenses with LicensePlist';
68
67
  const SETTINGS_BUNDLE_ROOT_PLIST_CONTENT = `<?xml version="1.0" encoding="UTF-8"?>
69
68
  <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">