Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
timreichen committed Nov 17, 2024
1 parent 9fd7c4a commit a738c45
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions cli/prompt_select.ts
Original file line number Diff line number Diff line change
Expand Up @@ -66,10 +66,10 @@ export function promptSelect(
case CR:
break loop;
}
Deno.stdout.writeSync(encoder.encode(`\x1b[${length}A${CLR}`));
Deno.stdout.writeSync(encoder.encode(`\x1b[1A${CLR}`.repeat(length)));
}
if (options.clear) {
Deno.stdout.writeSync(encoder.encode(`\x1b[${length + 1}A${CLR}`)); // clear values and message
Deno.stdout.writeSync(encoder.encode(`\x1b[1A${CLR}`.repeat(length + 1))); // clear values and message
}
Deno.stdin.setRaw(false);
return values[selectedIndex] ?? null;
Expand Down

0 comments on commit a738c45

Please sign in to comment.