petereon / beaupy

A Python library of interactive CLI elements you have been looking for
https://petereon.github.io/beaupy/
MIT License
183 stars 13 forks source link

feat: allow specifying an initial value for a prompt #31

Closed MatanRubin closed 1 year ago

MatanRubin commented 1 year ago

This change allows the user to specify an initial value for a prompt, similar to how "select" prompts allow specifying the initial position of the cursor. If an initial value is given, it is automatically placed in the prompt, and the cursor is moved to the end, as if the user just typed this input himself.