mindbox-expo-plugin 1.0.2-rc → 1.0.7-rc
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.
|
@@ -16,12 +16,18 @@ const addMindboxDependencies = (config, props = {}) => {
|
|
|
16
16
|
const providersToAdd = shouldRemoveFirebaseStarter
|
|
17
17
|
? props.androidPushProviders.filter(provider => provider !== "firebase")
|
|
18
18
|
: props.androidPushProviders;
|
|
19
|
-
|
|
19
|
+
const shouldAddWorkaround = props.workRuntimeWorkaround === true;
|
|
20
|
+
if (providersToAdd.length === 0 && !shouldAddWorkaround) {
|
|
20
21
|
return config;
|
|
21
22
|
}
|
|
22
23
|
return (0, config_plugins_1.withAppBuildGradle)(config, (buildGradle) => {
|
|
23
24
|
const contents = buildGradle.modResults.contents;
|
|
24
|
-
const
|
|
25
|
+
const extraDependencies = [];
|
|
26
|
+
if (props.workRuntimeWorkaround === true) {
|
|
27
|
+
extraDependencies.push(` ${androidConstants_1.ANDROID_CONSTANTS.IMPLEMENTATION} 'androidx.work:work-runtime-ktx:${androidConstants_1.ANDROID_CONSTANTS.WORK_RUNTIME_KTX_VERSION}'`);
|
|
28
|
+
}
|
|
29
|
+
const mindboxDependencies = providersToAdd.map(provider => ` ${androidConstants_1.ANDROID_CONSTANTS.IMPLEMENTATION} '${libraryMap[provider]}'`);
|
|
30
|
+
const dependencies = [...extraDependencies, ...mindboxDependencies].join('\n');
|
|
25
31
|
buildGradle.modResults.contents = buildGradle.modResults.contents.replace(/(\s*)dependencies\s*\{/, `$1dependencies {\n${dependencies}`);
|
|
26
32
|
return buildGradle;
|
|
27
33
|
});
|
|
@@ -14,6 +14,7 @@ export declare const ANDROID_CONSTANTS: {
|
|
|
14
14
|
readonly RUSTORE_MAVEN_URL: "https://artifactory-external.vkpartner.ru/artifactory/maven";
|
|
15
15
|
readonly RUSTORE_MAVEN_REPO: " maven { url = uri(\"https://artifactory-external.vkpartner.ru/artifactory/maven\") }";
|
|
16
16
|
readonly RUSTORE_PROJECT_ID_META_DATA_NAME: "ru.rustore.sdk.pushclient.project_id";
|
|
17
|
+
readonly WORK_RUNTIME_KTX_VERSION: "2.8.1";
|
|
17
18
|
};
|
|
18
19
|
export declare const REGEX_CAPTURE_GROUPS: {
|
|
19
20
|
readonly FIRST: 1;
|
|
@@ -5,6 +5,7 @@ const VERSIONS = {
|
|
|
5
5
|
GOOGLE_SERVICES: "4.4.0",
|
|
6
6
|
HUAWEI_AGCP: "1.9.1.300",
|
|
7
7
|
HUAWEI_PUSH: "6.11.0.300",
|
|
8
|
+
WORK_RUNTIME_KTX: "2.8.1",
|
|
8
9
|
};
|
|
9
10
|
exports.ANDROID_CONSTANTS = {
|
|
10
11
|
IMPLEMENTATION: "implementation",
|
|
@@ -22,6 +23,7 @@ exports.ANDROID_CONSTANTS = {
|
|
|
22
23
|
RUSTORE_MAVEN_URL: "https://artifactory-external.vkpartner.ru/artifactory/maven",
|
|
23
24
|
RUSTORE_MAVEN_REPO: " maven { url = uri(\"https://artifactory-external.vkpartner.ru/artifactory/maven\") }",
|
|
24
25
|
RUSTORE_PROJECT_ID_META_DATA_NAME: "ru.rustore.sdk.pushclient.project_id",
|
|
26
|
+
WORK_RUNTIME_KTX_VERSION: VERSIONS.WORK_RUNTIME_KTX,
|
|
25
27
|
};
|
|
26
28
|
exports.REGEX_CAPTURE_GROUPS = {
|
|
27
29
|
FIRST: 1,
|
package/build/mindboxTypes.d.ts
CHANGED
|
@@ -19,6 +19,7 @@ const MINDBOX_PLUGIN_PROPS = [
|
|
|
19
19
|
"iosDeploymentTarget",
|
|
20
20
|
"iosDevTeam",
|
|
21
21
|
"usedExpoNotification",
|
|
22
|
+
"workRuntimeWorkaround",
|
|
22
23
|
];
|
|
23
24
|
const VALID_ANDROID_PROVIDERS = ["firebase", "huawei", "rustore"];
|
|
24
25
|
const VALID_IOS_MODES = ["development", "production"];
|
|
@@ -79,6 +80,7 @@ function validatePluginProps(props) {
|
|
|
79
80
|
validateStringProp(props.smallIconAccentColor, "smallIconAccentColor");
|
|
80
81
|
validateBooleanProp(props.nativeRequestPermission, "nativeRequestPermission");
|
|
81
82
|
validateBooleanProp(props.usedExpoNotification, "usedExpoNotification");
|
|
83
|
+
validateBooleanProp(props.workRuntimeWorkaround, "workRuntimeWorkaround");
|
|
82
84
|
validateStringProp(props.iosNseFilePath, "iosNseFilePath");
|
|
83
85
|
validateStringProp(props.iosNceFilePath, "iosNceFilePath");
|
|
84
86
|
validateStringProp(props.iosAppGroupId, "iosAppGroupId");
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "mindbox-expo-plugin",
|
|
3
|
-
"version": "1.0.
|
|
4
|
-
"target-version": "1.0.
|
|
3
|
+
"version": "1.0.7-rc",
|
|
4
|
+
"target-version": "1.0.7-rc",
|
|
5
5
|
"main": "app.plugin.js",
|
|
6
6
|
"react-native": "build/runtime/index.js",
|
|
7
7
|
"types": "build/index.d.ts",
|
|
@@ -64,7 +64,8 @@
|
|
|
64
64
|
"after:bump": "npx auto-changelog -p"
|
|
65
65
|
},
|
|
66
66
|
"npm": {
|
|
67
|
-
"publish": true
|
|
67
|
+
"publish": true,
|
|
68
|
+
"skipChecks": true
|
|
68
69
|
},
|
|
69
70
|
"github": {
|
|
70
71
|
"release": true
|