Swap Tab/Enter in argument picker: Tab edits, Enter runs
More consistent with main picker flow. Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
parent
356a47eebc
commit
9f3227f7ef
|
|
@ -257,7 +257,7 @@ def pick_args(tool: dict) -> Optional[dict]:
|
|||
lines.append(line)
|
||||
|
||||
if editing is None:
|
||||
lines.append(f"{DIM}Enter:edit Tab:run Esc:back{RESET}")
|
||||
lines.append(f"{DIM}Tab:edit Enter:run Esc:back{RESET}")
|
||||
|
||||
sys.stdout.write('\n'.join(lines) + '\n')
|
||||
sys.stdout.flush()
|
||||
|
|
@ -278,10 +278,10 @@ def pick_args(tool: dict) -> Optional[dict]:
|
|||
elif ch.isprintable():
|
||||
edit_buf += ch
|
||||
else:
|
||||
if ch == '\t': # Done
|
||||
if ch in ('\r', '\n'): # Enter - run
|
||||
clear_dropdown(last_drawn)
|
||||
return values
|
||||
elif ch in ('\r', '\n'): # Edit
|
||||
elif ch == '\t': # Tab - edit
|
||||
editing = selected
|
||||
edit_buf = values[args[selected]['flag']]
|
||||
elif ch == '\x1b' or ch == '\x03': # Back
|
||||
|
|
|
|||
Loading…
Reference in New Issue