mirror of
https://github.com/YunoHost/moulinette.git
synced 2024-09-03 20:06:31 +02:00
[fix] Prefill input with long color question
This commit is contained in:
parent
f414a1656a
commit
08f7866f77
1 changed files with 2 additions and 1 deletions
|
@ -550,9 +550,10 @@ class Interface:
|
||||||
if is_password:
|
if is_password:
|
||||||
return getpass.getpass(colorize(m18n.g("colon", message), color))
|
return getpass.getpass(colorize(m18n.g("colon", message), color))
|
||||||
elif not is_multiline:
|
elif not is_multiline:
|
||||||
|
print(colorize(m18n.g("colon", message), color), end="")
|
||||||
set_startup_hook(lambda: insert_text(prefill))
|
set_startup_hook(lambda: insert_text(prefill))
|
||||||
try:
|
try:
|
||||||
value = input(colorize(m18n.g("colon", message), color))
|
value = input()
|
||||||
finally:
|
finally:
|
||||||
set_startup_hook()
|
set_startup_hook()
|
||||||
return value
|
return value
|
||||||
|
|
Loading…
Reference in a new issue