Skip to content

Commit 456a913

Browse files
committed
优化 规则
1 parent a21badc commit 456a913

1 file changed

Lines changed: 32 additions & 4 deletions

File tree

Autopage.user.js

Lines changed: 32 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
// ==UserScript==
22
// @name 自动无缝翻页
3-
// @version 3.5.2
3+
// @version 3.5.3
44
// @author X.I.U
55
// @description 无缝拼接下一页内容(瀑布流),目前支持:[所有「Discuz!、Flarum、phpBB、Xiuno、XenForo、DUX/XIU/D8/Begin(WP主题)」网站]、百度、谷歌、必应、搜狗、头条搜索、360 搜索、微信搜索、贴吧、豆瓣、微博、NGA、V2EX、B 站(Bilibili)、蓝奏云、煎蛋网、糗事百科、龙的天空、起点小说、IT之家、千图网、Pixabay、3DM、游侠网、游民星空、NexusMods、Steam 创意工坊、CS.RIN.RU、片库、茶杯狐、NO视频、低端影视、奈菲影视、音范丝、BT之家、萌番组、动漫花园、樱花动漫、爱恋动漫、AGE 动漫、Nyaa、SrkBT、RARBG、SubHD、423Down、不死鸟、扩展迷、极简插件、小众软件、动漫狂、漫画猫、漫画 DB、动漫之家、拷贝漫画、包子漫画、古风漫画网、Mangabz、PubMed、GreasyFork、Github、StackOverflow(以上仅一小部分,更多的写不下了...
66
// @match *://*/*
@@ -99,6 +99,7 @@
9999
insertE: 插入元素的函数
100100
5 = 插入 iframe 方式来加载下一页
101101
insStyle: 加载 iframe 前要插入的 CSS Style 样式
102+
iframe: 这个必须加到 page{} 外面
102103
nextL: 下一页链接所在元素
103104
pageE: 要获取的主体内容
104105
insertP: 主体内容插入的位置
@@ -1312,6 +1313,17 @@
13121313
scrollD: 1500
13131314
}
13141315
}, // IT 之家
1316+
/*pixiv: {
1317+
host: 'www.pixiv.net',
1318+
functionStart: function() {if (location.pathname.indexOf('/tags/') > -1) {curSite = DBSite.pixiv;}},
1319+
hiddenPN: true,
1320+
iframe: true,
1321+
pager: {
1322+
type: 5,
1323+
nextL: '//a[@aria-disabled="false"][contains(@class, "filterProps-Styled-Component")][@href][last()]',
1324+
scrollD: 2500
1325+
}
1326+
},*/ // Pixiv
13151327
_58pic: {
13161328
host: 'www.58pic.com',
13171329
functionStart: function() {insStyle('.qt-model-t, .qtw-card.place-box.is-one, .search-v3-row .search-v3-back {display: none !important;}'); // 隐藏登录弹窗
@@ -2303,18 +2315,22 @@
23032315
scrollD: 900
23042316
}
23052317
}, // SkrBT
2306-
rarbgprx: {
2318+
rarbg: {
23072319
host: /rarbg/,
2308-
functionStart: function() {if (location.pathname === '/torrents.php') {curSite = DBSite.rarbgprx;}},
2320+
functionStart: function() {if (location.pathname === '/torrents.php') {curSite = DBSite.rarbg; rarbg_bF(getAllCSS('table.lista2t tr.lista2'));}},
2321+
insStyle: 'html::-webkit-scrollbar {height: 0 !important;}',
23092322
pager: {
23102323
type: 1,
23112324
nextL: 'css;#pager_links > a[title="next page"]',
23122325
pageE: 'css;table.lista2t tr.lista2',
23132326
insertP: ['css;table.lista2t > tbody', 3],
23142327
replaceE: 'css;#pager_links',
23152328
scrollD: 1000
2329+
},
2330+
function: {
2331+
bF: rarbg_bF
23162332
}
2317-
}, // RARBG
2333+
}, // RARBG
23182334
subdh: {
23192335
host: 'subdh.com',
23202336
functionStart: function() {if (location.pathname === '/' || location.pathname.indexOf('/list/new') > -1) {
@@ -5179,6 +5195,18 @@
51795195
}
51805196

51815197

5198+
// [RARBG] 的插入前函数(鼠标指向显示封面)
5199+
function rarbg_bF(pageElems) {
5200+
pageElems.forEach(function (one) {
5201+
one.querySelectorAll('td > a[onmouseover][onmouseout]').forEach(function (now) {
5202+
now.parentElement.parentElement.setAttribute('onmouseover', now.getAttribute('onmouseover')); now.removeAttribute('onmouseover');
5203+
now.parentElement.parentElement.setAttribute('onmouseout', now.getAttribute('onmouseout')); now.removeAttribute('onmouseout');
5204+
});
5205+
});
5206+
return pageElems
5207+
}
5208+
5209+
51825210
// [LRepacks] 的插入前函数(调整 class)
51835211
function lrepacks_bF(pageElems) {
51845212
pageElems.forEach(function (one) {

0 commit comments

Comments
 (0)