Updated google translation

This commit is contained in:
Gres 2018-11-29 19:22:51 +03:00
parent a69213c956
commit 49c5659334
2 changed files with 3 additions and 2 deletions

View File

@ -6,7 +6,8 @@ function checkFinished () {
if (!isPageLoaded || !isTranslationFinished || isScheduled) return;
isScheduled = true;
setTimeout(function () {
var spans = [].slice.call (document.querySelectorAll ('#result_box > span'));
var spans = [].slice.call (document.querySelectorAll (
'span.translation > span, #result_box > span'));
var text = spans.reduce (function (res, i) {
return res + ' ' + i.innerText;
}, '');

View File

@ -18,7 +18,7 @@
"path": "translators/bing.js"
},
"Google translator": {
"version": 3,
"version": 4,
"url": "https://raw.githubusercontent.com/OneMoreGres/ScreenTranslator/master/translators/google.js",
"path": "translators/google.js"
},