Skip to content

Instantly share code, notes, and snippets.

@blueset

blueset/script.js

Created May 2, 2015
Embed
What would you like to do?
Netease LRC Translate Extractor 网易云音乐翻译提取脚本
/*
使用方法:
在浏览器中打开JS终端,作用范围定位到contentFrame。
将divider改成区分翻译的符号。
然后将以下代码粘贴执行。
协议:MIT
*/
var divider = " / ";
list = document.querySelectorAll("textarea");
for (i = 0; i < list.length; i++){
b = list[i].parentNode.parentNode.querySelector(".prim");
if (b.innerText.indexOf(divider) > 0)
list[i].innerText = b.innerText.substr(b.innerText.indexOf(divider)+divider.length);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment