Skip to content

Commit 6a1eb72

Browse files
authored
fix(types): move types declaration into "real" types declaration file (.d.ts) (#82)
1 parent 4e94689 commit 6a1eb72

3 files changed

Lines changed: 53 additions & 53 deletions

File tree

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
},
1414
"files": [
1515
"picocolors.*",
16-
"types.ts"
16+
"types.d.ts"
1717
],
1818
"keywords": [
1919
"terminal",

types.d.ts

Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
export type Formatter = (input: string | number | null | undefined) => string
2+
3+
export interface Colors {
4+
isColorSupported: boolean
5+
6+
reset: Formatter
7+
bold: Formatter
8+
dim: Formatter
9+
italic: Formatter
10+
underline: Formatter
11+
inverse: Formatter
12+
hidden: Formatter
13+
strikethrough: Formatter
14+
15+
black: Formatter
16+
red: Formatter
17+
green: Formatter
18+
yellow: Formatter
19+
blue: Formatter
20+
magenta: Formatter
21+
cyan: Formatter
22+
white: Formatter
23+
gray: Formatter
24+
25+
bgBlack: Formatter
26+
bgRed: Formatter
27+
bgGreen: Formatter
28+
bgYellow: Formatter
29+
bgBlue: Formatter
30+
bgMagenta: Formatter
31+
bgCyan: Formatter
32+
bgWhite: Formatter
33+
34+
blackBright: Formatter
35+
redBright: Formatter
36+
greenBright: Formatter
37+
yellowBright: Formatter
38+
blueBright: Formatter
39+
magentaBright: Formatter
40+
cyanBright: Formatter
41+
whiteBright: Formatter
42+
43+
bgBlackBright: Formatter
44+
bgRedBright: Formatter
45+
bgGreenBright: Formatter
46+
bgYellowBright: Formatter
47+
bgBlueBright: Formatter
48+
bgMagentaBright: Formatter
49+
bgCyanBright: Formatter
50+
bgWhiteBright: Formatter
51+
52+
}

types.ts

Lines changed: 0 additions & 52 deletions
This file was deleted.

0 commit comments

Comments
 (0)