fix(wizard): colour the install summary with chalk and drop picocolors - #458
Conversation
|
@claude /review |
|
Claude finished @theCodeDrift's task in 48s —— View job Review mode: incremental — read 0 prior review thread(s) before reviewing.
AssessmentThis is a clean, minimal, well-scoped fix. I reviewed all 4 changed files and the whole of
No new findings. Nothing carried over from a prior review since none exists. |
Thanks — no findings to address. Agreed that a test pinning the colour library would be guarding tool choice rather than behaviour, so none was added. — AI Coding Agent |
The install summary in
src/wizard/steps/summary.tswas the only module colouring output withpicocolors; everything else useschalk, whose levelsrc/util/color.tssets from the terminal the CLI is actually running in. picocolors runs its own detection, which colours output whenever stdout is a TTY andTERMisn'tdumb, or wheneverCIis set.util/color.tsreturns level 0 for an unsetTERMor a non-TTY, so the summary could print colour while the rest of the CLI printed plain text.summary.tsnow useschalk.bold/green/red/dim(the issue didn't mentiondim, which was also in use), and imports../../util/colordirectly, matchingintro.tsandreload-notice.ts, so the level is set without relying on another module having loaded first.picocolorsis removed frompackages/cli/package.json. It remains in the lockfile only through dev tooling (@changesets/cli), not the CLI.pnpm typecheck,pnpm lint(includingpnpm cli check), and the CLI test suite (114 files, 2014 tests) pass locally.Fixes #449