Comparing version 2.0.0 to 2.0.1
@@ -11,5 +11,6 @@ import args = require('./args'); | ||
readonly validate: typeof validate; | ||
readonly chalk: chalk.Chalk & { | ||
readonly renderList: (items: [string, string | undefined][]) => string; | ||
readonly chalk: (chalk.Chalk & { | ||
supportsColor: chalk.ColorSupport; | ||
}; | ||
}) | undefined; | ||
}; |
@@ -8,3 +8,9 @@ "use strict"; | ||
get validate() { return fetch('./validate'); }, | ||
get chalk() { return fetch('chalk').default; }, | ||
get renderList() { return fetch('cli-ux/lib/list').renderList; }, | ||
get chalk() { | ||
try { | ||
return fetch('chalk').default; | ||
} | ||
catch (err) { } | ||
}, | ||
}; | ||
@@ -11,0 +17,0 @@ const cache = {}; |
@@ -5,2 +5,7 @@ "use strict"; | ||
const ts_lodash_1 = require("ts-lodash"); | ||
function dim(s) { | ||
if (deps_1.deps.chalk) | ||
return deps_1.deps.chalk.dim(s); | ||
return s; | ||
} | ||
function flagUsage(flag, options = {}) { | ||
@@ -16,3 +21,3 @@ const label = []; | ||
description = `(required) ${description}`; | ||
description = description ? deps_1.deps.chalk.dim(description) : undefined; | ||
description = description ? dim(description) : undefined; | ||
return [' ' + label.join(',').trim() + usage, description]; | ||
@@ -19,0 +24,0 @@ } |
{ | ||
"name": "cli-flags", | ||
"description": "basic CLI flag parser", | ||
"version": "2.0.0", | ||
"version": "2.0.1", | ||
"author": "Jeff Dickey", | ||
"bugs": "https://github.com/heroku/cli-flags/issues", | ||
"dependencies": { | ||
"chalk": "^2.3.0", | ||
"cli-ux": "^2.0.9", | ||
@@ -18,2 +17,3 @@ "ts-lodash": "^4.0.7" | ||
"babel-core": "^6.26.0", | ||
"chalk": "^2.3.0", | ||
"del-cli": "^1.1.0", | ||
@@ -20,0 +20,0 @@ "husky": "^0.14.3", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
21305
2
579
17
6
- Removedchalk@^2.3.0