[BUG] cmd+escape focus toggle does not correctly restore focus to AskUserQuestion prompt

Resolved 💬 2 comments Opened Mar 18, 2026 by dnknapp Closed Apr 15, 2026

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?

Describe the bug

The cmd+escape keybinding toggles focus between the active editor and the Claude Code panel correctly when the text input is active. However, when an AskUserQuestion prompt is displayed (single-select or multi-select), using cmd+escape to switch to the editor and back does not restore focus to the prompt options. The behavior differs between prompt types.

Single-select behavior

  • Focus returns to the panel but lands on a non-interactive element (pressing Space/Enter does nothing)
  • Tab order: panel title → close button → first option (3 presses to reach options)
  • Shift+Tab navigates backward through earlier conversation elements
  • Scroll position has no effect

Multi-select behavior

  • Focus does not return to the panel at all — Tab moves into other parts of the VSCode interface
  • Shift+Tab works and navigates the options in reverse order (bottom to top)

What Should Happen?

Focus returns to the prompt options and keyboard navigation works, consistent with how focus returns to the text input in normal conversation.

Error Messages/Logs

Steps to Reproduce

  1. Trigger a response from Claude that includes an AskUserQuestion prompt
  2. Press cmd+escape to move focus to the active editor
  3. Press cmd+escape again to return focus to the Claude panel
  4. Attempt to navigate the prompt options with the keyboard

Claude Model

Sonnet (default)

Is this a regression?

I don't know

Last Working Version

_No response_

Claude Code Version

2.1.78

Platform

Anthropic API

Operating System

macOS

Terminal/Shell

VS Code integrated terminal

Additional Information

Possibly related to #28722 (AskUserQuestion focus management). That issue covers focus being stolen by the prompt; this is the inverse — focus cannot correctly return to the prompt via the standard toggle.

View original on GitHub ↗

This issue has 2 comments on GitHub. Read the full discussion on GitHub ↗