From 9c1e03ab26ed5b4d2889d61670d67246f3e29753 Mon Sep 17 00:00:00 2001 From: example Date: Fri, 17 May 2019 11:07:56 +0800 Subject: [PATCH] =?UTF-8?q?=E7=BF=BB=E8=AF=91=E5=9B=BE=E6=A0=87=E4=BD=8D?= =?UTF-8?q?=E7=BD=AE=E8=BD=BB=E5=BE=AE=E8=B0=83=E6=95=B4=EF=BC=8C=E5=87=8F?= =?UTF-8?q?=E5=B0=91=E7=82=B9=E5=87=BB=E8=90=BD=E7=A9=BA=E6=A6=82=E7=8E=87?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- translate/translate-dictionary.js | 6 +++--- translate/translate.js | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/translate/translate-dictionary.js b/translate/translate-dictionary.js index 1d86037..b4788db 100644 --- a/translate/translate-dictionary.js +++ b/translate/translate-dictionary.js @@ -1,7 +1,7 @@ // ==UserScript== // @name 划词翻译:多词典查询 // @namespace http://tampermonkey.net/ -// @version 5.1 +// @version 5.2 // @description 划词翻译调用“有道词典(有道翻译)、金山词霸、Bing 词典(必应词典)、剑桥高阶、沪江小D、谷歌翻译” // @author https://github.com/barrer // @match http://*/* @@ -379,8 +379,8 @@ if (selected && icon.style.display == 'none') { // 显示翻译图标 log('show icon'); log(selected + ' | ' + e.pageX + ' | ' + e.pageY); - icon.style.top = e.pageY + 10 + 'px'; - icon.style.left = e.pageX + 10 + 'px'; + icon.style.top = e.pageY + 8 + 'px'; + icon.style.left = e.pageX + 4 + 'px'; icon.style.display = 'block'; // 兼容部分 Content Security Policy icon.style.position = 'absolute'; diff --git a/translate/translate.js b/translate/translate.js index b9ab769..143038b 100644 --- a/translate/translate.js +++ b/translate/translate.js @@ -1,7 +1,7 @@ // ==UserScript== // @name Translate // @namespace http://tampermonkey.net/ -// @version 5.8 +// @version 5.9 // @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://*/* @@ -433,8 +433,8 @@ if (text && icon.style.display == 'none') { log('show icon'); log(text + ' | ' + e.pageX + ' | ' + e.pageY); - icon.style.top = e.pageY + 10 + 'px'; - icon.style.left = e.pageX + 10 + 'px'; + icon.style.top = e.pageY + 8 + 'px'; + icon.style.left = e.pageX + 4 + 'px'; icon.style.display = 'block'; // 兼容部分 Content Security Policy icon.style.position = 'absolute';