Releases: bombshell-dev/clack
@clack/[email protected]
Patch Changes
- 7b009df: Fix spinner clearing too many lines upwards when non-wrapping.
- ae84dd0: Update key binding text to show tab/space when navigating, and tab otherwise.
- Updated dependencies [d98e033]
- @clack/[email protected]
@clack/[email protected]
Patch Changes
- d98e033: add invert selection for multiselect prompt
@clack/[email protected]
Minor Changes
- 76fd17f: Added new
box
prompt for rendering boxed text, similar a note. - 1604f97: Add
clearOnError
option to password prompt to automatically clear input when validation fails
Patch Changes
- 1a45f93: Switched from wrap-ansi to fast-wrap-ansi
- 4c89dd7: chore: use more accurate type to replace any in group select
- Updated dependencies [1a45f93]
- Updated dependencies [1604f97]
- @clack/[email protected]
@clack/[email protected]
@clack/[email protected]
Minor Changes
- 7bc3301: Prompts now have a
userInput
stored separately from theirvalue
. - 2837845: Adds suggestion and path prompts
- 9e5bc6c: Add support for signals in prompts, allowing them to be aborted.
- df4eea1: Remove
suggestion
prompt and changepath
prompt to be an autocomplete prompt. - 9bd8072: Add a
required
option to autocomplete multiselect.
Patch Changes
- bfe0dd3: Prevents placeholder from being used as input value in text prompts
- 94fee2a: Changes
placeholder
to be a visual hint rather than a tabbable value. - Updated dependencies [bfe0dd3]
- Updated dependencies [7bc3301]
- Updated dependencies [2837845]
- Updated dependencies [34f52fe]
- Updated dependencies [94fee2a]
- Updated dependencies [4f6b3c2]
- Updated dependencies [df4eea1]
- Updated dependencies [8ead5d3]
- @clack/[email protected]
@clack/[email protected]
Minor Changes
- 07ca32d: Reverted a change where placeholders were being set as values on return.
Patch Changes
- Updated dependencies [07ca32d]
- @clack/[email protected]
@clack/[email protected]
Minor Changes
- 07ca32d: Reverted a change where placeholders were being set as values on return.
@clack/[email protected]
Major Changes
-
c713fd5: The package is now distributed as ESM-only. In
v0
releases, the package was dual-published as CJS and ESM.For existing CJS projects using Node v20+, please see Node's guide on Loading ECMAScript modules using
require()
.
Minor Changes
-
99c3530: Adds
format
option to the note prompt to allow formatting of individual lines -
0aaee4c: Added new
taskLog
prompt for log output which is cleared on success -
729bbb6: Add support for customizable spinner cancel and error messages. Users can now customize these messages either per spinner instance or globally via the
updateSettings
function to support multilingual CLIs.This update also improves the architecture by exposing the core settings to the prompts package, enabling more consistent default message handling across the codebase.
// Per-instance customization const spinner = prompts.spinner({ cancelMessage: "Operación cancelada", // "Operation cancelled" in Spanish errorMessage: "Se produjo un error", // "An error occurred" in Spanish }); // Global customization via updateSettings prompts.updateSettings({ messages: { cancel: "Operación cancelada", // "Operation cancelled" in Spanish error: "Se produjo un error", // "An error occurred" in Spanish }, }); // Settings can now be accessed directly console.log(prompts.settings.messages.cancel); // "Operación cancelada" // Direct options take priority over global settings const spinner = prompts.spinner({ cancelMessage: "Cancelled", // This will be used instead of the global setting });
-
44df9af: Adds a new
groupSpacing
option to grouped multi-select prompts. If set to an integer greater than 0, it will add that number of new lines between each group. -
f2c2b89: Adds
AutocompletePrompt
to core with comprehensive tests and implement bothautocomplete
andautocomplete-multiselect
components in prompts package. -
c45b9fb: Adds support for detecting spinner cancellation via CTRL+C. This allows for graceful handling of user interruptions during long-running operations.
-
9a09318: Adds new
progress
prompt to display a progess-bar -
19558b9: Added support for custom frames in spinner prompt
Patch Changes
- 46dc0a4: Fixes multiselect only shows hints on the first item in the options list. Now correctly shows hints for all selected options with hint property.
- 17342d2: Exposes a new
SpinnerResult
type to describe the return type ofspinner
- 6868c1c: Adds a new
selectableGroups
boolean to the group multi-select prompt. UsingselectableGroups: false
will disable the ability to select a top-level group, but still allow every child to be selected individually. - 7a556ad: Updates all prompts to accept a custom
output
andinput
stream - 7cc8a55: Messages passed to the
stop
method of a spinner no longer have dots stripped. - 2048eb1: Fix spinner's dots behavior with custom frames
- Updated dependencies [729bbb6]
- Updated dependencies [6868c1c]
- Updated dependencies [a4f5034]
- Updated dependencies [c713fd5]
- Updated dependencies [a36292b]
- Updated dependencies [f2c2b89]
- @clack/[email protected]
@clack/[email protected]
Patch Changes
- 11a5dc1: Fixes multiselect only shows hints on the first item in the options list. Now correctly shows hints for all selected options with hint property.
- 30aa7ed: Adds a new
selectableGroups
boolean to the group multi-select prompt. UsingselectableGroups: false
will disable the ability to select a top-level group, but still allow every child to be selected individually. - Updated dependencies [30aa7ed]
- Updated dependencies [5dfce8a]
- Updated dependencies [f574297]
- @clack/[email protected]
@clack/[email protected]
Patch Changes
- 30aa7ed: Adds a new
selectableGroups
boolean to the group multi-select prompt. UsingselectableGroups: false
will disable the ability to select a top-level group, but still allow every child to be selected individually. - 5dfce8a: Fixes an edge case for placeholder values. Previously, when pressing
enter
on an empty prompt, placeholder values would be ignored. Now, placeholder values are treated as the prompt value. - f574297: Fix "TTY initialization failed: uv_tty_init returned EBADF (bad file descriptor)" error happening on Windows for non-tty terminals.