-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathansi-seqs-to-ansi-tags.js
58 lines (50 loc) · 1.38 KB
/
ansi-seqs-to-ansi-tags.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
module.exports = {
'\u001B[30m': 'black',
'\u001B[31m': 'red',
'\u001B[32m': 'green',
'\u001B[33m': 'yellow',
'\u001B[34m': 'blue',
'\u001B[35m': 'magenta',
'\u001B[36m': 'cyan',
'\u001B[37m': 'white',
'\u001B[90m': 'gray',
'\u001B[91m': 'redBright',
'\u001B[92m': 'greenBright',
'\u001B[93m': 'yellowBright',
'\u001B[94m': 'blueBright',
'\u001B[95m': 'magentaBright',
'\u001B[96m': 'cyanBright',
'\u001B[97m': 'whiteBright',
'\u001B[39m': 'foregroundColorClose',
'\u001B[40m': 'bgBlack',
'\u001B[41m': 'bgRed',
'\u001B[42m': 'bgGreen',
'\u001B[43m': 'bgYellow',
'\u001B[44m': 'bgBlue',
'\u001B[45m': 'bgMagenta',
'\u001B[46m': 'bgCyan',
'\u001B[47m': 'bgWhite',
'\u001B[100m': 'bgGray',
'\u001B[101m': 'bgRedBright',
'\u001B[102m': 'bgGreenBright',
'\u001B[103m': 'bgYellowBright',
'\u001B[104m': 'bgBlueBright',
'\u001B[105m': 'bgMagentaBright',
'\u001B[106m': 'bgCyanBright',
'\u001B[107m': 'bgWhiteBright',
'\u001B[49m': 'backgroundColorClose',
'\u001B[1m': 'boldOpen',
'\u001B[2m': 'dimOpen',
'\u001B[3m': 'italicOpen',
'\u001B[4m': 'underlineOpen',
'\u001B[7m': 'inverseOpen',
'\u001B[8m': 'hiddenOpen',
'\u001B[9m': 'strikethroughOpen',
'\u001B[22m': 'boldDimClose',
'\u001B[23m': 'italicClose',
'\u001B[24m': 'underlineClose',
'\u001B[27m': 'inverseClose',
'\u001B[28m': 'hiddenClose',
'\u001B[29m': 'strikethroughClose',
'\u001B[0m': 'reset'
}