@mks2508/better-logger 3.1.0 → 5.0.0
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/CHANGELOG.json +45 -1
- package/dist/Logger.d.ts +129 -4
- package/dist/Logger.d.ts.map +1 -1
- package/dist/ScopedLogger.d.ts +17 -0
- package/dist/ScopedLogger.d.ts.map +1 -1
- package/dist/chunks/{Logger-C086w3EM.js → Logger-BZ7B7OXE.js} +258 -16
- package/dist/chunks/Logger-BZ7B7OXE.js.map +1 -0
- package/dist/chunks/Logger-Cbi1f10o.js +2 -0
- package/dist/chunks/Logger-Cbi1f10o.js.map +1 -0
- package/dist/chunks/cli-module-CadqgZ1Z.js +2 -0
- package/dist/chunks/cli-module-CadqgZ1Z.js.map +1 -0
- package/dist/chunks/cli-module-ClIJmaT8.js +383 -0
- package/dist/chunks/cli-module-ClIJmaT8.js.map +1 -0
- package/dist/chunks/color-converter-CCSQRztd.js +2 -0
- package/dist/chunks/color-converter-CCSQRztd.js.map +1 -0
- package/dist/chunks/color-converter-_Xdmsy7E.js +462 -0
- package/dist/chunks/color-converter-_Xdmsy7E.js.map +1 -0
- package/dist/chunks/{environment-DXHouGD4.js → environment-C1xxvc8l.js} +28 -478
- package/dist/chunks/environment-C1xxvc8l.js.map +1 -0
- package/dist/chunks/environment-Cprkw3g9.js +4 -0
- package/dist/chunks/environment-Cprkw3g9.js.map +1 -0
- package/dist/chunks/{formatting-BNnVUPcw.js → formatting-DMJxYq9o.js} +18 -18
- package/dist/chunks/{formatting-BNnVUPcw.js.map → formatting-DMJxYq9o.js.map} +1 -1
- package/dist/chunks/{formatting-Cg5YhB9Y.js → formatting-DpKxCsXq.js} +2 -2
- package/dist/chunks/{formatting-Cg5YhB9Y.js.map → formatting-DpKxCsXq.js.map} +1 -1
- package/dist/cli-module.d.ts +15 -0
- package/dist/cli-module.d.ts.map +1 -0
- package/dist/cli-primitives/box.d.ts +11 -0
- package/dist/cli-primitives/box.d.ts.map +1 -0
- package/dist/cli-primitives/cli-table.d.ts +11 -0
- package/dist/cli-primitives/cli-table.d.ts.map +1 -0
- package/dist/cli-primitives/divider.d.ts +11 -0
- package/dist/cli-primitives/divider.d.ts.map +1 -0
- package/dist/cli-primitives/header.d.ts +12 -0
- package/dist/cli-primitives/header.d.ts.map +1 -0
- package/dist/cli-primitives/index.d.ts +13 -0
- package/dist/cli-primitives/index.d.ts.map +1 -0
- package/dist/cli-primitives/server-fallback.d.ts +25 -0
- package/dist/cli-primitives/server-fallback.d.ts.map +1 -0
- package/dist/cli-primitives/spinner.d.ts +47 -0
- package/dist/cli-primitives/spinner.d.ts.map +1 -0
- package/dist/cli-primitives/step.d.ts +11 -0
- package/dist/cli-primitives/step.d.ts.map +1 -0
- package/dist/cli.cjs +2 -0
- package/dist/cli.cjs.map +1 -0
- package/dist/cli.js +12 -0
- package/dist/cli.js.map +1 -0
- package/dist/constants.d.ts +9 -1
- package/dist/constants.d.ts.map +1 -1
- package/dist/core.cjs +1 -1
- package/dist/core.js +2 -2
- package/dist/exports-module.d.ts +1 -1
- package/dist/exports-module.d.ts.map +1 -1
- package/dist/exports.cjs +1 -1
- package/dist/exports.js +2 -2
- package/dist/index.cjs +1 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +13 -3
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +162 -195
- package/dist/index.js.map +1 -1
- package/dist/styling-module.d.ts +1 -1
- package/dist/styling-module.d.ts.map +1 -1
- package/dist/styling.cjs +1 -1
- package/dist/styling.js +3 -3
- package/dist/types/core.d.ts +91 -0
- package/dist/types/core.d.ts.map +1 -1
- package/dist/types/index.d.ts +1 -1
- package/dist/types/index.d.ts.map +1 -1
- package/dist/writers/BufferWriter.d.ts +96 -0
- package/dist/writers/BufferWriter.d.ts.map +1 -0
- package/dist/writers/index.d.ts +6 -0
- package/dist/writers/index.d.ts.map +1 -0
- package/package.json +28 -3
- package/packages/core/package.json +1 -1
- package/playground/demo-all.ts +95 -0
- package/playground/demo-box.ts +85 -0
- package/playground/demo-levels.ts +56 -0
- package/playground/demo-real-world.ts +98 -0
- package/playground/demo-spinner.ts +77 -0
- package/playground/demo-steps.ts +72 -0
- package/playground/demo-table.ts +83 -0
- package/src/Logger.ts +263 -16
- package/src/ScopedLogger.ts +43 -1
- package/src/cli-module.ts +21 -0
- package/src/cli-primitives/box.ts +86 -0
- package/src/cli-primitives/cli-table.ts +62 -0
- package/src/cli-primitives/divider.ts +17 -0
- package/src/cli-primitives/header.ts +18 -0
- package/src/cli-primitives/index.ts +13 -0
- package/src/cli-primitives/server-fallback.ts +54 -0
- package/src/cli-primitives/spinner.ts +133 -0
- package/src/cli-primitives/step.ts +22 -0
- package/src/constants.ts +14 -2
- package/src/index.ts +23 -2
- package/src/types/core.ts +99 -0
- package/src/types/index.ts +4 -0
- package/src/writers/BufferWriter.ts +157 -0
- package/src/writers/index.ts +6 -0
- package/vite.config.ts +33 -0
- package/dist/chunks/Logger-BV0v1AyC.js +0 -2
- package/dist/chunks/Logger-BV0v1AyC.js.map +0 -1
- package/dist/chunks/Logger-C086w3EM.js.map +0 -1
- package/dist/chunks/environment-C_8J-zQ_.js +0 -4
- package/dist/chunks/environment-C_8J-zQ_.js.map +0 -1
- package/dist/chunks/environment-DXHouGD4.js.map +0 -1
package/dist/index.js
CHANGED
|
@@ -1,10 +1,12 @@
|
|
|
1
|
-
import { L as Logger } from "./chunks/Logger-
|
|
2
|
-
import { A, B, C,
|
|
3
|
-
import {
|
|
4
|
-
import { B as B2, D, E, T as T2,
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
1
|
+
import { L as Logger } from "./chunks/Logger-BZ7B7OXE.js";
|
|
2
|
+
import { A, B, C, e, H, c, S, a, T, b } from "./chunks/Logger-BZ7B7OXE.js";
|
|
3
|
+
import { a as isNode, i as isBrowser, S as StylePresets, b as StyleBuilder } from "./chunks/environment-C1xxvc8l.js";
|
|
4
|
+
import { B as B2, D, E, T as T2, e as e2, f, g, p } from "./chunks/environment-C1xxvc8l.js";
|
|
5
|
+
import { A as A2, c as c2, f as f2, e as e3, d, b as b2, g as g2, k, i, n, m, l, a as a2, h, j, r, s } from "./chunks/color-converter-_Xdmsy7E.js";
|
|
6
|
+
import { s as safeSerialize } from "./chunks/formatting-DMJxYq9o.js";
|
|
7
|
+
import { B as B3, l as l2, m as m2, k as k2, n as n2, j as j2, o, e as e4, h as h2, i as i2, c as c3, d as d2, p as p2, q, r as r2 } from "./chunks/formatting-DMJxYq9o.js";
|
|
7
8
|
import { R } from "./chunks/RemoteLogHandler-CjWpWZGl.js";
|
|
9
|
+
import { j as j3, c as c4, a as a3, g as g3, b as b3, e as e5, d as d3, f as f3, h as h3, i as i3, p as p3, r as r3, s as s2 } from "./chunks/cli-module-ClIJmaT8.js";
|
|
8
10
|
class ConsoleTransport {
|
|
9
11
|
constructor(options) {
|
|
10
12
|
this.options = options;
|
|
@@ -337,156 +339,104 @@ function getStyleCache() {
|
|
|
337
339
|
}
|
|
338
340
|
return _styleCache;
|
|
339
341
|
}
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
const padding = width - visibleLen;
|
|
350
|
-
switch (align) {
|
|
351
|
-
case "right":
|
|
352
|
-
return " ".repeat(padding) + str;
|
|
353
|
-
case "center":
|
|
354
|
-
const leftPad = Math.floor(padding / 2);
|
|
355
|
-
const rightPad = padding - leftPad;
|
|
356
|
-
return " ".repeat(leftPad) + str + " ".repeat(rightPad);
|
|
357
|
-
case "left":
|
|
358
|
-
default:
|
|
359
|
-
return str + " ".repeat(padding);
|
|
342
|
+
class BufferWriter {
|
|
343
|
+
buffer = [];
|
|
344
|
+
maxSize;
|
|
345
|
+
/**
|
|
346
|
+
* Creates a new BufferWriter
|
|
347
|
+
* @param maxSize - Maximum number of entries to buffer (default: 1000)
|
|
348
|
+
*/
|
|
349
|
+
constructor(maxSize = 1e3) {
|
|
350
|
+
this.maxSize = maxSize;
|
|
360
351
|
}
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
return `${leftContent}${" ".repeat(gap)}${rightContent}`;
|
|
371
|
-
}
|
|
372
|
-
function formatColumns(columns, maxWidth, colorCapability = "full") {
|
|
373
|
-
const width = maxWidth ?? getTerminalWidth();
|
|
374
|
-
columns.length;
|
|
375
|
-
const columnsWithWidths = columns.map((col, idx) => {
|
|
376
|
-
if (col.width) return { ...col, calculatedWidth: col.width };
|
|
377
|
-
const remainingWidth = width - columns.filter((c3, i2) => i2 !== idx && c3.width).reduce((sum, c3) => sum + (c3.width ?? 0), 0);
|
|
378
|
-
const autoColumns = columns.filter((c3) => !c3.width).length;
|
|
379
|
-
const calculatedWidth = Math.floor(remainingWidth / autoColumns);
|
|
380
|
-
return { ...col, calculatedWidth };
|
|
381
|
-
});
|
|
382
|
-
return columnsWithWidths.map((col) => {
|
|
383
|
-
let content = col.content;
|
|
384
|
-
if (col.color && colorCapability !== "none") {
|
|
385
|
-
const colorCode = getANSIForeground(col.color, colorCapability);
|
|
386
|
-
content = `${colorCode}${content}${ANSI.reset}`;
|
|
352
|
+
/**
|
|
353
|
+
* Writes a log entry to the buffer
|
|
354
|
+
* @param message - Formatted log message
|
|
355
|
+
* @param level - Log level
|
|
356
|
+
* @param styles - CSS styles (for browser console)
|
|
357
|
+
*/
|
|
358
|
+
write(message, level, styles) {
|
|
359
|
+
if (this.buffer.length >= this.maxSize) {
|
|
360
|
+
this.buffer.shift();
|
|
387
361
|
}
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
keyColor = "#888888",
|
|
395
|
-
valueColor = "#00ffff"
|
|
396
|
-
} = options;
|
|
397
|
-
const entries = Object.entries(obj);
|
|
398
|
-
if (entries.length === 0) return "";
|
|
399
|
-
const keyColorCode = colorCapability !== "none" ? getANSIForeground(keyColor, colorCapability) : "";
|
|
400
|
-
const valueColorCode = colorCapability !== "none" ? getANSIForeground(valueColor, colorCapability) : "";
|
|
401
|
-
const reset = colorCapability !== "none" ? ANSI.reset : "";
|
|
402
|
-
return entries.map(([key, value]) => {
|
|
403
|
-
const valueStr = typeof value === "object" ? JSON.stringify(value) : String(value);
|
|
404
|
-
return `${keyColorCode}${key}:${reset} ${valueColorCode}${valueStr}${reset}`;
|
|
405
|
-
}).join(separator);
|
|
406
|
-
}
|
|
407
|
-
function isKeyValueObject(obj) {
|
|
408
|
-
if (typeof obj !== "object" || obj === null) return false;
|
|
409
|
-
if (Array.isArray(obj)) return false;
|
|
410
|
-
const proto = Object.getPrototypeOf(obj);
|
|
411
|
-
if (proto !== Object.prototype && proto !== null) return false;
|
|
412
|
-
const values = Object.values(obj);
|
|
413
|
-
return values.every(
|
|
414
|
-
(v2) => typeof v2 === "string" || typeof v2 === "number" || typeof v2 === "boolean" || v2 === null
|
|
415
|
-
);
|
|
416
|
-
}
|
|
417
|
-
function formatBadge(badge2, style = "brackets", colorCapability = "full", color) {
|
|
418
|
-
const colorCode = color && colorCapability !== "none" ? getANSIForeground(color, colorCapability) : "";
|
|
419
|
-
const reset = colorCapability !== "none" ? ANSI.reset : "";
|
|
420
|
-
const bgBlack = colorCapability !== "none" ? ANSI.bg.black : "";
|
|
421
|
-
const text = badge2.toUpperCase();
|
|
422
|
-
switch (style) {
|
|
423
|
-
case "rounded":
|
|
424
|
-
return `${bgBlack}${colorCode}⟨${text}⟩${reset}`;
|
|
425
|
-
case "plain":
|
|
426
|
-
return `${colorCode}${text}${reset}`;
|
|
427
|
-
case "unicode":
|
|
428
|
-
return `${bgBlack}${colorCode}╭${text}╮${reset}`;
|
|
429
|
-
case "pill":
|
|
430
|
-
return `${bgBlack}${colorCode}⦗${text}⦘${reset}`;
|
|
431
|
-
case "brackets":
|
|
432
|
-
default:
|
|
433
|
-
return `${bgBlack}${colorCode}[${text}]${reset}`;
|
|
362
|
+
this.buffer.push({
|
|
363
|
+
message,
|
|
364
|
+
level,
|
|
365
|
+
styles,
|
|
366
|
+
timestamp: Date.now()
|
|
367
|
+
});
|
|
434
368
|
}
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
|
|
440
|
-
|
|
441
|
-
return date.toISOString().split("T")[0] ?? "";
|
|
442
|
-
case "time":
|
|
443
|
-
return date.toTimeString().slice(0, 8);
|
|
444
|
-
case "timeMs":
|
|
445
|
-
return date.toTimeString().slice(0, 8) + "." + String(date.getMilliseconds()).padStart(3, "0");
|
|
446
|
-
case "relative":
|
|
447
|
-
return formatRelativeTime(date);
|
|
448
|
-
case "elapsed":
|
|
449
|
-
return formatElapsedTime(date);
|
|
450
|
-
case "custom":
|
|
451
|
-
default:
|
|
452
|
-
return date.toLocaleTimeString();
|
|
369
|
+
/**
|
|
370
|
+
* Returns all buffered entries
|
|
371
|
+
* @returns Copy of the buffer array
|
|
372
|
+
*/
|
|
373
|
+
getBuffer() {
|
|
374
|
+
return [...this.buffer];
|
|
453
375
|
}
|
|
454
|
-
|
|
455
|
-
|
|
456
|
-
|
|
457
|
-
|
|
458
|
-
|
|
459
|
-
|
|
460
|
-
|
|
461
|
-
if (diff < 1e3) {
|
|
462
|
-
return `+${diff}ms`;
|
|
463
|
-
} else if (diff < 6e4) {
|
|
464
|
-
return `+${(diff / 1e3).toFixed(1)}s`;
|
|
465
|
-
} else {
|
|
466
|
-
const mins = Math.floor(diff / 6e4);
|
|
467
|
-
const secs = Math.floor(diff % 6e4 / 1e3);
|
|
468
|
-
return `+${mins}m${secs}s`;
|
|
376
|
+
/**
|
|
377
|
+
* Returns buffered entries filtered by log level
|
|
378
|
+
* @param levels - Log levels to include
|
|
379
|
+
* @returns Filtered buffer entries
|
|
380
|
+
*/
|
|
381
|
+
getByLevel(...levels) {
|
|
382
|
+
return this.buffer.filter((entry) => levels.includes(entry.level));
|
|
469
383
|
}
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
|
|
473
|
-
|
|
474
|
-
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
|
|
481
|
-
|
|
482
|
-
|
|
483
|
-
|
|
484
|
-
|
|
485
|
-
|
|
486
|
-
|
|
487
|
-
|
|
384
|
+
/**
|
|
385
|
+
* Returns the number of buffered entries
|
|
386
|
+
*/
|
|
387
|
+
get size() {
|
|
388
|
+
return this.buffer.length;
|
|
389
|
+
}
|
|
390
|
+
/**
|
|
391
|
+
* Checks if buffer is empty
|
|
392
|
+
*/
|
|
393
|
+
get isEmpty() {
|
|
394
|
+
return this.buffer.length === 0;
|
|
395
|
+
}
|
|
396
|
+
/**
|
|
397
|
+
* Clears all buffered entries
|
|
398
|
+
*/
|
|
399
|
+
clear() {
|
|
400
|
+
this.buffer = [];
|
|
401
|
+
}
|
|
402
|
+
/**
|
|
403
|
+
* Outputs all buffered entries to console and clears the buffer
|
|
404
|
+
*/
|
|
405
|
+
flush() {
|
|
406
|
+
this.buffer.forEach((entry) => {
|
|
407
|
+
if (entry.styles.length > 0) {
|
|
408
|
+
console.log(entry.message, ...entry.styles);
|
|
409
|
+
} else {
|
|
410
|
+
console.log(entry.message);
|
|
411
|
+
}
|
|
412
|
+
});
|
|
413
|
+
this.clear();
|
|
414
|
+
}
|
|
415
|
+
/**
|
|
416
|
+
* Outputs buffered entries to console without clearing
|
|
417
|
+
*/
|
|
418
|
+
replay() {
|
|
419
|
+
this.buffer.forEach((entry) => {
|
|
420
|
+
if (entry.styles.length > 0) {
|
|
421
|
+
console.log(entry.message, ...entry.styles);
|
|
422
|
+
} else {
|
|
423
|
+
console.log(entry.message);
|
|
424
|
+
}
|
|
425
|
+
});
|
|
426
|
+
}
|
|
427
|
+
/**
|
|
428
|
+
* Returns all messages as an array of strings
|
|
429
|
+
*/
|
|
430
|
+
toArray() {
|
|
431
|
+
return this.buffer.map((entry) => entry.message);
|
|
432
|
+
}
|
|
433
|
+
/**
|
|
434
|
+
* Returns all messages joined as a single string
|
|
435
|
+
* @param separator - String to join messages with (default: newline)
|
|
436
|
+
*/
|
|
437
|
+
toString(separator = "\n") {
|
|
438
|
+
return this.toArray().join(separator);
|
|
488
439
|
}
|
|
489
|
-
return result;
|
|
490
440
|
}
|
|
491
441
|
let _logger = null;
|
|
492
442
|
function getLogger() {
|
|
@@ -523,6 +473,14 @@ const showBanner = (bannerType) => getLogger().showBanner(bannerType);
|
|
|
523
473
|
const logWithSVG = (message, svgContent, options) => getLogger().logWithSVG(message, svgContent, options);
|
|
524
474
|
const logAnimated = (message, duration) => getLogger().logAnimated(message, duration);
|
|
525
475
|
const cli = (command) => getLogger().cli(command);
|
|
476
|
+
const step = (current, total, message) => getLogger().step(current, total, message);
|
|
477
|
+
const spinner = (message) => getLogger().spinner(message);
|
|
478
|
+
const box = (content, options) => getLogger().box(content, options);
|
|
479
|
+
const cliTable = (rows, options) => getLogger().cliTable(rows, options);
|
|
480
|
+
const header = (title, subtitle) => getLogger().header(title, subtitle);
|
|
481
|
+
const divider = () => getLogger().divider();
|
|
482
|
+
const blank = () => getLogger().blank();
|
|
483
|
+
const setCLILevel = (level) => getLogger().setCLILevel(level);
|
|
526
484
|
const addSerializer = (type, serializer, priority) => getLogger().addSerializer(type, serializer, priority);
|
|
527
485
|
const removeSerializer = (type) => getLogger().removeSerializer(type);
|
|
528
486
|
const on = (event, callback, priority) => getLogger().on(event, callback, priority);
|
|
@@ -542,15 +500,16 @@ const stylePresets = {
|
|
|
542
500
|
accent: StylePresets.accent().build()
|
|
543
501
|
};
|
|
544
502
|
export {
|
|
545
|
-
ANSI,
|
|
503
|
+
A2 as ANSI,
|
|
546
504
|
A as APILogger,
|
|
547
505
|
AnalyticsLogHandler,
|
|
548
506
|
B as BANNER_VARIANTS,
|
|
549
507
|
B3 as BUILD_FORMATTERS,
|
|
550
508
|
B2 as BUILD_PRESETS,
|
|
509
|
+
BufferWriter,
|
|
551
510
|
C as ComponentLogger,
|
|
552
511
|
ConsoleTransport,
|
|
553
|
-
|
|
512
|
+
e as ContextLogger,
|
|
554
513
|
D as DEFAULT_CONFIG,
|
|
555
514
|
E as ENVIRONMENT_DETECTION,
|
|
556
515
|
FileLogHandler,
|
|
@@ -571,85 +530,93 @@ export {
|
|
|
571
530
|
addHandler,
|
|
572
531
|
addSerializer,
|
|
573
532
|
addTransport,
|
|
574
|
-
|
|
575
|
-
|
|
576
|
-
|
|
577
|
-
|
|
578
|
-
|
|
579
|
-
|
|
533
|
+
l2 as ansiBackground,
|
|
534
|
+
m2 as ansiBold,
|
|
535
|
+
k2 as ansiColor,
|
|
536
|
+
n2 as ansiDim,
|
|
537
|
+
j2 as ansiStyle,
|
|
538
|
+
o as ansiUnderline,
|
|
580
539
|
api,
|
|
581
|
-
applyLogOptions,
|
|
540
|
+
j3 as applyLogOptions,
|
|
582
541
|
badge,
|
|
583
542
|
badges,
|
|
543
|
+
blank,
|
|
544
|
+
box,
|
|
584
545
|
clearBadges,
|
|
585
546
|
cli,
|
|
547
|
+
cliTable,
|
|
586
548
|
closeTransports,
|
|
587
|
-
|
|
549
|
+
c2 as colorToHex,
|
|
588
550
|
component,
|
|
589
|
-
|
|
590
|
-
|
|
591
|
-
|
|
592
|
-
|
|
551
|
+
e4 as createANSIOutput,
|
|
552
|
+
h2 as createBuildOutput,
|
|
553
|
+
i2 as createCIOutput,
|
|
554
|
+
c3 as createOutput,
|
|
593
555
|
createStyle,
|
|
594
556
|
critical,
|
|
595
|
-
|
|
557
|
+
f2 as cssColorToANSI,
|
|
596
558
|
debug,
|
|
597
559
|
index as default,
|
|
598
|
-
|
|
599
|
-
|
|
560
|
+
e2 as detectEnvironmentPreset,
|
|
561
|
+
d2 as detectOptimalFormat,
|
|
562
|
+
divider,
|
|
600
563
|
error,
|
|
601
564
|
flushTransports,
|
|
602
|
-
formatBadge,
|
|
603
|
-
formatColumns,
|
|
604
|
-
formatElapsedTime,
|
|
605
|
-
formatKeyValue,
|
|
606
|
-
|
|
607
|
-
formatRelativeTime,
|
|
608
|
-
|
|
565
|
+
c4 as formatBadge,
|
|
566
|
+
a3 as formatColumns,
|
|
567
|
+
g3 as formatElapsedTime,
|
|
568
|
+
b3 as formatKeyValue,
|
|
569
|
+
p2 as formatLogLevelANSI,
|
|
570
|
+
e5 as formatRelativeTime,
|
|
571
|
+
q as formatSuccessANSI,
|
|
609
572
|
f as formatTimestamp,
|
|
610
|
-
|
|
611
|
-
formatWithRightAlign,
|
|
612
|
-
|
|
613
|
-
|
|
614
|
-
|
|
615
|
-
getANSIForeground,
|
|
616
|
-
|
|
617
|
-
|
|
618
|
-
|
|
619
|
-
|
|
573
|
+
d3 as formatTimestampExt,
|
|
574
|
+
f3 as formatWithRightAlign,
|
|
575
|
+
e3 as getANSI256Background,
|
|
576
|
+
d as getANSI256Foreground,
|
|
577
|
+
b2 as getANSIBackground,
|
|
578
|
+
g2 as getANSIForeground,
|
|
579
|
+
k as getColorCapability,
|
|
580
|
+
i as getEnvironment,
|
|
581
|
+
n as getEnvironmentInfo,
|
|
582
|
+
g as getOptimalConfig,
|
|
620
583
|
getStyleCache,
|
|
621
|
-
|
|
622
|
-
getTerminalWidth,
|
|
623
|
-
getVisibleLength,
|
|
584
|
+
m as getTerminalHeight,
|
|
585
|
+
l as getTerminalWidth,
|
|
586
|
+
h3 as getVisibleLength,
|
|
624
587
|
group,
|
|
625
588
|
groupEnd,
|
|
626
|
-
|
|
589
|
+
header,
|
|
590
|
+
a2 as hexTo256,
|
|
627
591
|
h as hexToRgb,
|
|
628
592
|
info,
|
|
629
|
-
isKeyValueObject,
|
|
630
|
-
|
|
593
|
+
i3 as isKeyValueObject,
|
|
594
|
+
j as isRunningInTerminal,
|
|
631
595
|
logAnimated,
|
|
632
596
|
logWithSVG,
|
|
633
597
|
off,
|
|
634
598
|
on,
|
|
635
599
|
once,
|
|
636
|
-
padToWidth,
|
|
600
|
+
p3 as padToWidth,
|
|
637
601
|
p as parseStackTrace,
|
|
638
602
|
removeSerializer,
|
|
639
603
|
removeTransport,
|
|
640
|
-
resetStartTime,
|
|
604
|
+
r3 as resetStartTime,
|
|
641
605
|
r as rgbToHex,
|
|
642
|
-
|
|
606
|
+
r2 as sanitizeEmojis,
|
|
643
607
|
scope,
|
|
644
608
|
setBannerType,
|
|
609
|
+
setCLILevel,
|
|
645
610
|
setGlobalPrefix,
|
|
646
611
|
setTheme,
|
|
647
612
|
setVerbosity,
|
|
648
613
|
showBanner,
|
|
649
|
-
|
|
614
|
+
spinner,
|
|
615
|
+
step,
|
|
616
|
+
s2 as stripAnsi,
|
|
650
617
|
stylePresets,
|
|
651
618
|
success,
|
|
652
|
-
|
|
619
|
+
s as supportsANSI,
|
|
653
620
|
table,
|
|
654
621
|
time,
|
|
655
622
|
timeEnd,
|