@inquirer/core
Advanced tools
Comparing version 8.2.4 to 9.0.0
@@ -7,3 +7,3 @@ "use strict"; | ||
exports.Separator = void 0; | ||
const picocolors_1 = __importDefault(require("picocolors")); | ||
const yoctocolors_cjs_1 = __importDefault(require("yoctocolors-cjs")); | ||
const figures_1 = __importDefault(require("@inquirer/figures")); | ||
@@ -20,3 +20,3 @@ /** | ||
writable: true, | ||
value: picocolors_1.default.dim(Array.from({ length: 15 }).join(figures_1.default.line)) | ||
value: yoctocolors_cjs_1.default.dim(Array.from({ length: 15 }).join(figures_1.default.line)) | ||
}); | ||
@@ -23,0 +23,0 @@ Object.defineProperty(this, "type", { |
@@ -7,19 +7,19 @@ "use strict"; | ||
exports.defaultTheme = void 0; | ||
const picocolors_1 = __importDefault(require("picocolors")); | ||
const yoctocolors_cjs_1 = __importDefault(require("yoctocolors-cjs")); | ||
const cli_spinners_1 = __importDefault(require("cli-spinners")); | ||
exports.defaultTheme = { | ||
prefix: picocolors_1.default.green('?'), | ||
prefix: yoctocolors_cjs_1.default.green('?'), | ||
spinner: { | ||
interval: cli_spinners_1.default.dots.interval, | ||
frames: cli_spinners_1.default.dots.frames.map((frame) => picocolors_1.default.yellow(frame)), | ||
frames: cli_spinners_1.default.dots.frames.map((frame) => yoctocolors_cjs_1.default.yellow(frame)), | ||
}, | ||
style: { | ||
answer: picocolors_1.default.cyan, | ||
message: picocolors_1.default.bold, | ||
error: (text) => picocolors_1.default.red(`> ${text}`), | ||
defaultAnswer: (text) => picocolors_1.default.dim(`(${text})`), | ||
help: picocolors_1.default.dim, | ||
highlight: picocolors_1.default.cyan, | ||
key: (text) => picocolors_1.default.cyan(picocolors_1.default.bold(`<${text}>`)), | ||
answer: yoctocolors_cjs_1.default.cyan, | ||
message: yoctocolors_cjs_1.default.bold, | ||
error: (text) => yoctocolors_cjs_1.default.red(`> ${text}`), | ||
defaultAnswer: (text) => yoctocolors_cjs_1.default.dim(`(${text})`), | ||
help: yoctocolors_cjs_1.default.dim, | ||
highlight: yoctocolors_cjs_1.default.cyan, | ||
key: (text) => yoctocolors_cjs_1.default.cyan(yoctocolors_cjs_1.default.bold(`<${text}>`)), | ||
}, | ||
}; |
@@ -14,2 +14,1 @@ export * from './lib/key.js'; | ||
export { Separator } from './lib/Separator.js'; | ||
export { type InquirerReadline } from './lib/read-line.type.js'; |
@@ -1,2 +0,2 @@ | ||
import type { InquirerReadline } from './read-line.type.js'; | ||
import type { InquirerReadline } from '@inquirer/type'; | ||
type HookStore = { | ||
@@ -3,0 +3,0 @@ rl: InquirerReadline; |
@@ -1,2 +0,2 @@ | ||
import type { InquirerReadline } from './read-line.type.js'; | ||
import type { InquirerReadline } from '@inquirer/type'; | ||
export default class ScreenManager { | ||
@@ -3,0 +3,0 @@ private readonly rl; |
@@ -1,2 +0,2 @@ | ||
import type { InquirerReadline } from './read-line.type.js'; | ||
import type { InquirerReadline } from '@inquirer/type'; | ||
export declare function useEffect(cb: (rl: InquirerReadline) => void | (() => void), depArray: ReadonlyArray<unknown>): void; |
@@ -1,3 +0,3 @@ | ||
import { type InquirerReadline } from './read-line.type.js'; | ||
import { type InquirerReadline } from '@inquirer/type'; | ||
import { type KeypressEvent } from './key.js'; | ||
export declare function useKeypress(userHandler: (event: KeypressEvent, rl: InquirerReadline) => void): void; |
{ | ||
"name": "@inquirer/core", | ||
"version": "8.2.4", | ||
"version": "9.0.0", | ||
"engines": { | ||
@@ -61,3 +61,3 @@ "node": ">=18" | ||
"@inquirer/figures": "^1.0.3", | ||
"@inquirer/type": "^1.3.3", | ||
"@inquirer/type": "^1.4.0", | ||
"@types/mute-stream": "^0.0.4", | ||
@@ -70,9 +70,9 @@ "@types/node": "^20.14.9", | ||
"mute-stream": "^1.0.0", | ||
"picocolors": "^1.0.1", | ||
"signal-exit": "^4.1.0", | ||
"strip-ansi": "^6.0.1", | ||
"wrap-ansi": "^6.2.0" | ||
"wrap-ansi": "^6.2.0", | ||
"yoctocolors-cjs": "^2.1.1" | ||
}, | ||
"devDependencies": { | ||
"@inquirer/testing": "^2.1.23" | ||
"@inquirer/testing": "^2.1.24" | ||
}, | ||
@@ -102,3 +102,3 @@ "scripts": { | ||
"sideEffects": false, | ||
"gitHead": "d5f62c6ee3e671f7d1b776b85d43781869d70918" | ||
"gitHead": "fc27d575bceb96466cb8da8524c26d4eb2a77df0" | ||
} |
@@ -18,3 +18,3 @@ # `@inquirer/core` | ||
```ts | ||
import pc from 'picocolors'; | ||
import colors from 'yoctocolors'; | ||
import { | ||
@@ -48,8 +48,8 @@ createPrompt, | ||
if (status === 'done') { | ||
formattedValue = pc.cyan(value); | ||
formattedValue = colors.cyan(value); | ||
} else { | ||
defaultValue = pc.dim(config.default === false ? ' (y/N)' : ' (Y/n)'); | ||
defaultValue = colors.dim(config.default === false ? ' (y/N)' : ' (Y/n)'); | ||
} | ||
const message = pc.bold(config.message); | ||
const message = colors.bold(config.message); | ||
return `${prefix} ${message}${defaultValue} ${formattedValue}`; | ||
@@ -56,0 +56,0 @@ }, |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
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
82088
79
1643
+ Addedyoctocolors-cjs@^2.1.1
+ Addedyoctocolors-cjs@2.1.2(transitive)
- Removedpicocolors@^1.0.1
- Removedpicocolors@1.1.0(transitive)
Updated@inquirer/type@^1.4.0