自动无缝翻页

无缝拼接下一页内容(瀑布流,追求小而精),目前支持:[所有「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-09 提交的版本,查看 最新版本

  1. // ==UserScript==
  2. // @name 自动无缝翻页
  3. // @name:en AutoPager
  4. // @name:zh-CN 自动无缝翻页
  5. // @name:zh-TW 自動無縫翻頁
  6. // @version 4.6.7
  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: 2000
  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: 1000
  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: 1000
  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 {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: 1000
  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: 1000
  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: 1000
  2027. },
  2028. function: {
  2029. bF: gamersky_gl_bF
  2030. }
  2031. }, // 游民星空 - 攻略
  2032. nexusmods: {
  2033. host: 'www.nexusmods.com',
  2034. history: false,
  2035. pager: {
  2036. type: 1,
  2037. nextL: nexusmods_nextL,
  2038. pageE: 'css;ul.tiles > li',
  2039. replaceE: 'css;.pagination',
  2040. scrollD: 4000
  2041. },
  2042. function: {
  2043. bF: nexusmods_bF
  2044. }
  2045. }, // NexusMods
  2046. curseforge: {
  2047. host: 'www.curseforge.com',
  2048. pager: {
  2049. type: 1,
  2050. nextL: 'css;.pagination-next > a',
  2051. pageE: 'css;div.my-2',
  2052. replaceE: 'css;.pagination',
  2053. scrollD: 2500
  2054. }
  2055. }, // CurseForge
  2056. steamcommunity_workshop: {
  2057. host: 'steamcommunity.com',
  2058. functionS: function() {if (indexOF('/workshop/browse')) {curSite = DBSite.steamcommunity_workshop;} else if (indexOF(/eventcomments\/\d/)) {curSite = DBSite.steamcommunity_eventcomments;}},
  2059. pager: {
  2060. type: 1,
  2061. nextL: '//a[@class="pagebtn" and text()=">"]',
  2062. pageE: 'css;.workshopBrowseItems > *',
  2063. replaceE: 'css;.workshopBrowsePaging',
  2064. scriptT: 2,
  2065. scrollD: 1500
  2066. }
  2067. }, // Steam 创意工坊 - 项目列表
  2068. steamcommunity_eventcomments: {
  2069. style: '.forum_paging_controls {display: none !important;}',
  2070. pager: {
  2071. type: 1,
  2072. nextL: () => getNextUP('ctp=', /ctp=\d+/, location.pathname, '2', getCSS('span.commentthread_pagelinks > a:last-child').textContent),
  2073. pageE: 'css;.commentthread_comments > .commentthread_comment',
  2074. replaceE: 'css;.forum_paging .forum_paging_summary',
  2075. scriptT: 1,
  2076. scrollD: 1500
  2077. }
  2078. }, // Steam 社区 - 活动评论
  2079. yikm: {
  2080. host: 'www.yikm.net',
  2081. pager: {
  2082. type: 1,
  2083. nextL: '//ul[@class="pager"]//a[text()="下一页"]',
  2084. pageE: '//h2[contains(text(), "所有游戏") or contains(text(), "搜索结果")]/following-sibling::div[1]/div',
  2085. replaceE: 'css;ul.pager',
  2086. scrollD: 1500
  2087. }
  2088. }, // 小霸王其乐无穷
  2089. switch520: {
  2090. host: 'switch520.com',
  2091. functionS: function() {if (!indexOF('.html')) {curSite = DBSite.switch520;}},
  2092. pager: {
  2093. type: 1,
  2094. nextL: 'css;a.next',
  2095. pageE: 'css;.row.posts-wrapper > div',
  2096. replaceE: 'css;ul.page-numbers',
  2097. scrollD: 1000
  2098. }
  2099. }, // Switch520
  2100. cs_rin_ru: {
  2101. host: 'cs.rin.ru',
  2102. functionS: function() {if (lp == '/forum/viewforum.php') {
  2103. curSite = DBSite.cs_rin_ru;
  2104. } else if (lp == '/forum/search.php') {
  2105. curSite = DBSite.cs_rin_ru_search;
  2106. if (indexOF('sr=posts', 's')) curSite.pager.pageE = 'css;#wrapcentre > form > table.tablebg > tbody > tr[class^="row"]'
  2107. } else if (lp == '/forum/viewtopic.php' && GM_getValue('menu_thread')) {
  2108. curSite = DBSite.cs_rin_ru_list;
  2109. }},
  2110. pager: {
  2111. type: 1,
  2112. nextL: '//td[@class="gensmall"][@align="right"]//a[text()="Next"]',
  2113. pageE: 'css;#pagecontent > table.tablebg > tbody > tr:not([align])',
  2114. replaceE: 'css;#pagecontent > table:first-child',
  2115. scrollD: 1500
  2116. },
  2117. function: {
  2118. bF: cs_rin_ru_bF
  2119. }
  2120. }, // cs.rin.ru - 各版块帖子列表
  2121. cs_rin_ru_list: {
  2122. pager: {
  2123. type: 1,
  2124. nextL: 'id("pageheader")/p[@class="gensmall"]//a[text()="Next"]',
  2125. pageE: 'css;#pagecontent > table.tablebg:not(:nth-last-child(2)):not(:nth-child(2))',
  2126. replaceE: 'css;#pagecontent >table:not(.tablebg), #pageheader p.gensmall',
  2127. scrollD: 2000
  2128. }
  2129. }, // cs.rin.ru - 帖子内
  2130. cs_rin_ru_search: {
  2131. pager: {
  2132. type: 1,
  2133. nextL: 'id("wrapcentre")/div[@class="nav"]//a[text()="Next"]',
  2134. pageE: 'css;#wrapcentre > form > table.tablebg > tbody > tr[valign]',
  2135. replaceE: 'css;#wrapcentre > div',
  2136. scrollD: 1500
  2137. }
  2138. }, // cs.rin.ru - 搜索页
  2139. crackhub: {
  2140. host: 'crackhub.site',
  2141. style: 'html.wp-dark-mode-active .inside-article {background-color: var(--wp-dark-mode-bg);}',
  2142. pager: {
  2143. type: 1,
  2144. nextL: 'css;a.next.page-numbers',
  2145. pageE: 'css;article[id^="post-"]',
  2146. replaceE: 'css;nav.paging-navigation',
  2147. scrollD: 2000
  2148. }
  2149. }, // Crackhub213
  2150. fitgirl: {
  2151. host: 'fitgirl-repacks.site',
  2152. pager: {
  2153. type: 1,
  2154. nextL: 'css;a.next.page-numbers',
  2155. pageE: 'css;article[id^="post-"]',
  2156. replaceE: 'css;nav.paging-navigation',
  2157. scrollD: 2500
  2158. }
  2159. }, // FitGirl Repacks
  2160. bilibili_search: {
  2161. host: 'search.bilibili.com',
  2162. functionS: function() {
  2163. locationC = true;
  2164. if (lp == '/all' || lp == '/video') {
  2165. curSite = DBSite.bilibili_search;
  2166. } else if (lp == '/article') {
  2167. curSite = DBSite.bilibili_search_article;
  2168. }
  2169. },
  2170. retry: 100,
  2171. pager: {
  2172. type: 1,
  2173. nextL: bilibili_search_nextL,
  2174. pageE: '//ul[contains(@class, "video-list")]/li | //script[contains(text(), "window.__INITIAL_STATE__")]',
  2175. insertP: ['css;ul.video-list', 3],
  2176. replaceE: 'css;ul.pages',
  2177. scriptT: 2,
  2178. scrollD: 1000
  2179. },
  2180. function: {
  2181. bF: bilibili_search_bF,
  2182. aF: bilibili_search_aF
  2183. }
  2184. }, // B 站(Bilibili) - 搜索页 - 视频
  2185. bilibili_search_article: {
  2186. retry: 100,
  2187. pager: {
  2188. type: 1,
  2189. nextL: bilibili_search_nextL,
  2190. pageE: 'css;li.article-item',
  2191. replaceE: 'css;ul.pages',
  2192. //scriptT: 2,
  2193. scrollD: 1000
  2194. }
  2195. }, // B 站(Bilibili) - 搜索页 - 专栏
  2196. cupfox: {
  2197. host: 'www.cupfox.com',
  2198. pager: {
  2199. type: 2,
  2200. nextL: 'css;.load-more',
  2201. nextText: '点击加载更多',
  2202. scrollD: 700
  2203. }
  2204. }, // 茶杯狐
  2205. novipnoad: {
  2206. host: 'www.novipnoad.com',
  2207. functionS: function() {if (location.pathname != '/' && !indexOF('.html')) {curSite = DBSite.novipnoad;}},
  2208. pager: {
  2209. type: 1,
  2210. nextL: 'css;a.nextpostslink',
  2211. pageE: 'css;.video-listing-content .row > div',
  2212. replaceE: 'css;.wp-pagenavi',
  2213. scrollD: 1500
  2214. },
  2215. function: {
  2216. bF: src_bF,
  2217. pF: [0, 'img[data-original]', 'data-original']
  2218. }
  2219. }, // NO视频
  2220. ddrk: {
  2221. host: ['ddrk.me', 'ddys.tv'],
  2222. functionS: function() {if (lp == '/' || indexOF(/\/(category|tag)\//)) {curSite = DBSite.ddrk;}},
  2223. pager: {
  2224. type: 1,
  2225. nextL: 'css;a.next',
  2226. pageE: 'css;.post-box-list > article',
  2227. replaceE: 'css;.pagination_wrap',
  2228. scrollD: 1500
  2229. }
  2230. }, // 低端影视
  2231. nfmovies: {
  2232. host: 'www.nfmovies.com',
  2233. functionS: function() {if (lp == '/search.php' || indexOF('/list/')) {curSite = DBSite.nfmovies;}},
  2234. pager: {
  2235. type: 1,
  2236. nextL: '//ul[contains(@class, "myui-page")]/li/a[text()="下一页"]',
  2237. pageE: 'css;ul.myui-vodlist > li',
  2238. replaceE: 'css;ul.myui-page',
  2239. scrollD: 1500
  2240. },
  2241. function: {
  2242. bF: src_bF,
  2243. pF: [1, 'a[data-original]', 'data-original']
  2244. }
  2245. }, // 奈菲影视
  2246. zxzj: {
  2247. host: ['www.zxzj.me', 'www.zxzj.fun'],
  2248. functionS: function() {if (location.pathname != '/' && !indexOF('/detail/') && !indexOF('/video/')) {curSite = DBSite.zxzj;}},
  2249. style: 'div.stui-page__all {display: none !important;}',
  2250. pager: {
  2251. type: 1,
  2252. nextL: '//ul[contains(@class, "stui-page__item")]//a[text()="下一页"]',
  2253. pageE: 'css;ul.stui-vodlist > li',
  2254. replaceE: 'css;ul.stui-page__item',
  2255. scrollD: 1000
  2256. },
  2257. function: {
  2258. bF: src_bF,
  2259. pF: [1, 'a[data-original]', 'data-original']
  2260. }
  2261. }, // 在线之家
  2262. enlienli: {
  2263. host: 'enlienli.com',
  2264. functionS: function() {if (indexOF('/show/') || indexOF('/search')) {curSite = DBSite.enlienli;}},
  2265. pager: {
  2266. type: 1,
  2267. nextL: 'css;a.page-number.page-next',
  2268. pageE: 'css;.module-items > *',
  2269. replaceE: 'css;#page',
  2270. scrollD: 1000
  2271. },
  2272. function: {
  2273. bF: src_bF,
  2274. pF: [0, 'img[data-src]', 'data-src']
  2275. }
  2276. }, // 嗯哩嗯哩
  2277. mjw91: {
  2278. host: 'mjw91.com',
  2279. functionS: function() {if (!indexOF('/video/') || !indexOF('/vplay/')) {curSite = DBSite.mjw91;}},
  2280. pager: {
  2281. type: 1,
  2282. nextL: 'css;.next-page > a',
  2283. pageE: 'css;.m-movies > article',
  2284. replaceE: 'css;.pagination',
  2285. scrollD: 1500
  2286. },
  2287. function: {
  2288. bF: src_bF,
  2289. pF: [0, 'img[data-original]', 'data-original']
  2290. }
  2291. }, // 91 美剧网
  2292. zhenbuka: {
  2293. host: ['www.zhenbuka3.com', 'www.zhenbuka5.com'],
  2294. functionS: function() {if (indexOF('/vodtype/')) {curSite = DBSite.zhenbuka;}},
  2295. pager: {
  2296. type: 1,
  2297. nextL: '//ul[contains(@class, "stui-page")]/li/a[text()="下一页"]',
  2298. pageE: 'css;ul.stui-vodlist > li',
  2299. replaceE: 'css;ul.stui-page',
  2300. scrollD: 1500
  2301. },
  2302. function: {
  2303. bF: src_bF,
  2304. pF: [1, 'a[data-original]', 'data-original']
  2305. }
  2306. }, // 真不卡影院
  2307. zzzfun: {
  2308. host: 'www.zzzfun.com',
  2309. functionS: function() {
  2310. if (indexOF('/vod_type') || indexOF('/vod_show')) {
  2311. curSite = DBSite.zzzfun;
  2312. } else if (indexOF('/vod_search')) {
  2313. curSite = DBSite.zzzfun_search;
  2314. }},
  2315. pager: {
  2316. type: 1,
  2317. nextL: 'css;#page a[title="下一页"]',
  2318. pageE: 'css;ul.search-result > a',
  2319. replaceE: 'css;#page',
  2320. scrollD: 1000
  2321. },
  2322. function: {
  2323. bF: src_bF,
  2324. pF: [0, 'img[data-original]', 'data-original']
  2325. }
  2326. }, // ZzzFun 动漫
  2327. zzzfun_search: {
  2328. pager: {
  2329. type: 1,
  2330. nextL: 'css;#page a[title="下一页"]',
  2331. pageE: 'css;ul.show-list > li',
  2332. replaceE: 'css;#page',
  2333. scrollD: 1000
  2334. },
  2335. function: {
  2336. bF: src_bF,
  2337. pF: [0, 'img[data-original]', 'data-original']
  2338. }
  2339. }, // ZzzFun 动漫 - 搜索页
  2340. tucao: {
  2341. host: 'www.tucao.one',
  2342. functionS: function() {if (indexOF('/list/')) {
  2343. curSite = DBSite.tucao;
  2344. } else if (indexOF('search', 's')) {
  2345. curSite = DBSite.tucao_search;
  2346. }},
  2347. pager: {
  2348. type: 1,
  2349. nextL: 'css;.pagego a',
  2350. pageE: 'css;.list > ul > li',
  2351. replaceE: 'css;.newpages, .pagego, #float_show',
  2352. scrollD: 1000
  2353. }
  2354. }, // 吐槽弹幕网
  2355. tucao_search: {
  2356. pager: {
  2357. type: 1,
  2358. nextL: '//a[@class="a1"][contains(text(), "下一页")]',
  2359. pageE: 'css;.search_list > *',
  2360. replaceE: 'css;.pages',
  2361. scrollD: 1000
  2362. }
  2363. }, // 吐槽弹幕网 - 搜索页
  2364. mandao: {
  2365. host: 'www.mandao.tv',
  2366. functionS: function() {if (location.pathname != '/' && !indexOF('/man')) {
  2367. curSite = DBSite.mandao;
  2368. }},
  2369. pager: {
  2370. type: 1,
  2371. nextL: '//div[contains(@class, "page")]/a[text()=">"]',
  2372. pageE: 'css;.index-tj > ul > li',
  2373. replaceE: 'css;.page',
  2374. scrollD: 1000
  2375. },
  2376. function: {
  2377. bF: src_bF,
  2378. pF: [0, 'img[data-original]', 'data-original']
  2379. }
  2380. }, // 漫岛动漫
  2381. yxdm: {
  2382. host: 'www.yxdm.li',
  2383. functionS: function() {if (indexOF('/search') || indexOF('/category') || indexOF('/resource')) {curSite = DBSite.yxdm;}},
  2384. pager: {
  2385. type: 1,
  2386. nextL: '//a[@class="nextPage" or text()="下一页"]',
  2387. pageE: 'css;.dhnew > ul > li',
  2388. replaceE: 'css;.pagelist',
  2389. scrollD: 2000
  2390. }
  2391. }, // 怡萱动漫
  2392. nicotv: {
  2393. host: 'www.nicotv.me',
  2394. functionS: function() {if (indexOF('/search') || indexOF('/type')) {curSite = DBSite.nicotv;}},
  2395. pager: {
  2396. type: 1,
  2397. nextL: '//ul[contains(@class, "pagination ")]//a[text()="»"]',
  2398. pageE: 'css;ul.list-unstyled > li',
  2399. replaceE: 'css;ul.pagination ',
  2400. scrollD: 1000
  2401. },
  2402. function: {
  2403. bF: src_bF,
  2404. pF: [0, 'img[data-original]', 'data-original']
  2405. }
  2406. }, // 妮可动漫
  2407. yhdm: {
  2408. host: ['www.imomoe.la', 'www.imomoe.live'],
  2409. functionS: function() {if (indexOF('/list/')) {
  2410. curSite = DBSite.yhdm;
  2411. } else if (lp == '/so.asp' || lp == '/search.asp') {
  2412. curSite = DBSite.yhdm_;
  2413. }},
  2414. pager: {
  2415. type: 1,
  2416. nextL: '//div[@class="pages"]/a[text()="下一页"]',
  2417. pageE: 'css;#contrainer > .img> ul > li',
  2418. replaceE: 'css;.pages',
  2419. scrollD: 1000
  2420. }
  2421. }, // 樱花动漫
  2422. yhdm_: {
  2423. pager: {
  2424. type: 1,
  2425. nextL: '//div[@class="pages"]/a[text()="下一页"]',
  2426. pageE: 'css;#contrainer .fire .pics > ul > li',
  2427. replaceE: 'css;.pages',
  2428. scrollD: 1000
  2429. }
  2430. }, // 樱花动漫 - 搜索页等
  2431. agefans: {
  2432. host: ['www.agemys.com', 'www.age.tv'],
  2433. functionS: function() {if (indexOF('/catalog/') || lp == '/search') {
  2434. curSite = DBSite.agefans;
  2435. } else if (lp == '/recommend' || lp == '/update') {
  2436. curSite = DBSite.agefans_;
  2437. } else if (lp == '/rank') {
  2438. curSite = DBSite.agefans_rank;
  2439. }},
  2440. pager: {
  2441. type: 1,
  2442. nextL: 'id("container")//div[@class="blockcontent"]/div[@style][not(@class)]/li/a[contains(text(), "下一页")]',
  2443. pageE: 'css;#container .blockcontent1 > div',
  2444. replaceE: 'css;#container .blockcontent > div[style]:not([class])',
  2445. scrollD: 1000
  2446. }
  2447. }, // AGE 动漫 - 全部/搜索
  2448. agefans_: {
  2449. pager: {
  2450. type: 1,
  2451. nextL: 'id("container")//div[@class="blockcontent"]/div[@style][not(@class)]/li/a[contains(text(), "下一页")]',
  2452. pageE: 'css;#container .blockcontent > ul > li',
  2453. replaceE: 'css;#container .blockcontent > div[style]:not([class])',
  2454. scrollD: 1000
  2455. }
  2456. }, // AGE 动漫 - 其他页
  2457. agefans_rank: {
  2458. pager: {
  2459. type: 1,
  2460. nextL: 'id("container")/ul[@style][not(@class)]/li/a[contains(text(), "下一页")]',
  2461. pageE: 'css;#container > .div_right .blockcontent.div_right_r_3 > ul',
  2462. replaceE: 'css;#container > ul[style]:not([class])',
  2463. scrollD: 1000
  2464. }
  2465. }, // AGE 动漫 - 排行榜
  2466. dm233: {
  2467. host: 'www.dm233.cc',
  2468. functionS: function() {if (indexOF('/catalog/') || lp == '/recommend/' || lp == '/search') {
  2469. curSite = DBSite.dm233;
  2470. } else if (lp == '/article/') {
  2471. curSite = DBSite.dm233_article;
  2472. } else if (lp == '/rank/') {
  2473. curSite = DBSite.dm233_rank;
  2474. }},
  2475. pager: {
  2476. type: 1,
  2477. nextL: '//div[@class="pagelist"]//a[contains(text(), "下一页") or contains(text(), "下一頁")]',
  2478. pageE: 'css;.dhnew ul > li',
  2479. replaceE: 'css;.pagelist',
  2480. scrollD: 1000
  2481. }
  2482. }, // 233 动漫
  2483. dm233_article: {
  2484. pager: {
  2485. type: 1,
  2486. nextL: '//div[@class="pagelist"]//a[contains(text(), "下一页") or contains(text(), "下一頁")]',
  2487. pageE: 'css;.xgyd ul > li',
  2488. replaceE: 'css;.pagelist',
  2489. scrollD: 1000
  2490. }
  2491. }, // 233 动漫 - 动漫情报/资讯
  2492. dm233_rank: {
  2493. pager: {
  2494. type: 1,
  2495. nextL: '//div[@class="pagelist"]//a[contains(text(), "下一页") or contains(text(), "下一頁")]',
  2496. pageE: 'css;.side-update.normal-wai > .normal-nei',
  2497. replaceE: 'css;.pagelist',
  2498. scrollD: 1000
  2499. }
  2500. }, // 233 动漫 - 排行榜
  2501. anime1: {
  2502. host: 'anime1.me',
  2503. functionS: function() {if (indexOF('s=', 's')) {
  2504. curSite = DBSite.anime1_search;
  2505. } else if (lp == '/') {
  2506. curSite = DBSite.anime1;
  2507. }},
  2508. history: false,
  2509. pager: {
  2510. type: 4,
  2511. nextL: anime1_nextL,
  2512. interval: 500,
  2513. scrollD: 800
  2514. }
  2515. }, // Anime1
  2516. anime1_search: {
  2517. pager: {
  2518. type: 1,
  2519. nextL: 'css;.nav-previous > a',
  2520. pageE: 'css;#main > article',
  2521. replaceE: 'css;nav.navigation',
  2522. scrollD: 1200
  2523. }
  2524. }, // Anime1 - 搜索页
  2525. yinfans: {
  2526. host: /www\.yinfans\./,
  2527. style: '#post_container {height: auto !important;} #post_container > li {position: static !important; float: left !important; height: 620px !important;}',
  2528. pager: {
  2529. type: 1,
  2530. nextL: 'css;a.next',
  2531. pageE: 'css;#post_container > li',
  2532. replaceE: 'css;.pagination',
  2533. scrollD: 1500
  2534. }
  2535. }, // 音范丝
  2536. btbtt: {
  2537. host: /btbtt/,
  2538. pager: {
  2539. type: 1,
  2540. nextL: '//div[@class="page"]/a[contains(text(), "▶") or contains(text(), "下一页")]',
  2541. pageE: 'css;#threadlist > *',
  2542. replaceE: 'css;.page',
  2543. scrollD: 2000
  2544. }
  2545. }, // BT 之家
  2546. bdys: {
  2547. host: 'www.bd2020.com',
  2548. functionS: function() {if (location.pathname != '/' && !indexOF(/\/\d+\.htm/)) {curSite = DBSite.bdys;}},
  2549. pager: {
  2550. type: 2,
  2551. nextL: 'css;div.layui-flow-more > a',
  2552. nextText: '加载更多',
  2553. scrollD: 1000
  2554. }
  2555. }, // BD 影视
  2556. gaoqing_fm: {
  2557. host: 'gaoqing.fm',
  2558. pager: {
  2559. type: 2,
  2560. nextL: 'css;.col-md-12 > a, #loadmore > a',
  2561. interval: 1500,
  2562. scrollD: 1000
  2563. }
  2564. }, // 高清电台
  2565. yyds: {
  2566. host: 'yyds.fans',
  2567. functionS: function() {if (location.search != '' && !indexOF('p=', 's')) {curSite = DBSite.yyds;}},
  2568. pager: {
  2569. type: 1,
  2570. nextL: 'css;a.next.page-numbers',
  2571. pageE: 'css;.list-grouped > div',
  2572. replaceE: 'css;nav.pagination',
  2573. scrollD: 1100
  2574. }
  2575. }, // YYDS 电影
  2576. kisssub: {
  2577. host: ['www.kisssub.org','www.comicat.org', /(share|www)\.acgnx\./],
  2578. pager: {
  2579. type: 1,
  2580. nextL: 'css;a.nextprev:last-of-type',
  2581. pageE: 'css;#data_list > tr',
  2582. replaceE: 'css;.pages',
  2583. scrollD: 2500
  2584. }
  2585. }, // 爱恋动漫 / 漫猫动漫 / 末日动漫
  2586. dmhy: {
  2587. host: ['share.dmhy.org', 'dmhy.anoneko.com'],
  2588. pager: {
  2589. type: 1,
  2590. nextL: '//div[@class="nav_title"]/a[contains(text(), "下一")]',
  2591. pageE: 'css;#topic_list > tbody > tr',
  2592. replaceE: 'css;.nav_title',
  2593. scrollD: 1500
  2594. },
  2595. function: {
  2596. 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');`;}
  2597. }
  2598. }, // 动漫花园
  2599. futaacg: {
  2600. host: /futaacg\./,
  2601. pager: {
  2602. type: 1,
  2603. nextL: 'css;ul.pagination a[rel="next"]',
  2604. pageE: 'css;.topic-list > div',
  2605. replaceE: 'css;ul.pagination',
  2606. scrollD: 1500
  2607. }
  2608. }, // 扶她动漫
  2609. acg_rip: {
  2610. host: 'acg.rip',
  2611. pager: {
  2612. type: 1,
  2613. nextL: 'css;li.next>a',
  2614. pageE: 'css;table.post-index > tbody > tr',
  2615. replaceE: 'css;ul.pagination',
  2616. scrollD: 1500
  2617. }
  2618. }, // ACG.RIP
  2619. bangumi: {
  2620. host: 'bangumi.moe',
  2621. functionS: function() {if (indexOF('/lite')) {curSite = DBSite.bangumi_lite;} else {curSite = DBSite.bangumi;}},
  2622. pager: {
  2623. type: 2,
  2624. nextL: 'css;[torrent-list="lattorrents"] button[ng-click="loadMore()"] ,[torrent-list="torrents"] button[ng-click="loadMore()"]',
  2625. interval: 1000,
  2626. scrollD: 1500
  2627. }
  2628. }, // 萌番组
  2629. bangumi_lite: {
  2630. pager: {
  2631. type: 1,
  2632. nextL: '//section/a[./span[contains(@class, "next")]]',
  2633. pageE: 'css;li.torrent-li',
  2634. replaceE: 'css;.page-btn-section',
  2635. scrollD: 2000
  2636. }
  2637. }, // 萌番组 lite
  2638. miobt: {
  2639. host: ['miobt.com', 'www.36dm.club'],
  2640. functionS: function() {curSite = DBSite.miobt; if (location.hostname === 'www.36dm.club') {curSite.pager.scrollD = 1000;}},
  2641. pager: {
  2642. type: 1,
  2643. nextL: '//a[@class="nextprev"][contains(text(), "〉") or contains(text(), "下一页") or contains(text(), "»")]',
  2644. pageE: 'css;#data_list > tr',
  2645. replaceE: 'css;.pages',
  2646. scrollD: 2000
  2647. }
  2648. }, // MioBT + 简单动漫
  2649. reimu: {
  2650. host: /\.reimu\./,
  2651. functionS: function() {if (lp == '/' || indexOF('/category') || indexOF('/tag')) curSite = DBSite.reimu},
  2652. pager: {
  2653. type: 1,
  2654. nextL: 'css;span.current+a.sfwppa-current-page',
  2655. pageE: 'css;article[id^="post-"]',
  2656. replaceE: 'css;.wp-pagenavi',
  2657. scrollD: 1500
  2658. }
  2659. }, // REIMU
  2660. hacg: {
  2661. host: /\.hacg\./,
  2662. functionS: function() {if (indexOF('/wp/') && !indexOF(/\d+\.html/)) curSite = DBSite.hacg},
  2663. pager: {
  2664. type: 1,
  2665. nextL: 'css;a.nextpostslink',
  2666. pageE: 'css;article[id^="post-"]',
  2667. replaceE: 'css;.wp-pagenavi',
  2668. scrollD: 1500
  2669. }
  2670. }, // HACG
  2671. nyaa: {
  2672. host: /nyaa\.si/,
  2673. pager: {
  2674. type: 1,
  2675. nextL: 'css;a[rel="next"], li.next > a',
  2676. pageE: 'css;table.torrent-list > tbody > tr',
  2677. replaceE: 'css;ul.pagination',
  2678. scrollD: 2000
  2679. }
  2680. }, // Nyaa
  2681. skrbt: {
  2682. host: /skrbt/,
  2683. functionS: function() {if (lp == '/search') curSite = DBSite.skrbt;},
  2684. pager: {
  2685. type: 1,
  2686. nextL: skrbt_nextL,
  2687. pageE: 'css;div[class="row"] > .col-md-6 > ul',
  2688. insertP: ['css;nav[aria-label*="Page"]', 1],
  2689. replaceE: 'css;ul.pagination',
  2690. scrollD: 900
  2691. }
  2692. }, // SkrBT
  2693. _1337x: {
  2694. host: /1337x\./,
  2695. functionS: function() {if (indexOF('search/')) {curSite = DBSite._1337x;}},
  2696. pager: {
  2697. type: 1,
  2698. nextL: '//div[@class="pagination"]//a[text()=">>"]',
  2699. pageE: 'css;table.table-list > tbody > tr',
  2700. replaceE: 'css;.pagination',
  2701. scrollD: 1200
  2702. }
  2703. }, // 1337x
  2704. rarbg: {
  2705. host: /rarbg/,
  2706. functionS: function() {if (lp == '/torrents.php') {curSite = DBSite.rarbg; rarbg_bF(getAllCSS('table.lista2t tr.lista2'));}},
  2707. style: 'html::-webkit-scrollbar {height: 0 !important;}',
  2708. pager: {
  2709. type: 1,
  2710. nextL: 'css;#pager_links > a[title="next page"]',
  2711. pageE: 'css;table.lista2t tr.lista2',
  2712. replaceE: 'css;#pager_links',
  2713. scrollD: 1200
  2714. },
  2715. function: {
  2716. bF: rarbg_bF
  2717. }
  2718. }, // RARBG
  2719. /*thepiratebay: {
  2720. host: 'thepiratebay.org',
  2721. functionS: function() {if (lp == '/search.php') {curSite = DBSite.thepiratebay;}},
  2722. pager: {
  2723. type: 6,
  2724. nextL: 'css;center > b+a[href]',
  2725. pageE: 'css;ol#torrents > li[id]',
  2726. replaceE: 'css;center',
  2727. loadTime: 1000,
  2728. scrollD: 1500
  2729. }
  2730. },*/ // thepiratebay
  2731. subdh: {
  2732. host: 'subdh.com',
  2733. functionS: function() {if (lp == '/' || indexOF('/list/new')) {curSite = DBSite.subdh;} else if (indexOF('/search')) {curSite = DBSite.subdh_search;}},
  2734. pager: {
  2735. type: 1,
  2736. nextL: '//a[@class="page-link"][contains(text(), "下一页")]',
  2737. pageE: 'css;.col-lg-9 .bg-white.shadow-sm.rounded-3 > .row.gx-0',
  2738. replaceE: 'css;ul.pagination',
  2739. scrollD: 1000
  2740. }
  2741. }, // SubDH
  2742. subdh_search: {
  2743. pager: {
  2744. type: 1,
  2745. nextL: '//a[@class="page-link"][contains(text(), "下一页")]',
  2746. pageE: 'css;.col-lg-9 .bg-white.shadow-sm.rounded-3',
  2747. insertP: ['css;nav[aria-label="pagination"]', 1],
  2748. replaceE: 'css;ul.pagination',
  2749. scrollD: 1000
  2750. }
  2751. }, // SubDH - 搜索页
  2752. mini4k: {
  2753. host: 'www.mini4k.com',
  2754. functionS: function() {if (location.pathname != '/' && !indexOF(/\/\d{3,}/)) {curSite = DBSite.mini4k;};},
  2755. pager: {
  2756. type: 1,
  2757. nextL: 'css;a.pager__item--next',
  2758. pageE: 'css;div[class*="-item-list"] > ul > li',
  2759. replaceE: 'css;.pagination',
  2760. scrollD: 2000
  2761. }
  2762. }, // MINI4K
  2763. bthaha: {
  2764. host: /bthaha/,
  2765. functionS: function() {if (indexOF('/search/')) {
  2766. curSite = DBSite.bthaha;
  2767. getAllCSS('[id^="list_top"], [id^="list_bottom"]').forEach(function (one) {one.parentElement.parentElement.hidden = true;});
  2768. }},
  2769. style: '[id^="list_top"], [id^="list_bottom"] {display: none !important;}',
  2770. pager: {
  2771. type: 1,
  2772. nextL: '//ul[@class="pagination"]/li/a[contains(text(), "下一页")]',
  2773. pageE: 'css;table.table > tbody > tr',
  2774. replaceE: 'css;ul.pagination',
  2775. scrollD: 1000
  2776. },
  2777. function: {
  2778. bF: bthaha_bF
  2779. }
  2780. }, // BTHaha
  2781. a4k: {
  2782. host: 'www.a4k.net',
  2783. functionS: function() {if (!indexOF('/subtitle/')) {curSite = DBSite.a4k;};},
  2784. pager: {
  2785. type: 1,
  2786. nextL: 'css;a.pager__item--next',
  2787. pageE: 'css;ul.list > li',
  2788. replaceE: 'css;.pagination',
  2789. scrollD: 1000
  2790. }
  2791. }, // A4k 字幕网(字幕)
  2792. assrt: {
  2793. host: 'assrt.net',
  2794. functionS: function() {if (location.pathname === '/sub/') {curSite = DBSite.assrt;} else if (indexOF('/list/')) {curSite = DBSite.assrt_list;}},
  2795. pager: {
  2796. type: 1,
  2797. nextL: () => getNextEP('css;#pl-current+a[href]:not([id])', 'page=', /page=\d+/),
  2798. pageE: 'css;.resultcard > div:not(#top-banner):not(#bottom-banner):not(.pagelinkcard)',
  2799. insertP: ['css;.pagelinkcard', 1],
  2800. replaceE: 'css;.pagelinkcard',
  2801. scrollD: 1000
  2802. }
  2803. }, // 射手网(字幕)
  2804. assrt_list: {
  2805. pager: {
  2806. type: 1,
  2807. nextL: '//a[@id="pl-nav" and text()=">"]',
  2808. pageE: 'css;#resultsdiv > .subitem:not([id])',
  2809. replaceE: 'css;.pagelinkcard',
  2810. scrollD: 1000
  2811. }
  2812. }, // 射手网(字幕)
  2813. subhd: {
  2814. host: 'subhd.tv',
  2815. functionS: function() {if (lp == '/forum/forum') {
  2816. curSite = DBSite.subhd_forum;
  2817. } else if (location.pathname != '/' && location.pathname != '/zu' && !indexOF('/a/') && !indexOF('/d/') && !indexOF('/forum/')) {
  2818. curSite = DBSite.subhd;
  2819. }},
  2820. pager: {
  2821. type: 1,
  2822. nextL: '//a[@class="page-link"][contains(text(), "下一页")]',
  2823. pageE: 'css;.bg-white.shadow-sm.rounded-3',
  2824. insertP: ['css;nav.clearfix', 1],
  2825. replaceE: 'css;nav.clearfix',
  2826. scrollD: 1000
  2827. }
  2828. }, // SubHD(字幕)
  2829. subhd_forum: {
  2830. pager: {
  2831. type: 1,
  2832. nextL: '//a[@class="page-link"][contains(text(), "下一页")]',
  2833. pageE: 'css;.bg-white.shadow-sm.rounded-3 > div',
  2834. replaceE: 'css;nav.clearfix',
  2835. scrollD: 800
  2836. }
  2837. }, // SubHD - forum(字幕)
  2838. manben: {
  2839. host: 'www.manben.com',
  2840. functionS: function() {if (indexOF(/\/m\d+/)) {
  2841. if (getCookie('showtype') != '2') {
  2842. document.cookie='showtype=2; expires=Thu, 18 Dec 2031 12:00:00 GMT; path=/'; // 写入 Cookie 开启 [垂直阅读] 模式
  2843. location.reload(); // 刷新网页
  2844. }
  2845. curSite = DBSite.mhxqiu;
  2846. }}
  2847. }, // 漫本
  2848. haoman: {
  2849. host: ['www.haoman6.com', 'www.g-lens.com'],
  2850. functionS: function() {
  2851. if (indexOF('/chapter/')) {
  2852. curSite = DBSite.haoman;
  2853. if (location.hostname == 'www.g-lens.com') curSite.function.pF = [0, 'img[data-echo]', 'data-echo']
  2854. } else if (indexOF('/comic/')) {
  2855. if (getCSS('.chapter__more')) getCSS('.chapter__more').click();
  2856. } else if (indexOF('/category/') || indexOF('/search')) {
  2857. curSite = DBSite.haoman_list;
  2858. }},
  2859. 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;}',
  2860. pager: {
  2861. type: 1,
  2862. nextL: function() {if (getCSS('a.rd-aside__item.j-rd-next')) return location.origin + getCSS('a.rd-aside__item.j-rd-next').getAttribute('_href')},
  2863. pageE: 'css;.rd-article-wr > div',
  2864. replaceE: 'css;a.last-crumb, .rd-aside',
  2865. interval: 2000,
  2866. scrollD: 2000
  2867. },
  2868. function: {
  2869. bF: src_bF,
  2870. pF: [0, 'img[dta-echo]', 'dta-echo']
  2871. }
  2872. }, // 好漫 6
  2873. haoman_list: {
  2874. pager: {
  2875. type: 1,
  2876. nextL: 'css;a.next',
  2877. pageE: 'css;.cate-comic-list > div',
  2878. replaceE: 'css;#Pagination',
  2879. scrollD: 1000
  2880. },
  2881. function: {
  2882. bF: src_bF,
  2883. pF: [0, 'img[data-original]', 'data-original']
  2884. }
  2885. }, // 好漫 6 - 分类/搜索页
  2886. cartoonmad: {
  2887. host: ['www.cartoonmad.com','www.cartoonmad.cc'],
  2888. functionS: function() {if (indexOF('/comic/')) {
  2889. getCSS('body > table > tbody > tr:nth-child(4) > td > table > tbody > tr:first-child > td:first-child > a').href = 'javascript:void(0);'; // 清理图片上的链接
  2890. curSite = DBSite.cartoonmad;
  2891. } else if (location.pathname != '/') {
  2892. curSite = DBSite.cartoonmad_list;
  2893. }},
  2894. 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;}',
  2895. pager: {
  2896. type: 1,
  2897. nextL: cartoonmad_nextL,
  2898. pageE: 'css;body > table > tbody > tr:nth-child(4) > td > table > tbody > tr:first-child > td:first-child img',
  2899. replaceE: 'css;body > table > tbody > tr:nth-child(2), body > table > tbody > tr:nth-child(5)',
  2900. scrollD: 2000
  2901. }
  2902. }, // 动漫狂
  2903. cartoonmad_list: {
  2904. pager: {
  2905. type: 1,
  2906. nextL: '//a[@class="pages"][contains(text(), "下一頁")]',
  2907. pageE: 'css;td[background="/image/content_box4.gif"]+td > table > tbody > tr',
  2908. replaceE: '//a[@class="pages"]/parent::td/parent::tr | //font[contains(text(), "目前在第")]',
  2909. scrollD: 1000
  2910. }
  2911. }, // 动漫狂 - 分类/搜索页
  2912. dongman: {
  2913. host: 'www.dongman.la',
  2914. functionS: function() {if (indexOF('/chapter/')) {
  2915. src_bF(getAllCSS('img.mdui-img-fluid[data-srcset]:not([src])'), [0, 'img[data-srcset]', 'data-srcset']);
  2916. curSite = DBSite.dongman;
  2917. } else if (indexOF('/detail/')) {
  2918. setTimeout(function(){getCSS('a#zhankai').click()}, 500)
  2919. } else if (indexOF('/manhua/')) {
  2920. curSite = DBSite.dongman_list;
  2921. }},
  2922. 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;}',
  2923. pager: {
  2924. type: 1,
  2925. nextL: '//footer//a[./label[text()="下一章"]]',
  2926. pageE: 'css;.lazyBox',
  2927. insertP: ['css;.slick-track', 3],
  2928. replaceE: 'css;footer',
  2929. scrollD: 3000
  2930. },
  2931. function: {
  2932. bF: src_bF,
  2933. pF: [0, 'img[data-srcset]', 'data-srcset']
  2934. }
  2935. }, // 动漫啦
  2936. dongman_list: {
  2937. pager: {
  2938. type: 1,
  2939. nextL: '//a[@class="GPageLink" and text()="下一页"]',
  2940. pageE: 'css;.cy_list_mh > ul',
  2941. replaceE: 'css;.NewPages',
  2942. scrollD: 2000
  2943. }
  2944. }, // 动漫啦 - 分类页
  2945. manhuacat: {
  2946. host: ['www.manhuacat.com', 'www.maofly.com'],
  2947. functionS: function() {if (indexOF(/\/manga\/\d+\/.+\.html/)) {
  2948. if (getCookie('is_pull') == 'true') { // 强制关闭 [下拉] 模式
  2949. document.cookie='is_pull=false; expires=Thu, 18 Dec 2031 12:00:00 GMT; path=/'; // 写入 Cookie 关闭 [下拉] 模式
  2950. location.reload(); // 刷新网页
  2951. }
  2952. setTimeout(manhuacat_init, 100);
  2953. curSite = DBSite.manhuacat;
  2954. } else if (indexOF('/list')) {
  2955. curSite = DBSite.manhuacat_list;
  2956. } else if (indexOF('/search') || indexOF('/update')) {
  2957. curSite = DBSite.manhuacat_search;
  2958. }},
  2959. 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;}', // 隐藏不需要的元素,调整图片
  2960. pager: {
  2961. type: 4,
  2962. nextL: manhuacat_nextL,
  2963. insertP: ['css;.img-content', 3],
  2964. insertE: manhuacat_insertE,
  2965. replaceE: 'css;.comic-detail > .breadcrumb-bar, .comic-detail >h2.h4, .vg-r-data, body > script:not([src])',
  2966. interval: 2000,
  2967. scrollD: 3000
  2968. }
  2969. }, // 漫画猫
  2970. manhuacat_list: {
  2971. pager: {
  2972. type: 1,
  2973. nextL: '//div[contains(@class, "pagination")]//a[contains(text(), "下一页") or contains(text(), "下页")]',
  2974. pageE: 'css;.comic-main-section > *',
  2975. replaceE: 'css;.pagination',
  2976. scrollD: 1000
  2977. },
  2978. function: {
  2979. bF: src_bF,
  2980. pF: [0, 'img[data-original]', 'data-original']
  2981. }
  2982. }, // 漫画猫 - 分类页
  2983. manhuacat_search: {
  2984. pager: {
  2985. type: 1,
  2986. nextL: '//div[contains(@class, "pagination")]//a[contains(text(), "下一页") or contains(text(), "下页")]',
  2987. pageE: 'css;.comic-main-section .row > div',
  2988. replaceE: 'css;.pagination',
  2989. scrollD: 1000
  2990. }
  2991. }, // 漫画猫 - 搜索页
  2992. manhuatai: {
  2993. host: 'www.manhuatai.net',
  2994. functionS: function() {if (indexOF('/manhua/')) {
  2995. curSite = DBSite.manhuatai;
  2996. } else if (indexOF('/fenlei_') || indexOF('/top_')) {
  2997. curSite = DBSite.manhuatai_list;
  2998. } else if (indexOF('/search')) {
  2999. curSite = DBSite.manhuatai_search;
  3000. }},
  3001. pager: {
  3002. type: 1,
  3003. nextL: '//div[contains(@class, "page")]//a[@href][contains(text(), "下一页") or contains(text(), "下一章")]',
  3004. pageE: 'css;#htmlContent p.img > img',
  3005. replaceE: 'css;.page, .title',
  3006. scrollD: 2000
  3007. }
  3008. }, // 漫画台
  3009. manhuatai_list: {
  3010. pager: {
  3011. type: 1,
  3012. nextL: 'css;#pagelink a.next',
  3013. pageE: 'css;.article-list',
  3014. replaceE: 'css;#pagelink',
  3015. scrollD: 1500
  3016. }
  3017. }, // 漫画台 - 分类页
  3018. manhuatai_search: {
  3019. pager: {
  3020. type: 1,
  3021. nextL: 'css;#pagelink a.next',
  3022. pageE: 'css;#content > table > tbody > tr:not([align])',
  3023. replaceE: 'css;#pagelink',
  3024. scrollD: 1500
  3025. }
  3026. }, // 漫画台 - 搜索页
  3027. manhuapi: {
  3028. host: 'www.manhuapi.com',
  3029. functionS: function() {if (indexOF('/chapter/')) {
  3030. curSite = DBSite.manhuapi;
  3031. } else if (!indexOF(/\/manhua\/\d+\.html/)) {
  3032. curSite = DBSite.manhuapi_list;
  3033. }},
  3034. pager: {
  3035. type: 1,
  3036. nextL: '//div[@class="page"]/a[text()="下一页" or text()="下一章"]',
  3037. pageE: 'css;.mh_list img[src]',
  3038. replaceE: 'css;.page',
  3039. scrollD: 2000
  3040. }
  3041. }, // 漫画皮
  3042. manhuapi_list: {
  3043. pager: {
  3044. type: 1,
  3045. nextL: '//div[@class="pages"]/a[text()="下一页"]',
  3046. pageE: 'css;.cy_list_mh > ul',
  3047. replaceE: 'css;.pages',
  3048. scrollD: 1500
  3049. }
  3050. }, // 漫画皮 - 分类页
  3051. imanhuaw: {
  3052. host: ['www.imanhuaw.net', 'www.imanhuaw.com'],
  3053. functionS: function() {
  3054. if (getCSS('.mh-search-result')) {
  3055. curSite = DBSite.imanhuaw_list;
  3056. } else if (getCSS('a#zhankai')) {
  3057. getCSS('a#zhankai').click();
  3058. } else if (indexOF(/\/imanhua\/.+\/\d{3,}\.html/)) {
  3059. curSite = DBSite.imanhuaw; imanhuaw_init();
  3060. }
  3061. },
  3062. style: '#sider-left, #sider-right, .main-left, .main-right, .w996.tc, .title > span {display: none !important;}',
  3063. pager: {
  3064. type: 4,
  3065. nextL: imanhuaw_nextL,
  3066. insertP: ['css;#qTcms_Pic_middle img:last-of-type', 4],
  3067. insertE: imanhuaw_insertE,
  3068. replaceE: 'css;.title h2',
  3069. interval: 2000,
  3070. scrollD: 3000
  3071. }
  3072. }, // 爱漫画
  3073. imanhuaw_list: {
  3074. pager: {
  3075. type: 1,
  3076. nextL: '//div[@class="NewPages"]//a[text()="下一页"]',
  3077. pageE: 'css;ul.mh-search-list > li',
  3078. replaceE: 'css;.NewPages',
  3079. scrollD: 1500
  3080. }
  3081. }, // 爱漫画 - 分类页
  3082. manhuagui: {
  3083. host: ['www.mhgui.com', 'tw.mhgui.com', 'www.manhuagui.com', 'tw.manhuagui.com'],
  3084. functionS: function() {if (indexOF(/\/comic\/\d+\/\d+\.html/)) {
  3085. if (!getXpath('//li[@class="pfunc"]/a[@class="current"][text()="双击" or text()="雙擊"]')) getXpath('//li[@class="pfunc"]/a[text()="双击" or text()="雙擊"]').click();
  3086. pausePage = false;
  3087. setTimeout(manhuagui_init, 100);
  3088. curSite = DBSite.manhuagui;
  3089. } else if (indexOF('list/') || indexOF('/s/')) {
  3090. curSite = DBSite.manhuagui_list;
  3091. }},
  3092. 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;}',
  3093. pager: {
  3094. type: 4,
  3095. nextL: manhuagui_nextL,
  3096. pageE: 'css;body > script:not([src])',
  3097. insertP: ['css;#mangaBox', 3],
  3098. insertE: manhuagui_insertE,
  3099. replaceE: 'css;title',
  3100. interval: 4000,
  3101. scrollD: 2500
  3102. }
  3103. }, // 漫画柜
  3104. manhuagui_list: {
  3105. pager: {
  3106. type: 1,
  3107. nextL: '//div[@class="pager"]/a[text()="下一页" or text()="下一頁"]',
  3108. pageE: 'css;.book-result > ul > li, .book-list > ul > li',
  3109. insertP: ['css;.book-result > ul, .book-list > ul', 3],
  3110. replaceE: 'css;.pager',
  3111. scrollD: 1500
  3112. },
  3113. function: {
  3114. bF: src_bF,
  3115. pF: [0, 'img[data-src]', 'data-src']
  3116. }
  3117. }, // 漫画台 - 分类/搜索页
  3118. manhuadb: {
  3119. host: 'www.manhuadb.com',
  3120. functionS: function() {if (indexOF(/\/manhua\/\d+\/.+\.html/)) {
  3121. if (getCSS('img.img-fluid.show-pic')) getCSS('img.img-fluid.show-pic').style.display = 'none'; // 隐藏第一个图片(避免重复)
  3122. setTimeout(manhuadb_init, 100);
  3123. curSite = DBSite.manhuadb;
  3124. } else if (indexOF('/list')) {
  3125. curSite = DBSite.manhuacat_list;
  3126. } else if (indexOF('/search') || indexOF('/update')) {
  3127. curSite = DBSite.manhuacat_search;
  3128. }},
  3129. style: '.row.m-0.pt-3.ad_2_wrap, .row.m-0.ad_1_wrap, .pagination.justify-content-center, #left, #right {display: none !important;}',
  3130. pager: {
  3131. type: 4,
  3132. nextL: manhuadb_nextL,
  3133. pageE: 'css;body > script:not([type]):not([src]), .vg-r-data, ol.links-of-books.num_div',
  3134. insertP: ['css;.pjax-container', 3],
  3135. insertE: manhuadb_insertE,
  3136. interval: 5000,
  3137. scrollD: 3000
  3138. }
  3139. }, // 漫画 DB
  3140. hicomic: {
  3141. host: 'www.hicomic.net',
  3142. functionS: function() {if (indexOF('/chapters/')) {
  3143. setTimeout(hicomic_init, 100);
  3144. curSite = DBSite.hicomic;
  3145. }},
  3146. style: '.content {height: auto !important;} .footer, .left_cursor, .right_cursor, .finish {display: none !important;} .content > img {display: block !important;margin: 0 auto !important;}',
  3147. pager: {
  3148. type: 4,
  3149. nextL: hicomic_nextL,
  3150. insertP: ['css;.content', 3],
  3151. insertE: hicomic_insertE,
  3152. interval: 5000,
  3153. scrollD: 3000
  3154. }
  3155. }, // HiComic (嗨漫画)
  3156. dmzj: {
  3157. host: 'www.dmzj.com',
  3158. functionS: function() {if (indexOF('/view/')) {
  3159. if (getCookie('display_mode') != '1') { // 强制开启 [上下滚动阅读] 模式
  3160. document.cookie='display_mode=1; expires=Thu, 18 Dec 2031 12:00:00 GMT; path=/'; // 写入 Cookie 开启 [上下滚动阅读] 模式
  3161. location.reload(); // 刷新网页
  3162. }
  3163. setTimeout(function() {dmzj_init('.comic_wraCon > a > img')}, 100);
  3164. curSite = DBSite.dmzj;
  3165. } else if (indexOF('/category') || indexOF('/update')) {
  3166. curSite = DBSite.dmzj_list;
  3167. } else if (indexOF('/rank')) {
  3168. curSite = DBSite.dmzj_rank;
  3169. }},
  3170. 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;}', // 隐藏中间的页数信息
  3171. pager: {
  3172. type: 4,
  3173. nextL: 'css;span.next > a',
  3174. insertP: ['css;.comic_wraCon', 3],
  3175. insertE: dmzj_insertE,
  3176. replaceE: 'css;.wrap_last_mid, .wrap_last_head',
  3177. interval: 2000,
  3178. scrollD: 3000
  3179. }
  3180. }, // 动漫之家 - 原创
  3181. dmzj_list: {
  3182. style: '.wrap_mhlist_l.con_left, .wrap_list {height: auto!important;}',
  3183. pager: {
  3184. type: 1,
  3185. nextL: 'css;a.pg_next',
  3186. pageE: 'css;ul.list_con_li > li',
  3187. replaceE: 'css;.page',
  3188. scrollD: 1000
  3189. }
  3190. }, // 动漫之家 - 原创 - 分类页
  3191. dmzj_rank: {
  3192. style: '.wrap_mhlist_l.con_left {height: auto!important;}',
  3193. pager: {
  3194. type: 1,
  3195. nextL: 'css;a.pg_next',
  3196. pageE: 'css;.ph_r_con_li > div:not(.ad_column)',
  3197. replaceE: 'css;.page',
  3198. scrollD: 1000
  3199. }
  3200. }, // 动漫之家 - 原创 - 排行榜
  3201. dmzj_manhua: {
  3202. host: 'manhua.dmzj.com',
  3203. functionS: function() {if (indexOF(/\/\d+\.shtml/)) {
  3204. let chapterScroll = getCSS('#qiehuan_txt') // 强制为 [上下滚动阅读] 模式
  3205. if (chapterScroll && chapterScroll.textContent === '切换到上下滚动阅读') {chapterScroll.click();}
  3206. setTimeout(function() {dmzj_init('#center_box > .inner_img img[src]')}, 100);
  3207. curSite = DBSite.dmzj_manhua;
  3208. } else if (indexOF('/tags/')) {
  3209. curSite = DBSite.dmzj_manhua_list;
  3210. } else if (indexOF('/update')) {
  3211. curSite = DBSite.dmzj_manhua_update;
  3212. }},
  3213. 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;}', // 隐藏中间的页数信息
  3214. pager: {
  3215. type: 4,
  3216. nextL: 'css;#next_chapter',
  3217. insertP: ['css;#center_box', 3],
  3218. insertE: dmzj_manhua_insertE,
  3219. replaceE: 'css;.display_graybg',
  3220. interval: 2000,
  3221. scrollD: 3000
  3222. }
  3223. }, // 动漫之家 - 日漫
  3224. dmzj_manhua_list: {
  3225. pager: {
  3226. type: 1,
  3227. nextL: () => getNextUPN(/(?<=-)\d+(?=\.shtml)/, /-\d+\.shtml/, '-', '.shtml', '2', getCSS('#topage > option:last-child').value),
  3228. pageE: 'css;#search_list_div ul',
  3229. scrollD: 1500
  3230. }
  3231. }, // 蓝点网
  3232. dmzj_manhua_update: {
  3233. pager: {
  3234. type: 1,
  3235. nextL: '//div[@class="pages"]/a[contains(text(), "下一页")]',
  3236. pageE: 'css;.newpic_content > *:not(.pages)',
  3237. replaceE: 'css;.pages',
  3238. scrollD: 1000
  3239. }
  3240. }, //动漫之家 - 日漫 - 最新更新
  3241. acgn: {
  3242. host: 'comic.acgn.cc',
  3243. functionS: function() {
  3244. if (indexOF('/view-')) {
  3245. curSite = DBSite.acgn;
  3246. acgn_aF();
  3247. } else if (indexOF('/cate-') || indexOF('/pinyin-')) {
  3248. curSite = DBSite.acgn_list;
  3249. }
  3250. },
  3251. style: '.img1 {cursor: initial !important;}',
  3252. pager: {
  3253. type: 1,
  3254. nextL: 'css;#next_chapter',
  3255. pageE: 'css;.pic[_src]',
  3256. replaceE: 'css;[class^="display_"]',
  3257. interval: 2000,
  3258. scrollD: 2000
  3259. },
  3260. function: {
  3261. aF: acgn_aF
  3262. }
  3263. }, // 动漫戏说
  3264. acgn_list: {
  3265. pager: {
  3266. type: 1,
  3267. nextL: 'css;a[rel="next"]',
  3268. pageE: 'css;ul#display > li',
  3269. replaceE: 'css;#pagination',
  3270. scrollD: 1000
  3271. }
  3272. }, // 动漫戏说 - 分类页
  3273. ykmh: {
  3274. host: 'www.ykmh.com',
  3275. functionS: function() {if (indexOF(/\/\d+\.html/)) {
  3276. let chapterScroll = getCSS('#qiehuan_txt') // 强制为 [上下滚动阅读] 模式
  3277. if (localStorage.getItem('chapterScroll') != '"scroll"') {
  3278. localStorage.setItem('chapterScroll', '"scroll"'); location.reload()
  3279. } else {
  3280. setTimeout(ykmh_init, 100);
  3281. curSite = DBSite.ykmh;
  3282. }
  3283. } else if (indexOF('/list') || indexOF('/search')) {
  3284. curSite = DBSite.ykmh_list;
  3285. }},
  3286. 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;}',
  3287. pager: {
  3288. type: 4,
  3289. nextL: ykmh_nextL,
  3290. insertP: ['css;#images', 3],
  3291. insertE: ykmh_insertE,
  3292. replaceE: 'css;.head_title, span.head_wz',
  3293. interval: 2000,
  3294. scrollD: 3000
  3295. }
  3296. }, // 优酷漫画
  3297. ykmh_list: {
  3298. pager: {
  3299. type: 1,
  3300. nextL: 'css;li.next > a',
  3301. pageE: 'css;li.list-comic',
  3302. replaceE: 'css;ul.pagination',
  3303. scrollD: 1000
  3304. }
  3305. }, // 优酷漫画 - 分类页
  3306. copymanga: {
  3307. host: /copymanga\./,
  3308. functionS: function() {if (indexOF('/chapter/')) {
  3309. curSite = DBSite.copymanga;
  3310. } else if (indexOF('/comics')) {
  3311. curSite = DBSite.copymanga_list;
  3312. }},
  3313. style: '.upMember, .comicContainerAds, .footer {display: none !important;} body, html {height: auto !important;}',
  3314. iframe: true,
  3315. pager: {
  3316. type: 5,
  3317. nextL: 'css;.comicContent-next > a',
  3318. style: 'h4.header, h4.header +div[style*="fixed"] {display: none !important;}',
  3319. scrollD: 3000
  3320. }
  3321. }, // 拷贝漫画
  3322. copymanga_list: {
  3323. pager: {
  3324. type: 1,
  3325. nextL: 'css;li.next > a',
  3326. pageE: 'css;.exemptComic-box > div',
  3327. replaceE: 'css;ul.page-all',
  3328. scrollD: 1500
  3329. },
  3330. function: {
  3331. bF: src_bF,
  3332. pF: [0, 'img[data-src]', 'data-src']
  3333. }
  3334. }, // 拷贝漫画 - 分类页
  3335. mhxqiu: {
  3336. host: /\.mhxqiu/,
  3337. functionS: function() {if (indexOF(/\/\d+\.html/)) { // 阅读页
  3338. curSite = DBSite.mhxqiu;
  3339. } else if (indexOF(/\/\d+\/$/)) { // 目录页
  3340. setTimeout(function(){if (getCSS('#zhankai')) getCSS('#zhankai').click();}, 500)
  3341. } else if (indexOF(/\/(sort|rank)\//)) { // 分类页
  3342. curSite = DBSite.mhxqiu_list;
  3343. }},
  3344. 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;}',
  3345. pager: {
  3346. type: 4,
  3347. nextL: 'css;#mainControlNext',
  3348. insertP: ['css;#comicContain', 3],
  3349. insertE: mhxqiu_insertE,
  3350. replaceE: 'css;.main_control, h1.chaptername_title, span.title-comicHeading',
  3351. interval: 4000,
  3352. scrollD: 3000
  3353. }
  3354. }, // 漫画星球
  3355. mhxqiu_list: {
  3356. pager: {
  3357. type: 1,
  3358. nextL: '//div[@class="NewPages"]//a[contains(text(), "下一页")]',
  3359. pageE: 'css;.cy_list_mh > ul',
  3360. replaceE: 'css;.NewPages',
  3361. scrollD: 1000
  3362. }
  3363. }, // 漫画星球 - 分类页
  3364. fffdm: {
  3365. host: 'manhua.fffdm.com',
  3366. functionS: function() {if (location.pathname.split('/').length === 4) {curSite = DBSite.fffdm;}},
  3367. style: '#footer, #header {display: none !important;} #mhimg0 img {display: block !important;margin: 0 auto !important;}',
  3368. pager: {
  3369. type: 4,
  3370. nextL: '//a[contains(text(), "下一页") or contains(text(), "下一頁") or contains(text(), "下一话") or contains(text(), "下一話")]',
  3371. insertP: ['css;#mhimg0', 3],
  3372. insertE: fffdm_insertE,
  3373. replaceE: 'css;.navigation, #weizhi, h1',
  3374. scrollD: 2000
  3375. }
  3376. }, // 风之动漫
  3377. baozimh: {
  3378. host: ['www.webmota.com', 'cn.webmota.com', 'cn.baozimh.com'],
  3379. functionS: function() {
  3380. if (indexOF('/chapter/')) {
  3381. curSite = DBSite.baozimh;
  3382. } else if (indexOF('/comic/')) {
  3383. if (getCSS('#button_show_all_chatper')) getCSS('#button_show_all_chatper').click();
  3384. }},
  3385. style: '#footer, #header {display: none !important;} .header, .bottom-bar {opacity: 0.3;}',
  3386. pager: {
  3387. type: 1,
  3388. nextL: 'css;.next_chapter > a',
  3389. pageE: 'css;.comic-contain > amp-img',
  3390. replaceE: 'css;.next_chapter, .bottom-bar, .header .title',
  3391. scrollD: 2000
  3392. }
  3393. }, // 包子漫画
  3394. leyuman: {
  3395. host: 'www.leyuman.com',
  3396. functionS: function() {if (indexOF(/\/comic\/\d+\/\d+\.html/)) {
  3397. curSite = DBSite.leyuman;
  3398. setTimeout(leyuman_init, 100);
  3399. } else if (indexOF(/\/comic\/\d+\.html/)) {
  3400. setTimeout(function(){if (getCSS('#read-more')) getCSS('#read-more').click();}, 500)
  3401. } else {
  3402. curSite = DBSite.leyuman_list;
  3403. }},
  3404. style: '.mh_select, .mh_comicpic > p, mh_headpager {display: none !important;} .mh_comicpic > img{width: 100% !important; height: auto !important;}',
  3405. pager: {
  3406. type: 4,
  3407. nextL: 'css;#xurl',
  3408. insertP: ['css;.mh_comicpic', 3],
  3409. insertE: leyuman_insertE,
  3410. replaceE: 'css;.mh_headpager, .mh_readtitle',
  3411. interval: 3000,
  3412. scrollD: 3000
  3413. }
  3414. }, // 乐语漫画
  3415. leyuman_list: {
  3416. pager: {
  3417. type: 1,
  3418. nextL: '//a[@class="page-link"][contains(text(), "下一页")]',
  3419. pageE: 'css;.works_recommend.classification_works > ul',
  3420. replaceE: 'css;.paging',
  3421. scrollD: 1000
  3422. },
  3423. function: {
  3424. bF: src_bF,
  3425. pF: [0, 'img[data-src]', 'data-src']
  3426. }
  3427. }, // 乐语漫画 - 分类页
  3428. _77mh: {
  3429. host: 'www.77mh.cc',
  3430. functionS: function() {if (indexOF(/\/\d+\.html/)) {
  3431. curSite = DBSite._77mh;
  3432. setTimeout(_77mh_init, 100);
  3433. } else if (indexOF('/colist_')) {
  3434. setTimeout(function(){if (getCSS('#listmore1, .listmore')) getCSS('#listmore1, .listmore').click();}, 500)
  3435. } else {
  3436. curSite = DBSite._77mh_list;
  3437. }},
  3438. 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;}',
  3439. pager: {
  3440. type: 4,
  3441. nextL: _77mh_nextL,
  3442. insertP: ['css;#comicImg', 3],
  3443. insertE: _77mh_insertE,
  3444. interval: 3000,
  3445. scrollD: 2000
  3446. }
  3447. }, // 新新漫画
  3448. _77mh_list: {
  3449. pager: {
  3450. type: 1,
  3451. nextL: '//div[@class="pages_s"]/a[text()="下一页"]',
  3452. pageE: 'css;.ar_list_co > ul > li',
  3453. replaceE: 'css;.pages_s',
  3454. scrollD: 1000
  3455. }
  3456. }, // 新新漫画 - 分类页
  3457. _77mh_search: {
  3458. host: 'so.77mh.cc',
  3459. pager: {
  3460. type: 1,
  3461. nextL: 'css;a.next',
  3462. pageE: 'css;.ar_list_co > ul > dl',
  3463. replaceE: 'css;.pages_s',
  3464. scrollD: 1000
  3465. }
  3466. }, // 新新漫画 - 搜索页
  3467. gufengmh: {
  3468. host: /gufengmh/,
  3469. functionS: function() {if (indexOF(/\/\d+.+\.html/)) {
  3470. let chapterScroll = getCSS('#chapter-scroll') // 强制为 [下拉阅读] 模式
  3471. if (chapterScroll && chapterScroll.className === '') {chapterScroll.click();}
  3472. curSite = DBSite.gufengmh;
  3473. } else if (indexOF(/\/(update|list|search)/)) {
  3474. curSite = DBSite.gufengmh_list;
  3475. }},
  3476. style: 'p.img_info {display: none !important;}', // 隐藏中间的页数信息
  3477. pager: {
  3478. type: 4,
  3479. nextL: gufengmh_nextL,
  3480. pageE: 'css;body > script:first-child',
  3481. insertP: ['css;#images', 3],
  3482. insertE: gufengmh_insertE,
  3483. interval: 5000,
  3484. scrollD: 4000
  3485. }
  3486. }, // 古风漫画网
  3487. gufengmh_list: {
  3488. pager: {
  3489. type: 1,
  3490. nextL: 'css;li.next > a',
  3491. pageE: 'css;ul.book-list > li',
  3492. replaceE: 'css;ul.pagination',
  3493. scrollD: 1000
  3494. }
  3495. }, // 古风漫画网 - 分类页
  3496. szcdmj: {
  3497. host: 'www.szcdmj.com',
  3498. functionS: function() {
  3499. if (indexOF('/szcchapter/')) {
  3500. curSite = DBSite.szcdmj;
  3501. } else if (indexOF('/szcbook/')) {
  3502. if (getCSS('#detail-list-more')) getCSS('#detail-list-more').click();
  3503. } else if (lp == '/szcbolist' || lp == '/update') {
  3504. curSite = DBSite.szcdmj_list;
  3505. }},
  3506. style: '.header {opacity: 0.3 !important;}',
  3507. pager: {
  3508. type: 1,
  3509. nextL: '//div[@class="fanye"][1]/a[@href][text()="下一页" or text()="下一话"]',
  3510. pageE: 'css;.comicpage > div',
  3511. insertP: ['css;.comicpage', 3],
  3512. replaceE: 'css;.fanye,h1.title',
  3513. scrollD: 2000
  3514. },
  3515. function: {
  3516. bF: src_bF,
  3517. pF: [0, 'img[data-original]', 'data-original']
  3518. }
  3519. }, // 砂之船动漫家
  3520. szcdmj_list: {
  3521. pager: {
  3522. type: 1,
  3523. nextL: 'css;#nextPage',
  3524. pageE: 'css;ul.mh-list > li',
  3525. replaceE: 'css;.pagination',
  3526. scrollD: 1000
  3527. }
  3528. }, // 砂之船动漫家 - 分类/搜索页
  3529. mangabz: {
  3530. host: ['mangabz.com', 'www.mangabz.com'],
  3531. functionS: function() {if (indexOF(/\/m\d+/)) {
  3532. setTimeout(mangabz_init, 1500);
  3533. curSite = DBSite.mangabz;
  3534. } else if (indexOF(/\/\d+bz\//)) {
  3535. if (getCSS('.detail-list-form-more')) getCSS('.detail-list-form-more').click();
  3536. } else if (indexOF('/manga-list') || lp == '/search') {
  3537. curSite = DBSite.mangabz_list;
  3538. }},
  3539. 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;}',
  3540. hiddenPN: true,
  3541. pager: {
  3542. type: 4,
  3543. nextL: mangabz_nextL,
  3544. insertP: ['css;#cp_img', 3],
  3545. insertE: mangabz_insertE,
  3546. replaceE: 'css;p.top-title, body > .container > div:not([id])',
  3547. interval: 500,
  3548. scrollD: 2000
  3549. }
  3550. }, // Mangabz 漫画
  3551. mangabz_list: {
  3552. pager: {
  3553. type: 1,
  3554. nextL: '//div[@class="page-pagination"]//a[contains(text(), ">")]',
  3555. pageE: 'css;ul.mh-list > li',
  3556. replaceE: 'css;.page-pagination',
  3557. scrollD: 800
  3558. }
  3559. }, // Mangabz 漫画 - 分类/搜索页
  3560. xmanhua: {
  3561. host: ['xmanhua.com', 'www.xmanhua.com'],
  3562. functionS: function() {if (indexOF(/\/m\d+/)) {
  3563. setTimeout(mangabz_init, 1500);
  3564. curSite = DBSite.xmanhua;
  3565. } else if (indexOF(/\/\d+xm\//)) {
  3566. if (getCSS('.detail-list-form-more')) getCSS('.detail-list-form-more').click();
  3567. } else if (indexOF('/manga-list') || lp == '/search') {
  3568. curSite = DBSite.xmanhua_list;
  3569. }},
  3570. 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;}',
  3571. hiddenPN: true,
  3572. pager: {
  3573. type: 4,
  3574. nextL: xmanhua_nextL,
  3575. insertP: ['css;#cp_img', 3],
  3576. insertE: xmanhua_insertE,
  3577. replaceE: 'css;.reader-title, body > .container > div:not([id])',
  3578. interval: 500,
  3579. scrollD: 2500
  3580. }
  3581. }, // Xmanhua 漫画
  3582. xmanhua_list: {
  3583. pager: {
  3584. type: 1,
  3585. nextL: '//div[@class="page-pagination"]//a[contains(text(), ">")]',
  3586. pageE: 'css;ul.mh-list > li',
  3587. replaceE: 'css;.page-pagination',
  3588. scrollD: 1000
  3589. }
  3590. }, // Xmanhua 漫画 - 分类/搜索页
  3591. cocomanga: {
  3592. host: 'www.cocomanga.com',
  3593. functionS: function() {if (indexOF('.html')) {
  3594. if (!(getCookie('mh_readmode') === '' || getCookie('mh_readmode') === '3')) {
  3595. document.cookie='mh_readmode=; expires=Thu, 01 Jan 1970 00:00:00 GMT; path=/'; // 强制开启自带的无缝翻页功能
  3596. location.reload(); // 刷新网页
  3597. }
  3598. setTimeout(cocomanga_init, 500);
  3599. curSite = DBSite.cocomanga;
  3600. } else if (indexOF(/\/\d+\/$/)) {
  3601. setTimeout(function(){if (getCSS('a.website-display-all')) getCSS('a.website-display-all').click();}, 300)
  3602. } else if (lp == '/show') {
  3603. curSite = DBSite.cocomanga_list;
  3604. } else if (lp == '/search') {
  3605. curSite = DBSite.cocomanga_search;
  3606. }},
  3607. style: '.mh_readend, .mh_footpager, .mh_readmode {display: none !important;} .mh_comicpic img {cursor: unset !important;} .mh_comicpic img {min-height: 150px;}',
  3608. pager: {
  3609. type: 4,
  3610. nextL: '//a[contains(@class, "read_page_link") and contains(string(), "下一章")][not(contains(@href, "javascript"))]',
  3611. insertP: ['css;#mangalist', 3],
  3612. insertE: cocomanga_insertE,
  3613. replaceE: 'css;.mh_readtitle, .mh_headpager > a.mh_prevbook, .mh_readend',
  3614. interval: 1000,
  3615. scrollD: 2500
  3616. }
  3617. }, // COCOMANGA 漫画
  3618. cocomanga_list: {
  3619. pager: {
  3620. type: 1,
  3621. nextL: () => getNextEP('css;.fed-page-info a.fed-btns-green+a[onclick]', 'page=', /page=\d+/),
  3622. pageE: 'css;ul.fed-list-info > li',
  3623. replaceE: 'css;.fed-page-info',
  3624. scrollD: 1000
  3625. },
  3626. function: {
  3627. bF: src_bF,
  3628. pF: [1, 'a[data-original]', 'data-original']
  3629. }
  3630. }, // COCOMANGA 漫画 - 分类页
  3631. cocomanga_search: {
  3632. pager: {
  3633. type: 1,
  3634. nextL: () => getNextEP('css;.fed-page-info a.fed-btns-green+a[onclick]', 'page=', /page=\d+/),
  3635. pageE: 'css;dl.fed-deta-info',
  3636. replaceE: 'css;.fed-page-info',
  3637. scrollD: 1000
  3638. },
  3639. function: {
  3640. bF: src_bF,
  3641. pF: [1, 'a[data-original]', 'data-original']
  3642. }
  3643. }, // COCOMANGA 漫画 - 搜索页
  3644. qidian: {
  3645. host: 'www.qidian.com',
  3646. functionS: function() {if (indexOF('/all/')) {curSite = DBSite.qidian;}},
  3647. pager: {
  3648. type: 1,
  3649. nextL: 'css;a[class*="pagination-next"]',
  3650. pageE: 'css;ul.all-img-list > li',
  3651. replaceE: 'css;#page-container',
  3652. scrollD: 900
  3653. }
  3654. }, // 起点中文
  3655. qidian_read: {
  3656. host: 'read.qidian.com',
  3657. style: '.admire-wrap {display: none !important;}',
  3658. pager: {
  3659. type: 1,
  3660. nextL: 'css;a[id$="chapterNext"]',
  3661. pageE: 'css;.main-text-wrap > div:not(.admire-wrap)',
  3662. replaceE: 'css;.chapter-control',
  3663. scrollD: 900
  3664. }
  3665. }, // 起点中文 - 阅读页
  3666. baoshuu: {
  3667. host: 'www.baoshuu.com',
  3668. functionS: function() {if (indexOF('/TXT/list')) curSite = DBSite.baoshuu;},
  3669. pager: {
  3670. type: 1,
  3671. nextL: '//div[@class="listl2"]//a[text()="下一页"]',
  3672. pageE: 'css;.listl2 > ul > li',
  3673. replaceE: 'css;.listl2 > dl',
  3674. scrollD: 900
  3675. }
  3676. }, // 宝书网
  3677. baoshuu_m: {
  3678. host: 'm.baoshuu.com',
  3679. functionS: function() {if (indexOF('/TXT/list')) curSite = DBSite.baoshuu_m;},
  3680. pager: {
  3681. type: 1,
  3682. nextL: '//div[@class="man_first"]//a[text()="下一页"]',
  3683. pageE: 'css;.man_first > ul > li',
  3684. replaceE: 'css;.man_first > dl',
  3685. scrollD: 900
  3686. }
  3687. }, // 宝书网- 手机版
  3688. yushubo: {
  3689. host: 'www.yushubo.com',
  3690. functionS: function() {if (indexOF('/read_')) {
  3691. curSite = DBSite.yushubo;
  3692. } else if (indexOF('/lists/')) {
  3693. curSite = DBSite.yushubo_list;
  3694. } else if (indexOF('/all')) {
  3695. curSite = DBSite.yushubo_all;
  3696. }},
  3697. style: '.readbg.mt10 {display: none !important;}',
  3698. pager: {
  3699. type: 1,
  3700. nextL: '//div[contains(@class, "articlebtn")]/a[contains(text(), "下一页") or contains(text(), "下一章")]',
  3701. pageE: 'css;#BookText',
  3702. insertP: ['css;#BookText', 6],
  3703. insertP6Br: true,
  3704. replaceE: 'css;.articlebtn',
  3705. scrollD: 1000
  3706. }
  3707. }, // 御书网
  3708. yushubo_list: {
  3709. pager: {
  3710. type: 1,
  3711. nextL: 'id("pager")//a[contains(text(), "下一页")]',
  3712. pageE: 'css;.books-list > ul > li',
  3713. replaceE: 'css;#pager',
  3714. scrollD: 1000
  3715. }
  3716. }, // 御书网 - 分类页
  3717. yushubo_all: {
  3718. pager: {
  3719. type: 1,
  3720. nextL: 'id("pager")//a[contains(text(), "下一页")]',
  3721. pageE: 'css;ul.search-list > li',
  3722. replaceE: 'css;#pager',
  3723. scrollD: 1000
  3724. }
  3725. }, // 御书网 - 书库页
  3726. soxscc: {
  3727. host: 'www.soxscc.org',
  3728. functionS: function() {if (indexOF(/\/\d{4,}\.html/)) {curSite = DBSite.soxscc;}},
  3729. style: '.content > p, img {display: none !important;}',
  3730. pager: {
  3731. type: 1,
  3732. nextL: '//font[contains(text(), "下一章")]/following-sibling::a[1]',
  3733. pageE: 'css;.content',
  3734. insertP: ['css;.content', 6],
  3735. insertP6Br: true,
  3736. replaceE: 'css;.pagego',
  3737. scrollD: 1500
  3738. }
  3739. }, // 搜小说
  3740. ihuaben: {
  3741. host: 'www.ihuaben.com',
  3742. functionS: function() {if (indexOF(/\/\d{4,}\.html/)) {curSite = DBSite.ihuaben;}},
  3743. style: '.discription > p > i, img, #container, #BDBannerBottom_PC, iframe, .navFooter {display: none !important;} .discription > p {font-size: 16px; min-height: 24px; padding-bottom: 24px;}',
  3744. pager: {
  3745. type: 1,
  3746. nextL: 'id("preAndNextBar")/a[contains(text(), "下一章")]',
  3747. pageE: 'css;#contentsource > p',
  3748. insertP: ['css;.discription', 3],
  3749. replaceE: 'css;#preAndNextBar',
  3750. scrollD: 1000
  3751. }
  3752. }, // 话本小说网
  3753. xineyby: {
  3754. host: 'www.xineyby.com',
  3755. functionS: function() {if (indexOF('/read/')) {
  3756. curSite = DBSite.xineyby;
  3757. } else if (indexOF(/\/(list|quanben|search)/)) {
  3758. curSite = DBSite.xineyby_list;
  3759. }},
  3760. pager: {
  3761. type: 1,
  3762. nextL: 'id("footlink")/a[contains(text(), "下一页")]',
  3763. pageE: 'css;#contents',
  3764. insertP: ['css;#contents', 6],
  3765. insertP6Br: true,
  3766. replaceE: 'css;#footlink, #amain dd h1',
  3767. scrollD: 900
  3768. }
  3769. }, // 无错小说网
  3770. xineyby_list: {
  3771. pager: {
  3772. type: 1,
  3773. nextL: 'css;#pagelink a.next',
  3774. pageE: 'css;#content > dd tbody > tr:not(:first-child)',
  3775. insertP: ['css;#content > dd tbody', 3],
  3776. replaceE: 'css;#pagelink',
  3777. scrollD: 900
  3778. }
  3779. }, // 无错小说网 - 分类/搜索页
  3780. _530p: {
  3781. host: 'www.530p.com',
  3782. functionS: function() {if (indexOF(/\/\d{4,}\.htm/)) {curSite = DBSite._530p;}},
  3783. pager: {
  3784. type: 1,
  3785. nextL: 'css;#nextLink',
  3786. pageE: 'css;#cp_content',
  3787. insertP: ['css;#cp_content', 6],
  3788. insertP6Br: true,
  3789. replaceE: 'css;#pg_bar',
  3790. scrollD: 1500
  3791. }
  3792. }, // 无弹窗小说网
  3793. xiaoshuo77: {
  3794. host: 'm.xiaoshuo77.net',
  3795. functionS: function() {if (indexOF('.html')) {curSite = DBSite.xiaoshuo77; xs_bF(getAllCSS('#novelcontent'), [/(<br>)?(&nbsp;)+内容未完,下一页.*$|【本章阅读.*$/, '<br>']);}},
  3796. style: '#novelcontent > p, img {display: none !important;}',
  3797. pager: {
  3798. type: 1,
  3799. nextL: 'css;.page_chapter a.p4',
  3800. pageE: 'css;#novelcontent',
  3801. insertP: ['css;#novelcontent', 6],
  3802. replaceE: 'css;.page_chapter',
  3803. scrollD: 1500
  3804. },
  3805. function: {
  3806. bF: xs_bF,
  3807. pF: [/(<br>)?(&nbsp;)+内容未完,下一页.*$|【本章阅读.*$/, '<br>']
  3808. }
  3809. }, // 读书族小说网
  3810. linovel: {
  3811. host: 'www.linovel.net',
  3812. functionS: function() {if (indexOF(/\/book\/\d+\/.+\.html/)) {
  3813. insStyle('.reward-section {display: none !important;}');
  3814. } else if (indexOF('/cat/')) {
  3815. curSite = DBSite.linovel;
  3816. }},
  3817. pager: {
  3818. type: 1,
  3819. nextL: '//ul[@class="pagination"]/li/a[contains(text(), "下一页")]',
  3820. pageE: 'css;.rank-book-list > div',
  3821. replaceE: 'css;ul.pagination',
  3822. scrollD: 1000
  3823. }
  3824. }, // 轻之文库
  3825. _23qb: {
  3826. host: 'www.23qb.net',
  3827. functionS: function() {if (indexOF(/\/book\/\d+\/.+\.html/)) {
  3828. curSite = DBSite._23qb;
  3829. } else if (location.pathname != '/' && !indexOF(/\/book\/\d+\//)) {
  3830. curSite = DBSite._23qb_list;
  3831. }},
  3832. pager: {
  3833. type: 1,
  3834. nextL: () => (location.origin + ReadParams.url_next),
  3835. pageE: 'id("mlfy_main_text")/* | //script[contains(text(), "ReadParams")]',
  3836. insertP: ['css;#mlfy_main_text', 3],
  3837. replaceE: 'css;title',
  3838. scriptT: 2,
  3839. scrollD: 1500
  3840. }
  3841. }, // 铅笔小说
  3842. _23qb_list: {
  3843. pager: {
  3844. type: 1,
  3845. nextL: 'css;.pages a.next, .pages > strong+a',
  3846. pageE: 'css;#sitebox > dl',
  3847. replaceE: 'css;.pages',
  3848. scrollD: 1000
  3849. },
  3850. function: {
  3851. bF: src_bF,
  3852. pF: [0, 'img[_src]', '_src']
  3853. }
  3854. }, // 铅笔小说 - 分类页
  3855. linovelib: {
  3856. host: 'www.linovelib.com',
  3857. functionS: function() {if (indexOF(/\/novel\/\d+\/.+\.html/)) {
  3858. curSite = DBSite.linovelib;
  3859. } else if (indexOF('/wenku/')) {
  3860. curSite = DBSite.linovelib_wenku;
  3861. } else if (indexOF('/top/') || indexOF('/topfull/') || indexOF('toplist.php')) {
  3862. curSite = DBSite.linovelib_top;
  3863. }},
  3864. pager: {
  3865. type: 1,
  3866. nextL: '//p[@class="mlfy_page"]/a[contains(text(), "下一页") or contains(text(), "下一章")]',
  3867. pageE: 'css;#mlfy_main_text > *',
  3868. replaceE: 'css;p.mlfy_page',
  3869. scrollD: 1000
  3870. }
  3871. }, // 哔哩轻小说
  3872. linovelib_wenku: {
  3873. pager: {
  3874. type: 1,
  3875. nextL: 'css;#pagelink > a.next',
  3876. pageE: 'css;.store_collist > div.bookbox',
  3877. replaceE: 'css;#pagelink',
  3878. scrollD: 1000
  3879. },
  3880. function: {
  3881. bF: src_bF,
  3882. pF: [0, 'img[data-original]', 'data-original']
  3883. }
  3884. }, // 哔哩轻小说 - 文库
  3885. linovelib_top: {
  3886. pager: {
  3887. type: 1,
  3888. nextL: 'css;#pagelink > a.next',
  3889. pageE: 'css;.rankpage_box > div.rank_d_list',
  3890. replaceE: 'css;#pagelink',
  3891. scrollD: 1000
  3892. },
  3893. function: {
  3894. bF: src_bF,
  3895. pF: [0, 'img[data-original]', 'data-original']
  3896. }
  3897. }, // 哔哩轻小说 - 全本
  3898. linovelib_w: {
  3899. host: 'w.linovelib.com',
  3900. functionS: function() {if (indexOF(/\/novel\/\d+\/.+\.html/)) {
  3901. curSite = DBSite.linovelib_w;
  3902. } else if (indexOF('/wenku/') || indexOF('/sa/')) {
  3903. curSite = DBSite.linovelib_w_wenku;
  3904. }},
  3905. style: 'body {min-height: 1000px;}',
  3906. pager: {
  3907. type: 1,
  3908. nextL: function() {if (ReadParams) {return (location.origin + ReadParams.url_next)}; return ''},
  3909. pageE: '//body/script[contains(text(), "var ReadParams")] | id("apage")/div',
  3910. insertP: ['css;#apage', 3],
  3911. scriptT: 2,
  3912. scrollD: 1000
  3913. }
  3914. }, // 哔哩轻小说 (手机版)
  3915. linovelib_w_wenku: {
  3916. pager: {
  3917. type: 1,
  3918. nextL: 'css;#pagelink > strong+a ,#pagelink a.next',
  3919. pageE: 'css;ol.book-ol > li',
  3920. replaceE: 'css;#pagelink',
  3921. scrollD: 1000
  3922. },
  3923. function: {
  3924. bF: src_bF,
  3925. pF: [0, 'img[data-original]', 'data-original']
  3926. }
  3927. }, // 哔哩轻小说 (手机版) - 文库
  3928. _423down: {
  3929. host: 'www.423down.com',
  3930. functionS: function() {if (!indexOF('.html')) curSite = DBSite._423down;},
  3931. pager: {
  3932. type: 1,
  3933. nextL: '//div[@class="paging"]//a[contains(text(),"下一页")]',
  3934. pageE: 'css;div.content-wrap ul.excerpt > li',
  3935. replaceE: 'css;div.paging',
  3936. scrollD: 2000
  3937. }
  3938. }, // 423Down
  3939. iao_su: {
  3940. host: 'iao.su',
  3941. pager: {
  3942. type: 1,
  3943. nextL: 'css;li.next > a',
  3944. pageE: 'css;#index > article, #archive > article',
  3945. insertP: ['css;ol.page-navigator', 1],
  3946. replaceE: 'css;ol.page-navigator',
  3947. scriptT: 3,
  3948. scrollD: 1000
  3949. }
  3950. }, // 不死鸟
  3951. sharerw: {
  3952. host: 'www.sharerw.com',
  3953. functionS: function() {if (!indexOF('.html')) {if (lp == '/search.php') {curSite = DBSite.sharerw_search;} else {curSite = DBSite.sharerw;};};},
  3954. pager: {
  3955. type: 1,
  3956. nextL: 'css;span.next > a',
  3957. pageE: 'css;.new-post > article',
  3958. replaceE: 'css;.pagebar',
  3959. scrollD: 1500
  3960. }
  3961. }, // 分享者
  3962. sharerw_search: {
  3963. pager: {
  3964. type: 1,
  3965. nextL: 'css;span.next > a',
  3966. pageE: 'css;#mainbox > article',
  3967. replaceE: 'css;.pagebar',
  3968. scrollD: 1500
  3969. }
  3970. }, // 分享者 - 搜索页
  3971. extfans: {
  3972. host: 'www.extfans.com',
  3973. functionS: function() {if (location.pathname != '/') {curSite = DBSite.extfans;}},
  3974. pager: {
  3975. type: 1,
  3976. nextL: 'css;a.page-next',
  3977. pageE: 'css;.app-item-content, .article-item-content',
  3978. replaceE: 'css;.pagination-content',
  3979. scrollD: 2000
  3980. }
  3981. }, // 扩展迷
  3982. appinn: {
  3983. host: 'www.appinn.com',
  3984. pager: {
  3985. type: 1,
  3986. nextL: 'css;a.next.page-numbers',
  3987. pageE: 'css;section#latest-posts > article',
  3988. replaceE: 'css;div.nav-links',
  3989. scrollD: 1500
  3990. }
  3991. }, // 小众软件
  3992. isharepc: {
  3993. host: 'www.isharepc.com',
  3994. pager: {
  3995. type: 1,
  3996. nextL: 'css;a.next.page-numbers',
  3997. pageE: 'css;.content > div.post',
  3998. replaceE: 'css;nav.pagination',
  3999. scrollD: 1000
  4000. }
  4001. }, // 乐软博客
  4002. ghxi: {
  4003. host: 'www.ghxi.com',
  4004. functionS: function() {if (lp == '/' && !location.search) {curSite = DBSite.ghxi;} else {curSite = DBSite.ghxi_list;}},
  4005. pager: {
  4006. type: 2,
  4007. nextL: 'css;.load-more',
  4008. interval: 1000,
  4009. scrollD: 5000
  4010. }
  4011. }, // 果核剥壳 - 首页
  4012. ghxi_list: {
  4013. pager: {
  4014. type: 1,
  4015. nextL: 'css;a.next',
  4016. pageE: 'css;ul.post-loop > li',
  4017. replaceE: 'css;ul.pagination',
  4018. scrollD: 1500
  4019. },
  4020. function: {
  4021. bF: src_bF,
  4022. pF: [0, 'img[data-original]', 'data-original']
  4023. }
  4024. }, // 果核剥壳 - 分类/搜索页
  4025. _6yit: {
  4026. host: ['www.6yit.com'],
  4027. functionS: function() {if (!indexOF('.html')) {curSite = DBSite._6yit;}},
  4028. pager: {
  4029. type: 1,
  4030. nextL: 'css;a.next.page-numbers',
  4031. pageE: 'css;posts.posts-item.list',
  4032. replaceE: 'css;.pagenav',
  4033. scrollD: 1500
  4034. }
  4035. }, // 六音软件
  4036. apprcn: {
  4037. host: ['www.apprcn.com', 'free.apprcn.com'],
  4038. functionS: function() {if (lp == '/' || indexOF('/category/')) {curSite = DBSite.apprcn;}},
  4039. pager: {
  4040. type: 1,
  4041. nextL: '//div[@class="pagination"]//a[contains(text(), "Next")]',
  4042. pageE: 'css;article.article',
  4043. replaceE: 'css;.pagination',
  4044. scrollD: 1000
  4045. }
  4046. }, // 反斗软件
  4047. weidown: {
  4048. host: 'www.weidown.com',
  4049. functionS: function() {if (indexOF('/search/')) { //搜索页
  4050. curSite = DBSite.weidown_search;
  4051. } else if (indexOF('/special')) { // 专题页
  4052. curSite = DBSite.weidown_special;
  4053. } else {
  4054. curSite = DBSite.weidown;
  4055. }},
  4056. pager: {
  4057. type: 1,
  4058. nextL: 'css;a.nextpage',
  4059. pageE: 'css;.articleWrapper > .itemArticle, .articleWrapper > .richTextItem.search',
  4060. insertP: ['css;.articleWrapper', 3],
  4061. replaceE: 'css;#pageGroup',
  4062. scrollD: 1500
  4063. }
  4064. }, // 微当下载
  4065. weidown_search: {
  4066. pager: {
  4067. type: 1,
  4068. nextL: 'css;a.nextpage',
  4069. pageE: 'css;.articleListWrapper > .richTextItem.search',
  4070. replaceE: 'css;#pageGroup',
  4071. scrollD: 700
  4072. }
  4073. }, // 微当下载 - 搜索页
  4074. weidown_special: {
  4075. pager: {
  4076. type: 1,
  4077. nextL: 'css;a.nextpage',
  4078. pageE: 'css;.special > .item, .articleWrapper > div',
  4079. insertP: ['css;.special, .articleWrapper', 3],
  4080. replaceE: 'css;#pageGroup',
  4081. scrollD: 700
  4082. }
  4083. }, // 微当下载 - 专题页
  4084. fsylr: {
  4085. host: 'fsylr.com',
  4086. functionS: function() {if (!indexOF('.html')) {curSite = DBSite.fsylr;}},
  4087. pager: {
  4088. type: 1,
  4089. nextL: 'css;a.next.page-numbers',
  4090. pageE: 'css;.posts-con > div:not([class*="posts-"])',
  4091. replaceE: 'css;nav.pagination',
  4092. scrollD: 2000
  4093. }
  4094. }, // 发烧友绿软
  4095. iplaysoft: {
  4096. host: 'www.iplaysoft.com',
  4097. functionS: function() {if (indexOF('.html') || indexOF('/p/')) {curSite = DBSite.iplaysoft_comment;} else {curSite = DBSite.iplaysoft;}},
  4098. pager: {
  4099. type: 1,
  4100. nextL: 'css;.pagenavi a[title="下一页"]',
  4101. pageE: 'css;#postlist > div.entry',
  4102. replaceE: 'css;.pagenavi-button, .pagenavi',
  4103. scrollD: 1200
  4104. },
  4105. function: {
  4106. bF: src_bF,
  4107. pF: [0, 'img[data-src]', 'data-src']
  4108. }
  4109. }, // 异次元软件
  4110. iplaysoft_comment: {
  4111. pager: {
  4112. type: 2,
  4113. nextL: 'css;#loadHistoryComments',
  4114. nextTextOf: '展开后面',
  4115. scrollD: 1200
  4116. }
  4117. }, // 异次元软件 - 评论
  4118. mubolin: {
  4119. host: 'www.mubolin.cn',
  4120. pager: {
  4121. type: 1,
  4122. nextL: 'css;a.next.page-numbers',
  4123. pageE: 'css;#recent-content > div',
  4124. replaceE: 'css;nav.pagination',
  4125. scrollD: 1500
  4126. }
  4127. }, // 悪魔の小站
  4128. mpyit: {
  4129. host: 'www.mpyit.com',
  4130. functionS: function() {if (lp == '/' && !location.search) {
  4131. curSite = DBSite.mpyit;
  4132. } else if (indexOF('/category/') || indexOF('?s=', 's')) { // 搜索页 / 分类页
  4133. curSite = DBSite.mpyit_category;
  4134. }},
  4135. pager: {
  4136. type: 1,
  4137. nextL: 'css;a.page-numbers[title="下一页"]',
  4138. pageE: 'css;#post > div[id^="post-"]',
  4139. replaceE: 'css;#post > #pagenavi',
  4140. scrollD: 1700
  4141. }
  4142. }, // 老殁 | 殁漂遥
  4143. mpyit_category: {
  4144. pager: {
  4145. type: 1,
  4146. nextL: 'css;a.page-numbers[title="下一页"]',
  4147. pageE: 'css;#content > div[class^="entry_box"]',
  4148. replaceE: 'css;#content > #pagenavi',
  4149. scrollD: 1700
  4150. }
  4151. }, // 老殁 | 殁漂遥 - 搜索页/分类页
  4152. tenlonstudio: {
  4153. host: 'www.tenlonstudio.com',
  4154. functionS: function() {if (lp == '/' && !location.search) {
  4155. curSite = DBSite.tenlonstudio;
  4156. } else {
  4157. curSite = DBSite.tenlonstudio_list;
  4158. }},
  4159. pager: {
  4160. type: 2,
  4161. nextL: 'css;.load-more',
  4162. nextText: '加载更多',
  4163. interval: 500,
  4164. scrollD: 1000
  4165. }
  4166. }, // 腾龙工作室
  4167. tenlonstudio_list: {
  4168. pager: {
  4169. type: 1,
  4170. nextL: '//div[@class="btn-pager"]/a[contains(text(), "❯")]',
  4171. pageE: 'css;li.post-list-item',
  4172. replaceE: 'css;.ajax-pager',
  4173. scrollD: 1000
  4174. }
  4175. }, // 腾龙工作室 - 分类/搜索页
  4176. yxssp: {
  4177. host: 'www.yxssp.com',
  4178. pager: {
  4179. type: 1,
  4180. nextL: '//div[contains(@class, "page-nav")]/a[last()]',
  4181. pageE: 'css;.td-modules-container.td-module-number4 > div',
  4182. replaceE: 'css;.page-nav.td-pb-padding-side',
  4183. scrollD: 1000
  4184. }
  4185. }, // 异星软件空间
  4186. yrxitong: {
  4187. host: 'www.yrxitong.com',
  4188. functionS: function() {
  4189. if (lp == '/sr.jsp') {
  4190. curSite = DBSite.yrxitong_search;
  4191. } else if (!indexOF('/h-nd-')) {
  4192. curSite = DBSite.yrxitong;
  4193. }
  4194. },
  4195. pager: {
  4196. type: 1,
  4197. nextL: 'css;span.pageNext > a',
  4198. pageE: 'css;#containerFormsCenter .m_news_list > div',
  4199. replaceE: 'css;.pagenation',
  4200. scrollD: 1200
  4201. },
  4202. function: {
  4203. bF: src_bF,
  4204. pF: [1, 'a[data-original]', 'data-original']
  4205. }
  4206. }, // 小鱼儿 yr 系统
  4207. yrxitong_search: {
  4208. pager: {
  4209. type: 1,
  4210. nextL: 'css;span.pageNext > a',
  4211. pageE: 'css;#containerFormsCenter .newsList > div',
  4212. replaceE: 'css;.pagenation',
  4213. scrollD: 2000
  4214. }
  4215. }, // 小鱼儿 yr 系统 - 搜索页
  4216. downg: {
  4217. host: 'www.downg.com',
  4218. functionS: function() {if (indexOF('/new/')) {curSite = DBSite.downg;}},
  4219. pager: {
  4220. type: 1,
  4221. nextL: 'css;a.nextpage',
  4222. pageE: 'css;.ApdList > ul.ApdLi',
  4223. replaceE: 'css;.pagination',
  4224. scrollD: 1500
  4225. }
  4226. }, // 绿软家园
  4227. sordum: {
  4228. host: 'www.sordum.org',
  4229. pager: {
  4230. type: 1,
  4231. nextL: 'css;a.next.page-numbers',
  4232. pageE: 'css;.article > article',
  4233. replaceE: 'css;nav.navigation.posts-navigation',
  4234. scrollD: 1500
  4235. }
  4236. }, // (下面这几个都是国外博客网站)
  4237. winaero: {
  4238. host: 'winaero.com',
  4239. functionS: function() {if (lp == '/' || indexOF('/category/')) curSite = DBSite.winaero;},
  4240. pager: {
  4241. type: 1,
  4242. nextL: 'css;a.next.page-numbers',
  4243. pageE: 'css;#main > article',
  4244. replaceE: 'css;.pagination',
  4245. scrollD: 1500
  4246. }
  4247. },
  4248. lrepacks: {
  4249. host: 'lrepacks.net',
  4250. functionS: function() {if (!indexOF('.html')) curSite = DBSite.lrepacks;},
  4251. pager: {
  4252. type: 1,
  4253. nextL: 'css;.page_next > a',
  4254. pageE: 'css;#main .post-list article',
  4255. replaceE: 'css;.page_nav',
  4256. scrollD: 1500
  4257. },
  4258. function: {
  4259. bF: lrepacks_bF
  4260. }
  4261. },
  4262. winhelponline: {
  4263. host: 'www.winhelponline.com',
  4264. functionS: function() {if (lp == '/blog/') {curSite = DBSite.winhelponline;}},
  4265. pager: {
  4266. type: 1,
  4267. nextL: 'css;span.prev > a',
  4268. pageE: 'css;#main > article',
  4269. replaceE: 'css;nav.paging-navigation',
  4270. scrollD: 2000
  4271. }
  4272. },
  4273. windowslatest: {
  4274. host: 'www.windowslatest.com',
  4275. pager: {
  4276. type: 1,
  4277. nextL: '//div[contains(@class, "page-nav")]/a[last()]',
  4278. pageE: 'css;.td-ss-main-content > div:not(.td-block-title-wrap):not(.page-nav)',
  4279. replaceE: 'css;.page-nav',
  4280. scrollD: 2000
  4281. }
  4282. },
  4283. thewindowsclub: {
  4284. host: 'www.thewindowsclub.com',
  4285. functionS: function() {curSite = DBSite.thewindowsclub; if (lp == '/') {curSite.pager.scrollD = 2000;}},
  4286. pager: {
  4287. type: 1,
  4288. nextL: 'css;li.pagination-next > a',
  4289. pageE: 'css;#genesis-content > article.post',
  4290. replaceE: 'css;.pagination',
  4291. scrollD: 1500
  4292. }
  4293. },
  4294. acs: {
  4295. host: ['pubs.acs.org','onlinelibrary.wiley.com'],
  4296. functionS: function() {if (indexOF('/doSearch')) {curSite = DBSite.acs;}},
  4297. pager: {
  4298. type: 1,
  4299. nextL: 'css;a.pagination__btn--next',
  4300. pageE: 'css;ul.items-results > *',
  4301. replaceE: 'css;.pagination',
  4302. scrollD: 3000
  4303. }
  4304. }, // Wiley Online Library + ACS (Publications)
  4305. libgen: {
  4306. host: /libgen/,
  4307. functionS: function() {if (lp == '/search.php') {curSite = DBSite.libgen;}},
  4308. pager: {
  4309. type: 1,
  4310. nextL: '//font/a[contains(text(), "►")]',
  4311. pageE: 'css;table[rules="rows"] > tbody > tr:nth-of-type(n+2), .paginator+script:not([src])',
  4312. insertP: ['css;table[rules="rows"] > tbody', 3],
  4313. replaceE: '//td[./font/a[contains(text(), "►")]]',
  4314. scriptT: 2,
  4315. scrollD: 2000
  4316. }
  4317. }, // Library Genesis
  4318. sciencedirect: {
  4319. host: 'www.sciencedirect.com',
  4320. functionS: function() {locationC = true; if (lp == '/search') {curSite = DBSite.sciencedirect; setTimeout(function(){insStyle('html, body {height: ' + (document.documentElement.scrollHeight || document.body.scrollHeight) + 'px;}')}, 2000)}},
  4321. style: 'footer {display: none !important;}',
  4322. iframe: true,
  4323. pager: {
  4324. type: 5,
  4325. nextL: 'css;a[data-aa-name="srp-next-page"]',
  4326. scrollD: 2000
  4327. }
  4328. }, // ScienceDirect
  4329. pubmed: {
  4330. host: 'pubmed.ncbi.nlm.nih.gov',
  4331. pager: {
  4332. type: 2,
  4333. nextL: 'css;button.load-button.next-page',
  4334. nextText: 'Show more results',
  4335. scrollD: 1500
  4336. }
  4337. }, // PubMed
  4338. x_mol: {
  4339. host: 'www.x-mol.com',
  4340. functionS: function() {if (indexOF('/search/q') || indexOF('/paper/')) {curSite = DBSite.x_mol;}},
  4341. pager: {
  4342. type: 1,
  4343. nextL: () => getNextEP('css;.pagination li.active+li > a', 'pageIndex=', /pageIndex=\d+/),
  4344. pageE: 'css;.magazine-senior-search-results-list > ul > li, .magazine-model-content-new > ul > li',
  4345. insertP: ['css;.magazine-senior-search-results-list > ul, .magazine-model-content-new > ul', 3],
  4346. replaceE: 'css;.pagination',
  4347. scrollD: 2000
  4348. }
  4349. }, // X-MOL
  4350. cqvip: {
  4351. host: 'www.cqvip.com',
  4352. functionS: function() {if (indexOF('/search')) {curSite = DBSite.cqvip;}},
  4353. pager: {
  4354. type: 6,
  4355. nextL: '//ul[@class="pagenum"]//a[text()="下一页"]',
  4356. pageE: 'css;ul.prolist:last-child > li',
  4357. replaceE: 'css;ul.pagenum',
  4358. loadTime: 1000,
  4359. scrollD: 2000
  4360. }
  4361. }, // 维普网
  4362. ablesci: {
  4363. host: 'www.ablesci.com',
  4364. functionS: function() {if (indexOF('/detail') && GM_getValue('menu_thread')) {curSite = DBSite.ablesci_p;} else if (getCSS('ul.fly-list')) {curSite = DBSite.ablesci;}},
  4365. pager: {
  4366. type: 1,
  4367. nextL: 'css;li.next > a',
  4368. pageE: 'css;ul.fly-list > li',
  4369. replaceE: 'css;.pages',
  4370. scrollD: 2000
  4371. }
  4372. }, // 科研通
  4373. ablesci_p: {
  4374. pager: {
  4375. type: 1,
  4376. nextL: 'css;li.next > a',
  4377. pageE: 'css;ul#jieda > li',
  4378. replaceE: 'css;.pages',
  4379. scrollD: 2000
  4380. }
  4381. }, // 科研通 - 帖子内
  4382. google_scholar: {
  4383. host: 'scholar.google.com',
  4384. functionS: function() {if (lp == '/scholar') {curSite = DBSite.google_scholar;}},
  4385. pager: {
  4386. type: 1,
  4387. nextL: '//a[./span[contains(@class, "next")]]',
  4388. pageE: 'css;#gs_res_ccl_mid > *',
  4389. insertP: ['css;#gs_res_ccl_mid', 3],
  4390. replaceE: 'css;#gs_n',
  4391. scriptT: 1,
  4392. scrollD: 2000
  4393. }
  4394. }, // 谷歌学术
  4395. google_scholar_: {
  4396. host: 'sc.panda321.com',
  4397. pager: {
  4398. type: 1,
  4399. nextL: '//a[./span[contains(@class, "next")]]',
  4400. pageE: 'css;#gs_res_ccl_mid > *',
  4401. insertP: ['css;#gs_res_ccl_mid', 3],
  4402. replaceE: 'css;#gs_n',
  4403. scriptT: 1,
  4404. scrollD: 2000
  4405. },
  4406. function: {
  4407. bF: function(pageElems){
  4408. getCSS('#gs_n').remove();
  4409. return pageElems
  4410. }
  4411. }
  4412. }, // 谷歌学术 - 其他镜像站
  4413. bing_academic: {
  4414. style: 'li.aca_algo_count {display: none !important;}',
  4415. pager: {
  4416. type: 1,
  4417. nextL: 'css;a.sb_pagN',
  4418. pageE: 'css;#b_results > li.aca_algo',
  4419. replaceE: 'css;#b_results .b_pag',
  4420. scrollD: 1000
  4421. }
  4422. }, // 必应学术
  4423. baidu_xueshu: {
  4424. host: 'xueshu.baidu.com',
  4425. functionS: function() {if (lp == '/s') {
  4426. curSite = DBSite.baidu_xueshu;
  4427. } else if (indexOF('journal/navigation')) {
  4428. curSite = DBSite.baidu_xueshu_journal;
  4429. } else if (indexOF('paper/show')) {
  4430. curSite = DBSite.baidu_xueshu_paper;
  4431. }},
  4432. pager: {
  4433. type: 1,
  4434. nextL: 'id("page")/a[./i[@class="c-icon-pager-next"]]',
  4435. pageE: 'css;#bdxs_result_lists > div.result',
  4436. replaceE: 'css;#page',
  4437. scrollD: 1000
  4438. }
  4439. }, // 百度学术
  4440. baidu_xueshu_journal: {
  4441. pager: {
  4442. type: 1,
  4443. nextL: 'css;a.res-page-next',
  4444. pageE: 'css;#journaldetail > div',
  4445. replaceE: 'css;.res-page',
  4446. scrollD: 1000
  4447. }
  4448. }, // 百度学术
  4449. baidu_xueshu_paper: {
  4450. pager: {
  4451. type: 2,
  4452. nextL: 'css;div:not([style*="display: none"]) > .more_btn',
  4453. nextText: '加载更多',
  4454. scrollD: 1000
  4455. }
  4456. }, // 百度学术
  4457. so_xueshu: {
  4458. host: 'xueshu.so.com',
  4459. functionS: function() {if (lp == '/s') {curSite = DBSite.so_xueshu;}},
  4460. pager: {
  4461. type: 1,
  4462. nextL: 'css;a#snext',
  4463. pageE: 'css;ul.list > li',
  4464. replaceE: 'css;#page',
  4465. scrollD: 1000
  4466. }
  4467. }, // 360 学术
  4468. wanfangdata: {
  4469. host: 's.wanfangdata.com.cn',
  4470. functionS: function() {locationC = true; curSite = DBSite.wanfangdata;},
  4471. style: '#zkFooter {display: none !important;}',
  4472. iframe: true,
  4473. pager: {
  4474. type: 5,
  4475. nextL: () => getNextEP('css;.pager.active+span.pager', 'p=', /p=\d+/),
  4476. scrollD: 2000
  4477. }
  4478. }, // 万方数据知识服务平台
  4479. nsfc: {
  4480. host: ['output.nsfc.gov.cn', 'kd.nsfc.gov.cn'],
  4481. functionS: function() {if (indexOF('/conclusionProject/')) curSite = DBSite.nsfc;},
  4482. style: '#pageNoUl {display: none !important;}',
  4483. pager: {
  4484. type: 4,
  4485. nextL: nsfc_nextL,
  4486. insertP: ['css;#pageNoUl', 1],
  4487. insertE: nsfc_insertE,
  4488. scrollD: 1500
  4489. }
  4490. }, // 国家自然科学基金
  4491. coolkeyan: {
  4492. host: 'www.coolkeyan.com',
  4493. functionS: function() {if (location.hash.indexOf('/project/') > -1) curSite = DBSite.coolkeyan;},
  4494. style: '.q-img {height: auto !important;} .q-img__image {max-height: 1000px !important;} .row.q-my-sm.q-gutter-sm {display: none !important;}',
  4495. pager: {
  4496. type: 4,
  4497. nextL: coolkeyan_nextL,
  4498. insertP: ['//div[contains(@class, "q-img__image")][last()]', 4],
  4499. insertE: coolkeyan_insertE,
  4500. scrollD: 1500
  4501. }
  4502. }, // 酷科研
  4503. stackoverflow: {
  4504. host: 'stackoverflow.com',
  4505. functionS: function() {if (indexOF('/questions') && !indexOF(/\/questions\/\d+\//)) {
  4506. curSite = DBSite.stackoverflow;
  4507. } else if (lp == '/search') {
  4508. curSite = DBSite.stackoverflow_search;
  4509. } else if (lp == '/tags') {
  4510. curSite = DBSite.stackoverflow_tags;
  4511. } else if (lp == '/users') {
  4512. curSite = DBSite.stackoverflow_users;
  4513. }},
  4514. pager: {
  4515. type: 1,
  4516. nextL: 'css;a[rel="next"]',
  4517. pageE: 'css;#questions > div',
  4518. replaceE: 'css;.pager',
  4519. scrollD: 2000
  4520. }
  4521. }, // StackOverflow - Questions
  4522. stackoverflow_tags: {
  4523. pager: {
  4524. type: 1,
  4525. nextL: 'css;a[rel="next"]',
  4526. pageE: 'css;#tags-browser > div',
  4527. replaceE: 'css;.pager',
  4528. scrollD: 2000
  4529. }
  4530. }, // StackOverflow - Tags
  4531. stackoverflow_users: {
  4532. pager: {
  4533. type: 1,
  4534. nextL: 'css;a[rel="next"]',
  4535. pageE: 'css;#user-browser > div:first-child > div',
  4536. replaceE: 'css;.pager',
  4537. scrollD: 2000
  4538. }
  4539. }, // StackOverflow - Users
  4540. stackoverflow_search: {
  4541. pager: {
  4542. type: 1,
  4543. nextL: 'css;a[rel="next"]',
  4544. pageE: 'css;.js-search-results > div:first-child > div',
  4545. replaceE: 'css;.pager',
  4546. scrollD: 2000
  4547. }
  4548. }, // StackOverflow - Search
  4549. segmentfault: {
  4550. host: 'segmentfault.com',
  4551. functionS: function() {locationC = true;
  4552. if (indexOF('/questions')) {
  4553. curSite = DBSite.segmentfault;
  4554. } else if (lp == '/search') {
  4555. curSite = DBSite.segmentfault_search;
  4556. }},
  4557. pager: {
  4558. type: 1,
  4559. nextL: '//a[@class="page-link"][contains(text(), "下一页")]',
  4560. pageE: 'css;ul.list-group > li',
  4561. replaceE: 'css;ul.pagination',
  4562. scrollD: 1000
  4563. }
  4564. }, // SegmentFault - Questions
  4565. segmentfault_search: {
  4566. pager: {
  4567. type: 1,
  4568. nextL: 'css;a[rel="next"]',
  4569. pageE: 'css;.search-result > section',
  4570. replaceE: 'css;ul.pagination',
  4571. scrollD: 1000
  4572. }
  4573. }, // SegmentFault - Search
  4574. w3school_com_cn: {
  4575. host: 'www.w3school.com.cn',
  4576. functionS: function() {if (location.pathname.split('/').length > 2) {curSite = DBSite.w3school_com_cn;}},
  4577. style: '#maincontent h1:not(:nth-of-type(1)) {margin-top: 30px;}',
  4578. pager: {
  4579. type: 3,
  4580. nextL: function() { // 过滤部分非本页的参考手册
  4581. let next = getCSS('li.next > a[href]')
  4582. if (next && next.href.indexOf('/index.') === -1) return next.href;
  4583. curSite = {SiteTypeID: 0}; return ''
  4584. },
  4585. pageE: 'css;#maincontent > *:not([class*="prenextnav"]):not(#bpn):not(#tpn)',
  4586. insertP: ['id("bpn") | //div[contains(@class, "prenextnav")][last()]', 1],
  4587. replaceE: 'css;ul.prenext, #navsecond',
  4588. scrollE: 'id("bpn") | //div[contains(@class, "prenextnav")][last()]',
  4589. forceHTTPS: true,
  4590. scrollD: 600
  4591. }
  4592. }, // W3school
  4593. w3cschool_cn: {
  4594. host: 'www.w3cschool.cn',
  4595. functionS: function() {if (location.pathname.split('/').length > 2) {curSite = DBSite.w3cschool_cn;}},
  4596. style: '.widget-body, #rfbanner {display: none !important;}',
  4597. pager: {
  4598. type: 1,
  4599. nextL: 'css;.next-link > a',
  4600. pageE: 'css;#pro-mian-header, .content-bg',
  4601. replaceE: 'css;.content-links, .splitter-sidebar',
  4602. scrollD: 1500
  4603. }
  4604. }, // W3Cschool
  4605. runoob: {
  4606. host: 'www.runoob.com',
  4607. functionS: function() {if (location.pathname.split('/').length > 2 && getCSS('#leftcolumn')) {curSite = DBSite.runoob;}},
  4608. style: '#comments, #postcomments, #respond, #footer {display: none !important;} .article-intro h1:not(:nth-of-type(1)) {margin: 30px 0 10px 0;}',
  4609. pager: {
  4610. type: 1,
  4611. nextL: function() { // 过滤部分非本页的参考手册
  4612. let next = getCSS('#leftcolumn > a[style]~a[href]')
  4613. if (next && next.href.split('/').length === location.href.split('/').length && next.href.split('/')[3] === location.href.split('/')[3]) return next.href;
  4614. next.href = location.href; curSite = {SiteTypeID: 0}; return ''
  4615. },
  4616. pageE: 'css;#content > *, script[src*="assets/js/main.min.js"]',
  4617. insertP: ['css;#content', 3],
  4618. replaceE: 'css;.previous-next-links, #leftcolumn',
  4619. scriptT: 2,
  4620. forceHTTPS: true,
  4621. scrollD: 1000
  4622. }
  4623. }, // 菜鸟教程
  4624. cnblogs: {
  4625. host: ['www.cnblogs.com', 'zzk.cnblogs.com'],
  4626. functionS: function() {
  4627. if (location.hostname === 'zzk.cnblogs.com') {
  4628. curSite = DBSite.cnblogs_search;
  4629. } else if (getCSS('#post_list')) {
  4630. curSite = DBSite.cnblogs_list;
  4631. } else if (location.pathname.split('/').length === 3 && getCSS('.topicListFooter')) {
  4632. curSite = DBSite.cnblogs;
  4633. if (!getCSS('#homepage_top_pager')) {
  4634. getCSS('.forFlow').insertAdjacentHTML(getAddTo(2), '<div id="homepage_top_pager" class="topicListFooter"></div>');
  4635. getCSS('.forFlow').insertAdjacentHTML(getAddTo(3), '<div id="homepage_bottom_pager" class="topicListFooter"></div>');
  4636. }
  4637. }
  4638. },
  4639. pager: {
  4640. type: 1,
  4641. nextL: '//div[@class="topicListFooter"]//a[contains(text(), "下一页")]',
  4642. pageE: 'css;div.day',
  4643. replaceE: 'css;.topicListFooter',
  4644. scrollD: 1000
  4645. }
  4646. }, // 博客园 - 文章列表(个人)
  4647. cnblogs_list: {
  4648. pager: {
  4649. type: 1,
  4650. nextL: '//div[@class="pager"]//a[contains(text(), ">")]',
  4651. pageE: 'css;#post_list > article',
  4652. replaceE: 'css;.pager',
  4653. scrollD: 1000
  4654. }
  4655. }, // 博客园 - 文章列表
  4656. cnblogs_search: {
  4657. pager: {
  4658. type: 1,
  4659. nextL: '//div[@class="pager"]//a[contains(text(), ">")]',
  4660. pageE: 'css;div.searchItem',
  4661. replaceE: 'css;.pager',
  4662. scrollD: 1000
  4663. }
  4664. }, // 博客园 - 搜索页
  4665. gitee: {
  4666. host: 'gitee.com',
  4667. functionS: function() {
  4668. if (indexOF('/explore/')) {
  4669. curSite = DBSite.gitee;
  4670. } else if (indexOF(/\/issues$/)) {
  4671. curSite = DBSite.gitee_issues;
  4672. } else if (indexOF(/\/releases/)) {
  4673. curSite = DBSite.gitee_releases;
  4674. } else if (indexOF(/\/tags/)) {
  4675. curSite = DBSite.gitee_tags;
  4676. }
  4677. if (curSite.SiteTypeID > 0 && !curSite.pager.nextL) {
  4678. curSite.pager.type = 1;
  4679. curSite.pager.nextL = 'css;a[rel="next"]';
  4680. curSite.pager.replaceE = 'css;.pagination';
  4681. curSite.pager.scrollD = 2500;
  4682. }
  4683. },
  4684. pager: {
  4685. pageE: 'css;.items > .item',
  4686. }
  4687. }, // Gitee - Explore 列表
  4688. gitee_issues: {
  4689. pager: {
  4690. pageE: 'css;.issue-wrapper',
  4691. }
  4692. }, // Gitee - Issues 列表
  4693. gitee_releases: {
  4694. pager: {
  4695. pageE: 'css;.release-tag-item',
  4696. }
  4697. }, // Gitee - Releases 列表
  4698. gitee_tags: {
  4699. pager: {
  4700. pageE: 'css;.tag-item',
  4701. }
  4702. }, // Gitee - Tags 列表
  4703. gitee_search: {
  4704. host: 'search.gitee.com',
  4705. functionS: function() {if (location.search) curSite = DBSite.gitee_search;},
  4706. pager: {
  4707. type: 1,
  4708. nextL: 'css;li.next:not(.disabled) > a',
  4709. pageE: 'css;#hits-list > div',
  4710. replaceE: 'css;ul.pagination',
  4711. scrollD: 1000
  4712. }
  4713. }, // Gitee - Search 列表
  4714. github: {
  4715. host: ['github.com', 'hub.fastgit.org'],
  4716. functionS: function() {locationC = true;
  4717. if (lp == '/') {
  4718. curSite = DBSite.github;
  4719. } else if (indexOF('tab=stars', 's')) {
  4720. curSite = DBSite.github_star;
  4721. } else if (indexOF('tab=repositories', 's')) {
  4722. curSite = DBSite.github_repositories;
  4723. } else if (indexOF(/\/issues$/) || indexOF(/\/pulls$/)) {
  4724. curSite = DBSite.github_issues;
  4725. } else if (indexOF(/\/discussions$/) || indexOF('/discussions/categories')) {
  4726. curSite = DBSite.github_discussions;
  4727. } else if (indexOF(/\/releases$/)) {
  4728. curSite = DBSite.github_releases;
  4729. } else if (indexOF(/\/tags$/)) {
  4730. curSite = DBSite.github_tags;
  4731. } else if (indexOF('/commits')) {
  4732. curSite = DBSite.github_commits;
  4733. } else if (indexOF('/notifications')) {
  4734. curSite = DBSite.github_notifications;
  4735. } else if (indexOF('/search')) {
  4736. if (!location.search) return
  4737. if (!indexOF('type=', 's')) {
  4738. if (lp == '/search') {
  4739. curSite = DBSite.github_search_repositories;
  4740. } else {
  4741. curSite = DBSite.github_search_code;
  4742. }
  4743. } else {
  4744. curSite = DBSite['github_search_' + /type=[a-z]+/.exec(location.search.toLowerCase())[0].replace('type=','')];
  4745. }
  4746. if (curSite.SiteTypeID > 0 && !curSite.pager.nextL) {
  4747. curSite.pager.type = 1;
  4748. curSite.pager.nextL = 'css;a.next_page';
  4749. curSite.pager.replaceE = 'css;.pagination';
  4750. curSite.pager.scrollD = 3000;
  4751. }
  4752. }},
  4753. pager: {
  4754. type: 2,
  4755. nextL: 'css;.ajax-pagination-btn',
  4756. nextText: 'More',
  4757. scrollD: 2500
  4758. }
  4759. }, // Github - 首页
  4760. github_star: {
  4761. pager: {
  4762. type: 1,
  4763. nextL: '//div[@class="paginate-container"]//a[contains(text(), "Next")]',
  4764. pageE: 'css;#js-pjax-container .position-relative div[class^="col-lg-"] > div:not(.position-relative):not(.paginate-container)',
  4765. insertP: ['css;.paginate-container', 1],
  4766. replaceE: 'css;.paginate-container',
  4767. scrollD: 3000
  4768. }
  4769. }, // Github - 用户 Star 列表
  4770. github_repositories: {
  4771. pager: {
  4772. type: 1,
  4773. nextL: '//div[@class="paginate-container"]//a[contains(text(), "Next")]',
  4774. pageE: 'css;#user-repositories-list > ul > li',
  4775. replaceE: 'css;.paginate-container',
  4776. scrollD: 3000
  4777. }
  4778. }, // Github - 用户 项目 列表
  4779. github_issues: {
  4780. pager: {
  4781. type: 1,
  4782. nextL: 'css;a.next_page',
  4783. pageE: 'css;.js-navigation-container.js-active-navigation-container > div[id^="issue_"]',
  4784. replaceE: 'css;.pagination',
  4785. scrollD: 3000
  4786. }
  4787. }, // Github - Issues 列表 / PR 列表
  4788. github_discussions: {
  4789. pager: {
  4790. type: 1,
  4791. nextL: 'css;a.next_page',
  4792. pageE: 'css;ul[aria-labelledby="discussions-list"] > li',
  4793. replaceE: 'css;.pagination',
  4794. scrollD: 3000
  4795. }
  4796. }, // Github - Discussions 列表
  4797. github_releases: {
  4798. pager: {
  4799. type: 1,
  4800. nextL: 'css;a.next_page',
  4801. pageE: 'css;#repo-content-pjax-container > div[data-pjax] > div:not(.paginate-container)',
  4802. replaceE: 'css;.pagination',
  4803. scrollD: 3000
  4804. }
  4805. }, // Github - Releases 列表
  4806. github_tags: {
  4807. pager: {
  4808. type: 1,
  4809. nextL: '//div[@class="pagination"]/a[contains(text(), "Next")]',
  4810. pageE: 'css;.Box-body > div.Box-row',
  4811. replaceE: 'css;.pagination',
  4812. scrollD: 3000
  4813. }
  4814. }, // Github - Tags 列表
  4815. github_commits: {
  4816. pager: {
  4817. type: 1,
  4818. nextL: '//div[@class="paginate-container"]//a[contains(text(), "Older")]',
  4819. pageE: 'css;div.js-navigation-container > div',
  4820. replaceE: 'css;.paginate-container',
  4821. scrollD: 3000
  4822. }
  4823. }, // Github - Commits 列表
  4824. github_notifications: {
  4825. pager: {
  4826. type: 1,
  4827. nextL: 'css;nav.paginate-container > a[aria-label="Next"]',
  4828. pageE: 'css;li.notifications-list-item',
  4829. replaceE: 'css;nav.paginate-container, .js-notifications-list-paginator-counts',
  4830. scrollD: 3000
  4831. }
  4832. }, // Github - Notifications 列表
  4833. github_search_repositories: {
  4834. pager: {
  4835. pageE: 'css;ul.repo-list > li',
  4836. }
  4837. }, //Github - Search 列表
  4838. github_search_code: {
  4839. pager: {
  4840. pageE: 'css;.code-list-item',
  4841. }
  4842. }, // Github - Search 列表 - Code
  4843. github_search_commits: {
  4844. pager: {
  4845. pageE: 'css;#commit_search_results > div',
  4846. }
  4847. }, // Github - Search 列表 - Commit
  4848. github_search_issues: {
  4849. pager: {
  4850. pageE: 'css;.issue-list-item',
  4851. }
  4852. }, // Github - Search 列表 - Issues
  4853. github_search_discussions: {
  4854. pager: {
  4855. pageE: 'css;.discussion-list-item',
  4856. }
  4857. }, // Github - Search 列表 - Discussions
  4858. github_search_registrypackages: {
  4859. pager: {
  4860. pageE: 'css;#package_search_results > div',
  4861. }
  4862. }, // Github - Search 列表 - Package
  4863. github_search_marketplace: {
  4864. pager: {
  4865. pageE: 'css;#marketplace_search_results > div:first-child > div',
  4866. }
  4867. }, // Github - Search 列表 - Marketplace
  4868. github_search_topics: {
  4869. pager: {
  4870. pageE: 'css;.topic-list-item',
  4871. }
  4872. }, // Github - Search 列表 - Topics
  4873. github_search_wikis: {
  4874. pager: {
  4875. pageE: 'css;#wiki_search_results > div:first-child > div',
  4876. }
  4877. }, // Github - Search 列表 - wiki
  4878. github_search_users: {
  4879. pager: {
  4880. pageE: 'css;#user_search_results > div:first-child > div',
  4881. }
  4882. }, // Github - Search 列表 - user
  4883. oi_wiki: {
  4884. host: 'oi-wiki.org',
  4885. style: 'blockquote.page-copyright, h2#__comments, form#gitalk-form {display: none !important;} article.md-content__inner{min-height: 700px;}',
  4886. pager: {
  4887. type: 1,
  4888. nextL: 'css;li.md-nav__item.md-nav__item--active.md-nav__item--nested li.md-nav__item--active+li a',
  4889. pageE: 'css;article.md-content__inner',
  4890. insertP: ['css;article.md-content__inner', 6],
  4891. replaceE: 'css;.md-sidebar.md-sidebar--primary',
  4892. scrollD: 1300
  4893. }
  4894. }, // OI Wiki
  4895. guokr: {
  4896. host: 'www.guokr.com',
  4897. pager: {
  4898. type: 2,
  4899. nextL: 'css;div[class*="LoadMoreWrap"]',
  4900. interval: 1500,
  4901. scrollD: 1500
  4902. }
  4903. }, // 果壳网
  4904. landian: {
  4905. host: 'www.landian.vip',
  4906. functionS: function() {if (lp != '/' && !indexOF('/archives/') && !indexOF('/search/')) {curSite = DBSite.landian;}},
  4907. style: '.pagination {display: none !important;}',
  4908. pager: {
  4909. type: 1,
  4910. nextL: () => getNextUPN(/(?<=\/page\/)\d+/, /\/page\/\d+/, '/page/', '', '2', getCSS('.pagination > button.end').textContent),
  4911. pageE: 'css;.content li.color-border',
  4912. scrollD: 1500
  4913. }
  4914. }, // 蓝点网
  4915. kenengba: {
  4916. host: 'kenengba.com',
  4917. functionS: function() {if (lp == '/' || indexOF('/page/') || indexOF('/category/') || indexOF('/tag/')) {curSite = DBSite.kenengba;}},
  4918. pager: {
  4919. type: 1,
  4920. nextL: '//div[@class="pagebar"]/a[@href and text()=">>"]',
  4921. pageE: 'css;article.post',
  4922. replaceE: 'css;.pagebar',
  4923. scrollD: 3000
  4924. }
  4925. }, // 可能吧
  4926. expreview: {
  4927. host: 'www.expreview.com',
  4928. pager: {
  4929. type: 2,
  4930. nextL: 'css;#show_article_red_1SHOW',
  4931. interval: 1500,
  4932. scrollD: 1500
  4933. }
  4934. }, // 超能网
  4935. ithome: {
  4936. host: 'www.ithome.com',
  4937. pager: {
  4938. type: 2,
  4939. nextL: 'css;a.more',
  4940. interval: 1500,
  4941. scrollD: 1500
  4942. }
  4943. }, // IT之家
  4944. _36kr: {
  4945. host: ['36kr.com', 'www.36kr.com'],
  4946. functionS: function() {if (lp != '/' && !indexOF('/p/') && !indexOF('/newsflashes/')) {curSite = DBSite._36kr;}},
  4947. pager: {
  4948. type: 2,
  4949. nextL: 'css;.kr-loading-more-button.show',
  4950. nextText: '查看更多',
  4951. scrollD: 1500
  4952. }
  4953. }, // 36氪
  4954. _36kr_m: {
  4955. host: 'm.36kr.com',
  4956. pager: {
  4957. type: 2,
  4958. nextL: 'css;.kr-loading-more-button-default',
  4959. nextText: '查看更多',
  4960. scrollD: 1500
  4961. }
  4962. }, // 36氪 - 手机版
  4963. zhutix: {
  4964. host: 'zhutix.com',
  4965. functionS: function() {if (getCSS('#post-list')) {
  4966. curSite = DBSite.zhutix;
  4967. } else {
  4968. curSite = DBSite.zhutix_list;
  4969. }},
  4970. pager: {
  4971. type: 1,
  4972. nextL: '//li[@class="next-page"]/a | //div[@class="btn-pager"]/a[contains(text(), "❯")]',
  4973. pageE: 'css;#post-list > ul > li',
  4974. replaceE: 'css;.pagination, .b2-pagenav.post-nav',
  4975. scrollD: 1500
  4976. }
  4977. }, // 致美化
  4978. zhutix_list: {
  4979. pager: {
  4980. type: 1,
  4981. nextL: 'css;li.next-page a',
  4982. pageE: 'css;#primary-home > div:not(.pagination)',
  4983. replaceE: 'css;.pagination',
  4984. scrollD: 1500
  4985. }
  4986. }, // 致美化 - 文章列表
  4987. lanzou: {
  4988. host: /\.lanzou[a-z]\./,
  4989. hiddenPN: true,
  4990. pager: {
  4991. type: 2,
  4992. nextL: 'css;#filemore',
  4993. nextTextOf: '更多',
  4994. isHidden: true,
  4995. scrollD: 800
  4996. }
  4997. }, // 蓝奏云 - 分享链接列表
  4998. lanzou_: {
  4999. host: 'pc.woozooo.com',
  5000. iframe: true,
  5001. hiddenPN: true,
  5002. pager: {
  5003. type: 2,
  5004. nextL: 'css;#filemore > span[onclick]',
  5005. nextText: '显示更多文件',
  5006. isHidden: true,
  5007. scrollD: 800
  5008. }
  5009. }, // 蓝奏云 - 后台
  5010. alipanso: {
  5011. host: 'www.alipanso.com',
  5012. functionS: function() {if (lp == '/search.html') {curSite = DBSite.alipanso;}},
  5013. style: '.pager-wrap {display: none !important;}',
  5014. pager: {
  5015. type: 1,
  5016. nextL: () => getNextUP('page=', /page=\d+/),
  5017. pageE: 'css;#res_list > div',
  5018. scrollD: 2000
  5019. }
  5020. }, // 阿里盘搜
  5021. wikihow: {
  5022. host: ['www.wikihow.com', 'zh.wikihow.com'],
  5023. functionS: function() {if (indexOF('/Category:')) {
  5024. curSite = DBSite.wikihow;
  5025. } else if (indexOF('/wikiHowTo') && indexOF('?search=', 's')) {
  5026. curSite = DBSite.wikihow_search;
  5027. }},
  5028. pager: {
  5029. type: 1,
  5030. nextL: 'css;a.pag_next',
  5031. pageE: 'css;#cat_all > .cat_grid > div',
  5032. replaceE: 'css;#large_pagination',
  5033. scriptT: 3,
  5034. scrollD: 2000
  5035. }
  5036. }, // 指南
  5037. wikihow_search: {
  5038. pager: {
  5039. type: 1,
  5040. nextL: 'css;#searchresults_footer > a.buttonright',
  5041. pageE: 'css;#searchresults_list > a',
  5042. replaceE: 'css;#searchresults_footer',
  5043. scrollD: 3000
  5044. }
  5045. }, // 指南 - 搜索页
  5046. afreecatv: {
  5047. host: 'www.afreecatv.com',
  5048. pager: {
  5049. type: 2,
  5050. nextL: 'css;.btn-more > button',
  5051. interval: 2000,
  5052. scrollD: 1000
  5053. }
  5054. }, // 直播
  5055. greasyfork: {
  5056. host: 'greasyfork.org',
  5057. functionS: function() {if (indexOF(/\/scripts$/) || indexOF('/scripts/by-site/')) {
  5058. curSite = DBSite.greasyfork;
  5059. } else if (indexOF(/\/feedback$/)) {
  5060. curSite = DBSite.greasyfork_feedback;
  5061. } else if (indexOF('/discussions') && !indexOF(/\/\d+/)) {
  5062. curSite = DBSite.greasyfork_discussions;
  5063. }},
  5064. pager: {
  5065. type: 1,
  5066. nextL: 'css;a.next_page',
  5067. pageE: 'css;ol#browse-script-list > li',
  5068. replaceE: 'css;.pagination',
  5069. scrollD: 1300
  5070. }
  5071. }, // 脚本
  5072. greasyfork_feedback: {
  5073. pager: {
  5074. type: 1,
  5075. nextL: 'css;a.next_page',
  5076. pageE: 'css;.script-discussion-list > div',
  5077. replaceE: 'css;.pagination',
  5078. scrollD: 1800
  5079. }
  5080. }, // 脚本 - 反馈页
  5081. greasyfork_discussions: {
  5082. pager: {
  5083. type: 1,
  5084. nextL: 'css;a.next_page',
  5085. pageE: 'css;.discussion-list > div',
  5086. replaceE: 'css;.pagination',
  5087. scrollD: 1300
  5088. }
  5089. }, // 脚本 - 讨论页
  5090. userstyles: {
  5091. host: 'userstyles.world',
  5092. functionS: function() {if (lp == '/explore') {curSite = DBSite.userstyles;}},
  5093. pager: {
  5094. type: 1,
  5095. nextL: 'css;a.Pagination-button.next',
  5096. pageE: 'css;.card',
  5097. replaceE: 'css;.Pagination',
  5098. scrollD: 1500
  5099. }
  5100. }, // UserStyles
  5101. getquicker: {
  5102. host: 'getquicker.net',
  5103. functionS: function() {if (indexOF('/Share/')) {curSite = DBSite.getquicker;}},
  5104. pager: {
  5105. type: 1,
  5106. nextL: '//a[@class="page-link" and text()="下一页"]',
  5107. pageE: 'css;table.table > tbody > tr:not(:first-child), script[src^="/js/site.js"]',
  5108. insertP: ['css;table.table > tbody', 3],
  5109. replaceE: 'css;ul.pagination',
  5110. scriptT: 2,
  5111. scrollD: 1000
  5112. }
  5113. }, // Quicker
  5114. bookmarkearth: {
  5115. host: 'www.bookmarkearth.com',
  5116. functionS: function() {if (lp == '/' || lp == '/page') {
  5117. curSite = DBSite.bookmarkearth;
  5118. } else if (lp == '/s/search') {
  5119. curSite = DBSite.bookmarkearth_search;
  5120. }},
  5121. pager: {
  5122. type: 1,
  5123. nextL: () => getNextUP('currentPage=', /currentPage=\d+/, '/page', '2', getCSS('ul.pager').dataset.totalpage),
  5124. pageE: 'css;.document-piece',
  5125. replaceE: 'css;ul.pager',
  5126. scrollD: 1000
  5127. }
  5128. }, // 书签地球
  5129. bookmarkearth_search: {
  5130. pager: {
  5131. type: 1,
  5132. nextL: () => getNextEP('css;a.cut-page-item.active+a.cut-page-item', 'currentPage=', /currentPage=\d+/),
  5133. pageE: 'css;.document-piece',
  5134. replaceE: 'css;.cut-page',
  5135. scrollD: 1000
  5136. }
  5137. }, // 书签地球 - 搜索页
  5138. smzdm: {
  5139. host: ['www.smzdm.com', 'search.smzdm.com'],
  5140. functionS: function() {if (location.hostname === 'search.smzdm.com' || indexOF('/fenlei/') || indexOF(/\/mall\/.+\/.+/)) {curSite = DBSite.smzdm;}},
  5141. pager: {
  5142. type: 1,
  5143. nextL: '//ul[@class="pagenation-list"]//a[contains(text() ,"下一页")] | //ul[@class="pagenation-list"]/li[contains(@class, "next-page")]/a',
  5144. pageE: 'css;#feed-main-list > li',
  5145. replaceE: 'css;ul.pagenation-list',
  5146. scrollD: 1500
  5147. }
  5148. }, // 什么值得买 - 分类/搜索页
  5149. meidebi: {
  5150. host: 'www.meidebi.com',
  5151. functionS: function() {if (indexOF('/fenlei/') || lp == '/Search') {
  5152. curSite = DBSite.meidebi;
  5153. }},
  5154. pager: {
  5155. type: 1,
  5156. nextL: 'css;a.next',
  5157. pageE: 'css;.share-list > ul > li',
  5158. replaceE: 'css;.h-pages',
  5159. scrollD: 1500
  5160. }
  5161. }, // 没得比 - 分类/搜索页
  5162. ruyile_xuexiao: {
  5163. host: 'www.ruyile.com',
  5164. functionS: function() {
  5165. if (lp == '/xuexiao/') {
  5166. curSite = DBSite.ruyile_xuexiao;
  5167. } else if (lp == '/data/') {
  5168. curSite = DBSite.ruyile_data;
  5169. } else if (lp == '/shijuan/') {
  5170. curSite = DBSite.ruyile_shijuan;
  5171. }},
  5172. pager: {
  5173. type: 1,
  5174. nextL: '//div[@class="fy"]/a[contains(text(), "下一页")]',
  5175. pageE: 'css;.xxlb > .sk',
  5176. insertP: ['css;.xxlb', 3],
  5177. replaceE: 'css;.fy',
  5178. scrollD: 1000
  5179. }
  5180. }, // 如意了教育 - 学校
  5181. ruyile_data: {
  5182. pager: {
  5183. type: 1,
  5184. nextL: '//div[@class="fy"]/a[contains(text(), "下一页")]',
  5185. pageE: 'css;.m1_z > .lbk',
  5186. insertP: ['css;.page', 1],
  5187. replaceE: 'css;.fy',
  5188. scrollD: 1000
  5189. }
  5190. }, // 如意了教育 - 数据
  5191. ruyile_shijuan: {
  5192. pager: {
  5193. type: 1,
  5194. nextL: '//div[@class="fy"]/a[contains(text(), "下一页")]',
  5195. pageE: 'css;.m1_z > .m2_lb',
  5196. insertP: ['css;.page', 1],
  5197. replaceE: 'css;.fy',
  5198. scrollD: 1000
  5199. }
  5200. }, // 如意了教育 - 试卷
  5201. che168: {
  5202. host: 'www.che168.com',
  5203. functionS: function() {
  5204. if (location.pathname != '/' && !indexOF('/dealer/')) {
  5205. curSite = DBSite.che168;
  5206. }},
  5207. pager: {
  5208. type: 1,
  5209. nextL: 'css;a.page-item-next',
  5210. pageE: 'css;ul.viewlist_ul > li',
  5211. replaceE: 'css;.page',
  5212. scrollD: 2000
  5213. }
  5214. }, // 二手车之家
  5215. jiligamefun: {
  5216. host: 'www.jiligamefun.com',
  5217. functionS: function() {if (indexOF('/category/')) {curSite = DBSite.jiligamefun;}},
  5218. pager: {
  5219. type: 1,
  5220. nextL: 'css;a.poi-pager__item.poi-pager__item_next',
  5221. pageE: 'css;.inn-archive__container > article',
  5222. replaceE: 'css;.poi-pager',
  5223. scrollD: 1800
  5224. }
  5225. }, // 叽哩叽哩日报
  5226. wendangku: {
  5227. host: 'www.wendangku.net',
  5228. functionS: function() {if (indexOF('/doc/')) {curSite = DBSite.wendangku;}},
  5229. pager: {
  5230. type: 1,
  5231. nextL: 'css;a.next',
  5232. pageE: 'css;#contents > *:not(.pages)',
  5233. replaceE: 'css;.pages',
  5234. scrollD: 1800
  5235. }
  5236. }, // 文档库
  5237. oshwhub: {
  5238. host: 'www.oshwhub.com',
  5239. functionS: function() {if (lp == '/explore') {curSite = DBSite.oshwhub;}},
  5240. pager: {
  5241. type: 1,
  5242. nextL: 'css;a.current+a',
  5243. pageE: 'css;.each-project',
  5244. replaceE: 'css;.page',
  5245. scriptT: 0,
  5246. scrollD: 1200
  5247. }
  5248. }, // 立创开源硬件平台
  5249. netbian: {
  5250. host: 'pic.netbian.com',
  5251. style: 'li.nextpage {display: none !important;}',
  5252. pager: {
  5253. type: 1,
  5254. nextL: '//div[@class="page"]/a[contains(text(),"下一页")]',
  5255. pageE: 'css;.slist ul > li:not(.nextpage)',
  5256. replaceE: 'css;.page',
  5257. scrollD: 1000
  5258. }
  5259. }, // 彼岸图网
  5260. ioliu: {
  5261. host: 'bing.ioliu.cn',
  5262. functionS: function() {if (!indexOF('/photo/') && !indexOF('.html')) {curSite = DBSite.ioliu; document.head.appendChild(document.createElement('base')).target = '_blank';}},
  5263. style: '.progressive--not-loaded {filter: none !important;}',
  5264. pager: {
  5265. type: 1,
  5266. nextL: '//div[@class="page"]/a[contains(text(), "下一页")]',
  5267. pageE: 'css;body > .container > div.item',
  5268. replaceE: 'css;.page',
  5269. scrollD: 1000
  5270. }
  5271. }, // 必应壁纸
  5272. konachan: {
  5273. host: 'konachan.net',
  5274. functionS: function() {if (indexOF('/post')) {curSite = DBSite.konachan; document.head.appendChild(document.createElement('base')).target = '_blank';}},
  5275. 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;}',
  5276. pager: {
  5277. type: 1,
  5278. nextL: 'css;a.next_page',
  5279. pageE: 'css;ul#post-list-posts > li',
  5280. replaceE: 'css;#paginator',
  5281. scrollD: 1000
  5282. }
  5283. }, // 动漫壁纸
  5284. nastol: {
  5285. host: 'www.nastol.com.ua',
  5286. pager: {
  5287. type: 1,
  5288. nextL: '//a[./span[@class="nav-next"]]',
  5289. pageE: 'css;#dle-content > div',
  5290. replaceE: 'css;.navigation',
  5291. scrollD: 1000
  5292. }
  5293. }, // 壁纸
  5294. hdqwalls: {
  5295. host: 'hdqwalls.com',
  5296. pager: {
  5297. type: 1,
  5298. nextL: 'css;a#next',
  5299. pageE: 'css;.wallpapers_container > div.wall-resp',
  5300. replaceE: 'css;ul.pagination',
  5301. scrollD: 1000
  5302. }
  5303. }, // 壁纸
  5304. xinpianchang: {
  5305. host: 'www.xinpianchang.com',
  5306. style: '.lazy-img {opacity: 1 !important;}',
  5307. pager: {
  5308. type: 1,
  5309. nextL: 'css;.page > a[title="下一页"]',
  5310. pageE: 'css;div[class*="-container"] div[class*="-con"] > ul > li, div[class*="-container"] div[class*="-con"] > div[class*="-wrap"] > ul > li',
  5311. insertP: ['css;div[class*="-container"] div[class*="-con"] > ul, div[class*="-container"] div[class*="-con"] > div[class*="-wrap"] > ul', 3],
  5312. replaceE: 'css;.page',
  5313. scrollD: 2000
  5314. },
  5315. function: {
  5316. bF: src_bF,
  5317. pF: [0, 'img[_src]', '_src']
  5318. }
  5319. }, // 新片场
  5320. tujigu: {
  5321. host: ['www.tuji001.com', 'www.tujigu.net'],
  5322. functionS: function() {
  5323. if (indexOF('/a/')) {
  5324. curSite = DBSite.tujigu;
  5325. } else if (location.pathname != '/' && !indexOF('/search/')) {
  5326. curSite = DBSite.tujigu_list;
  5327. }},
  5328. style: '.content img {display: block !important;}',
  5329. pager: {
  5330. type: 1,
  5331. nextL: 'id("pages")/a[contains(text(), "下一页")]',
  5332. pageE: 'css;.content > img',
  5333. replaceE: 'css;#pages',
  5334. scrollD: 2000
  5335. }
  5336. }, // tujigu - 图片页
  5337. tujigu_list: {
  5338. pager: {
  5339. type: 1,
  5340. nextL: 'id("pages")/a[contains(text(), "下一页")]',
  5341. pageE: 'css;.hezi > ul > li',
  5342. insertP: ['//div[@class="hezi"][last()]/ul', 3],
  5343. replaceE: 'css;#pages',
  5344. scrollD: 1000
  5345. }
  5346. }, // tujigu - 分类页
  5347. mvtui: {
  5348. host: 'mvtui.com',
  5349. functionS: function() {if (indexOF('.html')) {curSite = DBSite.mvtui;} else {curSite = DBSite.mvtui_list;}},
  5350. pager: {
  5351. type: 1,
  5352. nextL: 'css;.article-paging span.current+a',
  5353. pageE: 'css;.article-content > p',
  5354. replaceE: 'css;.article-paging',
  5355. scrollD: 3000
  5356. }
  5357. }, // mvtui - 图片页
  5358. mvtui_list: {
  5359. pager: {
  5360. type: 1,
  5361. nextL: 'css;li.next-page a',
  5362. pageE: 'css;#posts > div',
  5363. replaceE: 'css;.pagination',
  5364. scrollD: 1500
  5365. },
  5366. function: {
  5367. bF: src_bF,
  5368. pF: [0, 'img[data-src]', 'data-src']
  5369. }
  5370. }, // mvtui - 分类页
  5371. mzitu: {
  5372. host: 'www.mzitu.com',
  5373. functionS: function() {if (indexOF(/\/\d+/)) {curSite = DBSite.mzitu;getCSS('.main-image a[href]').href = 'javascript:void(0);'} else {curSite = DBSite.mzitu_list;}},
  5374. pager: {
  5375. type: 1,
  5376. nextL: '//div[@class="pagenavi"]/a[contains(string(), "下一页")]',
  5377. pageE: 'css;.main-image img',
  5378. replaceE: 'css;.pagenavi',
  5379. scrollD: 1500
  5380. }
  5381. }, // mzitu - 图片页
  5382. mzitu_list: {
  5383. pager: {
  5384. type: 1,
  5385. nextL: 'css;.next.page-numbers',
  5386. pageE: 'css;.postlist > ul > li',
  5387. replaceE: 'css;.pagination',
  5388. scrollD: 1000
  5389. },
  5390. function: {
  5391. bF: src_bF,
  5392. pF: [0, 'img[data-original]', 'data-original']
  5393. }
  5394. }, // mzitu - 分类/搜索页
  5395. xiurenji: {
  5396. host: /\.xiuren[a-z]+\./,
  5397. functionS: function() {insStyle('img[src$=".gif"]:not([src*="logo"]) {display: none !important;}');
  5398. if (indexOF('.html') && !indexOF('/index')) {
  5399. curSite = DBSite.xiurenji;
  5400. } else if (indexOF('search')) {
  5401. curSite = DBSite.xiurenji_search;
  5402. } else {
  5403. curSite = DBSite.xiurenji_list;
  5404. }},
  5405. pager: {
  5406. type: 1,
  5407. nextL: '//div[@class="page"]/a[text()="下页"]',
  5408. pageE: 'css;div.content > p > *',
  5409. replaceE: 'css;.page',
  5410. scrollD: 1500
  5411. }
  5412. }, // xiurenji - 图片页
  5413. xiurenji_list: {
  5414. pager: {
  5415. type: 1,
  5416. nextL: '//div[@class="page"]/a[text()="下页"]',
  5417. pageE: 'css;li.i_list',
  5418. replaceE: 'css;.page',
  5419. scrollD: 1000
  5420. }
  5421. }, // xiurenji - 分类页
  5422. xiurenji_search: {
  5423. pager: {
  5424. type: 1,
  5425. nextL: 'css;.page > a.current+a',
  5426. pageE: 'css;.node > *',
  5427. replaceE: 'css;.page',
  5428. scrollD: 700
  5429. }
  5430. }, // xiurenji - 搜索页
  5431. tvv: {
  5432. host: /\.tvv\.tw/,
  5433. functionS: function() {if (lp == '/' || indexOF('/page/') || indexOF('/category/')) {curSite = DBSite.tvv;}},
  5434. 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;}',
  5435. pager: {
  5436. type: 1,
  5437. nextL: 'css;a.next',
  5438. pageE: 'css;.blog-listing',
  5439. replaceE: 'css;.pagination',
  5440. scrollD: 2000
  5441. }
  5442. }, // tvv
  5443. mm131: {
  5444. host: ['www.mm131.net', 'www.mmm131.com'],
  5445. functionS: function() {if (indexOF('.html')) {curSite = DBSite.mm131;} else {curSite = DBSite.mm131_list;}},
  5446. retry: 300,
  5447. pager: {
  5448. type: 1,
  5449. nextL: '//div[@class="content-page"]/a[contains(text(), "下一页")]',
  5450. pageE: 'css;.content-pic img',
  5451. replaceE: 'css;.content-page',
  5452. scrollD: 2000
  5453. }
  5454. }, // MM131 - 图片页
  5455. mm131_list: {
  5456. pager: {
  5457. type: 1,
  5458. nextL: '//dd[@class="page"]/a[contains(text(), "下一页")]',
  5459. pageE: 'css;dl.list-left > dd:not([class="page"])',
  5460. replaceE: 'css;.page',
  5461. scrollD: 1000
  5462. }
  5463. }, // MM131 - 分类页
  5464. mm131_m: {
  5465. host: 'm.mmm131.com',
  5466. 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;}},
  5467. retry: true,
  5468. pager: {
  5469. type: 1,
  5470. nextL: '//div[@class="paging"]/a[text()="下一张" or text()="下一页"]',
  5471. pageE: 'css;.post-content img',
  5472. replaceE: 'css;.paging',
  5473. scrollD: 2000
  5474. }
  5475. }, // MM131 - 手机版 - 图片页
  5476. mm131_m_list: {
  5477. pager: {
  5478. type: 1,
  5479. nextL: 'css;#xbtn',
  5480. pageE: 'css;#content > article',
  5481. replaceE: 'css;#webpage',
  5482. scrollD: 2000
  5483. },
  5484. function: {
  5485. bF: src_bF,
  5486. pF: [0, 'img[data-img]', 'data-img']
  5487. }
  5488. }, // MM131 - 手机版 - 分类页
  5489. mm131_m_: {
  5490. pager: {
  5491. type: 2,
  5492. nextL: 'css;#webpage>span[onclick]',
  5493. isHidden: true,
  5494. interval: 500,
  5495. scrollD: 2000
  5496. }
  5497. }, // MM131 - 手机版 - 首页
  5498. mrcong: {
  5499. host: 'mrcong.com',
  5500. functionS: function() {if (lp == '/' || indexOF('/tag/')) {curSite = DBSite.mrcong_list;} else {curSite = DBSite.mrcong;}},
  5501. pager: {
  5502. type: 1,
  5503. nextL: 'css;.post-page-numbers.current+a.post-page-numbers',
  5504. pageE: 'css;#fukie2 > p > img',
  5505. replaceE: 'css;.page-link',
  5506. scrollD: 3000
  5507. }
  5508. }, // MrCong - 图片页
  5509. mrcong_list: {
  5510. pager: {
  5511. type: 3,
  5512. nextL: 'css;.current+a.page',
  5513. pageE: 'css;article.item-list',
  5514. scrollE: 'css;.pagination',
  5515. replaceE: 'css;.pagination',
  5516. scrollD: 2000
  5517. }
  5518. }, // MrCong - 分类页
  5519. buondua: {
  5520. host: 'buondua.com',
  5521. functionS: function() {if (indexOF(/-photos-\d+/)) {curSite = DBSite.buondua;} else {curSite = DBSite.buondua_list;}},
  5522. pager: {
  5523. type: 3,
  5524. nextL: '//nav[@class="pagination"]//span[./a[contains(@class, "is-current")]]/following-sibling::span[1]/a',
  5525. pageE: 'css;.article-fulltext > p',
  5526. scrollE: 'css;nav.pagination',
  5527. replaceE: 'css;nav.pagination',
  5528. scrollD: 1500
  5529. },
  5530. function: {
  5531. bF: src_bF,
  5532. pF: [0, 'img[data-src]', 'data-src']
  5533. }
  5534. }, // Buon Dua - 图片页
  5535. buondua_list: {
  5536. pager: {
  5537. type: 3,
  5538. nextL: 'css;.pagination-next',
  5539. pageE: 'css;.items-row.column, .collection-item.column',
  5540. scrollE: 'css;nav.pagination',
  5541. replaceE: 'css;nav.pagination',
  5542. scrollD: 1200
  5543. },
  5544. function: {
  5545. bF: src_bF,
  5546. pF: [0, 'img[data-src]', 'data-src']
  5547. }
  5548. }, // Buon Dua - 分类页
  5549. fnvshen: {
  5550. host: 'www.fnvshen.com',
  5551. functionS: function() {
  5552. if (indexOF('/gallery/') || indexOF('/tag/')) {
  5553. curSite = DBSite.fnvshen_list;
  5554. } else if (indexOF('/g/')) {
  5555. curSite = DBSite.fnvshen;
  5556. } else if (indexOF(/\/article\/\d+\//)) {
  5557. curSite = DBSite.fnvshen_article;
  5558. } else if (indexOF('/article/')) {
  5559. curSite = DBSite.fnvshen_article_list;
  5560. }},
  5561. pager: {
  5562. type: 1,
  5563. nextL: 'css;#pages > span +a:not(.a1)',
  5564. pageE: 'css;#hgallery > img',
  5565. replaceE: 'css;#pages',
  5566. scrollD: 1500
  5567. }
  5568. }, // fnvshen - 图片页
  5569. fnvshen_list: {
  5570. style: '.yalayi_box {display: none !important; margin: -4px 0 !important;}',
  5571. pager: {
  5572. type: 1,
  5573. nextL: '//div[@class="pagesYY"]//a[contains(text(), "下一页")]',
  5574. pageE: 'css;#listdiv > ul > li',
  5575. replaceE: 'css;.pagesYY',
  5576. scrollD: 1000
  5577. },
  5578. function: {
  5579. bF: src_bF,
  5580. pF: [0, 'img[data-original]', 'data-original']
  5581. }
  5582. }, // fnvshen - 分类页
  5583. fnvshen_article_list: {
  5584. pager: {
  5585. type: 1,
  5586. nextL: '//div[@class="pagesYY"]//a[contains(text(), "下一页")]',
  5587. pageE: 'css;li.other_girlli',
  5588. replaceE: 'css;.pagesYY',
  5589. scrollD: 1000
  5590. }
  5591. }, //fnvshen - 文章列表
  5592. fnvshen_article: {
  5593. pager: {
  5594. type: 1,
  5595. nextL: 'css;.pagesYY a.cur+a',
  5596. pageE: 'css;#articleDiv',
  5597. insertP: ['css;#articleDiv', 6],
  5598. replaceE: 'css;.pagesYY',
  5599. scrollD: 1000
  5600. }
  5601. }, // fnvshen - 文章内
  5602. xrmn5: {
  5603. host: 'www.xrmn5.cc',
  5604. functionS: function() {if (indexOF(/\d+\.html/)) {
  5605. curSite = DBSite.xrmn5;
  5606. } else if (indexOF('/search')) {
  5607. curSite = DBSite.xrmn5_search;
  5608. } else {
  5609. curSite = DBSite.xrmn5_list;
  5610. }},
  5611. pager: {
  5612. type: 1,
  5613. nextL: '//div[contains(@class, "page")]//a[contains(text(), "下页")]',
  5614. pageE: 'css;.content_left > p > img',
  5615. replaceE: 'css;.page',
  5616. scrollD: 3000
  5617. }
  5618. }, // xrmn5 - 图片页
  5619. xrmn5_list: {
  5620. pager: {
  5621. type: 1,
  5622. nextL: '//div[contains(@class, "page")]//a[contains(text(), "下页")]',
  5623. pageE: 'css;ul.update_area_lists > li',
  5624. replaceE: 'css;.page',
  5625. scrollD: 2000
  5626. }
  5627. }, // xrmn5 - 分类页
  5628. xrmn5_search: {
  5629. pager: {
  5630. type: 1,
  5631. nextL: 'css;.page a.current+a',
  5632. pageE: 'css;div.sousuo',
  5633. replaceE: 'css;.page',
  5634. scrollD: 2000
  5635. }
  5636. }, // xrmn5 - 搜索页
  5637. jpmn8: {
  5638. host: 'www.jpmn8.com',
  5639. functionS: function() {if (indexOF(/\/\d+\.html/)) {curSite = DBSite.jpmn8;} else if (location.pathname != '/') {curSite = DBSite.jpmn8_list;}},
  5640. style: 'img[onload] {min-height: 500px;}',
  5641. pager: {
  5642. type: 1,
  5643. nextL: '//div[@class="pagination1"]//a[text()="下一页"]',
  5644. pageE: 'css;img[onload]',
  5645. replaceE: 'css;.pagination1',
  5646. scrollD: 3000
  5647. }
  5648. }, // jpmn8 - 图片页
  5649. jpmn8_list: {
  5650. pager: {
  5651. type: 1,
  5652. nextL: '//div[@class="pagination1"]//a[text()="下一页"]',
  5653. pageE: 'css;article.excerpt',
  5654. replaceE: 'css;.pagination1',
  5655. scrollD: 1500
  5656. }
  5657. }, // jpmn8 - 分类页
  5658. ku66: {
  5659. host: 'www.ku66.net',
  5660. functionS: function() {if (/\/\d+\.html/.test(location.pathname)) {curSite = DBSite.ku66;} else {curSite = DBSite.ku66_list;}},
  5661. style: '.content img {min-height: 500px;}',
  5662. pager: {
  5663. type: 1,
  5664. nextL: '//div[@class="NewPages"]//a[text()="下一页"]',
  5665. pageE: 'css;.content > img',
  5666. insertP: ['css;.content', 3],
  5667. replaceE: 'css;.NewPages',
  5668. scrollD: 4000
  5669. }
  5670. }, // ku66 - 图片页
  5671. ku66_list: {
  5672. pager: {
  5673. type: 1,
  5674. nextL: '//div[@class="NewPages"]//a[text()="下一页"]',
  5675. pageE: 'css;.TypeList > ul > li',
  5676. insertP: ['css;.TypeList > ul', 3],
  5677. replaceE: 'css;.NewPages',
  5678. scrollD: 1000
  5679. }
  5680. }, // ku66 - 分类页
  5681. ku66_m: {
  5682. host: 'm.ku66.net',
  5683. functionS: function() {if (/\/\d+\.html/.test(location.pathname)) {curSite = DBSite.ku66_m;} else {curSite = DBSite.ku66_m_list;}},
  5684. style: '.ArticleImageBox img {min-height: 200px;}',
  5685. pager: {
  5686. type: 1,
  5687. nextL: '//div[@class="article_page"]//a[text()="下一页"]',
  5688. pageE: 'css;.ArticleImageBox > *',
  5689. replaceE: 'css;.article_page',
  5690. scrollD: 4000
  5691. }
  5692. }, // ku66 - 手机版 - 图片页
  5693. ku66_m_list: {
  5694. pager: {
  5695. type: 1,
  5696. nextL: '//div[@class="article_page"]//a[text()="下一页"]',
  5697. pageE: 'css;.PictureList > ul > li',
  5698. replaceE: 'css;.article_page',
  5699. scrollD: 1000
  5700. }
  5701. }, // ku66 - 手机版 - 分类页
  5702. ku137: {
  5703. host: 'www.ku137.net',
  5704. functionS: function() {if (indexOF(/\/\d+\.html/)) {curSite = DBSite.ku137;} else if (location.pathname != '/') {curSite = DBSite.ku137_list;}},
  5705. style: '.Title9, .dibu1, .dibu2 {display: none !important;} .content img {min-height: 500px;}',
  5706. pager: {
  5707. type: 1,
  5708. nextL: '//div[@class="page"]/a[text()="下一页"]',
  5709. pageE: 'css;.content > img',
  5710. replaceE: 'css;.page',
  5711. scrollD: 3000
  5712. }
  5713. }, // ku137 - 图片页
  5714. ku137_list: {
  5715. pager: {
  5716. type: 1,
  5717. nextL: '//div[@class="page"]/a[text()="下一页"]',
  5718. pageE: 'css;.m-list > ul > li',
  5719. replaceE: 'css;.page',
  5720. scrollD: 1500
  5721. }
  5722. }, // ku137 - 分类页
  5723. ku137_m: {
  5724. host: 'm.ku137.net',
  5725. functionS: function() {if (indexOF(/\/\d+\.html/)) {curSite = DBSite.ku137_m;} else if (location.pathname != '/') {curSite = DBSite.ku137_m_list;}},
  5726. style: '.ArticleImageBox img {min-height: 300px;}',
  5727. pager: {
  5728. type: 1,
  5729. nextL: '//div[@class="article_page"]//a[text()="下一页"]',
  5730. pageE: 'css;.ArticleImageBox > *',
  5731. replaceE: 'css;.article_page',
  5732. scrollD: 3000
  5733. }
  5734. }, // ku137 - 手机版 - 图片页
  5735. ku137_m_list: {
  5736. pager: {
  5737. type: 1,
  5738. nextL: '//div[@class="article_page"]//a[text()="下一页"]',
  5739. pageE: 'css;.PictureList > ul > li',
  5740. replaceE: 'css;.article_page',
  5741. scrollD: 1500
  5742. }
  5743. }, // ku137 - 手机版 - 分类页
  5744. mnttz: {
  5745. host: 'www.mnttz.com',
  5746. functionS: function() {if (indexOF(/\/\d+\.html/)) {curSite = DBSite.mnttz;} else {curSite = DBSite.mnttz_list;}},
  5747. style: 'img.content_img {min-height: 500px;}',
  5748. pager: {
  5749. type: 1,
  5750. nextL: 'css;.article-paging > span+a',
  5751. pageE: 'css;img.content_img',
  5752. replaceE: 'css;.article-paging',
  5753. scrollD: 3000
  5754. }
  5755. }, // mnttz - 图片页
  5756. mnttz_list: {
  5757. pager: {
  5758. type: 1,
  5759. nextL: 'css;li.next-page > a',
  5760. pageE: 'css;article.excerpt',
  5761. replaceE: 'css;.pagination',
  5762. scrollD: 1500
  5763. },
  5764. function: {
  5765. bF: src_bF,
  5766. pF: [0, 'img[data-src]', 'data-src']
  5767. }
  5768. }, // mnttz - 分类页
  5769. kingdom: {
  5770. host: /kingdom-en\.com/,
  5771. functionS: function() {if (indexOF(/\/\d+\.html/)) {curSite = DBSite.kingdom;} else {curSite = DBSite.kingdom_list;}},
  5772. style: '.pic_center img {min-height: 300px;} .arcmain > .title, .footer, .index-list-title, .listmain_st {display: none !important;}',
  5773. pager: {
  5774. type: 1,
  5775. nextL: '//a[@class="page_next"] | //div[@class="article_page"]//a[text()="下一页"]',
  5776. pageE: 'css;.pic_center img',
  5777. replaceE: '//div[@class="pages2" or @class="article_page"]',
  5778. scrollD: 4000
  5779. }
  5780. }, // kingdom - 图片页
  5781. kingdom_list: {
  5782. pager: {
  5783. type: 1,
  5784. nextL: () => getCSS('a.page_next').href.replace(/(www.)?ermo.net/, location.hostname).replace(/http(s)?:/, location.protocol),
  5785. pageE: 'css;.channel_list3 > ul > li, ul#container > li',
  5786. replaceE: 'css;.pages, .list_page',
  5787. scrollD: 1000
  5788. }
  5789. }, // kingdom - 分类页
  5790. kissgoddess: {
  5791. host: /kissgoddess\./,
  5792. functionS: function() {if (indexOF('/album/') || indexOF('/category/')) curSite = DBSite.kissgoddess;},
  5793. style: '.td-gallery-content > img {min-height: 300px;}',
  5794. pager: {
  5795. type: 1,
  5796. nextL: 'css;a.a1:last-of-type',
  5797. pageE: 'css;.td-gallery-content > img, .td-category-span',
  5798. replaceE: 'css;#pages',
  5799. scrollD: 3000
  5800. },
  5801. function: {
  5802. bF: src_bF,
  5803. pF: [0, 'img[data-original]', 'data-original']
  5804. }
  5805. }, // Kiss Goddess - 图片页
  5806. planetminecraft: {
  5807. host: 'www.planetminecraft.com',
  5808. functionS: function() {if (!indexOF('/forums/') && !indexOF('/posts/')) {curSite = DBSite.planetminecraft;}},
  5809. style: '.resource .r-preview>a img[loading=lazy]:not(.lazyloaded) {visibility: initial !important;}',
  5810. pager: {
  5811. type: 1,
  5812. nextL: 'css;a.pagination_next',
  5813. pageE: 'css;.resource_block > ul.resource_list > li',
  5814. replaceE: 'css;.pagination',
  5815. scrollD: 3000
  5816. }
  5817. }, // Planet Minecraft
  5818. cadtutor: {
  5819. host: 'www.cadtutor.net',
  5820. functionS: function() {
  5821. if (indexOF('/forum/forum/')) {
  5822. curSite = DBSite.cadtutor;
  5823. } else if (indexOF('/forum/topic/') && GM_getValue('menu_thread')) {
  5824. curSite = DBSite.cadtutor_post;
  5825. } else if (indexOF('/forum/search/')) {
  5826. curSite = DBSite.cadtutor_search;
  5827. }},
  5828. pager: {
  5829. type: 1,
  5830. nextL: 'css;a[rel="next"]',
  5831. pageE: 'css;ol.ipsDataList > li:not([data-rowid])~li',
  5832. replaceE: 'css;ul.ipsPagination',
  5833. scrollD: 2000
  5834. }
  5835. }, // CADTutor - 列表页
  5836. cadtutor_post: {
  5837. pager: {
  5838. type: 1,
  5839. nextL: 'css;a[rel="next"]',
  5840. pageE: 'css;#elPostFeed > form > *:not(input):not(.after-first-post)',
  5841. replaceE: 'css;ul.ipsPagination',
  5842. scrollD: 2000
  5843. }
  5844. }, // CADTutor - 帖子内
  5845. cadtutor_search: {
  5846. pager: {
  5847. type: 1,
  5848. nextL: 'css;a[rel="next"]',
  5849. pageE: 'css;ol.ipsStream > li',
  5850. replaceE: 'css;ul.ipsPagination',
  5851. scrollD: 2000
  5852. }
  5853. }, // CADTutor - 搜索页
  5854. theswamp: {
  5855. host: 'www.theswamp.org',
  5856. functionS: function() {
  5857. if (!location.search) return
  5858. if (indexOF('board=', 's')) {
  5859. curSite = DBSite.theswamp;
  5860. } else if (indexOF('topic=', 's') && GM_getValue('menu_thread')) {
  5861. curSite = DBSite.theswamp_post;
  5862. }},
  5863. pager: {
  5864. type: 1,
  5865. nextL: 'css;.pagelinks > strong+a',
  5866. pageE: 'css;#messageindex tbody > tr:not([class])',
  5867. replaceE: 'css;.pagelinks',
  5868. scrollD: 2000
  5869. }
  5870. }, // TheSwamp - 列表页
  5871. theswamp_post: {
  5872. pager: {
  5873. type: 1,
  5874. nextL: 'css;.pagelinks > strong+a',
  5875. pageE: 'css;#forumposts form > *',
  5876. replaceE: 'css;.pagelinks',
  5877. scrollD: 2000
  5878. }
  5879. } // TheSwamp - 帖子内
  5880. };
  5881. // 生成 SiteTypeID
  5882. setSiteTypeID();
  5883. // 用于脚本判断(针对部分特殊的网站)
  5884. SiteType = {
  5885. BAIDU_TIEBA: DBSite.baidu_tieba.SiteTypeID
  5886. };
  5887. }
  5888.  
  5889.  
  5890. if (webType != 1) {
  5891. switch (webType) {
  5892. case 2: // < 所有 Discuz!论坛 >
  5893. discuz_(); break;
  5894. case 3: // < 所有 Flarum 论坛 >
  5895. DBSite.flarum.functionS(); break;
  5896. case 4: // < 所有 phpBB 论坛 >
  5897. DBSite.phpbb.functionS(); break;
  5898. case 5: // < 所有 Xiuno 论坛 >
  5899. DBSite.xiuno.functionS(); break;
  5900. case 6: // < 所有 XenForo 论坛 >
  5901. DBSite.xenforo.functionS(); break;
  5902. case 7: // < 所有 NexusPHP 论坛 >
  5903. DBSite.nexusphp.functionS(); break;
  5904. case 100: // < 所有使用 WordPress DUX 主题的网站 >
  5905. DBSite.dux.functionS(); if (location.hostname === 'apphot.cc') {curSite.pager.scrollD = 2500;}; break;
  5906. case 101: // < 所有使用 WordPress XIU 主题的网站 >
  5907. DBSite.dux.functionS(); curSite.function = {bF: src_bF, pF: [0, 'img.thumb[data-original]', 'data-original']}; break;
  5908. case 102: // < 所有使用 WordPress D8 主题的网站 >
  5909. DBSite.dux.functionS(); delete curSite.function; break;
  5910. case 103: // < 所有使用 WordPress Begin 主题的网站 >
  5911. DBSite.begin.functionS(); break;
  5912. case 200: // < 所有使用 笔趣阁 模板的小说网站 >
  5913. DBSite.biquge.functionS(); break;
  5914. }
  5915. }
  5916.  
  5917. // 显示页码
  5918. if (GM_getValue('menu_page_number')) {pageNumber('add');} else {pageNumber('set');}
  5919. // 左键双击网页空白处暂停翻页
  5920. pausePageEvent();
  5921. // 强制新标签页打开链接(翻页模式 5/6)
  5922. if (curSite.forceTarget) forceTarget();
  5923.  
  5924. // 对于使用 pjax 技术的网站,需要监听 URL 变化来重新判断翻页规则
  5925. if (locationC) {
  5926. nowLocation = location.href
  5927. if (window.onurlchange === undefined) {addUrlChangeEvent();} // Tampermonkey v4.11 版本添加的 onurlchange 事件 grant,可以监控 pjax 等网页的 URL 变化
  5928. if (webType === 1) {
  5929. window.addEventListener('urlchange', function(){
  5930. lp = location.pathname;
  5931. //console.log(nowLocation, location.href)
  5932. if (curSite.history !== false && window.top.document.xiu_nowUrl === location.href) {nowLocation = location.href; return}
  5933. if (nowLocation == location.href) return
  5934. if (curSite.pager && curSite.pager.type == 5) {
  5935. if (self != top) {window.top.location.href = location.href;} else {if (getCSS('iframe#xiu_iframe')) {getCSS('iframe#xiu_iframe').remove();}}
  5936. pausePage = true;
  5937. } // 对于翻页模式 5,如果是 iframe 框架内 URL 变动,则升级为顶级页面,如果是顶级页面的 URL 变动,则清理 iframe 框架
  5938. nowLocation = location.href; curSite = {SiteTypeID: 0}; pageNum.now = 1; // 重置规则+页码
  5939. registerMenuCommand(); // 重新判断规则
  5940. //console.log(curSite);
  5941. if (curSite.style) {insStyle(curSite.style)} // 插入 Style CSS 样式
  5942. curSite.pageUrl = ''; // 下一页URL
  5943. pageLoading(); // 自动无缝翻页
  5944.  
  5945. if (GM_getValue('menu_page_number')) {pageNumber('add');} else {pageNumber('set');} // 显示页码
  5946. pausePageEvent(); // 左键双击网页空白处暂停翻页
  5947. })
  5948. } else if (webType === 3) {
  5949. window.addEventListener('urlchange', function(){
  5950. lp = location.pathname;
  5951. if (nowLocation == location.href) return
  5952. nowLocation = location.href; curSite = {SiteTypeID: 0}; pageNum.now = 1; // 重置规则+页码
  5953. DBSite.flarum.functionS(); // 重新判断规则
  5954. if (curSite.style) {insStyle(curSite.style)} // 插入 Style CSS 样式
  5955. pageLoading(); // 自动无缝翻页
  5956.  
  5957. if (GM_getValue('menu_page_number')) {pageNumber('add');} else {pageNumber('set');} // 显示页码
  5958. pausePageEvent(); // 左键双击网页空白处暂停翻页
  5959. })
  5960. }
  5961. }
  5962. // 插入 Style CSS 样式
  5963. if (curSite.style) insStyle(curSite.style)
  5964.  
  5965. // 对翻页模式 5 的子 iframe 添加一个跟随滚动的事件
  5966. if (curSite.pager && curSite.pager.type === 5 && self != top) {
  5967. var beforeScrollTop = document.documentElement.scrollTop || document.body.scrollTop
  5968. window.addEventListener('scroll', function (e) {
  5969. let scrollTop = window.parent.document.documentElement.scrollTop || window.parent.document.body.scrollTop,
  5970. clientHeight = window.parent.document.documentElement.clientHeight || window.parent.document.body.clientHeight,
  5971. scrollHeight = window.parent.document.documentElement.scrollHeight || window.parent.document.body.scrollHeight,
  5972. afterScrollTop = document.documentElement.scrollTop || document.body.scrollTop,
  5973. delta = afterScrollTop - beforeScrollTop;
  5974. if (delta == 0) return false;
  5975. beforeScrollTop = afterScrollTop;
  5976. //console.log(delta, scrollHeight - (scrollTop + clientHeight), '2222')
  5977. if (delta > 0 && scrollTop + clientHeight < scrollHeight) {
  5978. window.parent.scrollBy(0, delta*2);
  5979. }
  5980. }, false);
  5981. }
  5982.  
  5983. curSite.pageUrl = ''; // 下一页URL
  5984. //console.log(curSite);
  5985. pageLoading(); // 自动无缝翻页
  5986.  
  5987.  
  5988. // --------------------------------------------------------
  5989.  
  5990.  
  5991. // [Discuz! 论坛] 判断各版块帖子列表类型
  5992. function discuzForum() {
  5993. if (getCSS('#autopbn')) { // 判断是否有 [下一页] 按钮
  5994. curSite = DBSite.discuz_forum;
  5995. } else if (getCSS('#waterfall')) { // 判断是否为图片模式
  5996. if (!getCSS('#pgbtn, .pgbtn')) { // 如果各版块帖子列表已存在这个元素,说明自带了无缝翻页
  5997. curSite = DBSite.discuz_waterfall; waterfallStyle(); // 图片模式列表样式预处理
  5998. }
  5999. } else {
  6000. curSite = DBSite.discuz_guide;
  6001. }
  6002. }
  6003. function discuz_() {
  6004. if (getCSS('body[id="nv_forum"][class^="pg_"][onkeydown*="27"]')) {
  6005. switch (getCSS('body[id="nv_forum"][class^="pg_"][onkeydown*="27"]').className) {
  6006. case 'pg_forumdisplay': // < 各版块帖子列表 >
  6007. discuzForum(); break;
  6008. case 'pg_viewthread': // < 帖子内 >
  6009. if (GM_getValue('menu_thread')) curSite = DBSite.discuz_thread; break;
  6010. case 'pg_guide': // < 导读帖子列表等 >
  6011. curSite = DBSite.discuz_guide; break;
  6012. case 'pg_collection': // < 淘贴列表 >
  6013. curSite = DBSite.discuz_collection; break;
  6014. }
  6015. }
  6016. // 如果上面没有匹配的则继续 < 搜索结果 >
  6017. if (curSite.SiteTypeID === 0) {
  6018. if (indexOF('search') || getCSS('body[id="nv_search"][onkeydown*="27"]')) {
  6019. curSite = DBSite.discuz_search;
  6020. }
  6021. }
  6022. // 如果上面没有匹配的则继续
  6023. if (curSite.SiteTypeID === 0) {
  6024. if (indexOF('.html')) { // 判断是不是静态网页(.html 结尾)
  6025. if (indexOF('/forum-')) { // < 各版块帖子列表 >
  6026. discuzForum();
  6027. } else if (indexOF('/thread-')) { // < 帖子内 >
  6028. if (GM_getValue('menu_thread')) curSite = DBSite.discuz_thread;
  6029. }
  6030. }
  6031. }
  6032. // 如果上面没有匹配的则继续
  6033. if (curSite.SiteTypeID === 0) {
  6034. if (indexOF('mod=forumdisplay', 's') || indexOF('forumdisplay.php')) { // < 各版块帖子列表 >
  6035. discuzForum();
  6036. } else if (indexOF('mod=viewthread', 's') || indexOF('viewthread.php')) { // < 帖子内 >
  6037. if (GM_getValue('menu_thread')) curSite = DBSite.discuz_thread;
  6038. } else if (indexOF('mod=guide', 's')) { // < 导读帖子列表 >
  6039. curSite = DBSite.discuz_guide;
  6040. } else if(indexOF('mod=space', 's') && indexOF('do=thread', 's')) { // 别人的主题/回复
  6041. curSite = DBSite.discuz_youspace;
  6042. } else if (indexOF('mod=collection', 's')) { // < 淘贴列表 >
  6043. curSite = DBSite.discuz_collection;
  6044. } else if (getCSS('#threadlist')) { // < 部分论坛的各板块 URL 是自定义的 >
  6045. discuzForum();
  6046. } else if (getCSS('#postlist')) { // < 部分论坛的帖子内 URL 是自定义的 >
  6047. if (GM_getValue('menu_thread')) curSite = DBSite.discuz_thread;
  6048. }
  6049. }
  6050. }
  6051. // [Discuz! 论坛] 图片模式列表样式预处理
  6052. function waterfallStyle() {
  6053. let width = getCSS('#waterfall > li:first-child').style.width;
  6054. 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;}`);
  6055. }
  6056.  
  6057.  
  6058. // [谷歌搜索] 的插入前函数(加载视频图片)
  6059. function google_bF(pageElems) {
  6060. if (!indexOF('tbm=nws', 's')){
  6061. pageElems.forEach(function (one) {
  6062. getAllCSS('a[aria-label][href*="https://www.youtube.com/watch?v="]').forEach(function (one1) {
  6063. let img = getCSS('img', one1)
  6064. if (img) img.src = `https://i.ytimg.com/vi/${one1.href.split('?v=')[1]}/mqdefault.jpg`
  6065. })
  6066. });
  6067. }
  6068. return pageElems
  6069. }
  6070.  
  6071.  
  6072. // [必应搜索] 的插入前函数(加载网站图标)
  6073. function bing_bF(pageElems) {
  6074. if (!getCSS('.b_title > a.sh_favicon')) {
  6075. insStyle('.b_title > a.sh_favicon {display: none !important;}');
  6076. delete curSite.function
  6077. console.log(curSite)
  6078. return pageElems
  6079. }
  6080. pageElems.forEach(function (one) {
  6081. getAllCSS('div.rms_iac[data-src]').forEach(function (one1) {
  6082. one1.outerHTML = `<img src="${one1.dataset.src}" height="16" width="16" alt="全球 Web 图标" role="presentation" class="rms_img">`;
  6083. })
  6084. });
  6085. return pageElems
  6086. }
  6087.  
  6088.  
  6089. // [头条搜索] 的插入前函数(过滤相关搜索)
  6090. function toutiao_bF(pageElems) {
  6091. if (getXpath('//div[contains(@class,"-header") and string()="相关搜索"]', pageElems[pageElems.length - 1])) pageElems[pageElems.length - 1].style.display = 'none';
  6092. return pageElems
  6093. }
  6094.  
  6095.  
  6096. // [Startpage] 获取下一页地址
  6097. function startpage_nextL() {
  6098. let form = getXpath('//div[contains(@class, "pagination ")]/form[./button[@class="pagination__next-prev-button next"]]'), value;
  6099. if (form) {
  6100. form.querySelectorAll('input[name]').forEach(function(input) {value += input.name + '=' + input.value + '&';}) // 生成表单参数
  6101. value = encodeURI(value.replace(/&$/,'')); // 清理最后一个 & 符号
  6102. if (form.action && value) return (form.action + '?' + value)
  6103. }
  6104. return '';
  6105. }
  6106.  
  6107.  
  6108. // [SkrBT] 获取下一页地址
  6109. function skrbt_nextL() {
  6110. let page = getCSS('a[onclick][aria-label="Next"]');
  6111. if (page) {page = /(?<=\()\d+(?=\))/.exec(page.onclick)[0];} else {return '';} // 获取下一页页码
  6112. if (page) {
  6113. let action = getCSS('#search-form').action, value = ''; // 获取提交表单 URL
  6114. getAllCSS('#search-form input[name]').forEach(function(input) {value += input.name + '=' + input.value + '&';}) // 生成表单参数
  6115. value = encodeURI(value.replace(/&$/,'').replace(/p=\d+/,'p=' + page)); // 清理最后一个 & 符号,并替换页码
  6116. if (action && value) return (action + '?' + value)
  6117. }
  6118. return '';
  6119. }
  6120.  
  6121.  
  6122. // [百度贴吧](发帖按钮点击事件)
  6123. function baidu_tieba_1() {
  6124. let button = getCSS('.tbui_aside_fbar_button.tbui_fbar_post > a');
  6125. if (button) {
  6126. button.remove();
  6127. 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>')
  6128. button = getCSS('.tbui_aside_fbar_button.tbui_fbar_post > a');
  6129. if (button) {
  6130. button.onclick = function(){
  6131. let button2 = getCSS('div.edui-btn.edui-btn-fullscreen.edui-btn-name-portrait');
  6132. if (button2) {button2.click();} else {alert('提示:登录后才能发帖!');}
  6133. return false;
  6134. }
  6135. }
  6136. }
  6137. }
  6138. // [百度贴吧] 插入数据
  6139. function baidu_tieba_insertE(pageElems, type) {
  6140. if (!pageElems) return
  6141. // 获取 <script> 内容
  6142. const scriptElems = getXpath(`//script[contains(text(), 'Bigpipe.register("frs-list/pagelet/thread_list", ')]`, pageElems, pageElems);
  6143. if (scriptElems) {
  6144. // 从 <script> 中提取帖子列表字符串
  6145. let scriptText = scriptElems.textContent.replace('Bigpipe.register("frs-list/pagelet/thread_list", ','');
  6146. scriptText = scriptText.slice(0, scriptText.indexOf(').'));
  6147. // 字符串转 Element 元素
  6148. let temp_baidu_tieba = document.createElement('div'); temp_baidu_tieba.innerHTML = JSON.parse(scriptText).content;
  6149. processElems(temp_baidu_tieba);
  6150. }
  6151. }
  6152.  
  6153.  
  6154. // [V2EX] 的插入后函数(新标签页打开链接)
  6155. function v2ex_aF(css) {
  6156. let links = getAllCSS(css);if (!links) return
  6157. links.forEach(function (_this) {_this.target = '_blank';});
  6158. }
  6159.  
  6160.  
  6161. // [龙的天空] 获取下一页地址
  6162. function lkong_nextL() {
  6163. let next = getCSS('li.ant-pagination-next'), page;
  6164. if (next && next.getAttribute('aria-disabled') === 'false') {
  6165. page = getCSS('li.ant-pagination-item-active[title]');
  6166. if (page && page.title) {
  6167. return (location.origin + location.pathname + '?page=' + ++page.title);
  6168. }
  6169. }
  6170. return '';
  6171. }
  6172.  
  6173.  
  6174. // [游民星空-攻略] 的插入前函数(移除下一页底部的 "更多相关内容请关注:xxx" 文字 + 加载图片)
  6175. function gamersky_gl_bF(pageElems) {
  6176. pageElems.forEach(function (one) {if (one.tagName === 'P' && one.textContent.indexOf('更多相关内容请关注') > -1) {one.style.display = 'none';}});
  6177. return src_bF(pageElems, [0, 'img[data-src]', 'data-src'])
  6178. }
  6179.  
  6180.  
  6181. // [NexusMods] 获取下一页地址
  6182. function nexusmods_nextL() {
  6183. if (getCSS('.nexus-ui-blocker')) return
  6184. let modList;
  6185. if (indexOF('/news')) {modList = RH_NewsTabContent;} else {modList = RH_ModList;}
  6186. let out_items = JSON.stringify(modList.out_items).replace(/{|}|"/g,''),
  6187. nextNum = getXpath('//div[contains(@class, "pagenav")][1]//a[contains(@class, "page-selected")]/parent::li/following-sibling::li/a'),
  6188. categories = modList.out_items.categories, categoriesUrl = '';
  6189. var url = '';
  6190. if (nextNum && nextNum.innerText) {
  6191. nextNum = nextNum.innerText;
  6192. if (out_items.indexOf('page:') > -1) {
  6193. out_items = out_items.replace(/page:\d+/, `page:${nextNum}`)
  6194. } else {
  6195. out_items += `,page:${nextNum}`;
  6196. }
  6197. if (categories && categories != []) {
  6198. for (let i = 0; i < categories.length; i++) {
  6199. categoriesUrl += `,categories[]:${categories[i]}`
  6200. }
  6201. categoriesUrl = categoriesUrl.replace(/,/,'');
  6202. if (out_items.indexOf('categories:') > -1) {
  6203. out_items = out_items.replace(/categories:\[.*\]/, categoriesUrl)
  6204. }
  6205. }
  6206. return `https://www.nexusmods.com${modList.uri}?RH_${modList.id}=${out_items}`
  6207. }
  6208. return ''
  6209. }
  6210. // [NexusMods] 的插入前函数(隐藏底部元素)
  6211. function nexusmods_bF(pageElems) {
  6212. pageElems.forEach(function (one) {
  6213. let now = one.querySelector('.mod-tile-left');
  6214. if (now) {
  6215. let downloadCount = now.querySelector('.downloadcount > span.flex-label');
  6216. if (downloadCount) {
  6217. if (GlobalModStats[now.dataset.gameId] && GlobalModStats[now.dataset.gameId][now.dataset.modId]) {
  6218. downloadCount.textContent = shortFormat(parseInt(GlobalModStats[now.dataset.gameId][now.dataset.modId].total));
  6219. }
  6220. }
  6221. }
  6222. });
  6223. return pageElems
  6224. }
  6225.  
  6226.  
  6227. // [cs_rin_ru] 各版块帖子列表的插入前函数(过滤置顶帖子)
  6228. function cs_rin_ru_bF(pageElems) {
  6229. for (let i = 0; i < pageElems.length; i++) {
  6230. if (pageElems[i].textContent.replace(/\n| /g,'') === 'Topics') {
  6231. pageElems.splice(0,i+1);
  6232. break;
  6233. }
  6234. }
  6235. return pageElems
  6236. }
  6237.  
  6238.  
  6239. // [bilibili_search] 获取下一页地址
  6240. function bilibili_search_nextL() {
  6241. if (!location.search) return
  6242. let pageActive = 1, pageLast = parseInt(getXpath('//ul[@class="pages"]/li[contains(@class, "page-item")][not(contains(@class, "next") or contains(@class, "prev"))][last()]').innerText);
  6243. if (!pageLast) return
  6244. if (indexOF(/page=\d+/, 's')) {
  6245. pageActive = parseInt(/page=\d+/.exec(location.search)[0].replace('page=',''))
  6246. }
  6247. if (pageActive < pageLast) {
  6248. if (indexOF(/page=\d+/, 's')) {
  6249. return (location.origin + location.pathname + location.search.replace(/page=\d+/,`page=${pageActive+1}`))
  6250. } else {
  6251. return (location.origin + location.pathname + location.search + `&page=${pageActive+1}`)
  6252. }
  6253. }
  6254. }
  6255. // [bilibili_search] 插入前函数(加载图片)
  6256. function bilibili_search_bF(pageElems) {
  6257. pageElems.forEach(function (one) {
  6258. let img = getCSS('.img > .lazy-img > img[src=""]', one)
  6259. if (img) {
  6260. img.setAttribute('data-srclz', 'lazy')
  6261. }
  6262. });
  6263. return pageElems
  6264. }
  6265. // [bilibili_search] 插入后函数(加载图片)
  6266. function bilibili_search_aF() {
  6267. let result = __INITIAL_STATE__.flow[__INITIAL_STATE__.flow.fields[0]].result;
  6268. if (result.length > 0) {
  6269. let imgArr = getAllCSS('.img > .lazy-img > img[data-srclz]');
  6270. if (imgArr.length > 0) {
  6271. for (let i = 0; i < imgArr.length; i++) {
  6272. imgArr[i].src = result[i].pic;
  6273. imgArr[i].removeAttribute('data-srclz');
  6274. }
  6275. }
  6276. }
  6277. }
  6278.  
  6279.  
  6280. // [Anime1] 获取下一页内容(叠加)
  6281. function anime1_nextL() {
  6282. let next = getCSS('a.paginate_button.next');
  6283. if (next && next.className.indexOf('disabled') === -1) {
  6284. let oldList = getCSS('#table-list > tbody').innerHTML;
  6285. if (oldList) {
  6286. next.click();
  6287. pageNum.now = pageNum._now + 1;
  6288. getCSS('#table-list > tbody').insertAdjacentHTML('afterbegin', oldList); // 插入到列表头部
  6289. }
  6290. }
  6291. }
  6292.  
  6293.  
  6294. // [BTHaha] 的插入前函数(隐藏底部元素)
  6295. function bthaha_bF(pageElems) {
  6296. pageElems.forEach(function (one) {
  6297. let now = one.querySelector('[id^="list_top"], [id^="list_bottom"]')
  6298. if (now) {one.hidden = true;}
  6299. });
  6300. return pageElems
  6301. }
  6302.  
  6303.  
  6304. // [RARBG] 的插入前函数(鼠标指向显示封面)
  6305. function rarbg_bF(pageElems) {
  6306. pageElems.forEach(function (one) {
  6307. one.querySelectorAll('td > a[onmouseover][onmouseout]').forEach(function (now) {
  6308. now.parentElement.parentElement.setAttribute('onmouseover', now.getAttribute('onmouseover')); now.removeAttribute('onmouseover');
  6309. now.parentElement.parentElement.setAttribute('onmouseout', now.getAttribute('onmouseout')); now.removeAttribute('onmouseout');
  6310. });
  6311. });
  6312. return pageElems
  6313. }
  6314.  
  6315.  
  6316. // [LRepacks] 的插入前函数(调整 class)
  6317. function lrepacks_bF(pageElems) {
  6318. pageElems.forEach(function (one) {
  6319. let now = one.querySelector('.slideUp, .elementFade')
  6320. if (now) {
  6321. now.className = now.className.replace('slideUp','slideUpRun').replace('elementFade','elementFadeRun');
  6322. }
  6323. });
  6324. return pageElems
  6325. }
  6326.  
  6327.  
  6328. // [漫画狂] 获取下一页地址
  6329. function cartoonmad_nextL() {
  6330. let url = getXpath('//a[@class="pages"][contains(text(),"下一頁")]');
  6331. if (url) {
  6332. if (url.getAttribute('href') === 'thend.asp') {
  6333. url = getXpath('//a[@class="pages"][contains(string(),"下一話")]')
  6334. if (url) return url.href;
  6335. pausePage = false;
  6336. GM_notification({text: `注意:该网站早期漫画(如海贼王、柯南)因为网站自身问题而无法翻至下一话(仅限于显示为 [第 X 卷]/[下一卷] 的)。\n因此需要手动去 [目录页] 进入下一卷!`, timeout: 10000});
  6337. } else {
  6338. return url.href;
  6339. }
  6340. }
  6341. return '';
  6342. }
  6343.  
  6344.  
  6345. // [漫画猫] 初始化(显示本话所以图片)
  6346. function manhuacat_init() {
  6347. let _img = '';
  6348. for (let now of img_data_arr) {_img += `<img src="${asset_domain}${img_pre}${now}">`;}
  6349. getOne(curSite.pager.insertP[0]).innerHTML = _img;
  6350.  
  6351. }
  6352. // [漫画猫] 获取下一页地址
  6353. function manhuacat_nextL(pageElems, type) {
  6354. if (type === 'url') {
  6355. if(pageElems.code == '0000') {
  6356. if (pageElems.url === curSite.pageUrl) return
  6357. curSite.pageUrl = pageElems.url;
  6358. getPageElems_(curSite.pageUrl); // 真正的下一页链接
  6359. }
  6360. } else {
  6361. let vg_r_data = getCSS('.vg-r-data');
  6362. if (vg_r_data) {
  6363. getPageElems_(`${location.origin}/chapter_num?chapter_id=${vg_r_data.dataset.chapter_num}&ctype=1&type=${vg_r_data.dataset.chapterType};`, 'json', 'GET', '', 'url');
  6364. }
  6365. }
  6366. }
  6367. // [漫画猫] 插入数据
  6368. function manhuacat_insertE(pageElems, type) {
  6369. if (!pageElems) return
  6370. if (type === 'url') { // 获取下一页链接
  6371. manhuacat_nextL(pageElems, type); return
  6372. }
  6373. addHistory(pageElems);
  6374. replaceElems(pageElems);
  6375.  
  6376. // 插入图片
  6377. 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');;
  6378. for (let now of _img_arr) {_img += `<img src="${vg_r_data.dataset.chapterDomain}${img_pre}${now}">`;}
  6379. if (_img) {
  6380. getOne(curSite.pager.insertP[0]).insertAdjacentHTML(getAddTo(curSite.pager.insertP[1]), _img); // 将 img 标签插入到网页中
  6381. pageNum.now = pageNum._now + 1
  6382. }
  6383. }
  6384.  
  6385.  
  6386. // [漫画柜] 初始化(将本话其余图片插入网页中)
  6387. function manhuagui_init() {
  6388. // hook imgDate 代码
  6389. SMH.imgData = function(n) {window['imgDate'] = n;return{preInit:function(){}}}
  6390. // 重新执行本页的 imgDate 代码
  6391. insScript(curSite.pager.pageE);
  6392. let _img = '', imgPath = `${location.protocol}//i.hamreus.com${window['imgDate'].path}`;
  6393. //console.log(imgPath, window['imgDate'])
  6394. if (!(window['imgDate']) || !(imgPath)) return
  6395. // 遍历图片文件名数组,组合为 img 标签
  6396. 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}">`;}
  6397. // 插入并覆盖原来的一个图片
  6398. getOne(curSite.pager.insertP[0]).innerHTML = _img;
  6399. pausePage = true;
  6400. }
  6401. // [漫画柜] 获取下一页地址
  6402. function manhuagui_nextL() {
  6403. if (window['imgDate'].nextId == 0) return
  6404. var url = location.origin + location.pathname.replace(window['imgDate'].cid.toString(), window['imgDate'].nextId.toString())
  6405. if (url === curSite.pageUrl) return
  6406. curSite.pageUrl = url
  6407. getPageElems_(curSite.pageUrl);
  6408. }
  6409. // [漫画柜] 插入数据
  6410. function manhuagui_insertE(pageElems, type) {
  6411. if (!pageElems) return
  6412. // 重新执行本页的 imgDate 代码
  6413. insScript(curSite.pager.pageE, document.body, pageElems);
  6414. let _img = '', imgPath = `${location.protocol}//i.hamreus.com${window['imgDate'].path}`;
  6415. //console.log(imgPath, window['imgDate'])
  6416. if (!(window['imgDate']) || !(imgPath)) return
  6417. // 遍历图片文件名数组,组合为 img 标签
  6418. 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}">`;}
  6419. getOne(curSite.pager.insertP[0]).insertAdjacentHTML(getAddTo(curSite.pager.insertP[1]), _img);
  6420. addHistory(pageElems);
  6421. pageNum.now = pageNum._now + 1
  6422. }
  6423.  
  6424.  
  6425. // [爱漫画] 初始化(调整本话其余图片)
  6426. function imanhuaw_init() {
  6427. let _img = '';
  6428. for (let one of base64_decode(qTcms_S_m_murl_e).split("$qingtiandy$")) {_img += `<img src="${one}">`;}
  6429. getOne(curSite.pager.insertP[0]).outerHTML = _img;
  6430. }
  6431. // [爱漫画] 获取下一页地址
  6432. function imanhuaw_nextL() {
  6433. let next = location.origin + qTcms_Pic_nextArr
  6434. if (next && next != location.origin && next != curSite.pageUrl) {
  6435. curSite.pageUrl = next;
  6436. getPageElems_(curSite.pageUrl);
  6437. }
  6438. }
  6439. // [爱漫画] 插入数据
  6440. function imanhuaw_insertE(pageElems, type) {
  6441. if (!pageElems) return
  6442. // 插入并运行 <script>
  6443. insScript('//head/script[not(@src)][contains(text(), "qTcms_S_m_murl_e")]', document.body, pageElems);
  6444.  
  6445. // 插入图片
  6446. let _img = '';
  6447. for (let one of base64_decode(qTcms_S_m_murl_e).split("$qingtiandy$")) {_img += `<img src="${one}">`;}
  6448. if (_img) {
  6449. // 将 img 标签插入到网页中
  6450. getOne(curSite.pager.insertP[0]).insertAdjacentHTML(getAddTo(curSite.pager.insertP[1]), _img);
  6451. addHistory(pageElems);
  6452. pageNum.now = pageNum._now + 1
  6453. }
  6454. }
  6455.  
  6456.  
  6457. // [漫画 DB] 初始化(将本话其余图片插入网页中)
  6458. function manhuadb_init() {
  6459. let _img = '', data = getCSS('.vg-r-data'), imgDate;
  6460. if (!data) return
  6461. getAllCSS(curSite.pager.pageE.replace('css;', '')).forEach(function (one) {
  6462. if (one.tagName === 'SCRIPT' && one.textContent.indexOf('var img_data =') > -1) {
  6463. let json = JSON.parse(window.atob(one.textContent.split("'")[1]));
  6464. if (json) {
  6465. let _img = '';
  6466. 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}">`;}
  6467. getOne(curSite.pager.insertP[0]).insertAdjacentHTML(getAddTo(curSite.pager.insertP[1]), _img); // 将 img 标签插入到网页中
  6468. }
  6469. }
  6470. })
  6471. }
  6472. // [漫画 DB] 获取下一页地址
  6473. function manhuadb_nextL() {
  6474. let nextArr = getAllCSS('a.fixed-a-es'), next;
  6475. var url = '';
  6476. if (nextArr.length == 0) return
  6477. for (let i = 0; i < nextArr.length; i++) {
  6478. if (nextArr[i].className.indexOf('active') > -1) {
  6479. if (nextArr[i+1]) url = nextArr[i+1].href;
  6480. break;
  6481. }
  6482. }
  6483. if (url === curSite.pageUrl) return
  6484. curSite.pageUrl = url
  6485. getPageElems_(curSite.pageUrl);
  6486. }
  6487. // [漫画 DB] 插入数据
  6488. function manhuadb_insertE(pageElems, type) {
  6489. if (!pageElems) return
  6490. if (replaceElems(pageElems, curSite.pager.pageE, curSite.pager.pageE)) {
  6491. addHistory(pageElems);
  6492. pageNum.now = pageNum._now + 1
  6493. manhuadb_init(); // 将刚刚替换的图片插入网页中
  6494. }
  6495. }
  6496.  
  6497.  
  6498. // [HiComic(嗨漫画)] 初始化(将本话其余图片插入网页中)
  6499. function hicomic_init() {
  6500. let _img = '';
  6501. getAllCSS('.chapter > section:not(:first-child) > section[val]').forEach(function (one) {
  6502. let src = one.getAttribute('val');
  6503. if (src.indexOf('!p_c_c_') === -1) src += '!p_c_c_h'
  6504. _img += `<img src="${src}">`
  6505. })
  6506. getOne(curSite.pager.insertP[0]).insertAdjacentHTML(getAddTo(curSite.pager.insertP[1]), _img); // 将 img 标签插入到网页中
  6507. window.document.title = window.document.title.replace(/(\(第.+\))? - HiComic/, `(${getCSS('.chapter_name').textContent}) - HiComic`); // 修改网页标题(加上 第 X 话)
  6508. }
  6509. // [HiComic(嗨漫画)] 获取下一页地址
  6510. function hicomic_nextL() {
  6511. let nextId;
  6512. nextId = getCSS('.next_chapter:not(.end)')
  6513. if (nextId && nextId.id && nextId.id != 'None') {
  6514. curSite.pageUrl = location.href;
  6515. getPageElems_(`https://www.hicomic.net/api/web/chapter/${nextId.id}/contents`, 'json');
  6516. }
  6517. }
  6518. // [HiComic(嗨漫画)] 插入数据
  6519. function hicomic_insertE(pageElems, type) {
  6520. if (!pageElems || pageElems.code != 200) return
  6521. if (pageElems.results.chapter.next) { // 写入下一页的 UUID
  6522. getCSS('.next_chapter').id = pageElems.results.chapter.next;
  6523. } else {
  6524. getCSS('.next_chapter').id = 'None';
  6525. getCSS('.next_chapter').classList.add('end');
  6526. }
  6527. curSite.pageUrl =`https://www.hicomic.net/chapters/${pageElems.results.chapter.uuid}/contents`
  6528. getCSS('.chapter_name').textContent = pageElems.results.chapter.name; // 修改漫画标题
  6529. addHistory(pageElems, window.document.title.replace(/(\(第.+\))? - HiComic/, `(${pageElems.results.chapter.name}) - HiComic`));
  6530. let _img = '';
  6531. for (let i = 0; i < pageElems.results.chapter.contents.length; i++) { // 遍历图片文件名数组,组合为 img 标签
  6532. let src = pageElems.results.chapter.contents[i].url;
  6533. if (src.indexOf('!p_c_c_') === -1) src += '!p_c_c_h';
  6534. _img += `<img src="${src}">`
  6535. }
  6536. getOne(curSite.pager.insertP[0]).insertAdjacentHTML(getAddTo(curSite.pager.insertP[1]), _img); // 将 img 标签插入到网页中
  6537. pageNum.now = pageNum._now + 1
  6538. }
  6539.  
  6540.  
  6541. // [动漫之家] 初始化(调整本话其余图片)
  6542. function dmzj_init(css) {
  6543. let _img = '';
  6544. getAllCSS(css).forEach(function (one) {_img += `<img src="${one.dataset.original}">`;})
  6545. getOne(curSite.pager.insertP[0]).innerHTML = _img;
  6546. }
  6547. // [动漫之家] 插入数据
  6548. function dmzj_insertE(pageElems, type) {
  6549. if (!pageElems) return
  6550. // 插入并运行 <script>
  6551. insScript('css;head > script[type]:not([src])', document.body, pageElems);
  6552.  
  6553. // 插入图片
  6554. let _img = '', _img_arr;
  6555. if (pages.indexOf('|') === -1) {
  6556. _img_arr = JSON.parse(pages.replace(/\r\n/g,'|')).page_url.split('|');
  6557. } else {
  6558. _img_arr = JSON.parse(pages).page_url.split('|');
  6559. }
  6560. for (let now of _img_arr) {
  6561. _img += `<img src="${img_prefix}${now}">`;
  6562. }
  6563. if (_img) {
  6564. getOne(curSite.pager.insertP[0]).insertAdjacentHTML(getAddTo(curSite.pager.insertP[1]), _img); // 将 img 标签插入到网页中
  6565. addHistory(pageElems);
  6566. if (replaceElems(pageElems)) pageNum.now = pageNum._now + 1
  6567. }
  6568. }
  6569. // [动漫之家-漫画] 插入数据
  6570. function dmzj_manhua_insertE(pageElems, type) {
  6571. if (!pageElems) return
  6572. // 插入并运行 <script>
  6573. insScript('css;head > script[type]:not([src])', document.body, pageElems);
  6574.  
  6575. // 插入图片
  6576. let _img = '';
  6577. for (let now of arr_pages) {
  6578. _img += `<img src="${img_prefix}${now}">`;
  6579. }
  6580. if (_img) {
  6581. getOne(curSite.pager.insertP[0]).insertAdjacentHTML(getAddTo(curSite.pager.insertP[1]), _img); // 将 img 标签插入到网页中
  6582. addHistory(pageElems);
  6583. if (replaceElems(pageElems)) pageNum.now = pageNum._now + 1
  6584. }
  6585. }
  6586.  
  6587.  
  6588. // [优酷漫画] 初始化(调整本话其余图片)
  6589. function ykmh_init(css) {
  6590. let host = SinMH.getChapterImage(1).split('/')[0] + '//' + SinMH.getChapterImage(1).split('/')[2];
  6591. if (!host) return
  6592. let _img = '';
  6593. for (let one of chapterImages) {_img += `<img src="${host}${one}">`;}
  6594. getOne(curSite.pager.insertP[0]).innerHTML = _img;
  6595. }
  6596. // [优酷漫画] 获取下一页地址
  6597. function ykmh_nextL() {
  6598. let url = comicUrl + nextChapterData.id + '.html'
  6599. if (url && url != '.html' && url != curSite.pageUrl) {
  6600. curSite.pageUrl = url;
  6601. getPageElems_(curSite.pageUrl);
  6602. }
  6603. }
  6604. // [优酷漫画] 插入数据
  6605. function ykmh_insertE(pageElems, type) {
  6606. //console.log(pageElems)
  6607. if (!pageElems) return
  6608. // 插入并运行 <script>
  6609. insScript('//script[contains(text(),"chapterImages")]', document.body, pageElems);
  6610.  
  6611. let host = SinMH.getChapterImage(1).split('/')[0] + '//' + SinMH.getChapterImage(1).split('/')[2];
  6612. if (!host) host = document.querySelector(curSite.pager.insertP[0]).src.split('/')[0] + '//' + document.querySelector(curSite.pager.insertP[0]).src.split('/')[2]
  6613. // 插入图片
  6614. let _img = '';
  6615. for (let one of chapterImages) {_img += `<img src="${host}${one}">`;}
  6616. if (_img) {
  6617. getOne(curSite.pager.insertP[0]).insertAdjacentHTML(getAddTo(curSite.pager.insertP[1]), _img); // 将 img 标签插入到网页中
  6618. addHistory(pageElems);
  6619. if (replaceElems(pageElems)) pageNum.now = pageNum._now + 1
  6620. }
  6621. }
  6622.  
  6623.  
  6624. // [动漫戏说] 插入后函数(加载图片)
  6625. function acgn_aF() {
  6626. let old = getAllCSS('.pic[_src][id]'), _img = '';
  6627. if (old.length > 0) {
  6628. for (let now of old) {now.outerHTML = `<div class="pic" _src="${now.getAttribute('_src')}"><img src="${now.getAttribute('_src')}" class="img1"></div>`;}
  6629. }
  6630. }
  6631.  
  6632.  
  6633. // [漫画星球] 插入数据
  6634. function mhxqiu_insertE(pageElems, type) {
  6635. if (!pageElems) return
  6636. // 插入并运行 <script>
  6637. insScript('//script[contains(text(), "eval") and contains(text(), "newImgs")]', document.body, pageElems);
  6638.  
  6639. // 插入图片
  6640. let _img = '';
  6641. 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>`;}
  6642. if (_img) {
  6643. // 将 img 标签插入到网页中
  6644. getOne(curSite.pager.insertP[0]).insertAdjacentHTML(getAddTo(curSite.pager.insertP[1]), _img);
  6645. addHistory(pageElems);
  6646. pageNum.now = pageNum._now + 1
  6647. replaceElems(pageElems)
  6648. }
  6649. }
  6650.  
  6651.  
  6652. // [风之动漫] 插入数据
  6653. function fffdm_insertE(pageElems, type) {
  6654. if (!pageElems) return
  6655. // 插入并运行 <script>
  6656. let scriptElems = getXpath('id("main")/script[contains(text(), "mhpicurl")][1]', pageElems, pageElems);
  6657. if (scriptElems) {
  6658. document.body.appendChild(document.createElement('script')).textContent = scriptElems.textContent.replace(/document\.write.+/, '');
  6659.  
  6660. // 插入图片
  6661. setTimeout(function() {
  6662. getOne(curSite.pager.insertP[0]).appendChild(document.createElement('img')).src = mhpicurl;
  6663. addHistory(pageElems);
  6664. pageNum.now = pageNum._now + 1
  6665. replaceElems(pageElems)
  6666. }, 100)
  6667. }
  6668. }
  6669.  
  6670.  
  6671. // [乐语漫画] 初始化(调整本话其余图片)
  6672. function leyuman_init() {
  6673. let _img = '';
  6674. for (let one of JSON.parse(z_img)) {
  6675. if (one.slice(0,4) === 'http') {
  6676. _img += `<img src="${one}">`;
  6677. } else {
  6678. _img += `<img src="https://img.shishi-life.com/${one}">`;
  6679. }
  6680. }
  6681. getOne(curSite.pager.insertP[0]).innerHTML = _img;
  6682.  
  6683. }
  6684. // [乐语漫画] 插入数据
  6685. function leyuman_insertE(pageElems, type) {
  6686. if (!pageElems) return
  6687. // 插入并运行 <script>
  6688. insScript('//body//script[not(@src)][contains(text(), "z_img=")]', document.body, pageElems);
  6689.  
  6690. // 插入图片
  6691. let _img = '';
  6692. for (let one of JSON.parse(z_img)) {
  6693. if (one.slice(0,4) === 'http') {
  6694. _img += `<img src="${one}">`;
  6695. } else {
  6696. _img += `<img src="https://img.shishi-life.com/${one}">`;
  6697. }
  6698. }
  6699. if (_img) {
  6700. // 将 img 标签插入到网页中
  6701. getOne(curSite.pager.insertP[0]).insertAdjacentHTML(getAddTo(curSite.pager.insertP[1]), _img);
  6702. addHistory(pageElems);
  6703. pageNum.now = pageNum._now + 1
  6704. replaceElems(pageElems)
  6705. }
  6706. }
  6707.  
  6708.  
  6709. // [新新漫画] 初始化(调整本话其余图片)
  6710. function _77mh_init() {
  6711. let _img = '';
  6712. for (let one of arr) {_img += `<img src="${img_qianz}${one}">`;}
  6713. getOne(curSite.pager.insertP[0]).innerHTML = _img;
  6714. }
  6715. // [新新漫画] 获取下一页地址
  6716. function _77mh_nextL() {
  6717. let next = nextLink_b
  6718. if (next && next != curSite.pageUrl) {
  6719. curSite.pageUrl = next;
  6720. getPageElems_(curSite.pageUrl);
  6721. }
  6722. }
  6723. // [新新漫画] 插入数据
  6724. function _77mh_insertE(pageElems, type) {
  6725. if (!pageElems) return
  6726. // 插入并运行 <script>
  6727. insScript('//script[not(@src)][contains(text(), "eval(")]', document.body, pageElems);
  6728.  
  6729. // 插入图片
  6730. let _img = '';
  6731. for (let one of msg.split('|')) {_img += `<img src="${img_qianz}${one}.webp">`;}
  6732. if (_img) {
  6733. // 将 img 标签插入到网页中
  6734. getOne(curSite.pager.insertP[0]).insertAdjacentHTML(getAddTo(curSite.pager.insertP[1]), _img);
  6735. addHistory(pageElems);
  6736. pageNum.now = pageNum._now + 1
  6737. }
  6738. }
  6739.  
  6740.  
  6741. // [古风漫画网] 获取下一页地址
  6742. function gufengmh_nextL() {
  6743. let pageElems = getOne(curSite.pager.pageE); // 寻找数据所在元素
  6744. if (pageElems) {
  6745. let comicUrl, nextId;
  6746. var url = '';
  6747. pageElems.textContent.split(';').forEach(function (one){ // 分号 ; 分割为数组并遍历
  6748. //console.log(one)
  6749. if (one.indexOf('comicUrl') > -1) { // 下一页 URL 前半部分
  6750. comicUrl = one.split('"')[1];
  6751. } else if (one.indexOf('nextChapterData') > -1) { // 下一页 URL 的后半部分 ID
  6752. nextId = one.split('"id":')[1].split(',')[0];
  6753. }
  6754. })
  6755. if (comicUrl && nextId && nextId != 'null') { // 组合到一起就是下一页 URL
  6756. url = comicUrl + nextId + '.html'
  6757. if (url === curSite.pageUrl) return
  6758. curSite.pageUrl = url
  6759. getPageElems_(curSite.pageUrl); // 访问下一页 URL 获取
  6760. }
  6761. }
  6762. }
  6763. // [古风漫画网] 插入数据
  6764. function gufengmh_insertE(pageElems, type) {
  6765. if (pageElems) {
  6766. let url = curSite.pageUrl;
  6767. pageElems = getOne(curSite.pager.pageE, pageElems, pageElems);
  6768. let chapterImages, chapterPath;
  6769. getOne(curSite.pager.pageE).innerText = pageElems.textContent; // 将当前网页内的数据所在元素内容改为刚刚获取的下一页数据内容,以便循环获取下一页 URL
  6770. pageElems.textContent.split(';').forEach(function (one){ // 分号 ; 分割为数组并遍历
  6771. //console.log(one)
  6772. if (one.indexOf('chapterImages') > -1) { // 图片文件名数组
  6773. chapterImages = one.replace(/^.+\[/, '').replace(']', '').replaceAll('"', '').split(',')
  6774. } else if (one.indexOf('chapterPath') > -1) { // 图片文件路径
  6775. chapterPath = one.split('"')[1];
  6776. } else if (one.indexOf('pageTitle') > -1) { // 网页标题
  6777. addHistory(pageElems, one.split('"')[1]);
  6778. }
  6779. })
  6780. if (chapterImages && chapterPath) {
  6781. let _img = '';
  6782. chapterImages.forEach(function (one2){_img += '<img src="https://res.xiaoqinre.com/' + chapterPath + one2 + '" data-index="0" style="display: inline-block;">';})
  6783. getOne(curSite.pager.insertP[0]).insertAdjacentHTML(getAddTo(curSite.pager.insertP[1]), _img); // 将 img 标签插入到网页中
  6784. pageNum.now = pageNum._now + 1
  6785. }
  6786. }
  6787. }
  6788.  
  6789.  
  6790. // [Mangabz 漫画] 初始化(调整本话图片)
  6791. function mangabz_init() {
  6792. let showimage = getCSS('#showimage'),
  6793. cp_img = getCSS('#cp_img'),
  6794. cp_image = getCSS('#cp_image');
  6795. if (showimage) {showimage.removeAttribute('oncontextmenu');}
  6796. if (cp_img) {cp_img.removeAttribute('oncontextmenu');}
  6797. if (cp_image) {
  6798. cp_image.removeAttribute('oncontextmenu');
  6799. cp_image.removeAttribute('id');
  6800. cp_image.removeAttribute('style');
  6801. }
  6802. }
  6803. // [Mangabz 漫画] 获取下一页地址
  6804. function mangabz_nextL() {
  6805. var url = '';
  6806. if (MANGABZ_PAGE === MANGABZ_IMAGE_COUNT) { // 下一话
  6807. if (getNextE('//a[./img[contains(@src, "icon_xiayizhang")]]')) getPageElems_(curSite.pageUrl); // 访问下一话 URL 获取
  6808. } else { // 下一页
  6809. if (!mkey) var mkey = '';
  6810. 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}`
  6811. if (url === curSite.pageUrl) return
  6812. curSite.pageUrl = url
  6813. //console.log(curSite.pageUrl)
  6814. getPageElems_(curSite.pageUrl, 'text', 'GET', '', 'Next'); // 访问下一页 URL 获取
  6815. }
  6816. }
  6817. // [Mangabz 漫画] 插入数据
  6818. function mangabz_insertE(pageElems, type) {
  6819. if (pageElems) {
  6820. if (type === 'Next') { // 下一页
  6821. let imgArr = eval(pageElems),
  6822. _img = '';
  6823. for (let now of imgArr) {_img += `<img src="${now}">`;}
  6824. if (_img) {
  6825. getOne(curSite.pager.insertP[0]).insertAdjacentHTML(getAddTo(curSite.pager.insertP[1]), _img); // 将 img 标签插入到网页中
  6826. MANGABZ_PAGE += imgArr.length;
  6827. addHistory(pageElems, document.title, location.origin + MANGABZ_CURL.substring(0, MANGABZ_CURL.length - 1) + '-p' + MANGABZ_PAGE + '/');
  6828. }
  6829. } else { // 下一话
  6830. // 插入 <script> 标签
  6831. insScript('css;html:not([dir]) > head > script:not([src])', document.body, pageElems);
  6832. addHistory(pageElems);
  6833. pageNum.now = pageNum._now + 1
  6834. replaceElems(pageElems)
  6835. MANGABZ_PAGE = 0;
  6836. mangabz_nextL();
  6837. }
  6838. }
  6839. }
  6840.  
  6841.  
  6842. // [Xmanhua 漫画] 获取下一页地址
  6843. function xmanhua_nextL() {
  6844. var url = '';
  6845. if (XMANHUA_PAGE === XMANHUA_IMAGE_COUNT) { // 下一话
  6846. if (getNextE('//a[./img[contains(@src, "reader-bottom-right-2.png")]]')) getPageElems_(curSite.pageUrl); // 访问下一话 URL 获取
  6847. } else { // 下一页
  6848. if (!mkey) var mkey = '';
  6849. 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}`
  6850. if (url === curSite.pageUrl) return
  6851. curSite.pageUrl = url
  6852. //console.log(curSite.pageUrl)
  6853. getPageElems_(curSite.pageUrl, 'text', 'GET', '', 'Next'); // 访问下一页 URL 获取
  6854. }
  6855. }
  6856. // [Xmanhua 漫画] 插入数据
  6857. function xmanhua_insertE(pageElems, type) {
  6858. if (pageElems) {
  6859. if (type === 'Next') { // 下一页
  6860. let imgArr = eval(pageElems),
  6861. _img = '';
  6862. for (let now of imgArr) {_img += `<img src="${now}">`;}
  6863. if (_img) {
  6864. getOne(curSite.pager.insertP[0]).insertAdjacentHTML(getAddTo(curSite.pager.insertP[1]), _img); // 将 img 标签插入到网页中
  6865. XMANHUA_PAGE += imgArr.length;
  6866. addHistory(pageElems, document.title, location.origin + XMANHUA_CURL.substring(0, XMANHUA_CURL.length - 1) + '-p' + XMANHUA_PAGE + '/');
  6867. }
  6868. } else { // 下一话
  6869. // 插入 <script> 标签
  6870. insScript('css;html:not([dir]) > head > script:not([src])', document.body, pageElems);
  6871. addHistory(pageElems);
  6872. pageNum.now = pageNum._now + 1
  6873. replaceElems(pageElems)
  6874. XMANHUA_PAGE = 0;
  6875. xmanhua_nextL();
  6876. }
  6877. }
  6878. }
  6879.  
  6880.  
  6881. // [COCOMANGA 漫画] 初始化(调整本话图片)
  6882. function cocomanga_init() {
  6883. let last = getCSS('.mh_comicpic:last-of-type');
  6884. if (last && last.getAttribute('p')) {
  6885. getOne(curSite.pager.insertP[0]).innerHTML = ''; // 删除旧图片元素
  6886. cocomanga_img(parseInt(last.getAttribute('p'))) // 插入新图片元素
  6887. }
  6888. }
  6889. // [COCOMANGA 漫画] 生成图片元素并插入网页
  6890. function cocomanga_img(totalImageCount) {
  6891. if (totalImageCount < 1) return
  6892. let _img = '';
  6893. for (let i=1; i<=totalImageCount; i++) {_img += `<div class="mh_comicpic" p="${i}"><img src="${__cr.getPicUrl(i)}"></div>`;}
  6894. getOne(curSite.pager.insertP[0]).insertAdjacentHTML(getAddTo(curSite.pager.insertP[1]), _img); // 将 img 标签插入到网页中
  6895. }
  6896. // [COCOMANGA 漫画] 插入数据
  6897. function cocomanga_insertE(pageElems, type) {
  6898. if (pageElems) {
  6899. // 插入 <script> 标签
  6900. insScript('css;head > script:not([src]), script[src*="custom.js"], script[src*="dynamicjs.js"]', document.body, pageElems);
  6901.  
  6902. // 插入新图片元素
  6903. setTimeout(function() {
  6904. let totalImageCount = __cdecrypt('fw122587mkertyui', CryptoJS.enc.Base64.parse(mh_info.enc_code1).toString(CryptoJS.enc.Utf8));
  6905. if (!totalImageCount) totalImageCount = __cdecrypt('fw12558899ertyui', CryptoJS.enc.Base64.parse(mh_info.enc_code1).toString(CryptoJS.enc.Utf8));
  6906. cocomanga_img(parseInt(totalImageCount));
  6907. }, 100)
  6908. addHistory(pageElems);
  6909. pageNum.now = pageNum._now + 1
  6910. replaceElems(pageElems)
  6911. }
  6912. }
  6913.  
  6914.  
  6915. // [国家自然科学基金] 获取下一页地址
  6916. function nsfc_nextL() {
  6917. let id = decodeURIComponent(document.location.href.split('/')[document.location.href.split('/').length - 1]), data
  6918. if (!document.nowPageNum) document.nowPageNum = 2
  6919. data = `id=${id}&index=${document.nowPageNum}`
  6920. if (data === curSite.pageUrl) return
  6921. curSite.pageUrl = data
  6922. getPageElems_(location.origin + '/baseQuery/data/completeProjectReport', 'json', 'POST', data); // 访问下一页 URL 获取
  6923. }
  6924. // [国家自然科学基金] 插入数据
  6925. function nsfc_insertE(pageElems, type) {
  6926. if (!pageElems || pageElems.code != 200) {curSite.SiteTypeID = 0; return}
  6927. if (!pageElems.data.hasnext) {curSite.SiteTypeID = 0} else {document.nowPageNum++}
  6928. pageNum.now = pageNum._now + 1
  6929. 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}">`);
  6930. }
  6931.  
  6932.  
  6933.  
  6934. // [酷科研] 获取下一页地址
  6935. function coolkeyan_nextL() {
  6936. if (!getCSS('.q-img__image')) return
  6937. let id = getCSS('.q-breadcrumbs--last > span.q-breadcrumbs__el'), data
  6938. if (id && id.textContent) {id=parseInt(id.textContent)} else {return}
  6939. if (!document.nowPageNum) document.nowPageNum = 2
  6940. data = `ratify_no=${id}&index=${document.nowPageNum}`
  6941. if (data === curSite.pageUrl) return
  6942. curSite.pageUrl = data
  6943. getPageElems_(location.origin + '/api/funds/nsfc/creport?' + data, 'json', 'GET'); // 访问下一页 URL 获取
  6944. }
  6945. // [酷科研] 插入数据
  6946. function coolkeyan_insertE(pageElems, type) {
  6947. if (!pageElems || pageElems == {}) {curSite.SiteTypeID = 0; return}
  6948. if (!pageElems.url) {curSite.SiteTypeID = 0; return} else {document.nowPageNum++}
  6949. pageNum.now = pageNum._now + 1
  6950. getCSS('.q-img>div[style*="padding-bottom"]').style.paddingBottom = `${(document.nowPageNum * 1000) - 1000}px`
  6951. 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>`);
  6952. }
  6953.  
  6954.  
  6955. // --------------------------------------------------------
  6956.  
  6957.  
  6958. // 自动无缝翻页
  6959. function pageLoading() {
  6960. if (curSite.SiteTypeID == 0) return
  6961. windowScroll(function (direction, e) {
  6962. // 下滑 且 未暂停翻页 且 SiteTypeID > 0 时,才准备翻页
  6963. if (direction != 'down' || !pausePage || curSite.SiteTypeID == 0) return
  6964. // 翻页模式 5 且为框架内时,要判断顶层是否通过页码暂停翻页了
  6965. if (curSite.pager.type == 5 && self != top && window.top.document.xiu_pausePage == false) return
  6966.  
  6967. let scrollTop = document.documentElement.scrollTop || window.pageYOffset || document.body.scrollTop,
  6968. scrollHeight = window.innerHeight || document.documentElement.clientHeight,
  6969. scrollD = curSite.pager.scrollD;
  6970.  
  6971. // <<<<< 翻页类型 3(依靠 [基准元素] 与 [浏览器可视区域底部] 之间的距离缩小来触发翻页)>>>>>
  6972. if (curSite.pager.type === 3) {
  6973. let scrollE = getOne(curSite.pager.scrollE);
  6974. //console.log(scrollE.offsetTop, scrollE.offsetTop - (scrollTop + scrollHeight), scrollD, scrollTop + scrollHeight, curSite.SiteTypeID)
  6975. if (scrollE.offsetTop - (scrollTop + scrollHeight) <= scrollD) {intervalPause(); checkURL(getPageElems);}
  6976.  
  6977. } else {
  6978. if (document.documentElement.scrollHeight <= scrollHeight + scrollTop + scrollD) {
  6979. // <<<<< 翻页类型 1(由脚本实现自动无缝翻页)>>>>>
  6980. if (curSite.pager.type === 1) {
  6981. intervalPause(); checkURL(getPageElems);
  6982.  
  6983. // <<<<< 翻页类型 2(网站自带了自动无缝翻页功能,只需要点击下一页按钮即可)>>>>>
  6984. } else if (curSite.pager.type === 2) {
  6985. let autopbn = getOne(curSite.pager.nextL);
  6986. if (!autopbn) return
  6987. if (curSite.pager.isHidden && isHidden(autopbn)) return // 如果 isHidden = true,那么需要判断元素是否隐藏
  6988. if (curSite.pager.nextText) {
  6989. // 按钮文本,当按钮文本 = 该文本时,才会点击按钮加载下一页
  6990. if (autopbn.innerText === curSite.pager.nextText) {autopbn.click(); pageNum.now = pageNum._now + 1;}
  6991. } else if (curSite.pager.nextTextOf) {
  6992. // 按钮文本的一部分,当按钮文本包含该文本时,才会点击按钮加载下一页
  6993. if (autopbn.innerText.indexOf(curSite.pager.nextTextOf) > -1) {autopbn.click(); pageNum.now = pageNum._now + 1;}
  6994. } else if (curSite.pager.nextHTML) {
  6995. // 按钮内元素,当按钮内元素 = 该元素内容时,才会点击按钮加载下一页
  6996. if (autopbn.innerHTML === curSite.pager.nextHTML) {autopbn.click(); pageNum.now = pageNum._now + 1;}
  6997. } else {
  6998. // 对于没有按钮文字变化的按钮,可以指定间隔时间(默认 300ms)
  6999. if (!curSite.pager.interval) curSite.pager.interval = 300;
  7000. intervalPause();
  7001. // 如果没有指定按钮文字就直接点击
  7002. autopbn.click(); pageNum.now = pageNum._now + 1;
  7003. }
  7004.  
  7005. // <<<<< 翻页类型 4(部分简单的动态加载类网站)>>>>>
  7006. } else if (curSite.pager.type === 4) {
  7007. // 为百度贴吧的发帖考虑,预留底部一小部分...
  7008. if (!(curSite.SiteTypeID === SiteType.BAIDU_TIEBA && document.documentElement.scrollHeight <= scrollHeight + scrollTop + 200)) {
  7009. intervalPause(); if (typeof curSite.pager.nextL == 'function') {curSite.pager.nextL();} else if (getNextE(curSite.pager.nextL)) {getPageElems_(curSite.pageUrl);}
  7010. }
  7011.  
  7012. // <<<<< 翻页类型 5(插入 iframe 方式来加载下一页)>>>>>
  7013. } else if (curSite.pager.type === 5) {checkURL(insIframe);
  7014.  
  7015. // <<<<< 翻页类型 6(通过 iframe 获取下一页动态加载内容)>>>>>
  7016. } else if (curSite.pager.type === 6) {checkURL(insIframe_);}
  7017. }
  7018. }
  7019. });
  7020.  
  7021. function intervalPause() {
  7022. if (curSite.pager.interval) {
  7023. pausePage = false
  7024. setTimeout(function(){pausePage = true;}, curSite.pager.interval)
  7025. }
  7026. }
  7027. }
  7028. // 判断是支持
  7029. function doesItSupport() {
  7030. setDBSite(); // 配置 DBSite 变量对象
  7031.  
  7032. // 遍历判断是否是某个已支持的网站,顺便直接赋值
  7033. let support = false;
  7034. end:
  7035. for (let now in DBSite) { // 遍历 对象
  7036. if (!DBSite[now].host) continue; // 如果不存在则继续下一个循环
  7037.  
  7038. // 如果是 数组
  7039. if (Array.isArray(DBSite[now].host)) {
  7040.  
  7041. for (let i of DBSite[now].host) { // 遍历 数组
  7042. if ((i instanceof RegExp && i.test(location.hostname)) || (typeof i === 'string' && i === location.hostname)) {
  7043.  
  7044. if (self != top) {if (!DBSite[now].iframe) break end;} // 如果当前位于 iframe 框架下,就需要判断是否需要继续执行
  7045. if (DBSite[now].functionS) { DBSite[now].functionS(); } else { curSite = DBSite[now]; }
  7046. support = true; break; // 如果找到了就退出循环
  7047. }
  7048. }
  7049.  
  7050. // 如果是 正则
  7051. } else if ((DBSite[now].host instanceof RegExp && DBSite[now].host.test(location.hostname)) || (typeof DBSite[now].host === 'string' && DBSite[now].host === location.hostname)) {
  7052.  
  7053. if (self != top) {if (!DBSite[now].iframe) break;} // 如果当前位于 iframe 框架下,就需要判断是否需要继续执行
  7054. if (DBSite[now].functionS) { DBSite[now].functionS(); } else { curSite = DBSite[now]; }
  7055. support = true; break; // 如果找到了就退出循环
  7056. }
  7057.  
  7058. }
  7059.  
  7060. if (support) {
  7061. console.info('[自动无缝翻页] - 独立规则 网站'); return 1;
  7062. } 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)) {
  7063. console.info('[自动无缝翻页] - <Discuz!> 论坛'); return 2;
  7064. } else if (getCSS('#flarum-loading')) {
  7065. console.info('[自动无缝翻页] - <Flarum> 论坛'); return 3;
  7066. } else if (getCSS('body#phpbb')) {
  7067. console.info('[自动无缝翻页] - <phpBB> 论坛'); return 4;
  7068. } else if (getXpath('//footer//a[contains(string(), "Xiuno")] | //link[contains(@href, "xiuno")] | //script[contains(@src, "xiuno")]')) {
  7069. console.info('[自动无缝翻页] - <Xiuno> 论坛'); return 5;
  7070. } else if (typeof XF != 'undefined') {
  7071. console.info('[自动无缝翻页] - <XenForo> 论坛'); return 6;
  7072. } else if (getCSS('head meta[name="generator" i][content="nexusphp" i]') || getXpath('id("footer")[contains(string(), "NexusPHP")]')) {
  7073. console.info('[自动无缝翻页] - <NexusPHP> 论坛'); return 7;
  7074. } else if (getCSS('link[href*="themes/dux" i], script[src*="themes/dux" i]')) {
  7075. console.info('[自动无缝翻页] - 使用 WordPress <DUX> 主题的网站'); return 100;
  7076. } else if (getCSS('link[href*="themes/xiu" i], script[src*="themes/xiu" i]')) {
  7077. console.info('[自动无缝翻页] - 使用 WordPress <XIU> 主题的网站'); return 101;
  7078. } else if (getCSS('link[href*="themes/d8" i], script[src*="themes/d8" i]')) {
  7079. console.info('[自动无缝翻页] - 使用 WordPress <D8> 主题的网站'); return 102;
  7080. } else if (getCSS('link[href*="themes/begin" i], script[src*="themes/begin" i], img[src*="themes/begin" i]')) {
  7081. console.info('[自动无缝翻页] - 使用 WordPress <Begin> 主题的网站'); return 103;
  7082. } else if ((getCSS('meta[name="description" i][content*="小说"], meta[name="description" i][content*="章节"], meta[name="description" i][content*="阅读"]') || location.hostname.indexOf('biqu') || document.title.indexOf('笔趣阁')) && getCSS('#content, .content, #chaptercontent, .chaptercontent, #BookText') && getXpath('//a[contains(text(), "下一章") or contains(text(), "下一页")]')) {
  7083. console.info('[自动无缝翻页] - <笔趣阁> 模板的小说网站'); return 200;
  7084. } else if (self != top) {
  7085. return -1;
  7086. }
  7087. return 0;
  7088. }
  7089.  
  7090.  
  7091. // 翻页类型 1/3
  7092. function getPageElems(url) {
  7093. GM_xmlhttpRequest({
  7094. url: url,
  7095. method: 'GET',
  7096. overrideMimeType: 'text/html; charset=' + document.charset,
  7097. headers: {
  7098. 'Referer': location.href
  7099. },
  7100. timeout: 10000,
  7101. onload: function (response) {
  7102. try {
  7103. //console.log('最终 URL:' + response.finalUrl, '返回内容:' + response.responseText)
  7104. processElems(createDocumentByString(response.responseText));
  7105. } catch (e) {
  7106. console.log(e);
  7107. }
  7108. }
  7109. });
  7110. }
  7111. // 翻页类型 4
  7112. function getPageElems_(url, type = '', method = 'GET', data = '', type2) {
  7113. let mimeType;
  7114. switch (type) {
  7115. case 'json':
  7116. mimeType = 'application/json; charset=' + document.charset; break;
  7117. case 'text':
  7118. mimeType = 'text/plain; charset=' + document.charset; break;
  7119. default:
  7120. mimeType = 'text/html; charset=' + document.charset;
  7121. }
  7122.  
  7123. GM_xmlhttpRequest({
  7124. url: url,
  7125. method: method,
  7126. data: data,
  7127. responseType: type,
  7128. overrideMimeType: mimeType,
  7129. headers: {
  7130. 'Referer': location.href,
  7131. 'Content-Type': (method === 'POST') ? 'application/x-www-form-urlencoded':''
  7132. },
  7133. timeout: 10000,
  7134. onload: function (response) {
  7135. try {
  7136. //console.log('最终 URL:' + response.finalUrl, '返回内容:' + response.responseText)
  7137. switch (type) {
  7138. case 'json':
  7139. curSite.pager.insertE(response.response, type2);
  7140. break;
  7141. case 'text':
  7142. curSite.pager.insertE(response.responseText, type2)
  7143. break;
  7144. default:
  7145. curSite.pager.insertE(createDocumentByString(response.responseText), type2)
  7146. }
  7147. } catch (e) {
  7148. console.log(e);
  7149. }
  7150. }
  7151. });
  7152. }
  7153. // 翻页类型 5(插入 iframe 方式加载下一页,无限套娃)
  7154. function insIframe(src) {
  7155. // 停用当前页面翻页
  7156. if (curSite.SiteTypeID == 0) return
  7157. curSite.SiteTypeID = 0;
  7158.  
  7159. // 创建 iframe
  7160. let iframe = document.createElement('iframe');
  7161. iframe.style = 'position: absolute; width: 100%; height: 100%; border: none;';
  7162. iframe.id = 'xiu_iframe';
  7163. iframe.src = src;
  7164.  
  7165. var beforeScrollTop = document.documentElement.scrollTop || document.body.scrollTop
  7166. // 当滚动条到底部时(即完全显示 iframe 框架),隐藏当前页面的滚动条
  7167. window.addEventListener('scroll', function () {
  7168. let scrollTop = document.documentElement.scrollTop || document.body.scrollTop,
  7169. clientHeight = document.documentElement.clientHeight || document.body.clientHeight,
  7170. scrollHeight = document.documentElement.scrollHeight || document.body.scrollHeight,
  7171. afterScrollTop = document.documentElement.scrollTop || document.body.scrollTop,
  7172. delta = afterScrollTop - beforeScrollTop;
  7173. if (delta == 0) return false;
  7174. beforeScrollTop = afterScrollTop;
  7175.  
  7176. //console.log(delta, scrollHeight - (scrollTop + clientHeight + 10), '1111')
  7177. if (delta > 0 && scrollTop + clientHeight + 10 >= scrollHeight && !getCSS('#xiu-scroll')) {
  7178. let newStyle = document.createElement('style'); newStyle.id = 'xiu-scroll';
  7179. newStyle.textContent = 'html::-webkit-scrollbar, body::-webkit-scrollbar {width: 0 !important;height: 0 !important;} html, body {scrollbar-width: none !important;}';
  7180. if (curSite.pager.style) newStyle.textContent += curSite.pager.style;
  7181. document.documentElement.appendChild(newStyle);
  7182. iframe.focus();
  7183. iframe.document.body.focus();
  7184. //iframe.document.body.click();
  7185. } else if (delta < 0 && getCSS('#xiu-scroll')) {
  7186. getCSS('#xiu-scroll').remove();
  7187. }
  7188. }, false);
  7189.  
  7190. // 加载完成后才继续
  7191. iframe.onload = function() {
  7192. // 添加历史记录
  7193. if (curSite.history !== false) addHistory(iframe.contentWindow.document, iframe.contentWindow.document.title);
  7194. // 当前页码 + 1
  7195. if (!curSite.hiddenPN) {
  7196. let autopageNumber = getCSS('#Autopage_number', window.top.document)
  7197. if (autopageNumber) {autopageNumber.textContent = parseInt(autopageNumber.textContent) + 1;}
  7198. }
  7199. }
  7200.  
  7201. // 插入 iframe
  7202. document.documentElement.appendChild(iframe);
  7203. }
  7204. // 翻页类型 6(通过 iframe 获取下一页动态加载内容,只有一个娃)
  7205. function insIframe_(src) {
  7206. // 暂停翻页
  7207. if (!pausePage) return
  7208. pausePage = false
  7209. console.log(src)
  7210. // 如果不存在,则创建一个 iframe
  7211. let iframe = document.getElementById('xiu_iframe');
  7212. if (!iframe) {
  7213. iframe = document.createElement('iframe');
  7214. iframe.style = 'position: absolute; top: -9999px; left: -9999px; width: 100%; height: 100%; border: none; z-index: -999; /*visibility: hidden;*/';
  7215. iframe.id = 'xiu_iframe';
  7216. iframe.src = src;
  7217. }
  7218.  
  7219. // 加载完成后才继续
  7220. iframe.onload = function() {
  7221. //iframe.contentWindow.scrollTo(0, 999999); // 滚动到底部,以触发网页的滚动条相关加载事件
  7222. //iframe.contentWindow.scrollTo({top: 9999999, behavior: 'smooth'});
  7223. if (!curSite.pager.loadTime) curSite.pager.loadTime = 100; // 默认 100ms
  7224. //console.log(curSite.pager.loadTime, curSite.pager.loadTime/30)
  7225. //console.time('sort');
  7226. let time1 = 0 ,time2 = setInterval(function(){
  7227. let scrollHeight = (iframe.contentWindow.document.documentElement.scrollHeight || iframe.contentWindow.document.body.scrollHeight)/10
  7228. iframe.contentWindow.scrollTo(0, 999999);
  7229. iframe.contentWindow.scrollTo(0, scrollHeight*time1);
  7230. //console.log(time1, iframe.contentWindow.document.documentElement.scrollHeight || iframe.contentWindow.document.body.scrollHeight)
  7231. if (++time1 == 10) {
  7232. //console.timeEnd('sort');
  7233. clearInterval(time2);
  7234. processElems(iframe.contentWindow.document); // 插入/替换元素等
  7235. //console.log(iframe.contentWindow.document.documentElement.scrollHeight || iframe.contentWindow.document.body.scrollHeight)
  7236. pausePage = true; // 恢复翻页
  7237. }
  7238. }, curSite.pager.loadTime/10)
  7239. }
  7240.  
  7241. // 插入 iframe(如果已存在则直接改 src)
  7242. if (document.getElementById('xiu_iframe')) {
  7243. iframe.src = src;
  7244. } else {
  7245. document.documentElement.appendChild(iframe);
  7246. }
  7247. }
  7248.  
  7249.  
  7250. // XHR 后处理结果,插入、替换元素等(适用于翻页类型 1/3/6)
  7251. function processElems(response) {
  7252. if (!curSite.pager.insertP) {curSite.pager.insertP = [curSite.pager.pageE, 5]}
  7253. let pageElems = getAll(curSite.pager.pageE, response, response), toElement;
  7254. if (curSite.pager.insertP[1] === 5) { // 插入 pageE 列表最后一个元素的后面
  7255. toElement = getAll(curSite.pager.insertP[0]).pop();
  7256. } else {
  7257. toElement = getOne(curSite.pager.insertP[0]);
  7258. }
  7259. //console.log(curSite.pager.pageE, pageElems, curSite.pager.insertP, toElement)
  7260.  
  7261. if (pageElems.length > 0 && toElement) {
  7262. // 如果有插入前函数就执行函数
  7263. if (curSite.function && curSite.function.bF) {
  7264. if (curSite.function.pF) { // 如果指定了参数
  7265. pageElems = curSite.function.bF(pageElems, curSite.function.pF);
  7266. } else {
  7267. pageElems = curSite.function.bF(pageElems);
  7268. }
  7269. }
  7270.  
  7271. // 插入位置
  7272. let addTo = getAddTo(curSite.pager.insertP[1]);
  7273.  
  7274. // 插入新页面元素
  7275. if (curSite.pager.insertP[1] === 6) { // 插入到目标内部末尾(针对文本,比如小说网页)
  7276. let afterend = '';
  7277. if (curSite.pager.insertP6Br) afterend += '<br/><br/>'
  7278. pageElems.forEach(function (one) {afterend += one.innerHTML;});
  7279. toElement.insertAdjacentHTML(addTo, afterend);
  7280. } else {
  7281. if (curSite.pager.insertP[1] === 2 || curSite.pager.insertP[1] === 4 || curSite.pager.insertP[1] === 5) pageElems.reverse(); // 插入到 [元素内头部]、[目标本身后面] 时,需要反转顺序
  7282. pageElems.forEach(function (one) {toElement.insertAdjacentElement(addTo, one);});
  7283. }
  7284.  
  7285. // 当前页码 + 1
  7286. pageNum.now = pageNum._now + 1
  7287.  
  7288. // 添加历史记录
  7289. if (curSite.history !== false) addHistory(response);
  7290.  
  7291. // 替换待替换元素
  7292. if (curSite.pager.replaceE) replaceElems(response);
  7293.  
  7294. // 插入 <script> 标签
  7295. if (curSite.pager.scriptT || curSite.pager.scriptT == 0) {
  7296. switch (curSite.pager.scriptT) {
  7297. case 0: // 下一页的所有 <script> 标签
  7298. insScript('css;script', toElement, response); break;
  7299. case 1: // 下一页的所有 <script> 标签(不包括 src 链接)
  7300. insScript('css;script:not([src])', toElement, response); break;
  7301. case 2: // 下一页主体元素 (pageE) 的同级 <script> 标签
  7302. insScript(null, toElement, pageElems); break;
  7303. case 3: // 下一页主体元素 (pageE) 的子元素 <script> 标签
  7304. insScript('css;script:not([src])', toElement, pageElems); break;
  7305. }
  7306. }
  7307.  
  7308. // 如果有插入后函数就执行函数
  7309. if (curSite.function && curSite.function.aF) {
  7310. if (curSite.function.pF) { // 如果指定了参数
  7311. curSite.function.aF(curSite.function.pF);
  7312. } else {
  7313. curSite.function.aF();
  7314. }
  7315. }
  7316. } else { // 获取主体元素失败后,尝试重新获取
  7317. console.log(curSite.pager.pageE, pageElems, curSite.pager.insertP, toElement)
  7318. if (curSite.retry) {
  7319. console.warn('[自动无缝翻页] 获取主体元素失败,尝试重新获取...')
  7320. setTimeout(function(){curSite.pageUrl = '';}, curSite.retry)
  7321. } else { // 尝试替换元素看能不能继续翻页下去
  7322. if (curSite.pager.replaceE) {
  7323. if (replaceElems(response)) { // 如果替换成功
  7324. console.log('[自动无缝翻页] 获取主体元素失败,尝试替换元素成功!')
  7325. pageNum.now = pageNum._now + 1; // 当前页码 + 1
  7326. if (curSite.history !== false) addHistory(response); // 添加历史记录
  7327. } else {console.error('[自动无缝翻页] 获取主体元素失败,尝试替换元素失败...')}
  7328. }
  7329. }
  7330. }
  7331. }
  7332. // 通用型插入前函数(加载图片)
  7333. function src_bF(pageElems, css) {
  7334. pageElems.forEach(function (one) {
  7335. if (css[0] == 0) { // src 图片
  7336. if (one.tagName == 'IMG' && one.getAttribute(css[2])) one.src = one.getAttribute(css[2]);
  7337. one.querySelectorAll(css[1]).forEach(function (now) {
  7338. now.src = now.getAttribute(css[2]);
  7339. });
  7340. } else if (css[0] == 1) { // 背景图片
  7341. if (one.tagName == 'IMG' && one.getAttribute(css[2])) one.style.backgroundImage = 'url("' + one.getAttribute(css[2]) + '")';
  7342. one.querySelectorAll(css[1]).forEach(function (now) {
  7343. now.style.backgroundImage = 'url("' + now.getAttribute(css[2]) + '")';
  7344. });
  7345. }
  7346. });
  7347. return pageElems
  7348. }
  7349. // 文字型插入前函数(正则过滤)
  7350. function xs_bF(pageElems, reg) {
  7351. pageElems.forEach(function (one) {
  7352. one.innerHTML = one.innerHTML.replace(reg[0], reg[1])
  7353. });
  7354. return pageElems
  7355. }
  7356.  
  7357. // 通用型获取下一页地址(从 元素 中获取页码)
  7358. function getNextE(css) {
  7359. if (!css) css = curSite.pager.nextL;
  7360. let next = getOne(css)
  7361. if (next && next.nodeType === 1 && next.href && next.href.slice(0,4) === 'http' && next.href != curSite.pageUrl) {
  7362. if (curSite.pager.forceHTTPS && location.protocol === 'https:') {
  7363. curSite.pageUrl = next.href.replace(/^http:/,'https:');
  7364. } else {
  7365. curSite.pageUrl = next.href;
  7366. }
  7367. //console.log(curSite.pageUrl)
  7368. return true
  7369. }
  7370. return false
  7371. }
  7372. // 通用型获取下一页地址(从 元素 中获取页码,URL 替换 page= 参数)
  7373. function getNextEP(css, pf, reg) {
  7374. let nextNum = getOne(css), url = '';
  7375. if (nextNum && nextNum.textContent) {
  7376. nextNum = nextNum.textContent.replaceAll(' ','');
  7377. if (location.search) {
  7378. if (indexOF(pf, 's')) {
  7379. url = location.search.replace(reg, pf + nextNum);
  7380. } else {
  7381. url = location.search + '&' + pf + nextNum;
  7382. }
  7383. } else {
  7384. url = '?' + pf + nextNum;
  7385. }
  7386. url = location.origin + location.pathname + url;
  7387. }
  7388. return url
  7389. }
  7390. // 通用型获取下一页地址(从 元素 中获取页码,URL 替换 pathname 路径)
  7391. function getNextEPN(css, reg, a, b = '') {
  7392. let nextNum = getOne(css), url = '';
  7393. if (nextNum && nextNum.textContent) {
  7394. nextNum = nextNum.textContent.replaceAll(' ','');
  7395. if (location.pathname) {
  7396. if (indexOF(reg)) {
  7397. url = location.pathname.replace(reg, a + nextNum + b);
  7398. } else {
  7399. url = location.pathname + a + nextNum + b;
  7400. }
  7401. } else {
  7402. url = location.pathname + a + nextNum + b;
  7403. }
  7404. url = location.origin + url;
  7405. }
  7406. return url
  7407. }
  7408. // 通用型获取下一页地址(从 URL 中获取页码,URL 替换 pathname 路径)
  7409. function getNextUPN(reg1, reg, a, b = '', initP = '2', endP) {
  7410. let nextNum = reg1.exec(location.pathname);
  7411. if (nextNum) {
  7412. nextNum = String(parseInt(nextNum[0])+1);
  7413. if (endP && (parseInt(nextNum[0]) > parseInt(endP))) return ''
  7414. } else {
  7415. nextNum = initP;
  7416. if (endP && (parseInt(nextNum[0]) >= parseInt(endP))) return ''
  7417. }
  7418. let url = '';
  7419. if (location.pathname) {
  7420. if (indexOF(reg)) {
  7421. url = location.pathname.replace(reg, a + nextNum + b);
  7422. } else {
  7423. url = location.pathname + a + nextNum + b;
  7424. }
  7425. } else {
  7426. url = location.pathname + a + nextNum + b;
  7427. }
  7428. url = location.origin + url;
  7429. return url
  7430. }
  7431. // 通用型获取下一页地址(从 URL 中获取页码,URL 替换 page= 参数)
  7432. function getNextUP(pf, reg, lp = location.pathname, initP = '2', endP) {
  7433. let nextNum = getSearch(pf.replace('=',''));
  7434. if (nextNum) {
  7435. nextNum = String(parseInt(nextNum)+1);
  7436. if (endP && (parseInt(nextNum) > parseInt(endP))) return ''
  7437. } else {
  7438. nextNum = initP;
  7439. if (endP && (parseInt(nextNum) >= parseInt(endP))) return ''
  7440. }
  7441. let url = '';
  7442. if (location.search) {
  7443. if (indexOF(pf, 's')) {
  7444. url = location.search.replace(reg, pf + nextNum);
  7445. } else {
  7446. url = location.search + '&' + pf + nextNum;
  7447. }
  7448. } else {
  7449. url = '?' + pf + nextNum;
  7450. }
  7451. url = location.origin + lp + url;
  7452. return url
  7453. }
  7454.  
  7455. // 检查 URL
  7456. function checkURL(func) {
  7457. if (typeof curSite.pager.nextL == 'function') {
  7458. let tempUrl = curSite.pager.nextL();
  7459. if (!tempUrl || (tempUrl && tempUrl.slice(0,4) != 'http') || tempUrl === curSite.pageUrl ) return;
  7460. curSite.pageUrl = tempUrl;
  7461. func(curSite.pageUrl);
  7462. } else if (getNextE()) {
  7463. func(curSite.pageUrl);
  7464. }
  7465. //console.log(curSite.pageUrl);
  7466. }
  7467. // 替换元素
  7468. function replaceElems(pageElems, o = curSite.pager.replaceE, r = curSite.pager.replaceE) {
  7469. let oriE = getAll(o),
  7470. repE = getAll(r, pageElems, pageElems);
  7471. //console.log(oriE, repE)
  7472. if (oriE.length != 0 && repE.length != 0 && oriE.length === repE.length) {
  7473. for (let i = 0; i < oriE.length; i++) {
  7474. oriE[i].outerHTML = repE[i].outerHTML;
  7475. }
  7476. return true
  7477. }
  7478. return false
  7479. }
  7480. // 添加历史记录
  7481. function addHistory(pageElems, title, url) {
  7482. if (!curSite.pageUrl) return
  7483. //console.log(pageElems.querySelector('title'), curSite.pageUrl)
  7484. title = title || pageElems.querySelector('title').textContent || window.top.document.title;
  7485. url = url || curSite.pageUrl;
  7486. window.top.document.title = title;
  7487. window.top.document.xiu_nowUrl = curSite.pageUrl;
  7488. window.top.history.pushState('xiu_history', title, url);
  7489. }
  7490. // 插入 <Script>
  7491. function insScript(selector, toElement = document.body, contextNode = document) {
  7492. let scriptElems = contextNode;
  7493. if (selector) {
  7494. if (contextNode instanceof Array) {
  7495. scriptElems = []; contextNode.forEach(function (one) {scriptElems = scriptElems.concat(getAll(selector, one, one));})
  7496. } else {
  7497. scriptElems = getAll(selector, contextNode, contextNode);
  7498. }
  7499. }
  7500. scriptElems.forEach(function (one) {
  7501. if (one.tagName === 'SCRIPT') {
  7502. if (one.src) {
  7503. toElement.appendChild(document.createElement('script')).src = one.src;
  7504. } else {
  7505. toElement.appendChild(document.createElement('script')).textContent = one.textContent;
  7506. }
  7507. }
  7508. });
  7509. }
  7510. // 插入 <Style>
  7511. function insStyle(style) {
  7512. document.documentElement.appendChild(document.createElement('style')).textContent = style;
  7513. }
  7514.  
  7515.  
  7516. // 获取元素(CSS/Xpath)来自:https://github.com/machsix/Super-preloader
  7517. function getCSS(css, contextNode = document) {
  7518. return contextNode.querySelector(css);
  7519. }
  7520. function getAllCSS(css, contextNode = document) {
  7521. return [].slice.call(contextNode.querySelectorAll(css));
  7522. }
  7523. function getXpath(xpath, contextNode, doc = document) {
  7524. contextNode = contextNode || doc;
  7525. try {
  7526. const result = doc.evaluate(xpath, contextNode, null, XPathResult.FIRST_ORDERED_NODE_TYPE, null);
  7527. // 应该总是返回一个元素节点
  7528. return result.singleNodeValue && result.singleNodeValue.nodeType === 1 && result.singleNodeValue;
  7529. } catch (err) {
  7530. throw new Error(`无效 Xpath: ${xpath}`);
  7531. }
  7532. }
  7533. function getAllXpath(xpath, contextNode, doc = document) {
  7534. contextNode = contextNode || doc;
  7535. const result = [];
  7536. try {
  7537. const query = doc.evaluate(xpath, contextNode, null, XPathResult.ORDERED_NODE_SNAPSHOT_TYPE, null);
  7538. for (let i = 0; i < query.snapshotLength; i++) {
  7539. const node = query.snapshotItem(i);
  7540. // 如果是 Element 节点
  7541. if (node.nodeType === 1) result.push(node);
  7542. }
  7543. } catch (err) {
  7544. throw new Error(`无效 Xpath: ${xpath}`);
  7545. }
  7546. return result;
  7547. }
  7548. function getOne(selector, contextNode = undefined, doc = document) {
  7549. if (!selector) return;
  7550. contextNode = contextNode || doc;
  7551. if (selector.search(/^css;/i) === 0) {
  7552. return getCSS(selector.slice(4), contextNode);
  7553. } else {
  7554. return getXpath(selector, contextNode, doc);
  7555. }
  7556. }
  7557. function getAll(selector, contextNode = undefined, doc = document) {
  7558. if (!selector) return [];
  7559. contextNode = contextNode || doc;
  7560. if (selector.search(/^css;/i) === 0) {
  7561. return getAllCSS(selector.slice(4), contextNode);
  7562. } else {
  7563. return getAllXpath(selector, contextNode, doc);
  7564. }
  7565. }
  7566. function createDocumentByString(e) {
  7567. if (e) {
  7568. if ('HTML' !== document.documentElement.nodeName) return (new DOMParser).parseFromString(e, 'application/xhtml+xml');
  7569. var t;
  7570. try { t = (new DOMParser).parseFromString(e, 'text/html');} catch (e) {}
  7571. if (t) return t;
  7572. if (document.implementation.createHTMLDocument) {
  7573. t = document.implementation.createHTMLDocument('ADocument');
  7574. } else {
  7575. 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) {}
  7576. }
  7577. if (t) {
  7578. var r = document.createRange(),
  7579. n = r.createContextualFragment(e);
  7580. r.selectNodeContents(document.body);
  7581. t.body.appendChild(n);
  7582. 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);
  7583. return t;
  7584. }
  7585. } else console.error('没有找到要转成 DOM 的字符串');
  7586. }
  7587.  
  7588.  
  7589. // 强制新标签页打开链接(翻页模式 5/6)
  7590. function forceTarget() {
  7591. document.body.addEventListener('click', function(e) {
  7592. if (e.target.tagName === 'A') {
  7593. forceTarget_(e.target, e);
  7594. } else {
  7595. let path = e.path || e.composedPath();
  7596. for (let i = 1; i < path.length - 3; i++) {
  7597. //console.log(path[i])
  7598. if (path[i].tagName === 'A') {
  7599. forceTarget_(path[i], e);
  7600. break;
  7601. }
  7602. }
  7603. }
  7604. });
  7605.  
  7606. function forceTarget_(target, e){
  7607. if (target.href && target.target != '_blank' && !(target.getAttribute('onclick')) && target.href.slice(0,4) == 'http' && target.getAttribute('href').slice(0,1) != '#') {
  7608. e.preventDefault(); // 阻止默认打开链接事件
  7609. //console.log(target.href);
  7610. //window.top.location.href = target.href;
  7611. window.GM_openInTab(target.href, {active: true,insert: true,setParent: true});
  7612. }
  7613. }
  7614. //document.head.appendChild(document.createElement('base')).target = '_top';
  7615. }
  7616. // 判断元素是否隐藏(隐藏返回 true)
  7617. function isHidden(el){
  7618. return (el.offsetParent === null);
  7619. }
  7620. // 判断 URL 是否存在指定文本
  7621. function indexOF(e, l = 'p', low = false){
  7622. switch (l) {
  7623. case 'h':
  7624. l = location.href; break;
  7625. case 'p':
  7626. l = location.pathname; break;
  7627. case 's':
  7628. l = location.search; break;
  7629. }
  7630. //console.log(l,e,l.indexOf(e))
  7631. if (low) {e = e.toLowerCase(); l = l.toLowerCase();} // 全部转为小写
  7632. if (e instanceof RegExp) {
  7633. if (e.test(l)) return true
  7634. } else {
  7635. if (l.indexOf(e) > -1) return true
  7636. }
  7637. return false
  7638. }
  7639. // 获取 Search 指定参数
  7640. function getSearch(variable) {
  7641. let query = window.location.search.substring(1),
  7642. vars = query.split('&');
  7643. for (var i=0;i<vars.length;i++) {
  7644. var pair = vars[i].split('=');
  7645. if(pair[0] == variable){return pair[1];}
  7646. }
  7647. return '';
  7648. }
  7649. // 启用/禁用 (当前网站)
  7650. function menu_disable(type) {
  7651. switch(type) {
  7652. case 'check':
  7653. return check(); break;
  7654. case 'add':
  7655. add(); break;
  7656. case 'del':
  7657. del(); break;
  7658. }
  7659.  
  7660. function check() { // 存在返回真,不存在返回假
  7661. if (GM_getValue('menu_disable').indexOf(location.hostname) == -1) return false // 不存在返回假
  7662. return true
  7663. }
  7664.  
  7665. function add() {
  7666. if (check()) return
  7667. let list = GM_getValue('menu_disable'); // 读取网站列表
  7668. list.push(location.hostname); // 追加网站域名
  7669. GM_setValue('menu_disable', list); // 写入配置
  7670. location.reload(); // 刷新网页
  7671. }
  7672.  
  7673. function del() {
  7674. if (!check()) return
  7675. let list = GM_getValue('menu_disable'), // 读取网站列表
  7676. index = list.indexOf(location.hostname);
  7677. list.splice(index, 1); // 删除网站域名
  7678. GM_setValue('menu_disable', list); // 写入配置
  7679. location.reload(); // 刷新网页
  7680. }
  7681. }
  7682. // 左键双击网页空白处暂停翻页
  7683. function pausePageEvent() {
  7684. if (!GM_getValue('menu_pause_page')) return
  7685. if (curSite.SiteTypeID === 0) return
  7686. if (curSite.pager && curSite.pager.type == 5) window.top.document.xiu_pausePage = pausePage
  7687. document.body.addEventListener('dblclick', function () {
  7688. if (pausePage) {GM_notification({text: `❌ 已暂停本页 [自动无缝翻页]\n (再次双击可恢复)`, timeout: 2000});} else {GM_notification({text: `✅ 已恢复本页 [自动无缝翻页]\n (再次双击可暂停)`, timeout: 2000});}
  7689. pausePage = !pausePage;
  7690. if (curSite.pager && curSite.pager.type == 5) window.top.document.xiu_pausePage = pausePage
  7691. });
  7692. }
  7693. // 显示页码
  7694. function pageNumber(type) {
  7695. 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}
  7696. let status = getCSS('#Autopage_number');
  7697. switch (type) {
  7698. case 'add':
  7699. add(); break;
  7700. case 'del':
  7701. del(); break;
  7702. case 'set':
  7703. set(); break;
  7704. }
  7705.  
  7706. function add(){
  7707. if (status) {
  7708. if (status.style.display === 'none') {status.style.display = 'flex';}
  7709. return
  7710. }
  7711. // 插入网页
  7712. 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>`,
  7713. _html = `<div id="Autopage_number" title="1. 此处数字为 [当前页码] (可在脚本菜单中关闭)&#10;&#10;2. 鼠标左键点击此处 [临时暂停本页自动无缝翻页](再次点击可恢复)">${pageNum._now}</div>`
  7714. document.documentElement.insertAdjacentHTML('beforeend', _style + _html);
  7715. // 解决 远景论坛 会清理掉前面插入的 CSS 样式的问题
  7716. if (location.hostname === 'bbs.pcbeta.com') {setTimeout(function(){document.documentElement.insertAdjacentHTML('beforeend', _style);}, 500);}
  7717. if (curSite.pager && curSite.pager.type == 5) window.top.document.xiu_pausePage = pausePage
  7718. // 点击事件(临时暂停翻页)
  7719. getCSS('#Autopage_number').onclick = function () {
  7720. if (pausePage) {this.style = 'color: #FF5722 !important; font-style: italic !important;';} else {this.style = '';}
  7721. pausePage = !pausePage;
  7722. if (curSite.pager && curSite.pager.type == 5) window.top.document.xiu_pausePage = pausePage
  7723. };
  7724. status = getCSS('#Autopage_number');
  7725. set();
  7726. }
  7727. // 监听储存当前页码的对象值的变化
  7728. function set(){
  7729. Object.defineProperty(pageNum, 'now', {
  7730. set: function(value) {
  7731. this._now = value;
  7732. if (status) status.textContent = value;
  7733. }
  7734. });
  7735. }
  7736. function del(){
  7737. if (!status) return
  7738. status.style.display = 'none';
  7739. }
  7740. }
  7741. // 菜单开关
  7742. function menu_switch(menu_status, Name, Tips) {
  7743. if (menu_status === true){
  7744. GM_setValue(Name, false);
  7745. } else {
  7746. GM_setValue(Name, true);
  7747. }
  7748. if (Name === 'menu_page_number') {
  7749. if (menu_status === true){pageNumber('del');} else {pageNumber('add');}
  7750. registerMenuCommand(); // 重新注册脚本菜单
  7751. } else {
  7752. location.reload();}
  7753. };
  7754. // 生成 SiteTypeID
  7755. function setSiteTypeID() {
  7756. let num = 0
  7757. for (let val in DBSite) {
  7758. DBSite[val].SiteTypeID = num = num + 1;
  7759. }
  7760. }
  7761. // 获取 Cookie
  7762. function getCookie(name) {
  7763. if (!name) return ''
  7764. let arr = document.cookie.split(';');
  7765. name += '='
  7766. for (let i=0; i<arr.length; i++) {
  7767. let now = arr[i].trim();
  7768. if (now.indexOf(name) == 0) return now.substring(name.length, now.length);
  7769. }
  7770. return '';
  7771. }
  7772. // 插入位置
  7773. function getAddTo(num) {
  7774. switch (num) {
  7775. case 1:
  7776. return 'beforebegin'; break;
  7777. case 2:
  7778. return 'afterbegin'; break;
  7779. case 3:
  7780. case 6:
  7781. return 'beforeend'; break;
  7782. case 4:
  7783. case 5:
  7784. return 'afterend'; break;
  7785. }
  7786. }
  7787. // 滚动条事件
  7788. function windowScroll(fn1) {
  7789. var beforeScrollTop = document.documentElement.scrollTop || document.body.scrollTop,
  7790. fn = fn1 || function () {};
  7791. setTimeout(function () { // 延时 1 秒执行,避免刚载入到页面就触发翻页事件
  7792. window.addEventListener('scroll', function (e) {
  7793. var afterScrollTop = document.documentElement.scrollTop || document.body.scrollTop,
  7794. delta = afterScrollTop - beforeScrollTop;
  7795. if (delta == 0) return false;
  7796. fn(delta > 0 ? 'down' : 'up', e);
  7797. beforeScrollTop = afterScrollTop;
  7798. }, false);
  7799. }, 1000)
  7800. }
  7801. // 自定义 urlchange 事件(用来监听 URL 变化)
  7802. function addUrlChangeEvent() {
  7803. history.pushState = ( f => function pushState(){
  7804. var ret = f.apply(this, arguments);
  7805. window.dispatchEvent(new Event('pushstate'));
  7806. window.dispatchEvent(new Event('urlchange'));
  7807. return ret;
  7808. })(history.pushState);
  7809.  
  7810. history.replaceState = ( f => function replaceState(){
  7811. var ret = f.apply(this, arguments);
  7812. window.dispatchEvent(new Event('replacestate'));
  7813. window.dispatchEvent(new Event('urlchange'));
  7814. return ret;
  7815. })(history.replaceState);
  7816.  
  7817. window.addEventListener('popstate',()=>{
  7818. window.dispatchEvent(new Event('urlchange'))
  7819. });
  7820. }
  7821. })();