@atlaspack/reporter-cli 2.12.1-dev.3466 → 2.12.1-dev.3502
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/lib/CLIReporter.js +33 -33
- package/lib/CLIReporter.js.map +1 -1
- package/package.json +7 -7
package/lib/CLIReporter.js
CHANGED
|
@@ -7458,30 +7458,30 @@ function $8f1b496691f71eed$export$2e2bcd8739ae039(phaseStartTimes) {
|
|
|
7458
7458
|
|
|
7459
7459
|
|
|
7460
7460
|
|
|
7461
|
-
var $
|
|
7461
|
+
var $1eb4d0626e548f55$exports = {};
|
|
7462
7462
|
'use strict';
|
|
7463
7463
|
|
|
7464
7464
|
|
|
7465
7465
|
|
|
7466
7466
|
var $aFgAi = parcelRequire("aFgAi");
|
|
7467
|
-
const $
|
|
7467
|
+
const $1eb4d0626e548f55$var$ESCAPES = new Set([
|
|
7468
7468
|
'\u001B',
|
|
7469
7469
|
'\u009B'
|
|
7470
7470
|
]);
|
|
7471
|
-
const $
|
|
7472
|
-
const $
|
|
7473
|
-
const $
|
|
7474
|
-
const $
|
|
7475
|
-
const $
|
|
7476
|
-
const $
|
|
7477
|
-
const $
|
|
7478
|
-
const $
|
|
7471
|
+
const $1eb4d0626e548f55$var$END_CODE = 39;
|
|
7472
|
+
const $1eb4d0626e548f55$var$ANSI_ESCAPE_BELL = '\u0007';
|
|
7473
|
+
const $1eb4d0626e548f55$var$ANSI_CSI = '[';
|
|
7474
|
+
const $1eb4d0626e548f55$var$ANSI_OSC = ']';
|
|
7475
|
+
const $1eb4d0626e548f55$var$ANSI_SGR_TERMINATOR = 'm';
|
|
7476
|
+
const $1eb4d0626e548f55$var$ANSI_ESCAPE_LINK = `${$1eb4d0626e548f55$var$ANSI_OSC}8;;`;
|
|
7477
|
+
const $1eb4d0626e548f55$var$wrapAnsi = (code)=>`${$1eb4d0626e548f55$var$ESCAPES.values().next().value}${$1eb4d0626e548f55$var$ANSI_CSI}${code}${$1eb4d0626e548f55$var$ANSI_SGR_TERMINATOR}`;
|
|
7478
|
+
const $1eb4d0626e548f55$var$wrapAnsiHyperlink = (uri)=>`${$1eb4d0626e548f55$var$ESCAPES.values().next().value}${$1eb4d0626e548f55$var$ANSI_ESCAPE_LINK}${uri}${$1eb4d0626e548f55$var$ANSI_ESCAPE_BELL}`;
|
|
7479
7479
|
// Calculate the length of words split on ' ', ignoring
|
|
7480
7480
|
// the extra characters added by ansi escape codes
|
|
7481
|
-
const $
|
|
7481
|
+
const $1eb4d0626e548f55$var$wordLengths = (string)=>string.split(' ').map((character)=>$00cf147e183718fd$exports(character));
|
|
7482
7482
|
// Wrap a long word across multiple rows
|
|
7483
7483
|
// Ansi escape codes do not count towards length
|
|
7484
|
-
const $
|
|
7484
|
+
const $1eb4d0626e548f55$var$wrapWord = (rows, word, columns)=>{
|
|
7485
7485
|
const characters = [
|
|
7486
7486
|
...word
|
|
7487
7487
|
];
|
|
@@ -7495,17 +7495,17 @@ const $9f25a33f1c171c9d$var$wrapWord = (rows, word, columns)=>{
|
|
|
7495
7495
|
rows.push(character);
|
|
7496
7496
|
visible = 0;
|
|
7497
7497
|
}
|
|
7498
|
-
if ($
|
|
7498
|
+
if ($1eb4d0626e548f55$var$ESCAPES.has(character)) {
|
|
7499
7499
|
isInsideEscape = true;
|
|
7500
|
-
isInsideLinkEscape = characters.slice(index + 1).join('').startsWith($
|
|
7500
|
+
isInsideLinkEscape = characters.slice(index + 1).join('').startsWith($1eb4d0626e548f55$var$ANSI_ESCAPE_LINK);
|
|
7501
7501
|
}
|
|
7502
7502
|
if (isInsideEscape) {
|
|
7503
7503
|
if (isInsideLinkEscape) {
|
|
7504
|
-
if (character === $
|
|
7504
|
+
if (character === $1eb4d0626e548f55$var$ANSI_ESCAPE_BELL) {
|
|
7505
7505
|
isInsideEscape = false;
|
|
7506
7506
|
isInsideLinkEscape = false;
|
|
7507
7507
|
}
|
|
7508
|
-
} else if (character === $
|
|
7508
|
+
} else if (character === $1eb4d0626e548f55$var$ANSI_SGR_TERMINATOR) isInsideEscape = false;
|
|
7509
7509
|
continue;
|
|
7510
7510
|
}
|
|
7511
7511
|
visible += characterLength;
|
|
@@ -7519,7 +7519,7 @@ const $9f25a33f1c171c9d$var$wrapWord = (rows, word, columns)=>{
|
|
|
7519
7519
|
if (!visible && rows[rows.length - 1].length > 0 && rows.length > 1) rows[rows.length - 2] += rows.pop();
|
|
7520
7520
|
};
|
|
7521
7521
|
// Trims spaces from a string ignoring invisible sequences
|
|
7522
|
-
const $
|
|
7522
|
+
const $1eb4d0626e548f55$var$stringVisibleTrimSpacesRight = (string)=>{
|
|
7523
7523
|
const words = string.split(' ');
|
|
7524
7524
|
let last = words.length;
|
|
7525
7525
|
while(last > 0){
|
|
@@ -7534,12 +7534,12 @@ const $9f25a33f1c171c9d$var$stringVisibleTrimSpacesRight = (string)=>{
|
|
|
7534
7534
|
// 'hard' will never allow a string to take up more than columns characters
|
|
7535
7535
|
//
|
|
7536
7536
|
// 'soft' allows long words to expand past the column length
|
|
7537
|
-
const $
|
|
7537
|
+
const $1eb4d0626e548f55$var$exec = (string, columns, options = {})=>{
|
|
7538
7538
|
if (options.trim !== false && string.trim() === '') return '';
|
|
7539
7539
|
let returnValue = '';
|
|
7540
7540
|
let escapeCode;
|
|
7541
7541
|
let escapeUrl;
|
|
7542
|
-
const lengths = $
|
|
7542
|
+
const lengths = $1eb4d0626e548f55$var$wordLengths(string);
|
|
7543
7543
|
let rows = [
|
|
7544
7544
|
''
|
|
7545
7545
|
];
|
|
@@ -7563,51 +7563,51 @@ const $9f25a33f1c171c9d$var$exec = (string, columns, options = {})=>{
|
|
|
7563
7563
|
const breaksStartingThisLine = 1 + Math.floor((lengths[index] - remainingColumns - 1) / columns);
|
|
7564
7564
|
const breaksStartingNextLine = Math.floor((lengths[index] - 1) / columns);
|
|
7565
7565
|
if (breaksStartingNextLine < breaksStartingThisLine) rows.push('');
|
|
7566
|
-
$
|
|
7566
|
+
$1eb4d0626e548f55$var$wrapWord(rows, word, columns);
|
|
7567
7567
|
continue;
|
|
7568
7568
|
}
|
|
7569
7569
|
if (rowLength + lengths[index] > columns && rowLength > 0 && lengths[index] > 0) {
|
|
7570
7570
|
if (options.wordWrap === false && rowLength < columns) {
|
|
7571
|
-
$
|
|
7571
|
+
$1eb4d0626e548f55$var$wrapWord(rows, word, columns);
|
|
7572
7572
|
continue;
|
|
7573
7573
|
}
|
|
7574
7574
|
rows.push('');
|
|
7575
7575
|
}
|
|
7576
7576
|
if (rowLength + lengths[index] > columns && options.wordWrap === false) {
|
|
7577
|
-
$
|
|
7577
|
+
$1eb4d0626e548f55$var$wrapWord(rows, word, columns);
|
|
7578
7578
|
continue;
|
|
7579
7579
|
}
|
|
7580
7580
|
rows[rows.length - 1] += word;
|
|
7581
7581
|
}
|
|
7582
|
-
if (options.trim !== false) rows = rows.map($
|
|
7582
|
+
if (options.trim !== false) rows = rows.map($1eb4d0626e548f55$var$stringVisibleTrimSpacesRight);
|
|
7583
7583
|
const pre = [
|
|
7584
7584
|
...rows.join('\n')
|
|
7585
7585
|
];
|
|
7586
7586
|
for (const [index, character] of pre.entries()){
|
|
7587
7587
|
returnValue += character;
|
|
7588
|
-
if ($
|
|
7589
|
-
const { groups: groups } = new RegExp(`(?:\\${$
|
|
7588
|
+
if ($1eb4d0626e548f55$var$ESCAPES.has(character)) {
|
|
7589
|
+
const { groups: groups } = new RegExp(`(?:\\${$1eb4d0626e548f55$var$ANSI_CSI}(?<code>\\d+)m|\\${$1eb4d0626e548f55$var$ANSI_ESCAPE_LINK}(?<uri>.*)${$1eb4d0626e548f55$var$ANSI_ESCAPE_BELL})`).exec(pre.slice(index).join('')) || {
|
|
7590
7590
|
groups: {}
|
|
7591
7591
|
};
|
|
7592
7592
|
if (groups.code !== undefined) {
|
|
7593
7593
|
const code = Number.parseFloat(groups.code);
|
|
7594
|
-
escapeCode = code === $
|
|
7594
|
+
escapeCode = code === $1eb4d0626e548f55$var$END_CODE ? undefined : code;
|
|
7595
7595
|
} else if (groups.uri !== undefined) escapeUrl = groups.uri.length === 0 ? undefined : groups.uri;
|
|
7596
7596
|
}
|
|
7597
7597
|
const code = $aFgAi.codes.get(Number(escapeCode));
|
|
7598
7598
|
if (pre[index + 1] === '\n') {
|
|
7599
|
-
if (escapeUrl) returnValue += $
|
|
7600
|
-
if (escapeCode && code) returnValue += $
|
|
7599
|
+
if (escapeUrl) returnValue += $1eb4d0626e548f55$var$wrapAnsiHyperlink('');
|
|
7600
|
+
if (escapeCode && code) returnValue += $1eb4d0626e548f55$var$wrapAnsi(code);
|
|
7601
7601
|
} else if (character === '\n') {
|
|
7602
|
-
if (escapeCode && code) returnValue += $
|
|
7603
|
-
if (escapeUrl) returnValue += $
|
|
7602
|
+
if (escapeCode && code) returnValue += $1eb4d0626e548f55$var$wrapAnsi(escapeCode);
|
|
7603
|
+
if (escapeUrl) returnValue += $1eb4d0626e548f55$var$wrapAnsiHyperlink(escapeUrl);
|
|
7604
7604
|
}
|
|
7605
7605
|
}
|
|
7606
7606
|
return returnValue;
|
|
7607
7607
|
};
|
|
7608
7608
|
// For each newline, invoke the method separately
|
|
7609
|
-
$
|
|
7610
|
-
return String(string).normalize().replace(/\r\n/g, '\n').split('\n').map((line)=>$
|
|
7609
|
+
$1eb4d0626e548f55$exports = (string, columns, options)=>{
|
|
7610
|
+
return String(string).normalize().replace(/\r\n/g, '\n').split('\n').map((line)=>$1eb4d0626e548f55$var$exec(line, columns, options)).join('\n');
|
|
7611
7611
|
};
|
|
7612
7612
|
|
|
7613
7613
|
|
|
@@ -7733,7 +7733,7 @@ async function $8d599e7fbf3e1a1b$var$writeDiagnostic(options, diagnostics, color
|
|
|
7733
7733
|
}
|
|
7734
7734
|
function $8d599e7fbf3e1a1b$var$wrapWithIndent(string, indent = 0, initialIndent = indent) {
|
|
7735
7735
|
let width = (0, $fba06550c179171f$export$74827651f504bd9d)().columns;
|
|
7736
|
-
return $8d599e7fbf3e1a1b$var$indentString((0, (/*@__PURE__*/$parcel$interopDefault($
|
|
7736
|
+
return $8d599e7fbf3e1a1b$var$indentString((0, (/*@__PURE__*/$parcel$interopDefault($1eb4d0626e548f55$exports)))(string.trimEnd(), width - indent, {
|
|
7737
7737
|
trim: false
|
|
7738
7738
|
}), indent, initialIndent);
|
|
7739
7739
|
}
|