1 | "use strict";
|
2 | Object.defineProperty(exports, "__esModule", { value: true });
|
3 | exports.yellow = exports.clc = void 0;
|
4 | const isColorAllowed = () => !process.env.NO_COLOR;
|
5 | const colorIfAllowed = (colorFn) => (text) => isColorAllowed() ? colorFn(text) : text;
|
6 | exports.clc = {
|
7 | bold: colorIfAllowed((text) => `\x1B[1m${text}\x1B[0m`),
|
8 | green: colorIfAllowed((text) => `\x1B[32m${text}\x1B[39m`),
|
9 | yellow: colorIfAllowed((text) => `\x1B[33m${text}\x1B[39m`),
|
10 | red: colorIfAllowed((text) => `\x1B[31m${text}\x1B[39m`),
|
11 | magentaBright: colorIfAllowed((text) => `\x1B[95m${text}\x1B[39m`),
|
12 | cyanBright: colorIfAllowed((text) => `\x1B[96m${text}\x1B[39m`),
|
13 | };
|
14 | exports.yellow = colorIfAllowed((text) => `\x1B[38;5;3m${text}\x1B[39m`);
|