mirror of
https://github.com/pnpm/pnpm.git
synced 2026-05-11 09:28:24 -04:00
fix(list): highlight in terminal with light theme
This commit is contained in:
5
.changeset/hungry-owls-relax.md
Normal file
5
.changeset/hungry-owls-relax.md
Normal file
@@ -0,0 +1,5 @@
|
||||
---
|
||||
"@pnpm/list": patch
|
||||
---
|
||||
|
||||
Highlight searched items with inverse. Works better in terminals with light theme.
|
||||
@@ -130,7 +130,7 @@ function printLabel (getPkgColor: GetPkgColor, node: PackageNode) {
|
||||
if (node.isSkipped) {
|
||||
txt += ' skipped'
|
||||
}
|
||||
return node.searched ? chalk.bold.bgBlack(txt) : txt
|
||||
return node.searched ? chalk.bold.inverse(txt) : txt
|
||||
}
|
||||
|
||||
function getPkgColor (node: PackageNode) {
|
||||
|
||||
@@ -20,7 +20,7 @@ const DEV_DEPENDENCIES = chalk.cyanBright('devDependencies:')
|
||||
const OPTIONAL_DEPENDENCIES = chalk.cyanBright('optionalDependencies:')
|
||||
const UNSAVED_DEPENDENCIES = chalk.cyanBright('not saved (you should add these dependencies to package.json if you need them):')
|
||||
|
||||
const highlighted = chalk.bold.bgBlack
|
||||
const highlighted = chalk.bold.inverse
|
||||
|
||||
const fixture = path.join(__dirname, 'fixture')
|
||||
const fixtureWithNoPkgNameAndNoVersion = path.join(__dirname, 'fixture-with-no-pkg-name-and-no-version')
|
||||
|
||||
Reference in New Issue
Block a user