...
This commit is contained in:
@@ -208,11 +208,13 @@ if (document.querySelector(".show_viewer") !== null) {
|
||||
sendMessage({type: "SHOWVIEWER"});
|
||||
}
|
||||
if(document.querySelector(".list-body") !== null) {
|
||||
removeSpecificGifs()
|
||||
var listBody = null
|
||||
try {listBody = document.querySelector(".list-body");}catch (e) {}
|
||||
getList(listBody.children)
|
||||
}
|
||||
if(document.querySelector("#novel_content") !== null){
|
||||
removeSpecificGifs()
|
||||
var title = null
|
||||
var contents = null
|
||||
try {title = toonTitle(document.querySelector(".page-desc")); }catch (e) {}
|
||||
@@ -236,6 +238,16 @@ if(document.querySelector("#html_encoder_div")) {
|
||||
}
|
||||
);
|
||||
}
|
||||
function removeSpecificGifs() {
|
||||
const images = document.getElementsByTagName('img');
|
||||
for (let i = images.length - 1; i >= 0; i--) {
|
||||
const src = images[i].src;
|
||||
// 요청하신 특정 도메인과 gif 패턴, 쿼리 파라미터를 체크
|
||||
if (src.includes('tokinbtoki') && src.includes('.gif') && src.includes('_=')) {
|
||||
images[i].parentNode.removeChild(images[i]);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
function getList(children) {
|
||||
// port.postMessage("Start of getList!" + children);
|
||||
|
||||
Reference in New Issue
Block a user