XFE Git
XFE Studio Git
Git 首页 全局搜索
XFE 主站 文档 NuGet
公开
关注 0 Fork 0 Star 1
返回提交历史

XFEstudio/gpt4free

Clean up highlightjs-copy.min.js

504b0dbf
foxfire52 <foxfire52@virgilio.it>
提交于

代码差异

1 个文件 +2 -4
Modified g4f/gui/client/static/js/highlightjs-copy.min.js +2 -4
@@ -26,13 +26,11 @@ class CopyButtonPlugin {
26 26 }
27 27
28 28 try {
29 console.warn("newText type: ", typeof newText);
30 console.warn("Current Text: " + newText);
31 29 await navigator.clipboard.writeText(newText);
32 30 } catch (e) {
33 console.error("Clipboard API writeText failed!!")
34 31 console.error(e);
35 fallback_copy(newText);
32 console.error("Clipboard API writeText() failed! Fallback to document.exec(\"copy\")...");
33 fallback_clipboard(newText);
36 34 }
37 35 button.innerHTML = "Copied!";
38 36 button.dataset.copied = true;