From 21143174c43c9978bc95ccc41e6baed852a1643b Mon Sep 17 00:00:00 2001 From: Sindre Sorhus Date: Sun, 23 Nov 2014 18:56:00 +0700 Subject: [PATCH] bump ansi-styles the gray alias is now in ansi-styles --- index.js | 4 +--- package.json | 6 +++--- readme.md | 6 ++++-- 3 files changed, 8 insertions(+), 8 deletions(-) diff --git a/index.js b/index.js index aec1d4d..0bbc27c 100644 --- a/index.js +++ b/index.js @@ -21,8 +21,6 @@ function build(_styles) { var styles = (function () { var ret = {}; - ansiStyles.grey = ansiStyles.gray; - Object.keys(ansiStyles).forEach(function (key) { ansiStyles[key].closeRe = new RegExp(escapeStringRegexp(ansiStyles[key].close), 'g'); @@ -54,7 +52,7 @@ function applyStyle() { return str; } - /*jshint validthis: true*/ + /*jshint validthis: true */ var nestedStyles = this._styles; var i = nestedStyles.length; diff --git a/package.json b/package.json index 47409c8..94fb785 100644 --- a/package.json +++ b/package.json @@ -40,14 +40,14 @@ "text" ], "dependencies": { - "ansi-styles": "^1.1.0", + "ansi-styles": "^2.0.0", "escape-string-regexp": "^1.0.1", "has-ansi": "^1.0.0", "strip-ansi": "^2.0.0", - "supports-color": "^1.0.0" + "supports-color": "^1.2.0" }, "devDependencies": { - "matcha": "^0.5.0", + "matcha": "^0.6.0", "mocha": "*" } } diff --git a/readme.md b/readme.md index 64487fb..a1da5f7 100644 --- a/readme.md +++ b/readme.md @@ -138,7 +138,7 @@ if (!chalk.supportsColor) { ## Styles -### General +### Modifiers - `reset` - `bold` @@ -149,7 +149,7 @@ if (!chalk.supportsColor) { - `hidden` - `strikethrough` *(not widely supported)* -### Text colors +### Colors - `black` - `red` @@ -172,10 +172,12 @@ if (!chalk.supportsColor) { - `bgCyan` - `bgWhite` + ## 256-colors Chalk does not support support anything other than the base eight colors, which guarantees it will work on all terminals and systems. Some terminals, specifically `xterm` compliant ones, will support the full range of 8-bit colors. For this the lower level [ansi-256-colors](https://github.com/jbnicolai/ansi-256-colors) package can be used. + ## License MIT © [Sindre Sorhus](http://sindresorhus.com)