Microsoft/vscode

Can't copy webview image to clipboard

Open

#292,567 建立於 2026年2月3日

在 GitHub 查看
 (1 留言) (0 反應) (1 負責人)TypeScript (10,221 fork)batch import
bughelp wantedwebview

倉庫指標

Star
 (74,848 star)
PR 合併指標
 (平均合併 11小時 48分鐘) (30 天內合併 1,000 個 PR)

描述

Does this issue occur when all extensions are disabled?: Yes (only had the repro extension enabled)

  • VS Code Version:
Version: 1.108.2
Commit: c9d77990917f3102ada88be140d28b038d1dd7c7
Date: 2026-01-21T13:52:09.270Z
Electron: 39.2.7
ElectronBuildId: 12953945
Chromium: 142.0.7444.235
Node.js: 22.21.1
V8: 14.2.231.21-electron.0
OS: Darwin arm64 25.1.0
  • OS Version: macos Tahoe 26.1 (25B78)

Steps to Reproduce:

Steps to repro.

  1. clone https://github.com/sboult/vscode-image-copy-to-clipboard-webview/tree/master
  2. open project in vscode
  3. npm install
  4. press f5 to launch the dev extension host
  5. use CMD+SHIFT+P (command palette) and select "Show Image in Webview"
  6. when the webview comes up right click on image and select "Copy"

You will notice no image is copied to the clipboard.

However, if you highlight the image and then use the context menu to copy it will go into the clipboard.

貢獻者指南