Context
This came up while evaluating @clack/prompts as a potential replacement for enquirer.js, comparing it with enquirer.js and @inquirer/prompts.
Split out from: #550
Problem
Some prompts may not handle long labels consistently.
For table-style labels with fixed-width columns, automatic wrapping can break visual alignment:
typescript-eslint 8.59.3 ❯ 8.59.4 @scope/project https://typescript-eslint.io/...
vitest 4.1.6 ❯ 4.1.7 @scope/project https://vitest.dev
If one row wraps and another does not, the columns become difficult to scan:
│ ◻ typescript-eslint 8.59.3 ❯ 8.59.4 @scope/project
│ https://typescript-eslint.io/packages/typescript-eslint
│ ◻ vitest 4.1.6 ❯ 4.1.7 @scope/project https://vitest.dev
Proposal
Audit prompts that render labels and open/fix bugs for any prompt that does not already handle long labels correctly.
Possible solutions could include:
- Consistent wrapping behavior across prompt types
- A
wrap: false option
- A
maxLabelWidth option
- Better support for rendering secondary information separately, such as through
hint
Notes
The maintainer noted that most prompts already handle wrapping, so this issue should focus only on prompts where wrapping is currently missing or inconsistent.
Context
This came up while evaluating
@clack/promptsas a potential replacement forenquirer.js, comparing it withenquirer.jsand@inquirer/prompts.Split out from: #550
Problem
Some prompts may not handle long labels consistently.
For table-style labels with fixed-width columns, automatic wrapping can break visual alignment:
If one row wraps and another does not, the columns become difficult to scan:
Proposal
Audit prompts that render labels and open/fix bugs for any prompt that does not already handle long labels correctly.
Possible solutions could include:
wrap: falseoptionmaxLabelWidthoptionhintNotes
The maintainer noted that most prompts already handle wrapping, so this issue should focus only on prompts where wrapping is currently missing or inconsistent.