@oxog/pigment 1.1.0 → 1.2.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/README.md +91 -79
- package/dist/index-DsggPsSl.d.cts +1482 -0
- package/dist/index-DsggPsSl.d.ts +1482 -0
- package/dist/index.cjs +423 -269
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +33 -134
- package/dist/index.d.ts +33 -134
- package/dist/index.js +423 -269
- package/dist/index.js.map +1 -1
- package/dist/plugins/index.cjs +510 -244
- package/dist/plugins/index.cjs.map +1 -1
- package/dist/plugins/index.d.cts +1 -3
- package/dist/plugins/index.d.ts +1 -3
- package/dist/plugins/index.js +510 -244
- package/dist/plugins/index.js.map +1 -1
- package/package.json +21 -12
- package/dist/index-CLqJXFfX.d.cts +0 -441
- package/dist/index-CLqJXFfX.d.ts +0 -441
package/dist/index.d.cts
CHANGED
|
@@ -1,74 +1,5 @@
|
|
|
1
|
-
import { P as
|
|
2
|
-
export { B as BoxBorder,
|
|
3
|
-
export { createKernel } from '@oxog/plugin';
|
|
4
|
-
export { MaybePromise, Unsubscribe } from '@oxog/types';
|
|
5
|
-
|
|
6
|
-
/**
|
|
7
|
-
* Builder-pattern Pigment for explicit composition.
|
|
8
|
-
*
|
|
9
|
-
* @example
|
|
10
|
-
* ```typescript
|
|
11
|
-
* const builder = new BuilderPigment(kernel);
|
|
12
|
-
* const styled = builder.bold().red().paint('Error!');
|
|
13
|
-
* ```
|
|
14
|
-
*/
|
|
15
|
-
declare class BuilderPigment {
|
|
16
|
-
private styles;
|
|
17
|
-
constructor(_kernel: PigmentKernel);
|
|
18
|
-
bold(): this;
|
|
19
|
-
dim(): this;
|
|
20
|
-
italic(): this;
|
|
21
|
-
underline(): this;
|
|
22
|
-
strikethrough(): this;
|
|
23
|
-
inverse(): this;
|
|
24
|
-
hidden(): this;
|
|
25
|
-
reset(): this;
|
|
26
|
-
black(): this;
|
|
27
|
-
red(): this;
|
|
28
|
-
green(): this;
|
|
29
|
-
yellow(): this;
|
|
30
|
-
blue(): this;
|
|
31
|
-
magenta(): this;
|
|
32
|
-
cyan(): this;
|
|
33
|
-
white(): this;
|
|
34
|
-
blackBright(): this;
|
|
35
|
-
redBright(): this;
|
|
36
|
-
greenBright(): this;
|
|
37
|
-
yellowBright(): this;
|
|
38
|
-
blueBright(): this;
|
|
39
|
-
magentaBright(): this;
|
|
40
|
-
cyanBright(): this;
|
|
41
|
-
whiteBright(): this;
|
|
42
|
-
gray(): this;
|
|
43
|
-
grey(): this;
|
|
44
|
-
bgBlack(): this;
|
|
45
|
-
bgRed(): this;
|
|
46
|
-
bgGreen(): this;
|
|
47
|
-
bgYellow(): this;
|
|
48
|
-
bgBlue(): this;
|
|
49
|
-
bgMagenta(): this;
|
|
50
|
-
bgCyan(): this;
|
|
51
|
-
bgWhite(): this;
|
|
52
|
-
bgBlackBright(): this;
|
|
53
|
-
bgRedBright(): this;
|
|
54
|
-
bgGreenBright(): this;
|
|
55
|
-
bgYellowBright(): this;
|
|
56
|
-
bgBlueBright(): this;
|
|
57
|
-
bgMagentaBright(): this;
|
|
58
|
-
bgCyanBright(): this;
|
|
59
|
-
bgWhiteBright(): this;
|
|
60
|
-
bgGray(): this;
|
|
61
|
-
bgGrey(): this;
|
|
62
|
-
ansi256(code: number): this;
|
|
63
|
-
bgAnsi256(code: number): this;
|
|
64
|
-
rgb(r: number, g: number, b: number): this;
|
|
65
|
-
bgRgb(r: number, g: number, b: number): this;
|
|
66
|
-
hex(color: string): this;
|
|
67
|
-
bgHex(color: string): this;
|
|
68
|
-
hsl(h: number, s: number, l: number): this;
|
|
69
|
-
bgHsl(h: number, s: number, l: number): this;
|
|
70
|
-
paint(text: string): string;
|
|
71
|
-
}
|
|
1
|
+
import { P as PigmentOptions, a as PigmentInstance, b as Pigment, C as ColorSupport, S as Styler, c as Platform } from './index-DsggPsSl.cjs';
|
|
2
|
+
export { B as BoxBorder, d as BoxChars, e as BoxOptions, f as BoxPluginOptions, g as BuilderPigment, h as ColorInput, E as EventHandler, G as GradientPluginOptions, K as Kernel, i as KernelOptions, M as MaybePromise, j as PigmentContext, k as PigmentEvents, l as PigmentKernel, m as PigmentPluginApi, n as PigmentPluginOptions, o as Plugin, p as SemanticPluginOptions, q as Style, r as StyleFunction, T as ThemeColorType, s as ThemePluginOptions, t as ThemePreset, u as ThemePresetColors, U as Unsubscribe, v as createKernel, w as plugins } from './index-DsggPsSl.cjs';
|
|
72
3
|
|
|
73
4
|
/**
|
|
74
5
|
* Creates a new Pigment instance using @oxog/plugin micro-kernel.
|
|
@@ -88,7 +19,7 @@ declare class BuilderPigment {
|
|
|
88
19
|
* forceColor: true, // Force colors
|
|
89
20
|
* });
|
|
90
21
|
*
|
|
91
|
-
* // With optional plugins
|
|
22
|
+
* // With optional plugins: they add methods to the instance
|
|
92
23
|
* import { gradientPlugin, themePlugin } from '@oxog/pigment/plugins';
|
|
93
24
|
*
|
|
94
25
|
* const pigment = createPigment({
|
|
@@ -97,71 +28,43 @@ declare class BuilderPigment {
|
|
|
97
28
|
* themePlugin({ preset: 'monokai' })
|
|
98
29
|
* ]
|
|
99
30
|
* });
|
|
31
|
+
* pigment.gradient('#ff0000', '#0000ff')('Hello');
|
|
32
|
+
* pigment.theme.keyword('const');
|
|
100
33
|
* ```
|
|
101
34
|
*/
|
|
102
|
-
declare function createPigment(options?: PigmentOptions):
|
|
103
|
-
builder: BuilderPigment;
|
|
104
|
-
level: number;
|
|
105
|
-
supportsColor: ColorSupport;
|
|
106
|
-
};
|
|
35
|
+
declare function createPigment(options?: PigmentOptions): PigmentInstance;
|
|
107
36
|
|
|
37
|
+
declare const MODIFIER_NAMES: readonly ["bold", "dim", "italic", "underline", "strikethrough", "inverse", "hidden", "reset"];
|
|
38
|
+
declare const COLOR_NAMES: readonly ["black", "red", "green", "yellow", "blue", "magenta", "cyan", "white", "blackBright", "redBright", "greenBright", "yellowBright", "blueBright", "magentaBright", "cyanBright", "whiteBright", "gray", "grey"];
|
|
39
|
+
declare const BACKGROUND_COLOR_NAMES: readonly ["bgBlack", "bgRed", "bgGreen", "bgYellow", "bgBlue", "bgMagenta", "bgCyan", "bgWhite", "bgBlackBright", "bgRedBright", "bgGreenBright", "bgYellowBright", "bgBlueBright", "bgMagentaBright", "bgCyanBright", "bgWhiteBright", "bgGray", "bgGrey"];
|
|
40
|
+
|
|
41
|
+
type ColorLevel = 0 | 1 | 2 | 3;
|
|
42
|
+
/** Style names available as chainable properties, like chalk's. */
|
|
43
|
+
type ChalkStyleName = (typeof MODIFIER_NAMES)[number] | (typeof COLOR_NAMES)[number] | (typeof BACKGROUND_COLOR_NAMES)[number];
|
|
44
|
+
/**
|
|
45
|
+
* Chalk-compatible styler. Every style is a chainable, callable property
|
|
46
|
+
* (`chalk.red.bold('x')`), and setting `level` changes the output like chalk.
|
|
47
|
+
*/
|
|
48
|
+
interface Chalk extends Record<ChalkStyleName, Pigment> {
|
|
49
|
+
}
|
|
108
50
|
declare class Chalk {
|
|
109
|
-
level: 0 | 1 | 2 | 3;
|
|
110
51
|
supportsColor: ColorSupport;
|
|
52
|
+
private currentLevel;
|
|
111
53
|
private pigment;
|
|
112
54
|
constructor(options?: {
|
|
113
|
-
level?:
|
|
55
|
+
level?: ColorLevel;
|
|
114
56
|
});
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
magenta(text: string): string;
|
|
120
|
-
cyan(text: string): string;
|
|
121
|
-
white(text: string): string;
|
|
122
|
-
black(text: string): string;
|
|
123
|
-
redBright(text: string): string;
|
|
124
|
-
greenBright(text: string): string;
|
|
125
|
-
yellowBright(text: string): string;
|
|
126
|
-
blueBright(text: string): string;
|
|
127
|
-
magentaBright(text: string): string;
|
|
128
|
-
cyanBright(text: string): string;
|
|
129
|
-
whiteBright(text: string): string;
|
|
130
|
-
gray(text: string): string;
|
|
131
|
-
grey(text: string): string;
|
|
132
|
-
bgRed(text: string): string;
|
|
133
|
-
bgGreen(text: string): string;
|
|
134
|
-
bgYellow(text: string): string;
|
|
135
|
-
bgBlue(text: string): string;
|
|
136
|
-
bgMagenta(text: string): string;
|
|
137
|
-
bgCyan(text: string): string;
|
|
138
|
-
bgWhite(text: string): string;
|
|
139
|
-
bgBlack(text: string): string;
|
|
140
|
-
bgRedBright(text: string): string;
|
|
141
|
-
bgGreenBright(text: string): string;
|
|
142
|
-
bgYellowBright(text: string): string;
|
|
143
|
-
bgBlueBright(text: string): string;
|
|
144
|
-
bgMagentaBright(text: string): string;
|
|
145
|
-
bgCyanBright(text: string): string;
|
|
146
|
-
bgWhiteBright(text: string): string;
|
|
147
|
-
bgGray(text: string): string;
|
|
148
|
-
bgGrey(text: string): string;
|
|
149
|
-
bold(text: string): string;
|
|
150
|
-
dim(text: string): string;
|
|
151
|
-
italic(text: string): string;
|
|
152
|
-
underline(text: string): string;
|
|
153
|
-
strikethrough(text: string): string;
|
|
154
|
-
inverse(text: string): string;
|
|
155
|
-
hidden(text: string): string;
|
|
156
|
-
reset(text: string): string;
|
|
157
|
-
/** Like chalk: returns the text only when colors are supported, otherwise ''. */
|
|
57
|
+
/** Color level (0-3). Setting it changes the output of every style. */
|
|
58
|
+
get level(): ColorLevel;
|
|
59
|
+
set level(level: ColorLevel);
|
|
60
|
+
/** Like chalk: returns the text only when colors are enabled, otherwise ''. */
|
|
158
61
|
visible(text: string): string;
|
|
159
|
-
rgb(r: number, g: number, b: number):
|
|
160
|
-
bgRgb(r: number, g: number, b: number):
|
|
161
|
-
hex(color: string):
|
|
162
|
-
bgHex(color: string):
|
|
163
|
-
ansi256(code: number):
|
|
164
|
-
bgAnsi256(code: number):
|
|
62
|
+
rgb(r: number, g: number, b: number): Pigment;
|
|
63
|
+
bgRgb(r: number, g: number, b: number): Pigment;
|
|
64
|
+
hex(color: string): Pigment;
|
|
65
|
+
bgHex(color: string): Pigment;
|
|
66
|
+
ansi256(code: number): Pigment;
|
|
67
|
+
bgAnsi256(code: number): Pigment;
|
|
165
68
|
}
|
|
166
69
|
|
|
167
70
|
declare const chalk: Chalk;
|
|
@@ -242,10 +145,6 @@ declare function hslToRgb(h: number, s: number, l: number): {
|
|
|
242
145
|
|
|
243
146
|
declare function rgbToAnsi256(r: number, g: number, b: number): number;
|
|
244
147
|
|
|
245
|
-
declare const pigment:
|
|
246
|
-
builder: BuilderPigment;
|
|
247
|
-
level: number;
|
|
248
|
-
supportsColor: ColorSupport;
|
|
249
|
-
};
|
|
148
|
+
declare const pigment: PigmentInstance;
|
|
250
149
|
|
|
251
|
-
export {
|
|
150
|
+
export { ColorSupport, Pigment, PigmentInstance, PigmentOptions, Platform, Styler, bgBlack, bgBlackBright, bgBlue, bgBlueBright, bgCyan, bgCyanBright, bgGray, bgGreen, bgGreenBright, bgGrey, bgMagenta, bgMagentaBright, bgRed, bgRedBright, bgWhite, bgWhiteBright, bgYellow, bgYellowBright, black, blackBright, blue, blueBright, bold, compose, createPigment, cyan, cyanBright, chalk as default, detectColorSupport, detectPlatform, dim, gray, green, greenBright, grey, hasTTY, hexToRgb, hidden, hslToRgb, inverse, isBrowser, isCI, isNode, isWindows, italic, magenta, magentaBright, pigment, red, redBright, reset, resetColorSupportCache, rgbToAnsi256, strikethrough, supportsColor, underline, validateHex, white, whiteBright, yellow, yellowBright };
|
package/dist/index.d.ts
CHANGED
|
@@ -1,74 +1,5 @@
|
|
|
1
|
-
import { P as
|
|
2
|
-
export { B as BoxBorder,
|
|
3
|
-
export { createKernel } from '@oxog/plugin';
|
|
4
|
-
export { MaybePromise, Unsubscribe } from '@oxog/types';
|
|
5
|
-
|
|
6
|
-
/**
|
|
7
|
-
* Builder-pattern Pigment for explicit composition.
|
|
8
|
-
*
|
|
9
|
-
* @example
|
|
10
|
-
* ```typescript
|
|
11
|
-
* const builder = new BuilderPigment(kernel);
|
|
12
|
-
* const styled = builder.bold().red().paint('Error!');
|
|
13
|
-
* ```
|
|
14
|
-
*/
|
|
15
|
-
declare class BuilderPigment {
|
|
16
|
-
private styles;
|
|
17
|
-
constructor(_kernel: PigmentKernel);
|
|
18
|
-
bold(): this;
|
|
19
|
-
dim(): this;
|
|
20
|
-
italic(): this;
|
|
21
|
-
underline(): this;
|
|
22
|
-
strikethrough(): this;
|
|
23
|
-
inverse(): this;
|
|
24
|
-
hidden(): this;
|
|
25
|
-
reset(): this;
|
|
26
|
-
black(): this;
|
|
27
|
-
red(): this;
|
|
28
|
-
green(): this;
|
|
29
|
-
yellow(): this;
|
|
30
|
-
blue(): this;
|
|
31
|
-
magenta(): this;
|
|
32
|
-
cyan(): this;
|
|
33
|
-
white(): this;
|
|
34
|
-
blackBright(): this;
|
|
35
|
-
redBright(): this;
|
|
36
|
-
greenBright(): this;
|
|
37
|
-
yellowBright(): this;
|
|
38
|
-
blueBright(): this;
|
|
39
|
-
magentaBright(): this;
|
|
40
|
-
cyanBright(): this;
|
|
41
|
-
whiteBright(): this;
|
|
42
|
-
gray(): this;
|
|
43
|
-
grey(): this;
|
|
44
|
-
bgBlack(): this;
|
|
45
|
-
bgRed(): this;
|
|
46
|
-
bgGreen(): this;
|
|
47
|
-
bgYellow(): this;
|
|
48
|
-
bgBlue(): this;
|
|
49
|
-
bgMagenta(): this;
|
|
50
|
-
bgCyan(): this;
|
|
51
|
-
bgWhite(): this;
|
|
52
|
-
bgBlackBright(): this;
|
|
53
|
-
bgRedBright(): this;
|
|
54
|
-
bgGreenBright(): this;
|
|
55
|
-
bgYellowBright(): this;
|
|
56
|
-
bgBlueBright(): this;
|
|
57
|
-
bgMagentaBright(): this;
|
|
58
|
-
bgCyanBright(): this;
|
|
59
|
-
bgWhiteBright(): this;
|
|
60
|
-
bgGray(): this;
|
|
61
|
-
bgGrey(): this;
|
|
62
|
-
ansi256(code: number): this;
|
|
63
|
-
bgAnsi256(code: number): this;
|
|
64
|
-
rgb(r: number, g: number, b: number): this;
|
|
65
|
-
bgRgb(r: number, g: number, b: number): this;
|
|
66
|
-
hex(color: string): this;
|
|
67
|
-
bgHex(color: string): this;
|
|
68
|
-
hsl(h: number, s: number, l: number): this;
|
|
69
|
-
bgHsl(h: number, s: number, l: number): this;
|
|
70
|
-
paint(text: string): string;
|
|
71
|
-
}
|
|
1
|
+
import { P as PigmentOptions, a as PigmentInstance, b as Pigment, C as ColorSupport, S as Styler, c as Platform } from './index-DsggPsSl.js';
|
|
2
|
+
export { B as BoxBorder, d as BoxChars, e as BoxOptions, f as BoxPluginOptions, g as BuilderPigment, h as ColorInput, E as EventHandler, G as GradientPluginOptions, K as Kernel, i as KernelOptions, M as MaybePromise, j as PigmentContext, k as PigmentEvents, l as PigmentKernel, m as PigmentPluginApi, n as PigmentPluginOptions, o as Plugin, p as SemanticPluginOptions, q as Style, r as StyleFunction, T as ThemeColorType, s as ThemePluginOptions, t as ThemePreset, u as ThemePresetColors, U as Unsubscribe, v as createKernel, w as plugins } from './index-DsggPsSl.js';
|
|
72
3
|
|
|
73
4
|
/**
|
|
74
5
|
* Creates a new Pigment instance using @oxog/plugin micro-kernel.
|
|
@@ -88,7 +19,7 @@ declare class BuilderPigment {
|
|
|
88
19
|
* forceColor: true, // Force colors
|
|
89
20
|
* });
|
|
90
21
|
*
|
|
91
|
-
* // With optional plugins
|
|
22
|
+
* // With optional plugins: they add methods to the instance
|
|
92
23
|
* import { gradientPlugin, themePlugin } from '@oxog/pigment/plugins';
|
|
93
24
|
*
|
|
94
25
|
* const pigment = createPigment({
|
|
@@ -97,71 +28,43 @@ declare class BuilderPigment {
|
|
|
97
28
|
* themePlugin({ preset: 'monokai' })
|
|
98
29
|
* ]
|
|
99
30
|
* });
|
|
31
|
+
* pigment.gradient('#ff0000', '#0000ff')('Hello');
|
|
32
|
+
* pigment.theme.keyword('const');
|
|
100
33
|
* ```
|
|
101
34
|
*/
|
|
102
|
-
declare function createPigment(options?: PigmentOptions):
|
|
103
|
-
builder: BuilderPigment;
|
|
104
|
-
level: number;
|
|
105
|
-
supportsColor: ColorSupport;
|
|
106
|
-
};
|
|
35
|
+
declare function createPigment(options?: PigmentOptions): PigmentInstance;
|
|
107
36
|
|
|
37
|
+
declare const MODIFIER_NAMES: readonly ["bold", "dim", "italic", "underline", "strikethrough", "inverse", "hidden", "reset"];
|
|
38
|
+
declare const COLOR_NAMES: readonly ["black", "red", "green", "yellow", "blue", "magenta", "cyan", "white", "blackBright", "redBright", "greenBright", "yellowBright", "blueBright", "magentaBright", "cyanBright", "whiteBright", "gray", "grey"];
|
|
39
|
+
declare const BACKGROUND_COLOR_NAMES: readonly ["bgBlack", "bgRed", "bgGreen", "bgYellow", "bgBlue", "bgMagenta", "bgCyan", "bgWhite", "bgBlackBright", "bgRedBright", "bgGreenBright", "bgYellowBright", "bgBlueBright", "bgMagentaBright", "bgCyanBright", "bgWhiteBright", "bgGray", "bgGrey"];
|
|
40
|
+
|
|
41
|
+
type ColorLevel = 0 | 1 | 2 | 3;
|
|
42
|
+
/** Style names available as chainable properties, like chalk's. */
|
|
43
|
+
type ChalkStyleName = (typeof MODIFIER_NAMES)[number] | (typeof COLOR_NAMES)[number] | (typeof BACKGROUND_COLOR_NAMES)[number];
|
|
44
|
+
/**
|
|
45
|
+
* Chalk-compatible styler. Every style is a chainable, callable property
|
|
46
|
+
* (`chalk.red.bold('x')`), and setting `level` changes the output like chalk.
|
|
47
|
+
*/
|
|
48
|
+
interface Chalk extends Record<ChalkStyleName, Pigment> {
|
|
49
|
+
}
|
|
108
50
|
declare class Chalk {
|
|
109
|
-
level: 0 | 1 | 2 | 3;
|
|
110
51
|
supportsColor: ColorSupport;
|
|
52
|
+
private currentLevel;
|
|
111
53
|
private pigment;
|
|
112
54
|
constructor(options?: {
|
|
113
|
-
level?:
|
|
55
|
+
level?: ColorLevel;
|
|
114
56
|
});
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
magenta(text: string): string;
|
|
120
|
-
cyan(text: string): string;
|
|
121
|
-
white(text: string): string;
|
|
122
|
-
black(text: string): string;
|
|
123
|
-
redBright(text: string): string;
|
|
124
|
-
greenBright(text: string): string;
|
|
125
|
-
yellowBright(text: string): string;
|
|
126
|
-
blueBright(text: string): string;
|
|
127
|
-
magentaBright(text: string): string;
|
|
128
|
-
cyanBright(text: string): string;
|
|
129
|
-
whiteBright(text: string): string;
|
|
130
|
-
gray(text: string): string;
|
|
131
|
-
grey(text: string): string;
|
|
132
|
-
bgRed(text: string): string;
|
|
133
|
-
bgGreen(text: string): string;
|
|
134
|
-
bgYellow(text: string): string;
|
|
135
|
-
bgBlue(text: string): string;
|
|
136
|
-
bgMagenta(text: string): string;
|
|
137
|
-
bgCyan(text: string): string;
|
|
138
|
-
bgWhite(text: string): string;
|
|
139
|
-
bgBlack(text: string): string;
|
|
140
|
-
bgRedBright(text: string): string;
|
|
141
|
-
bgGreenBright(text: string): string;
|
|
142
|
-
bgYellowBright(text: string): string;
|
|
143
|
-
bgBlueBright(text: string): string;
|
|
144
|
-
bgMagentaBright(text: string): string;
|
|
145
|
-
bgCyanBright(text: string): string;
|
|
146
|
-
bgWhiteBright(text: string): string;
|
|
147
|
-
bgGray(text: string): string;
|
|
148
|
-
bgGrey(text: string): string;
|
|
149
|
-
bold(text: string): string;
|
|
150
|
-
dim(text: string): string;
|
|
151
|
-
italic(text: string): string;
|
|
152
|
-
underline(text: string): string;
|
|
153
|
-
strikethrough(text: string): string;
|
|
154
|
-
inverse(text: string): string;
|
|
155
|
-
hidden(text: string): string;
|
|
156
|
-
reset(text: string): string;
|
|
157
|
-
/** Like chalk: returns the text only when colors are supported, otherwise ''. */
|
|
57
|
+
/** Color level (0-3). Setting it changes the output of every style. */
|
|
58
|
+
get level(): ColorLevel;
|
|
59
|
+
set level(level: ColorLevel);
|
|
60
|
+
/** Like chalk: returns the text only when colors are enabled, otherwise ''. */
|
|
158
61
|
visible(text: string): string;
|
|
159
|
-
rgb(r: number, g: number, b: number):
|
|
160
|
-
bgRgb(r: number, g: number, b: number):
|
|
161
|
-
hex(color: string):
|
|
162
|
-
bgHex(color: string):
|
|
163
|
-
ansi256(code: number):
|
|
164
|
-
bgAnsi256(code: number):
|
|
62
|
+
rgb(r: number, g: number, b: number): Pigment;
|
|
63
|
+
bgRgb(r: number, g: number, b: number): Pigment;
|
|
64
|
+
hex(color: string): Pigment;
|
|
65
|
+
bgHex(color: string): Pigment;
|
|
66
|
+
ansi256(code: number): Pigment;
|
|
67
|
+
bgAnsi256(code: number): Pigment;
|
|
165
68
|
}
|
|
166
69
|
|
|
167
70
|
declare const chalk: Chalk;
|
|
@@ -242,10 +145,6 @@ declare function hslToRgb(h: number, s: number, l: number): {
|
|
|
242
145
|
|
|
243
146
|
declare function rgbToAnsi256(r: number, g: number, b: number): number;
|
|
244
147
|
|
|
245
|
-
declare const pigment:
|
|
246
|
-
builder: BuilderPigment;
|
|
247
|
-
level: number;
|
|
248
|
-
supportsColor: ColorSupport;
|
|
249
|
-
};
|
|
148
|
+
declare const pigment: PigmentInstance;
|
|
250
149
|
|
|
251
|
-
export {
|
|
150
|
+
export { ColorSupport, Pigment, PigmentInstance, PigmentOptions, Platform, Styler, bgBlack, bgBlackBright, bgBlue, bgBlueBright, bgCyan, bgCyanBright, bgGray, bgGreen, bgGreenBright, bgGrey, bgMagenta, bgMagentaBright, bgRed, bgRedBright, bgWhite, bgWhiteBright, bgYellow, bgYellowBright, black, blackBright, blue, blueBright, bold, compose, createPigment, cyan, cyanBright, chalk as default, detectColorSupport, detectPlatform, dim, gray, green, greenBright, grey, hasTTY, hexToRgb, hidden, hslToRgb, inverse, isBrowser, isCI, isNode, isWindows, italic, magenta, magentaBright, pigment, red, redBright, reset, resetColorSupportCache, rgbToAnsi256, strikethrough, supportsColor, underline, validateHex, white, whiteBright, yellow, yellowBright };
|