您需要先安装一个扩展,例如 篡改猴、Greasemonkey 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 Userscripts ,之后才能安装此脚本。
您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。
您需要先安装用户脚本管理器扩展后才能安装此脚本。
press F5
// ==UserScript== // @name Google Translation Formatting // @namespace https://translate.google.cn/* // @version 0.4 // @description press F5 // @author quz // @match https://*translate.google.*/* // @include https://translate.google.* // @grant none // ==/UserScript== (function() { var txt = document.getElementById("source").value; //去除空格 if(txt.indexOf("\n")) { txt = txt.replace(/\n/g," "); } //按句子分段 if(txt.indexOf(".")) { txt = txt.replace(/\. /g,".\n\n"); } document.getElementById("source").value = txt; })();