@lvnt/release-radar 1.7.9 → 1.7.10
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/cli/package.json +1 -1
- package/cli/src/ui.ts +10 -5
- package/package.json +1 -1
package/cli/package.json
CHANGED
package/cli/src/ui.ts
CHANGED
|
@@ -159,16 +159,21 @@ export function renderTable(rows: TableRow[]): void {
|
|
|
159
159
|
|
|
160
160
|
// Rows
|
|
161
161
|
for (const row of rows) {
|
|
162
|
-
|
|
162
|
+
// Pad plain text BEFORE applying colors (chalk adds invisible ANSI codes)
|
|
163
|
+
let statusText: string;
|
|
164
|
+
let statusColored: string;
|
|
163
165
|
switch (row.status) {
|
|
164
166
|
case 'new':
|
|
165
|
-
|
|
167
|
+
statusText = 'NEW'.padEnd(colWidths.status);
|
|
168
|
+
statusColored = chalk.blue(statusText);
|
|
166
169
|
break;
|
|
167
170
|
case 'update':
|
|
168
|
-
|
|
171
|
+
statusText = 'UPDATE'.padEnd(colWidths.status);
|
|
172
|
+
statusColored = chalk.yellow(statusText);
|
|
169
173
|
break;
|
|
170
174
|
case 'current':
|
|
171
|
-
|
|
175
|
+
statusText = '✓'.padEnd(colWidths.status);
|
|
176
|
+
statusColored = chalk.green(statusText);
|
|
172
177
|
break;
|
|
173
178
|
}
|
|
174
179
|
const typeStr = row.type === 'npm' ? chalk.magenta('npm') : chalk.cyan('wget');
|
|
@@ -178,7 +183,7 @@ export function renderTable(rows: TableRow[]): void {
|
|
|
178
183
|
row.displayName.padEnd(colWidths.tool) +
|
|
179
184
|
row.version.padEnd(colWidths.latest) +
|
|
180
185
|
row.downloadedVersion.padEnd(colWidths.downloaded) +
|
|
181
|
-
|
|
186
|
+
statusColored +
|
|
182
187
|
typeStr
|
|
183
188
|
);
|
|
184
189
|
}
|