// ==UserScript==
// @name 骚扰拦截
// @version 1.3.21
// @namespace airbash/AnnoyancesInterception
// @homepage https://github.com/AirBashX/UserScript
// @author airbash
// @description 手机、电脑全平台通用:自动拦截或删除`下载弹窗`、`悬浮按钮`等影响用户体验的元素;长期维护:CSDN、简书、知乎、百家号、百度贴吧、百度新闻、新浪新闻、腾讯视频、优酷视频、爱奇艺、好看视频、百度搜索、哔哩哔哩、丁香园、微博、新浪财经、抖音、电子发烧友、新京报、观察者网、澎湃新闻、凤凰新闻、网易新闻、虎嗅、虎扑、豆瓣、太平洋电脑、汽车之家、taptap、it之家
// @match *://*.csdn.net/*
// @match *://*.jianshu.com/*
// @match *://juejin.cn/*
// @match *://www.zhihu.com/*
// @match *://zhuanlan.zhihu.com/p/*
// @match *://tieba.baidu.com/*
// @match *://baijiahao.baidu.com/s*
// @match *://mbd.baidu.com/newspage/data/*
// @match *://news.baidu.com/news*
// @match *://m.baidu.com/sf_baijiahao/*
// @match *://xw.qq.com/cmsid/*
// @match *://m.v.qq.com/*
// @match *://*.youku.com/*
// @match *://*.iqiyi.com/*
// @match *://haokan.baidu.com/*
// @match *://m.baidu.com/*
// @match *://*.bilibili.com/*
// @match *://www.bilibili.com/read/mobile*
// @match *://3g.dxy.cn/*
// @match *://m.weibo.cn/*
// @match *://cj.sina.cn/article*
// @match *://*.ixigua.com/*
// @match *://www.douyin.com/*
// @match *://m.elecfans.com/*
// @match *://m.bjnews.com.cn/detail/*
// @match *://*.guancha.cn/*
// @match *://m.thepaper.cn/newsDetail_forward_*
// @match *://*.ifeng.com/*
// @match *://3g.163.com/*/article/*
// @match *://m.huxiu.com/*
// @match *://m.hupu.com/*
// @match *://m.douban.com/movie/subject/*
// @match *://g.pconline.com.cn/*
// @match *://m.zol.com.cn/article/*
// @match *://www.autohome.com.cn/*
// @match *://www.taptap.com/*
// @match *://m.ithome.com/*
// @icon data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAEAAAABACAYAAACqaXHeAAAAAXNSR0IAr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BVKSr+UlYd+CYYM3hx9IcSdAgvmYNanrNs8E+AT+LRwfWVStzU2qc0YUBbZzdJipUpmYPIDaoCXhNERDVG3jilQ9gL5Ao4dnyCvf+PzehuHRSRCZTAU5iB0UdndgH96ur7xI1R/9fQWiwWyCVSagmgDhbk01Q6KECjM8Xu1kahscp7qHAY76fL6QIMFUBlhd7ceDxkg+fnHgyE7aAJshk3o/EDUDFBMO00O3BwkS/JMgcHnwxHxoThelAQNSQCZACIOStOq0sh7Vc5zZa7U5O+gKLAvTbg1HaWXZvrbv/aaOrduB7hWQhEDlfn4a+FDshpWMODNmCoR4NWGUab2zlegbAzK0zjacI6s9l+vL78gm5gjxc1Qx3IhRI7J6uAk5l1DfHwDhB6bCorJ/R8DcY/sPnhur8w41G5MeHMU13nKnAhBmo6Lx1Gky2rb+lcgLiKiLpq6h0LFtM23BGUVVCZIdsG/g5X62eOqpQEOIu6O6QLqs6bhwPTgQbEAISErZFngLHJVFsxEk8xwDzbNWiBagJIJi1Mk++CWqnyn/NgaE+BVySGm5AyTJzBt9pZJpEJpmiDSZU3Bt9VZJFPCr0CpaZPVPqZ3uezabTog87Gr8CNf3qAqc9UaAV4iBrSLgrpMA2NvEBFe66+yG9BDsFgAdf0HqkdRB8dQKoSwMUpdTQEtuzrramvfMFP+DaS5V2w0ayUYskyy8u0Gx9p6ap0Ax/boGx0OtymSMA5kB4+LO+vytG39y12eVhCE6VgxfclfQlybsLPQZG9rfE22MtLOKQEVDJg5ndULawkNaQrVpqDx/XTBjWK48CugR1Bc9K3s/KFC719tSbz8d/4fEkbgH4G71qYAAAAASUVORK5CYII=
// @run-at document-body
// @grant none
// @license GPL-3.0
// ==/UserScript==
(function () {
/**
* 规则列表
* @type {name/url/items}
*/
var websites = [
{
name: "CSDN",
url: "csdn.net",
items: [
//下载弹窗
".weixin-shadowbox",
//悬浮按钮:APP内打开+登录/打开注册(主页)
".feed-Sign-span",
//PC端:弹窗:学生认证
"#csdn-highschool-window",
//PC端:弹窗:登录账号
".passport-login-container",
],
},
{
name: "简书",
url: "jianshu.com",
items: [
//下载弹窗
".download-app-guidance",
//悬浮按钮:打开App,看更多相似好文
".call-app-btn",
//悬浮按钮:打开App,看更多好文(首页)
".index_call-app-btn",
],
overflow: true,
},
{
name: "掘金",
url: "juejin.cn",
items: [
//悬浮按钮:APP内打开
".open-button",
//下载弹窗
".byte-drawer",
//PC端:下方拓展弹窗
".recommend-box",
],
overflow: true,
},
{
name: "知乎",
url: "www.zhihu.com",
items: [
//下载弹窗
".ModalWrap",
//悬浮按钮:App内打开
".OpenInAppButton",
//PC端:发现页登录
".ExploreHomePage-specialsLogin",
],
},
{
name: "知乎专栏",
url: "zhuanlan.zhihu.com/p",
items: [
//悬浮按钮:App内打开
".OpenInAppButton",
],
},
{
name: "百度贴吧",
url: "tieba.baidu.com",
items: [
//悬浮按钮:打开百度贴吧
".nav-bar-bottom",
],
},
{
name: "百家号",
url: "baijiahao.baidu.com/s",
items: [
//下载弹窗
".layer-wrap",
//悬浮按钮:xxx独家语音
".undefined",
],
overflow: true,
},
{
name: "百度资讯",
url: "m.baidu.com/sf_baijiahao",
items: [
//悬浮按钮:xxx独家语音
".undefined",
],
overflow: true,
},
{
//https://mbd.baidu.com/newspage/data/videoshare?nid=sv_7901154226614508362
name: "百度资讯2",
url: "mbd.baidu.com/newspage/data",
items: [
//悬浮按钮:百度APP内播放
".drag-bottom",
],
overflow: true,
},
{
name: "腾讯新闻",
url: "xw.qq.com/cmsid",
items: [
//悬浮按钮:返回首页
".go-home",
],
},
{
name: "腾讯视频",
url: "m.v.qq.com",
items: [
//下载弹窗
".at-app-banner",
//打开APP查看高清内容
".open_app_bottom",
],
},
{
name: "优酷视频",
url: "youku.com",
items: [
//下载弹窗
".callEnd_box",
//悬浮按钮(主页):打开优酷APP更流畅
".callEnd_fixed_box",
//悬浮按钮:打开优酷APP更流畅
".undefined",
//悬浮按钮:红包
".Corner-container",
],
},
{
name: "爱奇艺",
url: "iqiyi.com/",
items: [
//下载弹窗
".m-iqyGuide-layer",
//打开爱奇艺APP,看精彩视频
"[class^=ChannelHomeBanner]",
//PC端:登录提示上侧
".pl__1",
],
},
{
name: "好看视频",
url: "haokan.baidu.com/",
items: [
//悬浮按钮:打开好看app(中间)
".open-app-button",
//固定文字:打开APP(多)
".top-video-card-img-app",
//固定按钮:下载APP(视频播放时)
".video-player-download-tips",
//固定按钮:打开(底部)
".open-app-bottom",
//PC端固定按钮:下载APP(视频暂停时)
".player-pause-code",
//PC端登录提示:登录提示
"#passport-login-pop",
//PC端登录提示:朦胧背板
".pop-mask",
],
},
{
name: "百度搜索",
url: "m.baidu.com",
items: [
//搜索结果:小程序
"[srcid=xcx_multi]",
//搜索结果:百度手机助手
"[srcid=app_mobile_simple]",
//搜索结果:百度手机助手:安全下载
"[srcid=app_mobile_simple_safety]",
//搜索结果:百度应用搜索(IOS)
"[srcid=app_mobile_ios]",
],
},
{
name: "哔哩哔哩",
url: "m.bilibili.com",
items: [
//悬浮按钮:打开app,看你感兴趣的内容(主页)
".m-home-float-openapp",
//悬浮按钮:bilibili内打开
".m-float-openapp",
//悬浮弹窗:打开
".openapp-dialog",
//固定按钮:播放时下载
".mplayer-widescreen-callapp",
//PC端:登录提示(右下角)
".lt-row",
//pc端:播放器登录提示
".bilibili-player-video-toast-bottom",
],
},
{
name: "B站文章",
url: "bilibili.com/read/mobile",
items: [
//悬浮按钮:立即体验
".h5-download-bar",
],
},
{
name: "丁香园",
url: "3g.dxy.cn",
items: [
//悬浮按钮:APP内打开
".wrap",
],
},
{
name: "微博",
url: "m.weibo.cn",
items: [
//悬浮按钮:在微博内打开(百度热议)
".app-btn-box",
//悬浮按钮:登录/注册
".login-btn",
//小程序
".wrap",
],
},
{
//https://cj.sina.cn/articles/view/2949462582/afcd3a36001015zoq
name: "新浪财经",
url: "cj.sina.cn/article",
items: [
//悬浮按钮:打开APP(顶部)
//"#sentiment",
//悬浮按钮:打开APP(底部)
".m-cj-openclient",
//悬浮按钮:去APP听语音播报
".voice2",
//固定按钮:立即体验(底部)
"#norm_qrcode_link_auto",
//固定按钮:打开APP,看最新信息(2)
"[class^=m-hot-subject]",
],
},
{
name: "西瓜视频",
url: "ixigua.com",
items: [
//PC端:登录提示
".loginBenefitNotification",
//悬浮按钮:打开西瓜视频,看全网超清视频
".xigua-download",
],
},
{
name: "抖音电脑版",
url: "www.douyin.com",
items: [
//PC端:右上角登录提示
".login-guide-container",
//PC端:登陆后查看评论
".recommend-comment-login",
],
},
{
name: "电子发烧友",
url: "m.elecfans.com",
items: [
//悬浮按钮:主页右侧
".hm_quick",
//悬浮按钮:登陆/注册
".login-reg-fixed",
//悬浮按钮:上方打开app
".open_app",
],
},
{
name: "新京报",
url: "m.bjnews.com.cn/detail/",
items: [
////悬浮按钮:立即打开(顶部)
".xjb-top",
],
},
{
name: "观察者网",
url: "guancha.cn",
items: [
//固定按钮:点击下载(顶部)
".g_header44",
//悬浮按钮:APP专享(底部)
".g_swiper_container",
],
},
{
name: "澎湃新闻",
url: "m.thepaper.cn/newsDetail_forward_",
items: [
//悬浮按钮:新闻滚条(底部)
".footer_banner",
],
},
{
name: "凤凰新闻",
url: "ifeng.com",
items: [
//固定按钮:立即打开(顶部)
"[class^=header-]",
//固定按钮:今天这条消息99%的人都不知道
"[class^=headerIn-]",
//悬浮按钮:打开(底部)
"[class^=fixBottom-]",
//悬浮按钮:立即打开(主页)
"[class^=fixSlide-]",
],
},
{
//https://3g.163.com/dy/article/HFH8LOBF0552CT1E.html
name: "网易新闻",
url: "3g.163.com",
items: [
//固定按钮:App内打开(底部)
".backflow-floating",
],
},
{
name: "虎嗅",
url: "m.huxiu.com",
items: [
//悬浮按钮:go!(主页)
".guide-wrap",
//悬浮按钮:打开(顶部)
".js-top-fixed",
],
},
{
name: "虎扑",
url: "m.hupu.com",
items: [
//悬浮按钮:App内打开
".open-hupu",
],
},
{
name: "豆瓣",
url: "m.douban.com/movie/subject",
items: [
//固定按钮:用App打开(电影详情页)
".subject-banner",
],
},
//https://g.pconline.com.cn/x/1498/14983204.html
{
name: "太平洋电脑",
url: "g.pconline.com.cn",
items: [
//悬浮按钮:打开app(底部)
".btnForAppOpenImg",
//悬浮按钮:打开知科技App
".btnForAppOpenA",
//固定按钮:立即打开(底部)
".WakeUptop",
],
},
{
name: "中关村在线",
url: "m.zol.com.cn/article/",
items: [
//固定按钮:发评论,赚金豆
".bottom-comment-tip",
],
},
{
name: "汽车之家",
url: "www.autohome.com.cn/",
items: [
//悬浮按钮:登录提示(PC端)
"#loginGuide",
],
},
{
//www.taptap.com
name: "taptap",
url: "www.taptap.com",
items: [
//悬浮按钮:打开taptap
".open-app-button",
//苹果端:悬浮按钮:添加到桌面
".show-add-to-screen",
//苹果端:固定按钮:添加到桌面
".add-to-screen-wrap",
],
overflow: true,
},
{
//https://m.ithome.com/
name: "it之家",
url: "m.ithome.com",
items: [
//固定按钮(底部):立即打开
".open-app-banner",
],
},
];
/**
* 主体部分
*/
for (website of websites) {
if (location.href.indexOf(website.url) != -1) {
//修复移动版页面不允许滑动
if (website.overflow) {
var css = document.createElement("style");
css.innerText = "body{overflow: unset !important}";
document.head.appendChild(css);
}
//隐藏/拦截骚扰元素
for (var item of website.items) {
var css = document.createElement("style");
css.innerText += item + "{display: none !important}";
document.head.appendChild(css);
}
}
}
})();
标签:name,url,items,按钮,骚扰,拦截,com,match
From: https://www.cnblogs.com/leoTsou/p/16660291.html