antelope-cli 1.1.3 → 1.1.5
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/index.js +0 -0
- package/onboarding/index.js +2 -2
- package/onboarding/logo.js +2 -1
- package/onboarding/themes.js +1 -1
- package/onboarding/variablesColors.js +1 -2
- package/package.json +1 -1
package/index.js
CHANGED
|
File without changes
|
package/onboarding/index.js
CHANGED
|
@@ -15,8 +15,8 @@ const rl = readline.createInterface({
|
|
|
15
15
|
|
|
16
16
|
const finishOnboarding = () => {
|
|
17
17
|
console.log(chalk.green('\nOnboarding completed!'));
|
|
18
|
-
rl.question('Start the application? (
|
|
19
|
-
if (result.toLowerCase() === '
|
|
18
|
+
rl.question('Start the application? (y/n) ', (result) => {
|
|
19
|
+
if (result.toLowerCase() === 'y') {
|
|
20
20
|
rl.close();
|
|
21
21
|
const startProcess = exec('npm start');
|
|
22
22
|
|
package/onboarding/logo.js
CHANGED
|
@@ -7,7 +7,8 @@ function start(rl) {
|
|
|
7
7
|
return new Promise((resolve, reject) => {
|
|
8
8
|
rl.question('Please enter the URL to the logo image suitable for a black background:\n', (url) => {
|
|
9
9
|
console.log(chalk.cyan('Logo saved successfully!'));
|
|
10
|
-
brandModule.updateBrand({logo: url})
|
|
10
|
+
brandModule.updateBrand({logo: url});
|
|
11
|
+
resolve(null);
|
|
11
12
|
});
|
|
12
13
|
});
|
|
13
14
|
}
|
package/onboarding/themes.js
CHANGED
|
@@ -8,7 +8,7 @@ function addColorToMap(mapName, key, value, data) {
|
|
|
8
8
|
const match = data.match(mapRegex);
|
|
9
9
|
if (match) {
|
|
10
10
|
const mapContent = match[1];
|
|
11
|
-
const newMapContent = `$${mapName}: (${mapContent} '${key}': ${value}
|
|
11
|
+
const newMapContent = `$${mapName}: (${mapContent},\n '${key}': ${value})`;
|
|
12
12
|
data = data.replace(mapRegex, newMapContent);
|
|
13
13
|
} else {
|
|
14
14
|
throw new Error(`Error: Could not find ${mapName} map in the file`);
|
|
@@ -21,10 +21,9 @@ function start(rl) {
|
|
|
21
21
|
const colorsMap = match[1];
|
|
22
22
|
|
|
23
23
|
// Append the new brand to the colors map
|
|
24
|
-
|
|
24
|
+
const newColorsMap = `$colors: (${colorsMap},\n '${connectedBrandName}': ${
|
|
25
25
|
hexColor ? '$' + connectedBrandName : defaultColor
|
|
26
26
|
},\n)`;
|
|
27
|
-
console.log(chalk.yellowBright(colorsMap, newColorsMap));
|
|
28
27
|
|
|
29
28
|
// Replace the $colors map in the file with the new one
|
|
30
29
|
data = data.replace(colorsRegex, newColorsMap);
|