Skip to content

[FEATURE] Setting to disable automatic editor group locking in the VS Code extension #80148

Description

@ChubbyDuck

Preflight Checklist

  • I have searched existing requests and this feature hasn't been requested yet
  • This is a single feature request (not multiple features)

Problem Statement

When the Claude Code panel opens in a new editor column, the extension programmatically locks that editor group by executing workbench.action.lockEditorGroup. Because the lock is applied imperatively, it bypasses the user's workbench.editor.autoLockGroups setting entirely — setting "mainThreadWebview-claudeVSCodePanel": false there has no effect. The extension exposes no setting of its own to opt out (verified against contributes.configuration of v2.1.217).

Consequences for users who don't want the lock:

Verified in the shipped extension.js of v2.1.216 / v2.1.217 (minified; Pe = vscode, u = panel manager):

Pe.commands.registerCommand("claude-vscode.editor.open", async (g, x, w) => {
  if (w !== Pe.ViewColumn.Active) r.setPreferredLocation("panel");
  let { startedInNewColumn: E } = u.createPanel(g, x, w);
  if (E) await Pe.commands.executeCommand("workbench.action.lockEditorGroup");
})

The lock is unconditional whenever startedInNewColumn is true.

Proposed Solution

Add a boolean setting, e.g. claudeCode.lockEditorGroupOnOpen (default true to preserve current behavior), to contributes.configuration, and gate the lock call on it:

const shouldLock = vscode.workspace
  .getConfiguration("claudeCode")
  .get<boolean>("lockEditorGroupOnOpen", true);
if (startedInNewColumn && shouldLock) {
  await vscode.commands.executeCommand("workbench.action.lockEditorGroup");
}

If the same pattern exists on other paths (e.g. the claudePlanPreview panel or the webview serializer/restore path), those should respect the setting too.

Alternative (or complementary): let VS Code's built-in workbench.editor.autoLockGroups mechanism drive the locking via the mainThreadWebview-claudeVSCodePanel view type instead of executing the command imperatively — then the existing user-facing VS Code setting would work as users expect.

Alternative Solutions

  • workbench.editor.autoLockGroups overrides for mainThreadWebview-claudeVSCodePanel and mainThreadWebview-claudePlanPreview set to false — no effect, since the lock is programmatic.
  • Manually running "View: Unlock Editor Group" — must be repeated after every panel open / window reload.
  • Binary-patching the installed extension (if(E) -> if(E&&!1)) — works, but must be re-applied after every extension update.

Priority

Medium - Would be very helpful

Feature Category

Configuration and settings

Use Case Example

  1. Open a project in VS Code/Cursor with the Claude Code panel in a side column.
  2. Open two files from the explorer.
  3. Today: the second file opens in a new split because the Claude group locked the layout; I unlock the group by hand, and again after the next reload.
  4. With "claudeCode.lockEditorGroupOnOpen": false, files open as normal tabs and the layout stays under my control.

Additional Context

Related issues:

Environment: anthropic.claude-code v2.1.216 / v2.1.217, VS Code and Cursor, macOS (Darwin 25.5.0).

UPD: for those, who need a temporary solution:

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions