[BUG] Slash command picker auto-submits commands that require arguments (should insert into input)
Preflight Checklist
- [x] I have searched existing issues and this hasn't been reported yet
- [x] This is a single bug report (please file separate reports for different bugs)
- [x] I am using the latest version of Claude Code
What's Wrong?
Selecting a slash command from the slash-command picker (click or Enter) immediately submits/executes the command as a chat message. For commands that require arguments (e.g., have argument-hint: "<feature-description>"), this prevents the user from adding parameters before execution.
What Should Happen?
When selecting a slash command from the picker, the command should be inserted into the input field without submitting, so the user can type the required arguments and then submit intentionally—especially for commands that declare an argument-hint indicating required args.
Error Messages/Logs
N/A (no error message; this is UI behavior).
Steps to Reproduce
Install or define a custom slash command with YAML frontmatter including an argument hint indicating required args, e.g.:
argument-hint: "<feature-description>"
Open Claude Code chat.
Type / to open the Slash Commands menu.
Click the command (or press Enter on the highlighted command).
Result: the command is submitted immediately as a message, without an opportunity to add arguments.
Claude Model
Opus
Is this a regression?
I don't know
Last Working Version
_No response_
Claude Code Version
2.1.34
Platform
Anthropic API
Operating System
Windows
Terminal/Shell
VS Code integrated terminal
Additional Information
<img width="1081" height="451" alt="Image" src="https://github.com/user-attachments/assets/2f0fe8c1-09ea-4e2a-a7de-d1f7f780cf16" />
Related but different issues:
Argument-hint UX visibility improvement (#20667)
Namespaced custom command + arguments causes picker issues (#6946)
Slash command selection/highlight issues (#19107)
Frontmatter argument-hint syntax-related bug (#8429)
This issue has 5 comments on GitHub. Read the full discussion on GitHub ↗