面板关闭外部JS访问权限

This commit is contained in:
example 2019-03-14 18:43:11 +08:00
parent 56ceca56c8
commit c9f06e2167

View File

@ -1,7 +1,7 @@
// ==UserScript==
// @name Translate
// @namespace http://tampermonkey.net/
// @version 4.6
// @version 4.7
// @description 划词翻译调用“金山词霸、有道词典有道翻译、Google Translate谷歌翻译、沪江小D、搜狗翻译、必应词典必应翻译、Microsoft Translator必应在线翻译、海词词典、百度翻译、Oxford Learner's Dictionaries、Oxford Dictionaries、Merriam-Webster、汉典、PDF 划词翻译、Google Search、Bing Search必应搜索、百度搜索、Wikipedia Search维基百科搜索”网页翻译
// @author https://github.com/barrer
// @match http://*/*
@ -381,7 +381,7 @@
var root = document.createElement('div');
document.documentElement.appendChild(root);
var shadow = root.attachShadow({
mode: 'open'
mode: 'closed'
});
// iframe 工具库加入 Shadow
shadow.appendChild(iframe);