Skip to content

Commit 366454c

Browse files
committed
chore: update changeset
1 parent 370a91e commit 366454c

File tree

1 file changed

+9
-21
lines changed

1 file changed

+9
-21
lines changed

.changeset/quiet-actors-wink.md

Lines changed: 9 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -3,24 +3,12 @@
33
"@clack/core": minor
44
---
55

6-
Adds a new `updateSettings()` function to support global customization.
7-
8-
`updateSettings()` accepts an `aliases` object that maps
9-
custom keys to an action (one of
10-
`up | down | left | right | space | enter | cancel`). In the future, `updateSettings()`
11-
will support more even more customization options.
12-
13-
```ts
14-
import { updateSettings } from "@clack/prompts";
15-
16-
// Update Clack to recognize custom keys keybindings
17-
// before calling any prompts
18-
updateSettings({
19-
aliases: {
20-
w: "up",
21-
a: "left",
22-
s: "down",
23-
d: "right",
24-
},
25-
});
26-
```
6+
Updates default keybindings to support Vim motion shortcuts and map the `escape` key to cancel (`ctrl+c`).
7+
8+
| alias | action |
9+
|------- |-------- |
10+
| `k` | up |
11+
| `l` | right |
12+
| `j` | down |
13+
| `h` | left |
14+
| `esc` | cancel |

0 commit comments

Comments
 (0)