@applicaster/zapplicaster-cli 13.0.0-alpha.3637360334 → 13.0.0-alpha.3732093334
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/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@applicaster/zapplicaster-cli",
|
|
3
|
-
"version": "13.0.0-alpha.
|
|
3
|
+
"version": "13.0.0-alpha.3732093334",
|
|
4
4
|
"description": "CLI Tool for the zapp app and Quick Brick project",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"publishConfig": {
|
|
@@ -28,10 +28,10 @@
|
|
|
28
28
|
},
|
|
29
29
|
"homepage": "https://github.com/applicaster/quickbrick#readme",
|
|
30
30
|
"dependencies": {
|
|
31
|
-
"@applicaster/zapp-react-dom-cli-template": "13.0.0-alpha.
|
|
32
|
-
"@applicaster/zapp-react-native-android-tv-cli-template": "13.0.0-alpha.
|
|
33
|
-
"@applicaster/zapp-react-native-cli-template": "13.0.0-alpha.
|
|
34
|
-
"@applicaster/zapp-react-native-tvos-cli-template": "13.0.0-alpha.
|
|
31
|
+
"@applicaster/zapp-react-dom-cli-template": "13.0.0-alpha.3732093334",
|
|
32
|
+
"@applicaster/zapp-react-native-android-tv-cli-template": "13.0.0-alpha.3732093334",
|
|
33
|
+
"@applicaster/zapp-react-native-cli-template": "13.0.0-alpha.3732093334",
|
|
34
|
+
"@applicaster/zapp-react-native-tvos-cli-template": "13.0.0-alpha.3732093334",
|
|
35
35
|
"axios": "^0.28.0",
|
|
36
36
|
"camelize": "^1.0.0",
|
|
37
37
|
"chalk": "^2.3.2",
|
|
@@ -48,7 +48,6 @@
|
|
|
48
48
|
"@applicaster/applicaster-types": "*",
|
|
49
49
|
"@applicaster/blur": "*",
|
|
50
50
|
"@applicaster/quick-brick-xray": "*",
|
|
51
|
-
"@applicaster/react-native-color-thief": "*",
|
|
52
51
|
"@applicaster/zapp-react-dom-ui-components": "*",
|
|
53
52
|
"@applicaster/zapp-react-native-redux": "*",
|
|
54
53
|
"@applicaster/zapp-react-native-tvos-app": "*",
|
|
@@ -103,7 +103,12 @@ const destinationPath = "path/to/workspace";
|
|
|
103
103
|
const platform = "ios";
|
|
104
104
|
const yarn = false;
|
|
105
105
|
const zappReactNative = false;
|
|
106
|
-
|
|
106
|
+
|
|
107
|
+
const buildParams = {
|
|
108
|
+
languages: ["en", "en-US", "es", "es-LA"],
|
|
109
|
+
appVersionId: "A1234",
|
|
110
|
+
quick_brick_version: "6.1.6",
|
|
111
|
+
};
|
|
107
112
|
|
|
108
113
|
const template = {
|
|
109
114
|
files: {
|
|
@@ -43,6 +43,38 @@ async function patchPackages() {
|
|
|
43
43
|
}
|
|
44
44
|
}
|
|
45
45
|
|
|
46
|
+
/**
|
|
47
|
+
* fallback to en for missing dayjslocalization
|
|
48
|
+
* converts the locale code to a dayjs compatible locale code
|
|
49
|
+
* lowercase input code is expected, e.g. "en-GB" => "en-gb"
|
|
50
|
+
* @param {string} code - locale code, e.g. "en", "fr", "es-LA"
|
|
51
|
+
* from @applicaster/zapp-react-native-utils/appUtils/localizationsHelper
|
|
52
|
+
* */
|
|
53
|
+
const toDayJSLocaleMap = (code) => {
|
|
54
|
+
const map = {
|
|
55
|
+
hy: "hy-am",
|
|
56
|
+
fj: null,
|
|
57
|
+
la: null,
|
|
58
|
+
no: null,
|
|
59
|
+
pa: "pa-in",
|
|
60
|
+
qu: null,
|
|
61
|
+
sm: null,
|
|
62
|
+
to: null,
|
|
63
|
+
xh: null,
|
|
64
|
+
tt: null,
|
|
65
|
+
"es-LA": "es",
|
|
66
|
+
"en-UK": "en-gb",
|
|
67
|
+
};
|
|
68
|
+
|
|
69
|
+
if (map[code] === null) {
|
|
70
|
+
return "en";
|
|
71
|
+
} else if (map[code]) {
|
|
72
|
+
return map[code];
|
|
73
|
+
} else {
|
|
74
|
+
return code.toLowerCase();
|
|
75
|
+
}
|
|
76
|
+
};
|
|
77
|
+
|
|
46
78
|
/**
|
|
47
79
|
* {@typedef configuration
|
|
48
80
|
* @type {Object}
|
|
@@ -135,6 +167,10 @@ async function appBootstrapper(configuration) {
|
|
|
135
167
|
|
|
136
168
|
configuration.sdkAssets = sdkAssets;
|
|
137
169
|
|
|
170
|
+
configuration.buildParams.dayJsLocales = configuration.buildParams.languages
|
|
171
|
+
.map(toDayJSLocaleMap)
|
|
172
|
+
.filter((v) => v !== "en");
|
|
173
|
+
|
|
138
174
|
configuration.excludedNodeModules = getExcludedNodeModules(plugins);
|
|
139
175
|
const { filesToRender } = template.files;
|
|
140
176
|
|