Skip to content

Commit

Permalink
fix: frozen subsequent select after using confirm (#43)
Browse files Browse the repository at this point in the history
  • Loading branch information
PierreDemailly authored Sep 30, 2023
1 parent 06c8d1a commit 743f64f
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/confirm-prompt.js
Original file line number Diff line number Diff line change
@@ -65,9 +65,8 @@ export class ConfirmPrompt extends AbstractPrompt {
}

#onKeypress(resolve, value, key) {
this.stdin.pause();
this.stdout.moveCursor(-this.#getQuestionQuery().length, 0);
this.stdout.clearScreenDown(() => this.stdin.resume());
this.stdout.clearScreenDown();

if (key.name === "return") {
resolve(this.selectedValue);

0 comments on commit 743f64f

Please sign in to comment.