From ffa3fecdf812cc66d3bfafea3ff60a5d8c6b4dc3 Mon Sep 17 00:00:00 2001 From: Matt Bierner <12821956+mjbvz@users.noreply.github.com> Date: Thu, 30 Apr 2026 21:22:57 -0700 Subject: [PATCH] Disable emmet commands when there is no active editor Fixes #313645 Co-authored-by: Copilot --- extensions/emmet/package.json | 44 +++++++++++++++++------------------ 1 file changed, 22 insertions(+), 22 deletions(-) diff --git a/extensions/emmet/package.json b/extensions/emmet/package.json index 67f834f9139..5ec0afb7ba5 100644 --- a/extensions/emmet/package.json +++ b/extensions/emmet/package.json @@ -384,91 +384,91 @@ "commandPalette": [ { "command": "editor.emmet.action.wrapWithAbbreviation", - "when": "!activeEditorIsReadonly" + "when": "activeEditor && !activeEditorIsReadonly" }, { "command": "editor.emmet.action.removeTag", - "when": "!activeEditorIsReadonly" + "when": "activeEditor && !activeEditorIsReadonly" }, { "command": "editor.emmet.action.updateTag", - "when": "!activeEditorIsReadonly" + "when": "activeEditor && !activeEditorIsReadonly" }, { "command": "editor.emmet.action.matchTag", - "when": "!activeEditorIsReadonly" + "when": "activeEditor && !activeEditorIsReadonly" }, { "command": "editor.emmet.action.balanceIn", - "when": "!activeEditorIsReadonly" + "when": "activeEditor && !activeEditorIsReadonly" }, { "command": "editor.emmet.action.balanceOut", - "when": "!activeEditorIsReadonly" + "when": "activeEditor && !activeEditorIsReadonly" }, { "command": "editor.emmet.action.prevEditPoint", - "when": "!activeEditorIsReadonly" + "when": "activeEditor && !activeEditorIsReadonly" }, { "command": "editor.emmet.action.nextEditPoint", - "when": "!activeEditorIsReadonly" + "when": "activeEditor && !activeEditorIsReadonly" }, { "command": "editor.emmet.action.mergeLines", - "when": "!activeEditorIsReadonly" + "when": "activeEditor && !activeEditorIsReadonly" }, { "command": "editor.emmet.action.selectPrevItem", - "when": "!activeEditorIsReadonly" + "when": "activeEditor && !activeEditorIsReadonly" }, { "command": "editor.emmet.action.selectNextItem", - "when": "!activeEditorIsReadonly" + "when": "activeEditor && !activeEditorIsReadonly" }, { "command": "editor.emmet.action.splitJoinTag", - "when": "!activeEditorIsReadonly" + "when": "activeEditor && !activeEditorIsReadonly" }, { "command": "editor.emmet.action.toggleComment", - "when": "!activeEditorIsReadonly" + "when": "activeEditor && !activeEditorIsReadonly" }, { "command": "editor.emmet.action.evaluateMathExpression", - "when": "!activeEditorIsReadonly" + "when": "activeEditor && !activeEditorIsReadonly" }, { "command": "editor.emmet.action.updateImageSize", - "when": "!activeEditorIsReadonly" + "when": "activeEditor && !activeEditorIsReadonly" }, { "command": "editor.emmet.action.incrementNumberByOneTenth", - "when": "!activeEditorIsReadonly" + "when": "activeEditor && !activeEditorIsReadonly" }, { "command": "editor.emmet.action.incrementNumberByOne", - "when": "!activeEditorIsReadonly" + "when": "activeEditor && !activeEditorIsReadonly" }, { "command": "editor.emmet.action.incrementNumberByTen", - "when": "!activeEditorIsReadonly" + "when": "activeEditor && !activeEditorIsReadonly" }, { "command": "editor.emmet.action.decrementNumberByOneTenth", - "when": "!activeEditorIsReadonly" + "when": "activeEditor && !activeEditorIsReadonly" }, { "command": "editor.emmet.action.decrementNumberByOne", - "when": "!activeEditorIsReadonly" + "when": "activeEditor && !activeEditorIsReadonly" }, { "command": "editor.emmet.action.decrementNumberByTen", - "when": "!activeEditorIsReadonly" + "when": "activeEditor && !activeEditorIsReadonly" }, { "command": "editor.emmet.action.reflectCSSValue", - "when": "!activeEditorIsReadonly" + "when": "activeEditor && !activeEditorIsReadonly" } ] }