自动无缝翻页

无缝拼接下一页内容(瀑布流,追求小而精),目前支持:[所有「Discuz!、Flarum、phpBB、Xiuno、XenForo、NexusPHP、DUX/XIU/D8/Begin(WP主题)」网站]、百度、谷歌、必应、搜狗、头条搜索、360 搜索、微信搜索、贴吧、豆瓣、知乎、微博、NGA、V2EX、B 站(Bilibili)、Pixiv、煎蛋网、糗事百科、龙的天空、起点中文、IT之家、千图网、Pixabay、3DM、游侠网、游民星空、NexusMods、Steam 创意工坊、CS.RIN.RU、茶杯狐、NO视频、低端影视、奈菲影视、音范丝、BT之家、萌番组、动漫花园、樱花动漫、爱恋动漫、AGE 动漫、Nyaa、SrkBT、RARBG、SubHD、423Down、不死鸟、扩展迷、小众软件、动漫狂、漫画猫、漫画 DB、动漫之家、拷贝漫画、包子漫画、Mangabz、PubMed、GreasyFork、Github、StackOverflow(以上仅一小部分,更多的写不下了...

当前为 2022-02-18 提交的版本,查看 最新版本

  1. // ==UserScript==
  2. // @name 自动无缝翻页
  3. // @name:en AutoPager
  4. // @name:zh-CN 自动无缝翻页
  5. // @name:zh-TW 自動無縫翻頁
  6. // @version 4.7.4
  7. // @author X.I.U
  8. // @description 无缝拼接下一页内容(瀑布流,追求小而精),目前支持:[所有「Discuz!、Flarum、phpBB、Xiuno、XenForo、NexusPHP、DUX/XIU/D8/Begin(WP主题)」网站]、百度、谷歌、必应、搜狗、头条搜索、360 搜索、微信搜索、贴吧、豆瓣、知乎、微博、NGA、V2EX、B 站(Bilibili)、Pixiv、煎蛋网、糗事百科、龙的天空、起点中文、IT之家、千图网、Pixabay、3DM、游侠网、游民星空、NexusMods、Steam 创意工坊、CS.RIN.RU、茶杯狐、NO视频、低端影视、奈菲影视、音范丝、BT之家、萌番组、动漫花园、樱花动漫、爱恋动漫、AGE 动漫、Nyaa、SrkBT、RARBG、SubHD、423Down、不死鸟、扩展迷、小众软件、动漫狂、漫画猫、漫画 DB、动漫之家、拷贝漫画、包子漫画、Mangabz、PubMed、GreasyFork、Github、StackOverflow(以上仅一小部分,更多的写不下了...
  9. // @description:en Seamlessly stitch next page content (waterfall)
  10. // @description:zh-CN 无缝拼接下一页内容(瀑布流,追求小而精),目前支持:[所有「Discuz!、Flarum、phpBB、Xiuno、XenForo、NexusPHP、DUX/XIU/D8/Begin(WP主题)」网站]、百度、谷歌、必应、搜狗、头条搜索、360 搜索、微信搜索、贴吧、豆瓣、知乎、微博、NGA、V2EX、B 站(Bilibili)、Pixiv、煎蛋网、糗事百科、龙的天空、起点中文、IT之家、千图网、Pixabay、3DM、游侠网、游民星空、NexusMods、Steam 创意工坊、CS.RIN.RU、茶杯狐、NO视频、低端影视、奈菲影视、音范丝、BT之家、萌番组、动漫花园、樱花动漫、爱恋动漫、AGE 动漫、Nyaa、SrkBT、RARBG、SubHD、423Down、不死鸟、扩展迷、小众软件、动漫狂、漫画猫、漫画 DB、动漫之家、拷贝漫画、包子漫画、Mangabz、PubMed、GreasyFork、Github、StackOverflow(以上仅一小部分,更多的写不下了...
  11. // @description:zh-TW 無縫拼接下一頁內容(瀑布流,追求小而精)
  12. // @match *://*/*
  13. // @connect www.ykmh.com
  14. // @connect www.xuexiniu.com
  15. // @connect bbs.xuexiniu.com
  16. // @connect www.tujigu.net
  17. // @connect weili.ooopic.com
  18. // @icon data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAALfElEQVRYhX2Xe3Bd1XXGf3vvc859X+nq6nUlW5Yly7JlI2xsYzAwtnk4ATpAxkNTHm0mnaTT/gHTTvrIBDLTpp1JUoZppqHQls5AKTR2INOWJJQSXF4x2BhsJCRZ8kuWZckPSVf3/Trn7N3RVTFpQrNn1l97n7O/vda31reWMKMPcmUJA9U8vrwHGdqCHn4HPzePaIxhVSoYbYRXrn7BeMVbCUduF6kVUXHwvQP+6amDaqDnoIompmQytaBnTmB8H5lowrjgFss48SBeI/hUEEZeudLi1ywhJEIJdL6Q8rzal/1a5SGC4XZrYBvWwEZobMdLdH6RH+z/Io1taEeh52fe8tOZbysl/ouWFvANYP7fSz4DgAEBBIL4xiS8ubmnVcTZK68aRK29Dtm8dgnZJydRW+/E2nrnp19nz+7U77+60zt0qMz07J/KxuQTwrIw4rMBCDP6wC+FIIcO34eudDdXf/7jD52Opi772lugY3AZr++hp06gz48j+waRqTWYmVHcS+chEMFeuw1hBzBzY7g/fQE9fmqBYPzBQKrpVa/R4OkCAnXlSvXnX9sIllk220BE4Z8OdHoj54YCK6Od1i2/iUmuRyDRk6NUn3+M0pv/hnf0AE40jEjEqP3oe6Rf/CGOWUTNjFKby2MP7EBtugURFWFxfOhB4+o4yfhrGAdZsxHaqZt6dNce9KXYFSPfGWS68JFqTXSqO7+MCaTqETGTwxSeeoRCOoPT2YUIhFC2jbQF/uwUatU6rPbVUM5T+OfHUO3dWKv6kSsGUIOD6PEPr+fswnanpecFZYVQhFAyjPS9Tj4xw2rcU+pJApEutWsvRjaBW8NUShilkE1JIqlUPfi6VMLNFTBVr+7KYKqJ8uEjlM+dJrR5K0L7eB+9hTd2CFrWYt33h0jH3O5Nj37TBGtgZUBkUN/6q4dQ7UmsnlW450//gU5PPRq460uQXAu+j//i99A/+UdUMoXqbMNkz2OnUkixlF4u9spe/HMTULyEaA7jXkoT2fEbQIXi838DJ4cRDXHkEjc2b0MPHdptZubGpBUbM0UfKQpBRDmKWRSD3tTMk87gddA2WGe4+dkzMD0CyQ5qP/4XVDCAvfkaLMvHamzEClpQzGDF46iuJOH1CaKr2tDZRfzhQ0Ru24NYsYrCM4/jDb+FiHdi3XU/0s3vr7WsGKxcfyPSy+bxi0UqJ8f/IriiE2vrnuWsLefQk8NoO4AMBBB9/XjDI6hQCjdTxq9WCaQ6ULaDFrIeKr3oIlv70Olz2K1xlAVaSUQojD786nKi9e5A3LBHMHn0W+LUUaS1FI9q+iZZWLhHdq/FxFbWSSfsIDIQwVw4g/GK2OuuhloNMzaCaF+DNBJtQfX8LFYigElX0OkQtZKHVy3jqwDlqWncCzPI3nU4t+2FWrH+OLHzHpRl3109memTOhqDi9NfkefHEKvWLTO+VKD68Qf4G27CueFWhJ/Df+0lVFcXJOJYnobm1ZjsJUxuFjyDjK/GNK2gND4ESuDPXcCOSaI7thPqX0ft8OtUn/oTKOQgkET39KJU4RbpZXOtNRW717p+FyRSdYT+v36H4u/fQXbfc3iRDkT3FsTGjWAWEU0OZKfAU9CyEdXVD2lQPduplmo4jkBEbMzK1VgDu5EVTe3gm1RHx6Bcxpz6YLkEO0lMYeFGi6z7eVMqhkT/ZrCb0LNT+NMTRH/nt/BLRdy3X8Nv68Lu6cZEHURjE6K3hirYeLRhDWyA4jxzH40RXJwkeuM29MpN+JcziEsz+Avz6GgcW1pYbUlEQCyHwYpSyxS7rGo+v8man4ZMATrAHf+QSt7FTkWR4QbsjlbIX8IMH0VuuAqj4piGAbhmEPPzI/injnNxMUPuwOtseOIxKKTJ7/8BTBxDdXcjO9sJdTeg01VqH4wg3CDB9bshHMKORbGolVOmeRW09dVdUxkbp3ruNM7GXnS1hK5OYSoSbBDZBcxCBtF3DcUzk6hkhGA0RmtHKx1rOkE04lbzWC1tqMRt1CZHUafPIs8H6/JsNTcgN+9YFq1qgbBUFUvnK9qrVghXCvWN8MBmivueJDtylqaeBKWJaXR4JZEtNyBWrkGt6AJboCZO4J49Rc64xGIhcgtZgm6egKhgtUQQto17WeHOLqCNj5Vowbr7q4j+Lcs1JhhEphcXLTebd0jPwpkx6Lwa++bbCR95ALecp5a6BrvrJoLdHajmMOTnKb3+BrVMntjARpzeFbz8jcfpa22gGm+kMJlm95Zu9M9+iI5G0G3d6EgIUSnjzs/gv/Icgd6rqcvz0IeYWnXc8pEtYnEe8gtXNL7xz74LehHSE3DqNP7EIdx3p5DSh7JNJePiBE/gN3Uz8NWHae5sRJYXqKQvU+raQPg7L6L3/QNMHcfp6EREGjC5LDp9GaOs5VQ/NQI93YctOxFPlwniDh/C3n47JHvrQPTBl3DHjiIDQUQ4jGhOYcqaQFuE0Nl53OnLRHfsZV33KsTxd6GlHeaP477zMl5uAWv7dkyLg6kZREsb+vgCcvPOuoaYuWNQWERs3jAuQ6nooXK6TH566cXnrjQK7uwFaoseWA3oJf2WEhEJUjm/gMgXCfdvQlFFv/R3uCND6FIRv7MfMnOIiaPoI/8NEb2kWAhfoLbdjLr2jmUv/8f+pVbkHRGNnZHum2/udxxtCn4j/vgEIjNTD4O9upfIprUYoxBKo9Z14jumTq7YYD9WayvuR++hs1lkshmha4iuNeDYiIAFMoCevIi+cJHaa29gmvsRTUn0R29g9u1D7bxxv+jrRnpD56cCkdjfV9NzpA+8A5VlLojWAczlGVTAYKXimIU8MlsjtKEXgiF0aRGdm8cEYnXm+O+/gdAGuWsP3shhTHoOEYqCCEF2DsrF5f+e/xiikUldrT6l3z+GevSaTahaZdRY6uFqxRXR1sRyzU/21Gu6OTOMfzmPd6kI8TgiX8B4imouj1QCKmVUNITJ59AnR1F77kH4ZaRnQFroMyeRW3egdt6DwIX391Gshv+4LK2jtcuLqK9t7ALjZXzH1uVM/mb/7BTRnjZEex+idQ2EAnjjR/BdF1PIoV2Bae/F/fh9dL5IYE0XUmpMNo+ev4AINSJWb0UPHa63Z7SvRN3/CHJpFHj2G4iZzAuBbTu+GWpIEGxrQ/3RnlvxG5M4kYa3Lc2u4uyFblnIE+xfAbF2RMtqZGsn/uTYUgHH+dz9eFMnqYx8gO+CEwkjhcDPF/DLHurSaeTm3RiWMsDHeuDrSFvBv3+bi08+N1Vwuj/vZWtu+dwclZlFrESoeZmZysJXoTsCjnVk8dDQBuN+n8RDD9fbcdG7leBX1iOkQjhBOHmQfKGAHW3CS6fR+QClmYuYMyPY265DtPVgtfctiw4V/GcfYfGNQzj3/u4DqlormUoZEQwuc0I//eSnY4G0wPJjmdGhw+mh0fWxNZ0037cXccPd1MXgk+GjNE/tR3+Le+YEyg5TnT6LXlwgcu1u7C99HZlsv3K2+vjvkTs2RvDe3747tm7Dy1SKvzSYPP/MLwxFAkIKEzEye2zswOXX395lJyK0fOFzRHfuglQfqPin59Nn0RNDuJk09vprkd0brmx5H7xCbfgQbrZ83OkfvN1pj0+ZmkBYNhjzCwCeffr/AsBDJyU6kqBwbPzRuTcP/GXV82lYlaJpfQ+BjVdhXX0tNKTAjvzKqKXPTeC++1NKY0c9kVz1SGzb9X8tjIdfzSFCDfUw/noA0scPuxBrwcvmmH3rQIvMm3/y0XdJS4JfIpiIUG9g+wcg6KDnZpGZNDQ0Ii5cSAtlPRHYct13axWvJNwadiiAli4iEP8VAJ89HQtR129TLiG1nos0Nt8dSOi12qi9lRq3utVqT/lirql24hW3vLBQi3d3XUqu73+PZOonBNR/WnbYSMeGTO5/Xf6ZtwDwPwtFRezQVs+sAAAAAElFTkSuQmCC
  19. // @grant GM_xmlhttpRequest
  20. // @grant GM_registerMenuCommand
  21. // @grant GM_unregisterMenuCommand
  22. // @grant GM_openInTab
  23. // @grant GM_getValue
  24. // @grant GM_setValue
  25. // @grant GM_notification
  26. // @grant window.onurlchange
  27. // @grant unsafeWindow
  28. // @license GPL-3.0 License
  29. // @run-at document-end
  30. // @namespace https://github.com/XIU2/UserScript
  31. // @supportURL https://github.com/XIU2/UserScript
  32. // @homepageURL https://github.com/XIU2/UserScript
  33. // ==/UserScript==
  34.  
  35. (function() {
  36. 'use strict';
  37. var menuAll = [
  38. ['menu_disable', '✅ 已启用 (点击对当前网站禁用)', '❌ 已禁用 (点击对当前网站启用)', []],
  39. ['menu_thread', '帖子内自动翻页 (社区类网站)', '帖子内自动翻页 (社区类网站)', true],
  40. ['menu_page_number', '显示当前页码及点击暂停翻页', '显示当前页码及点击暂停翻页', true],
  41. ['menu_pause_page', '左键双击网页空白处暂停翻页', '左键双击网页空白处暂停翻页', false]
  42. ], menuId = [], webType = 0, curSite = {SiteTypeID: 0}, DBSite, SiteType, pausePage = true, pageNum = {now: 1, _now: 1}, locationC = false, nowLocation = '', lp = location.pathname;
  43.  
  44. for (let i=0;i<menuAll.length;i++){ // 如果读取到的值为 null 就写入默认值
  45. if (GM_getValue(menuAll[i][0]) == null){GM_setValue(menuAll[i][0], menuAll[i][3])};
  46. }
  47. registerMenuCommand();
  48. if (menuId.length < 2) {return}
  49. // 注册脚本菜单
  50. function registerMenuCommand() {
  51. if (menuId.length != []){
  52. for (let i=0;i<menuId.length;i++){
  53. GM_unregisterMenuCommand(menuId[i]);
  54. }
  55. }
  56. for (let i=0;i<menuAll.length;i++) { // 循环注册脚本菜单
  57. menuAll[i][3] = GM_getValue(menuAll[i][0]);
  58.  
  59. if (menuAll[i][0] === 'menu_disable') { // 启用/禁用
  60.  
  61. if (menu_disable('check')) { // 当前网站在禁用列表中
  62. menuId[i] = GM_registerMenuCommand(`${menuAll[i][2]}`, function(){menu_disable('del')});
  63. return
  64. } else { // 不在禁用列表中
  65. webType = doesItSupport(); // 判断网站类型(即是否支持),顺便直接赋值
  66. if (webType === 0) {
  67. GM_registerMenuCommand('❌ 当前网站暂不支持 [点击申请支持]', function () {window.GM_openInTab('https://github.com/XIU2/UserScript#xiu2userscript', {active: true,insert: true,setParent: true});window.GM_openInTab('https://greasyfork.org/zh-CN/scripts/419215/feedback', {active: true,insert: true,setParent: true});});
  68. console.info('[自动无缝翻页] - 不支持当前网站 [ ' + location.href + ' ],欢迎申请支持: https://github.com/XIU2/UserScript / https://greasyfork.org/zh-CN/scripts/96880/feedback');
  69. return
  70. } else if (webType === -1) {
  71. return
  72. }
  73. menuId[i] = GM_registerMenuCommand(`${menuAll[i][1]}`, function(){menu_disable('add')});
  74. }
  75.  
  76. } else {
  77. menuId[i] = GM_registerMenuCommand(`${menuAll[i][3]?'✅':'❌'} ${menuAll[i][1]}`, function(){menu_switch(menuAll[i][3], menuAll[i][0], menuAll[i][2])});
  78. }
  79. }
  80. menuId[menuId.length] = GM_registerMenuCommand('💬 反馈 & 欢迎申请支持', function () {window.GM_openInTab('https://github.com/XIU2/UserScript#xiu2userscript', {active: true,insert: true,setParent: true});window.GM_openInTab('https://greasyfork.org/zh-CN/scripts/419215/feedback', {active: true,insert: true,setParent: true});});
  81. }
  82.  
  83. // 网站规则
  84. function setDBSite() {
  85. /*
  86. functionS: 匹配该网站域名时要执行的函数(一般用于根据 URL 分配相应翻页规则)
  87. locationC: 对于使用 pjax 技术的网站,需要监听 URL 变化来重新判断翻页规则(需要放在 functionS 中)
  88.  
  89. hiddenPN: 不显示脚本左下角的页码
  90. history: 添加历史记录 并 修改当前 URL(默认开启,对于不支持的网站要设置为 false)
  91. style: 要插入网页的 CSS Style 样式
  92. retry: 允许获取失败后重试
  93.  
  94. pager: {
  95. type: 翻页模式
  96. 1 = 由脚本实现自动无缝翻页(适用于:静态加载内容网站,常规模式)
  97.  
  98. 2 = 只需要点击下一页按钮(适用于:网站自带了 自动无缝翻页 功能)
  99. nextText: 按钮文本,当按钮文本 = 该文本时,才会点击按钮加载下一页(避免一瞬间加载太多次下一页,下同)
  100. nextTextOf: 按钮文本的一部分,当按钮文本包含该文本时,才会点击按钮加载下一页
  101. nextHTML: 按钮内元素,当按钮内元素 = 该元素内容时,才会点击按钮加载下一页
  102. interval: 点击间隔时间,对于没有按钮文字变化的按钮,可以手动指定间隔时间(单位 ms,默认 300,当指定上面三个时,会忽略 interval)
  103. isHidden: 只有下一页按钮可见时(没有被隐藏),才会点击
  104.  
  105. 3 = 依靠 [基准元素] 与 [浏览器可视区域底部] 之间的距离缩小来触发翻页(适用于:主体元素下方内容太多 且 高度不固定时)
  106. scrollE: 作为基准线的元素(一般为底部页码元素)
  107. scrollD: 基准元素 - 可视区域底部
  108.  
  109. 4 = 动态加载类网站(适用于:简单的动态加载内容网站)
  110. insertE: 用来插入元素的函数
  111.  
  112. 5 = 插入 iframe 方式来加载下一页,无限套娃(适用于:部分动态加载内容的网站,需要允许 iframe 且支持通过 GET/POST 直接打开下一页)
  113. style: 加载 iframe 前要插入的 CSS Style 样式(比如为了悬浮的样式与下一页的重叠,隐藏网页底部间距提高阅读连续性)
  114. iframe: 这个必须加到 pager{} 外面(这样才会在该域名的 iframe 框架下运行脚本)
  115. forceTarget: 强制新标签页打开链接(适用于一些使用 pjax 技术的链接)
  116.  
  117. 6 = 通过 iframe 获取下一页动态加载内容插入本页,只有一个娃(适用于:部分动态加载内容的网站,与上面不同的是,该模式适合简单的网页,没有复杂事件什么的)
  118. loadTime: 预留的网页加载时间,确保网页内容加载完成
  119. forceTarget: 强制新标签页打开链接
  120.  
  121. nextL: 下一页链接所在元素
  122. pageE: 要从下一页获取的元素
  123. insertP: 下一页元素插入本页的位置(数组第一个是基准元素,第二个是基准元素的前后具体位置)
  124. 1 = 插入基准元素自身的前面
  125. 2 = 插入基准元素内,第一个子元素前面
  126. 3 = 插入基准元素内,最后一个子元素后面
  127. 4 = 插入基准元素自身的后面
  128. 5 = 插入 pageE 列表最后一个元素的后面(该 insertP 可以直接省略不写,等同于 ['pageE', 5] )
  129. 6 = 插入该元素自身内部末尾(针对小说网站等文本类的),附带参数 insertP6Br: true, 用来中间插入换行
  130. // 小技巧:当基准元素是下一页主体元素的父元素时(或者说要将下一页元素插入到本页同元素最后一个后面时)是可以省略不写 insertP
  131. 例如:当 pageE: 'css;ul>li' 且 insertP: ['css;ul', 3] 时,实际等同于 ['css;ul>li', 5]
  132. 当 pageE: 'css;.item' 且 insertP: ['css;.item', 4] 时,实际等同于 ['css;.item', 5]
  133. 当 pageE: 'css;.item' 且 insertP: ['css;.page', 1] 时,实际等同于 ['css;.item', 5]
  134. 注意:如 pageE 中选择了多类元素,则不能省略 insertP(比如包含 `,` 与 `|` 符号)
  135.  
  136. replaceE: 要替换为下一页内容的元素(比如页码)
  137. scrollD: 翻页动作触发点([滚动条] 与 [网页底部] 之间的距离),数值越大,越早开始翻页,一般是访问网页速度越慢,该值就需要越大
  138.  
  139. scriptT: 单独插入 <script> 标签
  140. 0 = 下一页的所有 <script> 标签
  141. 1 = 下一页的所有 <script> 标签(不包括 src 链接)
  142. 2 = 下一页主体元素 (pageE) 的同级 <script> 标签
  143. 3 = 下一页主体元素 (pageE) 的子元素 <script> 标签
  144.  
  145. interval: 翻页后间隔时间(单位 ms)
  146. forceHTTPS: 下一页链接强制 HTTPS
  147. },
  148. function: {
  149. bF = 插入前执行函数
  150. aF = 插入后执行函数
  151. pF = 参数
  152. }
  153. */ //<<< 规则简单说明 >>>
  154. DBSite = {
  155. discuz_forum: {
  156. pager: {
  157. type: 2,
  158. nextL: 'css;#autopbn',
  159. nextTextOf: '下一页',
  160. scrollD: 1500
  161. }
  162. }, // Discuz! 论坛 - 帖子列表(自带无缝加载下一页按钮的)
  163. discuz_guide: {
  164. pager: {
  165. type: 1,
  166. nextL: 'css;a.nxt:not([href^="javascript"]) ,a.next:not([href^="javascript"])',
  167. pageE: 'id("threadlist")//table[./tbody[contains(@id, "normalthread_")]]/tbody[not(@id="separatorline")]',
  168. replaceE: 'css;.pg, .pages',
  169. scrollD: 1500
  170. }
  171. }, // Discuz! 论坛 - 导读页 及 帖子列表(不带无缝加载下一页按钮的)
  172. discuz_waterfall: {
  173. pager: {
  174. type: 1,
  175. nextL: 'css;a.nxt:not([href^="javascript"]) ,a.next:not([href^="javascript"])',
  176. pageE: 'css;#waterfall > li',
  177. replaceE: 'css;.pg, .pages',
  178. scrollD: 1500
  179. }
  180. }, // Discuz! 论坛 - 图片模式的帖子列表(不带无缝加载下一页按钮的)
  181. discuz_thread: {
  182. style: '.pgbtn {display: none;}',
  183. pager: {
  184. type: 1,
  185. nextL: 'css;a.nxt:not([href^="javascript"]) ,a.next:not([href^="javascript"])',
  186. pageE: 'css;#postlist > div[id^="post_"]',
  187. replaceE: '//div[contains(@class,"pg") or contains(@class,"pages")][./a[contains(@class,"nxt") or contains(@class,"next") or contains(@class,"prev")][not(contains(@href,"javascript") or contains(@href,"commentmore"))]]',
  188. scrollD: 1500
  189. },
  190. function: {
  191. bF: src_bF,
  192. pF: [0, 'img[file]', 'file']
  193. }
  194. }, // Discuz! 论坛 - 帖子内
  195. discuz_search: {
  196. pager: {
  197. type: 1,
  198. nextL: 'css;a.nxt:not([href^="javascript"]) ,a.next:not([href^="javascript"])',
  199. pageE: 'css;#threadlist > ul',
  200. replaceE: 'css;.pg, .pages',
  201. scrollD: 1500
  202. }
  203. }, // Discuz! 论坛 - 搜索页
  204. discuz_youspace: {
  205. pager: {
  206. type: 1,
  207. nextL: 'css;a.nxt:not([href^="javascript"]) ,a.next:not([href^="javascript"])',
  208. pageE: 'css;form:not([action^="search.php?"]) tbody > tr:not(.th)',
  209. replaceE: 'css;.pg, .pages',
  210. scrollD: 1500
  211. }
  212. }, // Discuz! 论坛 - 回复页、主题页(别人的)
  213. discuz_collection: {
  214. pager: {
  215. type: 1,
  216. nextL: 'css;a.nxt:not([href^="javascript"]) ,a.next:not([href^="javascript"])',
  217. pageE: 'css;#ct .bm_c table > tbody',
  218. replaceE: 'css;.pg, .pages',
  219. scrollD: 1500
  220. }
  221. }, // Discuz! 论坛 - 淘帖页
  222. flarum: {
  223. functionS: function() {locationC = true;if (!indexOF('/d/')) {curSite = DBSite.flarum;}},
  224. pager: {
  225. type: 2,
  226. nextL: 'css;.DiscussionList-loadMore > button',
  227. isHidden: true,
  228. scrollD: 1500
  229. }
  230. }, // Flarum 论坛
  231. phpbb: {
  232. functionS: function() {if (indexOF('/viewforum.php')) {
  233. curSite = DBSite.phpbb;
  234. } else if (indexOF('/viewtopic.php') && GM_getValue('menu_thread')) {
  235. curSite = DBSite.phpbb_post;
  236. } else if (indexOF('/search.php')) {
  237. curSite = DBSite.phpbb_search;
  238. }},
  239. pager: {
  240. type: 1,
  241. nextL: 'css;.pagination li.next a[rel="next"], .topic-actions .pagination strong~a',
  242. pageE: 'css;.forumbg:not(.announcement) ul.topiclist.topics > li',
  243. replaceE: 'css;.action-bar .pagination, .topic-actions .pagination',
  244. scrollD: 2000
  245. }
  246. }, // phpBB 论坛 - 帖子列表
  247. phpbb_post: {
  248. pager: {
  249. type: 1,
  250. nextL: 'css;.pagination li.next a[rel="next"], .topic-actions .pagination strong~a',
  251. pageE: 'css;div.post[id], div.post[id]+hr',
  252. replaceE: 'css;.action-bar .pagination, .topic-actions .pagination',
  253. scrollD: 2000
  254. }
  255. }, // phpBB 论坛 - 帖子内
  256. phpbb_search: {
  257. pager: {
  258. type: 1,
  259. nextL: 'css;.pagination li.next a[rel="next"], .topic-actions .pagination strong~a',
  260. pageE: 'css;div.search.post',
  261. replaceE: 'css;.action-bar .pagination, .pagination',
  262. scrollD: 2000
  263. }
  264. }, // phpBB 论坛 - 搜索页
  265. xenforo: {
  266. functionS: function() {if (indexOF(/\/(forums|f)\//)) {
  267. curSite = DBSite.xenforo;
  268. } else if (indexOF(/\/(threads|t)\//) && GM_getValue('menu_thread')) {
  269. curSite = DBSite.xenforo_post;
  270. } else if (indexOF('/search/')) {
  271. curSite = DBSite.xenforo_search;
  272. }},
  273. pager: {
  274. type: 1,
  275. nextL: 'css;a.pageNav-jump--next',
  276. pageE: 'css;.structItemContainer-group.js-threadList > div',
  277. replaceE: 'css;nav.pageNavWrapper',
  278. scrollD: 2500
  279. }
  280. }, // XenForo 论坛 - 帖子列表
  281. xenforo_post: {
  282. pager: {
  283. type: 1,
  284. nextL: 'css;a.pageNav-jump--next',
  285. pageE: 'css;.block-body.js-replyNewMessageContainer > article',
  286. replaceE: 'css;nav.pageNavWrapper',
  287. scrollD: 2500
  288. }
  289. }, // XenForo 论坛 - 帖子内
  290. xenforo_search: {
  291. pager: {
  292. type: 1,
  293. nextL: 'css;a.pageNav-jump--next',
  294. pageE: 'css;ol.block-body > li',
  295. replaceE: 'css;nav.pageNavWrapper',
  296. scrollD: 2500
  297. }
  298. }, // XenForo 论坛 - 搜索页
  299. xiuno: {
  300. functionS: function() {if (lp == '/' || indexOF(/\/(index|forum)/)) {curSite = DBSite.xiuno;} else if (indexOF('/thread') && GM_getValue('menu_thread')) {curSite = DBSite.xiuno_post;}},
  301. pager: {
  302. type: 1,
  303. nextL: '//li[@class="page-item"]/a[text()="▶"]',
  304. pageE: 'css;ul.threadlist > li',
  305. replaceE: 'css;ul.pagination',
  306. scrollD: 1500
  307. }
  308. }, // Xiuno 论坛 - 帖子列表
  309. xiuno_post: {
  310. pager: {
  311. type: 1,
  312. nextL: '//li[@class="page-item"]/a[text()="▶"]',
  313. pageE: 'css;li.post[data-pid]:not(.newpost)',
  314. replaceE: 'css;ul.pagination',
  315. scrollD: 1500
  316. }
  317. }, // Xiuno 论坛 - 帖子内
  318. nexusphp: {
  319. functionS: function() {
  320. if (lp == '/torrents.php' || getCSS('table.torrents')) {
  321. curSite = DBSite.nexusphp;
  322. } else if (lp == '/subtitles.php') {
  323. curSite = DBSite.nexusphp;
  324. curSite.pager.pageE = 'css;#outer > table.main~table > tbody > tr:not(:first-of-type)'
  325. } else if (lp == '/forums.php' && indexOF('action=viewforum', 's')) {
  326. curSite = DBSite.nexusphp;
  327. curSite.pager.pageE = 'css;#outer > table.main+table > tbody > tr:not(:first-of-type):not(:last-of-type)'
  328. } else if (lp == '/forums.php' && indexOF('action=viewtopic', 's') && GM_getValue('menu_thread')) {
  329. curSite = DBSite.nexusphp;
  330. curSite.pager.pageE = 'css;td.text > div, td.text > div+table.main'
  331. }},
  332. pager: {
  333. type: 1,
  334. nextL: '//a[./b[contains(text(), "下一页") or contains(text(), ">>")]]',
  335. pageE: 'css;table.torrents > tbody > tr:not(:first-of-type)',
  336. replaceE: '//p[@align][./font[@class="gray"]]',
  337. scrollD: 1500
  338. }
  339. }, // NexusPHP 论坛
  340. dux: {
  341. host: 'www.puresys.net',
  342. functionS: function() {if (!indexOF('.html')) curSite = DBSite.dux;},
  343. pager: {
  344. type: 1,
  345. nextL: 'css;li.next-page > a',
  346. pageE: 'css;.content > article',
  347. replaceE: 'css;.content > .pagination',
  348. scrollD: 1500
  349. },
  350. function: {
  351. bF: src_bF,
  352. pF: [0, 'img.thumb[data-src]', 'data-src']
  353. }
  354. }, // WordPress 的 DUX、XIU、D8 主题
  355. begin: {
  356. functionS: function() {if (location.search.slice(0,3) === '?s=') {curSite = DBSite.begin_search;} else if (!indexOF('.html')) {curSite = DBSite.begin;}},
  357. pager: {
  358. type: 2,
  359. nextL: 'css;div[id^="ias_trigger_"]',
  360. interval: 500,
  361. scrollD: 1500
  362. }
  363. }, // WordPress 的 Begin 主题
  364. begin_search: {
  365. pager: {
  366. type: 1,
  367. nextL: 'css;a.next',
  368. pageE: 'css;#main > ul > li',
  369. replaceE: 'css;nav.pagination',
  370. scrollD: 1500
  371. }
  372. }, // WordPress 的 Begin 主题 - 搜索页
  373. biquge: {
  374. functionS: function() {if (indexOF(/\d+\/\d+\.html/)) {curSite = DBSite.biquge;}},
  375. style: 'img, .posterror {display: none !important;}',
  376. pager: {
  377. type: 1,
  378. nextL: '//a[contains(text(), "下一章") or contains(text(), "下一页")]',
  379. pageE: 'css;#content, .content, #chaptercontent, .chaptercontent, #BookText',
  380. insertP: ['css;#content, .content, #chaptercontent, .chaptercontent, #BookText', 6],
  381. insertP6Br: true,
  382. replaceE: '//*[./a[contains(text(), "下一章") or contains(text(), "下一页")]]',
  383. scrollD: 1500
  384. }
  385. }, // 笔趣阁 模板的小说网站
  386. baidu: {
  387. host: 'www.baidu.com',
  388. functionS: function() {locationC = true; if (lp == '/s') {curSite = DBSite.baidu;} else if (location.pathname.slice(location.pathname.length - 2,location.pathname.length) == '/s') {location.hostname = 'm.baidu.com';}},
  389. style: '.new-pmd .c-img-border {position: initial !important;} .op-bk-polysemy-video__wrap.c-gap-bottom {display: none !important;}',
  390. pager: {
  391. type: 1,
  392. nextL: 'id("page")//a[contains(text(),"下一页")]',
  393. pageE: 'css;#content_left > *',
  394. replaceE: 'css;#page',
  395. scrollD: 2000
  396. }
  397. }, // 百度 搜索
  398. baidu_m: {
  399. host: 'm.baidu.com',
  400. functionS: function() {if (location.pathname.slice(location.pathname.length - 2,location.pathname.length) == '/s') curSite = DBSite.baidu_m;},
  401. style: 'div.result[tpl="recommend_list"], #page-copyright {display: none !important;}',
  402. pager: {
  403. type: 1,
  404. nextL: 'css;a[class^="new-nextpage"]',
  405. pageE: 'css;#results > *',
  406. replaceE: 'css;#page-controller',
  407. scrollD: 2000
  408. }
  409. }, // 百度 搜索 - 手机版
  410. google: {
  411. host: /\.google\./,
  412. functionS: function() {if (lp == '/search' && !indexOF('tbm=isch', 's')) {
  413. curSite = DBSite.google;
  414. } else if (lp == '/scholar') {
  415. curSite = DBSite.google_scholar;
  416. }},
  417. pager: {
  418. type: 1,
  419. nextL: 'css;#pnnext',
  420. pageE: 'id("search")/* | //style[not(contains(text(), "table,div,span,p{display:none}"))]',
  421. insertP: ['css;#search', 3],
  422. replaceE: 'id("navcnt") | id("rcnt")//div[@role="navigation"]',
  423. scriptT: 0,
  424. scrollD: 3000
  425. },
  426. function: {
  427. bF: google_bF
  428. }
  429. }, // 谷歌 搜索
  430. bing: {
  431. host: ['www.bing.com','cn.bing.com'],
  432. functionS: function() {if (lp == '/search') {
  433. curSite = DBSite.bing;
  434. curSite.function = {bF: bing_bF}
  435. } else if (lp == '/academic/search') {
  436. curSite = DBSite.bing_academic;
  437. }},
  438. style: '.b_imagePair.square_mp > .inner {display: none !important;}',
  439. pager: {
  440. type: 1,
  441. nextL: 'css;a.sb_pagN, a.sb_halfnext, a.sb_fullnpl',
  442. pageE: 'css;#b_results > li:not(.b_msg):not([class="b_ans"]):not(.b_pag):not(#mfa_root)',
  443. replaceE: 'css;#b_results > .b_pag',
  444. scrollD: 2000
  445. }
  446. }, // 必应 搜索
  447. sogou: {
  448. host: 'www.sogou.com',
  449. functionS: function() {if (location.pathname != '/') {curSite = DBSite.sogou;}},
  450. pager: {
  451. type: 1,
  452. nextL: 'css;#sogou_next',
  453. pageE: 'css;.results > *',
  454. replaceE: 'css;#pagebar_container',
  455. scriptT: 3,
  456. scrollD: 2000
  457. }
  458. }, // 搜狗 搜索
  459. sogou_weixin: {
  460. host: 'weixin.sogou.com',
  461. functionS: function() {if (lp == '/') {
  462. curSite = DBSite.sogou_weixin;
  463. } else if (lp == '/weixin') {
  464. curSite = DBSite.sogou_weixin_search;
  465. }},
  466. pager: {
  467. type: 2,
  468. nextL: 'css;#look-more',
  469. interval: 1000,
  470. scrollD: 1000
  471. }
  472. }, // 搜狗微信 - 首页
  473. sogou_weixin_search: {
  474. pager: {
  475. type: 1,
  476. nextL: 'css;#sogou_next',
  477. pageE: 'css;ul[class*="news-list"] > li',
  478. replaceE: 'css;#pagebar_container',
  479. scrollD: 1200
  480. }
  481. }, // 搜狗微信 - 搜索
  482. toutiao: {
  483. host: ['www.toutiao.com', 'so.toutiao.com'],
  484. functionS: function() {if (location.hostname != 'www.toutiao.com' && lp == '/search') curSite = DBSite.toutiao;},
  485. pager: {
  486. type: 1,
  487. nextL: '//div[contains(@class, "-pagination")]/a[string()="下一页"]',
  488. pageE: 'css;div[class*="-result-list"] > .result-content[data-i]',
  489. replaceE: 'css;div[class*="-pagination"]',
  490. scrollD: 2000
  491. },
  492. function: {
  493. bF: toutiao_bF
  494. }
  495. }, // 头条 搜索
  496. so: {
  497. host: 'www.so.com',
  498. functionS: function() {if (location.pathname != '/') {curSite = DBSite.so; insStyle('img {opacity: 1 !important;}')}},
  499. pager: {
  500. type: 1,
  501. nextL: 'css;a#snext',
  502. pageE: 'css;ul.result > li, style:not(src)',
  503. insertP: ['css;ul.result', 3],
  504. replaceE: 'css;#page',
  505. scrollD: 2000
  506. },
  507. function: {
  508. bF: src_bF,
  509. pF: [0, 'img[data-isrc]', 'data-isrc']
  510. }
  511. }, // 360 搜索
  512. duckduckgo: {
  513. host: 'duckduckgo.com',
  514. functionS: function() {
  515. if (getCookie('av') != '1') {
  516. document.cookie='av=1; expires=Thu, 18 Dec 2031 12:00:00 GMT; path=/'; // 写入 Cookie 强制开启自带的无缝翻页功能
  517. location.reload(); // 刷新网页
  518. }
  519. },
  520. history: false
  521. }, // DuckDuckGo 搜索
  522. startpage: {
  523. host: ['startpage.com', 'www.startpage.com'],
  524. functionS: function() {if (indexOF('/search')) {curSite = DBSite.startpage;}},
  525. pager: {
  526. type: 1,
  527. nextL: startpage_nextL,
  528. pageE: 'css;section.w-gl--desktop > div',
  529. replaceE: 'css;.pagination',
  530. scrollD: 2000
  531. }
  532. }, // Startpage 搜索
  533. yandex: {
  534. host: ['yandex.com', 'yandex.ru', 'yandex.ua', 'yandex.by', 'yandex.kz', 'yandex.uz', 'yandex.com.tr'],
  535. functionS: function() {if (lp == '/search/') {curSite = DBSite.yandex;} else if (lp == '/video/search') {curSite = DBSite.yandex_video;}},
  536. pager: {
  537. type: 1,
  538. nextL: 'css;a.pager__item_kind_next',
  539. pageE: 'css;#search-result > *, style',
  540. insertP: ['css;#search-result', 3],
  541. replaceE: 'css;.pager',
  542. scrollD: 1500
  543. }
  544. }, // Yandex 搜索
  545. yandex_video: {
  546. hiddenPN: true,
  547. pager: {
  548. type: 2,
  549. nextL: 'css;button.more__button',
  550. interval: 1000,
  551. scrollD: 1000
  552. }
  553. }, // Yandex 搜索 - 视频
  554. yahoo: {
  555. host: 'search.yahoo.com',
  556. functionS: function() {if (indexOF('/search')) {curSite = DBSite.yahoo;}},
  557. pager: {
  558. type: 1,
  559. nextL: 'css;.pagination a.next',
  560. pageE: 'css;#web ol > li',
  561. replaceE: 'css;.pagination',
  562. scrollD: 2000
  563. }
  564. }, // Yahoo 搜索
  565. yahoo_jp: {
  566. host: 'search.yahoo.co.jp',
  567. functionS: function() {if (indexOF('/search')) {curSite = DBSite.yahoo_jp;}},
  568. pager: {
  569. type: 1,
  570. nextL: 'css;.Pagenation__next > a',
  571. pageE: 'css;.Contents__innerGroupBody > div',
  572. replaceE: 'css;.Pagenation',
  573. scrollD: 2000
  574. }
  575. }, // Yahoo 搜索 (JP)
  576. qwant: {
  577. host: 'www.qwant.com',
  578. functionS: function() {locationC = true; if (indexOF('q=', 's') && indexOF('t=web', 's')) {curSite = DBSite.qwant;}},
  579. pager: {
  580. type: 2,
  581. nextL: 'css;button[data-testid="buttonShowMore"]',
  582. interval: 500,
  583. scrollD: 2000
  584. }
  585. }, // Qwant 搜索
  586. ecosia: {
  587. host: 'www.ecosia.org',
  588. functionS: function() {if (lp == '/search') {curSite = DBSite.ecosia;}},
  589. pager: {
  590. type: 1,
  591. nextL: 'css;nav.pagination a[aria-label="Next page"]',
  592. pageE: 'css;section.mainline > div:not(.related-queries)',
  593. replaceE: 'css;nav.pagination',
  594. scrollD: 1500
  595. }
  596. }, // Ecosia 搜索
  597. magi: {
  598. host: 'magi.com',
  599. functionS: function() {if (lp == '/search') {curSite = DBSite.magi;}},
  600. pager: {
  601. type: 2,
  602. nextL: 'css;.card[data-type="next"]',
  603. nextText: '加载更多',
  604. scrollD: 1500
  605. }
  606. }, // Magi 搜索
  607. ask: {
  608. host: ['ask.com', 'www.ask.com'],
  609. functionS: function() {if (lp == '/web') {curSite = DBSite.ask;}},
  610. style: '.PartialSearchResults-heading {display: none !important;}',
  611. pager: {
  612. type: 1,
  613. nextL: 'css;li.PartialWebPagination-next > a',
  614. pageE: 'css;.PartialSearchResults.mid',
  615. replaceE: 'css;.PartialWebPagination',
  616. scrollD: 2000
  617. }
  618. }, // ASK 搜索
  619. fsou: {
  620. host: 'fsou.cc',
  621. functionS: function() {
  622. if (lp == '/search') {
  623. if (window.screen.width < 780) {
  624. curSite = DBSite.fsou_m;
  625. } else {
  626. curSite = DBSite.fsou;
  627. }
  628. }
  629. },
  630. retry: 1000,
  631. pager: {
  632. type: 6,
  633. nextL: () => getNextEP('css;.turn-page-num-wrap.selected', 'pageIndex=', /pageIndex=\d+/),
  634. pageE: 'css;.organic-results > div',
  635. replaceE: 'css;.bottom-pagination',
  636. loadTime: 1000,
  637. scrollD: 3000
  638. }
  639. }, // F 搜
  640. fsou_m: {
  641. pager: {
  642. type: 2,
  643. nextL: 'css;.next-page-container',
  644. scrollD: 1500
  645. }
  646. }, // F 搜 - 手机版
  647. baidu_tieba: {
  648. host: ['tieba.baidu.com', 'jump2.bdimg.com'],
  649. functionS: function() {if (location.hostname == 'jump2.bdimg.com') location.hostname = 'tieba.baidu.com';
  650. if (lp == '/f') {
  651. baidu_tieba_1(); // 右侧悬浮发帖按钮点击事件(解决自动翻页导致无法发帖的问题)
  652. curSite = DBSite.baidu_tieba;
  653. } else if (indexOF('/p/') && GM_getValue('menu_thread')) {
  654. curSite = DBSite.baidu_tieba_post;
  655. } else if (lp == '/f/search/res') {
  656. curSite = DBSite.baidu_tieba_search;
  657. }},
  658. style: 'img.j_retract {margin-top: 0 !important;margin-bottom: 0 !important;}', // 修复帖子列表中预览图片,在切换下一个/上一个图片时,多出来的图片上下边距
  659. history: false,
  660. iframe: true,
  661. pager: {
  662. type: 4,
  663. nextL: function() {if (getNextE('css;a.next.pagination-item')) getPageElems_(curSite.pageUrl + '&pagelets=frs-list%2Fpagelet%2Fthread&pagelets_stamp=' + new Date().getTime());},
  664. pageE: 'css;#thread_list > li',
  665. insertP: ['css;#thread_list', 3],
  666. insertE: baidu_tieba_insertE,
  667. replaceE: 'css;#frs_list_pager',
  668. interval: 2000,
  669. scrollD: 2500
  670. },
  671. function: {
  672. bF: src_bF,
  673. pF: [0, 'img[data-original]', 'data-original']
  674. }
  675. }, // 百度贴吧 - 帖子列表
  676. baidu_tieba_post: {
  677. forceTarget: true,
  678. style: '.d_sign_split, img.j_user_sign, .d_author .d_pb_icons, .save_face_bg, .save_face_bg_2, li.d_name a.icon_tbworld, .lzl_cnt a.icon_tbworld, .topic_list_box.topic-fixed {display: none !important;} a.p_author_face.j_frame_guide {background: none repeat scroll 0 0 #FFF !important;border: 1px solid #CCC !important;padding: inherit !important;} .red_text, .red-text, .vip_red, .vip-red, .vip_red:hover, .vip-red:hover, .vip_red:visited, .vip-red:visited {color: #2d64b3 !important;}', // 签名、印记、头像边框、VIP 元素
  679. pager: {
  680. type: 5,
  681. nextL: '//li[contains(@class,"pb_list_pager")]/a[text()="下一页"]',
  682. style: 'ul.tbui_aside_float_bar, .core_title_wrap_bright.tbui_follow_fixed.core_title_absolute_bright {display: none !important;}',
  683. scrollD: 1500
  684. }
  685. }, // 百度贴吧 - 帖子内
  686. baidu_tieba_search: {
  687. pager: {
  688. type: 1,
  689. nextL: 'css;a.next',
  690. pageE: 'css;.s_post_list > div',
  691. replaceE: 'css;.pager',
  692. scrollD: 1000
  693. }
  694. }, // 百度贴吧 - 搜索页
  695. douban_subject_comments: {
  696. host: 'movie.douban.com',
  697. functionS: function() {if (indexOF('/subject/') && indexOF('/comments')) {
  698. curSite = DBSite.douban_subject_comments;
  699. } else if (indexOF('/subject/') && indexOF('/reviews')) {
  700. curSite = DBSite.douban_subject_reviews;
  701. } else if(indexOF('/subject/') && indexOF('/episode') || indexOF('/subject/') && indexOF('/tv_discuss')) {
  702. curSite = DBSite.douban_subject_episode;
  703. } else if(indexOF('/people/') && indexOF('/collect')) {
  704. curSite = DBSite.douban_people_collect;
  705. } else if(indexOF('/celebrity/') && indexOF('/movies')) {
  706. curSite = DBSite.douban_celebrity_movies;
  707. }},
  708. pager: {
  709. type: 1,
  710. nextL: 'css;a.next',
  711. pageE: 'css;#comments > .comment-item',
  712. replaceE: 'css;#paginator',
  713. scrollD: 1500
  714. }
  715. }, // 豆瓣 - 短评
  716. douban_subject_reviews: {
  717. pager: {
  718. type: 1,
  719. nextL: 'css;link[rel="next"]',
  720. pageE: 'css;.review-list > div',
  721. replaceE: 'css;.paginator',
  722. scrollD: 1500
  723. }
  724. }, // 豆瓣 - 影评
  725. douban_subject_episode: {
  726. pager: {
  727. type: 1,
  728. nextL: 'css;link[rel="next"]',
  729. pageE: 'css;#comments > div',
  730. replaceE: 'css;.paginator',
  731. scrollD: 1500
  732. }
  733. }, // 豆瓣 - 剧评
  734. douban_people_collect: {
  735. pager: {
  736. type: 1,
  737. nextL: 'css;link[rel="next"]',
  738. pageE: 'css;.grid-view > div',
  739. replaceE: 'css;.paginator',
  740. scrollD: 1500
  741. }
  742. }, // 豆瓣 - 看过的电影
  743. douban_celebrity_movies: {
  744. pager: {
  745. type: 1,
  746. nextL: 'css;link[rel="next"]',
  747. pageE: 'css;.grid_view > ul > li',
  748. replaceE: 'css;.paginator',
  749. scrollD: 1500
  750. }
  751. }, // 豆瓣 - 作品
  752. douban_group: {
  753. host: 'www.douban.com',
  754. functionS: function() {if (indexOF('/group/topic/') && GM_getValue('menu_thread')) {
  755. curSite = DBSite.douban_group_topic;
  756. } else if (indexOF('/group/explore')) {
  757. curSite = DBSite.douban_group_explore;
  758. } else if (indexOF('/group/') && indexOF('/discussion')) {
  759. curSite = DBSite.douban_group;
  760. }},
  761. pager: {
  762. type: 1,
  763. nextL: 'css;span.next > a',
  764. pageE: 'css;table.olt > tbody > tr:not(.th)',
  765. replaceE: 'css;.paginator',
  766. scrollD: 1500
  767. }
  768. }, // 豆瓣 - 小组
  769. douban_group_explore: {
  770. pager: {
  771. type: 1,
  772. nextL: 'css;span.next > a',
  773. pageE: 'css;#content .article > div > .channel-item',
  774. replaceE: 'css;.paginator',
  775. scrollD: 1500
  776. }
  777. }, // 豆瓣 - 小组讨论精选
  778. douban_group_topic: {
  779. pager: {
  780. type: 1,
  781. nextL: 'css;span.next > a',
  782. pageE: 'css;#comments > li',
  783. replaceE: 'css;.paginator',
  784. scrollD: 1500
  785. }
  786. }, // 豆瓣 - 小组帖子内
  787. zhihu: {
  788. host: 'www.zhihu.com',
  789. functionS: function() {locationC = true; if (indexOF(/\/people\/.+\/.+/) || indexOF('/collection/')) {curSite = DBSite.zhihu; if (self != top) insStyle('#ProfileHeader {display: none !important;}')}},
  790. forceTarget: true,
  791. iframe: true,
  792. pager: {
  793. type: 5,
  794. nextL: function() {
  795. let next = getCSS('.Pagination .PaginationButton--current+button:not(.PaginationButton-next)');
  796. if (next) return (location.origin + location.pathname + '?page=' + next.textContent)
  797. },
  798. scrollD: 2000
  799. }
  800. }, // 知乎 - 用户主页、收藏夹
  801. weibo_comment: {
  802. host: 'weibo.com',
  803. pager: {
  804. type: 2,
  805. nextL: 'css;a[action-type="click_more_comment"]',
  806. nextText: '查看更多c',
  807. scrollD: 1000
  808. }
  809. }, // 微博评论
  810. tianya: {
  811. host: 'bbs.tianya.cn',
  812. functionS: function() {if (indexOF('/list')) {
  813. curSite = DBSite.tianya;
  814. } else if (indexOF('/post') && GM_getValue('menu_thread')) {
  815. curSite = DBSite.tianya_post;
  816. }},
  817. pager: {
  818. type: 1,
  819. nextL: '//div[contains(@class, "pages")]/div[@class="links"]/a[text()="下一页"]',
  820. pageE: 'css;.tab-bbs-list > tbody:not(:first-of-type)',
  821. replaceE: '//div[contains(@class, "pages")]',
  822. scrollD: 1500
  823. }
  824. }, // 天涯社区
  825. tianya_post: {
  826. pager: {
  827. type: 1,
  828. nextL: 'css;a.js-keyboard-next',
  829. pageE: 'css;.atl-main > div[class="atl-item"]',
  830. replaceE: 'css;.atl-pages > form',
  831. scrollD: 2000
  832. }
  833. }, // 天涯社区 - 帖子内
  834. hupu: {
  835. host: 'bbs.hupu.com',
  836. functionS: function() {if (indexOF('.html')) {
  837. if (GM_getValue('menu_thread')) curSite = DBSite.hupu_post;
  838. } else if (lp != '/' && !indexOF('/all-')) {
  839. curSite = DBSite.hupu;
  840. }},
  841. pager: {
  842. type: 1,
  843. nextL: function() {let next = getCSS('li.hupu-rc-pagination-item-active+li.hupu-rc-pagination-item > a');if (next) {return (location.origin + location.pathname.replace(/-\d+/,'') + '-' + next.textContent)} else {return ''}},
  844. pageE: 'css;li.bbs-sl-web-post-body',
  845. replaceE: 'css;ul.hupu-rc-pagination',
  846. scrollD: 1500
  847. }
  848. }, // 虎扑社区
  849. hupu_post: {
  850. pager: {
  851. type: 1,
  852. nextL: 'css;li.hupu-rc-pagination-next > a',
  853. pageE: 'css;.post-reply-list ',
  854. replaceE: 'css;ul.hupu-rc-pagination',
  855. scrollD: 2000
  856. }
  857. }, // 虎扑社区 - 帖子内
  858. nga_thread: {
  859. host: ['bbs.nga.cn', 'ngabbs.com', 'nga.178.com', 'g.nga.cn'],
  860. iframe: true,
  861. functionS: function() {locationC = true;
  862. if (lp == '/thread.php') {
  863. curSite = DBSite.nga_thread;
  864. } else if (lp == '/read.php' && GM_getValue('menu_thread')) {
  865. curSite = DBSite.nga_read;
  866. }},
  867. pager: {
  868. type: 1,
  869. nextL: 'css;#pagebbtm a[title="下一页"]',
  870. pageE: 'css;#topicrows > tbody, #topicrows > script',
  871. insertP: ['css;#topicrows', 3],
  872. replaceE: 'css;div[name="pageball"]',
  873. scriptT: 2,
  874. scrollD: 1000
  875. },
  876. function: {
  877. aF: function() {document.body.appendChild(document.createElement('script')).textContent = 'commonui.topicArg.loadAll();';}
  878. }
  879. }, // NGA - 各版块帖子列表
  880. nga_read: {
  881. history: false,
  882. retry: 1000,
  883. pager: {
  884. type: 1,
  885. nextL: 'css;#pagebbtm a[title*="下一页"]',
  886. pageE: 'id("m_posts_c")/table | id("m_posts_c")/script | //script[contains(text(), "commonui.userInfo.setAll")]',
  887. insertP: ['css;#m_posts_c', 3],
  888. replaceE: 'css;div[name="pageball"]',
  889. scriptT: 2,
  890. scrollD: 1000
  891. }
  892. }, // NGA - 帖子内
  893. v2ex_recent: {
  894. host: ['v2ex.com', 'www.v2ex.com'],
  895. functionS: function() {if (lp == '/') {
  896. v2ex_aF('#Main a.topic-link:not([target])');
  897. } else if (lp == '/recent') {
  898. curSite = DBSite.v2ex_recent;
  899. v2ex_aF('#Main a.topic-link:not([target])');
  900. } else if (lp == '/notifications') {
  901. curSite = DBSite.v2ex_notifications;
  902. v2ex_aF('#Main a[href^="/t/"]:not([target])');
  903. } else if (lp == '/balance') {
  904. curSite = DBSite.v2ex_balance;
  905. } else if (indexOF('/go/')) {
  906. curSite = DBSite.v2ex_go;
  907. v2ex_aF('#Main a.topic-link:not([target])');
  908. } else if (indexOF('/replies')) {
  909. curSite = DBSite.v2ex_replies;
  910. v2ex_aF('#Main a[href^="/t/"]:not([target])');
  911. }},
  912. pager: {
  913. type: 1,
  914. nextL: 'css;a.page_current+a.page_normal',
  915. pageE: 'css;.cell.item',
  916. replaceE: 'css;#Main > .box > .cell[style]:not(.item) > table',
  917. scrollD: 1500
  918. },
  919. function: {
  920. aF: v2ex_aF,
  921. pF: '#Main a.topic-link:not([target])'
  922. }
  923. }, // V2EX - 最近主题页
  924. v2ex_notifications: {
  925. pager: {
  926. type: 1,
  927. nextL: 'css;a.page_current+a.page_normal',
  928. pageE: 'css;#notifications > div',
  929. replaceE: 'css;#Main > .box > .cell[style] > table',
  930. scrollD: 1500
  931. },
  932. function: {
  933. aF: v2ex_aF,
  934. pF: '#Main a[href^="/t/"]:not([target])'
  935. }
  936. }, // V2EX - 提醒消息页
  937. v2ex_replies: {
  938. pager: {
  939. type: 1,
  940. nextL: 'css;a.page_current+a.page_normal',
  941. pageE: '//div[@id="Main"]//div[@class="box"]//div[@class="dock_area"] | //*[@id="Main"]//div[@class="box"]//div[@class="inner"] | //*[@id="Main"]//div[@class="box"]//div[@class="dock_area"][last()]/following-sibling::div[@class="cell"][1]',
  942. insertP: ['//div[@id="Main"]//div[@class="box"]//div[@class="cell"][last()]', 1],
  943. replaceE: 'css;#Main > .box > .cell[style] > table',
  944. scrollD: 1500
  945. },
  946. function: {
  947. aF: v2ex_aF,
  948. pF: '#Main a[href^="/t/"]:not([target])'
  949. }
  950. }, // V2EX - 用户回复页
  951. v2ex_go: {
  952. pager: {
  953. type: 1,
  954. nextL: 'css;a.page_current+a.page_normal',
  955. pageE: 'css;#TopicsNode > div',
  956. replaceE: 'css;#Main > .box > .cell[style] > table',
  957. scrollD: 1500
  958. },
  959. function: {
  960. aF: v2ex_aF,
  961. pF: '#Main a.topic-link:not([target])'
  962. }
  963. }, // V2EX - 分类主题页
  964. v2ex_balance: {
  965. pager: {
  966. type: 1,
  967. nextL: 'css;a.page_current+a.page_normal',
  968. pageE: 'css;#Main .box > div:not(.cell) > table > tbody > tr:not(:first-child)',
  969. replaceE: 'css;#Main > .box > .cell[style] > table',
  970. scrollD: 1000
  971. }
  972. }, // V2EX - 账户余额页
  973. jandan: {
  974. host: 'jandan.net',
  975. functionS: function() {if (lp == '/' || indexOF('/page/')) {
  976. curSite = DBSite.jandan;
  977. } else if (lp == '/dzh') {
  978. curSite = DBSite.jandan_dzh;
  979. } else {
  980. curSite = DBSite.jandan_comment;
  981. }},
  982. style: '#nav_prev, #nav_next, .post.f:not(.list-post) {display: none !important;}',
  983. history: false,
  984. pager: {
  985. type: 1,
  986. nextL: '//div[@class="wp-pagenavi"]/a[contains(text(), "下一页") or contains(text(), "更多文章")]',
  987. pageE: 'css;#content > .list-post',
  988. replaceE: 'css;.wp-pagenavi',
  989. scrollD: 1500
  990. },
  991. function: {
  992. bF: src_bF,
  993. pF: [0, 'img[data-original]', 'data-original']
  994. }
  995. }, // 煎蛋网
  996. jandan_comment: {
  997. style: '#nav_prev, #nav_next {display: none !important;}',
  998. pager: {
  999. type: 1,
  1000. nextL: 'css;a.previous-comment-page',
  1001. pageE: 'css;ol.commentlist > li[id^="comment-"], script[src^="//cdn.jandan.net/static/min/"]',
  1002. insertP: ['css;ol.commentlist', 3],
  1003. replaceE: 'css;.cp-pagenavi',
  1004. scriptT: 2,
  1005. scrollD: 1500
  1006. }
  1007. }, // 煎蛋网
  1008. jandan_dzh: {
  1009. history: false,
  1010. pager: {
  1011. type: 2,
  1012. nextL: 'css;.show_more',
  1013. interval: 1500,
  1014. scrollD: 1500
  1015. }
  1016. }, // 煎蛋网 - 大杂烩
  1017. qiushibaike: {
  1018. host: 'www.qiushibaike.com',
  1019. functionS: function() {insStyle('.qrcode-wrap, .qrcode-wrap-img, .index-side-left-AD1 {display: none !important;}');
  1020. if (lp == '/') {
  1021. curSite = DBSite.qiushibaike;
  1022. } else if (!indexOF('/article/')) {
  1023. curSite = DBSite.qiushibaike_;
  1024. }},
  1025. pager: {
  1026. type: 1,
  1027. nextL: '//ul[@class="pagination"]//a[./span[@class="next"]]',
  1028. pageE: 'css;.recommend-article > ul > li',
  1029. replaceE: 'css;ul.pagination',
  1030. scrollD: 1500
  1031. }
  1032. }, // 糗事百科
  1033. qiushibaike_: {
  1034. pager: {
  1035. type: 1,
  1036. nextL: '//ul[@class="pagination"]//a[./span[@class="next"]]',
  1037. pageE: 'css;[id^="qiushi_tag_"]',
  1038. replaceE: 'css;ul.pagination',
  1039. scrollD: 1500
  1040. }
  1041. }, // 糗事百科 - 分类页
  1042. lkong: {
  1043. host: 'www.lkong.com',
  1044. functionS: function() {locationC = true; if (indexOF('/forum/')) {
  1045. curSite = DBSite.lkong;
  1046. } else if (indexOF('/thread/') && GM_getValue('menu_thread')) {
  1047. curSite = DBSite.lkong_thread;
  1048. }},
  1049. history: false,
  1050. pager: {
  1051. type: 1,
  1052. nextL: lkong_nextL,
  1053. pageE: '//div[@class="main-title"]/parent::div/parent::div | //head/style[@data-emotion-css]',
  1054. insertP: ['//div[@class="main-title"][1]/parent::div/parent::div/parent::div', 3],
  1055. replaceE: 'css;ul.ant-pagination',
  1056. interval: 500,
  1057. scrollD: 1200
  1058. }
  1059. }, // 龙的天空 - 各版块帖子列表
  1060. lkong_thread: {
  1061. pager: {
  1062. type: 1,
  1063. nextL: lkong_nextL,
  1064. pageE: '//div[@class="main-content"]/parent::div | //head/style[@data-emotion-css]',
  1065. insertP: ['//div[@class="main-content"][1]/parent::div/parent::div', 3],
  1066. replaceE: 'css;ul.ant-pagination',
  1067. interval: 500,
  1068. scrollD: 1200
  1069. }
  1070. }, // 龙的天空 - 帖子内
  1071. pediy_forum: {
  1072. host: 'bbs.pediy.com',
  1073. functionS: function() {if (indexOF('/forum-')) {
  1074. curSite = DBSite.pediy_forum;
  1075. } else if (indexOF('/thread-') && GM_getValue('menu_thread')) {
  1076. curSite = DBSite.pediy_thread;
  1077. }},
  1078. pager: {
  1079. type: 1,
  1080. nextL: '//a[@class="page-link" and text()="▶"]',
  1081. pageE: 'css;table.threadlist > tbody > tr',
  1082. replaceE: 'css;ul.pagination',
  1083. scrollD: 1500
  1084. }
  1085. }, // 看雪论坛 - 各版块帖子列表
  1086. pediy_thread: {
  1087. pager: {
  1088. type: 1,
  1089. nextL: '//a[@class="page-link" and text()="▶"]',
  1090. pageE: 'css;table.postlist > tbody > tr[data-pid]',
  1091. replaceE: 'css;ul.pagination',
  1092. scrollD: 1500
  1093. }
  1094. }, // 看雪论坛 - 帖子内
  1095. bangumitv: {
  1096. host: 'bangumi.tv',
  1097. functionS: function() {
  1098. if (indexOF('/browser') || indexOF('/subject_search')) {
  1099. curSite = DBSite.bangumitv;
  1100. } else if (indexOF('/forum')) {
  1101. curSite = DBSite.bangumitv_forum;
  1102. }},
  1103. pager: {
  1104. type: 1,
  1105. nextL: '//div[@class="page_inner"]/a[text()="››"]',
  1106. pageE: 'css;ul#browserItemList > li',
  1107. replaceE: 'css;.page_inner',
  1108. scrollD: 1500
  1109. }
  1110. }, // 番组计划
  1111. bangumitv_forum: {
  1112. pager: {
  1113. type: 1,
  1114. nextL: '//div[@class="page_inner"]/a[text()="››"]',
  1115. pageE: 'css;.topic_list > tbody:last-of-type > tr.topic',
  1116. replaceE: 'css;.page_inner',
  1117. scrollD: 1500
  1118. }
  1119. }, // 番组计划 - 小组帖子列表
  1120. dongchedi: {
  1121. host: 'www.dongchedi.com',
  1122. functionS: function() {locationC = true;
  1123. if (indexOF('/community/')) {
  1124. curSite = DBSite.dongchedi;
  1125. }},
  1126. pager: {
  1127. type: 1,
  1128. nextL: 'css;li.pagination-item.is-active+li > a',
  1129. pageE: 'css;.data-wrapper > section.community-card, style',
  1130. insertP: ['css;.data-wrapper', 3],
  1131. replaceE: '//ul[./li[contains(@class, "pagination-item")]]',
  1132. scrollD: 2000
  1133. },
  1134. function: {
  1135. bF: function(pageElems) {
  1136. pageElems.forEach(function (one) {
  1137. one.querySelectorAll('.g-load-img-wrap, .tw-absolute.tw-cursor-pointer, .avatar').forEach(function (now) {
  1138. getCSS('noscript+img', now).src = getCSS('noscript > img', now).src;
  1139. });
  1140. });
  1141. return pageElems
  1142. }
  1143. }
  1144. }, // 懂车帝论坛
  1145. kdslife: {
  1146. host: 'club.kdslife.com',
  1147. functionS: function() {
  1148. if (indexOF('/f_')) {
  1149. curSite = DBSite.kdslife;
  1150. } else if (indexOF('/t_')) {
  1151. curSite = DBSite.kdslife_t;
  1152. }},
  1153. pager: {
  1154. type: 1,
  1155. nextL: '//div[@class="fr i3_r"]/a[text()="后一页"]',
  1156. pageE: 'css;ul.main_List > li.i2:not(.h_bg)',
  1157. replaceE: 'css;ul.main_List > li.i3',
  1158. scrollD: 1000
  1159. }
  1160. }, // 宽带山论坛
  1161. kdslife_t: {
  1162. pager: {
  1163. type: 1,
  1164. nextL: '//div[@class="pages"]/a[text()=">>"]',
  1165. pageE: 'css;#reply_list_panel > *, script[src*="ui/js/kds.js"]',
  1166. insertP: ['css;#reply_list_panel', 3],
  1167. replaceE: 'css;.pages',
  1168. scriptT: 2,
  1169. scrollD: 1000
  1170. }
  1171. }, // 宽带山论坛 - 帖子内
  1172. libaclub: {
  1173. host: 'www.libaclub.com',
  1174. functionS: function() {
  1175. if (lp == '/' || indexOF('/date_')) {
  1176. curSite = DBSite.libaclub;
  1177. } else if (indexOF('/f_')) {
  1178. curSite = DBSite.libaclub_f;
  1179. } else if (indexOF('/t_') || indexOF('/reply_')) {
  1180. curSite = DBSite.libaclub_t;
  1181. } else if (indexOF('/prt_')) {
  1182. curSite = DBSite.libaclub_prt;
  1183. } else if (lp == '/facade.php') {
  1184. curSite = DBSite.libaclub_search;
  1185. }},
  1186. style: 'li.ui-list-merchant-ad, .ui-nav-appImage {display: none !important;}',
  1187. pager: {
  1188. type: 1,
  1189. nextL: '//div[@class="ui-crumbs-more"]/a[@class="fn-link"][1]',
  1190. pageE: 'css;ul.ui-list > li:not(.ui-list-item-head):not(.ui-list-merchant-ad)',
  1191. replaceE: 'css;div.ui-crumbs-more',
  1192. scrollD: 1200
  1193. }
  1194. }, // 篱笆网论坛
  1195. libaclub_f: {
  1196. style: 'li.ui-list-merchant-ad, .ui-nav-appImage {display: none !important;}',
  1197. pager: {
  1198. type: 1,
  1199. nextL: 'css;a.ui-paging-next',
  1200. pageE: 'css;ul.ui-list > li:not(.ui-list-item-head):not(.ui-list-merchant-ad)',
  1201. replaceE: 'css;div.ui-paging',
  1202. scrollD: 1200
  1203. }
  1204. }, // 篱笆网论坛 - 各版块帖子列表
  1205. libaclub_t: {
  1206. style: 'li.ui-list-merchant-ad, .ui-nav-appImage {display: none !important;}',
  1207. pager: {
  1208. type: 1,
  1209. nextL: 'css;a.ui-paging-next',
  1210. pageE: 'css;.ui-box-content > div.ui-topic, .ui-box-content > a[name]',
  1211. insertP: ['css;.ui-box-content', 3],
  1212. replaceE: 'css;div.ui-paging',
  1213. scrollD: 1500
  1214. }
  1215. }, // 篱笆网论坛 - 帖子内
  1216. libaclub_prt: {
  1217. style: 'li.ui-list-merchant-ad, .ui-nav-appImage {display: none !important;}',
  1218. pager: {
  1219. type: 1,
  1220. nextL: 'css;a.ui-paging-next',
  1221. pageE: 'css;ul.ui-list > li',
  1222. replaceE: 'css;div.ui-paging',
  1223. scrollD: 2000
  1224. }
  1225. }, // 篱笆网论坛 - 帖子内 - 打印版
  1226. libaclub_search: {
  1227. style: 'li.ui-list-merchant-ad, .ui-nav-appImage {display: none !important;}',
  1228. pager: {
  1229. type: 1,
  1230. nextL: '//div[@class="ui-page"]/a[contains(text(), "下一页")]',
  1231. pageE: 'css;.ui-box-main > ul.ui-list > li',
  1232. replaceE: 'css;div.ui-page',
  1233. scrollD: 1200
  1234. }
  1235. }, // 篱笆网论坛 - 搜索页
  1236. taoguba: {
  1237. host: 'www.taoguba.com.cn',
  1238. functionS: function() {insStyle('#joinTGB {display: none !important;}')
  1239. if (indexOF('/Article/') && GM_getValue('menu_thread')) {
  1240. curSite = DBSite.taoguba_t;
  1241. } else if (indexOF('/shenghuoba/')) {
  1242. curSite = DBSite.taoguba_;
  1243. } else if (indexOF(/\/bbs|zongban|dianzan|jinghua\//)) {
  1244. curSite = DBSite.taoguba;
  1245. }},
  1246. history: false,
  1247. pager: {
  1248. type: 1,
  1249. nextL: function() {
  1250. let next = getXpath('//div[contains(@class, "t_page01")]/a[contains(text(), "下一页")]'), next_ = '/';
  1251. if (next) {
  1252. next = next.getAttribute('onclick').replace('gotoPage(','').replace(')','').split(',');
  1253. if (indexOF(/\/dianzan|jinghua\//)) next_ = '-';
  1254. if (parseInt(next[0]) <= parseInt(next[2])) {return (`${location.origin}/${location.pathname.split('/')[1]}/${next[0]}${next_}${next[1]}`)}
  1255. }
  1256. return '';
  1257. },
  1258. pageE: 'css;.p_list > .p_list01[class*="user_"]',
  1259. replaceE: 'css;.t_page',
  1260. scrollD: 1000
  1261. }
  1262. }, // 淘股吧论坛
  1263. taoguba_: {
  1264. history: false,
  1265. pager: {
  1266. type: 1,
  1267. nextL: function() {
  1268. let next = getCSS('#N_go_pageBtn'), next_ = location.pathname.split('/')[2].split('-')[0];
  1269. if (next && (parseInt(next.dataset.now) + 1 <= parseInt(next.dataset.total))) {
  1270. if (!next_) next_ = 'H';
  1271. return (`${location.origin}/shenghuoba/${next_}-${parseInt(next.dataset.now) + 1}`)
  1272. }
  1273. return '';
  1274. },
  1275. pageE: 'css;.lifeContent-topicList-item',
  1276. replaceE: 'css;.N_sortPage ',
  1277. scrollD: 1000
  1278. }
  1279. }, // 淘股吧论坛 - 生活圈
  1280. taoguba_t: {
  1281. history: false,
  1282. pager: {
  1283. type: 1,
  1284. nextL: function() {
  1285. let next = getXpath('//div[contains(@class, "t_page01")]/a[contains(text(), "下一页")]');
  1286. if (next) {
  1287. next = next.getAttribute('onclick').replace('gotoPageTopic(','').replace(')','').split(',');
  1288. if (parseInt(next[0]) <= parseInt(next[1])) {return (`${location.origin}/Article/${getCSS("#looktopicID").value}/${next[0]}`)}
  1289. }
  1290. return '';
  1291. },
  1292. pageE: 'css;div[id^="reply_"]',
  1293. replaceE: 'css;.t_page',
  1294. scrollD: 1000
  1295. },
  1296. function: {
  1297. bF: src_bF,
  1298. pF: [0, 'img[data-original]', 'data-original']
  1299. }
  1300. }, // 淘股吧论坛 - 帖子内
  1301. lowendtalk: {
  1302. host: 'lowendtalk.com',
  1303. pager: {
  1304. type: 1,
  1305. nextL: 'css;a.Next',
  1306. pageE: 'css;ul.DataList > li',
  1307. replaceE: 'css;.Pager',
  1308. scrollD: 1500
  1309. }
  1310. }, // LowEndTalk
  1311. lieyou: {
  1312. host: 'bbs.lieyou888.com',
  1313. functionS: function() {if (indexOF('/forum')) {curSite = DBSite.lieyou;}},
  1314. pager: {
  1315. type: 1,
  1316. nextL: '//div[contains(@class, "_pageNav")]/a[text()="下一页"]',
  1317. pageE: 'css;ul.gb-bbs-list > li',
  1318. replaceE: 'css;._pageNav',
  1319. scrollD: 1000
  1320. },
  1321. function: {
  1322. bF: src_bF,
  1323. pF: [0, 'img[original]', 'original']
  1324. }
  1325. }, // 芥子空间论坛
  1326. xcar_forumdisplay: {
  1327. host: 'www.xcar.com.cn',
  1328. functionS: function() {if (lp == '/bbs/forumdisplay.php') {curSite = DBSite.xcar_forumdisplay}},
  1329. pager: {
  1330. type: 1,
  1331. nextL: 'css;a.page_down',
  1332. pageE: 'css;.table-section > dl:not(.table_head)',
  1333. replaceE: 'css;.forumList_page',
  1334. scrollD: 2000
  1335. }
  1336. }, // 爱卡汽车网论坛 - 各版块帖子列表
  1337. flyert_forumdisplay: {
  1338. host: 'www.flyert.com',
  1339. functionS: function() {if (indexOF('/forum-') || indexOF('mod=forumdisplay', 's')) {
  1340. curSite = DBSite.flyert_forumdisplay;
  1341. } else if (indexOF('/forum') || indexOF('mod=viewthread', 's')) {
  1342. if (GM_getValue('menu_thread')) {curSite = DBSite.flyert_viewthread;}
  1343. }},
  1344. pager: {
  1345. type: 1,
  1346. nextL: 'css;a.nxt:not([href*="javascript"])',
  1347. pageE: 'css;#threadlist table > tbody[id^="normalthread_"]',
  1348. replaceE: 'css;.pg',
  1349. scrollD: 2500
  1350. }
  1351. }, // 飞客网论坛 - 各版块帖子列表
  1352. flyert_viewthread: {
  1353. pager: {
  1354. type: 1,
  1355. nextL: 'css;a.nxt:not([href*="javascript"])',
  1356. pageE: 'css;#postlist > .comiis_viewbox',
  1357. replaceE: 'css;.comiis_pgs > .pg',
  1358. scrollD: 3000
  1359. }
  1360. }, // 飞客网论坛 - 帖子内
  1361. cnprint: {
  1362. host: 'www.cnprint.org',
  1363. functionS: function() {if (indexOF('/forum/')) {curSite = DBSite.cnprint;} else if (indexOF('/thread/') && GM_getValue('menu_thread')) {curSite = DBSite.cnprint_thread;}},
  1364. pager: {
  1365. type: 1,
  1366. nextL: 'css;a[rel="next"]',
  1367. pageE: 'css;tbody[id*="threadbits_forum"] > tr',
  1368. replaceE: 'css;.pagenav',
  1369. scrollD: 2500
  1370. }
  1371. }, // CPC 中文印刷社区
  1372. cnprint_thread: {
  1373. pager: {
  1374. type: 1,
  1375. nextL: 'css;a[rel="next"]',
  1376. pageE: 'css;#posts > div:not([id])',
  1377. replaceE: 'css;.pagenav',
  1378. scrollD: 2000
  1379. }
  1380. }, // CPC 中文印刷社区 - 帖子内
  1381. discusshk: {
  1382. host: /.+\.discuss\.com\.hk/,
  1383. functionS: function() {if (lp == '/forumdisplay.php') {curSite = DBSite.discusshk;} else if (lp == '/viewthread.php' && GM_getValue('menu_thread')) {curSite = DBSite.discusshk_thread;}},
  1384. pager: {
  1385. type: 1,
  1386. nextL: 'css;.pagination a.next',
  1387. pageE: 'css;tbody[id^="normalthread_"]',
  1388. replaceE: 'css;.pagination',
  1389. scrollD: 2000
  1390. }
  1391. }, // 中国香港社区
  1392. discusshk_thread: {
  1393. style: '.viewthread.mt-0:not(:first-of-type) .viewthread__head {display: none !important;}',
  1394. pager: {
  1395. type: 1,
  1396. nextL: 'css;.pagination a.next',
  1397. pageE: 'css;.viewthread',
  1398. replaceE: 'css;.pagination',
  1399. scrollD: 2000
  1400. }
  1401. }, // 中国香港论坛 - 帖子内
  1402. tgfcer: {
  1403. host: 'bbs.tgfcer.com',
  1404. functionS: function() {if (lp == '/forumdisplay.php' || indexOF('/forum')) {curSite = DBSite.tgfcer;} else if (GM_getValue('menu_thread') && (lp == '/viewthread.php' || indexOF('/thread'))) {curSite = DBSite.tgfcer_thread;}},
  1405. pager: {
  1406. type: 1,
  1407. nextL: 'css;.pages a.next',
  1408. pageE: 'css;tbody[id^="normalthread_"]',
  1409. replaceE: 'css;.pages',
  1410. scrollD: 2000
  1411. }
  1412. }, // TGFC Lifestyle
  1413. tgfcer_thread: {
  1414. style: '.viewthread:not(:first-of-type) h1 {display: none !important;}',
  1415. pager: {
  1416. type: 1,
  1417. nextL: 'css;.pages a.next',
  1418. pageE: 'css;.viewthread',
  1419. replaceE: 'css;.pages',
  1420. scrollD: 2000
  1421. }
  1422. }, // TGFC Lifestyle - 帖子内
  1423. south: {
  1424. host: /((www|bbs)\.)?(soul|north|south|white|level|summer|spring|snow)-plus\.(net|org)/,
  1425. functionS: function() {
  1426. if (lp == '/thread.php' || lp == '/search.php') {
  1427. curSite = DBSite.south;
  1428. } else if (lp == '/thread_new.php') {
  1429. curSite = DBSite.south; curSite.pager.pageE = 'css;li.dcsns-li'; curSite.pager.scrollD = 2000; curSite.function = {bF: src_bF,pF: [0, 'img[data-original]', 'data-original']}; curSite.style = 'img.lazy {display: inline !important;}';
  1430. } else if (GM_getValue('menu_thread') && lp == '/read.php') {
  1431. curSite = DBSite.south; curSite.pager.pageE = 'css;form[name=delatc] > *:not(input)';
  1432. } else if (lp == '/u.php' && (indexOF('action-topic-', 's') || indexOF('action-post-', 's'))) {
  1433. curSite = DBSite.south; curSite.pager.pageE = 'css;#u-contentmain table tr';
  1434. }},
  1435. pager: {
  1436. type: 1,
  1437. nextL: '//div[@class="pages"]/ul/li[./b]/following-sibling::li[1][not(@class)]/a[not(text()="»")]',
  1438. pageE: 'css;tr.tr3',
  1439. replaceE: 'css;.pages',
  1440. scrollD: 1500
  1441. }
  1442. }, // South Plus (南+)
  1443. goddessfantasy: {
  1444. host: 'www.goddessfantasy.net',
  1445. functionS: function() {
  1446. if (indexOF('board=', 's')) {
  1447. curSite = DBSite.goddessfantasy;
  1448. } else if (indexOF('topic=', 's')) {
  1449. if (GM_getValue('menu_thread')) curSite = DBSite.goddessfantasy; curSite.pager.pageE = 'css;#quickModForm > *';
  1450. }},
  1451. pager: {
  1452. type: 1,
  1453. nextL: '//div[contains(@class,"pagelinks")]/a[@class="navPages" and text()="»"]',
  1454. pageE: 'css;.table_grid > tbody > tr',
  1455. replaceE: 'css;.pagelinks',
  1456. scrollD: 1500
  1457. }
  1458. }, // 纯美苹果园
  1459. adnmb3: {
  1460. host: ['adnmb3.com', 'www.tnmb.org'],
  1461. functionS: function() {
  1462. if (indexOF('/m/f/')) {
  1463. curSite = DBSite.adnmb3_mf;
  1464. } else if (indexOF('/m/t/')) {
  1465. if (GM_getValue('menu_thread')) curSite = DBSite.adnmb3_mt;
  1466. } else if (indexOF(/\/(f|Forum)\//)) {
  1467. curSite = DBSite.adnmb3;
  1468. } else if (indexOF('/t/')) {
  1469. if (GM_getValue('menu_thread')) curSite = DBSite.adnmb3_t;
  1470. }},
  1471. pager: {
  1472. type: 1,
  1473. nextL: '//ul[contains(@class, "pagination")]//a[text()="下一页"]',
  1474. pageE: 'css;.h-threads-list > *, script[src$="/h.desktop.js"]',
  1475. insertP: ['css;.h-threads-list', 3],
  1476. replaceE: '//ul[contains(@class, "pagination")]',
  1477. scriptT: 2,
  1478. scrollD: 2500
  1479. }
  1480. }, // A 岛
  1481. adnmb3_t: {
  1482. pager: {
  1483. type: 1,
  1484. nextL: '//ul[contains(@class, "pagination")]//a[text()="下一页"]',
  1485. pageE: 'css;.h-threads-list > .h-threads-item > .h-threads-item-replys, script[src$="/h.desktop.js"]',
  1486. insertP: ['css;.h-threads-list > .h-threads-item', 3],
  1487. replaceE: '//ul[contains(@class, "pagination")]',
  1488. scriptT: 2,
  1489. scrollD: 2500
  1490. }
  1491. }, // A 岛 - 帖子内
  1492. adnmb3_mf: {
  1493. pager: {
  1494. type: 1,
  1495. nextL: '//li[contains(@class, "pagination-next")]//a[text()="下一页"]',
  1496. pageE: 'css;.h-middle > div[id^="threads_"], .h-middle > hr.h-middle > div[id^="threads_"], .h-middle > hr:nth-of-type(n+2), script[src$="/h.mobile.js"]',
  1497. insertP: ['css;#h-threads-pagination', 1],
  1498. replaceE: 'css;#h-threads-pagination',
  1499. scriptT: 2,
  1500. scrollD: 2500
  1501. }
  1502. }, // A 岛 - 帖子列表(手机版)
  1503. adnmb3_mt: {
  1504. pager: {
  1505. type: 1,
  1506. nextL: '//li[contains(@class, "pagination-next")]//a[text()="下一页"]',
  1507. pageE: 'css;.h-threads-replylist > div, script[src$="/h.mobile.js"]',
  1508. insertP: ['css;.h-threads-replylist', 3],
  1509. replaceE: 'css;#h-threads-pagination',
  1510. scriptT: 2,
  1511. scrollD: 2500
  1512. }
  1513. }, // A 岛 - 帖子内(手机版)
  1514. pixiv: {
  1515. host: 'www.pixiv.net',
  1516. functionS: function() {locationC = true;
  1517. if (lp == '/') {
  1518. forceTarget();
  1519. } else if (indexOF('/tags/')/* && self == top*/) {
  1520. curSite = DBSite.pixiv;
  1521. } else if (indexOF('/users/') && indexOF(/\/(artworks|illustrations|manga)/)) {
  1522. curSite = DBSite.pixiv_user;
  1523. } else if (indexOF('/artworks/')) {
  1524. setTimeout(function(){getXpath('//button[contains(string(), "查看全部") or contains(string(), "See all") or contains(string(), "すべて見る") or contains(string(), "모두 보기")]').click();}, 1000)
  1525. }
  1526. },
  1527. forceTarget: true,
  1528. style: 'ul[class*="-1 "] > li {display: inline !important;} #root{margin-bottom: -175px;} ul > li > button[class^="sc-"], a[href^="/premium/lead/lp"] {display: none !important;}',
  1529. iframe: true,
  1530. pager: {
  1531. type: 5,
  1532. nextL: 'css;a[aria-disabled="false"][class*="filterProps-Styled-Component"][href]:last-child',
  1533. /*pageE: '//ul[contains(@class, "-1 ")]/li',
  1534. insertP: ['//ul[contains(@class, "-1 ")]', 3],
  1535. replaceE: '//nav[./a[@aria-disabled="false"][contains(@class, "filterProps-Styled-Component")]]',*/
  1536. scrollD: 2000
  1537. }
  1538. }, // Pixiv - 分类页
  1539. pixiv_user: {
  1540. forceTarget: true,
  1541. style: 'ul[class*="-1 "] > li {display: inline !important;} #root{margin-bottom: -125px;} ul > li > button[class^="sc-"][style="background-color: rgb(0, 0, 0);"], a[href^="/premium/lead/lp"] {display: none !important;}',
  1542. pager: {
  1543. type: 5,
  1544. nextL: 'css;a[aria-disabled="false"][class*="filterProps-Styled-Component"][href]:last-child',
  1545. /*pageE: '//ul[contains(@class, "-1 ")]/li',
  1546. insertP: ['//ul[contains(@class, "-1 ")]', 3],
  1547. replaceE: '//nav[./a[@aria-disabled="false"][contains(@class, "filterProps-Styled-Component")]]',*/
  1548. scrollD: 2000
  1549. }
  1550. }, // Pixiv - 用户作品页
  1551. vilipix: {
  1552. host: 'www.vilipix.com',
  1553. functionS: function() {locationC = true; if (lp == '/') {forceTarget();} else if (indexOF(/\/(tags|user|new|ranking)/)) {curSite = DBSite.vilipix;}},
  1554. forceTarget: true,
  1555. pager: {
  1556. type: 6,
  1557. nextL: function() {let next = getCSS('li.number.active+li.number'); if (next) return (location.origin + location.pathname + '?p=' + next.textContent)},
  1558. pageE: 'css;ul.illust-content > li',
  1559. replaceE: 'css;ul.el-pager',
  1560. loadTime: 800,
  1561. scrollD: 2000
  1562. }
  1563. }, // Vilipix
  1564. pixivision: {
  1565. host: 'www.pixivision.net',
  1566. functionS: function() {if (!indexOF('/a/')) curSite = DBSite.pixivision;},
  1567. pager: {
  1568. type: 1,
  1569. nextL: 'css;a.next',
  1570. pageE: 'css;li.article-card-container',
  1571. replaceE: 'css;._pager',
  1572. scrollD: 2000
  1573. }
  1574. }, // Pixivision
  1575. _58pic: {
  1576. host: 'www.58pic.com',
  1577. functionS: function() {insStyle('.qt-model-t.login-model {display: none !important;}');
  1578. if (indexOF(/\/(tupian|piccate)\//)) {
  1579. curSite = DBSite._58pic;
  1580. if (indexOF('/piccate/') && getCSS('.card-grid-box .qt-card-box[style*="width:"]')) insStyle('.card-grid-box .qt-card-box {display: block;height: 300px;min-height: 250px;}')
  1581. } else if (indexOF('/c/')) {
  1582. curSite = DBSite._58pic_c;
  1583. }},
  1584. style: '.qtw-card.place-box, .card-lazy, .is-line .is-back {display: none !important;}',
  1585. pager: {
  1586. type: 1,
  1587. nextL: '//div[contains(@class,"page-box")]//a[text()="下一页"]',
  1588. pageE: 'css;.card-grid-box:not(.favorites-box) > div',
  1589. replaceE: 'css;.page-box',
  1590. scrollD: 2500
  1591. },
  1592. function: {
  1593. bF: src_bF,
  1594. pF: [0, 'img[data-original]', 'data-original']
  1595. }
  1596. }, // 千图网 - 分类/搜索页
  1597. _58pic_c: {
  1598. pager: {
  1599. type: 1,
  1600. nextL: '//div[contains(@class,"page-box")]//a[text()="下一页"]',
  1601. pageE: 'css;.list-box > .qtw-card',
  1602. replaceE: 'css;.page-box',
  1603. scrollD: 4000
  1604. },
  1605. function: {
  1606. bF: src_bF,
  1607. pF: [0, 'img[data-original]', 'data-original']
  1608. }
  1609. }, // 千图网 - 专题/收藏夹
  1610. _588ku: {
  1611. host: '588ku.com',
  1612. style: '.listlogin-box.listloginBox, .CLdialogV1, .editIndexEntry, .globalRSideB {display: none !important;}',
  1613. pager: {
  1614. type: 1,
  1615. nextL: '//ul[contains(@class, "page-list")]//a[text()="下一页"]',
  1616. pageE: 'css;.data-box .dataList, .data-box .data-list',
  1617. insertP: ['css;.data-box .dataList, .data-box .data-list', 3],
  1618. replaceE: 'css;ul.page-list',
  1619. scrollD: 2000
  1620. },
  1621. function: {
  1622. bF: src_bF,
  1623. pF: [0, 'img[data-original]', 'data-original']
  1624. }
  1625. }, // 千库网
  1626. nipic: {
  1627. host: ['www.nipic.com', 'soso.nipic.com'],
  1628. style: 'li.search-works-item {display: none !important;}',
  1629. pager: {
  1630. type: 1,
  1631. nextL: '//a[@title="下一页" or text()="下一页"][not(contains(@class, "search-works-nextpage"))]',
  1632. pageE: 'css;ul#img-list-outer > li',
  1633. replaceE: 'css;.common-page-box, .common-seo-page-box',
  1634. scrollD: 2000
  1635. },
  1636. function: {
  1637. bF: src_bF,
  1638. pF: [0, 'img[data-original]', 'data-original']
  1639. }
  1640. }, // 昵图网
  1641. ztupic: {
  1642. host: 'www.ztupic.com',
  1643. functionS: function() {if (lp != '/' && !indexOF('/sucai/')) {curSite = DBSite.ztupic;}},
  1644. pager: {
  1645. type: 1,
  1646. nextL: 'css;a.page-link[rel="next"]',
  1647. pageE: 'css;.floor_item',
  1648. replaceE: 'css;ul.pagination',
  1649. scrollD: 2000
  1650. },
  1651. function: {
  1652. bF: src_bF,
  1653. pF: [0, 'img[data-src]', 'data-src']
  1654. }
  1655. }, // 众图网
  1656. ooopic: {
  1657. host: ['www.ooopic.com', 'so.ooopic.com', 'weili.ooopic.com'],
  1658. functionS: function() {if (lp != '/' && !indexOF('/weili_')) {curSite = DBSite.ooopic;}},
  1659. style: '.overWidth.clearfix.masonry {height: auto !important;} .pic-list, .video-list {position: relative !important;float: left !important;top: auto !important;left: auto !important;}',
  1660. pager: {
  1661. type: 1,
  1662. nextL: 'css;a.next_page, a.so-next',
  1663. pageE: 'css;.overWidth.clearfix.masonry > div',
  1664. replaceE: 'css;.page',
  1665. scrollD: 2000
  1666. },
  1667. function: {
  1668. bF: src_bF,
  1669. pF: [0, 'img[data-original]', 'data-original']
  1670. }
  1671. }, // 我图网
  1672. ibaotu: {
  1673. host: 'ibaotu.com',
  1674. functionS: function() {if (lp != '/' && !indexOF('/sucai/')) {curSite = DBSite.ibaotu;if (indexOF('/yinxiao') || indexOF('/peiyue')) {curSite.pager.pageE = 'css;ul.media-list-ul > li[pr-data-title]'} else if (indexOF('/font/')) {curSite.pager.pageE = 'css;.baotufonts-list > a'}}},
  1675. style: '.searchAdver {display: none !important;}',
  1676. pager: {
  1677. type: 1,
  1678. nextL: 'css;a.next',
  1679. pageE: 'css;.pr-container[pr-data-title]:not(.searchAdver)',
  1680. replaceE: 'css;.pagelist',
  1681. scrollD: 2000
  1682. },
  1683. function: {
  1684. bF: src_bF,
  1685. pF: [0, 'img[data-url]', 'data-url']
  1686. }
  1687. }, // 包图网
  1688. pixabay: {
  1689. host: 'pixabay.com',
  1690. pager: {
  1691. type: 1,
  1692. nextL: '//a[text()="›"]',
  1693. pageE: 'css;[class^="results"] > [class^="container"] > div',
  1694. replaceE: '//a[text()="›"]',
  1695. scrollD: 2000
  1696. },
  1697. function: {
  1698. bF: src_bF,
  1699. pF: [0, 'img[data-lazy-src]', 'data-lazy-src']
  1700. }
  1701. }, // Pixabay
  1702. logosc: {
  1703. host: 'www.logosc.cn',
  1704. functionS: function() {if (indexOF('/so/')) {curSite = DBSite.logosc;}},
  1705. pager: {
  1706. type: 2,
  1707. nextL: 'css;button.so-pablo-button',
  1708. interval: 1500,
  1709. scrollD: 1500
  1710. }
  1711. }, // 搜图神器 (免费无版权)
  1712. sccnn: {
  1713. host: 'www.sccnn.com',
  1714. pager: {
  1715. type: 1,
  1716. nextL: '//ul[@class="listpage"]//a[text()=">"]',
  1717. pageE: 'css;td[valign="TOP"]:not([width]) tr[valign="Middle"]',
  1718. replaceE: 'css;ul.listpage',
  1719. scrollD: 1000
  1720. }
  1721. }, // 素材中国
  1722. sccnn_so: {
  1723. host: 'so.sccnn.com',
  1724. pager: {
  1725. type: 1,
  1726. nextL: 'css;font[color="Red"]+a.F16',
  1727. pageE: '//tr[@valign="Top"][1]/preceding-sibling::tr',
  1728. replaceE: '//tr[@valign="Top"][last()]',
  1729. scrollD: 1000
  1730. }
  1731. }, // 素材中国 - 搜索页
  1732. pngss: {
  1733. host: 'pngss.com',
  1734. functionS: function() {if (lp == '/search') curSite = DBSite.pngss;},
  1735. pager: {
  1736. type: 1,
  1737. nextL: 'css;.page a[rel="next"]',
  1738. pageE: 'css;ul.list-ul > li',
  1739. replaceE: 'css;.page',
  1740. scrollD: 1200
  1741. },
  1742. function: {
  1743. bF: src_bF,
  1744. pF: [0, 'img[data-original]', 'data-original']
  1745. }
  1746. }, // PNG 搜索网
  1747. iconfont: {
  1748. host: 'www.iconfont.cn',
  1749. functionS: function() {locationC = true; if (indexOF('/search/')) curSite = DBSite.iconfont;},
  1750. forceTarget: true,
  1751. style: '.footer, header .bind-tips, .block-pagination-wrap {display: none !important;}',
  1752. iframe: true,
  1753. pager: {
  1754. type: 5,
  1755. nextL: () => getNextEP('css;li.active+li:not(.disabled) > a', 'page=', /page=\d+/),
  1756. scrollD: 1000
  1757. }
  1758. }, // iconfont
  1759. iconarchive: {
  1760. host: 'iconarchive.com',
  1761. functionS: function() {if (indexOF(/\/(tag|search|category)/)) curSite = DBSite.iconarchive;},
  1762. pager: {
  1763. type: 1,
  1764. nextL: 'css;a.next',
  1765. pageE: 'css;.icondetail',
  1766. replaceE: 'css;.pagination',
  1767. scrollD: 2000
  1768. }
  1769. }, // IconArchive
  1770. puxiang: {
  1771. host: 'www.puxiang.com',
  1772. functionS: function() {if (lp == '/search/favorite') {
  1773. curSite = DBSite.puxiang_collect;
  1774. } else if (lp == '/search/puxiang' || lp == '/list' || lp == '/galleries' || lp == '/articles') {
  1775. curSite = DBSite.puxiang;
  1776. } else if (lp == '/') {
  1777. curSite = DBSite.puxiang; curSite.pager.scrollD = 4000;
  1778. }},
  1779. pager: {
  1780. type: 1,
  1781. nextL: 'css;li.next > a',
  1782. pageE: 'css;.work-list > div',
  1783. replaceE: 'css;.pagerbar',
  1784. scrollD: 1500
  1785. }
  1786. }, // 普象网 - 作品集/搜索页
  1787. puxiang_collect: {
  1788. pager: {
  1789. type: 1,
  1790. nextL: 'css;li.next > a',
  1791. pageE: 'css;.collect-list > div',
  1792. replaceE: 'css;.pagerbar',
  1793. scrollD: 1500
  1794. }
  1795. }, // 普象网 - 收藏夹
  1796. xuexiniu: {
  1797. host: ['www.xuexiniu.com', 'bbs.xuexiniu.com'],
  1798. functionS: function() {
  1799. if (getCSS('body#nv_forum.pg_forumdisplay')) {
  1800. if (getCSS('ul.waterfall')) {
  1801. curSite = DBSite.xuexiniu_forum;
  1802. } else {
  1803. curSite = DBSite.discuz_guide
  1804. }
  1805. } else if (getCSS('body#nv_forum.pg_viewthread') && GM_getValue('menu_thread')) {
  1806. curSite = DBSite.xuexiniu_thread;
  1807. } else if (indexOF('/search.php')) {
  1808. curSite = DBSite.xuexiniu_search;
  1809. } else {
  1810. curSite = DBSite.xuexiniu;
  1811. }
  1812. },
  1813. pager: {
  1814. type: 1,
  1815. nextL: '//a[@class="page-link" and contains(text(), "下一页")]',
  1816. pageE: 'css;.row > .col-sm-6',
  1817. replaceE: 'css;ul.pagination',
  1818. scrollD: 1000
  1819. }
  1820. }, // 学犀牛 - 分类页
  1821. xuexiniu_forum: {
  1822. pager: {
  1823. type: 1,
  1824. nextL: 'css;a.nxt:not([href*="javascript"])',
  1825. pageE: 'css;.waterfall > li',
  1826. replaceE: 'css;.pg',
  1827. scrollD: 1500
  1828. }
  1829. }, // 学犀牛 - 各板块帖子列表
  1830. xuexiniu_thread: {
  1831. pager: {
  1832. type: 1,
  1833. nextL: 'css;a.nxt:not([href*="javascript"])',
  1834. pageE: 'css;#zhanzhuai_primary > .box',
  1835. replaceE: 'css;.pg',
  1836. scrollD: 1500
  1837. }
  1838. }, // 学犀牛 - 帖子内
  1839. xuexiniu_search: {
  1840. pager: {
  1841. type: 1,
  1842. nextL: 'css;a.nxt:not([href*="javascript"])',
  1843. pageE: 'css;.yangshi.yangshi2',
  1844. insertP: ['css;.page', 1],
  1845. replaceE: 'css;.page',
  1846. scrollD: 1500
  1847. }
  1848. }, // 学犀牛 - 搜索页
  1849. om: {
  1850. host: 'www.om.cn',
  1851. functionS: function() {if (location.pathname != '/') {curSite = DBSite.om;}},
  1852. pager: {
  1853. type: 1,
  1854. nextL: 'css;li.next > a',
  1855. pageE: 'css;.main_content > ul > li',
  1856. replaceE: 'css;ul.pagination',
  1857. scrollD: 1500
  1858. }
  1859. }, // 欧模网
  1860. xiadele: {
  1861. host: ['www.xiadele.com', 'search.xiadele.com'],
  1862. functionS: function() {if (location.pathname != '/') {curSite = DBSite.xiadele;}},
  1863. style: '.last-li-carousel-img {display: none !important;}',
  1864. pager: {
  1865. type: 1,
  1866. nextL: 'css;li.next_page a[rel="next"]',
  1867. pageE: 'css;ul.list-page-ul > li',
  1868. replaceE: 'css;ul.pagination',
  1869. scrollD: 2000
  1870. }
  1871. }, // 下得乐
  1872. Mixkit: {
  1873. host: 'mixkit.co',
  1874. functionS: function() {if (location.pathname != '/') {curSite = DBSite.Mixkit;}},
  1875. pager: {
  1876. type: 1,
  1877. nextL: 'css;a.pagination__link--next',
  1878. pageE: 'css;.item-grid-item',
  1879. replaceE: 'css;.pagination__wrapper',
  1880. scrollD: 2000
  1881. }
  1882. }, // Mixkit
  1883. _3dmgame: {
  1884. host: 'www.3dmgame.com',
  1885. functionS: function() {
  1886. if (getCSS('.Llist_b > div.lis')) {
  1887. curSite = DBSite._3dmgame_list;
  1888. } else if (getCSS('.newsleft > ul')) {
  1889. curSite = DBSite._3dmgame_list2;
  1890. } else if (indexOF('/resource')) {
  1891. curSite = DBSite._3dmgame_list3;
  1892. } else {
  1893. curSite = DBSite._3dmgame;
  1894. }},
  1895. pager: {
  1896. type: 3,
  1897. nextL: 'css;li.next > a',
  1898. pageE: 'css;script[src*="common.js"], .news_warp_center > *',
  1899. insertP: ['css;.news_warp_center', 3],
  1900. replaceE: 'css;.pagewrap',
  1901. scrollE: 'css;.pagewrap',
  1902. scriptT: 2,
  1903. scrollD: 300
  1904. }
  1905. }, // 3DM
  1906. _3dmgame_list: {
  1907. pager: {
  1908. type: 1,
  1909. nextL: 'css;li.next > a',
  1910. pageE: 'css;.Llist_b > div.lis',
  1911. replaceE: 'css;.pagewrap',
  1912. scrollD: 1000
  1913. },
  1914. function: {
  1915. bF: src_bF,
  1916. pF: [0, 'img[data-original]', 'data-original']
  1917. }
  1918. }, // 3DM - 分类页
  1919. _3dmgame_list2: {
  1920. pager: {
  1921. type: 1,
  1922. nextL: 'css;li.next > a',
  1923. pageE: 'css;.newsleft > ul > li',
  1924. replaceE: 'css;.pagewrap',
  1925. scrollD: 1000
  1926. },
  1927. function: {
  1928. bF: src_bF,
  1929. pF: [0, 'img[data-original]', 'data-original']
  1930. }
  1931. }, // 3DM - 游戏专区 - 分类页
  1932. _3dmgame_list3: {
  1933. pager: {
  1934. type: 1,
  1935. nextL: 'css;li.next > a',
  1936. pageE: 'css;.item > ul',
  1937. insertP: ['css;.item > ul:last-child', 1],
  1938. replaceE: 'css;.pagewrap',
  1939. scrollD: 800
  1940. }
  1941. }, // 3DM - 游戏专区 - 资源页
  1942. _3dmgame_mod: {
  1943. host: 'mod.3dmgame.com',
  1944. pager: {
  1945. type: 1,
  1946. nextL: () => getNextEP('//li[@class="page-list active"]/following-sibling::li[contains(@class, "page-list")]/a', 'Page=', /Page=\d+/),
  1947. pageE: '//div[contains(@class, "game-mod-list") or contains(@class, "search-mod-list")] | //script[not(@src or @type)][contains(text(), ".game-mod-page") or contains(text(), ".search-mod-page")]',
  1948. insertP: ['//div[contains(@class, "game-mod-wrap") or contains(@class, "search-mod ")]', 3],
  1949. scriptT: 2,
  1950. scrollD: 1200
  1951. }
  1952. }, // 3DM MOD站
  1953. ali213_www: {
  1954. host: 'www.ali213.net',
  1955. pager: {
  1956. type: 3,
  1957. nextL: 'css;#after_this_page',
  1958. pageE: 'css;#Content >*:not(.news_ding):not(.page_fenye)',
  1959. insertP: ['css;.page_fenye', 1],
  1960. replaceE: 'css;.page_fenye',
  1961. scrollE: 'css;.page_fenye',
  1962. scrollD: 0
  1963. }
  1964. }, // 游侠网
  1965. ali213_list: {
  1966. host: 'down.ali213.net',
  1967. functionS: function() {if (getCSS('.famous-ul > .famous-li')) {curSite = DBSite.ali213_list;}},
  1968. pager: {
  1969. type: 1,
  1970. nextL: 'css;a.page-next',
  1971. pageE: 'css;.famous-ul > .famous-li',
  1972. replaceE: 'css;.page-container',
  1973. scrollD: 1000
  1974. },
  1975. function: {
  1976. bF: src_bF,
  1977. pF: [0, 'img[data-original]', 'data-original']
  1978. }
  1979. }, // 游侠网 - 分类页
  1980. ali213_gl: {
  1981. host: 'gl.ali213.net',
  1982. style: '.n_show_b, a.morezjjump {display: none !important;}',
  1983. pager: {
  1984. type: 3,
  1985. nextL: 'css;a.next',
  1986. pageE: 'css;.c-detail > *',
  1987. insertP: ['css;.c-detail', 3],
  1988. replaceE: 'css;.page_fenye',
  1989. scrollE: 'css;.page_fenye',
  1990. scrollD: 200
  1991. }
  1992. }, // 游侠网 - 攻略
  1993. ali213_pic: {
  1994. host: 'pic.ali213.net',
  1995. style: 'a.prev, a.next {display: none !important;}',
  1996. pager: {
  1997. type: 1,
  1998. nextL: 'css;a.next',
  1999. pageE: 'css;#image-show > img',
  2000. replaceE: 'css;#image-show > a',
  2001. scrollD: 1200
  2002. }
  2003. }, // 游侠网 - 图库
  2004. gamersky_ent: {
  2005. host: 'www.gamersky.com',
  2006. functionS: function() {if (indexOF('/ent/')) {curSite = DBSite.gamersky_ent;} else {curSite = DBSite.gamersky_gl;}},
  2007. pager: {
  2008. type: 3,
  2009. nextL: '//div[@class="page_css"]/a[text()="下一页"]',
  2010. pageE: 'css;.Mid2L_con > *:not(.gs_nc_editor):not(.pagecss):not(.page_css):not(.gs_ccs_solve):not(.post_ding)',
  2011. insertP: ['css;.page_css', 1],
  2012. replaceE: 'css;.page_css',
  2013. scrollE: 'css;.page_css',
  2014. scrollD: 0
  2015. }
  2016. }, // 游民星空
  2017. gamersky_gl: {
  2018. pager: {
  2019. type: 3,
  2020. nextL: '//div[@class="page_css"]/a[text()="下一页"]',
  2021. pageE: 'css;.Mid2L_con > *:not(.gs_nc_editor):not(.pagecss):not(.gs_ccs_solve):not(.post_ding)',
  2022. insertP: ['css;.gs_nc_editor', 1],
  2023. replaceE: 'css;.page_css',
  2024. scrollE: 'css;.page_css',
  2025. forceHTTPS: true,
  2026. scrollD: 0
  2027. },
  2028. function: {
  2029. bF: gamersky_gl_bF
  2030. }
  2031. }, // 游民星空 - 攻略
  2032. nexusmods: {
  2033. host: 'www.nexusmods.com',
  2034. functionS: function() {locationC = true; if (!(lp == '/' || indexOF(/\/mods\/\d+/))) {curSite = DBSite.nexusmods;}},
  2035. history: false,
  2036. pager: {
  2037. type: 1,
  2038. nextL: nexusmods_nextL,
  2039. pageE: 'css;ul.tiles > li',
  2040. replaceE: 'css;.pagination',
  2041. scrollD: 4000
  2042. },
  2043. function: {
  2044. bF: nexusmods_bF
  2045. }
  2046. }, // NexusMods
  2047. curseforge: {
  2048. host: 'www.curseforge.com',
  2049. pager: {
  2050. type: 1,
  2051. nextL: 'css;.pagination-next > a',
  2052. pageE: 'css;div.my-2',
  2053. replaceE: 'css;.pagination',
  2054. scrollD: 2500
  2055. }
  2056. }, // CurseForge
  2057. steamcommunity_workshop: {
  2058. host: 'steamcommunity.com',
  2059. functionS: function() {if (indexOF('/workshop/browse')) {curSite = DBSite.steamcommunity_workshop;} else if (indexOF(/eventcomments\/\d/)) {curSite = DBSite.steamcommunity_eventcomments;}},
  2060. pager: {
  2061. type: 1,
  2062. nextL: '//a[@class="pagebtn" and text()=">"]',
  2063. pageE: 'css;.workshopBrowseItems > *',
  2064. replaceE: 'css;.workshopBrowsePaging',
  2065. scriptT: 2,
  2066. scrollD: 1500
  2067. }
  2068. }, // Steam 创意工坊 - 项目列表
  2069. steamcommunity_eventcomments: {
  2070. style: '.forum_paging_controls {display: none !important;}',
  2071. pager: {
  2072. type: 1,
  2073. nextL: () => getNextUP('ctp=', /ctp=\d+/, location.pathname, '2', getCSS('span.commentthread_pagelinks > a:last-child').textContent),
  2074. pageE: 'css;.commentthread_comments > .commentthread_comment',
  2075. replaceE: 'css;.forum_paging .forum_paging_summary',
  2076. scriptT: 1,
  2077. scrollD: 1500
  2078. }
  2079. }, // Steam 社区 - 活动评论
  2080. yikm: {
  2081. host: 'www.yikm.net',
  2082. pager: {
  2083. type: 1,
  2084. nextL: '//ul[@class="pager"]//a[text()="下一页"]',
  2085. pageE: '//h2[contains(text(), "所有游戏") or contains(text(), "搜索结果")]/following-sibling::div[1]/div',
  2086. replaceE: 'css;ul.pager',
  2087. scrollD: 1500
  2088. }
  2089. }, // 小霸王其乐无穷
  2090. switch520: {
  2091. host: 'switch520.com',
  2092. functionS: function() {if (!indexOF('.html')) {curSite = DBSite.switch520;}},
  2093. pager: {
  2094. type: 1,
  2095. nextL: 'css;a.next',
  2096. pageE: 'css;.row.posts-wrapper > div',
  2097. replaceE: 'css;ul.page-numbers',
  2098. scrollD: 1000
  2099. }
  2100. }, // Switch520
  2101. cs_rin_ru: {
  2102. host: 'cs.rin.ru',
  2103. functionS: function() {if (lp == '/forum/viewforum.php') {
  2104. curSite = DBSite.cs_rin_ru;
  2105. } else if (lp == '/forum/search.php') {
  2106. curSite = DBSite.cs_rin_ru_search;
  2107. if (indexOF('sr=posts', 's')) curSite.pager.pageE = 'css;#wrapcentre > form > table.tablebg > tbody > tr[class^="row"]'
  2108. } else if (lp == '/forum/viewtopic.php' && GM_getValue('menu_thread')) {
  2109. curSite = DBSite.cs_rin_ru_list;
  2110. }},
  2111. pager: {
  2112. type: 1,
  2113. nextL: '//td[@class="gensmall"][@align="right"]//a[text()="Next"]',
  2114. pageE: 'css;#pagecontent > table.tablebg > tbody > tr:not([align])',
  2115. replaceE: 'css;#pagecontent > table:first-child',
  2116. scrollD: 1500
  2117. },
  2118. function: {
  2119. bF: cs_rin_ru_bF
  2120. }
  2121. }, // cs.rin.ru - 各版块帖子列表
  2122. cs_rin_ru_list: {
  2123. pager: {
  2124. type: 1,
  2125. nextL: 'id("pageheader")/p[@class="gensmall"]//a[text()="Next"]',
  2126. pageE: 'css;#pagecontent > table.tablebg:not(:nth-last-child(2)):not(:nth-child(2))',
  2127. replaceE: 'css;#pagecontent >table:not(.tablebg), #pageheader p.gensmall',
  2128. scrollD: 2000
  2129. }
  2130. }, // cs.rin.ru - 帖子内
  2131. cs_rin_ru_search: {
  2132. pager: {
  2133. type: 1,
  2134. nextL: 'id("wrapcentre")/div[@class="nav"]//a[text()="Next"]',
  2135. pageE: 'css;#wrapcentre > form > table.tablebg > tbody > tr[valign]',
  2136. replaceE: 'css;#wrapcentre > div',
  2137. scrollD: 1500
  2138. }
  2139. }, // cs.rin.ru - 搜索页
  2140. crackhub: {
  2141. host: 'crackhub.site',
  2142. style: 'html.wp-dark-mode-active .inside-article {background-color: var(--wp-dark-mode-bg);}',
  2143. pager: {
  2144. type: 1,
  2145. nextL: 'css;a.next.page-numbers',
  2146. pageE: 'css;article[id^="post-"]',
  2147. replaceE: 'css;nav.paging-navigation',
  2148. scrollD: 2000
  2149. }
  2150. }, // Crackhub213
  2151. fitgirl: {
  2152. host: 'fitgirl-repacks.site',
  2153. pager: {
  2154. type: 1,
  2155. nextL: 'css;a.next.page-numbers',
  2156. pageE: 'css;article[id^="post-"]',
  2157. replaceE: 'css;nav.paging-navigation',
  2158. scrollD: 2500
  2159. }
  2160. }, // FitGirl Repacks
  2161. bilibili_search: {
  2162. host: 'search.bilibili.com',
  2163. functionS: function() {
  2164. locationC = true;
  2165. if (lp == '/all' || lp == '/video') {
  2166. curSite = DBSite.bilibili_search;
  2167. } else if (lp == '/article') {
  2168. curSite = DBSite.bilibili_search_article;
  2169. }
  2170. },
  2171. retry: 100,
  2172. pager: {
  2173. type: 1,
  2174. nextL: bilibili_search_nextL,
  2175. pageE: '//ul[contains(@class, "video-list")]/li | //script[contains(text(), "window.__INITIAL_STATE__")]',
  2176. insertP: ['css;ul.video-list', 3],
  2177. replaceE: 'css;ul.pages',
  2178. scriptT: 2,
  2179. scrollD: 1000
  2180. },
  2181. function: {
  2182. bF: bilibili_search_bF,
  2183. aF: bilibili_search_aF
  2184. }
  2185. }, // B 站(Bilibili) - 搜索页 - 视频
  2186. bilibili_search_article: {
  2187. retry: 100,
  2188. pager: {
  2189. type: 1,
  2190. nextL: bilibili_search_nextL,
  2191. pageE: 'css;li.article-item',
  2192. replaceE: 'css;ul.pages',
  2193. //scriptT: 2,
  2194. scrollD: 1000
  2195. }
  2196. }, // B 站(Bilibili) - 搜索页 - 专栏
  2197. cupfox: {
  2198. host: 'www.cupfox.com',
  2199. pager: {
  2200. type: 2,
  2201. nextL: 'css;.load-more',
  2202. nextText: '点击加载更多',
  2203. scrollD: 700
  2204. }
  2205. }, // 茶杯狐
  2206. novipnoad: {
  2207. host: 'www.novipnoad.com',
  2208. functionS: function() {if (location.pathname != '/' && !indexOF('.html')) {curSite = DBSite.novipnoad;}},
  2209. pager: {
  2210. type: 1,
  2211. nextL: 'css;a.nextpostslink',
  2212. pageE: 'css;.video-listing-content .row > div',
  2213. replaceE: 'css;.wp-pagenavi',
  2214. scrollD: 1500
  2215. },
  2216. function: {
  2217. bF: src_bF,
  2218. pF: [0, 'img[data-original]', 'data-original']
  2219. }
  2220. }, // NO视频
  2221. ddrk: {
  2222. host: ['ddrk.me', 'ddys.tv'],
  2223. functionS: function() {if (lp == '/' || indexOF(/\/(category|tag)\//)) {curSite = DBSite.ddrk;}},
  2224. pager: {
  2225. type: 1,
  2226. nextL: 'css;a.next',
  2227. pageE: 'css;.post-box-list > article',
  2228. replaceE: 'css;.pagination_wrap',
  2229. scrollD: 1500
  2230. }
  2231. }, // 低端影视
  2232. nfmovies: {
  2233. host: 'www.nfmovies.com',
  2234. functionS: function() {if (lp == '/search.php' || indexOF('/list/')) {curSite = DBSite.nfmovies;}},
  2235. pager: {
  2236. type: 1,
  2237. nextL: '//ul[contains(@class, "myui-page")]/li/a[text()="下一页"]',
  2238. pageE: 'css;ul.myui-vodlist > li',
  2239. replaceE: 'css;ul.myui-page',
  2240. scrollD: 1500
  2241. },
  2242. function: {
  2243. bF: src_bF,
  2244. pF: [1, 'a[data-original]', 'data-original']
  2245. }
  2246. }, // 奈菲影视
  2247. zxzj: {
  2248. host: ['www.zxzj.me', 'www.zxzj.fun'],
  2249. functionS: function() {if (location.pathname != '/' && !indexOF('/detail/') && !indexOF('/video/')) {curSite = DBSite.zxzj;}},
  2250. style: 'div.stui-page__all {display: none !important;}',
  2251. pager: {
  2252. type: 1,
  2253. nextL: '//ul[contains(@class, "stui-page__item")]//a[text()="下一页"]',
  2254. pageE: 'css;ul.stui-vodlist > li',
  2255. replaceE: 'css;ul.stui-page__item',
  2256. scrollD: 1000
  2257. },
  2258. function: {
  2259. bF: src_bF,
  2260. pF: [1, 'a[data-original]', 'data-original']
  2261. }
  2262. }, // 在线之家
  2263. enlienli: {
  2264. host: 'enlienli.com',
  2265. functionS: function() {if (indexOF('/show/') || indexOF('/search')) {curSite = DBSite.enlienli;}},
  2266. pager: {
  2267. type: 1,
  2268. nextL: 'css;a.page-number.page-next',
  2269. pageE: 'css;.module-items > *',
  2270. replaceE: 'css;#page',
  2271. scrollD: 1000
  2272. },
  2273. function: {
  2274. bF: src_bF,
  2275. pF: [0, 'img[data-src]', 'data-src']
  2276. }
  2277. }, // 嗯哩嗯哩
  2278. mjw91: {
  2279. host: 'mjw91.com',
  2280. functionS: function() {if (!indexOF('/video/') || !indexOF('/vplay/')) {curSite = DBSite.mjw91;}},
  2281. pager: {
  2282. type: 1,
  2283. nextL: 'css;.next-page > a',
  2284. pageE: 'css;.m-movies > article',
  2285. replaceE: 'css;.pagination',
  2286. scrollD: 1500
  2287. },
  2288. function: {
  2289. bF: src_bF,
  2290. pF: [0, 'img[data-original]', 'data-original']
  2291. }
  2292. }, // 91 美剧网
  2293. zhenbuka: {
  2294. host: ['www.zhenbuka3.com', 'www.zhenbuka5.com'],
  2295. functionS: function() {if (indexOF('/vodtype/')) {curSite = DBSite.zhenbuka;}},
  2296. pager: {
  2297. type: 1,
  2298. nextL: '//ul[contains(@class, "stui-page")]/li/a[text()="下一页"]',
  2299. pageE: 'css;ul.stui-vodlist > li',
  2300. replaceE: 'css;ul.stui-page',
  2301. scrollD: 1500
  2302. },
  2303. function: {
  2304. bF: src_bF,
  2305. pF: [1, 'a[data-original]', 'data-original']
  2306. }
  2307. }, // 真不卡影院
  2308. zzzfun: {
  2309. host: 'www.zzzfun.com',
  2310. functionS: function() {
  2311. if (indexOF('/vod_type') || indexOF('/vod_show')) {
  2312. curSite = DBSite.zzzfun;
  2313. } else if (indexOF('/vod_search')) {
  2314. curSite = DBSite.zzzfun_search;
  2315. }},
  2316. pager: {
  2317. type: 1,
  2318. nextL: 'css;#page a[title="下一页"]',
  2319. pageE: 'css;ul.search-result > a',
  2320. replaceE: 'css;#page',
  2321. scrollD: 1000
  2322. },
  2323. function: {
  2324. bF: src_bF,
  2325. pF: [0, 'img[data-original]', 'data-original']
  2326. }
  2327. }, // ZzzFun 动漫
  2328. zzzfun_search: {
  2329. pager: {
  2330. type: 1,
  2331. nextL: 'css;#page a[title="下一页"]',
  2332. pageE: 'css;ul.show-list > li',
  2333. replaceE: 'css;#page',
  2334. scrollD: 1000
  2335. },
  2336. function: {
  2337. bF: src_bF,
  2338. pF: [0, 'img[data-original]', 'data-original']
  2339. }
  2340. }, // ZzzFun 动漫 - 搜索页
  2341. tucao: {
  2342. host: 'www.tucao.one',
  2343. functionS: function() {if (indexOF('/list/')) {
  2344. curSite = DBSite.tucao;
  2345. } else if (indexOF('search', 's')) {
  2346. curSite = DBSite.tucao_search;
  2347. }},
  2348. pager: {
  2349. type: 1,
  2350. nextL: 'css;.pagego a',
  2351. pageE: 'css;.list > ul > li',
  2352. replaceE: 'css;.newpages, .pagego, #float_show',
  2353. scrollD: 1000
  2354. }
  2355. }, // 吐槽弹幕网
  2356. tucao_search: {
  2357. pager: {
  2358. type: 1,
  2359. nextL: '//a[@class="a1"][contains(text(), "下一页")]',
  2360. pageE: 'css;.search_list > *',
  2361. replaceE: 'css;.pages',
  2362. scrollD: 1000
  2363. }
  2364. }, // 吐槽弹幕网 - 搜索页
  2365. mandao: {
  2366. host: 'www.mandao.tv',
  2367. functionS: function() {if (location.pathname != '/' && !indexOF('/man')) {
  2368. curSite = DBSite.mandao;
  2369. }},
  2370. pager: {
  2371. type: 1,
  2372. nextL: '//div[contains(@class, "page")]/a[text()=">"]',
  2373. pageE: 'css;.index-tj > ul > li',
  2374. replaceE: 'css;.page',
  2375. scrollD: 1000
  2376. },
  2377. function: {
  2378. bF: src_bF,
  2379. pF: [0, 'img[data-original]', 'data-original']
  2380. }
  2381. }, // 漫岛动漫
  2382. yxdm: {
  2383. host: 'www.yxdm.li',
  2384. functionS: function() {if (indexOF('/search') || indexOF('/category') || indexOF('/resource')) {curSite = DBSite.yxdm;}},
  2385. pager: {
  2386. type: 1,
  2387. nextL: '//a[@class="nextPage" or text()="下一页"]',
  2388. pageE: 'css;.dhnew > ul > li',
  2389. replaceE: 'css;.pagelist',
  2390. scrollD: 2000
  2391. }
  2392. }, // 怡萱动漫
  2393. nicotv: {
  2394. host: 'www.nicotv.me',
  2395. functionS: function() {if (indexOF('/search') || indexOF('/type')) {curSite = DBSite.nicotv;}},
  2396. pager: {
  2397. type: 1,
  2398. nextL: '//ul[contains(@class, "pagination ")]//a[text()="»"]',
  2399. pageE: 'css;ul.list-unstyled > li',
  2400. replaceE: 'css;ul.pagination ',
  2401. scrollD: 1000
  2402. },
  2403. function: {
  2404. bF: src_bF,
  2405. pF: [0, 'img[data-original]', 'data-original']
  2406. }
  2407. }, // 妮可动漫
  2408. yhdm: {
  2409. host: ['www.imomoe.la', 'www.imomoe.live'],
  2410. functionS: function() {if (indexOF('/list/')) {
  2411. curSite = DBSite.yhdm;
  2412. } else if (lp == '/so.asp' || lp == '/search.asp') {
  2413. curSite = DBSite.yhdm_;
  2414. }},
  2415. pager: {
  2416. type: 1,
  2417. nextL: '//div[@class="pages"]/a[text()="下一页"]',
  2418. pageE: 'css;#contrainer > .img> ul > li',
  2419. replaceE: 'css;.pages',
  2420. scrollD: 1000
  2421. }
  2422. }, // 樱花动漫
  2423. yhdm_: {
  2424. pager: {
  2425. type: 1,
  2426. nextL: '//div[@class="pages"]/a[text()="下一页"]',
  2427. pageE: 'css;#contrainer .fire .pics > ul > li',
  2428. replaceE: 'css;.pages',
  2429. scrollD: 1000
  2430. }
  2431. }, // 樱花动漫 - 搜索页等
  2432. agefans: {
  2433. host: ['www.agemys.com', 'www.age.tv'],
  2434. functionS: function() {if (indexOF('/catalog/') || lp == '/search') {
  2435. curSite = DBSite.agefans;
  2436. } else if (lp == '/recommend' || lp == '/update') {
  2437. curSite = DBSite.agefans_;
  2438. } else if (lp == '/rank') {
  2439. curSite = DBSite.agefans_rank;
  2440. }},
  2441. pager: {
  2442. type: 1,
  2443. nextL: 'id("container")//div[@class="blockcontent"]/div[@style][not(@class)]/li/a[contains(text(), "下一页")]',
  2444. pageE: 'css;#container .blockcontent1 > div',
  2445. replaceE: 'css;#container .blockcontent > div[style]:not([class])',
  2446. scrollD: 1000
  2447. }
  2448. }, // AGE 动漫 - 全部/搜索
  2449. agefans_: {
  2450. pager: {
  2451. type: 1,
  2452. nextL: 'id("container")//div[@class="blockcontent"]/div[@style][not(@class)]/li/a[contains(text(), "下一页")]',
  2453. pageE: 'css;#container .blockcontent > ul > li',
  2454. replaceE: 'css;#container .blockcontent > div[style]:not([class])',
  2455. scrollD: 1000
  2456. }
  2457. }, // AGE 动漫 - 其他页
  2458. agefans_rank: {
  2459. pager: {
  2460. type: 1,
  2461. nextL: 'id("container")/ul[@style][not(@class)]/li/a[contains(text(), "下一页")]',
  2462. pageE: 'css;#container > .div_right .blockcontent.div_right_r_3 > ul',
  2463. replaceE: 'css;#container > ul[style]:not([class])',
  2464. scrollD: 1000
  2465. }
  2466. }, // AGE 动漫 - 排行榜
  2467. dm233: {
  2468. host: 'www.dm233.cc',
  2469. functionS: function() {if (indexOF('/catalog/') || lp == '/recommend/' || lp == '/search') {
  2470. curSite = DBSite.dm233;
  2471. } else if (lp == '/article/') {
  2472. curSite = DBSite.dm233_article;
  2473. } else if (lp == '/rank/') {
  2474. curSite = DBSite.dm233_rank;
  2475. }},
  2476. pager: {
  2477. type: 1,
  2478. nextL: '//div[@class="pagelist"]//a[contains(text(), "下一页") or contains(text(), "下一頁")]',
  2479. pageE: 'css;.dhnew ul > li',
  2480. replaceE: 'css;.pagelist',
  2481. scrollD: 1000
  2482. }
  2483. }, // 233 动漫
  2484. dm233_article: {
  2485. pager: {
  2486. type: 1,
  2487. nextL: '//div[@class="pagelist"]//a[contains(text(), "下一页") or contains(text(), "下一頁")]',
  2488. pageE: 'css;.xgyd ul > li',
  2489. replaceE: 'css;.pagelist',
  2490. scrollD: 1000
  2491. }
  2492. }, // 233 动漫 - 动漫情报/资讯
  2493. dm233_rank: {
  2494. pager: {
  2495. type: 1,
  2496. nextL: '//div[@class="pagelist"]//a[contains(text(), "下一页") or contains(text(), "下一頁")]',
  2497. pageE: 'css;.side-update.normal-wai > .normal-nei',
  2498. replaceE: 'css;.pagelist',
  2499. scrollD: 1000
  2500. }
  2501. }, // 233 动漫 - 排行榜
  2502. anime1: {
  2503. host: 'anime1.me',
  2504. functionS: function() {if (indexOF('s=', 's')) {
  2505. curSite = DBSite.anime1_search;
  2506. } else if (lp == '/') {
  2507. curSite = DBSite.anime1;
  2508. }},
  2509. history: false,
  2510. pager: {
  2511. type: 4,
  2512. nextL: anime1_nextL,
  2513. interval: 500,
  2514. scrollD: 800
  2515. }
  2516. }, // Anime1
  2517. anime1_search: {
  2518. pager: {
  2519. type: 1,
  2520. nextL: 'css;.nav-previous > a',
  2521. pageE: 'css;#main > article',
  2522. replaceE: 'css;nav.navigation',
  2523. scrollD: 1200
  2524. }
  2525. }, // Anime1 - 搜索页
  2526. yinfans: {
  2527. host: /www\.yinfans\./,
  2528. style: '#post_container {height: auto !important;} #post_container > li {position: static !important; float: left !important; height: 620px !important;}',
  2529. pager: {
  2530. type: 1,
  2531. nextL: 'css;a.next',
  2532. pageE: 'css;#post_container > li',
  2533. replaceE: 'css;.pagination',
  2534. scrollD: 1500
  2535. }
  2536. }, // 音范丝
  2537. btbtt: {
  2538. host: /btbtt/,
  2539. pager: {
  2540. type: 1,
  2541. nextL: '//div[@class="page"]/a[contains(text(), "▶") or contains(text(), "下一页")]',
  2542. pageE: 'css;#threadlist > *',
  2543. replaceE: 'css;.page',
  2544. scrollD: 2000
  2545. }
  2546. }, // BT 之家
  2547. bdys: {
  2548. host: 'www.bd2020.com',
  2549. functionS: function() {if (location.pathname != '/' && !indexOF(/\/\d+\.htm/)) {curSite = DBSite.bdys;}},
  2550. pager: {
  2551. type: 2,
  2552. nextL: 'css;div.layui-flow-more > a',
  2553. nextText: '加载更多',
  2554. scrollD: 1000
  2555. }
  2556. }, // BD 影视
  2557. gaoqing_fm: {
  2558. host: 'gaoqing.fm',
  2559. pager: {
  2560. type: 2,
  2561. nextL: 'css;.col-md-12 > a, #loadmore > a',
  2562. interval: 1500,
  2563. scrollD: 1000
  2564. }
  2565. }, // 高清电台
  2566. yyds: {
  2567. host: 'yyds.fans',
  2568. functionS: function() {if (location.search != '' && !indexOF('p=', 's')) {curSite = DBSite.yyds;}},
  2569. pager: {
  2570. type: 1,
  2571. nextL: 'css;a.next.page-numbers',
  2572. pageE: 'css;.list-grouped > div',
  2573. replaceE: 'css;nav.pagination',
  2574. scrollD: 1100
  2575. }
  2576. }, // YYDS 电影
  2577. kisssub: {
  2578. host: ['www.kisssub.org','www.comicat.org', /(share|www)\.acgnx\./],
  2579. pager: {
  2580. type: 1,
  2581. nextL: 'css;a.nextprev:last-of-type',
  2582. pageE: 'css;#data_list > tr',
  2583. replaceE: 'css;.pages',
  2584. scrollD: 2500
  2585. }
  2586. }, // 爱恋动漫 / 漫猫动漫 / 末日动漫
  2587. dmhy: {
  2588. host: ['share.dmhy.org', 'dmhy.anoneko.com'],
  2589. pager: {
  2590. type: 1,
  2591. nextL: '//div[@class="nav_title"]/a[contains(text(), "下一")]',
  2592. pageE: 'css;#topic_list > tbody > tr',
  2593. replaceE: 'css;.nav_title',
  2594. scrollD: 1500
  2595. },
  2596. function: {
  2597. aF: function() {document.body.appendChild(document.createElement('script')).textContent = `$('#topic_list > tbody > tr:even:not(.even):not(.odd)').addClass('even'); $('#topic_list > tbody > tr:odd:not(.even):not(.odd)').addClass('odd');`;}
  2598. }
  2599. }, // 动漫花园
  2600. futaacg: {
  2601. host: /futaacg\./,
  2602. pager: {
  2603. type: 1,
  2604. nextL: 'css;ul.pagination a[rel="next"]',
  2605. pageE: 'css;.topic-list > div',
  2606. replaceE: 'css;ul.pagination',
  2607. scrollD: 1500
  2608. }
  2609. }, // 扶她动漫
  2610. acg_rip: {
  2611. host: 'acg.rip',
  2612. pager: {
  2613. type: 1,
  2614. nextL: 'css;li.next>a',
  2615. pageE: 'css;table.post-index > tbody > tr',
  2616. replaceE: 'css;ul.pagination',
  2617. scrollD: 1500
  2618. }
  2619. }, // ACG.RIP
  2620. bangumi: {
  2621. host: 'bangumi.moe',
  2622. functionS: function() {if (indexOF('/lite')) {curSite = DBSite.bangumi_lite;} else {curSite = DBSite.bangumi;}},
  2623. pager: {
  2624. type: 2,
  2625. nextL: 'css;[torrent-list="lattorrents"] button[ng-click="loadMore()"] ,[torrent-list="torrents"] button[ng-click="loadMore()"]',
  2626. interval: 1000,
  2627. scrollD: 1500
  2628. }
  2629. }, // 萌番组
  2630. bangumi_lite: {
  2631. pager: {
  2632. type: 1,
  2633. nextL: '//section/a[./span[contains(@class, "next")]]',
  2634. pageE: 'css;li.torrent-li',
  2635. replaceE: 'css;.page-btn-section',
  2636. scrollD: 2000
  2637. }
  2638. }, // 萌番组 lite
  2639. miobt: {
  2640. host: ['miobt.com', 'www.36dm.club'],
  2641. functionS: function() {curSite = DBSite.miobt; if (location.hostname === 'www.36dm.club') {curSite.pager.scrollD = 1000;}},
  2642. pager: {
  2643. type: 1,
  2644. nextL: '//a[@class="nextprev"][contains(text(), "〉") or contains(text(), "下一页") or contains(text(), "»")]',
  2645. pageE: 'css;#data_list > tr',
  2646. replaceE: 'css;.pages',
  2647. scrollD: 2000
  2648. }
  2649. }, // MioBT + 简单动漫
  2650. reimu: {
  2651. host: /\.reimu\./,
  2652. functionS: function() {if (lp == '/' || indexOF('/category') || indexOF('/tag')) curSite = DBSite.reimu},
  2653. pager: {
  2654. type: 1,
  2655. nextL: 'css;span.current+a.sfwppa-current-page',
  2656. pageE: 'css;article[id^="post-"]',
  2657. replaceE: 'css;.wp-pagenavi',
  2658. scrollD: 1500
  2659. }
  2660. }, // REIMU
  2661. hacg: {
  2662. host: /\.hacg\./,
  2663. functionS: function() {if (indexOF('/wp/') && !indexOF(/\d+\.html/)) curSite = DBSite.hacg},
  2664. pager: {
  2665. type: 1,
  2666. nextL: 'css;a.nextpostslink',
  2667. pageE: 'css;article[id^="post-"]',
  2668. replaceE: 'css;.wp-pagenavi',
  2669. scrollD: 1500
  2670. }
  2671. }, // HACG
  2672. nyaa: {
  2673. host: /nyaa\.si/,
  2674. pager: {
  2675. type: 1,
  2676. nextL: 'css;a[rel="next"], li.next > a',
  2677. pageE: 'css;table.torrent-list > tbody > tr',
  2678. replaceE: 'css;ul.pagination',
  2679. scrollD: 2000
  2680. }
  2681. }, // Nyaa
  2682. skrbt: {
  2683. host: /skrbt/,
  2684. functionS: function() {if (lp == '/search') curSite = DBSite.skrbt;},
  2685. pager: {
  2686. type: 1,
  2687. nextL: skrbt_nextL,
  2688. pageE: 'css;div[class="row"] > .col-md-6 > ul',
  2689. insertP: ['css;nav[aria-label*="Page"]', 1],
  2690. replaceE: 'css;ul.pagination',
  2691. scrollD: 900
  2692. }
  2693. }, // SkrBT
  2694. _1337x: {
  2695. host: /1337x\./,
  2696. functionS: function() {if (indexOF('search/')) {curSite = DBSite._1337x;}},
  2697. pager: {
  2698. type: 1,
  2699. nextL: '//div[@class="pagination"]//a[text()=">>"]',
  2700. pageE: 'css;table.table-list > tbody > tr',
  2701. replaceE: 'css;.pagination',
  2702. scrollD: 1200
  2703. }
  2704. }, // 1337x
  2705. rarbg: {
  2706. host: /rarbg/,
  2707. functionS: function() {if (lp == '/torrents.php') {curSite = DBSite.rarbg; rarbg_bF(getAllCSS('table.lista2t tr.lista2'));}},
  2708. style: 'html::-webkit-scrollbar {height: 0 !important;}',
  2709. pager: {
  2710. type: 1,
  2711. nextL: 'css;#pager_links > a[title="next page"]',
  2712. pageE: 'css;table.lista2t tr.lista2',
  2713. replaceE: 'css;#pager_links',
  2714. scrollD: 1200
  2715. },
  2716. function: {
  2717. bF: rarbg_bF
  2718. }
  2719. }, // RARBG
  2720. /*thepiratebay: {
  2721. host: 'thepiratebay.org',
  2722. functionS: function() {if (lp == '/search.php') {curSite = DBSite.thepiratebay;}},
  2723. pager: {
  2724. type: 6,
  2725. nextL: 'css;center > b+a[href]',
  2726. pageE: 'css;ol#torrents > li[id]',
  2727. replaceE: 'css;center',
  2728. loadTime: 1000,
  2729. scrollD: 1500
  2730. }
  2731. },*/ // thepiratebay
  2732. subdh: {
  2733. host: 'subdh.com',
  2734. functionS: function() {if (lp == '/' || indexOF('/list/new')) {curSite = DBSite.subdh;} else if (indexOF('/search')) {curSite = DBSite.subdh_search;}},
  2735. pager: {
  2736. type: 1,
  2737. nextL: '//a[@class="page-link"][contains(text(), "下一页")]',
  2738. pageE: 'css;.col-lg-9 .bg-white.shadow-sm.rounded-3 > .row.gx-0',
  2739. replaceE: 'css;ul.pagination',
  2740. scrollD: 1000
  2741. }
  2742. }, // SubDH
  2743. subdh_search: {
  2744. pager: {
  2745. type: 1,
  2746. nextL: '//a[@class="page-link"][contains(text(), "下一页")]',
  2747. pageE: 'css;.col-lg-9 .bg-white.shadow-sm.rounded-3',
  2748. insertP: ['css;nav[aria-label="pagination"]', 1],
  2749. replaceE: 'css;ul.pagination',
  2750. scrollD: 1000
  2751. }
  2752. }, // SubDH - 搜索页
  2753. mini4k: {
  2754. host: 'www.mini4k.com',
  2755. functionS: function() {if (location.pathname != '/' && !indexOF(/\/\d{3,}/)) {curSite = DBSite.mini4k;};},
  2756. pager: {
  2757. type: 1,
  2758. nextL: 'css;a.pager__item--next',
  2759. pageE: 'css;div[class*="-item-list"] > ul > li',
  2760. replaceE: 'css;.pagination',
  2761. scrollD: 2000
  2762. }
  2763. }, // MINI4K
  2764. bthaha: {
  2765. host: /bthaha/,
  2766. functionS: function() {if (indexOF('/search/')) {
  2767. curSite = DBSite.bthaha;
  2768. getAllCSS('[id^="list_top"], [id^="list_bottom"]').forEach(function (one) {one.parentElement.parentElement.hidden = true;});
  2769. }},
  2770. style: '[id^="list_top"], [id^="list_bottom"] {display: none !important;}',
  2771. pager: {
  2772. type: 1,
  2773. nextL: '//ul[@class="pagination"]/li/a[contains(text(), "下一页")]',
  2774. pageE: 'css;table.table > tbody > tr',
  2775. replaceE: 'css;ul.pagination',
  2776. scrollD: 1000
  2777. },
  2778. function: {
  2779. bF: bthaha_bF
  2780. }
  2781. }, // BTHaha
  2782. a4k: {
  2783. host: 'www.a4k.net',
  2784. functionS: function() {if (!indexOF('/subtitle/')) {curSite = DBSite.a4k;};},
  2785. pager: {
  2786. type: 1,
  2787. nextL: 'css;a.pager__item--next',
  2788. pageE: 'css;ul.list > li',
  2789. replaceE: 'css;.pagination',
  2790. scrollD: 1000
  2791. }
  2792. }, // A4k 字幕网(字幕)
  2793. assrt: {
  2794. host: 'assrt.net',
  2795. functionS: function() {if (location.pathname === '/sub/') {curSite = DBSite.assrt;} else if (indexOF('/list/')) {curSite = DBSite.assrt_list;}},
  2796. pager: {
  2797. type: 1,
  2798. nextL: () => getNextEP('css;#pl-current+a[href]:not([id])', 'page=', /page=\d+/),
  2799. pageE: 'css;.resultcard > div:not(#top-banner):not(#bottom-banner):not(.pagelinkcard)',
  2800. insertP: ['css;.pagelinkcard', 1],
  2801. replaceE: 'css;.pagelinkcard',
  2802. scrollD: 1000
  2803. }
  2804. }, // 射手网(字幕)
  2805. assrt_list: {
  2806. pager: {
  2807. type: 1,
  2808. nextL: '//a[@id="pl-nav" and text()=">"]',
  2809. pageE: 'css;#resultsdiv > .subitem:not([id])',
  2810. replaceE: 'css;.pagelinkcard',
  2811. scrollD: 1000
  2812. }
  2813. }, // 射手网(字幕)
  2814. subhd: {
  2815. host: 'subhd.tv',
  2816. functionS: function() {if (lp == '/forum/forum') {
  2817. curSite = DBSite.subhd_forum;
  2818. } else if (location.pathname != '/' && location.pathname != '/zu' && !indexOF('/a/') && !indexOF('/d/') && !indexOF('/forum/')) {
  2819. curSite = DBSite.subhd;
  2820. }},
  2821. pager: {
  2822. type: 1,
  2823. nextL: '//a[@class="page-link"][contains(text(), "下一页")]',
  2824. pageE: 'css;.bg-white.shadow-sm.rounded-3',
  2825. insertP: ['css;nav.clearfix', 1],
  2826. replaceE: 'css;nav.clearfix',
  2827. scrollD: 1000
  2828. }
  2829. }, // SubHD(字幕)
  2830. subhd_forum: {
  2831. pager: {
  2832. type: 1,
  2833. nextL: '//a[@class="page-link"][contains(text(), "下一页")]',
  2834. pageE: 'css;.bg-white.shadow-sm.rounded-3 > div',
  2835. replaceE: 'css;nav.clearfix',
  2836. scrollD: 800
  2837. }
  2838. }, // SubHD - forum(字幕)
  2839. manben: {
  2840. host: 'www.manben.com',
  2841. functionS: function() {if (indexOF(/\/m\d+/)) {
  2842. if (getCookie('showtype') != '2') {
  2843. document.cookie='showtype=2; expires=Thu, 18 Dec 2031 12:00:00 GMT; path=/'; // 写入 Cookie 开启 [垂直阅读] 模式
  2844. location.reload(); // 刷新网页
  2845. }
  2846. curSite = DBSite.mhxqiu;
  2847. }}
  2848. }, // 漫本
  2849. haoman: {
  2850. host: ['www.haoman6.com', 'www.g-lens.com'],
  2851. functionS: function() {
  2852. if (indexOF('/chapter/')) {
  2853. curSite = DBSite.haoman;
  2854. if (location.hostname == 'www.g-lens.com') curSite.function.pF = [0, 'img[data-echo]', 'data-echo']
  2855. } else if (indexOF('/comic/')) {
  2856. if (getCSS('.chapter__more')) getCSS('.chapter__more').click();
  2857. } else if (indexOF('/category/') || indexOF('/search')) {
  2858. curSite = DBSite.haoman_list;
  2859. }},
  2860. style: '.rd-guess, .rd-aside, .page-index__btn {display: none !important;} .rd-article__pic {display: initial !important;} .rd-article__pic > img {margin: 0 auto;display: block;height: auto;min-height: 200px;}',
  2861. pager: {
  2862. type: 1,
  2863. nextL: function() {if (getCSS('a.rd-aside__item.j-rd-next')) return location.origin + getCSS('a.rd-aside__item.j-rd-next').getAttribute('_href')},
  2864. pageE: 'css;.rd-article-wr > div',
  2865. replaceE: 'css;a.last-crumb, .rd-aside',
  2866. interval: 2000,
  2867. scrollD: 2000
  2868. },
  2869. function: {
  2870. bF: src_bF,
  2871. pF: [0, 'img[dta-echo]', 'dta-echo']
  2872. }
  2873. }, // 好漫 6
  2874. haoman_list: {
  2875. pager: {
  2876. type: 1,
  2877. nextL: 'css;a.next',
  2878. pageE: 'css;.cate-comic-list > div',
  2879. replaceE: 'css;#Pagination',
  2880. scrollD: 1000
  2881. },
  2882. function: {
  2883. bF: src_bF,
  2884. pF: [0, 'img[data-original]', 'data-original']
  2885. }
  2886. }, // 好漫 6 - 分类/搜索页
  2887. cartoonmad: {
  2888. host: ['www.cartoonmad.com','www.cartoonmad.cc'],
  2889. functionS: function() {if (indexOF('/comic/')) {
  2890. getCSS('body > table > tbody > tr:nth-child(4) > td > table > tbody > tr:first-child > td:first-child > a').href = 'javascript:void(0);'; // 清理图片上的链接
  2891. curSite = DBSite.cartoonmad;
  2892. } else if (location.pathname != '/') {
  2893. curSite = DBSite.cartoonmad_list;
  2894. }},
  2895. style: 'body > table > tbody > tr:nth-child(4) > td > table > tbody > tr:first-child > td:not(:first-child) {display: none !important;} body > table > tbody > tr:nth-child(4) > td > table > tbody > tr:first-child > td:first-child img {max-width: 100%;height: auto;display: block !important;margin: 0 auto !important;}',
  2896. pager: {
  2897. type: 1,
  2898. nextL: cartoonmad_nextL,
  2899. pageE: 'css;body > table > tbody > tr:nth-child(4) > td > table > tbody > tr:first-child > td:first-child img',
  2900. replaceE: 'css;body > table > tbody > tr:nth-child(2), body > table > tbody > tr:nth-child(5)',
  2901. scrollD: 2000
  2902. }
  2903. }, // 动漫狂
  2904. cartoonmad_list: {
  2905. pager: {
  2906. type: 1,
  2907. nextL: '//a[@class="pages"][contains(text(), "下一頁")]',
  2908. pageE: 'css;td[background="/image/content_box4.gif"]+td > table > tbody > tr',
  2909. replaceE: '//a[@class="pages"]/parent::td/parent::tr | //font[contains(text(), "目前在第")]',
  2910. scrollD: 1000
  2911. }
  2912. }, // 动漫狂 - 分类/搜索页
  2913. dongman: {
  2914. host: 'www.dongman.la',
  2915. functionS: function() {if (indexOF('/chapter/')) {
  2916. src_bF(getAllCSS('img.mdui-img-fluid[data-srcset]:not([src])'), [0, 'img[data-srcset]', 'data-srcset']);
  2917. curSite = DBSite.dongman;
  2918. } else if (indexOF('/detail/')) {
  2919. setTimeout(function(){getCSS('a#zhankai').click()}, 500)
  2920. } else if (indexOF('/manhua/')) {
  2921. curSite = DBSite.dongman_list;
  2922. }},
  2923. style: 'button.prePic, button.nextPic, footer, header, #left-drawer {display: none !important;} body, #app {padding: 0 !important;} .slick-track {width: 100% !important;} .lazyBox {width: 100%; display: inline-block;}',
  2924. pager: {
  2925. type: 1,
  2926. nextL: '//footer//a[./label[text()="下一章"]]',
  2927. pageE: 'css;.lazyBox',
  2928. insertP: ['css;.slick-track', 3],
  2929. replaceE: 'css;footer',
  2930. scrollD: 3000
  2931. },
  2932. function: {
  2933. bF: src_bF,
  2934. pF: [0, 'img[data-srcset]', 'data-srcset']
  2935. }
  2936. }, // 动漫啦
  2937. dongman_list: {
  2938. pager: {
  2939. type: 1,
  2940. nextL: '//a[@class="GPageLink" and text()="下一页"]',
  2941. pageE: 'css;.cy_list_mh > ul',
  2942. replaceE: 'css;.NewPages',
  2943. scrollD: 2000
  2944. }
  2945. }, // 动漫啦 - 分类页
  2946. manhuacat: {
  2947. host: ['www.manhuacat.com', 'www.maofly.com'],
  2948. functionS: function() {if (indexOF(/\/manga\/\d+\/.+\.html/)) {
  2949. if (getCookie('is_pull') == 'true') { // 强制关闭 [下拉] 模式
  2950. document.cookie='is_pull=false; expires=Thu, 18 Dec 2031 12:00:00 GMT; path=/'; // 写入 Cookie 关闭 [下拉] 模式
  2951. location.reload(); // 刷新网页
  2952. }
  2953. setTimeout(manhuacat_init, 100);
  2954. curSite = DBSite.manhuacat;
  2955. } else if (indexOF('/list')) {
  2956. curSite = DBSite.manhuacat_list;
  2957. } else if (indexOF('/search') || indexOF('/update')) {
  2958. curSite = DBSite.manhuacat_search;
  2959. }},
  2960. style: '#left, #right, #pull-load, .loading, .pagination, footer {display: none !important;} .img-content > img {display: block !important;margin: 0 auto !important; border: none !important; padding: 0 !important; max-width: 99% !important; height: auto !important;}', // 隐藏不需要的元素,调整图片
  2961. pager: {
  2962. type: 4,
  2963. nextL: manhuacat_nextL,
  2964. insertP: ['css;.img-content', 3],
  2965. insertE: manhuacat_insertE,
  2966. replaceE: 'css;.comic-detail > .breadcrumb-bar, .comic-detail >h2.h4, .vg-r-data, body > script:not([src])',
  2967. interval: 2000,
  2968. scrollD: 3000
  2969. }
  2970. }, // 漫画猫
  2971. manhuacat_list: {
  2972. pager: {
  2973. type: 1,
  2974. nextL: '//div[contains(@class, "pagination")]//a[contains(text(), "下一页") or contains(text(), "下页")]',
  2975. pageE: 'css;.comic-main-section > *',
  2976. replaceE: 'css;.pagination',
  2977. scrollD: 1000
  2978. },
  2979. function: {
  2980. bF: src_bF,
  2981. pF: [0, 'img[data-original]', 'data-original']
  2982. }
  2983. }, // 漫画猫 - 分类页
  2984. manhuacat_search: {
  2985. pager: {
  2986. type: 1,
  2987. nextL: '//div[contains(@class, "pagination")]//a[contains(text(), "下一页") or contains(text(), "下页")]',
  2988. pageE: 'css;.comic-main-section .row > div',
  2989. replaceE: 'css;.pagination',
  2990. scrollD: 1000
  2991. }
  2992. }, // 漫画猫 - 搜索页
  2993. manhuatai: {
  2994. host: 'www.manhuatai.net',
  2995. functionS: function() {if (indexOF('/manhua/')) {
  2996. curSite = DBSite.manhuatai;
  2997. } else if (indexOF('/fenlei_') || indexOF('/top_')) {
  2998. curSite = DBSite.manhuatai_list;
  2999. } else if (indexOF('/search')) {
  3000. curSite = DBSite.manhuatai_search;
  3001. }},
  3002. pager: {
  3003. type: 1,
  3004. nextL: '//div[contains(@class, "page")]//a[@href][contains(text(), "下一页") or contains(text(), "下一章")]',
  3005. pageE: 'css;#htmlContent p.img > img',
  3006. replaceE: 'css;.page, .title',
  3007. scrollD: 2000
  3008. }
  3009. }, // 漫画台
  3010. manhuatai_list: {
  3011. pager: {
  3012. type: 1,
  3013. nextL: 'css;#pagelink a.next',
  3014. pageE: 'css;.article-list',
  3015. replaceE: 'css;#pagelink',
  3016. scrollD: 1500
  3017. }
  3018. }, // 漫画台 - 分类页
  3019. manhuatai_search: {
  3020. pager: {
  3021. type: 1,
  3022. nextL: 'css;#pagelink a.next',
  3023. pageE: 'css;#content > table > tbody > tr:not([align])',
  3024. replaceE: 'css;#pagelink',
  3025. scrollD: 1500
  3026. }
  3027. }, // 漫画台 - 搜索页
  3028. manhuapi: {
  3029. host: 'www.manhuapi.com',
  3030. functionS: function() {if (indexOF('/chapter/')) {
  3031. curSite = DBSite.manhuapi;
  3032. } else if (!indexOF(/\/manhua\/\d+\.html/)) {
  3033. curSite = DBSite.manhuapi_list;
  3034. }},
  3035. pager: {
  3036. type: 1,
  3037. nextL: '//div[@class="page"]/a[text()="下一页" or text()="下一章"]',
  3038. pageE: 'css;.mh_list img[src]',
  3039. replaceE: 'css;.page',
  3040. scrollD: 2000
  3041. }
  3042. }, // 漫画皮
  3043. manhuapi_list: {
  3044. pager: {
  3045. type: 1,
  3046. nextL: '//div[@class="pages"]/a[text()="下一页"]',
  3047. pageE: 'css;.cy_list_mh > ul',
  3048. replaceE: 'css;.pages',
  3049. scrollD: 1500
  3050. }
  3051. }, // 漫画皮 - 分类页
  3052. imanhuaw: {
  3053. host: ['www.imanhuaw.net', 'www.imanhuaw.com', 'www.ccshwy.com'],
  3054. functionS: function() {
  3055. if (getCSS('.mh-search-result')) {
  3056. curSite = DBSite.imanhuaw_list;
  3057. } else if (getCSS('a#zhankai')) {
  3058. getCSS('a#zhankai').click();
  3059. } else if (indexOF(/\/\d{3,}\.html/)) {
  3060. curSite = DBSite.imanhuaw; imanhuaw_init();
  3061. }
  3062. },
  3063. style: '#sider-left, #sider-right, .main-left, .main-right, .w996.tc, .title > span {display: none !important;} #qTcms_Pic_middle img {max-width: 110%;height: auto;}',
  3064. pager: {
  3065. type: 4,
  3066. nextL: imanhuaw_nextL,
  3067. insertP: ['css;#qTcms_Pic_middle img:last-of-type', 4],
  3068. insertE: imanhuaw_insertE,
  3069. replaceE: 'css;.title h2',
  3070. interval: 2000,
  3071. scrollD: 3000
  3072. }
  3073. }, // 爱漫画 + 188漫画网
  3074. imanhuaw_list: {
  3075. pager: {
  3076. type: 1,
  3077. nextL: '//div[@class="NewPages"]//a[text()="下一页"]',
  3078. pageE: 'css;ul.mh-search-list > li',
  3079. replaceE: 'css;.NewPages',
  3080. scrollD: 1500
  3081. }
  3082. }, // 爱漫画 - 分类页
  3083. manhuagui: {
  3084. host: ['www.mhgui.com', 'tw.mhgui.com', 'www.manhuagui.com', 'tw.manhuagui.com'],
  3085. functionS: function() {if (indexOF(/\/comic\/\d+\/\d+\.html/)) {
  3086. if (!getXpath('//li[@class="pfunc"]/a[@class="current"][text()="双击" or text()="雙擊"]')) getXpath('//li[@class="pfunc"]/a[text()="双击" or text()="雙擊"]').click();
  3087. pausePage = false;
  3088. setTimeout(manhuagui_init, 100);
  3089. curSite = DBSite.manhuagui;
  3090. } else if (indexOF('list/') || indexOF('/s/')) {
  3091. curSite = DBSite.manhuagui_list;
  3092. }},
  3093. style: '.sub-btn, .tc {display: none !important;} #mangaBox > img {width: auto !important;height: auto !important;display: block !important;margin: 0 auto !important;max-width: 100% !important;}',
  3094. pager: {
  3095. type: 4,
  3096. nextL: manhuagui_nextL,
  3097. pageE: 'css;body > script:not([src])',
  3098. insertP: ['css;#mangaBox', 3],
  3099. insertE: manhuagui_insertE,
  3100. replaceE: 'css;title',
  3101. interval: 4000,
  3102. scrollD: 2500
  3103. }
  3104. }, // 漫画柜
  3105. manhuagui_list: {
  3106. pager: {
  3107. type: 1,
  3108. nextL: '//div[@class="pager"]/a[text()="下一页" or text()="下一頁"]',
  3109. pageE: 'css;.book-result > ul > li, .book-list > ul > li',
  3110. insertP: ['css;.book-result > ul, .book-list > ul', 3],
  3111. replaceE: 'css;.pager',
  3112. scrollD: 1500
  3113. },
  3114. function: {
  3115. bF: src_bF,
  3116. pF: [0, 'img[data-src]', 'data-src']
  3117. }
  3118. }, // 漫画台 - 分类/搜索页
  3119. _36manga: {
  3120. host: ['36manga.com', 'www.36manga.com', '36manhua.com', 'www.36manhua.com'],
  3121. functionS: function() {if (indexOF(/\/manhua\/.+\/\d+\.html/)) {
  3122. if (localStorage.getItem('chapterScroll') != '"pagination"') {
  3123. localStorage.setItem('chapterScroll', '"pagination"'); location.reload()
  3124. } else {
  3125. pausePage = false;
  3126. setTimeout(_36manga_init, 100);
  3127. curSite = DBSite._36manga;
  3128. }
  3129. } else if (indexOF('list/') || indexOF('/search/')) {
  3130. curSite = DBSite._36manga_list;
  3131. }},
  3132. style: '#sider-left, #sider-right, p.img_info, .tc, .chapter-view + .w996 {display: none !important;} #images > img {width: auto !important;height: auto !important;display: block !important;margin: 0 auto !important;max-width: 100% !important;}',
  3133. pager: {
  3134. type: 4,
  3135. nextL: _36manga_nextL,
  3136. pageE: '//body/script[contains(text(), "chapterImages")]',
  3137. insertP: ['css;#images', 3],
  3138. insertE: _36manga_insertE,
  3139. replaceE: 'css;.title',
  3140. interval: 4000,
  3141. scrollD: 2500
  3142. }
  3143. }, // 36漫画
  3144. _36manga_list: {
  3145. pager: {
  3146. type: 1,
  3147. nextL: 'css;ul.pagination li.next a',
  3148. pageE: 'css;#contList',
  3149. replaceE: 'css;ul.pagination',
  3150. scrollD: 1500
  3151. }
  3152. }, // 36漫画 - 分类/搜索页
  3153. manhuadb: {
  3154. host: 'www.manhuadb.com',
  3155. functionS: function() {if (indexOF(/\/manhua\/\d+\/.+\.html/)) {
  3156. if (getCSS('img.img-fluid.show-pic')) getCSS('img.img-fluid.show-pic').style.display = 'none'; // 隐藏第一个图片(避免重复)
  3157. setTimeout(manhuadb_init, 100);
  3158. curSite = DBSite.manhuadb;
  3159. } else if (indexOF('/list')) {
  3160. curSite = DBSite.manhuacat_list;
  3161. } else if (indexOF('/search') || indexOF('/update')) {
  3162. curSite = DBSite.manhuacat_search;
  3163. }},
  3164. style: '.row.m-0.pt-3.ad_2_wrap, .row.m-0.ad_1_wrap, .pagination.justify-content-center, #left, #right {display: none !important;}',
  3165. pager: {
  3166. type: 4,
  3167. nextL: manhuadb_nextL,
  3168. pageE: 'css;body > script:not([type]):not([src]), .vg-r-data, ol.links-of-books.num_div',
  3169. insertP: ['css;.pjax-container', 3],
  3170. insertE: manhuadb_insertE,
  3171. interval: 5000,
  3172. scrollD: 3000
  3173. }
  3174. }, // 漫画 DB
  3175. hicomic: {
  3176. host: 'www.hicomic.net',
  3177. functionS: function() {if (indexOF('/chapters/')) {
  3178. setTimeout(hicomic_init, 100);
  3179. curSite = DBSite.hicomic;
  3180. }},
  3181. style: '.content {height: auto !important;} .footer, .left_cursor, .right_cursor, .finish {display: none !important;} .content > img {display: block !important;margin: 0 auto !important;}',
  3182. pager: {
  3183. type: 4,
  3184. nextL: hicomic_nextL,
  3185. insertP: ['css;.content', 3],
  3186. insertE: hicomic_insertE,
  3187. interval: 5000,
  3188. scrollD: 3000
  3189. }
  3190. }, // HiComic (嗨漫画)
  3191. dmzj: {
  3192. host: 'www.dmzj.com',
  3193. functionS: function() {if (indexOF('/view/')) {
  3194. if (getCookie('display_mode') != '1') { // 强制开启 [上下滚动阅读] 模式
  3195. document.cookie='display_mode=1; expires=Thu, 18 Dec 2031 12:00:00 GMT; path=/'; // 写入 Cookie 开启 [上下滚动阅读] 模式
  3196. location.reload(); // 刷新网页
  3197. }
  3198. setTimeout(function() {dmzj_init('.comic_wraCon > a > img')}, 100);
  3199. curSite = DBSite.dmzj;
  3200. } else if (indexOF('/category') || indexOF('/update')) {
  3201. curSite = DBSite.dmzj_list;
  3202. } else if (indexOF('/rank')) {
  3203. curSite = DBSite.dmzj_rank;
  3204. }},
  3205. style: 'p.mh_curr_page, .btmBtnBox, .float_code, #floatCode {display: none !important;} .comic_wraCon > img {display: block !important;margin: 0 auto !important; border: none !important; padding: 0 !important; max-width: 99% !important; height: auto !important;}', // 隐藏中间的页数信息
  3206. pager: {
  3207. type: 4,
  3208. nextL: 'css;span.next > a',
  3209. insertP: ['css;.comic_wraCon', 3],
  3210. insertE: dmzj_insertE,
  3211. replaceE: 'css;.wrap_last_mid, .wrap_last_head',
  3212. interval: 2000,
  3213. scrollD: 3000
  3214. }
  3215. }, // 动漫之家 - 原创
  3216. dmzj_list: {
  3217. style: '.wrap_mhlist_l.con_left, .wrap_list {height: auto!important;}',
  3218. pager: {
  3219. type: 1,
  3220. nextL: 'css;a.pg_next',
  3221. pageE: 'css;ul.list_con_li > li',
  3222. replaceE: 'css;.page',
  3223. scrollD: 1000
  3224. }
  3225. }, // 动漫之家 - 原创 - 分类页
  3226. dmzj_rank: {
  3227. style: '.wrap_mhlist_l.con_left {height: auto!important;}',
  3228. pager: {
  3229. type: 1,
  3230. nextL: 'css;a.pg_next',
  3231. pageE: 'css;.ph_r_con_li > div:not(.ad_column)',
  3232. replaceE: 'css;.page',
  3233. scrollD: 1000
  3234. }
  3235. }, // 动漫之家 - 原创 - 排行榜
  3236. dmzj_manhua: {
  3237. host: 'manhua.dmzj.com',
  3238. functionS: function() {if (indexOF(/\/\d+\.shtml/)) {
  3239. let chapterScroll = getCSS('#qiehuan_txt') // 强制为 [上下滚动阅读] 模式
  3240. if (chapterScroll && chapterScroll.textContent === '切换到上下滚动阅读') {chapterScroll.click();}
  3241. setTimeout(function() {dmzj_init('#center_box > .inner_img img[src]')}, 100);
  3242. curSite = DBSite.dmzj_manhua;
  3243. } else if (indexOF('/tags/')) {
  3244. curSite = DBSite.dmzj_manhua_list;
  3245. } else if (indexOF('/update')) {
  3246. curSite = DBSite.dmzj_manhua_update;
  3247. }},
  3248. style: 'p.curr_page, .btmBtnBox, .float_code, #floatCode {display: none !important;} #center_box > img {display: block !important;margin: 0 auto !important; border: none !important; padding: 0 !important; max-width: 99% !important; height: auto !important;}', // 隐藏中间的页数信息
  3249. pager: {
  3250. type: 4,
  3251. nextL: 'css;#next_chapter',
  3252. insertP: ['css;#center_box', 3],
  3253. insertE: dmzj_manhua_insertE,
  3254. replaceE: 'css;.display_graybg',
  3255. interval: 2000,
  3256. scrollD: 3000
  3257. }
  3258. }, // 动漫之家 - 日漫
  3259. dmzj_manhua_list: {
  3260. pager: {
  3261. type: 1,
  3262. nextL: () => getNextUPN(/(?<=-)\d+(?=\.shtml)/, /-\d+\.shtml/, '-', '.shtml', '2', getCSS('#topage > option:last-child').value),
  3263. pageE: 'css;#search_list_div ul',
  3264. scrollD: 1500
  3265. }
  3266. }, // 蓝点网
  3267. dmzj_manhua_update: {
  3268. pager: {
  3269. type: 1,
  3270. nextL: '//div[@class="pages"]/a[contains(text(), "下一页")]',
  3271. pageE: 'css;.newpic_content > *:not(.pages)',
  3272. replaceE: 'css;.pages',
  3273. scrollD: 1000
  3274. }
  3275. }, //动漫之家 - 日漫 - 最新更新
  3276. acgn: {
  3277. host: 'comic.acgn.cc',
  3278. functionS: function() {
  3279. if (indexOF('/view-')) {
  3280. curSite = DBSite.acgn;
  3281. acgn_aF();
  3282. } else if (indexOF('/cate-') || indexOF('/pinyin-')) {
  3283. curSite = DBSite.acgn_list;
  3284. }
  3285. },
  3286. style: '.img1 {cursor: initial !important;}',
  3287. pager: {
  3288. type: 1,
  3289. nextL: 'css;#next_chapter',
  3290. pageE: 'css;.pic[_src]',
  3291. replaceE: 'css;[class^="display_"]',
  3292. interval: 2000,
  3293. scrollD: 2000
  3294. },
  3295. function: {
  3296. aF: acgn_aF
  3297. }
  3298. }, // 动漫戏说
  3299. acgn_list: {
  3300. pager: {
  3301. type: 1,
  3302. nextL: 'css;a[rel="next"]',
  3303. pageE: 'css;ul#display > li',
  3304. replaceE: 'css;#pagination',
  3305. scrollD: 1000
  3306. }
  3307. }, // 动漫戏说 - 分类页
  3308. ykmh: {
  3309. host: 'www.ykmh.com',
  3310. functionS: function() {if (indexOF(/\/\d+\.html/)) {
  3311. let chapterScroll = getCSS('#qiehuan_txt') // 强制为 [上下滚动阅读] 模式
  3312. if (localStorage.getItem('chapterScroll') != '"scroll"') {
  3313. localStorage.setItem('chapterScroll', '"scroll"'); location.reload()
  3314. } else {
  3315. setTimeout(ykmh_init, 100);
  3316. curSite = DBSite.ykmh;
  3317. }
  3318. } else if (indexOF('/list') || indexOF('/search')) {
  3319. curSite = DBSite.ykmh_list;
  3320. }},
  3321. style: 'p.img_info {display: none !important;} #images > img {display: block !important;margin: 0 auto !important; border: none !important; padding: 0 !important; max-width: 99% !important; height: auto !important;}',
  3322. pager: {
  3323. type: 4,
  3324. nextL: ykmh_nextL,
  3325. insertP: ['css;#images', 3],
  3326. insertE: ykmh_insertE,
  3327. replaceE: 'css;.head_title, span.head_wz',
  3328. interval: 2000,
  3329. scrollD: 3000
  3330. }
  3331. }, // 优酷漫画
  3332. ykmh_list: {
  3333. pager: {
  3334. type: 1,
  3335. nextL: 'css;li.next > a',
  3336. pageE: 'css;li.list-comic',
  3337. replaceE: 'css;ul.pagination',
  3338. scrollD: 1000
  3339. }
  3340. }, // 优酷漫画 - 分类页
  3341. copymanga: {
  3342. host: /copymanga\./,
  3343. functionS: function() {if (indexOF('/chapter/')) {
  3344. curSite = DBSite.copymanga;
  3345. } else if (indexOF('/comics')) {
  3346. curSite = DBSite.copymanga_list;
  3347. }},
  3348. style: '.upMember, .comicContainerAds, .footer {display: none !important;} body, html {height: auto !important;}',
  3349. iframe: true,
  3350. pager: {
  3351. type: 5,
  3352. nextL: 'css;.comicContent-next > a',
  3353. style: 'h4.header, h4.header +div[style*="fixed"] {display: none !important;}',
  3354. scrollD: 3000
  3355. }
  3356. }, // 拷贝漫画
  3357. copymanga_list: {
  3358. pager: {
  3359. type: 1,
  3360. nextL: 'css;li.next > a',
  3361. pageE: 'css;.exemptComic-box > div',
  3362. replaceE: 'css;ul.page-all',
  3363. scrollD: 1500
  3364. },
  3365. function: {
  3366. bF: src_bF,
  3367. pF: [0, 'img[data-src]', 'data-src']
  3368. }
  3369. }, // 拷贝漫画 - 分类页
  3370. mhxqiu: {
  3371. host: /\.mhxqiu/,
  3372. functionS: function() {if (indexOF(/\/\d+\.html/)) { // 阅读页
  3373. curSite = DBSite.mhxqiu;
  3374. } else if (indexOF(/\/\d+\/$/)) { // 目录页
  3375. setTimeout(function(){if (getCSS('#zhankai')) getCSS('#zhankai').click();}, 500)
  3376. } else if (indexOF(/\/(sort|rank)\//)) { // 分类页
  3377. curSite = DBSite.mhxqiu_list;
  3378. }},
  3379. style: '.imgFloat_1, .imgFloat_2, .main_control, span.comic-ft {display: none !important;} html, body, #mainView {height: auto !important;} body.view .main ul.comic-contain li{margin:0 auto !important;} .comic-contain .loaded{box-shadow: none !important;}',
  3380. pager: {
  3381. type: 4,
  3382. nextL: 'css;#mainControlNext',
  3383. insertP: ['css;#comicContain', 3],
  3384. insertE: mhxqiu_insertE,
  3385. replaceE: 'css;.main_control, h1.chaptername_title, span.title-comicHeading',
  3386. interval: 4000,
  3387. scrollD: 3000
  3388. }
  3389. }, // 漫画星球
  3390. mhxqiu_list: {
  3391. pager: {
  3392. type: 1,
  3393. nextL: '//div[@class="NewPages"]//a[contains(text(), "下一页")]',
  3394. pageE: 'css;.cy_list_mh > ul',
  3395. replaceE: 'css;.NewPages',
  3396. scrollD: 1000
  3397. }
  3398. }, // 漫画星球 - 分类页
  3399. fffdm: {
  3400. host: 'manhua.fffdm.com',
  3401. functionS: function() {if (location.pathname.split('/').length === 4) {curSite = DBSite.fffdm;}},
  3402. style: '#footer, #header {display: none !important;} #mhimg0 img {display: block !important;margin: 0 auto !important;}',
  3403. pager: {
  3404. type: 4,
  3405. nextL: '//a[contains(text(), "下一页") or contains(text(), "下一頁") or contains(text(), "下一话") or contains(text(), "下一話")]',
  3406. insertP: ['css;#mhimg0', 3],
  3407. insertE: fffdm_insertE,
  3408. replaceE: 'css;.navigation, #weizhi, h1',
  3409. scrollD: 2000
  3410. }
  3411. }, // 风之动漫
  3412. baozimh: {
  3413. host: ['www.webmota.com', 'cn.webmota.com', 'cn.baozimh.com'],
  3414. functionS: function() {
  3415. if (indexOF('/chapter/')) {
  3416. curSite = DBSite.baozimh;
  3417. } else if (indexOF('/comic/')) {
  3418. if (getCSS('#button_show_all_chatper')) getCSS('#button_show_all_chatper').click();
  3419. }},
  3420. style: '#footer, #header {display: none !important;} .header, .bottom-bar {opacity: 0.3;}',
  3421. pager: {
  3422. type: 1,
  3423. nextL: 'css;.next_chapter > a',
  3424. pageE: 'css;.comic-contain > amp-img',
  3425. replaceE: 'css;.next_chapter, .bottom-bar, .header .title',
  3426. scrollD: 2000
  3427. }
  3428. }, // 包子漫画
  3429. leyuman: {
  3430. host: 'www.leyuman.com',
  3431. functionS: function() {if (indexOF(/\/comic\/\d+\/\d+\.html/)) {
  3432. curSite = DBSite.leyuman;
  3433. setTimeout(leyuman_init, 100);
  3434. } else if (indexOF(/\/comic\/\d+\.html/)) {
  3435. setTimeout(function(){if (getCSS('#read-more')) getCSS('#read-more').click();}, 500)
  3436. } else {
  3437. curSite = DBSite.leyuman_list;
  3438. }},
  3439. style: '.mh_select, .mh_comicpic > p, mh_headpager {display: none !important;} .mh_comicpic > img{width: 100% !important; height: auto !important;}',
  3440. pager: {
  3441. type: 4,
  3442. nextL: 'css;#xurl',
  3443. insertP: ['css;.mh_comicpic', 3],
  3444. insertE: leyuman_insertE,
  3445. replaceE: 'css;.mh_headpager, .mh_readtitle',
  3446. interval: 3000,
  3447. scrollD: 3000
  3448. }
  3449. }, // 乐语漫画
  3450. leyuman_list: {
  3451. pager: {
  3452. type: 1,
  3453. nextL: '//a[@class="page-link"][contains(text(), "下一页")]',
  3454. pageE: 'css;.works_recommend.classification_works > ul',
  3455. replaceE: 'css;.paging',
  3456. scrollD: 1000
  3457. },
  3458. function: {
  3459. bF: src_bF,
  3460. pF: [0, 'img[data-src]', 'data-src']
  3461. }
  3462. }, // 乐语漫画 - 分类页
  3463. _77mh: {
  3464. host: 'www.77mh.cc',
  3465. functionS: function() {if (indexOF(/\/\d+\.html/)) {
  3466. curSite = DBSite._77mh;
  3467. setTimeout(_77mh_init, 100);
  3468. } else if (indexOF('/colist_')) {
  3469. setTimeout(function(){if (getCSS('#listmore1, .listmore')) getCSS('#listmore1, .listmore').click();}, 500)
  3470. } else {
  3471. curSite = DBSite._77mh_list;
  3472. }},
  3473. style: '.page_num, #bdtopbot {display: none !important;} #comicImg > img {display: block !important;margin: 0 auto !important; border: none !important; padding: 0 !important; max-width: 99% !important; height: auto !important;}',
  3474. pager: {
  3475. type: 4,
  3476. nextL: _77mh_nextL,
  3477. insertP: ['css;#comicImg', 3],
  3478. insertE: _77mh_insertE,
  3479. interval: 3000,
  3480. scrollD: 2000
  3481. }
  3482. }, // 新新漫画
  3483. _77mh_list: {
  3484. pager: {
  3485. type: 1,
  3486. nextL: '//div[@class="pages_s"]/a[text()="下一页"]',
  3487. pageE: 'css;.ar_list_co > ul > li',
  3488. replaceE: 'css;.pages_s',
  3489. scrollD: 1000
  3490. }
  3491. }, // 新新漫画 - 分类页
  3492. _77mh_search: {
  3493. host: 'so.77mh.cc',
  3494. pager: {
  3495. type: 1,
  3496. nextL: 'css;a.next',
  3497. pageE: 'css;.ar_list_co > ul > dl',
  3498. replaceE: 'css;.pages_s',
  3499. scrollD: 1000
  3500. }
  3501. }, // 新新漫画 - 搜索页
  3502. gufengmh: {
  3503. host: /gufengmh/,
  3504. functionS: function() {if (indexOF(/\/\d+.+\.html/)) {
  3505. let chapterScroll = getCSS('#chapter-scroll') // 强制为 [下拉阅读] 模式
  3506. if (chapterScroll && chapterScroll.className === '') {chapterScroll.click();}
  3507. curSite = DBSite.gufengmh;
  3508. } else if (indexOF(/\/(update|list|search)/)) {
  3509. curSite = DBSite.gufengmh_list;
  3510. }},
  3511. style: 'p.img_info {display: none !important;}', // 隐藏中间的页数信息
  3512. pager: {
  3513. type: 4,
  3514. nextL: gufengmh_nextL,
  3515. pageE: 'css;body > script:first-child',
  3516. insertP: ['css;#images', 3],
  3517. insertE: gufengmh_insertE,
  3518. interval: 5000,
  3519. scrollD: 4000
  3520. }
  3521. }, // 古风漫画网
  3522. gufengmh_list: {
  3523. pager: {
  3524. type: 1,
  3525. nextL: 'css;li.next > a',
  3526. pageE: 'css;ul.book-list > li',
  3527. replaceE: 'css;ul.pagination',
  3528. scrollD: 1000
  3529. }
  3530. }, // 古风漫画网 - 分类页
  3531. szcdmj: {
  3532. host: 'www.szcdmj.com',
  3533. functionS: function() {
  3534. if (indexOF('/szcchapter/')) {
  3535. curSite = DBSite.szcdmj;
  3536. } else if (indexOF('/szcbook/')) {
  3537. if (getCSS('#detail-list-more')) getCSS('#detail-list-more').click();
  3538. } else if (lp == '/szcbolist' || lp == '/update') {
  3539. curSite = DBSite.szcdmj_list;
  3540. }},
  3541. style: '.header {opacity: 0.3 !important;}',
  3542. pager: {
  3543. type: 1,
  3544. nextL: '//div[@class="fanye"][1]/a[@href][text()="下一页" or text()="下一话"]',
  3545. pageE: 'css;.comicpage > div',
  3546. insertP: ['css;.comicpage', 3],
  3547. replaceE: 'css;.fanye,h1.title',
  3548. scrollD: 2000
  3549. },
  3550. function: {
  3551. bF: src_bF,
  3552. pF: [0, 'img[data-original]', 'data-original']
  3553. }
  3554. }, // 砂之船动漫家
  3555. szcdmj_list: {
  3556. pager: {
  3557. type: 1,
  3558. nextL: 'css;#nextPage',
  3559. pageE: 'css;ul.mh-list > li',
  3560. replaceE: 'css;.pagination',
  3561. scrollD: 1000
  3562. }
  3563. }, // 砂之船动漫家 - 分类/搜索页
  3564. mangabz: {
  3565. host: ['mangabz.com', 'www.mangabz.com'],
  3566. functionS: function() {if (indexOF(/\/m\d+/)) {
  3567. setTimeout(mangabz_init, 1500);
  3568. curSite = DBSite.mangabz;
  3569. } else if (indexOF(/\/\d+bz\//)) {
  3570. if (getCSS('.detail-list-form-more')) getCSS('.detail-list-form-more').click();
  3571. } else if (indexOF('/manga-list') || lp == '/search') {
  3572. curSite = DBSite.mangabz_list;
  3573. }},
  3574. style: 'body > .container > div:not([id]) {display: none !important;} .top-bar {opacity: 0.3 !important;} #cp_img > img{display: block !important;margin: 0 auto !important;width: auto !important; height: auto !important;}',
  3575. hiddenPN: true,
  3576. pager: {
  3577. type: 4,
  3578. nextL: mangabz_nextL,
  3579. insertP: ['css;#cp_img', 3],
  3580. insertE: mangabz_insertE,
  3581. replaceE: 'css;p.top-title, body > .container > div:not([id])',
  3582. interval: 500,
  3583. scrollD: 2000
  3584. }
  3585. }, // Mangabz 漫画
  3586. mangabz_list: {
  3587. pager: {
  3588. type: 1,
  3589. nextL: '//div[@class="page-pagination"]//a[contains(text(), ">")]',
  3590. pageE: 'css;ul.mh-list > li',
  3591. replaceE: 'css;.page-pagination',
  3592. scrollD: 800
  3593. }
  3594. }, // Mangabz 漫画 - 分类/搜索页
  3595. xmanhua: {
  3596. host: ['xmanhua.com', 'www.xmanhua.com'],
  3597. functionS: function() {if (indexOF(/\/m\d+/)) {
  3598. setTimeout(mangabz_init, 1500);
  3599. curSite = DBSite.xmanhua;
  3600. } else if (indexOF(/\/\d+xm\//)) {
  3601. if (getCSS('.detail-list-form-more')) getCSS('.detail-list-form-more').click();
  3602. } else if (indexOF('/manga-list') || lp == '/search') {
  3603. curSite = DBSite.xmanhua_list;
  3604. }},
  3605. style: 'a.reader-bottom-page {display: none !important;} .header, .reader-bottom {opacity: 0.3 !important;} #cp_img > img{display: block !important;margin: 0 auto !important;width: auto !important; height: auto !important;}',
  3606. hiddenPN: true,
  3607. pager: {
  3608. type: 4,
  3609. nextL: xmanhua_nextL,
  3610. insertP: ['css;#cp_img', 3],
  3611. insertE: xmanhua_insertE,
  3612. replaceE: 'css;.reader-title, body > .container > div:not([id])',
  3613. interval: 500,
  3614. scrollD: 2500
  3615. }
  3616. }, // Xmanhua 漫画
  3617. xmanhua_list: {
  3618. pager: {
  3619. type: 1,
  3620. nextL: '//div[@class="page-pagination"]//a[contains(text(), ">")]',
  3621. pageE: 'css;ul.mh-list > li',
  3622. replaceE: 'css;.page-pagination',
  3623. scrollD: 1000
  3624. }
  3625. }, // Xmanhua 漫画 - 分类/搜索页
  3626. cocomanga: {
  3627. host: 'www.cocomanga.com',
  3628. functionS: function() {if (indexOF('.html')) {
  3629. if (!(getCookie('mh_readmode') === '' || getCookie('mh_readmode') === '3')) {
  3630. document.cookie='mh_readmode=; expires=Thu, 01 Jan 1970 00:00:00 GMT; path=/'; // 强制开启自带的无缝翻页功能
  3631. location.reload(); // 刷新网页
  3632. }
  3633. setTimeout(cocomanga_init, 500);
  3634. curSite = DBSite.cocomanga;
  3635. } else if (indexOF(/\/\d+\/$/)) {
  3636. setTimeout(function(){if (getCSS('a.website-display-all')) getCSS('a.website-display-all').click();}, 300)
  3637. } else if (lp == '/show') {
  3638. curSite = DBSite.cocomanga_list;
  3639. } else if (lp == '/search') {
  3640. curSite = DBSite.cocomanga_search;
  3641. }},
  3642. style: '.mh_readend, .mh_footpager, .mh_readmode {display: none !important;} .mh_comicpic img {cursor: unset !important;} .mh_comicpic img {min-height: 150px;}',
  3643. pager: {
  3644. type: 4,
  3645. nextL: '//a[contains(@class, "read_page_link") and contains(string(), "下一章")][not(contains(@href, "javascript"))]',
  3646. insertP: ['css;#mangalist', 3],
  3647. insertE: cocomanga_insertE,
  3648. replaceE: 'css;.mh_readtitle, .mh_headpager > a.mh_prevbook, .mh_readend',
  3649. interval: 1000,
  3650. scrollD: 2500
  3651. }
  3652. }, // COCOMANGA 漫画
  3653. cocomanga_list: {
  3654. pager: {
  3655. type: 1,
  3656. nextL: () => getNextEP('css;.fed-page-info a.fed-btns-green+a[onclick]', 'page=', /page=\d+/),
  3657. pageE: 'css;ul.fed-list-info > li',
  3658. replaceE: 'css;.fed-page-info',
  3659. scrollD: 1000
  3660. },
  3661. function: {
  3662. bF: src_bF,
  3663. pF: [1, 'a[data-original]', 'data-original']
  3664. }
  3665. }, // COCOMANGA 漫画 - 分类页
  3666. cocomanga_search: {
  3667. pager: {
  3668. type: 1,
  3669. nextL: () => getNextEP('css;.fed-page-info a.fed-btns-green+a[onclick]', 'page=', /page=\d+/),
  3670. pageE: 'css;dl.fed-deta-info',
  3671. replaceE: 'css;.fed-page-info',
  3672. scrollD: 1000
  3673. },
  3674. function: {
  3675. bF: src_bF,
  3676. pF: [1, 'a[data-original]', 'data-original']
  3677. }
  3678. }, // COCOMANGA 漫画 - 搜索页
  3679. qidian: {
  3680. host: 'www.qidian.com',
  3681. functionS: function() {if (indexOF('/all/')) {curSite = DBSite.qidian;}},
  3682. pager: {
  3683. type: 1,
  3684. nextL: 'css;a[class*="pagination-next"]',
  3685. pageE: 'css;ul.all-img-list > li',
  3686. replaceE: 'css;#page-container',
  3687. scrollD: 900
  3688. }
  3689. }, // 起点中文
  3690. qidian_read: {
  3691. host: 'read.qidian.com',
  3692. style: '.admire-wrap {display: none !important;}',
  3693. pager: {
  3694. type: 1,
  3695. nextL: 'css;a[id$="chapterNext"]',
  3696. pageE: 'css;.main-text-wrap > div:not(.admire-wrap)',
  3697. replaceE: 'css;.chapter-control',
  3698. scrollD: 900
  3699. }
  3700. }, // 起点中文 - 阅读页
  3701. baoshuu: {
  3702. host: 'www.baoshuu.com',
  3703. functionS: function() {if (indexOF('/TXT/list')) curSite = DBSite.baoshuu;},
  3704. pager: {
  3705. type: 1,
  3706. nextL: '//div[@class="listl2"]//a[text()="下一页"]',
  3707. pageE: 'css;.listl2 > ul > li',
  3708. replaceE: 'css;.listl2 > dl',
  3709. scrollD: 900
  3710. }
  3711. }, // 宝书网
  3712. baoshuu_m: {
  3713. host: 'm.baoshuu.com',
  3714. functionS: function() {if (indexOF('/TXT/list')) curSite = DBSite.baoshuu_m;},
  3715. pager: {
  3716. type: 1,
  3717. nextL: '//div[@class="man_first"]//a[text()="下一页"]',
  3718. pageE: 'css;.man_first > ul > li',
  3719. replaceE: 'css;.man_first > dl',
  3720. scrollD: 900
  3721. }
  3722. }, // 宝书网- 手机版
  3723. yushubo: {
  3724. host: 'www.yushubo.com',
  3725. functionS: function() {if (indexOF('/read_')) {
  3726. curSite = DBSite.yushubo;
  3727. } else if (indexOF('/lists/')) {
  3728. curSite = DBSite.yushubo_list;
  3729. } else if (indexOF('/all')) {
  3730. curSite = DBSite.yushubo_all;
  3731. }},
  3732. style: '.readbg.mt10 {display: none !important;}',
  3733. pager: {
  3734. type: 1,
  3735. nextL: '//div[contains(@class, "articlebtn")]/a[contains(text(), "下一页") or contains(text(), "下一章")]',
  3736. pageE: 'css;#BookText',
  3737. insertP: ['css;#BookText', 6],
  3738. insertP6Br: true,
  3739. replaceE: 'css;.articlebtn',
  3740. scrollD: 1000
  3741. }
  3742. }, // 御书网
  3743. yushubo_list: {
  3744. pager: {
  3745. type: 1,
  3746. nextL: 'id("pager")//a[contains(text(), "下一页")]',
  3747. pageE: 'css;.books-list > ul > li',
  3748. replaceE: 'css;#pager',
  3749. scrollD: 1000
  3750. }
  3751. }, // 御书网 - 分类页
  3752. yushubo_all: {
  3753. pager: {
  3754. type: 1,
  3755. nextL: 'id("pager")//a[contains(text(), "下一页")]',
  3756. pageE: 'css;ul.search-list > li',
  3757. replaceE: 'css;#pager',
  3758. scrollD: 1000
  3759. }
  3760. }, // 御书网 - 书库页
  3761. soxscc: {
  3762. host: 'www.soxscc.org',
  3763. functionS: function() {if (indexOF(/\/\d{4,}\.html/)) {curSite = DBSite.soxscc;}},
  3764. style: '.content > p, img {display: none !important;}',
  3765. pager: {
  3766. type: 1,
  3767. nextL: '//font[contains(text(), "下一章")]/following-sibling::a[1]',
  3768. pageE: 'css;.content',
  3769. insertP: ['css;.content', 6],
  3770. insertP6Br: true,
  3771. replaceE: 'css;.pagego',
  3772. scrollD: 1500
  3773. }
  3774. }, // 搜小说
  3775. ihuaben: {
  3776. host: 'www.ihuaben.com',
  3777. functionS: function() {if (indexOF(/\/\d{4,}\.html/)) {curSite = DBSite.ihuaben;}},
  3778. style: '.discription > p > i, img, #container, #BDBannerBottom_PC, iframe, .navFooter {display: none !important;} .discription > p {font-size: 16px; min-height: 24px; padding-bottom: 24px;}',
  3779. pager: {
  3780. type: 1,
  3781. nextL: 'id("preAndNextBar")/a[contains(text(), "下一章")]',
  3782. pageE: 'css;#contentsource > p',
  3783. insertP: ['css;.discription', 3],
  3784. replaceE: 'css;#preAndNextBar',
  3785. scrollD: 1000
  3786. }
  3787. }, // 话本小说网
  3788. xineyby: {
  3789. host: 'www.xineyby.com',
  3790. functionS: function() {if (indexOF('/read/')) {
  3791. curSite = DBSite.xineyby;
  3792. } else if (indexOF(/\/(list|quanben|search)/)) {
  3793. curSite = DBSite.xineyby_list;
  3794. }},
  3795. pager: {
  3796. type: 1,
  3797. nextL: 'id("footlink")/a[contains(text(), "下一页")]',
  3798. pageE: 'css;#contents',
  3799. insertP: ['css;#contents', 6],
  3800. insertP6Br: true,
  3801. replaceE: 'css;#footlink, #amain dd h1',
  3802. scrollD: 900
  3803. }
  3804. }, // 无错小说网
  3805. xineyby_list: {
  3806. pager: {
  3807. type: 1,
  3808. nextL: 'css;#pagelink a.next',
  3809. pageE: 'css;#content > dd tbody > tr:not(:first-child)',
  3810. insertP: ['css;#content > dd tbody', 3],
  3811. replaceE: 'css;#pagelink',
  3812. scrollD: 900
  3813. }
  3814. }, // 无错小说网 - 分类/搜索页
  3815. _530p: {
  3816. host: 'www.530p.com',
  3817. functionS: function() {if (indexOF(/\/\d{4,}\.htm/)) {curSite = DBSite._530p;}},
  3818. pager: {
  3819. type: 1,
  3820. nextL: 'css;#nextLink',
  3821. pageE: 'css;#cp_content',
  3822. insertP: ['css;#cp_content', 6],
  3823. insertP6Br: true,
  3824. replaceE: 'css;#pg_bar',
  3825. scrollD: 1500
  3826. }
  3827. }, // 无弹窗小说网
  3828. xiaoshuo77: {
  3829. host: 'm.xiaoshuo77.net',
  3830. functionS: function() {if (indexOF('.html')) {curSite = DBSite.xiaoshuo77; xs_bF(getAllCSS('#novelcontent'), [/(<br>)?(&nbsp;)+内容未完,下一页.*$|【本章阅读.*$/, '<br>']);}},
  3831. style: '#novelcontent > p, img {display: none !important;}',
  3832. pager: {
  3833. type: 1,
  3834. nextL: 'css;.page_chapter a.p4',
  3835. pageE: 'css;#novelcontent',
  3836. insertP: ['css;#novelcontent', 6],
  3837. replaceE: 'css;.page_chapter',
  3838. scrollD: 1500
  3839. },
  3840. function: {
  3841. bF: xs_bF,
  3842. pF: [/(<br>)?(&nbsp;)+内容未完,下一页.*$|【本章阅读.*$/, '<br>']
  3843. }
  3844. }, // 读书族小说网
  3845. linovel: {
  3846. host: 'www.linovel.net',
  3847. functionS: function() {if (indexOF(/\/book\/\d+\/.+\.html/)) {
  3848. insStyle('.reward-section {display: none !important;}');
  3849. } else if (indexOF('/cat/')) {
  3850. curSite = DBSite.linovel;
  3851. }},
  3852. pager: {
  3853. type: 1,
  3854. nextL: '//ul[@class="pagination"]/li/a[contains(text(), "下一页")]',
  3855. pageE: 'css;.rank-book-list > div',
  3856. replaceE: 'css;ul.pagination',
  3857. scrollD: 1000
  3858. }
  3859. }, // 轻之文库
  3860. _23qb: {
  3861. host: 'www.23qb.net',
  3862. functionS: function() {if (indexOF(/\/book\/\d+\/.+\.html/)) {
  3863. curSite = DBSite._23qb; xs_bF(getAllCSS('#mlfy_main_text > *'), [/(继续下一页).+|铅笔小说.+/, '']);
  3864. } else if (location.pathname != '/' && !indexOF(/\/book\/\d+\//)) {
  3865. curSite = DBSite._23qb_list;
  3866. }},
  3867. pager: {
  3868. type: 1,
  3869. nextL: () => (location.origin + ReadParams.url_next),
  3870. pageE: 'id("TextContent")/p | //script[contains(text(), "ReadParams")]',
  3871. insertP: ['css;#TextContent', 3],
  3872. replaceE: 'css;.chepnav',
  3873. scriptT: 2,
  3874. scrollD: 1500
  3875. },
  3876. function: {
  3877. bF: xs_bF,
  3878. pF: [/.*继续下一页.*|.*铅笔小说.*/, '']
  3879. }
  3880. }, // 铅笔小说
  3881. _23qb_list: {
  3882. pager: {
  3883. type: 1,
  3884. nextL: 'css;.pages a.next, .pages > strong+a',
  3885. pageE: 'css;#sitebox > dl',
  3886. replaceE: 'css;.pages',
  3887. scrollD: 1000
  3888. },
  3889. function: {
  3890. bF: src_bF,
  3891. pF: [0, 'img[_src]', '_src']
  3892. }
  3893. }, // 铅笔小说 - 分类页
  3894. linovelib: {
  3895. host: 'www.linovelib.com',
  3896. functionS: function() {if (indexOF(/\/novel\/\d+\/.+\.html/)) {
  3897. curSite = DBSite.linovelib;
  3898. } else if (indexOF('/wenku/')) {
  3899. curSite = DBSite.linovelib_wenku;
  3900. } else if (indexOF('/top/') || indexOF('/topfull/') || indexOF('toplist.php')) {
  3901. curSite = DBSite.linovelib_top;
  3902. }},
  3903. pager: {
  3904. type: 1,
  3905. nextL: '//p[@class="mlfy_page"]/a[contains(text(), "下一页") or contains(text(), "下一章")]',
  3906. pageE: 'css;#mlfy_main_text > *',
  3907. replaceE: 'css;p.mlfy_page',
  3908. scrollD: 1000
  3909. }
  3910. }, // 哔哩轻小说
  3911. linovelib_wenku: {
  3912. pager: {
  3913. type: 1,
  3914. nextL: 'css;#pagelink > a.next',
  3915. pageE: 'css;.store_collist > div.bookbox',
  3916. replaceE: 'css;#pagelink',
  3917. scrollD: 1000
  3918. },
  3919. function: {
  3920. bF: src_bF,
  3921. pF: [0, 'img[data-original]', 'data-original']
  3922. }
  3923. }, // 哔哩轻小说 - 文库
  3924. linovelib_top: {
  3925. pager: {
  3926. type: 1,
  3927. nextL: 'css;#pagelink > a.next',
  3928. pageE: 'css;.rankpage_box > div.rank_d_list',
  3929. replaceE: 'css;#pagelink',
  3930. scrollD: 1000
  3931. },
  3932. function: {
  3933. bF: src_bF,
  3934. pF: [0, 'img[data-original]', 'data-original']
  3935. }
  3936. }, // 哔哩轻小说 - 全本
  3937. linovelib_w: {
  3938. host: 'w.linovelib.com',
  3939. functionS: function() {if (indexOF(/\/novel\/\d+\/.+\.html/)) {
  3940. curSite = DBSite.linovelib_w;
  3941. } else if (indexOF('/wenku/') || indexOF('/sa/')) {
  3942. curSite = DBSite.linovelib_w_wenku;
  3943. }},
  3944. style: 'body {min-height: 1000px;}',
  3945. pager: {
  3946. type: 1,
  3947. nextL: function() {if (ReadParams) {return (location.origin + ReadParams.url_next)}; return ''},
  3948. pageE: '//body/script[contains(text(), "var ReadParams")] | id("apage")/div',
  3949. insertP: ['css;#apage', 3],
  3950. scriptT: 2,
  3951. scrollD: 1000
  3952. }
  3953. }, // 哔哩轻小说 (手机版)
  3954. linovelib_w_wenku: {
  3955. pager: {
  3956. type: 1,
  3957. nextL: 'css;#pagelink > strong+a ,#pagelink a.next',
  3958. pageE: 'css;ol.book-ol > li',
  3959. replaceE: 'css;#pagelink',
  3960. scrollD: 1000
  3961. },
  3962. function: {
  3963. bF: src_bF,
  3964. pF: [0, 'img[data-original]', 'data-original']
  3965. }
  3966. }, // 哔哩轻小说 (手机版) - 文库
  3967. _423down: {
  3968. host: 'www.423down.com',
  3969. functionS: function() {if (!indexOF('.html')) curSite = DBSite._423down;},
  3970. pager: {
  3971. type: 1,
  3972. nextL: '//div[@class="paging"]//a[contains(text(),"下一页")]',
  3973. pageE: 'css;div.content-wrap ul.excerpt > li',
  3974. replaceE: 'css;div.paging',
  3975. scrollD: 2000
  3976. }
  3977. }, // 423Down
  3978. iao_su: {
  3979. host: 'iao.su',
  3980. pager: {
  3981. type: 1,
  3982. nextL: 'css;li.next > a',
  3983. pageE: 'css;#index > article, #archive > article',
  3984. insertP: ['css;ol.page-navigator', 1],
  3985. replaceE: 'css;ol.page-navigator',
  3986. scriptT: 3,
  3987. scrollD: 1000
  3988. }
  3989. }, // 不死鸟
  3990. sharerw: {
  3991. host: 'www.sharerw.com',
  3992. functionS: function() {if (!indexOF('.html')) {if (lp == '/search.php') {curSite = DBSite.sharerw_search;} else {curSite = DBSite.sharerw;};};},
  3993. pager: {
  3994. type: 1,
  3995. nextL: 'css;span.next > a',
  3996. pageE: 'css;.new-post > article',
  3997. replaceE: 'css;.pagebar',
  3998. scrollD: 1500
  3999. }
  4000. }, // 分享者
  4001. sharerw_search: {
  4002. pager: {
  4003. type: 1,
  4004. nextL: 'css;span.next > a',
  4005. pageE: 'css;#mainbox > article',
  4006. replaceE: 'css;.pagebar',
  4007. scrollD: 1500
  4008. }
  4009. }, // 分享者 - 搜索页
  4010. extfans: {
  4011. host: 'www.extfans.com',
  4012. functionS: function() {if (location.pathname != '/') {curSite = DBSite.extfans;}},
  4013. pager: {
  4014. type: 1,
  4015. nextL: 'css;a.page-next',
  4016. pageE: 'css;.app-item-content, .article-item-content',
  4017. replaceE: 'css;.pagination-content',
  4018. scrollD: 2000
  4019. }
  4020. }, // 扩展迷
  4021. appinn: {
  4022. host: 'www.appinn.com',
  4023. pager: {
  4024. type: 1,
  4025. nextL: 'css;a.next.page-numbers',
  4026. pageE: 'css;section#latest-posts > article',
  4027. replaceE: 'css;div.nav-links',
  4028. scrollD: 1500
  4029. }
  4030. }, // 小众软件
  4031. isharepc: {
  4032. host: 'www.isharepc.com',
  4033. pager: {
  4034. type: 1,
  4035. nextL: 'css;a.next.page-numbers',
  4036. pageE: 'css;.content > div.post',
  4037. replaceE: 'css;nav.pagination',
  4038. scrollD: 1000
  4039. }
  4040. }, // 乐软博客
  4041. ghxi: {
  4042. host: 'www.ghxi.com',
  4043. functionS: function() {if (lp == '/' && !location.search) {curSite = DBSite.ghxi;} else {curSite = DBSite.ghxi_list;}},
  4044. pager: {
  4045. type: 2,
  4046. nextL: 'css;.load-more',
  4047. interval: 1000,
  4048. scrollD: 5000
  4049. }
  4050. }, // 果核剥壳 - 首页
  4051. ghxi_list: {
  4052. pager: {
  4053. type: 1,
  4054. nextL: 'css;a.next',
  4055. pageE: 'css;ul.post-loop > li',
  4056. replaceE: 'css;ul.pagination',
  4057. scrollD: 1500
  4058. },
  4059. function: {
  4060. bF: src_bF,
  4061. pF: [0, 'img[data-original]', 'data-original']
  4062. }
  4063. }, // 果核剥壳 - 分类/搜索页
  4064. _6yit: {
  4065. host: ['www.6yit.com'],
  4066. functionS: function() {if (!indexOF('.html')) {curSite = DBSite._6yit;}},
  4067. pager: {
  4068. type: 1,
  4069. nextL: 'css;a.next.page-numbers',
  4070. pageE: 'css;posts.posts-item.list',
  4071. replaceE: 'css;.pagenav',
  4072. scrollD: 1500
  4073. }
  4074. }, // 六音软件
  4075. apprcn: {
  4076. host: ['www.apprcn.com', 'free.apprcn.com'],
  4077. functionS: function() {if (lp == '/' || indexOF('/category/')) {curSite = DBSite.apprcn;}},
  4078. pager: {
  4079. type: 1,
  4080. nextL: '//div[@class="pagination"]//a[contains(text(), "Next")]',
  4081. pageE: 'css;article.article',
  4082. replaceE: 'css;.pagination',
  4083. scrollD: 1000
  4084. }
  4085. }, // 反斗软件
  4086. weidown: {
  4087. host: 'www.weidown.com',
  4088. functionS: function() {if (indexOF('/search/')) { //搜索页
  4089. curSite = DBSite.weidown_search;
  4090. } else if (indexOF('/special')) { // 专题页
  4091. curSite = DBSite.weidown_special;
  4092. } else {
  4093. curSite = DBSite.weidown;
  4094. }},
  4095. pager: {
  4096. type: 1,
  4097. nextL: 'css;a.nextpage',
  4098. pageE: 'css;.articleWrapper > .itemArticle, .articleWrapper > .richTextItem.search',
  4099. insertP: ['css;.articleWrapper', 3],
  4100. replaceE: 'css;#pageGroup',
  4101. scrollD: 1500
  4102. }
  4103. }, // 微当下载
  4104. weidown_search: {
  4105. pager: {
  4106. type: 1,
  4107. nextL: 'css;a.nextpage',
  4108. pageE: 'css;.articleListWrapper > .richTextItem.search',
  4109. replaceE: 'css;#pageGroup',
  4110. scrollD: 700
  4111. }
  4112. }, // 微当下载 - 搜索页
  4113. weidown_special: {
  4114. pager: {
  4115. type: 1,
  4116. nextL: 'css;a.nextpage',
  4117. pageE: 'css;.special > .item, .articleWrapper > div',
  4118. insertP: ['css;.special, .articleWrapper', 3],
  4119. replaceE: 'css;#pageGroup',
  4120. scrollD: 700
  4121. }
  4122. }, // 微当下载 - 专题页
  4123. fsylr: {
  4124. host: 'fsylr.com',
  4125. functionS: function() {if (!indexOF('.html')) {curSite = DBSite.fsylr;}},
  4126. pager: {
  4127. type: 1,
  4128. nextL: 'css;a.next.page-numbers',
  4129. pageE: 'css;.posts-con > div:not([class*="posts-"])',
  4130. replaceE: 'css;nav.pagination',
  4131. scrollD: 2000
  4132. }
  4133. }, // 发烧友绿软
  4134. iplaysoft: {
  4135. host: 'www.iplaysoft.com',
  4136. functionS: function() {if (indexOF('.html') || indexOF('/p/')) {curSite = DBSite.iplaysoft_comment;} else {curSite = DBSite.iplaysoft;}},
  4137. pager: {
  4138. type: 1,
  4139. nextL: 'css;.pagenavi a[title="下一页"]',
  4140. pageE: 'css;#postlist > div.entry',
  4141. replaceE: 'css;.pagenavi-button, .pagenavi',
  4142. scrollD: 1200
  4143. },
  4144. function: {
  4145. bF: src_bF,
  4146. pF: [0, 'img[data-src]', 'data-src']
  4147. }
  4148. }, // 异次元软件
  4149. iplaysoft_comment: {
  4150. pager: {
  4151. type: 2,
  4152. nextL: 'css;#loadHistoryComments',
  4153. nextTextOf: '展开后面',
  4154. scrollD: 1200
  4155. }
  4156. }, // 异次元软件 - 评论
  4157. mubolin: {
  4158. host: 'www.mubolin.cn',
  4159. pager: {
  4160. type: 1,
  4161. nextL: 'css;a.next.page-numbers',
  4162. pageE: 'css;#recent-content > div',
  4163. replaceE: 'css;nav.pagination',
  4164. scrollD: 1500
  4165. }
  4166. }, // 悪魔の小站
  4167. mpyit: {
  4168. host: 'www.mpyit.com',
  4169. functionS: function() {if (lp == '/' && !location.search) {
  4170. curSite = DBSite.mpyit;
  4171. } else if (indexOF('/category/') || indexOF('?s=', 's')) { // 搜索页 / 分类页
  4172. curSite = DBSite.mpyit_category;
  4173. }},
  4174. pager: {
  4175. type: 1,
  4176. nextL: 'css;a.page-numbers[title="下一页"]',
  4177. pageE: 'css;#post > div[id^="post-"]',
  4178. replaceE: 'css;#post > #pagenavi',
  4179. scrollD: 1700
  4180. }
  4181. }, // 老殁 | 殁漂遥
  4182. mpyit_category: {
  4183. pager: {
  4184. type: 1,
  4185. nextL: 'css;a.page-numbers[title="下一页"]',
  4186. pageE: 'css;#content > div[class^="entry_box"]',
  4187. replaceE: 'css;#content > #pagenavi',
  4188. scrollD: 1700
  4189. }
  4190. }, // 老殁 | 殁漂遥 - 搜索页/分类页
  4191. tenlonstudio: {
  4192. host: 'www.tenlonstudio.com',
  4193. functionS: function() {if (lp == '/' && !location.search) {
  4194. curSite = DBSite.tenlonstudio;
  4195. } else {
  4196. curSite = DBSite.tenlonstudio_list;
  4197. }},
  4198. pager: {
  4199. type: 2,
  4200. nextL: 'css;.load-more',
  4201. nextText: '加载更多',
  4202. interval: 500,
  4203. scrollD: 1000
  4204. }
  4205. }, // 腾龙工作室
  4206. tenlonstudio_list: {
  4207. pager: {
  4208. type: 1,
  4209. nextL: '//div[@class="btn-pager"]/a[contains(text(), "❯")]',
  4210. pageE: 'css;li.post-list-item',
  4211. replaceE: 'css;.ajax-pager',
  4212. scrollD: 1000
  4213. }
  4214. }, // 腾龙工作室 - 分类/搜索页
  4215. yxssp: {
  4216. host: 'www.yxssp.com',
  4217. pager: {
  4218. type: 1,
  4219. nextL: '//div[contains(@class, "page-nav")]/a[last()]',
  4220. pageE: 'css;.td-modules-container.td-module-number4 > div',
  4221. replaceE: 'css;.page-nav.td-pb-padding-side',
  4222. scrollD: 1000
  4223. }
  4224. }, // 异星软件空间
  4225. yrxitong: {
  4226. host: 'www.yrxitong.com',
  4227. functionS: function() {
  4228. if (lp == '/sr.jsp') {
  4229. curSite = DBSite.yrxitong_search;
  4230. } else if (!indexOF('/h-nd-')) {
  4231. curSite = DBSite.yrxitong;
  4232. }
  4233. },
  4234. pager: {
  4235. type: 1,
  4236. nextL: 'css;span.pageNext > a',
  4237. pageE: 'css;#containerFormsCenter .m_news_list > div',
  4238. replaceE: 'css;.pagenation',
  4239. scrollD: 1200
  4240. },
  4241. function: {
  4242. bF: src_bF,
  4243. pF: [1, 'a[data-original]', 'data-original']
  4244. }
  4245. }, // 小鱼儿 yr 系统
  4246. yrxitong_search: {
  4247. pager: {
  4248. type: 1,
  4249. nextL: 'css;span.pageNext > a',
  4250. pageE: 'css;#containerFormsCenter .newsList > div',
  4251. replaceE: 'css;.pagenation',
  4252. scrollD: 2000
  4253. }
  4254. }, // 小鱼儿 yr 系统 - 搜索页
  4255. downg: {
  4256. host: 'www.downg.com',
  4257. functionS: function() {if (indexOF('/new/')) {curSite = DBSite.downg;}},
  4258. pager: {
  4259. type: 1,
  4260. nextL: 'css;a.nextpage',
  4261. pageE: 'css;.ApdList > ul.ApdLi',
  4262. replaceE: 'css;.pagination',
  4263. scrollD: 1500
  4264. }
  4265. }, // 绿软家园
  4266. sordum: {
  4267. host: 'www.sordum.org',
  4268. pager: {
  4269. type: 1,
  4270. nextL: 'css;a.next.page-numbers',
  4271. pageE: 'css;.article > article',
  4272. replaceE: 'css;nav.navigation.posts-navigation',
  4273. scrollD: 1500
  4274. }
  4275. }, // (下面这几个都是国外博客网站)
  4276. winaero: {
  4277. host: 'winaero.com',
  4278. functionS: function() {if (lp == '/' || indexOF('/category/')) curSite = DBSite.winaero;},
  4279. pager: {
  4280. type: 1,
  4281. nextL: 'css;a.next.page-numbers',
  4282. pageE: 'css;#main > article',
  4283. replaceE: 'css;.pagination',
  4284. scrollD: 1500
  4285. }
  4286. },
  4287. lrepacks: {
  4288. host: 'lrepacks.net',
  4289. functionS: function() {if (!indexOF('.html')) curSite = DBSite.lrepacks;},
  4290. pager: {
  4291. type: 1,
  4292. nextL: 'css;.page_next > a',
  4293. pageE: 'css;#main .post-list article',
  4294. replaceE: 'css;.page_nav',
  4295. scrollD: 1500
  4296. },
  4297. function: {
  4298. bF: lrepacks_bF
  4299. }
  4300. },
  4301. dlandroid: {
  4302. host: 'dlandroid.com',
  4303. functionS: function() {if (indexOF('/cat/') || (lp === '/' && indexOF('?s=', 's'))) curSite = DBSite.dlandroid;},
  4304. pager: {
  4305. type: 1,
  4306. nextL: 'css;a.next.page-numbers',
  4307. pageE: 'css;div.post',
  4308. replaceE: 'css;.navigation',
  4309. scrollD: 1500
  4310. },
  4311. function: {
  4312. bF: src_bF,
  4313. pF: [0, 'img[data-src]', 'data-src']
  4314. }
  4315. }, // DlAndroid
  4316. winhelponline: {
  4317. host: 'www.winhelponline.com',
  4318. functionS: function() {if (lp == '/blog/') {curSite = DBSite.winhelponline;}},
  4319. pager: {
  4320. type: 1,
  4321. nextL: 'css;span.prev > a',
  4322. pageE: 'css;#main > article',
  4323. replaceE: 'css;nav.paging-navigation',
  4324. scrollD: 2000
  4325. }
  4326. },
  4327. windowslatest: {
  4328. host: 'www.windowslatest.com',
  4329. pager: {
  4330. type: 1,
  4331. nextL: '//div[contains(@class, "page-nav")]/a[last()]',
  4332. pageE: 'css;.td-ss-main-content > div:not(.td-block-title-wrap):not(.page-nav)',
  4333. replaceE: 'css;.page-nav',
  4334. scrollD: 2000
  4335. }
  4336. },
  4337. thewindowsclub: {
  4338. host: 'www.thewindowsclub.com',
  4339. functionS: function() {curSite = DBSite.thewindowsclub; if (lp == '/') {curSite.pager.scrollD = 2000;}},
  4340. pager: {
  4341. type: 1,
  4342. nextL: 'css;li.pagination-next > a',
  4343. pageE: 'css;#genesis-content > article.post',
  4344. replaceE: 'css;.pagination',
  4345. scrollD: 1500
  4346. }
  4347. },
  4348. acs: {
  4349. host: ['pubs.acs.org','onlinelibrary.wiley.com'],
  4350. functionS: function() {if (indexOF('/doSearch')) {curSite = DBSite.acs;}},
  4351. pager: {
  4352. type: 1,
  4353. nextL: 'css;a.pagination__btn--next',
  4354. pageE: 'css;ul.items-results > *',
  4355. replaceE: 'css;.pagination',
  4356. scrollD: 3000
  4357. }
  4358. }, // Wiley Online Library + ACS (Publications)
  4359. libgen: {
  4360. host: /libgen/,
  4361. functionS: function() {if (lp == '/search.php') {curSite = DBSite.libgen;}},
  4362. pager: {
  4363. type: 1,
  4364. nextL: '//font/a[contains(text(), "►")]',
  4365. pageE: 'css;table[rules="rows"] > tbody > tr:nth-of-type(n+2), .paginator+script:not([src])',
  4366. insertP: ['css;table[rules="rows"] > tbody', 3],
  4367. replaceE: '//td[./font/a[contains(text(), "►")]]',
  4368. scriptT: 2,
  4369. scrollD: 2000
  4370. }
  4371. }, // Library Genesis
  4372. sciencedirect: {
  4373. host: 'www.sciencedirect.com',
  4374. functionS: function() {locationC = true; if (lp == '/search') {curSite = DBSite.sciencedirect; setTimeout(function(){insStyle('html, body {height: ' + (document.documentElement.scrollHeight || document.body.scrollHeight) + 'px;}')}, 2000)}},
  4375. style: 'footer {display: none !important;}',
  4376. iframe: true,
  4377. pager: {
  4378. type: 5,
  4379. nextL: 'css;a[data-aa-name="srp-next-page"]',
  4380. scrollD: 2000
  4381. }
  4382. }, // ScienceDirect
  4383. pubmed: {
  4384. host: 'pubmed.ncbi.nlm.nih.gov',
  4385. pager: {
  4386. type: 2,
  4387. nextL: 'css;button.load-button.next-page',
  4388. nextText: 'Show more results',
  4389. scrollD: 1500
  4390. }
  4391. }, // PubMed
  4392. x_mol: {
  4393. host: 'www.x-mol.com',
  4394. functionS: function() {if (indexOF('/search/q') || indexOF('/paper/')) {curSite = DBSite.x_mol;}},
  4395. pager: {
  4396. type: 1,
  4397. nextL: () => getNextEP('css;.pagination li.active+li > a', 'pageIndex=', /pageIndex=\d+/),
  4398. pageE: 'css;.magazine-senior-search-results-list > ul > li, .magazine-model-content-new > ul > li',
  4399. insertP: ['css;.magazine-senior-search-results-list > ul, .magazine-model-content-new > ul', 3],
  4400. replaceE: 'css;.pagination',
  4401. scrollD: 2000
  4402. }
  4403. }, // X-MOL
  4404. cqvip: {
  4405. host: 'www.cqvip.com',
  4406. functionS: function() {if (indexOF('/search')) {curSite = DBSite.cqvip;}},
  4407. pager: {
  4408. type: 6,
  4409. nextL: '//ul[@class="pagenum"]//a[text()="下一页"]',
  4410. pageE: 'css;ul.prolist:last-child > li',
  4411. replaceE: 'css;ul.pagenum',
  4412. loadTime: 1000,
  4413. scrollD: 2000
  4414. }
  4415. }, // 维普网
  4416. ablesci: {
  4417. host: 'www.ablesci.com',
  4418. functionS: function() {if (indexOF('/detail') && GM_getValue('menu_thread')) {curSite = DBSite.ablesci_p;} else if (getCSS('ul.fly-list')) {curSite = DBSite.ablesci;}},
  4419. pager: {
  4420. type: 1,
  4421. nextL: 'css;li.next > a',
  4422. pageE: 'css;ul.fly-list > li',
  4423. replaceE: 'css;.pages',
  4424. scrollD: 2000
  4425. }
  4426. }, // 科研通
  4427. ablesci_p: {
  4428. pager: {
  4429. type: 1,
  4430. nextL: 'css;li.next > a',
  4431. pageE: 'css;ul#jieda > li',
  4432. replaceE: 'css;.pages',
  4433. scrollD: 2000
  4434. }
  4435. }, // 科研通 - 帖子内
  4436. coolkeyan: {
  4437. host: 'www.coolkeyan.com',
  4438. functionS: function() {if (location.hash.indexOf('/project/') > -1) curSite = DBSite.coolkeyan;},
  4439. style: '.q-img {height: auto !important;} .q-img__image {max-height: 1000px !important;} .row.q-my-sm.q-gutter-sm {display: none !important;}',
  4440. pager: {
  4441. type: 4,
  4442. nextL: coolkeyan_nextL,
  4443. insertP: ['//div[contains(@class, "q-img__image")][last()]', 4],
  4444. insertE: coolkeyan_insertE,
  4445. scrollD: 1500
  4446. }
  4447. }, // 酷科研
  4448. muchong: {
  4449. host: 'muchong.com',
  4450. functionS: function() {if (indexOF('/f-') || indexOF('search.php')) {
  4451. curSite = DBSite.muchong;
  4452. } else if (indexOF('/t-') && GM_getValue('menu_thread')) {
  4453. curSite = DBSite.muchong; curSite.pager.pageE = 'css;#maincontent > table > tbody:not(.header)'; curSite.pager.scrollD = 2000;
  4454. }},
  4455. style: 'tr.forum_head {display: none !important;}',
  4456. pager: {
  4457. type: 1,
  4458. nextL: '//div[contains(@class, "xmc_Pages")]//a[text()="下一页"]',
  4459. pageE: 'css;.forum_body table > tbody',
  4460. replaceE: 'css;.xmc_Pages',
  4461. scrollD: 1500
  4462. }
  4463. }, // 小木虫
  4464. google_scholar: {
  4465. host: 'scholar.google.com',
  4466. functionS: function() {if (lp == '/scholar') {curSite = DBSite.google_scholar;}},
  4467. pager: {
  4468. type: 1,
  4469. nextL: '//a[./span[contains(@class, "next")]]',
  4470. pageE: 'css;#gs_res_ccl_mid > *',
  4471. insertP: ['css;#gs_res_ccl_mid', 3],
  4472. replaceE: 'css;#gs_n',
  4473. scriptT: 1,
  4474. scrollD: 2000
  4475. }
  4476. }, // 谷歌学术
  4477. google_scholar_: {
  4478. host: 'sc.panda321.com',
  4479. pager: {
  4480. type: 1,
  4481. nextL: '//a[./span[contains(@class, "next")]]',
  4482. pageE: 'css;#gs_res_ccl_mid > *',
  4483. insertP: ['css;#gs_res_ccl_mid', 3],
  4484. replaceE: 'css;#gs_n',
  4485. scriptT: 1,
  4486. scrollD: 2000
  4487. },
  4488. function: {
  4489. bF: function(pageElems){
  4490. getCSS('#gs_n').remove();
  4491. return pageElems
  4492. }
  4493. }
  4494. }, // 谷歌学术 - 其他镜像站
  4495. bing_academic: {
  4496. style: 'li.aca_algo_count {display: none !important;}',
  4497. pager: {
  4498. type: 1,
  4499. nextL: 'css;a.sb_pagN',
  4500. pageE: 'css;#b_results > li.aca_algo',
  4501. replaceE: 'css;#b_results .b_pag',
  4502. scrollD: 1000
  4503. }
  4504. }, // 必应学术
  4505. baidu_xueshu: {
  4506. host: 'xueshu.baidu.com',
  4507. functionS: function() {if (lp == '/s') {
  4508. curSite = DBSite.baidu_xueshu;
  4509. } else if (indexOF('journal/navigation')) {
  4510. curSite = DBSite.baidu_xueshu_journal;
  4511. } else if (indexOF('paper/show')) {
  4512. curSite = DBSite.baidu_xueshu_paper;
  4513. }},
  4514. pager: {
  4515. type: 1,
  4516. nextL: 'id("page")/a[./i[@class="c-icon-pager-next"]]',
  4517. pageE: 'css;#bdxs_result_lists > div.result',
  4518. replaceE: 'css;#page',
  4519. scrollD: 1000
  4520. }
  4521. }, // 百度学术
  4522. baidu_xueshu_journal: {
  4523. pager: {
  4524. type: 1,
  4525. nextL: 'css;a.res-page-next',
  4526. pageE: 'css;#journaldetail > div',
  4527. replaceE: 'css;.res-page',
  4528. scrollD: 1000
  4529. }
  4530. }, // 百度学术
  4531. baidu_xueshu_paper: {
  4532. pager: {
  4533. type: 2,
  4534. nextL: 'css;div:not([style*="display: none"]) > .more_btn',
  4535. nextText: '加载更多',
  4536. scrollD: 1000
  4537. }
  4538. }, // 百度学术
  4539. so_xueshu: {
  4540. host: 'xueshu.so.com',
  4541. functionS: function() {if (lp == '/s') {curSite = DBSite.so_xueshu;}},
  4542. pager: {
  4543. type: 1,
  4544. nextL: 'css;a#snext',
  4545. pageE: 'css;ul.list > li',
  4546. replaceE: 'css;#page',
  4547. scrollD: 1000
  4548. }
  4549. }, // 360 学术
  4550. wanfangdata: {
  4551. host: 's.wanfangdata.com.cn',
  4552. functionS: function() {locationC = true; curSite = DBSite.wanfangdata;},
  4553. style: '#zkFooter {display: none !important;}',
  4554. iframe: true,
  4555. pager: {
  4556. type: 5,
  4557. nextL: () => getNextEP('css;.pager.active+span.pager', 'p=', /p=\d+/),
  4558. scrollD: 2000
  4559. }
  4560. }, // 万方数据知识服务
  4561. nsfc: {
  4562. host: ['output.nsfc.gov.cn', 'kd.nsfc.gov.cn'],
  4563. functionS: function() {if (indexOF('/conclusionProject/')) curSite = DBSite.nsfc;},
  4564. style: '#pageNoUl {display: none !important;}',
  4565. pager: {
  4566. type: 4,
  4567. nextL: nsfc_nextL,
  4568. insertP: ['css;#pageNoUl', 1],
  4569. insertE: nsfc_insertE,
  4570. scrollD: 1500
  4571. }
  4572. }, // 国家自然科学基金
  4573. stackoverflow: {
  4574. host: 'stackoverflow.com',
  4575. functionS: function() {if (indexOF('/questions') && !indexOF(/\/questions\/\d+\//)) {
  4576. curSite = DBSite.stackoverflow;
  4577. } else if (lp == '/search') {
  4578. curSite = DBSite.stackoverflow_search;
  4579. } else if (lp == '/tags') {
  4580. curSite = DBSite.stackoverflow_tags;
  4581. } else if (lp == '/users') {
  4582. curSite = DBSite.stackoverflow_users;
  4583. }},
  4584. pager: {
  4585. type: 1,
  4586. nextL: 'css;a[rel="next"]',
  4587. pageE: 'css;#questions > div',
  4588. replaceE: 'css;.pager',
  4589. scrollD: 2000
  4590. }
  4591. }, // StackOverflow - Questions
  4592. stackoverflow_tags: {
  4593. pager: {
  4594. type: 1,
  4595. nextL: 'css;a[rel="next"]',
  4596. pageE: 'css;#tags-browser > div',
  4597. replaceE: 'css;.pager',
  4598. scrollD: 2000
  4599. }
  4600. }, // StackOverflow - Tags
  4601. stackoverflow_users: {
  4602. pager: {
  4603. type: 1,
  4604. nextL: 'css;a[rel="next"]',
  4605. pageE: 'css;#user-browser > div:first-child > div',
  4606. replaceE: 'css;.pager',
  4607. scrollD: 2000
  4608. }
  4609. }, // StackOverflow - Users
  4610. stackoverflow_search: {
  4611. pager: {
  4612. type: 1,
  4613. nextL: 'css;a[rel="next"]',
  4614. pageE: 'css;.js-search-results > div:first-child > div',
  4615. replaceE: 'css;.pager',
  4616. scrollD: 2000
  4617. }
  4618. }, // StackOverflow - Search
  4619. segmentfault: {
  4620. host: 'segmentfault.com',
  4621. functionS: function() {locationC = true;
  4622. if (indexOF('/questions')) {
  4623. curSite = DBSite.segmentfault;
  4624. } else if (lp == '/search') {
  4625. curSite = DBSite.segmentfault_search;
  4626. }},
  4627. pager: {
  4628. type: 1,
  4629. nextL: '//a[@class="page-link"][contains(text(), "下一页")]',
  4630. pageE: 'css;ul.list-group > li',
  4631. replaceE: 'css;ul.pagination',
  4632. scrollD: 1000
  4633. }
  4634. }, // SegmentFault - Questions
  4635. segmentfault_search: {
  4636. pager: {
  4637. type: 1,
  4638. nextL: 'css;a[rel="next"]',
  4639. pageE: 'css;.search-result > section',
  4640. replaceE: 'css;ul.pagination',
  4641. scrollD: 1000
  4642. }
  4643. }, // SegmentFault - Search
  4644. w3school_com_cn: {
  4645. host: 'www.w3school.com.cn',
  4646. functionS: function() {if (location.pathname.split('/').length > 2) {curSite = DBSite.w3school_com_cn;}},
  4647. style: '#maincontent h1:not(:nth-of-type(1)) {margin-top: 30px;}',
  4648. pager: {
  4649. type: 3,
  4650. nextL: function() { // 过滤部分非本页的参考手册
  4651. let next = getCSS('li.next > a[href]')
  4652. if (next && next.href.indexOf('/index.') === -1) return next.href;
  4653. curSite = {SiteTypeID: 0}; return ''
  4654. },
  4655. pageE: 'css;#maincontent > *:not([class*="prenextnav"]):not(#bpn):not(#tpn)',
  4656. insertP: ['id("bpn") | //div[contains(@class, "prenextnav")][last()]', 1],
  4657. replaceE: 'css;ul.prenext, #navsecond',
  4658. scrollE: 'id("bpn") | //div[contains(@class, "prenextnav")][last()]',
  4659. forceHTTPS: true,
  4660. scrollD: 600
  4661. }
  4662. }, // W3school
  4663. w3cschool_cn: {
  4664. host: 'www.w3cschool.cn',
  4665. functionS: function() {if (location.pathname.split('/').length > 2) {curSite = DBSite.w3cschool_cn;}},
  4666. style: '.widget-body, #rfbanner {display: none !important;}',
  4667. pager: {
  4668. type: 1,
  4669. nextL: 'css;.next-link > a',
  4670. pageE: 'css;#pro-mian-header, .content-bg',
  4671. replaceE: 'css;.content-links, .splitter-sidebar',
  4672. scrollD: 1500
  4673. }
  4674. }, // W3Cschool
  4675. runoob: {
  4676. host: 'www.runoob.com',
  4677. functionS: function() {if (location.pathname.split('/').length > 2 && getCSS('#leftcolumn')) {curSite = DBSite.runoob;}},
  4678. style: '#comments, #postcomments, #respond, #footer {display: none !important;} .article-intro h1:not(:nth-of-type(1)) {margin: 30px 0 10px 0;}',
  4679. pager: {
  4680. type: 1,
  4681. nextL: function() { // 过滤部分非本页的参考手册
  4682. let next = getCSS('#leftcolumn > a[style]~a[href]')
  4683. if (next && next.href.split('/').length === location.href.split('/').length && next.href.split('/')[3] === location.href.split('/')[3]) return next.href;
  4684. next.href = location.href; curSite = {SiteTypeID: 0}; return ''
  4685. },
  4686. pageE: 'css;#content > *, script[src*="assets/js/main.min.js"]',
  4687. insertP: ['css;#content', 3],
  4688. replaceE: 'css;.previous-next-links, #leftcolumn',
  4689. scriptT: 2,
  4690. forceHTTPS: true,
  4691. scrollD: 1000
  4692. }
  4693. }, // 菜鸟教程
  4694. cnblogs: {
  4695. host: ['www.cnblogs.com', 'zzk.cnblogs.com'],
  4696. functionS: function() {
  4697. if (location.hostname === 'zzk.cnblogs.com') {
  4698. curSite = DBSite.cnblogs_search;
  4699. } else if (getCSS('#post_list')) {
  4700. curSite = DBSite.cnblogs_list;
  4701. } else if (location.pathname.split('/').length === 3 && getCSS('.topicListFooter')) {
  4702. curSite = DBSite.cnblogs;
  4703. if (!getCSS('#homepage_top_pager')) {
  4704. getCSS('.forFlow').insertAdjacentHTML(getAddTo(2), '<div id="homepage_top_pager" class="topicListFooter"></div>');
  4705. getCSS('.forFlow').insertAdjacentHTML(getAddTo(3), '<div id="homepage_bottom_pager" class="topicListFooter"></div>');
  4706. }
  4707. }
  4708. },
  4709. pager: {
  4710. type: 1,
  4711. nextL: '//div[@class="topicListFooter"]//a[contains(text(), "下一页")]',
  4712. pageE: 'css;div.day',
  4713. replaceE: 'css;.topicListFooter',
  4714. scrollD: 1000
  4715. }
  4716. }, // 博客园 - 文章列表(个人)
  4717. cnblogs_list: {
  4718. pager: {
  4719. type: 1,
  4720. nextL: '//div[@class="pager"]//a[contains(text(), ">")]',
  4721. pageE: 'css;#post_list > article',
  4722. replaceE: 'css;.pager',
  4723. scrollD: 1000
  4724. }
  4725. }, // 博客园 - 文章列表
  4726. cnblogs_search: {
  4727. pager: {
  4728. type: 1,
  4729. nextL: '//div[@class="pager"]//a[contains(text(), ">")]',
  4730. pageE: 'css;div.searchItem',
  4731. replaceE: 'css;.pager',
  4732. scrollD: 1000
  4733. }
  4734. }, // 博客园 - 搜索页
  4735. gitee: {
  4736. host: 'gitee.com',
  4737. functionS: function() {
  4738. if (indexOF('/explore/')) {
  4739. curSite = DBSite.gitee;
  4740. } else if (indexOF(/\/issues$/)) {
  4741. curSite = DBSite.gitee_issues;
  4742. } else if (indexOF(/\/releases/)) {
  4743. curSite = DBSite.gitee_releases;
  4744. } else if (indexOF(/\/tags/)) {
  4745. curSite = DBSite.gitee_tags;
  4746. }
  4747. if (curSite.SiteTypeID > 0 && !curSite.pager.nextL) {
  4748. curSite.pager.type = 1;
  4749. curSite.pager.nextL = 'css;a[rel="next"]';
  4750. curSite.pager.replaceE = 'css;.pagination';
  4751. curSite.pager.scrollD = 2500;
  4752. }
  4753. },
  4754. pager: {
  4755. pageE: 'css;.items > .item',
  4756. }
  4757. }, // Gitee - Explore 列表
  4758. gitee_issues: {
  4759. pager: {
  4760. pageE: 'css;.issue-wrapper',
  4761. }
  4762. }, // Gitee - Issues 列表
  4763. gitee_releases: {
  4764. pager: {
  4765. pageE: 'css;.release-tag-item',
  4766. }
  4767. }, // Gitee - Releases 列表
  4768. gitee_tags: {
  4769. pager: {
  4770. pageE: 'css;.tag-item',
  4771. }
  4772. }, // Gitee - Tags 列表
  4773. gitee_search: {
  4774. host: 'search.gitee.com',
  4775. functionS: function() {if (location.search) curSite = DBSite.gitee_search;},
  4776. pager: {
  4777. type: 1,
  4778. nextL: 'css;li.next:not(.disabled) > a',
  4779. pageE: 'css;#hits-list > div',
  4780. replaceE: 'css;ul.pagination',
  4781. scrollD: 1000
  4782. }
  4783. }, // Gitee - Search 列表
  4784. github: {
  4785. host: ['github.com', 'hub.fastgit.org'],
  4786. functionS: function() {locationC = true;
  4787. if (lp == '/') {
  4788. curSite = DBSite.github;
  4789. } else if (indexOF('tab=stars', 's')) {
  4790. curSite = DBSite.github_star;
  4791. } else if (indexOF('tab=repositories', 's')) {
  4792. curSite = DBSite.github_repositories;
  4793. } else if (indexOF(/\/issues$/) || indexOF(/\/pulls$/)) {
  4794. curSite = DBSite.github_issues;
  4795. } else if (indexOF(/\/discussions$/) || indexOF('/discussions/categories')) {
  4796. curSite = DBSite.github_discussions;
  4797. } else if (indexOF(/\/releases$/)) {
  4798. curSite = DBSite.github_releases;
  4799. } else if (indexOF(/\/tags$/)) {
  4800. curSite = DBSite.github_tags;
  4801. } else if (indexOF('/commits')) {
  4802. curSite = DBSite.github_commits;
  4803. } else if (indexOF('/notifications')) {
  4804. curSite = DBSite.github_notifications;
  4805. } else if (indexOF('/search')) {
  4806. if (!location.search) return
  4807. if (!indexOF('type=', 's')) {
  4808. if (lp == '/search') {
  4809. curSite = DBSite.github_search_repositories;
  4810. } else {
  4811. curSite = DBSite.github_search_code;
  4812. }
  4813. } else {
  4814. curSite = DBSite['github_search_' + /type=[a-z]+/.exec(location.search.toLowerCase())[0].replace('type=','')];
  4815. }
  4816. if (curSite.SiteTypeID > 0 && !curSite.pager.nextL) {
  4817. curSite.pager.type = 1;
  4818. curSite.pager.nextL = 'css;a.next_page';
  4819. curSite.pager.replaceE = 'css;.pagination';
  4820. curSite.pager.scrollD = 3000;
  4821. }
  4822. }},
  4823. pager: {
  4824. type: 2,
  4825. nextL: 'css;.ajax-pagination-btn',
  4826. nextText: 'More',
  4827. scrollD: 2500
  4828. }
  4829. }, // Github - 首页
  4830. github_star: {
  4831. pager: {
  4832. type: 1,
  4833. nextL: '//div[@class="paginate-container"]//a[contains(text(), "Next")]',
  4834. pageE: 'css;#js-pjax-container .position-relative div[class^="col-lg-"] > div:not(.position-relative):not(.paginate-container)',
  4835. insertP: ['css;.paginate-container', 1],
  4836. replaceE: 'css;.paginate-container',
  4837. scrollD: 3000
  4838. }
  4839. }, // Github - 用户 Star 列表
  4840. github_repositories: {
  4841. pager: {
  4842. type: 1,
  4843. nextL: '//div[@class="paginate-container"]//a[contains(text(), "Next")]',
  4844. pageE: 'css;#user-repositories-list > ul > li',
  4845. replaceE: 'css;.paginate-container',
  4846. scrollD: 3000
  4847. }
  4848. }, // Github - 用户 项目 列表
  4849. github_issues: {
  4850. pager: {
  4851. type: 1,
  4852. nextL: 'css;a.next_page',
  4853. pageE: 'css;.js-navigation-container.js-active-navigation-container > div[id^="issue_"]',
  4854. replaceE: 'css;.pagination',
  4855. scrollD: 3000
  4856. }
  4857. }, // Github - Issues 列表 / PR 列表
  4858. github_discussions: {
  4859. pager: {
  4860. type: 1,
  4861. nextL: 'css;a.next_page',
  4862. pageE: 'css;ul[aria-labelledby="discussions-list"] > li',
  4863. replaceE: 'css;.pagination',
  4864. scrollD: 3000
  4865. }
  4866. }, // Github - Discussions 列表
  4867. github_releases: {
  4868. pager: {
  4869. type: 1,
  4870. nextL: 'css;a.next_page',
  4871. pageE: 'css;#repo-content-pjax-container > div[data-pjax] > div:not(.paginate-container)',
  4872. replaceE: 'css;.pagination',
  4873. scrollD: 3000
  4874. }
  4875. }, // Github - Releases 列表
  4876. github_tags: {
  4877. pager: {
  4878. type: 1,
  4879. nextL: '//div[@class="pagination"]/a[contains(text(), "Next")]',
  4880. pageE: 'css;.Box-body > div.Box-row',
  4881. replaceE: 'css;.pagination',
  4882. scrollD: 3000
  4883. }
  4884. }, // Github - Tags 列表
  4885. github_commits: {
  4886. pager: {
  4887. type: 1,
  4888. nextL: '//div[@class="paginate-container"]//a[contains(text(), "Older")]',
  4889. pageE: 'css;div.js-navigation-container > div',
  4890. replaceE: 'css;.paginate-container',
  4891. scrollD: 3000
  4892. }
  4893. }, // Github - Commits 列表
  4894. github_notifications: {
  4895. pager: {
  4896. type: 1,
  4897. nextL: 'css;nav.paginate-container > a[aria-label="Next"]',
  4898. pageE: 'css;li.notifications-list-item',
  4899. replaceE: 'css;nav.paginate-container, .js-notifications-list-paginator-counts',
  4900. scrollD: 3000
  4901. }
  4902. }, // Github - Notifications 列表
  4903. github_search_repositories: {
  4904. pager: {
  4905. pageE: 'css;ul.repo-list > li',
  4906. }
  4907. }, //Github - Search 列表
  4908. github_search_code: {
  4909. pager: {
  4910. pageE: 'css;.code-list-item',
  4911. }
  4912. }, // Github - Search 列表 - Code
  4913. github_search_commits: {
  4914. pager: {
  4915. pageE: 'css;#commit_search_results > div',
  4916. }
  4917. }, // Github - Search 列表 - Commit
  4918. github_search_issues: {
  4919. pager: {
  4920. pageE: 'css;.issue-list-item',
  4921. }
  4922. }, // Github - Search 列表 - Issues
  4923. github_search_discussions: {
  4924. pager: {
  4925. pageE: 'css;.discussion-list-item',
  4926. }
  4927. }, // Github - Search 列表 - Discussions
  4928. github_search_registrypackages: {
  4929. pager: {
  4930. pageE: 'css;#package_search_results > div',
  4931. }
  4932. }, // Github - Search 列表 - Package
  4933. github_search_marketplace: {
  4934. pager: {
  4935. pageE: 'css;#marketplace_search_results > div:first-child > div',
  4936. }
  4937. }, // Github - Search 列表 - Marketplace
  4938. github_search_topics: {
  4939. pager: {
  4940. pageE: 'css;.topic-list-item',
  4941. }
  4942. }, // Github - Search 列表 - Topics
  4943. github_search_wikis: {
  4944. pager: {
  4945. pageE: 'css;#wiki_search_results > div:first-child > div',
  4946. }
  4947. }, // Github - Search 列表 - wiki
  4948. github_search_users: {
  4949. pager: {
  4950. pageE: 'css;#user_search_results > div:first-child > div',
  4951. }
  4952. }, // Github - Search 列表 - user
  4953. oi_wiki: {
  4954. host: 'oi-wiki.org',
  4955. style: 'blockquote.page-copyright, h2#__comments, form#gitalk-form {display: none !important;} article.md-content__inner{min-height: 700px;}',
  4956. pager: {
  4957. type: 1,
  4958. nextL: 'css;li.md-nav__item.md-nav__item--active.md-nav__item--nested li.md-nav__item--active+li a',
  4959. pageE: 'css;article.md-content__inner',
  4960. insertP: ['css;article.md-content__inner', 6],
  4961. replaceE: 'css;.md-sidebar.md-sidebar--primary',
  4962. scrollD: 1300
  4963. }
  4964. }, // OI Wiki
  4965. guokr: {
  4966. host: 'www.guokr.com',
  4967. pager: {
  4968. type: 2,
  4969. nextL: 'css;div[class*="LoadMoreWrap"]',
  4970. interval: 1500,
  4971. scrollD: 1500
  4972. }
  4973. }, // 果壳网
  4974. landian: {
  4975. host: 'www.landian.vip',
  4976. functionS: function() {if (lp != '/' && !indexOF('/archives/') && !indexOF('/search/')) {curSite = DBSite.landian;}},
  4977. style: '.pagination {display: none !important;}',
  4978. pager: {
  4979. type: 1,
  4980. nextL: () => getNextUPN(/(?<=\/page\/)\d+/, /\/page\/\d+/, '/page/', '', '2', getCSS('.pagination > button.end').textContent),
  4981. pageE: 'css;.content li.color-border',
  4982. scrollD: 1500
  4983. }
  4984. }, // 蓝点网
  4985. kenengba: {
  4986. host: 'kenengba.com',
  4987. functionS: function() {if (lp == '/' || indexOF('/page/') || indexOF('/category/') || indexOF('/tag/')) {curSite = DBSite.kenengba;}},
  4988. pager: {
  4989. type: 1,
  4990. nextL: '//div[@class="pagebar"]/a[@href and text()=">>"]',
  4991. pageE: 'css;article.post',
  4992. replaceE: 'css;.pagebar',
  4993. scrollD: 3000
  4994. }
  4995. }, // 可能吧
  4996. expreview: {
  4997. host: 'www.expreview.com',
  4998. pager: {
  4999. type: 2,
  5000. nextL: 'css;#show_article_red_1SHOW',
  5001. interval: 1500,
  5002. scrollD: 1500
  5003. }
  5004. }, // 超能网
  5005. ithome: {
  5006. host: 'www.ithome.com',
  5007. pager: {
  5008. type: 2,
  5009. nextL: 'css;a.more',
  5010. interval: 1500,
  5011. scrollD: 1500
  5012. }
  5013. }, // IT之家
  5014. _36kr: {
  5015. host: ['36kr.com', 'www.36kr.com'],
  5016. functionS: function() {if (lp != '/' && !indexOF('/p/') && !indexOF('/newsflashes/')) {curSite = DBSite._36kr;}},
  5017. pager: {
  5018. type: 2,
  5019. nextL: 'css;.kr-loading-more-button.show',
  5020. nextText: '查看更多',
  5021. scrollD: 1500
  5022. }
  5023. }, // 36氪
  5024. _36kr_m: {
  5025. host: 'm.36kr.com',
  5026. pager: {
  5027. type: 2,
  5028. nextL: 'css;.kr-loading-more-button-default',
  5029. nextText: '查看更多',
  5030. scrollD: 1500
  5031. }
  5032. }, // 36氪 - 手机版
  5033. sciencealert: {
  5034. host: 'www.sciencealert.com',
  5035. pager: {
  5036. type: 2,
  5037. nextL: 'css;.load-more',
  5038. nextTextOf: 'LOAD MORE',
  5039. scrollD: 2000
  5040. }
  5041. }, // ScienceAlert
  5042. zhutix: {
  5043. host: 'zhutix.com',
  5044. functionS: function() {if (getCSS('#post-list')) {
  5045. curSite = DBSite.zhutix;
  5046. } else {
  5047. curSite = DBSite.zhutix_list;
  5048. }},
  5049. pager: {
  5050. type: 1,
  5051. nextL: '//li[@class="next-page"]/a | //div[@class="btn-pager"]/a[contains(text(), "❯")]',
  5052. pageE: 'css;#post-list > ul > li',
  5053. replaceE: 'css;.pagination, .b2-pagenav.post-nav',
  5054. scrollD: 1500
  5055. }
  5056. }, // 致美化
  5057. zhutix_list: {
  5058. pager: {
  5059. type: 1,
  5060. nextL: 'css;li.next-page a',
  5061. pageE: 'css;#primary-home > div:not(.pagination)',
  5062. replaceE: 'css;.pagination',
  5063. scrollD: 1500
  5064. }
  5065. }, // 致美化 - 文章列表
  5066. lanzou: {
  5067. host: /\.lanzou[a-z]\./,
  5068. hiddenPN: true,
  5069. pager: {
  5070. type: 2,
  5071. nextL: 'css;#filemore',
  5072. nextTextOf: '更多',
  5073. isHidden: true,
  5074. scrollD: 800
  5075. }
  5076. }, // 蓝奏云 - 分享链接列表
  5077. lanzou_: {
  5078. host: 'pc.woozooo.com',
  5079. iframe: true,
  5080. hiddenPN: true,
  5081. pager: {
  5082. type: 2,
  5083. nextL: 'css;#filemore > span[onclick]',
  5084. nextText: '显示更多文件',
  5085. isHidden: true,
  5086. scrollD: 800
  5087. }
  5088. }, // 蓝奏云 - 后台
  5089. alipanso: {
  5090. host: 'www.alipanso.com',
  5091. functionS: function() {if (lp == '/search.html') {curSite = DBSite.alipanso;}},
  5092. style: '.pager-wrap {display: none !important;}',
  5093. pager: {
  5094. type: 1,
  5095. nextL: () => getNextUP('page=', /page=\d+/),
  5096. pageE: 'css;#res_list > div',
  5097. scrollD: 2000
  5098. }
  5099. }, // 阿里盘搜
  5100. wikihow: {
  5101. host: ['www.wikihow.com', 'zh.wikihow.com'],
  5102. functionS: function() {if (indexOF('/Category:')) {
  5103. curSite = DBSite.wikihow;
  5104. } else if (indexOF('/wikiHowTo') && indexOF('?search=', 's')) {
  5105. curSite = DBSite.wikihow_search;
  5106. }},
  5107. pager: {
  5108. type: 1,
  5109. nextL: 'css;a.pag_next',
  5110. pageE: 'css;#cat_all > .cat_grid > div',
  5111. replaceE: 'css;#large_pagination',
  5112. scriptT: 3,
  5113. scrollD: 2000
  5114. }
  5115. }, // 指南
  5116. wikihow_search: {
  5117. pager: {
  5118. type: 1,
  5119. nextL: 'css;#searchresults_footer > a.buttonright',
  5120. pageE: 'css;#searchresults_list > a',
  5121. replaceE: 'css;#searchresults_footer',
  5122. scrollD: 3000
  5123. }
  5124. }, // 指南 - 搜索页
  5125. afreecatv: {
  5126. host: 'www.afreecatv.com',
  5127. pager: {
  5128. type: 2,
  5129. nextL: 'css;.btn-more > button',
  5130. interval: 2000,
  5131. scrollD: 1000
  5132. }
  5133. }, // 直播
  5134. greasyfork: {
  5135. host: 'greasyfork.org',
  5136. functionS: function() {if (indexOF(/\/scripts$/) || indexOF('/scripts/by-site/')) {
  5137. curSite = DBSite.greasyfork;
  5138. } else if (indexOF(/\/feedback$/)) {
  5139. curSite = DBSite.greasyfork_feedback;
  5140. } else if (indexOF('/discussions') && !indexOF(/\/\d+/)) {
  5141. curSite = DBSite.greasyfork_discussions;
  5142. }},
  5143. pager: {
  5144. type: 1,
  5145. nextL: 'css;a.next_page',
  5146. pageE: 'css;ol#browse-script-list > li',
  5147. replaceE: 'css;.pagination',
  5148. scrollD: 1300
  5149. }
  5150. }, // 脚本
  5151. greasyfork_feedback: {
  5152. pager: {
  5153. type: 1,
  5154. nextL: 'css;a.next_page',
  5155. pageE: 'css;.script-discussion-list > div',
  5156. replaceE: 'css;.pagination',
  5157. scrollD: 1800
  5158. }
  5159. }, // 脚本 - 反馈页
  5160. greasyfork_discussions: {
  5161. pager: {
  5162. type: 1,
  5163. nextL: 'css;a.next_page',
  5164. pageE: 'css;.discussion-list > div',
  5165. replaceE: 'css;.pagination',
  5166. scrollD: 1300
  5167. }
  5168. }, // 脚本 - 讨论页
  5169. userstyles: {
  5170. host: 'userstyles.world',
  5171. functionS: function() {if (lp == '/explore') {curSite = DBSite.userstyles;}},
  5172. pager: {
  5173. type: 1,
  5174. nextL: 'css;a.Pagination-button.next',
  5175. pageE: 'css;.card',
  5176. replaceE: 'css;.Pagination',
  5177. scrollD: 1500
  5178. }
  5179. }, // UserStyles
  5180. getquicker: {
  5181. host: 'getquicker.net',
  5182. functionS: function() {if (indexOF('/Share/')) {curSite = DBSite.getquicker;}},
  5183. pager: {
  5184. type: 1,
  5185. nextL: '//a[@class="page-link" and text()="下一页"]',
  5186. pageE: 'css;table.table > tbody > tr:not(:first-child), script[src^="/js/site.js"]',
  5187. insertP: ['css;table.table > tbody', 3],
  5188. replaceE: 'css;ul.pagination',
  5189. scriptT: 2,
  5190. scrollD: 1000
  5191. }
  5192. }, // Quicker
  5193. bookmarkearth: {
  5194. host: 'www.bookmarkearth.com',
  5195. functionS: function() {if (lp == '/' || lp == '/page') {
  5196. curSite = DBSite.bookmarkearth;
  5197. } else if (lp == '/s/search') {
  5198. curSite = DBSite.bookmarkearth_search;
  5199. }},
  5200. pager: {
  5201. type: 1,
  5202. nextL: () => getNextUP('currentPage=', /currentPage=\d+/, '/page', '2', getCSS('ul.pager').dataset.totalpage),
  5203. pageE: 'css;.document-piece',
  5204. replaceE: 'css;ul.pager',
  5205. scrollD: 1000
  5206. }
  5207. }, // 书签地球
  5208. bookmarkearth_search: {
  5209. pager: {
  5210. type: 1,
  5211. nextL: () => getNextEP('css;a.cut-page-item.active+a.cut-page-item', 'currentPage=', /currentPage=\d+/),
  5212. pageE: 'css;.document-piece',
  5213. replaceE: 'css;.cut-page',
  5214. scrollD: 1000
  5215. }
  5216. }, // 书签地球 - 搜索页
  5217. smzdm: {
  5218. host: ['www.smzdm.com', 'search.smzdm.com'],
  5219. functionS: function() {if (location.hostname === 'search.smzdm.com' || indexOF('/fenlei/') || indexOF(/\/mall\/.+\/.+/)) {curSite = DBSite.smzdm;}},
  5220. pager: {
  5221. type: 1,
  5222. nextL: '//ul[@class="pagenation-list"]//a[contains(text() ,"下一页")] | //ul[@class="pagenation-list"]/li[contains(@class, "next-page")]/a',
  5223. pageE: 'css;#feed-main-list > li',
  5224. replaceE: 'css;ul.pagenation-list',
  5225. scrollD: 1500
  5226. }
  5227. }, // 什么值得买 - 分类/搜索页
  5228. meidebi: {
  5229. host: 'www.meidebi.com',
  5230. functionS: function() {if (indexOF('/fenlei/') || lp == '/Search') {
  5231. curSite = DBSite.meidebi;
  5232. }},
  5233. pager: {
  5234. type: 1,
  5235. nextL: 'css;a.next',
  5236. pageE: 'css;.share-list > ul > li',
  5237. replaceE: 'css;.h-pages',
  5238. scrollD: 1500
  5239. }
  5240. }, // 没得比 - 分类/搜索页
  5241. ruyile_xuexiao: {
  5242. host: 'www.ruyile.com',
  5243. functionS: function() {
  5244. if (lp == '/xuexiao/') {
  5245. curSite = DBSite.ruyile_xuexiao;
  5246. } else if (lp == '/data/') {
  5247. curSite = DBSite.ruyile_data;
  5248. } else if (lp == '/shijuan/') {
  5249. curSite = DBSite.ruyile_shijuan;
  5250. }},
  5251. pager: {
  5252. type: 1,
  5253. nextL: '//div[@class="fy"]/a[contains(text(), "下一页")]',
  5254. pageE: 'css;.xxlb > .sk',
  5255. insertP: ['css;.xxlb', 3],
  5256. replaceE: 'css;.fy',
  5257. scrollD: 1000
  5258. }
  5259. }, // 如意了教育 - 学校
  5260. ruyile_data: {
  5261. pager: {
  5262. type: 1,
  5263. nextL: '//div[@class="fy"]/a[contains(text(), "下一页")]',
  5264. pageE: 'css;.m1_z > .lbk',
  5265. insertP: ['css;.page', 1],
  5266. replaceE: 'css;.fy',
  5267. scrollD: 1000
  5268. }
  5269. }, // 如意了教育 - 数据
  5270. ruyile_shijuan: {
  5271. pager: {
  5272. type: 1,
  5273. nextL: '//div[@class="fy"]/a[contains(text(), "下一页")]',
  5274. pageE: 'css;.m1_z > .m2_lb',
  5275. insertP: ['css;.page', 1],
  5276. replaceE: 'css;.fy',
  5277. scrollD: 1000
  5278. }
  5279. }, // 如意了教育 - 试卷
  5280. koolearn: {
  5281. host: 'cet4.koolearn.com',
  5282. pager: {
  5283. type: 1,
  5284. nextL: 'id("page")/a[text()="下一页"]',
  5285. pageE: 'css;ul.xqy_entry_list > li,.xqy_core_text > p:not([style="text-align:center"])',
  5286. insertP: ['css;ul.xqy_entry_list,.xqy_core_text', 3],
  5287. replaceE: 'css;#page',
  5288. scrollD: 2500
  5289. }
  5290. }, // 新东方在线
  5291. che168: {
  5292. host: 'www.che168.com',
  5293. functionS: function() {
  5294. if (location.pathname != '/' && !indexOF('/dealer/')) {
  5295. curSite = DBSite.che168;
  5296. }},
  5297. pager: {
  5298. type: 1,
  5299. nextL: 'css;a.page-item-next',
  5300. pageE: 'css;ul.viewlist_ul > li',
  5301. replaceE: 'css;.page',
  5302. scrollD: 2000
  5303. }
  5304. }, // 二手车之家
  5305. jiligamefun: {
  5306. host: 'www.jiligamefun.com',
  5307. functionS: function() {if (indexOF('/category/')) {curSite = DBSite.jiligamefun;}},
  5308. pager: {
  5309. type: 1,
  5310. nextL: 'css;a.poi-pager__item.poi-pager__item_next',
  5311. pageE: 'css;.inn-archive__container > article',
  5312. replaceE: 'css;.poi-pager',
  5313. scrollD: 1800
  5314. }
  5315. }, // 叽哩叽哩日报
  5316. wendangku: {
  5317. host: 'www.wendangku.net',
  5318. functionS: function() {if (indexOF('/doc/')) {curSite = DBSite.wendangku;}},
  5319. pager: {
  5320. type: 1,
  5321. nextL: 'css;a.next',
  5322. pageE: 'css;#contents > *:not(.pages)',
  5323. replaceE: 'css;.pages',
  5324. scrollD: 1800
  5325. }
  5326. }, // 文档库
  5327. oshwhub: {
  5328. host: 'www.oshwhub.com',
  5329. functionS: function() {if (lp == '/explore') {curSite = DBSite.oshwhub;}},
  5330. pager: {
  5331. type: 1,
  5332. nextL: 'css;a.current+a',
  5333. pageE: 'css;.each-project',
  5334. replaceE: 'css;.page',
  5335. scriptT: 0,
  5336. scrollD: 1200
  5337. }
  5338. }, // 立创开源硬件平台
  5339. netbian: {
  5340. host: 'pic.netbian.com',
  5341. style: 'li.nextpage {display: none !important;}',
  5342. pager: {
  5343. type: 1,
  5344. nextL: '//div[@class="page"]/a[contains(text(),"下一页")]',
  5345. pageE: 'css;.slist ul > li:not(.nextpage)',
  5346. replaceE: 'css;.page',
  5347. scrollD: 1000
  5348. }
  5349. }, // 彼岸图网
  5350. ioliu: {
  5351. host: 'bing.ioliu.cn',
  5352. functionS: function() {if (!indexOF('/photo/') && !indexOF('.html')) {curSite = DBSite.ioliu; document.head.appendChild(document.createElement('base')).target = '_blank';}},
  5353. style: '.progressive--not-loaded {filter: none !important;}',
  5354. pager: {
  5355. type: 1,
  5356. nextL: '//div[@class="page"]/a[contains(text(), "下一页")]',
  5357. pageE: 'css;body > .container > div.item',
  5358. replaceE: 'css;.page',
  5359. scrollD: 1000
  5360. }
  5361. }, // 必应壁纸
  5362. konachan: {
  5363. host: 'konachan.net',
  5364. functionS: function() {if (indexOF('/post')) {curSite = DBSite.konachan; document.head.appendChild(document.createElement('base')).target = '_blank';}},
  5365. style: 'html, body {min-height: 1000px;} .javascript-hide {display: inline-block !important;} ul#post-list-posts img, ul#post-list-posts .inner{width: auto !important; height: auto !important;} ul#post-list-posts li {width: 33% !important;} a.directlink {margin: 0 !important;}',
  5366. pager: {
  5367. type: 1,
  5368. nextL: 'css;a.next_page',
  5369. pageE: 'css;ul#post-list-posts > li',
  5370. replaceE: 'css;#paginator',
  5371. scrollD: 1000
  5372. }
  5373. }, // 动漫壁纸
  5374. nastol: {
  5375. host: 'www.nastol.com.ua',
  5376. pager: {
  5377. type: 1,
  5378. nextL: '//a[./span[@class="nav-next"]]',
  5379. pageE: 'css;#dle-content > div',
  5380. replaceE: 'css;.navigation',
  5381. scrollD: 1000
  5382. }
  5383. }, // 壁纸
  5384. hdqwalls: {
  5385. host: 'hdqwalls.com',
  5386. pager: {
  5387. type: 1,
  5388. nextL: 'css;a#next',
  5389. pageE: 'css;.wallpapers_container > div.wall-resp',
  5390. replaceE: 'css;ul.pagination',
  5391. scrollD: 1000
  5392. }
  5393. }, // 壁纸
  5394. xinpianchang: {
  5395. host: 'www.xinpianchang.com',
  5396. style: '.lazy-img {opacity: 1 !important;}',
  5397. pager: {
  5398. type: 1,
  5399. nextL: 'css;.page > a[title="下一页"]',
  5400. pageE: 'css;div[class*="-container"] div[class*="-con"] > ul > li, div[class*="-container"] div[class*="-con"] > div[class*="-wrap"] > ul > li',
  5401. insertP: ['css;div[class*="-container"] div[class*="-con"] > ul, div[class*="-container"] div[class*="-con"] > div[class*="-wrap"] > ul', 3],
  5402. replaceE: 'css;.page',
  5403. scrollD: 2000
  5404. },
  5405. function: {
  5406. bF: src_bF,
  5407. pF: [0, 'img[_src]', '_src']
  5408. }
  5409. }, // 新片场
  5410. tujigu: {
  5411. host: ['www.tuji001.com', 'www.tujigu.net'],
  5412. functionS: function() {
  5413. if (indexOF('/a/')) {
  5414. curSite = DBSite.tujigu;
  5415. } else if (location.pathname != '/' && !indexOF('/search/')) {
  5416. curSite = DBSite.tujigu_list;
  5417. }},
  5418. style: '.content img {display: block !important;}',
  5419. pager: {
  5420. type: 1,
  5421. nextL: 'id("pages")/a[contains(text(), "下一页")]',
  5422. pageE: 'css;.content > img',
  5423. replaceE: 'css;#pages',
  5424. scrollD: 2000
  5425. }
  5426. }, // tujigu - 图片页
  5427. tujigu_list: {
  5428. pager: {
  5429. type: 1,
  5430. nextL: 'id("pages")/a[contains(text(), "下一页")]',
  5431. pageE: 'css;.hezi > ul > li',
  5432. insertP: ['//div[@class="hezi"][last()]/ul', 3],
  5433. replaceE: 'css;#pages',
  5434. scrollD: 1000
  5435. }
  5436. }, // tujigu - 分类页
  5437. mvtui: {
  5438. host: 'mvtui.com',
  5439. functionS: function() {if (indexOF('.html')) {curSite = DBSite.mvtui;} else {curSite = DBSite.mvtui_list;}},
  5440. pager: {
  5441. type: 1,
  5442. nextL: 'css;.article-paging span.current+a',
  5443. pageE: 'css;.article-content > p',
  5444. replaceE: 'css;.article-paging',
  5445. scrollD: 3000
  5446. }
  5447. }, // mvtui - 图片页
  5448. mvtui_list: {
  5449. pager: {
  5450. type: 1,
  5451. nextL: 'css;li.next-page a',
  5452. pageE: 'css;#posts > div',
  5453. replaceE: 'css;.pagination',
  5454. scrollD: 1500
  5455. },
  5456. function: {
  5457. bF: src_bF,
  5458. pF: [0, 'img[data-src]', 'data-src']
  5459. }
  5460. }, // mvtui - 分类页
  5461. mzitu: {
  5462. host: 'www.mzitu.com',
  5463. functionS: function() {if (indexOF(/\/\d+/)) {curSite = DBSite.mzitu;getCSS('.main-image a[href]').href = 'javascript:void(0);'} else {curSite = DBSite.mzitu_list;}},
  5464. pager: {
  5465. type: 1,
  5466. nextL: '//div[@class="pagenavi"]/a[contains(string(), "下一页")]',
  5467. pageE: 'css;.main-image img',
  5468. replaceE: 'css;.pagenavi',
  5469. scrollD: 1500
  5470. }
  5471. }, // mzitu - 图片页
  5472. mzitu_list: {
  5473. pager: {
  5474. type: 1,
  5475. nextL: 'css;.next.page-numbers',
  5476. pageE: 'css;.postlist > ul > li',
  5477. replaceE: 'css;.pagination',
  5478. scrollD: 1000
  5479. },
  5480. function: {
  5481. bF: src_bF,
  5482. pF: [0, 'img[data-original]', 'data-original']
  5483. }
  5484. }, // mzitu - 分类/搜索页
  5485. xiurenji: {
  5486. host: /\.xiuren[a-z]+\./,
  5487. functionS: function() {insStyle('img[src$=".gif"]:not([src*="logo"]) {display: none !important;}');
  5488. if (indexOF('.html') && !indexOF('/index')) {
  5489. curSite = DBSite.xiurenji;
  5490. } else if (indexOF('search')) {
  5491. curSite = DBSite.xiurenji_search;
  5492. } else {
  5493. curSite = DBSite.xiurenji_list;
  5494. }},
  5495. pager: {
  5496. type: 1,
  5497. nextL: '//div[@class="page"]/a[text()="下页"]',
  5498. pageE: 'css;div.content > p > *',
  5499. replaceE: 'css;.page',
  5500. scrollD: 1500
  5501. }
  5502. }, // xiurenji - 图片页
  5503. xiurenji_list: {
  5504. pager: {
  5505. type: 1,
  5506. nextL: '//div[@class="page"]/a[text()="下页"]',
  5507. pageE: 'css;li.i_list',
  5508. replaceE: 'css;.page',
  5509. scrollD: 1000
  5510. }
  5511. }, // xiurenji - 分类页
  5512. xiurenji_search: {
  5513. pager: {
  5514. type: 1,
  5515. nextL: 'css;.page > a.current+a',
  5516. pageE: 'css;.node > *',
  5517. replaceE: 'css;.page',
  5518. scrollD: 700
  5519. }
  5520. }, // xiurenji - 搜索页
  5521. tvv: {
  5522. host: /\.tvv\.tw/,
  5523. functionS: function() {if (lp == '/' || indexOF('/page/') || indexOF('/category/')) {curSite = DBSite.tvv;}},
  5524. style: '.blog-masonry, .blog-masonry-4col {height: auto !important;} .blog-listing {position: relative !important;float: left !important;top: auto !important;left: auto !important;} .blog-title > a {white-space: nowrap;overflow: hidden;text-overflow: ellipsis;} .blog-image img {min-height: 300px;}',
  5525. pager: {
  5526. type: 1,
  5527. nextL: 'css;a.next',
  5528. pageE: 'css;.blog-listing',
  5529. replaceE: 'css;.pagination',
  5530. scrollD: 2000
  5531. }
  5532. }, // tvv
  5533. mm131: {
  5534. host: ['www.mm131.net', 'www.mmm131.com'],
  5535. functionS: function() {if (indexOF('.html')) {curSite = DBSite.mm131;} else {curSite = DBSite.mm131_list;}},
  5536. retry: 300,
  5537. pager: {
  5538. type: 1,
  5539. nextL: '//div[@class="content-page"]/a[contains(text(), "下一页")]',
  5540. pageE: 'css;.content-pic img',
  5541. replaceE: 'css;.content-page',
  5542. scrollD: 2000
  5543. }
  5544. }, // MM131 - 图片页
  5545. mm131_list: {
  5546. pager: {
  5547. type: 1,
  5548. nextL: '//dd[@class="page"]/a[contains(text(), "下一页")]',
  5549. pageE: 'css;dl.list-left > dd:not([class="page"])',
  5550. replaceE: 'css;.page',
  5551. scrollD: 1000
  5552. }
  5553. }, // MM131 - 分类页
  5554. mm131_m: {
  5555. host: 'm.mmm131.com',
  5556. functionS: function() {insStyle('.bannert, .bannerb, bannert_ios, .bannerb_ios {display: none !important;}'); if (lp == '/') {curSite = DBSite.mm131_m_;} else if (indexOF('.html')) {curSite = DBSite.mm131_m;} else {curSite = DBSite.mm131_m_list;}},
  5557. retry: true,
  5558. pager: {
  5559. type: 1,
  5560. nextL: '//div[@class="paging"]/a[text()="下一张" or text()="下一页"]',
  5561. pageE: 'css;.post-content img',
  5562. replaceE: 'css;.paging',
  5563. scrollD: 2000
  5564. }
  5565. }, // MM131 - 手机版 - 图片页
  5566. mm131_m_list: {
  5567. pager: {
  5568. type: 1,
  5569. nextL: 'css;#xbtn',
  5570. pageE: 'css;#content > article',
  5571. replaceE: 'css;#webpage',
  5572. scrollD: 2000
  5573. },
  5574. function: {
  5575. bF: src_bF,
  5576. pF: [0, 'img[data-img]', 'data-img']
  5577. }
  5578. }, // MM131 - 手机版 - 分类页
  5579. mm131_m_: {
  5580. pager: {
  5581. type: 2,
  5582. nextL: 'css;#webpage>span[onclick]',
  5583. isHidden: true,
  5584. interval: 500,
  5585. scrollD: 2000
  5586. }
  5587. }, // MM131 - 手机版 - 首页
  5588. mrcong: {
  5589. host: 'mrcong.com',
  5590. functionS: function() {if (lp == '/' || indexOF('/tag/')) {curSite = DBSite.mrcong_list;} else {curSite = DBSite.mrcong;}},
  5591. pager: {
  5592. type: 1,
  5593. nextL: 'css;.post-page-numbers.current+a.post-page-numbers',
  5594. pageE: 'css;#fukie2 > p > img',
  5595. replaceE: 'css;.page-link',
  5596. scrollD: 3000
  5597. }
  5598. }, // MrCong - 图片页
  5599. mrcong_list: {
  5600. pager: {
  5601. type: 3,
  5602. nextL: 'css;.current+a.page',
  5603. pageE: 'css;article.item-list',
  5604. scrollE: 'css;.pagination',
  5605. replaceE: 'css;.pagination',
  5606. scrollD: 2000
  5607. }
  5608. }, // MrCong - 分类页
  5609. buondua: {
  5610. host: 'buondua.com',
  5611. functionS: function() {if (indexOF(/-photos-\d+/)) {curSite = DBSite.buondua;} else {curSite = DBSite.buondua_list;}},
  5612. pager: {
  5613. type: 3,
  5614. nextL: '//nav[@class="pagination"]//span[./a[contains(@class, "is-current")]]/following-sibling::span[1]/a',
  5615. pageE: 'css;.article-fulltext > p',
  5616. scrollE: 'css;nav.pagination',
  5617. replaceE: 'css;nav.pagination',
  5618. scrollD: 1500
  5619. },
  5620. function: {
  5621. bF: src_bF,
  5622. pF: [0, 'img[data-src]', 'data-src']
  5623. }
  5624. }, // Buon Dua - 图片页
  5625. buondua_list: {
  5626. pager: {
  5627. type: 3,
  5628. nextL: 'css;.pagination-next',
  5629. pageE: 'css;.items-row.column, .collection-item.column',
  5630. scrollE: 'css;nav.pagination',
  5631. replaceE: 'css;nav.pagination',
  5632. scrollD: 1200
  5633. },
  5634. function: {
  5635. bF: src_bF,
  5636. pF: [0, 'img[data-src]', 'data-src']
  5637. }
  5638. }, // Buon Dua - 分类页
  5639. fnvshen: {
  5640. host: 'www.fnvshen.com',
  5641. functionS: function() {
  5642. if (indexOF('/gallery/') || indexOF('/tag/')) {
  5643. curSite = DBSite.fnvshen_list;
  5644. } else if (indexOF('/g/')) {
  5645. curSite = DBSite.fnvshen;
  5646. } else if (indexOF(/\/article\/\d+\//)) {
  5647. curSite = DBSite.fnvshen_article;
  5648. } else if (indexOF('/article/')) {
  5649. curSite = DBSite.fnvshen_article_list;
  5650. }},
  5651. pager: {
  5652. type: 1,
  5653. nextL: 'css;#pages > span +a:not(.a1)',
  5654. pageE: 'css;#hgallery > img',
  5655. replaceE: 'css;#pages',
  5656. scrollD: 1500
  5657. }
  5658. }, // fnvshen - 图片页
  5659. fnvshen_list: {
  5660. style: '.yalayi_box {display: none !important; margin: -4px 0 !important;}',
  5661. pager: {
  5662. type: 1,
  5663. nextL: '//div[@class="pagesYY"]//a[contains(text(), "下一页")]',
  5664. pageE: 'css;#listdiv > ul > li',
  5665. replaceE: 'css;.pagesYY',
  5666. scrollD: 1000
  5667. },
  5668. function: {
  5669. bF: src_bF,
  5670. pF: [0, 'img[data-original]', 'data-original']
  5671. }
  5672. }, // fnvshen - 分类页
  5673. fnvshen_article_list: {
  5674. pager: {
  5675. type: 1,
  5676. nextL: '//div[@class="pagesYY"]//a[contains(text(), "下一页")]',
  5677. pageE: 'css;li.other_girlli',
  5678. replaceE: 'css;.pagesYY',
  5679. scrollD: 1000
  5680. }
  5681. }, //fnvshen - 文章列表
  5682. fnvshen_article: {
  5683. pager: {
  5684. type: 1,
  5685. nextL: 'css;.pagesYY a.cur+a',
  5686. pageE: 'css;#articleDiv',
  5687. insertP: ['css;#articleDiv', 6],
  5688. replaceE: 'css;.pagesYY',
  5689. scrollD: 1000
  5690. }
  5691. }, // fnvshen - 文章内
  5692. xrmn5: {
  5693. host: 'www.xrmn5.cc',
  5694. functionS: function() {if (indexOF(/\d+\.html/)) {
  5695. curSite = DBSite.xrmn5;
  5696. } else if (indexOF('/search')) {
  5697. curSite = DBSite.xrmn5_search;
  5698. } else {
  5699. curSite = DBSite.xrmn5_list;
  5700. }},
  5701. pager: {
  5702. type: 1,
  5703. nextL: '//div[contains(@class, "page")]//a[contains(text(), "下页")]',
  5704. pageE: 'css;.content_left > p > img',
  5705. replaceE: 'css;.page',
  5706. scrollD: 3000
  5707. }
  5708. }, // xrmn5 - 图片页
  5709. xrmn5_list: {
  5710. pager: {
  5711. type: 1,
  5712. nextL: '//div[contains(@class, "page")]//a[contains(text(), "下页")]',
  5713. pageE: 'css;ul.update_area_lists > li',
  5714. replaceE: 'css;.page',
  5715. scrollD: 2000
  5716. }
  5717. }, // xrmn5 - 分类页
  5718. xrmn5_search: {
  5719. pager: {
  5720. type: 1,
  5721. nextL: 'css;.page a.current+a',
  5722. pageE: 'css;div.sousuo',
  5723. replaceE: 'css;.page',
  5724. scrollD: 2000
  5725. }
  5726. }, // xrmn5 - 搜索页
  5727. jpmn8: {
  5728. host: 'www.jpmn8.com',
  5729. functionS: function() {if (indexOF(/\/\d+\.html/)) {curSite = DBSite.jpmn8;} else if (location.pathname != '/') {curSite = DBSite.jpmn8_list;}},
  5730. style: 'img[onload] {min-height: 500px;}',
  5731. pager: {
  5732. type: 1,
  5733. nextL: '//div[@class="pagination1"]//a[text()="下一页"]',
  5734. pageE: 'css;img[onload]',
  5735. replaceE: 'css;.pagination1',
  5736. scrollD: 3000
  5737. }
  5738. }, // jpmn8 - 图片页
  5739. jpmn8_list: {
  5740. pager: {
  5741. type: 1,
  5742. nextL: '//div[@class="pagination1"]//a[text()="下一页"]',
  5743. pageE: 'css;article.excerpt',
  5744. replaceE: 'css;.pagination1',
  5745. scrollD: 1500
  5746. }
  5747. }, // jpmn8 - 分类页
  5748. ku66: {
  5749. host: 'www.ku66.net',
  5750. functionS: function() {if (/\/\d+\.html/.test(location.pathname)) {curSite = DBSite.ku66;} else {curSite = DBSite.ku66_list;}},
  5751. style: '.content img {min-height: 500px;}',
  5752. pager: {
  5753. type: 1,
  5754. nextL: '//div[@class="NewPages"]//a[text()="下一页"]',
  5755. pageE: 'css;.content > img',
  5756. insertP: ['css;.content', 3],
  5757. replaceE: 'css;.NewPages',
  5758. scrollD: 4000
  5759. }
  5760. }, // ku66 - 图片页
  5761. ku66_list: {
  5762. pager: {
  5763. type: 1,
  5764. nextL: '//div[@class="NewPages"]//a[text()="下一页"]',
  5765. pageE: 'css;.TypeList > ul > li',
  5766. insertP: ['css;.TypeList > ul', 3],
  5767. replaceE: 'css;.NewPages',
  5768. scrollD: 1000
  5769. }
  5770. }, // ku66 - 分类页
  5771. ku66_m: {
  5772. host: 'm.ku66.net',
  5773. functionS: function() {if (/\/\d+\.html/.test(location.pathname)) {curSite = DBSite.ku66_m;} else {curSite = DBSite.ku66_m_list;}},
  5774. style: '.ArticleImageBox img {min-height: 200px;}',
  5775. pager: {
  5776. type: 1,
  5777. nextL: '//div[@class="article_page"]//a[text()="下一页"]',
  5778. pageE: 'css;.ArticleImageBox > *',
  5779. replaceE: 'css;.article_page',
  5780. scrollD: 4000
  5781. }
  5782. }, // ku66 - 手机版 - 图片页
  5783. ku66_m_list: {
  5784. pager: {
  5785. type: 1,
  5786. nextL: '//div[@class="article_page"]//a[text()="下一页"]',
  5787. pageE: 'css;.PictureList > ul > li',
  5788. replaceE: 'css;.article_page',
  5789. scrollD: 1000
  5790. }
  5791. }, // ku66 - 手机版 - 分类页
  5792. ku137: {
  5793. host: 'www.ku137.net',
  5794. functionS: function() {if (indexOF(/\/\d+\.html/)) {curSite = DBSite.ku137;} else if (location.pathname != '/') {curSite = DBSite.ku137_list;}},
  5795. style: '.Title9, .dibu1, .dibu2 {display: none !important;} .content img {min-height: 500px;}',
  5796. pager: {
  5797. type: 1,
  5798. nextL: '//div[@class="page"]/a[text()="下一页"]',
  5799. pageE: 'css;.content > img',
  5800. replaceE: 'css;.page',
  5801. scrollD: 3000
  5802. }
  5803. }, // ku137 - 图片页
  5804. ku137_list: {
  5805. pager: {
  5806. type: 1,
  5807. nextL: '//div[@class="page"]/a[text()="下一页"]',
  5808. pageE: 'css;.m-list > ul > li',
  5809. replaceE: 'css;.page',
  5810. scrollD: 1500
  5811. }
  5812. }, // ku137 - 分类页
  5813. ku137_m: {
  5814. host: 'm.ku137.net',
  5815. functionS: function() {if (indexOF(/\/\d+\.html/)) {curSite = DBSite.ku137_m;} else if (location.pathname != '/') {curSite = DBSite.ku137_m_list;}},
  5816. style: '.ArticleImageBox img {min-height: 300px;}',
  5817. pager: {
  5818. type: 1,
  5819. nextL: '//div[@class="article_page"]//a[text()="下一页"]',
  5820. pageE: 'css;.ArticleImageBox > *',
  5821. replaceE: 'css;.article_page',
  5822. scrollD: 3000
  5823. }
  5824. }, // ku137 - 手机版 - 图片页
  5825. ku137_m_list: {
  5826. pager: {
  5827. type: 1,
  5828. nextL: '//div[@class="article_page"]//a[text()="下一页"]',
  5829. pageE: 'css;.PictureList > ul > li',
  5830. replaceE: 'css;.article_page',
  5831. scrollD: 1500
  5832. }
  5833. }, // ku137 - 手机版 - 分类页
  5834. mnttz: {
  5835. host: 'www.mnttz.com',
  5836. functionS: function() {if (indexOF(/\/\d+\.html/)) {curSite = DBSite.mnttz;} else {curSite = DBSite.mnttz_list;}},
  5837. style: 'img.content_img {min-height: 500px;}',
  5838. pager: {
  5839. type: 1,
  5840. nextL: 'css;.article-paging > span+a',
  5841. pageE: 'css;img.content_img',
  5842. replaceE: 'css;.article-paging',
  5843. scrollD: 3000
  5844. }
  5845. }, // mnttz - 图片页
  5846. mnttz_list: {
  5847. pager: {
  5848. type: 1,
  5849. nextL: 'css;li.next-page > a',
  5850. pageE: 'css;article.excerpt',
  5851. replaceE: 'css;.pagination',
  5852. scrollD: 1500
  5853. },
  5854. function: {
  5855. bF: src_bF,
  5856. pF: [0, 'img[data-src]', 'data-src']
  5857. }
  5858. }, // mnttz - 分类页
  5859. kingdom: {
  5860. host: /kingdom-en\.com/,
  5861. functionS: function() {if (indexOF(/\/\d+\.html/)) {curSite = DBSite.kingdom;} else {curSite = DBSite.kingdom_list;}},
  5862. style: '.pic_center img {min-height: 300px;} .arcmain > .title, .footer, .index-list-title, .listmain_st {display: none !important;}',
  5863. pager: {
  5864. type: 1,
  5865. nextL: '//a[@class="page_next"] | //div[@class="article_page"]//a[text()="下一页"]',
  5866. pageE: 'css;.pic_center img',
  5867. replaceE: '//div[@class="pages2" or @class="article_page"]',
  5868. scrollD: 4000
  5869. }
  5870. }, // kingdom - 图片页
  5871. kingdom_list: {
  5872. pager: {
  5873. type: 1,
  5874. nextL: () => getCSS('a.page_next').href.replace(/(www.)?ermo.net/, location.hostname).replace(/http(s)?:/, location.protocol),
  5875. pageE: 'css;.channel_list3 > ul > li, ul#container > li',
  5876. replaceE: 'css;.pages, .list_page',
  5877. scrollD: 1000
  5878. }
  5879. }, // kingdom - 分类页
  5880. kissgoddess: {
  5881. host: /kissgoddess\./,
  5882. functionS: function() {if (indexOF('/album/') || indexOF('/category/')) curSite = DBSite.kissgoddess;},
  5883. style: '.td-gallery-content > img {min-height: 300px;}',
  5884. pager: {
  5885. type: 1,
  5886. nextL: 'css;a.a1:last-of-type',
  5887. pageE: 'css;.td-gallery-content > img, .td-category-span',
  5888. replaceE: 'css;#pages',
  5889. scrollD: 3000
  5890. },
  5891. function: {
  5892. bF: src_bF,
  5893. pF: [0, 'img[data-original]', 'data-original']
  5894. }
  5895. }, // Kiss Goddess - 图片页
  5896. planetminecraft: {
  5897. host: 'www.planetminecraft.com',
  5898. functionS: function() {if (!indexOF('/forums/') && !indexOF('/posts/')) {curSite = DBSite.planetminecraft;}},
  5899. style: '.resource .r-preview>a img[loading=lazy]:not(.lazyloaded) {visibility: initial !important;}',
  5900. pager: {
  5901. type: 1,
  5902. nextL: 'css;a.pagination_next',
  5903. pageE: 'css;.resource_block > ul.resource_list > li',
  5904. replaceE: 'css;.pagination',
  5905. scrollD: 3000
  5906. }
  5907. }, // Planet Minecraft
  5908. cadtutor: {
  5909. host: 'www.cadtutor.net',
  5910. functionS: function() {
  5911. if (indexOF('/forum/forum/')) {
  5912. curSite = DBSite.cadtutor;
  5913. } else if (indexOF('/forum/topic/') && GM_getValue('menu_thread')) {
  5914. curSite = DBSite.cadtutor_post;
  5915. } else if (indexOF('/forum/search/')) {
  5916. curSite = DBSite.cadtutor_search;
  5917. }},
  5918. pager: {
  5919. type: 1,
  5920. nextL: 'css;a[rel="next"]',
  5921. pageE: 'css;ol.ipsDataList > li:not([data-rowid])~li',
  5922. replaceE: 'css;ul.ipsPagination',
  5923. scrollD: 2000
  5924. }
  5925. }, // CADTutor - 列表页
  5926. cadtutor_post: {
  5927. pager: {
  5928. type: 1,
  5929. nextL: 'css;a[rel="next"]',
  5930. pageE: 'css;#elPostFeed > form > *:not(input):not(.after-first-post)',
  5931. replaceE: 'css;ul.ipsPagination',
  5932. scrollD: 2000
  5933. }
  5934. }, // CADTutor - 帖子内
  5935. cadtutor_search: {
  5936. pager: {
  5937. type: 1,
  5938. nextL: 'css;a[rel="next"]',
  5939. pageE: 'css;ol.ipsStream > li',
  5940. replaceE: 'css;ul.ipsPagination',
  5941. scrollD: 2000
  5942. }
  5943. }, // CADTutor - 搜索页
  5944. theswamp: {
  5945. host: 'www.theswamp.org',
  5946. functionS: function() {
  5947. if (!location.search) return
  5948. if (indexOF('board=', 's')) {
  5949. curSite = DBSite.theswamp;
  5950. } else if (indexOF('topic=', 's') && GM_getValue('menu_thread')) {
  5951. curSite = DBSite.theswamp_post;
  5952. }},
  5953. pager: {
  5954. type: 1,
  5955. nextL: 'css;.pagelinks > strong+a',
  5956. pageE: 'css;#messageindex tbody > tr:not([class])',
  5957. replaceE: 'css;.pagelinks',
  5958. scrollD: 2000
  5959. }
  5960. }, // TheSwamp - 列表页
  5961. theswamp_post: {
  5962. pager: {
  5963. type: 1,
  5964. nextL: 'css;.pagelinks > strong+a',
  5965. pageE: 'css;#forumposts form > *',
  5966. replaceE: 'css;.pagelinks',
  5967. scrollD: 2000
  5968. }
  5969. } // TheSwamp - 帖子内
  5970. };
  5971. // 生成 SiteTypeID
  5972. setSiteTypeID();
  5973. // 用于脚本判断(针对部分特殊的网站)
  5974. SiteType = {
  5975. BAIDU_TIEBA: DBSite.baidu_tieba.SiteTypeID
  5976. };
  5977. }
  5978.  
  5979.  
  5980. if (webType != 1) {
  5981. switch (webType) {
  5982. case 2: // < 所有 Discuz!论坛 >
  5983. discuz_(); break;
  5984. case 3: // < 所有 Flarum 论坛 >
  5985. DBSite.flarum.functionS(); break;
  5986. case 4: // < 所有 phpBB 论坛 >
  5987. DBSite.phpbb.functionS(); break;
  5988. case 5: // < 所有 Xiuno 论坛 >
  5989. DBSite.xiuno.functionS(); break;
  5990. case 6: // < 所有 XenForo 论坛 >
  5991. DBSite.xenforo.functionS(); break;
  5992. case 7: // < 所有 NexusPHP 论坛 >
  5993. DBSite.nexusphp.functionS(); break;
  5994. case 100: // < 所有使用 WordPress DUX 主题的网站 >
  5995. DBSite.dux.functionS(); if (location.hostname === 'apphot.cc') {curSite.pager.scrollD = 2500;}; break;
  5996. case 101: // < 所有使用 WordPress XIU 主题的网站 >
  5997. DBSite.dux.functionS(); curSite.function = {bF: src_bF, pF: [0, 'img.thumb[data-original]', 'data-original']}; break;
  5998. case 102: // < 所有使用 WordPress D8 主题的网站 >
  5999. DBSite.dux.functionS(); delete curSite.function; break;
  6000. case 103: // < 所有使用 WordPress Begin 主题的网站 >
  6001. DBSite.begin.functionS(); break;
  6002. case 200: // < 所有使用 笔趣阁 模板的小说网站 >
  6003. DBSite.biquge.functionS(); break;
  6004. }
  6005. }
  6006.  
  6007. // 显示页码
  6008. if (GM_getValue('menu_page_number')) {pageNumber('add');} else {pageNumber('set');}
  6009. // 左键双击网页空白处暂停翻页
  6010. pausePageEvent();
  6011. // 强制新标签页打开链接(翻页模式 5/6)
  6012. if (curSite.forceTarget) forceTarget();
  6013.  
  6014. // 对于使用 pjax 技术的网站,需要监听 URL 变化来重新判断翻页规则
  6015. if (locationC) {
  6016. nowLocation = location.href
  6017. if (window.onurlchange === undefined) {addUrlChangeEvent();} // Tampermonkey v4.11 版本添加的 onurlchange 事件 grant,可以监控 pjax 等网页的 URL 变化
  6018. if (webType === 1) {
  6019. window.addEventListener('urlchange', function(){
  6020. lp = location.pathname;
  6021. //console.log(nowLocation, location.href)
  6022. if (curSite.history !== false && window.top.document.xiu_nowUrl === location.href) {nowLocation = location.href; return}
  6023. if (nowLocation == location.href) return
  6024. if (curSite.pager && curSite.pager.type == 5) {
  6025. if (self != top) {window.top.location.href = location.href;} else {if (getCSS('iframe#xiu_iframe')) {getCSS('iframe#xiu_iframe').remove();}}
  6026. pausePage = true;
  6027. } // 对于翻页模式 5,如果是 iframe 框架内 URL 变动,则升级为顶级页面,如果是顶级页面的 URL 变动,则清理 iframe 框架
  6028. nowLocation = location.href; curSite = {SiteTypeID: 0}; pageNum.now = 1; // 重置规则+页码
  6029. registerMenuCommand(); // 重新判断规则
  6030. //console.log(curSite);
  6031. if (curSite.style) {insStyle(curSite.style)} // 插入 Style CSS 样式
  6032. curSite.pageUrl = ''; // 下一页URL
  6033. pageLoading(); // 自动无缝翻页
  6034.  
  6035. if (GM_getValue('menu_page_number')) {pageNumber('add');} else {pageNumber('set');} // 显示页码
  6036. pausePageEvent(); // 左键双击网页空白处暂停翻页
  6037. })
  6038. } else if (webType === 3) {
  6039. window.addEventListener('urlchange', function(){
  6040. lp = location.pathname;
  6041. if (nowLocation == location.href) return
  6042. nowLocation = location.href; curSite = {SiteTypeID: 0}; pageNum.now = 1; // 重置规则+页码
  6043. DBSite.flarum.functionS(); // 重新判断规则
  6044. if (curSite.style) {insStyle(curSite.style)} // 插入 Style CSS 样式
  6045. pageLoading(); // 自动无缝翻页
  6046.  
  6047. if (GM_getValue('menu_page_number')) {pageNumber('add');} else {pageNumber('set');} // 显示页码
  6048. pausePageEvent(); // 左键双击网页空白处暂停翻页
  6049. })
  6050. }
  6051. }
  6052. // 插入 Style CSS 样式
  6053. if (curSite.style) insStyle(curSite.style)
  6054.  
  6055. // 对翻页模式 5 的子 iframe 添加一个跟随滚动的事件
  6056. if (curSite.pager && curSite.pager.type === 5 && self != top) {
  6057. var beforeScrollTop = document.documentElement.scrollTop || document.body.scrollTop
  6058. window.addEventListener('scroll', function (e) {
  6059. let scrollTop = window.parent.document.documentElement.scrollTop || window.parent.document.body.scrollTop,
  6060. clientHeight = window.parent.document.documentElement.clientHeight || window.parent.document.body.clientHeight,
  6061. scrollHeight = window.parent.document.documentElement.scrollHeight || window.parent.document.body.scrollHeight,
  6062. afterScrollTop = document.documentElement.scrollTop || document.body.scrollTop,
  6063. delta = afterScrollTop - beforeScrollTop;
  6064. if (delta == 0) return false;
  6065. beforeScrollTop = afterScrollTop;
  6066. //console.log(delta, scrollHeight - (scrollTop + clientHeight), '2222')
  6067. if (delta > 0 && scrollTop + clientHeight < scrollHeight) {
  6068. window.parent.scrollBy(0, delta*2);
  6069. }
  6070. }, false);
  6071. }
  6072.  
  6073. curSite.pageUrl = ''; // 下一页URL
  6074. //console.log(curSite);
  6075. pageLoading(); // 自动无缝翻页
  6076.  
  6077.  
  6078. // --------------------------------------------------------
  6079.  
  6080.  
  6081. // [Discuz! 论坛] 判断各版块帖子列表类型
  6082. function discuzForum() {
  6083. if (getCSS('#autopbn')) { // 判断是否有 [下一页] 按钮
  6084. curSite = DBSite.discuz_forum;
  6085. } else if (getCSS('#waterfall')) { // 判断是否为图片模式
  6086. if (!getCSS('#pgbtn, .pgbtn')) { // 如果各版块帖子列表已存在这个元素,说明自带了无缝翻页
  6087. curSite = DBSite.discuz_waterfall; waterfallStyle(); // 图片模式列表样式预处理
  6088. }
  6089. } else {
  6090. curSite = DBSite.discuz_guide;
  6091. }
  6092. }
  6093. function discuz_() {
  6094. if (getCSS('body[id="nv_forum"][class^="pg_"][onkeydown*="27"]')) {
  6095. switch (getCSS('body[id="nv_forum"][class^="pg_"][onkeydown*="27"]').className) {
  6096. case 'pg_forumdisplay': // < 各版块帖子列表 >
  6097. discuzForum(); break;
  6098. case 'pg_viewthread': // < 帖子内 >
  6099. if (GM_getValue('menu_thread')) curSite = DBSite.discuz_thread; break;
  6100. case 'pg_guide': // < 导读帖子列表等 >
  6101. curSite = DBSite.discuz_guide; break;
  6102. case 'pg_collection': // < 淘贴列表 >
  6103. curSite = DBSite.discuz_collection; break;
  6104. }
  6105. }
  6106. // 如果上面没有匹配的则继续 < 搜索结果 >
  6107. if (curSite.SiteTypeID === 0) {
  6108. if (indexOF('search') || getCSS('body[id="nv_search"][onkeydown*="27"]')) {
  6109. curSite = DBSite.discuz_search;
  6110. }
  6111. }
  6112. // 如果上面没有匹配的则继续
  6113. if (curSite.SiteTypeID === 0) {
  6114. if (indexOF('.html')) { // 判断是不是静态网页(.html 结尾)
  6115. if (indexOF('/forum-')) { // < 各版块帖子列表 >
  6116. discuzForum();
  6117. } else if (indexOF('/thread-')) { // < 帖子内 >
  6118. if (GM_getValue('menu_thread')) curSite = DBSite.discuz_thread;
  6119. }
  6120. }
  6121. }
  6122. // 如果上面没有匹配的则继续
  6123. if (curSite.SiteTypeID === 0) {
  6124. if (indexOF('mod=forumdisplay', 's') || indexOF('forumdisplay.php')) { // < 各版块帖子列表 >
  6125. discuzForum();
  6126. } else if (indexOF('mod=viewthread', 's') || indexOF('viewthread.php')) { // < 帖子内 >
  6127. if (GM_getValue('menu_thread')) curSite = DBSite.discuz_thread;
  6128. } else if (indexOF('mod=guide', 's')) { // < 导读帖子列表 >
  6129. curSite = DBSite.discuz_guide;
  6130. } else if(indexOF('mod=space', 's') && indexOF('do=thread', 's')) { // 别人的主题/回复
  6131. curSite = DBSite.discuz_youspace;
  6132. } else if (indexOF('mod=collection', 's')) { // < 淘贴列表 >
  6133. curSite = DBSite.discuz_collection;
  6134. } else if (getCSS('#threadlist')) { // < 部分论坛的各板块 URL 是自定义的 >
  6135. discuzForum();
  6136. } else if (getCSS('#postlist')) { // < 部分论坛的帖子内 URL 是自定义的 >
  6137. if (GM_getValue('menu_thread')) curSite = DBSite.discuz_thread;
  6138. }
  6139. }
  6140. }
  6141. // [Discuz! 论坛] 图片模式列表样式预处理
  6142. function waterfallStyle() {
  6143. let width = getCSS('#waterfall > li:first-child').style.width;
  6144. if (width) insStyle(`#waterfall {height: auto !important; width: 100% !important;} #waterfall > li {width: ${width} !important; float: left !important; position: inherit !important; left: auto !important; top: auto !important;}`);
  6145. }
  6146.  
  6147.  
  6148. // [谷歌搜索] 的插入前函数(加载视频图片)
  6149. function google_bF(pageElems) {
  6150. if (!indexOF('tbm=nws', 's')){
  6151. pageElems.forEach(function (one) {
  6152. getAllCSS('a[aria-label][href*="https://www.youtube.com/watch?v="]').forEach(function (one1) {
  6153. let img = getCSS('img', one1)
  6154. if (img) img.src = `https://i.ytimg.com/vi/${one1.href.split('?v=')[1]}/mqdefault.jpg`
  6155. })
  6156. });
  6157. }
  6158. return pageElems
  6159. }
  6160.  
  6161.  
  6162. // [必应搜索] 的插入前函数(加载网站图标)
  6163. function bing_bF(pageElems) {
  6164. if (!getCSS('.b_title > a.sh_favicon')) {
  6165. insStyle('.b_title > a.sh_favicon {display: none !important;}');
  6166. delete curSite.function
  6167. console.log(curSite)
  6168. return pageElems
  6169. }
  6170. pageElems.forEach(function (one) {
  6171. getAllCSS('div.rms_iac[data-src]').forEach(function (one1) {
  6172. one1.outerHTML = `<img src="${one1.dataset.src}" height="16" width="16" alt="全球 Web 图标" role="presentation" class="rms_img">`;
  6173. })
  6174. });
  6175. return pageElems
  6176. }
  6177.  
  6178.  
  6179. // [头条搜索] 的插入前函数(过滤相关搜索)
  6180. function toutiao_bF(pageElems) {
  6181. if (getXpath('//div[contains(@class,"-header") and string()="相关搜索"]', pageElems[pageElems.length - 1])) pageElems[pageElems.length - 1].style.display = 'none';
  6182. return pageElems
  6183. }
  6184.  
  6185.  
  6186. // [Startpage] 获取下一页地址
  6187. function startpage_nextL() {
  6188. let form = getXpath('//div[contains(@class, "pagination ")]/form[./button[@class="pagination__next-prev-button next"]]'), value;
  6189. if (form) {
  6190. form.querySelectorAll('input[name]').forEach(function(input) {value += input.name + '=' + input.value + '&';}) // 生成表单参数
  6191. value = encodeURI(value.replace(/&$/,'')); // 清理最后一个 & 符号
  6192. if (form.action && value) return (form.action + '?' + value)
  6193. }
  6194. return '';
  6195. }
  6196.  
  6197.  
  6198. // [SkrBT] 获取下一页地址
  6199. function skrbt_nextL() {
  6200. let page = getCSS('a[onclick][aria-label="Next"]');
  6201. if (page) {page = /(?<=\()\d+(?=\))/.exec(page.onclick)[0];} else {return '';} // 获取下一页页码
  6202. if (page) {
  6203. let action = getCSS('#search-form').action, value = ''; // 获取提交表单 URL
  6204. getAllCSS('#search-form input[name]').forEach(function(input) {value += input.name + '=' + input.value + '&';}) // 生成表单参数
  6205. value = encodeURI(value.replace(/&$/,'').replace(/p=\d+/,'p=' + page)); // 清理最后一个 & 符号,并替换页码
  6206. if (action && value) return (action + '?' + value)
  6207. }
  6208. return '';
  6209. }
  6210.  
  6211.  
  6212. // [百度贴吧](发帖按钮点击事件)
  6213. function baidu_tieba_1() {
  6214. let button = getCSS('.tbui_aside_fbar_button.tbui_fbar_post > a');
  6215. if (button) {
  6216. button.remove();
  6217. getCSS('li.tbui_aside_fbar_button.tbui_fbar_down').insertAdjacentHTML(getAddTo(4), '<li class="tbui_aside_fbar_button tbui_fbar_post"><a href="javascript:void(0);" title="因为 [自动无缝翻页] 的原因,请点击该按钮发帖!"></a></li>')
  6218. button = getCSS('.tbui_aside_fbar_button.tbui_fbar_post > a');
  6219. if (button) {
  6220. button.onclick = function(){
  6221. let button2 = getCSS('div.edui-btn.edui-btn-fullscreen.edui-btn-name-portrait');
  6222. if (button2) {button2.click();} else {alert('提示:登录后才能发帖!');}
  6223. return false;
  6224. }
  6225. }
  6226. }
  6227. }
  6228. // [百度贴吧] 插入数据
  6229. function baidu_tieba_insertE(pageElems, type) {
  6230. if (!pageElems) return
  6231. // 获取 <script> 内容
  6232. const scriptElems = getXpath(`//script[contains(text(), 'Bigpipe.register("frs-list/pagelet/thread_list", ')]`, pageElems, pageElems);
  6233. if (scriptElems) {
  6234. // 从 <script> 中提取帖子列表字符串
  6235. let scriptText = scriptElems.textContent.replace('Bigpipe.register("frs-list/pagelet/thread_list", ','');
  6236. scriptText = scriptText.slice(0, scriptText.indexOf(').'));
  6237. // 字符串转 Element 元素
  6238. let temp_baidu_tieba = document.createElement('div'); temp_baidu_tieba.innerHTML = JSON.parse(scriptText).content;
  6239. processElems(temp_baidu_tieba);
  6240. }
  6241. }
  6242.  
  6243.  
  6244. // [V2EX] 的插入后函数(新标签页打开链接)
  6245. function v2ex_aF(css) {
  6246. let links = getAllCSS(css);if (!links) return
  6247. links.forEach(function (_this) {_this.target = '_blank';});
  6248. }
  6249.  
  6250.  
  6251. // [龙的天空] 获取下一页地址
  6252. function lkong_nextL() {
  6253. let next = getCSS('li.ant-pagination-next'), page;
  6254. if (next && next.getAttribute('aria-disabled') === 'false') {
  6255. page = getCSS('li.ant-pagination-item-active[title]');
  6256. if (page && page.title) {
  6257. return (location.origin + location.pathname + '?page=' + ++page.title);
  6258. }
  6259. }
  6260. return '';
  6261. }
  6262.  
  6263.  
  6264. // [游民星空-攻略] 的插入前函数(移除下一页底部的 "更多相关内容请关注:xxx" 文字 + 加载图片)
  6265. function gamersky_gl_bF(pageElems) {
  6266. pageElems.forEach(function (one) {if (one.tagName === 'P' && one.textContent.indexOf('更多相关内容请关注') > -1) {one.style.display = 'none';}});
  6267. return src_bF(pageElems, [0, 'img[data-src]', 'data-src'])
  6268. }
  6269.  
  6270.  
  6271. // [NexusMods] 获取下一页地址
  6272. function nexusmods_nextL() {
  6273. if (getCSS('.nexus-ui-blocker')) return
  6274. let modList;
  6275. if (indexOF('/news')) {modList = RH_NewsTabContent;} else {modList = RH_ModList;}
  6276. if (!modList) return
  6277. let out_items = JSON.stringify(modList.out_items).replace(/{|}|"/g,''),
  6278. nextNum = getXpath('//div[contains(@class, "pagenav")][1]//a[contains(@class, "page-selected")]/parent::li/following-sibling::li/a'),
  6279. categories = modList.out_items.categories, categoriesUrl = '';
  6280. var url = '';
  6281. if (nextNum && nextNum.innerText) {
  6282. nextNum = nextNum.innerText;
  6283. if (out_items.indexOf('page:') > -1) {
  6284. out_items = out_items.replace(/page:\d+/, `page:${nextNum}`)
  6285. } else {
  6286. out_items += `,page:${nextNum}`;
  6287. }
  6288. if (categories && categories != []) {
  6289. for (let i = 0; i < categories.length; i++) {
  6290. categoriesUrl += `,categories[]:${categories[i]}`
  6291. }
  6292. categoriesUrl = categoriesUrl.replace(/,/,'');
  6293. if (out_items.indexOf('categories:') > -1) {
  6294. out_items = out_items.replace(/categories:\[.*\]/, categoriesUrl)
  6295. }
  6296. }
  6297. return `https://www.nexusmods.com${modList.uri}?RH_${modList.id}=${out_items}`
  6298. }
  6299. return ''
  6300. }
  6301. // [NexusMods] 的插入前函数(隐藏底部元素)
  6302. function nexusmods_bF(pageElems) {
  6303. pageElems.forEach(function (one) {
  6304. let now = one.querySelector('.mod-tile-left');
  6305. if (now) {
  6306. let downloadCount = now.querySelector('.downloadcount > span.flex-label');
  6307. if (downloadCount) {
  6308. if (GlobalModStats[now.dataset.gameId] && GlobalModStats[now.dataset.gameId][now.dataset.modId]) {
  6309. downloadCount.textContent = shortFormat(parseInt(GlobalModStats[now.dataset.gameId][now.dataset.modId].total));
  6310. }
  6311. }
  6312. }
  6313. });
  6314. return pageElems
  6315. }
  6316.  
  6317.  
  6318. // [cs_rin_ru] 各版块帖子列表的插入前函数(过滤置顶帖子)
  6319. function cs_rin_ru_bF(pageElems) {
  6320. for (let i = 0; i < pageElems.length; i++) {
  6321. if (pageElems[i].textContent.replace(/\n| /g,'') === 'Topics') {
  6322. pageElems.splice(0,i+1);
  6323. break;
  6324. }
  6325. }
  6326. return pageElems
  6327. }
  6328.  
  6329.  
  6330. // [bilibili_search] 获取下一页地址
  6331. function bilibili_search_nextL() {
  6332. if (!location.search) return
  6333. let pageActive = 1, pageLast = parseInt(getXpath('//ul[@class="pages"]/li[contains(@class, "page-item")][not(contains(@class, "next") or contains(@class, "prev"))][last()]').innerText);
  6334. if (!pageLast) return
  6335. if (indexOF(/page=\d+/, 's')) {
  6336. pageActive = parseInt(/page=\d+/.exec(location.search)[0].replace('page=',''))
  6337. }
  6338. if (pageActive < pageLast) {
  6339. if (indexOF(/page=\d+/, 's')) {
  6340. return (location.origin + location.pathname + location.search.replace(/page=\d+/,`page=${pageActive+1}`))
  6341. } else {
  6342. return (location.origin + location.pathname + location.search + `&page=${pageActive+1}`)
  6343. }
  6344. }
  6345. }
  6346. // [bilibili_search] 插入前函数(加载图片)
  6347. function bilibili_search_bF(pageElems) {
  6348. pageElems.forEach(function (one) {
  6349. let img = getCSS('.img > .lazy-img > img[src=""]', one)
  6350. if (img) {
  6351. img.setAttribute('data-srclz', 'lazy')
  6352. }
  6353. });
  6354. return pageElems
  6355. }
  6356. // [bilibili_search] 插入后函数(加载图片)
  6357. function bilibili_search_aF() {
  6358. let result = __INITIAL_STATE__.flow[__INITIAL_STATE__.flow.fields[0]].result;
  6359. if (result.length > 0) {
  6360. let imgArr = getAllCSS('.img > .lazy-img > img[data-srclz]');
  6361. if (imgArr.length > 0) {
  6362. for (let i = 0; i < imgArr.length; i++) {
  6363. imgArr[i].src = result[i].pic;
  6364. imgArr[i].removeAttribute('data-srclz');
  6365. }
  6366. }
  6367. }
  6368. }
  6369.  
  6370.  
  6371. // [Anime1] 获取下一页内容(叠加)
  6372. function anime1_nextL() {
  6373. let next = getCSS('a.paginate_button.next');
  6374. if (next && next.className.indexOf('disabled') === -1) {
  6375. let oldList = getCSS('#table-list > tbody').innerHTML;
  6376. if (oldList) {
  6377. next.click();
  6378. pageNum.now = pageNum._now + 1;
  6379. getCSS('#table-list > tbody').insertAdjacentHTML('afterbegin', oldList); // 插入到列表头部
  6380. }
  6381. }
  6382. }
  6383.  
  6384.  
  6385. // [BTHaha] 的插入前函数(隐藏底部元素)
  6386. function bthaha_bF(pageElems) {
  6387. pageElems.forEach(function (one) {
  6388. let now = one.querySelector('[id^="list_top"], [id^="list_bottom"]')
  6389. if (now) {one.hidden = true;}
  6390. });
  6391. return pageElems
  6392. }
  6393.  
  6394.  
  6395. // [RARBG] 的插入前函数(鼠标指向显示封面)
  6396. function rarbg_bF(pageElems) {
  6397. pageElems.forEach(function (one) {
  6398. one.querySelectorAll('td > a[onmouseover][onmouseout]').forEach(function (now) {
  6399. now.parentElement.parentElement.setAttribute('onmouseover', now.getAttribute('onmouseover')); now.removeAttribute('onmouseover');
  6400. now.parentElement.parentElement.setAttribute('onmouseout', now.getAttribute('onmouseout')); now.removeAttribute('onmouseout');
  6401. });
  6402. });
  6403. return pageElems
  6404. }
  6405.  
  6406.  
  6407. // [LRepacks] 的插入前函数(调整 class)
  6408. function lrepacks_bF(pageElems) {
  6409. pageElems.forEach(function (one) {
  6410. let now = one.querySelector('.slideUp, .elementFade')
  6411. if (now) {
  6412. now.className = now.className.replace('slideUp','slideUpRun').replace('elementFade','elementFadeRun');
  6413. }
  6414. });
  6415. return pageElems
  6416. }
  6417.  
  6418.  
  6419. // [漫画狂] 获取下一页地址
  6420. function cartoonmad_nextL() {
  6421. let url = getXpath('//a[@class="pages"][contains(text(),"下一頁")]');
  6422. if (url) {
  6423. if (url.getAttribute('href') === 'thend.asp') {
  6424. url = getXpath('//a[@class="pages"][contains(string(),"下一話")]')
  6425. if (url) return url.href;
  6426. pausePage = false;
  6427. GM_notification({text: `注意:该网站早期漫画(如海贼王、柯南)因为网站自身问题而无法翻至下一话(仅限于显示为 [第 X 卷]/[下一卷] 的)。\n因此需要手动去 [目录页] 进入下一卷!`, timeout: 10000});
  6428. } else {
  6429. return url.href;
  6430. }
  6431. }
  6432. return '';
  6433. }
  6434.  
  6435.  
  6436. // [漫画猫] 初始化(显示本话所以图片)
  6437. function manhuacat_init() {
  6438. let _img = '';
  6439. for (let now of img_data_arr) {_img += `<img src="${asset_domain}${img_pre}${now}">`;}
  6440. getOne(curSite.pager.insertP[0]).innerHTML = _img;
  6441.  
  6442. }
  6443. // [漫画猫] 获取下一页地址
  6444. function manhuacat_nextL(pageElems, type) {
  6445. if (type === 'url') {
  6446. if(pageElems.code == '0000') {
  6447. if (pageElems.url === curSite.pageUrl) return
  6448. curSite.pageUrl = pageElems.url;
  6449. getPageElems_(curSite.pageUrl); // 真正的下一页链接
  6450. }
  6451. } else {
  6452. let vg_r_data = getCSS('.vg-r-data');
  6453. if (vg_r_data) {
  6454. getPageElems_(`${location.origin}/chapter_num?chapter_id=${vg_r_data.dataset.chapter_num}&ctype=1&type=${vg_r_data.dataset.chapterType};`, 'json', 'GET', '', 'url');
  6455. }
  6456. }
  6457. }
  6458. // [漫画猫] 插入数据
  6459. function manhuacat_insertE(pageElems, type) {
  6460. if (!pageElems) return
  6461. if (type === 'url') { // 获取下一页链接
  6462. manhuacat_nextL(pageElems, type); return
  6463. }
  6464. addHistory(pageElems);
  6465. replaceElems(pageElems);
  6466.  
  6467. // 插入图片
  6468. let _img = '', _img_arr = LZString.decompressFromBase64(getXpath('//body/script[not(@src)][contains(text(), "img_data")]').textContent.split('"')[1]).split(','), vg_r_data = getCSS('.vg-r-data');;
  6469. for (let now of _img_arr) {_img += `<img src="${vg_r_data.dataset.chapterDomain}${img_pre}${now}">`;}
  6470. if (_img) {
  6471. getOne(curSite.pager.insertP[0]).insertAdjacentHTML(getAddTo(curSite.pager.insertP[1]), _img); // 将 img 标签插入到网页中
  6472. pageNum.now = pageNum._now + 1
  6473. }
  6474. }
  6475.  
  6476.  
  6477. // [漫画柜] 初始化(将本话其余图片插入网页中)
  6478. function manhuagui_init() {
  6479. // hook imgDate 代码
  6480. SMH.imgData = function(n) {window['imgDate'] = n;return{preInit:function(){}}}
  6481. // 重新执行本页的 imgDate 代码
  6482. insScript(curSite.pager.pageE);
  6483. let _img = '', imgPath = `${location.protocol}//i.hamreus.com${window['imgDate'].path}`;
  6484. //console.log(imgPath, window['imgDate'])
  6485. if (!(window['imgDate']) || !(imgPath)) return
  6486. // 遍历图片文件名数组,组合为 img 标签
  6487. for (let i = 0; i < window['imgDate'].files.length; i++) {_img += `<img src="${imgPath + window['imgDate'].files[i]}?e=${window['imgDate'].sl.e}&m=${window['imgDate'].sl.m}">`;}
  6488. // 插入并覆盖原来的一个图片
  6489. getOne(curSite.pager.insertP[0]).innerHTML = _img;
  6490. pausePage = true;
  6491. }
  6492. // [漫画柜] 获取下一页地址
  6493. function manhuagui_nextL() {
  6494. if (window['imgDate'].nextId == 0) return
  6495. var url = location.origin + location.pathname.replace(window['imgDate'].cid.toString(), window['imgDate'].nextId.toString())
  6496. if (url === curSite.pageUrl) return
  6497. curSite.pageUrl = url
  6498. getPageElems_(curSite.pageUrl);
  6499. }
  6500. // [漫画柜] 插入数据
  6501. function manhuagui_insertE(pageElems, type) {
  6502. if (!pageElems) return
  6503. // 重新执行本页的 imgDate 代码
  6504. insScript(curSite.pager.pageE, document.body, pageElems);
  6505. let _img = '', imgPath = `${location.protocol}//i.hamreus.com${window['imgDate'].path}`;
  6506. //console.log(imgPath, window['imgDate'])
  6507. if (!(window['imgDate']) || !(imgPath)) return
  6508. // 遍历图片文件名数组,组合为 img 标签
  6509. for (let i = 0; i < window['imgDate'].files.length; i++) {_img += `<img src="${imgPath + window['imgDate'].files[i]}?e=${window['imgDate'].sl.e}&m=${window['imgDate'].sl.m}">`;}
  6510. getOne(curSite.pager.insertP[0]).insertAdjacentHTML(getAddTo(curSite.pager.insertP[1]), _img);
  6511. addHistory(pageElems);
  6512. pageNum.now = pageNum._now + 1
  6513. }
  6514.  
  6515.  
  6516. // [36漫画] 初始化(将本话其余图片插入网页中)
  6517. function _36manga_init() {
  6518. let _img = '', imgPath = `${SinConf.resHost[0].domain[0]}${chapterPath}`;
  6519. if (!(chapterImages) || !(imgPath)) return
  6520. // 遍历图片文件名数组,组合为 img 标签
  6521. for (let i = 0; i < chapterImages.length; i++) {_img += `<img src="${imgPath}${chapterImages[i]}">`;}
  6522. // 插入并覆盖原来的一个图片
  6523. getOne(curSite.pager.insertP[0]).innerHTML = _img;
  6524. pausePage = true;
  6525. }
  6526. // [36漫画] 获取下一页地址
  6527. function _36manga_nextL() {
  6528. if (!nextChapterData.id) return
  6529. var url = comicUrl + nextChapterData.id + '.html'
  6530. if (url === curSite.pageUrl) return
  6531. curSite.pageUrl = url
  6532. getPageElems_(curSite.pageUrl);
  6533. }
  6534. // [36漫画] 插入数据
  6535. function _36manga_insertE(pageElems, type) {
  6536. if (!pageElems) return
  6537. // 插入并执行数据代码
  6538. insScript(curSite.pager.pageE, document.body, pageElems);
  6539. let _img = '', imgPath = `${SinConf.resHost[0].domain[0]}${chapterPath}`;
  6540. if (!(chapterImages) || !(imgPath)) return
  6541. // 遍历图片文件名数组,组合为 img 标签
  6542. for (let i = 0; i < chapterImages.length; i++) {_img += `<img src="${imgPath}${chapterImages[i]}">`;}
  6543. // 插入并覆盖原来的一个图片
  6544. getOne(curSite.pager.insertP[0]).insertAdjacentHTML(getAddTo(curSite.pager.insertP[1]), _img);
  6545. addHistory(pageElems);
  6546. pageNum.now = pageNum._now + 1
  6547. }
  6548.  
  6549.  
  6550. // [爱漫画] 获取全部图片
  6551. function imanhuaw_getIMG() {
  6552. let _img = '', _imgUrl;
  6553. for (let one of base64_decode(qTcms_S_m_murl_e).split("$qingtiandy$")) {
  6554. _imgUrl = one;
  6555. if (one.substring(0,1) == '/') {
  6556. _imgUrl = qTcms_m_weburl + _imgUrl;
  6557. } else {
  6558. if (qTcms_Pic_m_if != '2') {
  6559. one = one.replace(/\?/gi, 'a1a1');
  6560. one = one.replace(/&/gi, 'b1b1');
  6561. one = one.replace(/%/gi, 'c1c1');
  6562. let m_httpurl = '';
  6563. if (typeof(qTcms_S_m_mhttpurl) != 'undefined') m_httpurl = base64_decode(qTcms_S_m_mhttpurl);
  6564. if (location.hostname == 'www.ccshwy.com') qTcms_m_indexurl = 'http://h.ccshwy.com/';
  6565. _imgUrl = qTcms_m_indexurl + 'statics/pic/?p=' + escape(one) + '&picid=' + qTcms_S_m_id + '&m_httpurl=' + escape(m_httpurl);
  6566. } else {
  6567. _imgUrl = _imgUrl.replace('http:', '') ;
  6568. _imgUrl = _imgUrl.replace('https:', '');
  6569. }
  6570. }
  6571. _img += `<img src="${_imgUrl}">`;
  6572. }
  6573. return _img;
  6574. }
  6575. // [爱漫画] 初始化(调整本话其余图片)
  6576. function imanhuaw_init() {
  6577. getOne(curSite.pager.insertP[0]).outerHTML = imanhuaw_getIMG();
  6578. document.oncontextmenu = function(){}
  6579. }
  6580. // [爱漫画] 获取下一页地址
  6581. function imanhuaw_nextL() {
  6582. let next = location.origin + qTcms_Pic_nextArr
  6583. if (next && next != location.origin && next != curSite.pageUrl) {
  6584. curSite.pageUrl = next;
  6585. getPageElems_(curSite.pageUrl);
  6586. }
  6587. }
  6588. // [爱漫画] 插入数据
  6589. function imanhuaw_insertE(pageElems, type) {
  6590. if (!pageElems) return
  6591. // 插入并运行 <script>
  6592. insScript('//head/script[not(@src)][contains(text(), "qTcms_S_m_murl_e")]', document.body, pageElems);
  6593. // 将 img 标签插入到网页中
  6594. getOne(curSite.pager.insertP[0]).insertAdjacentHTML(getAddTo(curSite.pager.insertP[1]), imanhuaw_getIMG());
  6595. addHistory(pageElems);
  6596. pageNum.now = pageNum._now + 1
  6597. }
  6598.  
  6599.  
  6600. // [漫画 DB] 初始化(将本话其余图片插入网页中)
  6601. function manhuadb_init() {
  6602. let _img = '', data = getCSS('.vg-r-data'), imgDate;
  6603. if (!data) return
  6604. getAllCSS(curSite.pager.pageE.replace('css;', '')).forEach(function (one) {
  6605. if (one.tagName === 'SCRIPT' && one.textContent.indexOf('var img_data =') > -1) {
  6606. let json = JSON.parse(window.atob(one.textContent.split("'")[1]));
  6607. if (json) {
  6608. let _img = '';
  6609. for (let i = 0; i < json.length; i++) {_img += `<img class="img-fluid show-pic" src="${data.dataset.host + data.dataset.img_pre + json[i].img}">`;}
  6610. getOne(curSite.pager.insertP[0]).insertAdjacentHTML(getAddTo(curSite.pager.insertP[1]), _img); // 将 img 标签插入到网页中
  6611. }
  6612. }
  6613. })
  6614. }
  6615. // [漫画 DB] 获取下一页地址
  6616. function manhuadb_nextL() {
  6617. let nextArr = getAllCSS('a.fixed-a-es'), next;
  6618. var url = '';
  6619. if (nextArr.length == 0) return
  6620. for (let i = 0; i < nextArr.length; i++) {
  6621. if (nextArr[i].className.indexOf('active') > -1) {
  6622. if (nextArr[i+1]) url = nextArr[i+1].href;
  6623. break;
  6624. }
  6625. }
  6626. if (url === curSite.pageUrl) return
  6627. curSite.pageUrl = url
  6628. getPageElems_(curSite.pageUrl);
  6629. }
  6630. // [漫画 DB] 插入数据
  6631. function manhuadb_insertE(pageElems, type) {
  6632. if (!pageElems) return
  6633. if (replaceElems(pageElems, curSite.pager.pageE, curSite.pager.pageE)) {
  6634. addHistory(pageElems);
  6635. pageNum.now = pageNum._now + 1
  6636. manhuadb_init(); // 将刚刚替换的图片插入网页中
  6637. }
  6638. }
  6639.  
  6640.  
  6641. // [HiComic(嗨漫画)] 初始化(将本话其余图片插入网页中)
  6642. function hicomic_init() {
  6643. let _img = '';
  6644. getAllCSS('.chapter > section:not(:first-child) > section[val]').forEach(function (one) {
  6645. let src = one.getAttribute('val');
  6646. if (src.indexOf('!p_c_c_') === -1) src += '!p_c_c_h'
  6647. _img += `<img src="${src}">`
  6648. })
  6649. getOne(curSite.pager.insertP[0]).insertAdjacentHTML(getAddTo(curSite.pager.insertP[1]), _img); // 将 img 标签插入到网页中
  6650. window.document.title = window.document.title.replace(/(\(第.+\))? - HiComic/, `(${getCSS('.chapter_name').textContent}) - HiComic`); // 修改网页标题(加上 第 X 话)
  6651. }
  6652. // [HiComic(嗨漫画)] 获取下一页地址
  6653. function hicomic_nextL() {
  6654. let nextId;
  6655. nextId = getCSS('.next_chapter:not(.end)')
  6656. if (nextId && nextId.id && nextId.id != 'None') {
  6657. curSite.pageUrl = location.href;
  6658. getPageElems_(`https://www.hicomic.net/api/web/chapter/${nextId.id}/contents`, 'json');
  6659. }
  6660. }
  6661. // [HiComic(嗨漫画)] 插入数据
  6662. function hicomic_insertE(pageElems, type) {
  6663. if (!pageElems || pageElems.code != 200) return
  6664. if (pageElems.results.chapter.next) { // 写入下一页的 UUID
  6665. getCSS('.next_chapter').id = pageElems.results.chapter.next;
  6666. } else {
  6667. getCSS('.next_chapter').id = 'None';
  6668. getCSS('.next_chapter').classList.add('end');
  6669. }
  6670. curSite.pageUrl =`https://www.hicomic.net/chapters/${pageElems.results.chapter.uuid}/contents`
  6671. getCSS('.chapter_name').textContent = pageElems.results.chapter.name; // 修改漫画标题
  6672. addHistory(pageElems, window.document.title.replace(/(\(第.+\))? - HiComic/, `(${pageElems.results.chapter.name}) - HiComic`));
  6673. let _img = '';
  6674. for (let i = 0; i < pageElems.results.chapter.contents.length; i++) { // 遍历图片文件名数组,组合为 img 标签
  6675. let src = pageElems.results.chapter.contents[i].url;
  6676. if (src.indexOf('!p_c_c_') === -1) src += '!p_c_c_h';
  6677. _img += `<img src="${src}">`
  6678. }
  6679. getOne(curSite.pager.insertP[0]).insertAdjacentHTML(getAddTo(curSite.pager.insertP[1]), _img); // 将 img 标签插入到网页中
  6680. pageNum.now = pageNum._now + 1
  6681. }
  6682.  
  6683.  
  6684. // [动漫之家] 初始化(调整本话其余图片)
  6685. function dmzj_init(css) {
  6686. let _img = '';
  6687. getAllCSS(css).forEach(function (one) {_img += `<img src="${one.dataset.original}">`;})
  6688. getOne(curSite.pager.insertP[0]).innerHTML = _img;
  6689. }
  6690. // [动漫之家] 插入数据
  6691. function dmzj_insertE(pageElems, type) {
  6692. if (!pageElems) return
  6693. // 插入并运行 <script>
  6694. insScript('css;head > script[type]:not([src])', document.body, pageElems);
  6695.  
  6696. // 插入图片
  6697. let _img = '', _img_arr;
  6698. if (pages.indexOf('|') === -1) {
  6699. _img_arr = JSON.parse(pages.replace(/\r\n/g,'|')).page_url.split('|');
  6700. } else {
  6701. _img_arr = JSON.parse(pages).page_url.split('|');
  6702. }
  6703. for (let now of _img_arr) {
  6704. _img += `<img src="${img_prefix}${now}">`;
  6705. }
  6706. if (_img) {
  6707. getOne(curSite.pager.insertP[0]).insertAdjacentHTML(getAddTo(curSite.pager.insertP[1]), _img); // 将 img 标签插入到网页中
  6708. addHistory(pageElems);
  6709. if (replaceElems(pageElems)) pageNum.now = pageNum._now + 1
  6710. }
  6711. }
  6712. // [动漫之家-漫画] 插入数据
  6713. function dmzj_manhua_insertE(pageElems, type) {
  6714. if (!pageElems) return
  6715. // 插入并运行 <script>
  6716. insScript('css;head > script[type]:not([src])', document.body, pageElems);
  6717.  
  6718. // 插入图片
  6719. let _img = '';
  6720. for (let now of arr_pages) {
  6721. _img += `<img src="${img_prefix}${now}">`;
  6722. }
  6723. if (_img) {
  6724. getOne(curSite.pager.insertP[0]).insertAdjacentHTML(getAddTo(curSite.pager.insertP[1]), _img); // 将 img 标签插入到网页中
  6725. addHistory(pageElems);
  6726. if (replaceElems(pageElems)) pageNum.now = pageNum._now + 1
  6727. }
  6728. }
  6729.  
  6730.  
  6731. // [优酷漫画] 初始化(调整本话其余图片)
  6732. function ykmh_init(css) {
  6733. let host = SinMH.getChapterImage(1).split('/')[0] + '//' + SinMH.getChapterImage(1).split('/')[2];
  6734. if (!host) return
  6735. let _img = '';
  6736. for (let one of chapterImages) {_img += `<img src="${host}${one}">`;}
  6737. getOne(curSite.pager.insertP[0]).innerHTML = _img;
  6738. }
  6739. // [优酷漫画] 获取下一页地址
  6740. function ykmh_nextL() {
  6741. let url = comicUrl + nextChapterData.id + '.html'
  6742. if (url && url != '.html' && url != curSite.pageUrl) {
  6743. curSite.pageUrl = url;
  6744. getPageElems_(curSite.pageUrl);
  6745. }
  6746. }
  6747. // [优酷漫画] 插入数据
  6748. function ykmh_insertE(pageElems, type) {
  6749. //console.log(pageElems)
  6750. if (!pageElems) return
  6751. // 插入并运行 <script>
  6752. insScript('//script[contains(text(),"chapterImages")]', document.body, pageElems);
  6753.  
  6754. let host = SinMH.getChapterImage(1).split('/')[0] + '//' + SinMH.getChapterImage(1).split('/')[2];
  6755. if (!host) host = document.querySelector(curSite.pager.insertP[0]).src.split('/')[0] + '//' + document.querySelector(curSite.pager.insertP[0]).src.split('/')[2]
  6756. // 插入图片
  6757. let _img = '';
  6758. for (let one of chapterImages) {_img += `<img src="${host}${one}">`;}
  6759. if (_img) {
  6760. getOne(curSite.pager.insertP[0]).insertAdjacentHTML(getAddTo(curSite.pager.insertP[1]), _img); // 将 img 标签插入到网页中
  6761. addHistory(pageElems);
  6762. if (replaceElems(pageElems)) pageNum.now = pageNum._now + 1
  6763. }
  6764. }
  6765.  
  6766.  
  6767. // [动漫戏说] 插入后函数(加载图片)
  6768. function acgn_aF() {
  6769. let old = getAllCSS('.pic[_src][id]'), _img = '';
  6770. if (old.length > 0) {
  6771. for (let now of old) {now.outerHTML = `<div class="pic" _src="${now.getAttribute('_src')}"><img src="${now.getAttribute('_src')}" class="img1"></div>`;}
  6772. }
  6773. }
  6774.  
  6775.  
  6776. // [漫画星球] 插入数据
  6777. function mhxqiu_insertE(pageElems, type) {
  6778. if (!pageElems) return
  6779. // 插入并运行 <script>
  6780. insScript('//script[contains(text(), "eval") and contains(text(), "newImgs")]', document.body, pageElems);
  6781.  
  6782. // 插入图片
  6783. let _img = '';
  6784. for (let now of newImgs) {_img += `<li><div style="display: inline-block;zoom: 1;"><img src="${now}" class="loaded lazy" style="opacity: 1;box-shadow:none;"></div></li>`;}
  6785. if (_img) {
  6786. // 将 img 标签插入到网页中
  6787. getOne(curSite.pager.insertP[0]).insertAdjacentHTML(getAddTo(curSite.pager.insertP[1]), _img);
  6788. addHistory(pageElems);
  6789. pageNum.now = pageNum._now + 1
  6790. replaceElems(pageElems)
  6791. }
  6792. }
  6793.  
  6794.  
  6795. // [风之动漫] 插入数据
  6796. function fffdm_insertE(pageElems, type) {
  6797. if (!pageElems) return
  6798. // 插入并运行 <script>
  6799. let scriptElems = getXpath('id("main")/script[contains(text(), "mhpicurl")][1]', pageElems, pageElems);
  6800. if (scriptElems) {
  6801. document.body.appendChild(document.createElement('script')).textContent = scriptElems.textContent.replace(/document\.write.+/, '');
  6802.  
  6803. // 插入图片
  6804. setTimeout(function() {
  6805. getOne(curSite.pager.insertP[0]).appendChild(document.createElement('img')).src = mhpicurl;
  6806. addHistory(pageElems);
  6807. pageNum.now = pageNum._now + 1
  6808. replaceElems(pageElems)
  6809. }, 100)
  6810. }
  6811. }
  6812.  
  6813.  
  6814. // [乐语漫画] 初始化(调整本话其余图片)
  6815. function leyuman_init() {
  6816. let _img = '';
  6817. for (let one of JSON.parse(z_img)) {
  6818. if (one.slice(0,4) === 'http') {
  6819. _img += `<img src="${one}">`;
  6820. } else {
  6821. _img += `<img src="https://img.shishi-life.com/${one}">`;
  6822. }
  6823. }
  6824. getOne(curSite.pager.insertP[0]).innerHTML = _img;
  6825.  
  6826. }
  6827. // [乐语漫画] 插入数据
  6828. function leyuman_insertE(pageElems, type) {
  6829. if (!pageElems) return
  6830. // 插入并运行 <script>
  6831. insScript('//body//script[not(@src)][contains(text(), "z_img=")]', document.body, pageElems);
  6832.  
  6833. // 插入图片
  6834. let _img = '';
  6835. for (let one of JSON.parse(z_img)) {
  6836. if (one.slice(0,4) === 'http') {
  6837. _img += `<img src="${one}">`;
  6838. } else {
  6839. _img += `<img src="https://img.shishi-life.com/${one}">`;
  6840. }
  6841. }
  6842. if (_img) {
  6843. // 将 img 标签插入到网页中
  6844. getOne(curSite.pager.insertP[0]).insertAdjacentHTML(getAddTo(curSite.pager.insertP[1]), _img);
  6845. addHistory(pageElems);
  6846. pageNum.now = pageNum._now + 1
  6847. replaceElems(pageElems)
  6848. }
  6849. }
  6850.  
  6851.  
  6852. // [新新漫画] 初始化(调整本话其余图片)
  6853. function _77mh_init() {
  6854. let _img = '';
  6855. for (let one of arr) {_img += `<img src="${img_qianz}${one}">`;}
  6856. getOne(curSite.pager.insertP[0]).innerHTML = _img;
  6857. }
  6858. // [新新漫画] 获取下一页地址
  6859. function _77mh_nextL() {
  6860. let next = nextLink_b
  6861. if (next && next != curSite.pageUrl) {
  6862. curSite.pageUrl = next;
  6863. getPageElems_(curSite.pageUrl);
  6864. }
  6865. }
  6866. // [新新漫画] 插入数据
  6867. function _77mh_insertE(pageElems, type) {
  6868. if (!pageElems) return
  6869. // 插入并运行 <script>
  6870. insScript('//script[not(@src)][contains(text(), "eval(")]', document.body, pageElems);
  6871.  
  6872. // 插入图片
  6873. let _img = '';
  6874. for (let one of msg.split('|')) {_img += `<img src="${img_qianz}${one}.webp">`;}
  6875. if (_img) {
  6876. // 将 img 标签插入到网页中
  6877. getOne(curSite.pager.insertP[0]).insertAdjacentHTML(getAddTo(curSite.pager.insertP[1]), _img);
  6878. addHistory(pageElems);
  6879. pageNum.now = pageNum._now + 1
  6880. }
  6881. }
  6882.  
  6883.  
  6884. // [古风漫画网] 获取下一页地址
  6885. function gufengmh_nextL() {
  6886. let pageElems = getOne(curSite.pager.pageE); // 寻找数据所在元素
  6887. if (pageElems) {
  6888. let comicUrl, nextId;
  6889. var url = '';
  6890. pageElems.textContent.split(';').forEach(function (one){ // 分号 ; 分割为数组并遍历
  6891. //console.log(one)
  6892. if (one.indexOf('comicUrl') > -1) { // 下一页 URL 前半部分
  6893. comicUrl = one.split('"')[1];
  6894. } else if (one.indexOf('nextChapterData') > -1) { // 下一页 URL 的后半部分 ID
  6895. nextId = one.split('"id":')[1].split(',')[0];
  6896. }
  6897. })
  6898. if (comicUrl && nextId && nextId != 'null') { // 组合到一起就是下一页 URL
  6899. url = comicUrl + nextId + '.html'
  6900. if (url === curSite.pageUrl) return
  6901. curSite.pageUrl = url
  6902. getPageElems_(curSite.pageUrl); // 访问下一页 URL 获取
  6903. }
  6904. }
  6905. }
  6906. // [古风漫画网] 插入数据
  6907. function gufengmh_insertE(pageElems, type) {
  6908. if (pageElems) {
  6909. let url = curSite.pageUrl;
  6910. pageElems = getOne(curSite.pager.pageE, pageElems, pageElems);
  6911. let chapterImages, chapterPath;
  6912. getOne(curSite.pager.pageE).innerText = pageElems.textContent; // 将当前网页内的数据所在元素内容改为刚刚获取的下一页数据内容,以便循环获取下一页 URL
  6913. pageElems.textContent.split(';').forEach(function (one){ // 分号 ; 分割为数组并遍历
  6914. //console.log(one)
  6915. if (one.indexOf('chapterImages') > -1) { // 图片文件名数组
  6916. chapterImages = one.replace(/^.+\[/, '').replace(']', '').replaceAll('"', '').split(',')
  6917. } else if (one.indexOf('chapterPath') > -1) { // 图片文件路径
  6918. chapterPath = one.split('"')[1];
  6919. } else if (one.indexOf('pageTitle') > -1) { // 网页标题
  6920. addHistory(pageElems, one.split('"')[1]);
  6921. }
  6922. })
  6923. if (chapterImages && chapterPath) {
  6924. let _img = '';
  6925. chapterImages.forEach(function (one2){_img += '<img src="https://res.xiaoqinre.com/' + chapterPath + one2 + '" data-index="0" style="display: inline-block;">';})
  6926. getOne(curSite.pager.insertP[0]).insertAdjacentHTML(getAddTo(curSite.pager.insertP[1]), _img); // 将 img 标签插入到网页中
  6927. pageNum.now = pageNum._now + 1
  6928. }
  6929. }
  6930. }
  6931.  
  6932.  
  6933. // [Mangabz 漫画] 初始化(调整本话图片)
  6934. function mangabz_init() {
  6935. let showimage = getCSS('#showimage'),
  6936. cp_img = getCSS('#cp_img'),
  6937. cp_image = getCSS('#cp_image');
  6938. if (showimage) {showimage.removeAttribute('oncontextmenu');}
  6939. if (cp_img) {cp_img.removeAttribute('oncontextmenu');}
  6940. if (cp_image) {
  6941. cp_image.removeAttribute('oncontextmenu');
  6942. cp_image.removeAttribute('id');
  6943. cp_image.removeAttribute('style');
  6944. }
  6945. }
  6946. // [Mangabz 漫画] 获取下一页地址
  6947. function mangabz_nextL() {
  6948. var url = '';
  6949. if (MANGABZ_PAGE === MANGABZ_IMAGE_COUNT) { // 下一话
  6950. if (getNextE('//a[./img[contains(@src, "icon_xiayizhang")]]')) getPageElems_(curSite.pageUrl); // 访问下一话 URL 获取
  6951. } else { // 下一页
  6952. if (!mkey) var mkey = '';
  6953. url = location.origin + location.pathname + 'chapterimage.ashx' + `?cid=${MANGABZ_CID}&page=${MANGABZ_PAGE + 1}&key=${(mkey)}&_cid=${MANGABZ_CID}&_mid=${MANGABZ_MID}&_dt=${MANGABZ_VIEWSIGN_DT}&_sign=${MANGABZ_VIEWSIGN}`
  6954. if (url === curSite.pageUrl) return
  6955. curSite.pageUrl = url
  6956. //console.log(curSite.pageUrl)
  6957. getPageElems_(curSite.pageUrl, 'text', 'GET', '', 'Next'); // 访问下一页 URL 获取
  6958. }
  6959. }
  6960. // [Mangabz 漫画] 插入数据
  6961. function mangabz_insertE(pageElems, type) {
  6962. if (pageElems) {
  6963. if (type === 'Next') { // 下一页
  6964. let imgArr = eval(pageElems),
  6965. _img = '';
  6966. for (let now of imgArr) {_img += `<img src="${now}">`;}
  6967. if (_img) {
  6968. getOne(curSite.pager.insertP[0]).insertAdjacentHTML(getAddTo(curSite.pager.insertP[1]), _img); // 将 img 标签插入到网页中
  6969. MANGABZ_PAGE += imgArr.length;
  6970. addHistory(pageElems, document.title, location.origin + MANGABZ_CURL.substring(0, MANGABZ_CURL.length - 1) + '-p' + MANGABZ_PAGE + '/');
  6971. }
  6972. } else { // 下一话
  6973. // 插入 <script> 标签
  6974. insScript('css;html:not([dir]) > head > script:not([src])', document.body, pageElems);
  6975. addHistory(pageElems);
  6976. pageNum.now = pageNum._now + 1
  6977. replaceElems(pageElems)
  6978. MANGABZ_PAGE = 0;
  6979. mangabz_nextL();
  6980. }
  6981. }
  6982. }
  6983.  
  6984.  
  6985. // [Xmanhua 漫画] 获取下一页地址
  6986. function xmanhua_nextL() {
  6987. var url = '';
  6988. if (XMANHUA_PAGE === XMANHUA_IMAGE_COUNT) { // 下一话
  6989. if (getNextE('//a[./img[contains(@src, "reader-bottom-right-2.png")]]')) getPageElems_(curSite.pageUrl); // 访问下一话 URL 获取
  6990. } else { // 下一页
  6991. if (!mkey) var mkey = '';
  6992. url = location.origin + location.pathname + 'chapterimage.ashx' + `?cid=${XMANHUA_CID}&page=${XMANHUA_PAGE + 1}&key=${(mkey)}&_cid=${XMANHUA_CID}&_mid=${XMANHUA_MID}&_dt=${XMANHUA_VIEWSIGN_DT}&_sign=${XMANHUA_VIEWSIGN}`
  6993. if (url === curSite.pageUrl) return
  6994. curSite.pageUrl = url
  6995. //console.log(curSite.pageUrl)
  6996. getPageElems_(curSite.pageUrl, 'text', 'GET', '', 'Next'); // 访问下一页 URL 获取
  6997. }
  6998. }
  6999. // [Xmanhua 漫画] 插入数据
  7000. function xmanhua_insertE(pageElems, type) {
  7001. if (pageElems) {
  7002. if (type === 'Next') { // 下一页
  7003. let imgArr = eval(pageElems),
  7004. _img = '';
  7005. for (let now of imgArr) {_img += `<img src="${now}">`;}
  7006. if (_img) {
  7007. getOne(curSite.pager.insertP[0]).insertAdjacentHTML(getAddTo(curSite.pager.insertP[1]), _img); // 将 img 标签插入到网页中
  7008. XMANHUA_PAGE += imgArr.length;
  7009. addHistory(pageElems, document.title, location.origin + XMANHUA_CURL.substring(0, XMANHUA_CURL.length - 1) + '-p' + XMANHUA_PAGE + '/');
  7010. }
  7011. } else { // 下一话
  7012. // 插入 <script> 标签
  7013. insScript('css;html:not([dir]) > head > script:not([src])', document.body, pageElems);
  7014. addHistory(pageElems);
  7015. pageNum.now = pageNum._now + 1
  7016. replaceElems(pageElems)
  7017. XMANHUA_PAGE = 0;
  7018. xmanhua_nextL();
  7019. }
  7020. }
  7021. }
  7022.  
  7023.  
  7024. // [COCOMANGA 漫画] 初始化(调整本话图片)
  7025. function cocomanga_init() {
  7026. let last = getCSS('.mh_comicpic:last-of-type');
  7027. if (last && last.getAttribute('p')) {
  7028. getOne(curSite.pager.insertP[0]).innerHTML = ''; // 删除旧图片元素
  7029. cocomanga_img(parseInt(last.getAttribute('p'))) // 插入新图片元素
  7030. }
  7031. }
  7032. // [COCOMANGA 漫画] 生成图片元素并插入网页
  7033. function cocomanga_img(totalImageCount) {
  7034. if (totalImageCount < 1) return
  7035. let _img = '';
  7036. for (let i=1; i<=totalImageCount; i++) {_img += `<div class="mh_comicpic" p="${i}"><img src="${__cr.getPicUrl(i)}"></div>`;}
  7037. getOne(curSite.pager.insertP[0]).insertAdjacentHTML(getAddTo(curSite.pager.insertP[1]), _img); // 将 img 标签插入到网页中
  7038. }
  7039. // [COCOMANGA 漫画] 插入数据
  7040. function cocomanga_insertE(pageElems, type) {
  7041. if (pageElems) {
  7042. // 插入 <script> 标签
  7043. insScript('css;head > script:not([src]), script[src*="custom.js"], script[src*="dynamicjs.js"]', document.body, pageElems);
  7044.  
  7045. // 插入新图片元素
  7046. setTimeout(function() {
  7047. let totalImageCount = __cdecrypt('fw122587mkertyui', CryptoJS.enc.Base64.parse(mh_info.enc_code1).toString(CryptoJS.enc.Utf8));
  7048. if (!totalImageCount) totalImageCount = __cdecrypt('fw12558899ertyui', CryptoJS.enc.Base64.parse(mh_info.enc_code1).toString(CryptoJS.enc.Utf8));
  7049. cocomanga_img(parseInt(totalImageCount));
  7050. }, 100)
  7051. addHistory(pageElems);
  7052. pageNum.now = pageNum._now + 1
  7053. replaceElems(pageElems)
  7054. }
  7055. }
  7056.  
  7057.  
  7058. // [国家自然科学基金] 获取下一页地址
  7059. function nsfc_nextL() {
  7060. let id = decodeURIComponent(document.location.href.split('/')[document.location.href.split('/').length - 1]), data
  7061. if (!document.nowPageNum) document.nowPageNum = 2
  7062. data = `id=${id}&index=${document.nowPageNum}`
  7063. if (data === curSite.pageUrl) return
  7064. curSite.pageUrl = data
  7065. getPageElems_(location.origin + '/baseQuery/data/completeProjectReport', 'json', 'POST', data); // 访问下一页 URL 获取
  7066. }
  7067. // [国家自然科学基金] 插入数据
  7068. function nsfc_insertE(pageElems, type) {
  7069. if (!pageElems || pageElems.code != 200) {curSite.SiteTypeID = 0; return}
  7070. if (!pageElems.data.hasnext) {curSite.SiteTypeID = 0} else {document.nowPageNum++}
  7071. pageNum.now = pageNum._now + 1
  7072. getOne(curSite.pager.insertP[0]).insertAdjacentHTML(getAddTo(curSite.pager.insertP[1]), `<img style="width: 100%;" data-magnify="gallery" data-src="${pageElems.data.url}" src="${pageElems.data.url}">`);
  7073. }
  7074.  
  7075.  
  7076.  
  7077. // [酷科研] 获取下一页地址
  7078. function coolkeyan_nextL() {
  7079. if (!getCSS('.q-img__image')) return
  7080. let id = getCSS('.q-breadcrumbs--last > span.q-breadcrumbs__el'), data
  7081. if (id && id.textContent) {id=parseInt(id.textContent)} else {return}
  7082. if (!document.nowPageNum) document.nowPageNum = 2
  7083. data = `ratify_no=${id}&index=${document.nowPageNum}`
  7084. if (data === curSite.pageUrl) return
  7085. curSite.pageUrl = data
  7086. getPageElems_(location.origin + '/api/funds/nsfc/creport?' + data, 'json', 'GET'); // 访问下一页 URL 获取
  7087. }
  7088. // [酷科研] 插入数据
  7089. function coolkeyan_insertE(pageElems, type) {
  7090. if (!pageElems || pageElems == {}) {curSite.SiteTypeID = 0; return}
  7091. if (!pageElems.url) {curSite.SiteTypeID = 0; return} else {document.nowPageNum++}
  7092. pageNum.now = pageNum._now + 1
  7093. getCSS('.q-img>div[style*="padding-bottom"]').style.paddingBottom = `${(document.nowPageNum * 1000) - 1000}px`
  7094. getOne(curSite.pager.insertP[0]).insertAdjacentHTML(getAddTo(curSite.pager.insertP[1]), `<div class="q-img__image absolute-full" style="background-size: contain; background-position: 50% 50%; background-image: url('${pageElems.url}'); top: ${(document.nowPageNum * 1000) - 2000}px"></div>`);
  7095. }
  7096.  
  7097.  
  7098. // --------------------------------------------------------
  7099.  
  7100.  
  7101. // 自动无缝翻页
  7102. function pageLoading() {
  7103. if (curSite.SiteTypeID == 0) return
  7104. windowScroll(function (direction, e) {
  7105. // 下滑 且 未暂停翻页 且 SiteTypeID > 0 时,才准备翻页
  7106. if (direction != 'down' || !pausePage || curSite.SiteTypeID == 0) return
  7107. // 翻页模式 5 且为框架内时,要判断顶层是否通过页码暂停翻页了
  7108. if (curSite.pager.type == 5 && self != top && window.top.document.xiu_pausePage == false) return
  7109.  
  7110. let scrollTop = document.documentElement.scrollTop || window.pageYOffset || document.body.scrollTop,
  7111. scrollHeight = window.innerHeight || document.documentElement.clientHeight,
  7112. scrollD = curSite.pager.scrollD;
  7113.  
  7114. // <<<<< 翻页类型 3(依靠 [基准元素] 与 [浏览器可视区域底部] 之间的距离缩小来触发翻页)>>>>>
  7115. if (curSite.pager.type === 3) {
  7116. let scrollE = getOne(curSite.pager.scrollE);
  7117. //console.log(scrollE.offsetTop, scrollE.offsetTop - (scrollTop + scrollHeight), scrollD, scrollTop + scrollHeight, curSite.SiteTypeID)
  7118. if (scrollE.offsetTop - (scrollTop + scrollHeight) <= scrollD) {intervalPause(); checkURL(getPageElems);}
  7119.  
  7120. } else {
  7121. if (document.documentElement.scrollHeight <= scrollHeight + scrollTop + scrollD) {
  7122. // <<<<< 翻页类型 1(由脚本实现自动无缝翻页)>>>>>
  7123. if (curSite.pager.type === 1) {
  7124. intervalPause(); checkURL(getPageElems);
  7125.  
  7126. // <<<<< 翻页类型 2(网站自带了自动无缝翻页功能,只需要点击下一页按钮即可)>>>>>
  7127. } else if (curSite.pager.type === 2) {
  7128. let autopbn = getOne(curSite.pager.nextL);
  7129. if (!autopbn) return
  7130. if (curSite.pager.isHidden && isHidden(autopbn)) return // 如果 isHidden = true,那么需要判断元素是否隐藏
  7131. if (curSite.pager.nextText) {
  7132. // 按钮文本,当按钮文本 = 该文本时,才会点击按钮加载下一页
  7133. if (autopbn.innerText === curSite.pager.nextText) {autopbn.click(); pageNum.now = pageNum._now + 1;}
  7134. } else if (curSite.pager.nextTextOf) {
  7135. // 按钮文本的一部分,当按钮文本包含该文本时,才会点击按钮加载下一页
  7136. if (autopbn.innerText.indexOf(curSite.pager.nextTextOf) > -1) {autopbn.click(); pageNum.now = pageNum._now + 1;}
  7137. } else if (curSite.pager.nextHTML) {
  7138. // 按钮内元素,当按钮内元素 = 该元素内容时,才会点击按钮加载下一页
  7139. if (autopbn.innerHTML === curSite.pager.nextHTML) {autopbn.click(); pageNum.now = pageNum._now + 1;}
  7140. } else {
  7141. // 对于没有按钮文字变化的按钮,可以指定间隔时间(默认 300ms)
  7142. if (!curSite.pager.interval) curSite.pager.interval = 300;
  7143. intervalPause();
  7144. // 如果没有指定按钮文字就直接点击
  7145. autopbn.click(); pageNum.now = pageNum._now + 1;
  7146. }
  7147.  
  7148. // <<<<< 翻页类型 4(部分简单的动态加载类网站)>>>>>
  7149. } else if (curSite.pager.type === 4) {
  7150. // 为百度贴吧的发帖考虑,预留底部一小部分...
  7151. if (!(curSite.SiteTypeID === SiteType.BAIDU_TIEBA && document.documentElement.scrollHeight <= scrollHeight + scrollTop + 200)) {
  7152. intervalPause(); if (typeof curSite.pager.nextL == 'function') {curSite.pager.nextL();} else if (getNextE(curSite.pager.nextL)) {getPageElems_(curSite.pageUrl);}
  7153. }
  7154.  
  7155. // <<<<< 翻页类型 5(插入 iframe 方式来加载下一页)>>>>>
  7156. } else if (curSite.pager.type === 5) {checkURL(insIframe);
  7157.  
  7158. // <<<<< 翻页类型 6(通过 iframe 获取下一页动态加载内容)>>>>>
  7159. } else if (curSite.pager.type === 6) {checkURL(insIframe_);}
  7160. }
  7161. }
  7162. });
  7163.  
  7164. function intervalPause() {
  7165. if (curSite.pager.interval) {
  7166. pausePage = false
  7167. setTimeout(function(){pausePage = true;}, curSite.pager.interval)
  7168. }
  7169. }
  7170. }
  7171. // 判断是支持
  7172. function doesItSupport() {
  7173. setDBSite(); // 配置 DBSite 变量对象
  7174.  
  7175. // 遍历判断是否是某个已支持的网站,顺便直接赋值
  7176. let support = false;
  7177. end:
  7178. for (let now in DBSite) { // 遍历 对象
  7179. if (!DBSite[now].host) continue; // 如果不存在则继续下一个循环
  7180.  
  7181. // 如果是 数组
  7182. if (Array.isArray(DBSite[now].host)) {
  7183.  
  7184. for (let i of DBSite[now].host) { // 遍历 数组
  7185. if ((i instanceof RegExp && i.test(location.hostname)) || (typeof i === 'string' && i === location.hostname)) {
  7186.  
  7187. if (self != top) {if (!DBSite[now].iframe) break end;} // 如果当前位于 iframe 框架下,就需要判断是否需要继续执行
  7188. if (DBSite[now].functionS) { DBSite[now].functionS(); } else { curSite = DBSite[now]; }
  7189. support = true; break; // 如果找到了就退出循环
  7190. }
  7191. }
  7192.  
  7193. // 如果是 正则/字符串
  7194. } else if ((DBSite[now].host instanceof RegExp && DBSite[now].host.test(location.hostname)) || (typeof DBSite[now].host === 'string' && DBSite[now].host === location.hostname)) {
  7195.  
  7196. if (self != top) {if (!DBSite[now].iframe) break;} // 如果当前位于 iframe 框架下,就需要判断是否需要继续执行
  7197. if (DBSite[now].functionS) { DBSite[now].functionS(); } else { curSite = DBSite[now]; }
  7198. support = true; break; // 如果找到了就退出循环
  7199. }
  7200.  
  7201. }
  7202.  
  7203. if (support) {
  7204. console.info('[自动无缝翻页] - 独立规则 网站'); return 1;
  7205. } else if (self != top) {
  7206. return -1;
  7207. } else if (getCSS('meta[name="author" i][content*="Discuz!" i], meta[name="generator" i][content*="Discuz!" i], body[id="nv_forum" i][class^="pg_" i][onkeydown*="27"], body[id="nv_search" i][onkeydown*="27"]') || (getCSS('a[href*="www.discuz.net" i]') && getCSS('a[href*="www.discuz.net" i]').textContent.indexOf('Discuz!') > -1) || (getCSS('#ft') && getCSS('#ft').textContent.indexOf('Discuz!') > -1)) {
  7208. console.info('[自动无缝翻页] - <Discuz!> 论坛'); return 2;
  7209. } else if (getCSS('#flarum-loading')) {
  7210. console.info('[自动无缝翻页] - <Flarum> 论坛'); return 3;
  7211. } else if (getCSS('body#phpbb')) {
  7212. console.info('[自动无缝翻页] - <phpBB> 论坛'); return 4;
  7213. } else if (getXpath('//footer//a[contains(string(), "Xiuno")] | //link[contains(@href, "xiuno")] | //script[contains(@src, "xiuno")]')) {
  7214. console.info('[自动无缝翻页] - <Xiuno> 论坛'); return 5;
  7215. } else if (typeof XF != 'undefined') {
  7216. console.info('[自动无缝翻页] - <XenForo> 论坛'); return 6;
  7217. } else if (getCSS('head meta[name="generator" i][content="nexusphp" i]') || getXpath('id("footer")[contains(string(), "NexusPHP")]')) {
  7218. console.info('[自动无缝翻页] - <NexusPHP> 论坛'); return 7;
  7219. } else if (getCSS('link[href*="themes/dux" i], script[src*="themes/dux" i]')) {
  7220. console.info('[自动无缝翻页] - 使用 WordPress <DUX> 主题的网站'); return 100;
  7221. } else if (getCSS('link[href*="themes/xiu" i], script[src*="themes/xiu" i]')) {
  7222. console.info('[自动无缝翻页] - 使用 WordPress <XIU> 主题的网站'); return 101;
  7223. } else if (getCSS('link[href*="themes/d8" i], script[src*="themes/d8" i]')) {
  7224. console.info('[自动无缝翻页] - 使用 WordPress <D8> 主题的网站'); return 102;
  7225. } else if (getCSS('link[href*="themes/begin" i], script[src*="themes/begin" i], img[src*="themes/begin" i]')) {
  7226. console.info('[自动无缝翻页] - 使用 WordPress <Begin> 主题的网站'); return 103;
  7227. } else if ((getCSS('meta[name="description" i][content*="小说"], meta[name="description" i][content*="章节"], meta[name="description" i][content*="阅读"]') || location.hostname.indexOf('biqu') > -1 || document.title.indexOf('笔趣阁') > -1) && getCSS('#content, .content, #chaptercontent, .chaptercontent, #BookText') && getXpath('//a[contains(text(), "下一章") or contains(text(), "下一页")]')) {
  7228. console.info('[自动无缝翻页] - <笔趣阁> 模板的小说网站'); return 200;
  7229. }
  7230. return 0;
  7231. }
  7232.  
  7233.  
  7234. // 翻页类型 1/3
  7235. function getPageElems(url) {
  7236. GM_xmlhttpRequest({
  7237. url: url,
  7238. method: 'GET',
  7239. overrideMimeType: 'text/html; charset=' + document.charset,
  7240. headers: {
  7241. 'Referer': location.href
  7242. },
  7243. timeout: 10000,
  7244. onload: function (response) {
  7245. try {
  7246. //console.log('最终 URL:' + response.finalUrl, '返回内容:' + response.responseText)
  7247. processElems(createDocumentByString(response.responseText));
  7248. } catch (e) {
  7249. console.log(e);
  7250. }
  7251. }
  7252. });
  7253. }
  7254. // 翻页类型 4
  7255. function getPageElems_(url, type = '', method = 'GET', data = '', type2) {
  7256. let mimeType;
  7257. switch (type) {
  7258. case 'json':
  7259. mimeType = 'application/json; charset=' + document.charset; break;
  7260. case 'text':
  7261. mimeType = 'text/plain; charset=' + document.charset; break;
  7262. default:
  7263. mimeType = 'text/html; charset=' + document.charset;
  7264. }
  7265.  
  7266. GM_xmlhttpRequest({
  7267. url: url,
  7268. method: method,
  7269. data: data,
  7270. responseType: type,
  7271. overrideMimeType: mimeType,
  7272. headers: {
  7273. 'Referer': location.href,
  7274. 'Content-Type': (method === 'POST') ? 'application/x-www-form-urlencoded':''
  7275. },
  7276. timeout: 10000,
  7277. onload: function (response) {
  7278. try {
  7279. //console.log('最终 URL:' + response.finalUrl, '返回内容:' + response.responseText)
  7280. switch (type) {
  7281. case 'json':
  7282. curSite.pager.insertE(response.response, type2);
  7283. break;
  7284. case 'text':
  7285. curSite.pager.insertE(response.responseText, type2)
  7286. break;
  7287. default:
  7288. curSite.pager.insertE(createDocumentByString(response.responseText), type2)
  7289. }
  7290. } catch (e) {
  7291. console.log(e);
  7292. }
  7293. }
  7294. });
  7295. }
  7296. // 翻页类型 5(插入 iframe 方式加载下一页,无限套娃)
  7297. function insIframe(src) {
  7298. // 停用当前页面翻页
  7299. if (curSite.SiteTypeID == 0) return
  7300. curSite.SiteTypeID = 0;
  7301.  
  7302. // 创建 iframe
  7303. let iframe = document.createElement('iframe');
  7304. iframe.style = 'position: absolute; width: 100%; height: 100%; border: none;';
  7305. iframe.id = 'xiu_iframe';
  7306. iframe.src = src;
  7307.  
  7308. var beforeScrollTop = document.documentElement.scrollTop || document.body.scrollTop
  7309. // 当滚动条到底部时(即完全显示 iframe 框架),隐藏当前页面的滚动条
  7310. window.addEventListener('scroll', function () {
  7311. let scrollTop = document.documentElement.scrollTop || document.body.scrollTop,
  7312. clientHeight = document.documentElement.clientHeight || document.body.clientHeight,
  7313. scrollHeight = document.documentElement.scrollHeight || document.body.scrollHeight,
  7314. afterScrollTop = document.documentElement.scrollTop || document.body.scrollTop,
  7315. delta = afterScrollTop - beforeScrollTop;
  7316. if (delta == 0) return false;
  7317. beforeScrollTop = afterScrollTop;
  7318.  
  7319. //console.log(delta, scrollHeight - (scrollTop + clientHeight + 10), '1111')
  7320. if (delta > 0 && scrollTop + clientHeight + 10 >= scrollHeight && !getCSS('#xiu-scroll')) {
  7321. let newStyle = document.createElement('style'); newStyle.id = 'xiu-scroll';
  7322. newStyle.textContent = 'html::-webkit-scrollbar, body::-webkit-scrollbar {width: 0 !important;height: 0 !important;} html, body {scrollbar-width: none !important;}';
  7323. if (curSite.pager.style) newStyle.textContent += curSite.pager.style;
  7324. document.documentElement.appendChild(newStyle);
  7325. iframe.focus();
  7326. iframe.document.body.focus();
  7327. //iframe.document.body.click();
  7328. } else if (delta < 0 && getCSS('#xiu-scroll')) {
  7329. getCSS('#xiu-scroll').remove();
  7330. }
  7331. }, false);
  7332.  
  7333. // 加载完成后才继续
  7334. iframe.onload = function() {
  7335. // 添加历史记录
  7336. if (curSite.history !== false) addHistory(iframe.contentWindow.document, iframe.contentWindow.document.title);
  7337. // 当前页码 + 1
  7338. if (!curSite.hiddenPN) {
  7339. let autopageNumber = getCSS('#Autopage_number', window.top.document)
  7340. if (autopageNumber) {autopageNumber.textContent = parseInt(autopageNumber.textContent) + 1;}
  7341. }
  7342. }
  7343.  
  7344. // 插入 iframe
  7345. document.documentElement.appendChild(iframe);
  7346. }
  7347. // 翻页类型 6(通过 iframe 获取下一页动态加载内容,只有一个娃)
  7348. function insIframe_(src) {
  7349. // 暂停翻页
  7350. if (!pausePage) return
  7351. pausePage = false
  7352. console.log(src)
  7353. // 如果不存在,则创建一个 iframe
  7354. let iframe = document.getElementById('xiu_iframe');
  7355. if (!iframe) {
  7356. iframe = document.createElement('iframe');
  7357. iframe.style = 'position: absolute; top: -9999px; left: -9999px; width: 100%; height: 100%; border: none; z-index: -999; /*visibility: hidden;*/';
  7358. iframe.id = 'xiu_iframe';
  7359. iframe.src = src;
  7360. }
  7361.  
  7362. // 加载完成后才继续
  7363. iframe.onload = function() {
  7364. //iframe.contentWindow.scrollTo(0, 999999); // 滚动到底部,以触发网页的滚动条相关加载事件
  7365. //iframe.contentWindow.scrollTo({top: 9999999, behavior: 'smooth'});
  7366. if (!curSite.pager.loadTime) curSite.pager.loadTime = 100; // 默认 100ms
  7367. //console.log(curSite.pager.loadTime, curSite.pager.loadTime/30)
  7368. //console.time('sort');
  7369. let time1 = 0 ,time2 = setInterval(function(){
  7370. let scrollHeight = (iframe.contentWindow.document.documentElement.scrollHeight || iframe.contentWindow.document.body.scrollHeight)/10
  7371. iframe.contentWindow.scrollTo(0, 999999);
  7372. iframe.contentWindow.scrollTo(0, scrollHeight*time1);
  7373. //console.log(time1, iframe.contentWindow.document.documentElement.scrollHeight || iframe.contentWindow.document.body.scrollHeight)
  7374. if (++time1 == 10) {
  7375. //console.timeEnd('sort');
  7376. clearInterval(time2);
  7377. processElems(iframe.contentWindow.document); // 插入/替换元素等
  7378. //console.log(iframe.contentWindow.document.documentElement.scrollHeight || iframe.contentWindow.document.body.scrollHeight)
  7379. pausePage = true; // 恢复翻页
  7380. }
  7381. }, curSite.pager.loadTime/10)
  7382. }
  7383.  
  7384. // 插入 iframe(如果已存在则直接改 src)
  7385. if (document.getElementById('xiu_iframe')) {
  7386. iframe.src = src;
  7387. } else {
  7388. document.documentElement.appendChild(iframe);
  7389. }
  7390. }
  7391.  
  7392.  
  7393. // XHR 后处理结果,插入、替换元素等(适用于翻页类型 1/3/6)
  7394. function processElems(response) {
  7395. if (!curSite.pager.insertP) {curSite.pager.insertP = [curSite.pager.pageE, 5]}
  7396. let pageElems = getAll(curSite.pager.pageE, response, response), toElement;
  7397. if (curSite.pager.insertP[1] === 5) { // 插入 pageE 列表最后一个元素的后面
  7398. toElement = getAll(curSite.pager.insertP[0]).pop();
  7399. } else {
  7400. toElement = getOne(curSite.pager.insertP[0]);
  7401. }
  7402. //console.log(curSite.pager.pageE, pageElems, curSite.pager.insertP, toElement)
  7403.  
  7404. if (pageElems.length > 0 && toElement) {
  7405. // 如果有插入前函数就执行函数
  7406. if (curSite.function && curSite.function.bF) {
  7407. if (curSite.function.pF) { // 如果指定了参数
  7408. pageElems = curSite.function.bF(pageElems, curSite.function.pF);
  7409. } else {
  7410. pageElems = curSite.function.bF(pageElems);
  7411. }
  7412. }
  7413.  
  7414. // 插入位置
  7415. let addTo = getAddTo(curSite.pager.insertP[1]);
  7416.  
  7417. // 插入新页面元素
  7418. if (curSite.pager.insertP[1] === 6) { // 插入到目标内部末尾(针对文本,比如小说网页)
  7419. let afterend = '';
  7420. if (curSite.pager.insertP6Br) afterend += '<br/><br/>'
  7421. pageElems.forEach(function (one) {afterend += one.innerHTML;});
  7422. toElement.insertAdjacentHTML(addTo, afterend);
  7423. } else {
  7424. if (curSite.pager.insertP[1] === 2 || curSite.pager.insertP[1] === 4 || curSite.pager.insertP[1] === 5) pageElems.reverse(); // 插入到 [元素内头部]、[目标本身后面] 时,需要反转顺序
  7425. pageElems.forEach(function (one) {toElement.insertAdjacentElement(addTo, one);});
  7426. }
  7427.  
  7428. // 当前页码 + 1
  7429. pageNum.now = pageNum._now + 1
  7430.  
  7431. // 添加历史记录
  7432. if (curSite.history !== false) addHistory(response);
  7433.  
  7434. // 替换待替换元素
  7435. if (curSite.pager.replaceE) replaceElems(response);
  7436.  
  7437. // 插入 <script> 标签
  7438. if (curSite.pager.scriptT || curSite.pager.scriptT == 0) {
  7439. switch (curSite.pager.scriptT) {
  7440. case 0: // 下一页的所有 <script> 标签
  7441. insScript('css;script', toElement, response); break;
  7442. case 1: // 下一页的所有 <script> 标签(不包括 src 链接)
  7443. insScript('css;script:not([src])', toElement, response); break;
  7444. case 2: // 下一页主体元素 (pageE) 的同级 <script> 标签
  7445. insScript(null, toElement, pageElems); break;
  7446. case 3: // 下一页主体元素 (pageE) 的子元素 <script> 标签
  7447. insScript('css;script:not([src])', toElement, pageElems); break;
  7448. }
  7449. }
  7450.  
  7451. // 如果有插入后函数就执行函数
  7452. if (curSite.function && curSite.function.aF) {
  7453. if (curSite.function.pF) { // 如果指定了参数
  7454. curSite.function.aF(curSite.function.pF);
  7455. } else {
  7456. curSite.function.aF();
  7457. }
  7458. }
  7459. } else { // 获取主体元素失败后,尝试重新获取
  7460. console.log(curSite.pager.pageE, pageElems, curSite.pager.insertP, toElement)
  7461. if (curSite.retry) {
  7462. console.warn('[自动无缝翻页] 获取主体元素失败,尝试重新获取...')
  7463. setTimeout(function(){curSite.pageUrl = '';}, curSite.retry)
  7464. } else { // 尝试替换元素看能不能继续翻页下去
  7465. if (curSite.pager.replaceE) {
  7466. if (replaceElems(response)) { // 如果替换成功
  7467. console.log('[自动无缝翻页] 获取主体元素失败,尝试替换元素成功!')
  7468. pageNum.now = pageNum._now + 1; // 当前页码 + 1
  7469. if (curSite.history !== false) addHistory(response); // 添加历史记录
  7470. } else {console.error('[自动无缝翻页] 获取主体元素失败,尝试替换元素失败...')}
  7471. }
  7472. }
  7473. }
  7474. }
  7475. // 通用型插入前函数(加载图片)
  7476. function src_bF(pageElems, css) {
  7477. pageElems.forEach(function (one) {
  7478. if (css[0] == 0) { // src 图片
  7479. if (one.tagName == 'IMG' && one.getAttribute(css[2])) one.src = one.getAttribute(css[2]);
  7480. one.querySelectorAll(css[1]).forEach(function (now) {
  7481. now.src = now.getAttribute(css[2]);
  7482. });
  7483. } else if (css[0] == 1) { // 背景图片
  7484. if (one.tagName == 'IMG' && one.getAttribute(css[2])) one.style.backgroundImage = 'url("' + one.getAttribute(css[2]) + '")';
  7485. one.querySelectorAll(css[1]).forEach(function (now) {
  7486. now.style.backgroundImage = 'url("' + now.getAttribute(css[2]) + '")';
  7487. });
  7488. }
  7489. });
  7490. return pageElems
  7491. }
  7492. // 文字型插入前函数(正则过滤)
  7493. function xs_bF(pageElems, reg) {
  7494. pageElems.forEach(function (one) {
  7495. console.log(one.innerHTML)
  7496. one.innerHTML = one.innerHTML.replace(reg[0], reg[1])
  7497. });
  7498. return pageElems
  7499. }
  7500.  
  7501. // 通用型获取下一页地址(从 元素 中获取页码)
  7502. function getNextE(css) {
  7503. if (!css) css = curSite.pager.nextL;
  7504. let next = getOne(css)
  7505. if (next && next.nodeType === 1 && next.href && next.href.slice(0,4) === 'http' && next.href != curSite.pageUrl) {
  7506. if (curSite.pager.forceHTTPS && location.protocol === 'https:') {
  7507. curSite.pageUrl = next.href.replace(/^http:/,'https:');
  7508. } else {
  7509. curSite.pageUrl = next.href;
  7510. }
  7511. //console.log(curSite.pageUrl)
  7512. return true
  7513. }
  7514. return false
  7515. }
  7516. // 通用型获取下一页地址(从 元素 中获取页码,URL 替换 page= 参数)
  7517. function getNextEP(css, pf, reg) {
  7518. let nextNum = getOne(css), url = '';
  7519. if (nextNum && nextNum.textContent) {
  7520. nextNum = nextNum.textContent.replaceAll(' ','');
  7521. if (location.search) {
  7522. if (indexOF(pf, 's')) {
  7523. url = location.search.replace(reg, pf + nextNum);
  7524. } else {
  7525. url = location.search + '&' + pf + nextNum;
  7526. }
  7527. } else {
  7528. url = '?' + pf + nextNum;
  7529. }
  7530. url = location.origin + location.pathname + url;
  7531. }
  7532. return url
  7533. }
  7534. // 通用型获取下一页地址(从 元素 中获取页码,URL 替换 pathname 路径)
  7535. function getNextEPN(css, reg, a, b = '') {
  7536. let nextNum = getOne(css), url = '';
  7537. if (nextNum && nextNum.textContent) {
  7538. nextNum = nextNum.textContent.replaceAll(' ','');
  7539. if (location.pathname) {
  7540. if (indexOF(reg)) {
  7541. url = location.pathname.replace(reg, a + nextNum + b);
  7542. } else {
  7543. url = location.pathname + a + nextNum + b;
  7544. }
  7545. } else {
  7546. url = location.pathname + a + nextNum + b;
  7547. }
  7548. url = location.origin + url;
  7549. }
  7550. return url
  7551. }
  7552. // 通用型获取下一页地址(从 URL 中获取页码,URL 替换 pathname 路径)
  7553. function getNextUPN(reg1, reg, a, b = '', initP = '2', endP) {
  7554. let nextNum = reg1.exec(location.pathname);
  7555. if (nextNum) {
  7556. nextNum = String(parseInt(nextNum[0])+1);
  7557. if (endP && (parseInt(nextNum[0]) > parseInt(endP))) return ''
  7558. } else {
  7559. nextNum = initP;
  7560. if (endP && (parseInt(nextNum[0]) >= parseInt(endP))) return ''
  7561. }
  7562. let url = '';
  7563. if (location.pathname) {
  7564. if (indexOF(reg)) {
  7565. url = location.pathname.replace(reg, a + nextNum + b);
  7566. } else {
  7567. url = location.pathname + a + nextNum + b;
  7568. }
  7569. } else {
  7570. url = location.pathname + a + nextNum + b;
  7571. }
  7572. url = location.origin + url;
  7573. return url
  7574. }
  7575. // 通用型获取下一页地址(从 URL 中获取页码,URL 替换 page= 参数)
  7576. function getNextUP(pf, reg, lp = location.pathname, initP = '2', endP) {
  7577. let nextNum = getSearch(pf.replace('=',''));
  7578. if (nextNum) {
  7579. nextNum = String(parseInt(nextNum)+1);
  7580. if (endP && (parseInt(nextNum) > parseInt(endP))) return ''
  7581. } else {
  7582. nextNum = initP;
  7583. if (endP && (parseInt(nextNum) >= parseInt(endP))) return ''
  7584. }
  7585. let url = '';
  7586. if (location.search) {
  7587. if (indexOF(pf, 's')) {
  7588. url = location.search.replace(reg, pf + nextNum);
  7589. } else {
  7590. url = location.search + '&' + pf + nextNum;
  7591. }
  7592. } else {
  7593. url = '?' + pf + nextNum;
  7594. }
  7595. url = location.origin + lp + url;
  7596. return url
  7597. }
  7598.  
  7599. // 检查 URL
  7600. function checkURL(func) {
  7601. if (typeof curSite.pager.nextL == 'function') {
  7602. let tempUrl = curSite.pager.nextL();
  7603. if (!tempUrl || (tempUrl && tempUrl.slice(0,4) != 'http') || tempUrl === curSite.pageUrl ) return;
  7604. curSite.pageUrl = tempUrl;
  7605. func(curSite.pageUrl);
  7606. } else if (getNextE()) {
  7607. func(curSite.pageUrl);
  7608. }
  7609. //console.log(curSite.pageUrl);
  7610. }
  7611. // 替换元素
  7612. function replaceElems(pageElems, o = curSite.pager.replaceE, r = curSite.pager.replaceE) {
  7613. let oriE = getAll(o),
  7614. repE = getAll(r, pageElems, pageElems);
  7615. //console.log(oriE, repE)
  7616. if (oriE.length != 0 && repE.length != 0 && oriE.length === repE.length) {
  7617. for (let i = 0; i < oriE.length; i++) {
  7618. oriE[i].outerHTML = repE[i].outerHTML;
  7619. }
  7620. return true
  7621. }
  7622. return false
  7623. }
  7624. // 添加历史记录
  7625. function addHistory(pageElems, title, url) {
  7626. if (!curSite.pageUrl) return
  7627. // 对于自带类似功能 或者 覆盖了 history 原生函数的网站,则跳过不再添加历史记录
  7628. if (window.top.history.toString() !== '[object History]') return
  7629.  
  7630. //console.log(pageElems.querySelector('title'), curSite.pageUrl)
  7631. title = title || pageElems.querySelector('title').textContent || window.top.document.title;
  7632. url = url || curSite.pageUrl;
  7633. window.top.document.title = title;
  7634. window.top.document.xiu_nowUrl = curSite.pageUrl;
  7635. window.top.history.pushState('xiu_history', title, url);
  7636. }
  7637. // 插入 <Script>
  7638. function insScript(selector, toElement = document.body, contextNode = document) {
  7639. let scriptElems = contextNode;
  7640. if (selector) {
  7641. if (contextNode instanceof Array) {
  7642. scriptElems = []; contextNode.forEach(function (one) {scriptElems = scriptElems.concat(getAll(selector, one, one));})
  7643. } else {
  7644. scriptElems = getAll(selector, contextNode, contextNode);
  7645. }
  7646. }
  7647. scriptElems.forEach(function (one) {
  7648. if (one.tagName === 'SCRIPT') {
  7649. if (one.src) {
  7650. toElement.appendChild(document.createElement('script')).src = one.src;
  7651. } else {
  7652. toElement.appendChild(document.createElement('script')).textContent = one.textContent;
  7653. }
  7654. }
  7655. });
  7656. }
  7657. // 插入 <Style>
  7658. function insStyle(style) {
  7659. document.documentElement.appendChild(document.createElement('style')).textContent = style;
  7660. }
  7661.  
  7662.  
  7663. // 获取元素(CSS/Xpath)来自:https://github.com/machsix/Super-preloader
  7664. function getCSS(css, contextNode = document) {
  7665. return contextNode.querySelector(css);
  7666. }
  7667. function getAllCSS(css, contextNode = document) {
  7668. return [].slice.call(contextNode.querySelectorAll(css));
  7669. }
  7670. function getXpath(xpath, contextNode, doc = document) {
  7671. contextNode = contextNode || doc;
  7672. try {
  7673. const result = doc.evaluate(xpath, contextNode, null, XPathResult.FIRST_ORDERED_NODE_TYPE, null);
  7674. // 应该总是返回一个元素节点
  7675. return result.singleNodeValue && result.singleNodeValue.nodeType === 1 && result.singleNodeValue;
  7676. } catch (err) {
  7677. throw new Error(`无效 Xpath: ${xpath}`);
  7678. }
  7679. }
  7680. function getAllXpath(xpath, contextNode, doc = document) {
  7681. contextNode = contextNode || doc;
  7682. const result = [];
  7683. try {
  7684. const query = doc.evaluate(xpath, contextNode, null, XPathResult.ORDERED_NODE_SNAPSHOT_TYPE, null);
  7685. for (let i = 0; i < query.snapshotLength; i++) {
  7686. const node = query.snapshotItem(i);
  7687. // 如果是 Element 节点
  7688. if (node.nodeType === 1) result.push(node);
  7689. }
  7690. } catch (err) {
  7691. throw new Error(`无效 Xpath: ${xpath}`);
  7692. }
  7693. return result;
  7694. }
  7695. function getOne(selector, contextNode = undefined, doc = document) {
  7696. if (!selector) return;
  7697. contextNode = contextNode || doc;
  7698. if (selector.search(/^css;/i) === 0) {
  7699. return getCSS(selector.slice(4), contextNode);
  7700. } else {
  7701. return getXpath(selector, contextNode, doc);
  7702. }
  7703. }
  7704. function getAll(selector, contextNode = undefined, doc = document) {
  7705. if (!selector) return [];
  7706. contextNode = contextNode || doc;
  7707. if (selector.search(/^css;/i) === 0) {
  7708. return getAllCSS(selector.slice(4), contextNode);
  7709. } else {
  7710. return getAllXpath(selector, contextNode, doc);
  7711. }
  7712. }
  7713. function createDocumentByString(e) {
  7714. if (e) {
  7715. if ('HTML' !== document.documentElement.nodeName) return (new DOMParser).parseFromString(e, 'application/xhtml+xml');
  7716. var t;
  7717. try { t = (new DOMParser).parseFromString(e, 'text/html');} catch (e) {}
  7718. if (t) return t;
  7719. if (document.implementation.createHTMLDocument) {
  7720. t = document.implementation.createHTMLDocument('ADocument');
  7721. } else {
  7722. try {((t = document.cloneNode(!1)).appendChild(t.importNode(document.documentElement, !1)), t.documentElement.appendChild(t.createElement('head')), t.documentElement.appendChild(t.createElement('body')));} catch (e) {}
  7723. }
  7724. if (t) {
  7725. var r = document.createRange(),
  7726. n = r.createContextualFragment(e);
  7727. r.selectNodeContents(document.body);
  7728. t.body.appendChild(n);
  7729. for (var a, o = { TITLE: !0, META: !0, LINK: !0, STYLE: !0, BASE: !0}, i = t.body, s = i.childNodes, c = s.length - 1; c >= 0; c--) o[(a = s[c]).nodeName] && i.removeChild(a);
  7730. return t;
  7731. }
  7732. } else console.error('没有找到要转成 DOM 的字符串');
  7733. }
  7734.  
  7735.  
  7736. // 强制新标签页打开链接(翻页模式 5/6)
  7737. function forceTarget() {
  7738. document.body.addEventListener('click', function(e) {
  7739. if (e.target.tagName === 'A') {
  7740. forceTarget_(e.target, e);
  7741. } else {
  7742. let path = e.path || e.composedPath();
  7743. for (let i = 1; i < path.length - 3; i++) {
  7744. //console.log(path[i])
  7745. if (path[i].tagName === 'A') {
  7746. forceTarget_(path[i], e);
  7747. break;
  7748. }
  7749. }
  7750. }
  7751. });
  7752.  
  7753. function forceTarget_(target, e){
  7754. if (target.href && target.target != '_blank' && !(target.getAttribute('onclick')) && target.href.slice(0,4) == 'http' && target.getAttribute('href').slice(0,1) != '#') {
  7755. e.preventDefault(); // 阻止默认打开链接事件
  7756. //console.log(target.href);
  7757. //window.top.location.href = target.href;
  7758. window.GM_openInTab(target.href, {active: true,insert: true,setParent: true});
  7759. }
  7760. }
  7761. //document.head.appendChild(document.createElement('base')).target = '_top';
  7762. }
  7763. // 判断元素是否隐藏(隐藏返回 true)
  7764. function isHidden(el){
  7765. return (el.offsetParent === null);
  7766. }
  7767. // 判断 URL 是否存在指定文本
  7768. function indexOF(e, l = 'p', low = false){
  7769. switch (l) {
  7770. case 'h':
  7771. l = location.href; break;
  7772. case 'p':
  7773. l = location.pathname; break;
  7774. case 's':
  7775. l = location.search; break;
  7776. }
  7777. //console.log(l,e,l.indexOf(e))
  7778. if (low) {e = e.toLowerCase(); l = l.toLowerCase();} // 全部转为小写
  7779. if (e instanceof RegExp) {
  7780. if (e.test(l)) return true
  7781. } else {
  7782. if (l.indexOf(e) > -1) return true
  7783. }
  7784. return false
  7785. }
  7786. // 获取 Search 指定参数
  7787. function getSearch(variable) {
  7788. let query = window.location.search.substring(1),
  7789. vars = query.split('&');
  7790. for (var i=0;i<vars.length;i++) {
  7791. var pair = vars[i].split('=');
  7792. if(pair[0] == variable){return pair[1];}
  7793. }
  7794. return '';
  7795. }
  7796. // 启用/禁用 (当前网站)
  7797. function menu_disable(type) {
  7798. switch(type) {
  7799. case 'check':
  7800. return check(); break;
  7801. case 'add':
  7802. add(); break;
  7803. case 'del':
  7804. del(); break;
  7805. }
  7806.  
  7807. function check() { // 存在返回真,不存在返回假
  7808. if (GM_getValue('menu_disable').indexOf(location.hostname) == -1) return false // 不存在返回假
  7809. return true
  7810. }
  7811.  
  7812. function add() {
  7813. if (check()) return
  7814. let list = GM_getValue('menu_disable'); // 读取网站列表
  7815. list.push(location.hostname); // 追加网站域名
  7816. GM_setValue('menu_disable', list); // 写入配置
  7817. location.reload(); // 刷新网页
  7818. }
  7819.  
  7820. function del() {
  7821. if (!check()) return
  7822. let list = GM_getValue('menu_disable'), // 读取网站列表
  7823. index = list.indexOf(location.hostname);
  7824. list.splice(index, 1); // 删除网站域名
  7825. GM_setValue('menu_disable', list); // 写入配置
  7826. location.reload(); // 刷新网页
  7827. }
  7828. }
  7829. // 左键双击网页空白处暂停翻页
  7830. function pausePageEvent() {
  7831. if (!GM_getValue('menu_pause_page')) return
  7832. if (curSite.SiteTypeID === 0) return
  7833. if (curSite.pager && curSite.pager.type == 5) window.top.document.xiu_pausePage = pausePage
  7834. document.body.addEventListener('dblclick', function () {
  7835. if (pausePage) {GM_notification({text: `❌ 已暂停本页 [自动无缝翻页]\n (再次双击可恢复)`, timeout: 2000});} else {GM_notification({text: `✅ 已恢复本页 [自动无缝翻页]\n (再次双击可暂停)`, timeout: 2000});}
  7836. pausePage = !pausePage;
  7837. if (curSite.pager && curSite.pager.type == 5) window.top.document.xiu_pausePage = pausePage
  7838. });
  7839. }
  7840. // 显示页码
  7841. function pageNumber(type) {
  7842. if (curSite.SiteTypeID === 0 || curSite.hiddenPN || (curSite.pager && curSite.pager.type == 5 && self != top)) {if (getCSS('#Autopage_number')) {getCSS('#Autopage_number').style.display = 'none';}; return}
  7843. let status = getCSS('#Autopage_number');
  7844. switch (type) {
  7845. case 'add':
  7846. add(); break;
  7847. case 'del':
  7848. del(); break;
  7849. case 'set':
  7850. set(); break;
  7851. }
  7852.  
  7853. function add(){
  7854. if (status) {
  7855. if (status.style.display === 'none') {status.style.display = 'flex';}
  7856. return
  7857. }
  7858. // 插入网页
  7859. let _style = `<style>#Autopage_number {top: calc(75vh) !important;left: 0 !important;width: 32px;height: 32px;padding: 6px !important;display: flex;position: fixed !important;opacity: 0.5;transition: .2s;z-index: 9999 !important;cursor: pointer;user-select: none !important;flex-direction: column;align-items: center;justify-content: center;box-sizing: content-box;border-radius: 0 50% 50% 0;transform-origin: center !important;transform: translateX(-8px);background-color: #eee;-webkit-tap-highlight-color: transparent;box-shadow: 1px 1px 3px 0px #aaa !important;color: #000 !important;font-size: medium;} #Autopage_number:hover {opacity: 0.9;transform: translateX(0);}</style>`,
  7860. _html = `<div id="Autopage_number" title="1. 此处数字为 [当前页码] (可在脚本菜单中关闭)&#10;&#10;2. 鼠标左键点击此处 [临时暂停本页自动无缝翻页](再次点击可恢复)">${pageNum._now}</div>`
  7861. document.documentElement.insertAdjacentHTML('beforeend', _style + _html);
  7862. // 解决 远景论坛 会清理掉前面插入的 CSS 样式的问题
  7863. if (location.hostname === 'bbs.pcbeta.com') {setTimeout(function(){document.documentElement.insertAdjacentHTML('beforeend', _style);}, 500);}
  7864. if (curSite.pager && curSite.pager.type == 5) window.top.document.xiu_pausePage = pausePage
  7865. // 点击事件(临时暂停翻页)
  7866. getCSS('#Autopage_number').onclick = function () {
  7867. if (pausePage) {this.style = 'color: #FF5722 !important; font-style: italic !important;';} else {this.style = '';}
  7868. pausePage = !pausePage;
  7869. if (curSite.pager && curSite.pager.type == 5) window.top.document.xiu_pausePage = pausePage
  7870. };
  7871. status = getCSS('#Autopage_number');
  7872. set();
  7873. }
  7874. // 监听储存当前页码的对象值的变化
  7875. function set(){
  7876. Object.defineProperty(pageNum, 'now', {
  7877. set: function(value) {
  7878. this._now = value;
  7879. if (status) status.textContent = value;
  7880. }
  7881. });
  7882. }
  7883. function del(){
  7884. if (!status) return
  7885. status.style.display = 'none';
  7886. }
  7887. }
  7888. // 菜单开关
  7889. function menu_switch(menu_status, Name, Tips) {
  7890. if (menu_status === true){
  7891. GM_setValue(Name, false);
  7892. } else {
  7893. GM_setValue(Name, true);
  7894. }
  7895. if (Name === 'menu_page_number') {
  7896. if (menu_status === true){pageNumber('del');} else {pageNumber('add');}
  7897. registerMenuCommand(); // 重新注册脚本菜单
  7898. } else {
  7899. location.reload();}
  7900. };
  7901. // 生成 SiteTypeID
  7902. function setSiteTypeID() {
  7903. let num = 0
  7904. for (let val in DBSite) {
  7905. DBSite[val].SiteTypeID = num = num + 1;
  7906. }
  7907. }
  7908. // 获取 Cookie
  7909. function getCookie(name) {
  7910. if (!name) return ''
  7911. let arr = document.cookie.split(';');
  7912. name += '='
  7913. for (let i=0; i<arr.length; i++) {
  7914. let now = arr[i].trim();
  7915. if (now.indexOf(name) == 0) return now.substring(name.length, now.length);
  7916. }
  7917. return '';
  7918. }
  7919. // 插入位置
  7920. function getAddTo(num) {
  7921. switch (num) {
  7922. case 1:
  7923. return 'beforebegin'; break;
  7924. case 2:
  7925. return 'afterbegin'; break;
  7926. case 3:
  7927. case 6:
  7928. return 'beforeend'; break;
  7929. case 4:
  7930. case 5:
  7931. return 'afterend'; break;
  7932. }
  7933. }
  7934. // 滚动条事件
  7935. function windowScroll(fn1) {
  7936. var beforeScrollTop = document.documentElement.scrollTop || document.body.scrollTop,
  7937. fn = fn1 || function () {};
  7938. setTimeout(function () { // 延时 1 秒执行,避免刚载入到页面就触发翻页事件
  7939. window.addEventListener('scroll', function (e) {
  7940. var afterScrollTop = document.documentElement.scrollTop || document.body.scrollTop,
  7941. delta = afterScrollTop - beforeScrollTop;
  7942. if (delta == 0) return false;
  7943. fn(delta > 0 ? 'down' : 'up', e);
  7944. beforeScrollTop = afterScrollTop;
  7945. }, false);
  7946. }, 1000)
  7947. }
  7948. // 自定义 urlchange 事件(用来监听 URL 变化)
  7949. function addUrlChangeEvent() {
  7950. history.pushState = ( f => function pushState(){
  7951. var ret = f.apply(this, arguments);
  7952. window.dispatchEvent(new Event('pushstate'));
  7953. window.dispatchEvent(new Event('urlchange'));
  7954. return ret;
  7955. })(history.pushState);
  7956.  
  7957. history.replaceState = ( f => function replaceState(){
  7958. var ret = f.apply(this, arguments);
  7959. window.dispatchEvent(new Event('replacestate'));
  7960. window.dispatchEvent(new Event('urlchange'));
  7961. return ret;
  7962. })(history.replaceState);
  7963.  
  7964. window.addEventListener('popstate',()=>{
  7965. window.dispatchEvent(new Event('urlchange'))
  7966. });
  7967. }
  7968. })();