Skip to content

Commit ea451db

Browse files
committed
fix
1 parent 9284126 commit ea451db

1 file changed

Lines changed: 10 additions & 6 deletions

File tree

Kill TieBa AD/Kill TieBa AD.user.js

Lines changed: 10 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
// ==UserScript==
22
// @name Kill TieBa AD
3-
// @name:zh-CN 贴吧伪装广告清理
4-
// @name:zh-TW 貼吧僞裝廣告清理
3+
// @name:zh-CN 贴吧广告清理
4+
// @name:zh-TW 貼吧廣告清理
55
// @name:ja 贴吧去广告
66
// @namespace hoothin
7-
// @version 0.53
7+
// @version 1.0
88
// @description Just Kill TieBa AD
9-
// @description:zh-CN 清理AdBlock或uBlock Origin等未能清理掉的百度贴吧列表伪装广告、帖内伪装广告与推荐应用广告
10-
// @description:zh-TW 清理AdBlock或uBlock Origin等未能清理掉的百度貼吧列表偽裝廣告、帖內偽裝廣告與推薦應用廣告
11-
// @description:ja 去除AdBlock或uBlock Origin等未能清理掉的百度贴吧列表伪装广告、帖内伪装广告与推荐应用广告
9+
// @description:zh-CN 清理adb等未能清理掉的百度贴吧(tieba.baidu.com)广告
10+
// @description:zh-TW 清理adb等未能清理掉的百度貼吧(tieba.baidu.com)廣告
11+
// @description:ja 去除adb等未能清理掉的百度贴吧(tieba.baidu.com)广告
1212
// @author hoothin
1313
// @include http*://tieba.baidu.com/*
1414
// @grant none
@@ -83,6 +83,10 @@
8383
delList.push(previousSibling);
8484
}else{
8585
if(thread.getAttribute && thread.getAttribute("data-field")){
86+
var tpointTagType=thread.querySelector(".tpoint-tag-type");
87+
if(tpointTagType && tpointTagType.innerHTML.indexOf("广告") != -1)delList.push(thread);
88+
let tdata=JSON.parse(thread.getAttribute("data-field")),pContent=thread.querySelector(".p_content_fix");
89+
if(tdata.content && tdata.content.pb_tpoint && tdata.content.pb_tpoint.is_tpoint==1 && pContent)pContent.classList.remove("p_content_fix");
8690
}else{
8791
if(thread.classList && thread.classList.length==2){
8892
delList.push(thread);

0 commit comments

Comments
 (0)