自动无缝翻页

无缝拼接下一页内容(瀑布流),目前支持:[所有「Discuz!、Flarum、phpBB、Xiuno、XenForo、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(以上仅一小部分,更多的写不下了...

当前为 2021-12-08 提交的版本,查看 最新版本

  1. // ==UserScript==
  2. // @name 自动无缝翻页
  3. // @version 4.0.6
  4. // @author X.I.U
  5. // @description 无缝拼接下一页内容(瀑布流),目前支持:[所有「Discuz!、Flarum、phpBB、Xiuno、XenForo、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(以上仅一小部分,更多的写不下了...
  6. // @match *://*/*
  7. // @connect www.xuexiniu.com
  8. // @connect bbs.xuexiniu.com
  9. // @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
  10. // @grant GM_xmlhttpRequest
  11. // @grant GM_registerMenuCommand
  12. // @grant GM_unregisterMenuCommand
  13. // @grant GM_openInTab
  14. // @grant GM_getValue
  15. // @grant GM_setValue
  16. // @grant GM_notification
  17. // @grant unsafeWindow
  18. // @license GPL-3.0 License
  19. // @run-at document-end
  20. // @namespace https://github.com/XIU2/UserScript
  21. // @supportURL https://github.com/XIU2/UserScript
  22. // @homepageURL https://github.com/XIU2/UserScript
  23. // ==/UserScript==
  24.  
  25. (function() {
  26. 'use strict';
  27. var menuAll = [
  28. ['menu_disable', '✅ 已启用 (点击对当前网站禁用)', '❌ 已禁用 (点击对当前网站启用)', []],
  29. ['menu_discuz_thread_page', '帖子内自动翻页', '帖子内自动翻页', true],
  30. ['menu_page_number', '显示当前页码及点击暂停翻页', '显示当前页码及点击暂停翻页', true],
  31. ['menu_pause_page', '左键双击网页空白处暂停翻页', '左键双击网页空白处暂停翻页', false]
  32. ], menuId = [], webType = 0, curSite = {SiteTypeID: 0}, DBSite, SiteType, pausePage = true, pageNum = {now: 1, _now: 1}, locationC = false, nowLocation = '', lp = location.pathname, forumWebsite = ['cs.rin.ru', 'www.flyert.com', 'bbs.pediy.com', 'www.libaclub.com', 'tieba.baidu.com', 'www.cadtutor.net', 'www.theswamp.org', 'www.xuexiniu.com', 'bbs.xuexiniu.com', 'www.taoguba.com.cn', 'www.cnprint.org', 'www.ablesci.com'];
  33. for (let i=0;i<menuAll.length;i++){ // 如果读取到的值为 null 就写入默认值
  34. if (GM_getValue(menuAll[i][0]) == null){GM_setValue(menuAll[i][0], menuAll[i][3])};
  35. }
  36. registerMenuCommand();
  37. if (menuId.length < 2) {return}
  38. // 注册脚本菜单
  39. function registerMenuCommand() {
  40. if (menuId.length != []){
  41. for (let i=0;i<menuId.length;i++){
  42. GM_unregisterMenuCommand(menuId[i]);
  43. }
  44. }
  45. for (let i=0;i<menuAll.length;i++) { // 循环注册脚本菜单
  46. menuAll[i][3] = GM_getValue(menuAll[i][0]);
  47. if (menuAll[i][0] === 'menu_disable') { // 启用/禁用
  48.  
  49. if (menu_disable('check')) { // 当前网站在禁用列表中
  50. menuId[i] = GM_registerMenuCommand(`${menuAll[i][2]}`, function(){menu_disable('del')});
  51. return
  52. } else { // // 不在禁用列表中
  53. webType = doesItSupport(); // 判断网站类型(即是否支持),顺便直接赋值
  54. if (webType === 0) {
  55. 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});});
  56. console.info('[自动无缝翻页] - 不支持当前网站 [ ' + location.href + ' ],欢迎申请支持: https://github.com/XIU2/UserScript / https://greasyfork.org/zh-CN/scripts/96880/feedback');
  57. return
  58. } else if (webType === -1) {
  59. return
  60. }
  61. menuId[i] = GM_registerMenuCommand(`${menuAll[i][1]}`, function(){menu_disable('add')});
  62. }
  63.  
  64. } else if (menuAll[i][0] === 'menu_discuz_thread_page') { // 帖子内自动翻页 (仅论坛)
  65.  
  66. if ([2,4,5,6].indexOf(webType) > -1 || forumWebsite.indexOf(location.hostname) > -1) {
  67. menuId[i] = GM_registerMenuCommand(`${menuAll[i][3]?'✅':'❌'} ${menuAll[i][1]}`, function(){menu_switch(menuAll[i][3], menuAll[i][0], menuAll[i][2])});
  68. }
  69.  
  70. } else {
  71. menuId[i] = GM_registerMenuCommand(`${menuAll[i][3]?'✅':'❌'} ${menuAll[i][1]}`, function(){menu_switch(menuAll[i][3], menuAll[i][0], menuAll[i][2])});
  72. }
  73. }
  74. 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});});
  75. }
  76.  
  77. // 网站规则
  78. function setDBSite() {
  79. /*
  80. functionS: 匹配该网站域名时要执行的函数(一般用于根据 URL 分配相应翻页规则)
  81. locationC: 对于使用 pjax 技术的网站,需要监听 URL 变化来重新判断翻页规则(需要放在 functionS 中)
  82.  
  83. insStyle: 要插入网页的 CSS Style 样式
  84. hiddenPN: 不显示脚本左下角的页码
  85. history: 添加历史记录 并 修改当前 URL
  86. retry: 允许获取失败后重试
  87.  
  88. pager: {
  89. type: 翻页模式
  90. 1 = 由脚本实现自动无缝翻页(适用于:静态加载内容网站,常规模式)
  91.  
  92. 2 = 只需要点击下一页按钮(适用于:网站自带了 自动无缝翻页 功能)
  93. nextText: 按钮文本,当按钮文本 = 该文本时,才会点击按钮加载下一页(避免一瞬间加载太多次下一页,下同)
  94. nextTextOf: 按钮文本的一部分,当按钮文本包含该文本时,才会点击按钮加载下一页
  95. nextHTML: 按钮内元素,当按钮内元素 = 该元素内容时,才会点击按钮加载下一页
  96. interval: 点击间隔时间,对于没有按钮文字变化的按钮,可以手动指定间隔时间(单位 ms,默认 300,当指定上面三个时,会忽略 interval)
  97. isHidden: 只有下一页按钮可见时(没有被隐藏),才会点击
  98.  
  99. 3 = 依靠 [基准元素] 与 [浏览器可视区域底部] 之间的距离缩小来触发翻页(适用于:主体元素下方内容太多 且 高度不固定时)
  100. scrollE: 作为基准线的元素(一般为底部页码元素)
  101. scrollD: 基准元素 - 可视区域底部
  102.  
  103. 4 = 动态加载类网站(适用于:简单的动态加载内容网站)
  104. insertE: 用来插入元素的函数
  105.  
  106. 5 = 插入 iframe 方式来加载下一页,无限套娃(适用于:部分动态加载内容的网站,需要允许 iframe 且支持通过 GET/POST 直接打开下一页)
  107. insStyle: 加载 iframe 前要插入的 CSS Style 样式(比如为了悬浮的样式与下一页的重叠,隐藏网页底部间距提高阅读连续性)
  108. iframe: 这个必须加到 pager{} 外面(这样才会在该域名的 iframe 框架下运行脚本)
  109. forceTarget: 强制新标签页打开链接(适用于一些使用 pjax 技术的链接)
  110.  
  111. 6 = 通过 iframe 获取下一页动态加载内容插入本页,只有一个娃(适用于:部分动态加载内容的网站,与上面不同的是,该模式适合简单的网页,没有复杂事件什么的)
  112. loadTime: 预留的网页加载时间,确保网页内容加载完成
  113. forceTarget: 强制新标签页打开链接
  114.  
  115. nextL: 下一页链接所在元素
  116. pageE: 要从下一页获取的元素
  117. insertP: 下一页元素插入本页的位置(数组第一个是基准元素,第二个是基准元素的前后具体位置)
  118. 1 = 插入基准元素自身的前面
  119. 2 = 插入基准元素内,第一个子元素前面
  120. 3 = 插入基准元素内,最后一个子元素后面
  121. 4 = 插入基准元素自身的后面
  122. 5 = 插入 pageE 列表最后一个元素的后面(该 insertP 可以直接省略不写,等同于 ['pageE', 5] )
  123. 6 = 插入该元素自身内部末尾(针对小说网站等文本类的)
  124. // 小技巧:当基准元素是下一页主体元素的父元素时(或者说要将下一页元素插入到本页同元素最后一个后面时)是可以省略不写 insertP
  125. 例如:当 pageE: 'css;ul>li' 且 insertP: ['css;ul', 3] 时,实际等同于 ['css;ul>li', 5]
  126. 当 pageE: 'css;.item' 且 insertP: ['css;.item', 4] 时,实际等同于 ['css;.item', 5]
  127. 当 pageE: 'css;.item' 且 insertP: ['css;.page', 1] 时,实际等同于 ['css;.item', 5]
  128. 注意:如 pageE 中选择了多类元素,则不能省略 insertP(比如包含 `,` 与 `|` 符号)
  129.  
  130. replaceE: 要替换为下一页内容的元素(比如页码)
  131. scrollD: 翻页动作触发点([滚动条] 与 [网页底部] 之间的距离),数值越大,越早开始翻页,一般是访问网页速度越慢,该值就需要越大
  132.  
  133. scriptT: 单独插入 <script> 标签
  134. 0 = 下一页的所有 <script> 标签
  135. 1 = 下一页的所有 <script> 标签(不包括 src 链接)
  136. 2 = 下一页主体元素 (pageE) 的同级 <script> 标签
  137. 3 = 下一页主体元素 (pageE) 的子元素 <script> 标签
  138.  
  139. interval: 翻页后间隔时间(单位 ms)
  140. forceHTTPS: 下一页链接强制 HTTPS
  141. },
  142. function: {
  143. bF = 插入前执行函数
  144. aF = 插入后执行函数
  145. pF = 参数
  146. }
  147. */ //<<< 规则简单说明 >>>
  148. DBSite = {
  149. discuz_forum: {
  150. pager: {
  151. type: 2,
  152. nextL: 'css;#autopbn',
  153. nextTextOf: '下一页',
  154. scrollD: 1500
  155. }
  156. }, // Discuz! 论坛 - 帖子列表(自带无缝加载下一页按钮的)
  157. discuz_guide: {
  158. pager: {
  159. type: 1,
  160. nextL: 'css;a.nxt:not([href^="javascript"]) ,a.next:not([href^="javascript"])',
  161. pageE: 'id("threadlist")//table[./tbody[contains(@id, "normalthread_")]]/tbody[not(@id="separatorline")]',
  162. replaceE: 'css;.pg, .pages',
  163. scrollD: 1000
  164. }
  165. }, // Discuz! 论坛 - 导读页 及 帖子列表(不带无缝加载下一页按钮的)
  166. discuz_waterfall: {
  167. pager: {
  168. type: 1,
  169. nextL: 'css;a.nxt:not([href^="javascript"]) ,a.next:not([href^="javascript"])',
  170. pageE: 'css;#waterfall > li',
  171. replaceE: 'css;.pg, .pages',
  172. scrollD: 1000
  173. }
  174. }, // Discuz! 论坛 - 图片模式的帖子列表(不带无缝加载下一页按钮的)
  175. discuz_thread: {
  176. insStyle: '.pgbtn {display: none;}',
  177. pager: {
  178. type: 1,
  179. nextL: 'css;a.nxt:not([href^="javascript"]) ,a.next:not([href^="javascript"])',
  180. pageE: 'css;#postlist > div[id^="post_"]',
  181. replaceE: 'css;.pg, .pages',
  182. scrollD: 1000
  183. },
  184. function: {
  185. bF: src_bF,
  186. pF: [0, 'img[file]', 'file']
  187. }
  188. }, // Discuz! 论坛 - 帖子内
  189. discuz_search: {
  190. pager: {
  191. type: 1,
  192. nextL: 'css;a.nxt:not([href^="javascript"]) ,a.next:not([href^="javascript"])',
  193. pageE: 'css;#threadlist > ul',
  194. replaceE: 'css;.pg, .pages',
  195. scrollD: 1000
  196. }
  197. }, // Discuz! 论坛 - 搜索页
  198. discuz_youspace: {
  199. pager: {
  200. type: 1,
  201. nextL: 'css;a.nxt:not([href^="javascript"]) ,a.next:not([href^="javascript"])',
  202. pageE: 'css;form:not([action^="search.php?"]) tbody > tr:not(.th)',
  203. replaceE: 'css;.pg, .pages',
  204. scrollD: 1000
  205. }
  206. }, // Discuz! 论坛 - 回复页、主题页(别人的)
  207. discuz_collection: {
  208. pager: {
  209. type: 1,
  210. nextL: 'css;a.nxt:not([href^="javascript"]) ,a.next:not([href^="javascript"])',
  211. pageE: 'css;#ct .bm_c table > tbody',
  212. replaceE: 'css;.pg, .pages',
  213. scrollD: 1000
  214. }
  215. }, // Discuz! 论坛 - 淘帖页
  216. flarum: {
  217. functionS: function() {locationC = true;if (!indexOF('/d/')) {curSite = DBSite.flarum;}},
  218. pager: {
  219. type: 2,
  220. nextL: 'css;.DiscussionList-loadMore > button',
  221. isHidden: true,
  222. scrollD: 1000
  223. }
  224. }, // Flarum 论坛
  225. phpbb: {
  226. functionS: function() {if (indexOF('/viewforum.php')) {
  227. curSite = DBSite.phpbb;
  228. } else if (indexOF('/viewtopic.php') && GM_getValue('menu_discuz_thread_page')) {
  229. curSite = DBSite.phpbb_post;
  230. } else if (indexOF('/search.php')) {
  231. curSite = DBSite.phpbb_search;
  232. }},
  233. pager: {
  234. type: 1,
  235. nextL: 'css;.pagination li.next a[rel="next"], .topic-actions .pagination strong~a',
  236. pageE: 'css;.forumbg:not(.announcement) ul.topiclist.topics > li',
  237. replaceE: 'css;.action-bar .pagination, .topic-actions .pagination',
  238. scrollD: 2000
  239. }
  240. }, // phpBB 论坛 - 帖子列表
  241. phpbb_post: {
  242. pager: {
  243. type: 1,
  244. nextL: 'css;.pagination li.next a[rel="next"], .topic-actions .pagination strong~a',
  245. pageE: 'css;div.post[id], div.post[id]+hr',
  246. replaceE: 'css;.action-bar .pagination, .topic-actions .pagination',
  247. scrollD: 2000
  248. }
  249. }, // phpBB 论坛 - 帖子内
  250. phpbb_search: {
  251. pager: {
  252. type: 1,
  253. nextL: 'css;.pagination li.next a[rel="next"], .topic-actions .pagination strong~a',
  254. pageE: 'css;div.search.post',
  255. replaceE: 'css;.action-bar .pagination, .pagination',
  256. scrollD: 2000
  257. }
  258. }, // phpBB 论坛 - 搜索页
  259. xenforo: {
  260. functionS: function() {if (indexOF(/\/(forums|f)\//)) {
  261. curSite = DBSite.xenforo;
  262. } else if (indexOF(/\/(threads|t)\//) && GM_getValue('menu_discuz_thread_page')) {
  263. curSite = DBSite.xenforo_post;
  264. } else if (indexOF('/search/')) {
  265. curSite = DBSite.xenforo_search;
  266. }},
  267. pager: {
  268. type: 1,
  269. nextL: 'css;a.pageNav-jump--next',
  270. pageE: 'css;.structItemContainer-group.js-threadList > div',
  271. replaceE: 'css;nav.pageNavWrapper',
  272. scrollD: 2500
  273. }
  274. }, // XenForo 论坛 - 帖子列表
  275. xenforo_post: {
  276. pager: {
  277. type: 1,
  278. nextL: 'css;a.pageNav-jump--next',
  279. pageE: 'css;.block-body.js-replyNewMessageContainer > article',
  280. replaceE: 'css;nav.pageNavWrapper',
  281. scrollD: 2500
  282. }
  283. }, // XenForo 论坛 - 帖子内
  284. xenforo_search: {
  285. pager: {
  286. type: 1,
  287. nextL: 'css;a.pageNav-jump--next',
  288. pageE: 'css;ol.block-body > li',
  289. replaceE: 'css;nav.pageNavWrapper',
  290. scrollD: 2500
  291. }
  292. }, // XenForo 论坛 - 搜索页
  293. xiuno: {
  294. functionS: function() {if (lp == '/' || indexOF(/\/(index|forum)/)) {curSite = DBSite.xiuno;} else if (indexOF('/thread') && GM_getValue('menu_discuz_thread_page')) {curSite = DBSite.xiuno_post;}},
  295. pager: {
  296. type: 1,
  297. nextL: '//li[@class="page-item"]/a[text()="▶"]',
  298. pageE: 'css;ul.threadlist > li',
  299. replaceE: 'css;ul.pagination',
  300. scrollD: 1500
  301. }
  302. }, // Xiuno 论坛 - 帖子列表
  303. xiuno_post: {
  304. pager: {
  305. type: 1,
  306. nextL: '//li[@class="page-item"]/a[text()="▶"]',
  307. pageE: 'css;li.post[data-pid]:not(.newpost)',
  308. replaceE: 'css;ul.pagination',
  309. scrollD: 1500
  310. }
  311. }, // Xiuno 论坛 - 帖子内
  312. dux: {
  313. functionS: function() {if (!indexOF('.html')) curSite = DBSite.dux;},
  314. host: 'www.puresys.net',
  315. pager: {
  316. type: 1,
  317. nextL: 'css;li.next-page > a',
  318. pageE: 'css;.content > article',
  319. replaceE: 'css;.content > .pagination',
  320. scrollD: 1500
  321. },
  322. function: {
  323. bF: src_bF,
  324. pF: [0, 'img.thumb[data-src]', 'data-src']
  325. }
  326. }, // WordPress 的 DUX、XIU、D8 主题
  327. begin: {
  328. functionS: function() {if (location.search.slice(0,3) === '?s=') {curSite = DBSite.begin_search;} else if (!indexOF('.html')) {curSite = DBSite.begin;}},
  329. pager: {
  330. type: 2,
  331. nextL: 'css;div[id^="ias_trigger_"]',
  332. interval: 500,
  333. scrollD: 1500
  334. }
  335. }, // WordPress 的 Begin 主题
  336. begin_search: {
  337. pager: {
  338. type: 1,
  339. nextL: 'css;a.next',
  340. pageE: 'css;#main > ul > li',
  341. replaceE: 'css;nav.pagination',
  342. scrollD: 1500
  343. }
  344. }, // WordPress 的 Begin 主题 - 搜索页
  345. biquge: {
  346. functionS: function() {if (indexOF(/\d+\/\d+\.html/)) {curSite = DBSite.biquge;}},
  347. insStyle: 'img {display: none !important;}',
  348. history: true,
  349. pager: {
  350. type: 1,
  351. nextL: '//a[contains(text(), "下一章") or contains(text(), "下一页")]',
  352. pageE: 'css;#content, #chaptercontent, .chaptercontent, #BookText',
  353. insertP: ['css;#content, #chaptercontent, .chaptercontent, #BookText', 6],
  354. replaceE: '//*[./a[contains(text(), "下一章") or contains(text(), "下一页")]]',
  355. scrollD: 1500
  356. }
  357. }, // 笔趣阁 模板的小说网站
  358. baidu: {
  359. host: 'www.baidu.com',
  360. functionS: function() {locationC = true; if (lp == '/s') {curSite = DBSite.baidu;} else if (indexOF('/s')) {location.hostname = 'm.baidu.com';}},
  361. insStyle: '.new-pmd .c-img-border {position: initial !important;} .op-bk-polysemy-video__wrap.c-gap-bottom {display: none !important;}',
  362. history: true,
  363. pager: {
  364. type: 1,
  365. nextL: 'id("page")//a[contains(text(),"下一页")]',
  366. pageE: 'css;#content_left > *',
  367. replaceE: 'css;#page',
  368. scrollD: 2000
  369. }
  370. }, // 百度 搜索
  371. baidu_m: {
  372. host: 'm.baidu.com',
  373. functionS: function() {if (indexOF('/s')) curSite = DBSite.baidu_m;},
  374. history: true,
  375. insStyle: 'div.result[tpl="recommend_list"], #page-copyright {display: none !important;}',
  376. pager: {
  377. type: 1,
  378. nextL: 'css;a[class^="new-nextpage"]',
  379. pageE: 'css;#results > *',
  380. replaceE: 'css;#page-controller',
  381. scrollD: 2000
  382. }
  383. }, // 百度 搜索 - 手机版
  384. google: {
  385. host: /\.google\./,
  386. functionS: function() {if (lp == '/search' && !indexOF('tbm=isch', 's')) {
  387. curSite = DBSite.google;
  388. } else if (lp == '/scholar') {
  389. curSite = DBSite.google_scholar;
  390. }},
  391. history: true,
  392. pager: {
  393. type: 1,
  394. nextL: 'css;#pnnext',
  395. pageE: 'id("search")/* | //style[not(contains(text(), "table,div,span,p{display:none}"))]',
  396. insertP: ['css;#search', 3],
  397. replaceE: 'id("navcnt") | id("rcnt")//div[@role="navigation"]',
  398. scriptT: 0,
  399. scrollD: 3000
  400. },
  401. function: {
  402. bF: google_bF
  403. }
  404. }, // 谷歌 搜索
  405. bing: {
  406. host: ['www.bing.com','cn.bing.com'],
  407. functionS: function() {if (lp == '/search') {
  408. curSite = DBSite.bing;
  409. } else if (lp == '/academic/search') {
  410. curSite = DBSite.bing_academic;
  411. }},
  412. insStyle: '.b_imagePair.square_mp > .inner {display: none !important;}',
  413. history: true,
  414. pager: {
  415. type: 1,
  416. nextL: 'css;a.sb_pagN',
  417. pageE: 'css;#b_results > li:not(.b_msg):not([class="b_ans"]):not(.b_pag):not(#mfa_root)',
  418. replaceE: 'css;#b_results > .b_pag',
  419. scrollD: 1500
  420. },
  421. function: {
  422. bF: bing_bF
  423. }
  424. }, // 必应 搜索
  425. sogou: {
  426. host: 'www.sogou.com',
  427. functionS: function() {if (location.pathname != '/') {curSite = DBSite.sogou;}},
  428. history: true,
  429. pager: {
  430. type: 1,
  431. nextL: 'css;#sogou_next',
  432. pageE: 'css;.results > *',
  433. replaceE: 'css;#pagebar_container',
  434. scriptT: 3,
  435. scrollD: 1500
  436. }
  437. }, // 搜狗 搜索
  438. sogou_weixin: {
  439. host: 'weixin.sogou.com',
  440. functionS: function() {if (lp == '/') {
  441. curSite = DBSite.sogou_weixin;
  442. } else if (lp == '/weixin') {
  443. curSite = DBSite.sogou_weixin_search;
  444. }},
  445. pager: {
  446. type: 2,
  447. nextL: 'css;#look-more',
  448. interval: 1000,
  449. scrollD: 1000
  450. }
  451. }, // 搜狗微信 - 首页
  452. sogou_weixin_search: {
  453. history: true,
  454. pager: {
  455. type: 1,
  456. nextL: 'css;#sogou_next',
  457. pageE: 'css;ul[class*="news-list"] > li',
  458. replaceE: 'css;#pagebar_container',
  459. scrollD: 1200
  460. }
  461. }, // 搜狗微信 - 搜索
  462. toutiao: {
  463. host: ['www.toutiao.com', 'so.toutiao.com'],
  464. functionS: function() {if (location.hostname != 'www.toutiao.com' && lp == '/search') curSite = DBSite.toutiao;},
  465. history: true,
  466. pager: {
  467. type: 1,
  468. nextL: '//div[contains(@class, "-pagination")]/a[string()="下一页"]',
  469. pageE: 'css;div[class*="-result-list"] > .result-content[data-i]',
  470. replaceE: 'css;div[class*="-pagination"]',
  471. scrollD: 1500
  472. },
  473. function: {
  474. bF: toutiao_bF
  475. }
  476. }, // 头条 搜索
  477. so: {
  478. host: 'www.so.com',
  479. functionS: function() {if (location.pathname != '/') {curSite = DBSite.so; insStyle('img {opacity: 1 !important;}')}},
  480. history: true,
  481. pager: {
  482. type: 1,
  483. nextL: 'css;a#snext',
  484. pageE: 'css;ul.result > li, style:not(src)',
  485. insertP: ['css;ul.result', 3],
  486. replaceE: 'css;#page',
  487. scrollD: 1500
  488. },
  489. function: {
  490. bF: src_bF,
  491. pF: [0, 'img[data-isrc]', 'data-isrc']
  492. }
  493. }, // 360 搜索
  494. duckduckgo: {
  495. host: 'duckduckgo.com',
  496. functionS: function() {
  497. if (getCookie('av') != '1') {
  498. document.cookie='av=1; expires=Thu, 18 Dec 2031 12:00:00 GMT; path=/'; // 写入 Cookie 强制开启自带的无缝翻页功能
  499. location.reload(); // 刷新网页
  500. }
  501. },
  502. }, // DuckDuckGo 搜索
  503. startpage: {
  504. host: ['startpage.com', 'www.startpage.com'],
  505. functionS: function() {if (indexOF('/search')) {curSite = DBSite.startpage;}},
  506. history: true,
  507. pager: {
  508. type: 1,
  509. nextL: startpage_nextL,
  510. pageE: 'css;section.w-gl--desktop > div',
  511. replaceE: 'css;.pagination',
  512. scrollD: 2000
  513. }
  514. }, // Startpage 搜索
  515. yandex: {
  516. host: 'yandex.com',
  517. functionS: function() {if (lp == '/search/') {curSite = DBSite.yandex;}},
  518. history: true,
  519. pager: {
  520. type: 1,
  521. nextL: 'css;a.pager__item_kind_next',
  522. pageE: 'css;#search-result > *, style',
  523. insertP: ['css;#search-result', 3],
  524. replaceE: 'css;.pager',
  525. scrollD: 2000
  526. }
  527. }, // Yandex 搜索
  528. yahoo: {
  529. host: 'search.yahoo.com',
  530. functionS: function() {if (indexOF('/search')) {curSite = DBSite.yahoo;}},
  531. history: true,
  532. pager: {
  533. type: 1,
  534. nextL: 'css;.pagination a.next',
  535. pageE: 'css;#web ol > li',
  536. replaceE: 'css;.pagination',
  537. scrollD: 2000
  538. }
  539. }, // Yahoo 搜索
  540. yahoo_jp: {
  541. host: 'search.yahoo.co.jp',
  542. functionS: function() {if (indexOF('/search')) {curSite = DBSite.yahoo_jp;}},
  543. history: true,
  544. pager: {
  545. type: 1,
  546. nextL: 'css;.Pagenation__next > a',
  547. pageE: 'css;.Contents__innerGroupBody > div',
  548. replaceE: 'css;.Pagenation',
  549. scrollD: 2000
  550. }
  551. }, // Yahoo 搜索 (JP)
  552. qwant: {
  553. host: 'www.qwant.com',
  554. functionS: function() {locationC = true; if (indexOF('q=', 's') && indexOF('t=web', 's')) {curSite = DBSite.qwant;}},
  555. pager: {
  556. type: 2,
  557. nextL: 'css;button[data-testid="buttonShowMore"]',
  558. interval: 500,
  559. scrollD: 2000
  560. }
  561. }, // Qwant 搜索
  562. ecosia: {
  563. host: 'www.ecosia.org',
  564. functionS: function() {if (lp == '/search') {curSite = DBSite.ecosia;}},
  565. history: true,
  566. pager: {
  567. type: 1,
  568. nextL: 'css;nav.pagination a[aria-label="Next page"]',
  569. pageE: 'css;section.mainline > div:not(.related-queries)',
  570. replaceE: 'css;nav.pagination',
  571. scrollD: 1500
  572. }
  573. }, // Ecosia 搜索
  574. magi: {
  575. host: 'magi.com',
  576. functionS: function() {if (lp == '/search') {curSite = DBSite.magi;}},
  577. pager: {
  578. type: 2,
  579. nextL: 'css;.card[data-type="next"]',
  580. nextText: '加载更多',
  581. scrollD: 1500
  582. }
  583. }, // Magi 搜索
  584. ask: {
  585. host: ['ask.com', 'www.ask.com'],
  586. functionS: function() {if (lp == '/web') {curSite = DBSite.ask;}},
  587. insStyle: '.PartialSearchResults-heading {display: none !important;}',
  588. history: true,
  589. pager: {
  590. type: 1,
  591. nextL: 'css;li.PartialWebPagination-next > a',
  592. pageE: 'css;.PartialSearchResults.mid',
  593. replaceE: 'css;.PartialWebPagination',
  594. scrollD: 2000
  595. }
  596. }, // ASK 搜索
  597. fsou: {
  598. host: 'fsou.cc',
  599. functionS: function() {if (lp == '/search') {curSite = DBSite.fsou;}},
  600. history: true,
  601. retry: 1000,
  602. pager: {
  603. type: 6,
  604. nextL: () => getNextP('css;.selected.turn-page-text.turn-page-num', 'pageIndex=', /pageIndex=\d+/),
  605. pageE: 'css;#search-result > div',
  606. replaceE: 'css;.bottom-pagination',
  607. loadTime: 1000,
  608. scrollD: 3000
  609. },
  610. function: {
  611. bF: fsou_bF
  612. }
  613. }, // F 搜
  614. baidu_tieba: {
  615. host: ['tieba.baidu.com', 'jump2.bdimg.com'],
  616. functionS: function() {if (location.hostname == 'jump2.bdimg.com') location.hostname = 'tieba.baidu.com';
  617. if (lp == '/f') {
  618. baidu_tieba_1(); // 右侧悬浮发帖按钮点击事件(解决自动翻页导致无法发帖的问题)
  619. curSite = DBSite.baidu_tieba;
  620. } else if (indexOF('/p/') && GM_getValue('menu_discuz_thread_page')) {
  621. curSite = DBSite.baidu_tieba_post;
  622. } else if (lp == '/f/search/res') {
  623. curSite = DBSite.baidu_tieba_search;
  624. }},
  625. insStyle: 'img.j_retract {margin-top: 0 !important;margin-bottom: 0 !important;}', // 修复帖子列表中预览图片,在切换下一个/上一个图片时,多出来的图片上下边距
  626. iframe: true,
  627. pager: {
  628. type: 4,
  629. nextL: function() {if (getNextE('css;a.next.pagination-item')) getPageElems_(curSite.pageUrl + '&pagelets=frs-list%2Fpagelet%2Fthread&pagelets_stamp=' + new Date().getTime());},
  630. pageE: 'css;#thread_list > li',
  631. insertP: ['css;#thread_list', 3],
  632. insertE: baidu_tieba_insertE,
  633. replaceE: 'css;#frs_list_pager',
  634. interval: 2000,
  635. scrollD: 2500
  636. },
  637. function: {
  638. bF: src_bF,
  639. pF: [0, 'img[data-original]', 'data-original']
  640. }
  641. }, // 百度贴吧 - 帖子列表
  642. baidu_tieba_post: {
  643. forceTarget: true,
  644. insStyle: '.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 元素
  645. pager: {
  646. type: 5,
  647. nextL: '//li[contains(@class,"pb_list_pager")]/a[text()="下一页"]',
  648. insStyle: 'ul.tbui_aside_float_bar, .core_title_wrap_bright.tbui_follow_fixed.core_title_absolute_bright {display: none !important;}',
  649. scrollD: 1500
  650. }
  651. }, // 百度贴吧 - 帖子内
  652. baidu_tieba_search: {
  653. pager: {
  654. type: 1,
  655. nextL: 'css;a.next',
  656. pageE: 'css;.s_post_list > div',
  657. replaceE: 'css;.pager',
  658. scriptT: 1,
  659. scrollD: 1000
  660. }
  661. }, // 百度贴吧 - 搜索页
  662. douban_subject_comments: {
  663. host: 'movie.douban.com',
  664. functionS: function() {if (indexOF('/subject') && indexOF('/comments')) {
  665. curSite = DBSite.douban_subject_comments;
  666. } else if (indexOF('/subject') && indexOF('/reviews')) {
  667. curSite = DBSite.douban_subject_reviews;
  668. } else if(indexOF('/subject') && indexOF('/episode') || indexOF('/subject') && indexOF('/tv_discuss')) {
  669. curSite = DBSite.douban_subject_episode;
  670. } else if(indexOF('/people') && indexOF('/collect')) { // 看过的电影
  671. curSite = DBSite.douban_people_collect;
  672. }},
  673. pager: {
  674. type: 1,
  675. nextL: 'css;a.next',
  676. pageE: 'css;#comments > .comment-item',
  677. replaceE: 'css;#paginator',
  678. scrollD: 1000
  679. }
  680. }, // 豆瓣 - 短评
  681. douban_subject_reviews: {
  682. pager: {
  683. type: 1,
  684. nextL: 'css;link[rel="next"]',
  685. pageE: 'css;.review-list > div',
  686. replaceE: 'css;.paginator',
  687. scrollD: 1000
  688. }
  689. }, // 豆瓣 - 影评
  690. douban_subject_episode: {
  691. pager: {
  692. type: 1,
  693. nextL: 'css;link[rel="next"]',
  694. pageE: 'css;#comments > div',
  695. replaceE: 'css;.paginator',
  696. scrollD: 1000
  697. }
  698. }, // 豆瓣 - 剧评
  699. douban_people_collect: {
  700. pager: {
  701. type: 1,
  702. nextL: 'css;link[rel="next"]',
  703. pageE: 'css;.grid-view > div',
  704. replaceE: 'css;.paginator',
  705. scrollD: 1000
  706. }
  707. }, // 豆瓣 - 看过的电影
  708. douban_group: {
  709. host: 'www.douban.com',
  710. functionS: function() {if (indexOF('/group/topic/')) {
  711. curSite = DBSite.douban_group_topic;
  712. } else if (indexOF('/group/explore')) {
  713. curSite = DBSite.douban_group_explore;
  714. } else if (indexOF('/group/') && indexOF('/discussion')) {
  715. curSite = DBSite.douban_group;
  716. }},
  717. pager: {
  718. type: 1,
  719. nextL: 'css;span.next > a',
  720. pageE: 'css;table.olt > tbody > tr:not(.th)',
  721. replaceE: 'css;.paginator',
  722. scrollD: 1000
  723. }
  724. }, // 豆瓣 - 小组
  725. douban_group_explore: {
  726. pager: {
  727. type: 1,
  728. nextL: 'css;span.next > a',
  729. pageE: 'css;#content .article > div > .channel-item',
  730. replaceE: 'css;.paginator',
  731. scrollD: 1000
  732. }
  733. }, // 豆瓣 - 小组讨论精选
  734. douban_group_topic: {
  735. pager: {
  736. type: 1,
  737. nextL: 'css;span.next > a',
  738. pageE: 'css;#comments > li',
  739. replaceE: 'css;.paginator',
  740. scrollD: 1000
  741. }
  742. }, // 豆瓣 - 小组帖子内
  743. zhihu: {
  744. host: 'www.zhihu.com',
  745. functionS: function() {locationC = true; if (indexOF(/\/people\/.+\/.+/) || indexOF('/collection/')) {curSite = DBSite.zhihu; if (self != top) insStyle('#ProfileHeader {display: none !important;}')}},
  746. forceTarget: true,
  747. history: true,
  748. iframe: true,
  749. pager: {
  750. type: 5,
  751. nextL: function() {
  752. let next = getCSS('.Pagination .PaginationButton--current+button:not(.PaginationButton-next)');
  753. if (next) return (location.origin + location.pathname + '?page=' + next.textContent)
  754. },
  755. scrollD: 2000
  756. }
  757. }, // 知乎 - 用户主页、收藏夹
  758. weibo_comment: {
  759. host: 'weibo.com',
  760. pager: {
  761. type: 2,
  762. nextL: 'css;a[action-type="click_more_comment"]',
  763. nextText: '查看更多c',
  764. scrollD: 1000
  765. }
  766. }, // 微博评论
  767. tianya: {
  768. host: 'bbs.tianya.cn',
  769. functionS: function() {if (indexOF('/list')) {
  770. curSite = DBSite.tianya;
  771. } else if (indexOF('/post')) {
  772. curSite = DBSite.tianya_post;
  773. }},
  774. pager: {
  775. type: 1,
  776. nextL: '//div[contains(@class, "pages")]/div[@class="links"]/a[text()="下一页"]',
  777. pageE: 'css;.tab-bbs-list > tbody:not(:first-of-type)',
  778. replaceE: '//div[contains(@class, "pages")]',
  779. scrollD: 1500
  780. }
  781. }, // 天涯社区
  782. tianya_post: {
  783. pager: {
  784. type: 1,
  785. nextL: 'css;a.js-keyboard-next',
  786. pageE: 'css;.atl-main > div[class="atl-item"]',
  787. replaceE: 'css;.atl-pages > form',
  788. scrollD: 2000
  789. }
  790. }, // 天涯社区 - 帖子内
  791. nga_thread: {
  792. host: ['bbs.nga.cn', 'ngabbs.com', 'nga.178.com', 'g.nga.cn'],
  793. iframe: true,
  794. functionS: function() {locationC = true;
  795. if (lp == '/thread.php') { // 帖子列表
  796. curSite = DBSite.nga_thread;
  797. } else if (lp == '/read.php') { // 帖子内
  798. curSite = DBSite.nga_read;
  799. }},
  800. pager: {
  801. type: 1,
  802. nextL: 'css;#pagebbtm a[title="下一页"]',
  803. pageE: 'css;#topicrows > tbody, #topicrows > script',
  804. insertP: ['css;#topicrows', 3],
  805. replaceE: 'css;div[name="pageball"]',
  806. scriptT: 2,
  807. scrollD: 1000
  808. },
  809. function: {
  810. aF: function() {document.body.appendChild(document.createElement('script')).textContent = 'commonui.topicArg.loadAll();';}
  811. }
  812. }, // NGA - 各版块帖子列表
  813. nga_read: {
  814. pager: {
  815. type: 1,
  816. nextL: 'css;#pagebbtm a[title*="下一页"]',
  817. pageE: 'id("m_posts_c")/table | id("m_posts_c")/script | //script[contains(text(), "commonui.userInfo.setAll")]',
  818. insertP: ['css;#m_posts_c', 3],
  819. replaceE: 'css;div[name="pageball"]',
  820. scriptT: 2,
  821. scrollD: 1000
  822. }
  823. }, // NGA - 帖子内
  824. v2ex_recent: {
  825. host: ['v2ex.com', 'www.v2ex.com'],
  826. functionS: function() {if (lp == '/') {
  827. v2ex_aF('#Main a.topic-link:not([target])');
  828. } else if (lp == '/recent') {
  829. curSite = DBSite.v2ex_recent;
  830. v2ex_aF('#Main a.topic-link:not([target])');
  831. } else if (lp == '/notifications') {
  832. curSite = DBSite.v2ex_notifications;
  833. v2ex_aF('#Main a[href^="/t/"]:not([target])');
  834. } else if (lp == '/balance') {
  835. curSite = DBSite.v2ex_balance;
  836. } else if (indexOF('/go/')) {
  837. curSite = DBSite.v2ex_go;
  838. v2ex_aF('#Main a.topic-link:not([target])');
  839. } else if (indexOF('/replies')) {
  840. curSite = DBSite.v2ex_replies;
  841. v2ex_aF('#Main a[href^="/t/"]:not([target])');
  842. }},
  843. pager: {
  844. type: 1,
  845. nextL: 'css;a.page_current+a.page_normal',
  846. pageE: 'css;.cell.item',
  847. replaceE: 'css;#Main > .box > .cell[style]:not(.item) > table',
  848. scrollD: 1500
  849. },
  850. function: {
  851. aF: v2ex_aF,
  852. pF: '#Main a.topic-link:not([target])'
  853. }
  854. }, // V2EX - 最近主题页
  855. v2ex_notifications: {
  856. pager: {
  857. type: 1,
  858. nextL: 'css;a.page_current+a.page_normal',
  859. pageE: 'css;#notifications > div',
  860. replaceE: 'css;#Main > .box > .cell[style] > table',
  861. scrollD: 1500
  862. },
  863. function: {
  864. aF: v2ex_aF,
  865. pF: '#Main a[href^="/t/"]:not([target])'
  866. }
  867. }, // V2EX - 提醒消息页
  868. v2ex_replies: {
  869. pager: {
  870. type: 1,
  871. nextL: 'css;a.page_current+a.page_normal',
  872. 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]',
  873. insertP: ['//div[@id="Main"]//div[@class="box"]//div[@class="cell"][last()]', 1],
  874. replaceE: 'css;#Main > .box > .cell[style] > table',
  875. scrollD: 1500
  876. },
  877. function: {
  878. aF: v2ex_aF,
  879. pF: '#Main a[href^="/t/"]:not([target])'
  880. }
  881. }, // V2EX - 用户回复页
  882. v2ex_go: {
  883. pager: {
  884. type: 1,
  885. nextL: 'css;a.page_current+a.page_normal',
  886. pageE: 'css;#TopicsNode > div',
  887. replaceE: 'css;#Main > .box > .cell[style] > table',
  888. scrollD: 1500
  889. },
  890. function: {
  891. aF: v2ex_aF,
  892. pF: '#Main a.topic-link:not([target])'
  893. }
  894. }, // V2EX - 分类主题页
  895. v2ex_balance: {
  896. pager: {
  897. type: 1,
  898. nextL: 'css;a.page_current+a.page_normal',
  899. pageE: 'css;#Main .box > div:not(.cell) > table > tbody > tr:not(:first-child)',
  900. replaceE: 'css;#Main > .box > .cell[style] > table',
  901. scrollD: 1000
  902. }
  903. }, // V2EX - 账户余额页
  904. jandan: {
  905. host: 'jandan.net',
  906. functionS: function() {if (lp == '/' || indexOF('/page/')) {
  907. curSite = DBSite.jandan;
  908. } else if (lp == '/dzh') {
  909. curSite = DBSite.jandan_dzh;
  910. } else {
  911. curSite = DBSite.jandan_comment;
  912. }},
  913. insStyle: '#nav_prev, #nav_next, .post.f:not(.list-post) {display: none !important;}',
  914. pager: {
  915. type: 1,
  916. nextL: '//div[@class="wp-pagenavi"]/a[contains(text(), "下一页") or contains(text(), "更多文章")]',
  917. pageE: 'css;#content > .list-post',
  918. replaceE: 'css;.wp-pagenavi',
  919. scrollD: 1500
  920. },
  921. function: {
  922. bF: src_bF,
  923. pF: [0, 'img[data-original]', 'data-original']
  924. }
  925. }, // 煎蛋网
  926. jandan_comment: {
  927. insStyle: '#nav_prev, #nav_next {display: none !important;}',
  928. pager: {
  929. type: 1,
  930. nextL: 'css;a.previous-comment-page',
  931. pageE: 'css;ol.commentlist > li[id^="comment-"], script[src^="//cdn.jandan.net/static/min/"]',
  932. insertP: ['css;ol.commentlist', 3],
  933. replaceE: 'css;.cp-pagenavi',
  934. scriptT: 2,
  935. scrollD: 1500
  936. }
  937. }, // 煎蛋网
  938. jandan_dzh: {
  939. pager: {
  940. type: 2,
  941. nextL: 'css;.show_more',
  942. interval: 1500,
  943. scrollD: 1500
  944. }
  945. }, // 煎蛋网 - 大杂烩
  946. qiushibaike: {
  947. host: 'www.qiushibaike.com',
  948. functionS: function() {insStyle('.qrcode-wrap, .qrcode-wrap-img, .index-side-left-AD1 {display: none !important;}');
  949. if (lp == '/') {
  950. curSite = DBSite.qiushibaike;
  951. } else if (!indexOF('/article/')) {
  952. curSite = DBSite.qiushibaike_;
  953. }},
  954. pager: {
  955. type: 1,
  956. nextL: '//ul[@class="pagination"]//a[./span[@class="next"]]',
  957. pageE: 'css;.recommend-article > ul > li',
  958. replaceE: 'css;ul.pagination',
  959. scrollD: 1500
  960. }
  961. }, // 糗事百科
  962. qiushibaike_: {
  963. pager: {
  964. type: 1,
  965. nextL: '//ul[@class="pagination"]//a[./span[@class="next"]]',
  966. pageE: 'css;[id^="qiushi_tag_"]',
  967. replaceE: 'css;ul.pagination',
  968. scrollD: 1500
  969. }
  970. }, // 糗事百科 - 分类页
  971. lkong: {
  972. host: 'www.lkong.com',
  973. functionS: function() {if (indexOF('/forum/')) {
  974. curSite = DBSite.lkong;
  975. } else if (indexOF('/thread/')) {
  976. curSite = DBSite.lkong_thread;
  977. }},
  978. pager: {
  979. type: 1,
  980. nextL: lkong_nextL,
  981. pageE: '//div[@class="main-title"]/parent::div/parent::div | //head/style[@data-emotion-css]',
  982. insertP: ['//div[@class="main-title"][1]/parent::div/parent::div/parent::div', 3],
  983. replaceE: 'css;ul.ant-pagination',
  984. interval: 500,
  985. scrollD: 1200
  986. }
  987. }, // 龙的天空 - 各版块帖子列表
  988. lkong_thread: {
  989. pager: {
  990. type: 1,
  991. nextL: lkong_nextL,
  992. pageE: '//div[@class="main-content"]/parent::div | //head/style[@data-emotion-css]',
  993. insertP: ['//div[@class="main-content"][1]/parent::div/parent::div', 3],
  994. replaceE: 'css;ul.ant-pagination',
  995. interval: 500,
  996. scrollD: 1200
  997. }
  998. }, // 龙的天空 - 帖子内
  999. pediy_forum: {
  1000. host: 'bbs.pediy.com',
  1001. functionS: function() {if (indexOF('/forum-')) {
  1002. curSite = DBSite.pediy_forum;
  1003. } else if (indexOF('/thread-')) {
  1004. if (GM_getValue('menu_discuz_thread_page')) {curSite = DBSite.pediy_thread;}
  1005. }},
  1006. pager: {
  1007. type: 1,
  1008. nextL: '//a[@class="page-link" and text()="▶"]',
  1009. pageE: 'css;table.threadlist > tbody > tr',
  1010. replaceE: 'css;ul.pagination',
  1011. scrollD: 1500
  1012. }
  1013. }, // 看雪论坛 - 各版块帖子列表
  1014. pediy_thread: {
  1015. pager: {
  1016. type: 1,
  1017. nextL: '//a[@class="page-link" and text()="▶"]',
  1018. pageE: 'css;table.postlist > tbody > tr[data-pid]',
  1019. replaceE: 'css;ul.pagination',
  1020. scrollD: 1500
  1021. }
  1022. }, // 看雪论坛 - 帖子内
  1023. bangumitv: {
  1024. host: 'bangumi.tv',
  1025. functionS: function() {
  1026. if (indexOF('/browser') || indexOF('/subject_search')) {
  1027. curSite = DBSite.bangumitv;
  1028. } else if (indexOF('/forum')) {
  1029. curSite = DBSite.bangumitv_forum;
  1030. }},
  1031. pager: {
  1032. type: 1,
  1033. nextL: '//div[@class="page_inner"]/a[text()="››"]',
  1034. pageE: 'css;ul#browserItemList > li',
  1035. replaceE: 'css;.page_inner',
  1036. scrollD: 1500
  1037. }
  1038. }, // 番组计划
  1039. bangumitv_forum: {
  1040. pager: {
  1041. type: 1,
  1042. nextL: '//div[@class="page_inner"]/a[text()="››"]',
  1043. pageE: 'css;.topic_list > tbody:last-of-type > tr.topic',
  1044. replaceE: 'css;.page_inner',
  1045. scrollD: 1500
  1046. }
  1047. }, // 番组计划 - 小组帖子列表
  1048. dongchedi: {
  1049. host: 'www.dongchedi.com',
  1050. functionS: function() {locationC = true;
  1051. if (indexOF('/community/')) {
  1052. curSite = DBSite.dongchedi;
  1053. }},
  1054. history: true,
  1055. pager: {
  1056. type: 1,
  1057. nextL: 'css;li.pagination-item.is-active+li > a',
  1058. pageE: 'css;.data-wrapper > section.community-card, style',
  1059. insertP: ['css;.data-wrapper', 3],
  1060. replaceE: '//ul[./li[contains(@class, "pagination-item")]]',
  1061. scrollD: 2000
  1062. },
  1063. function: {
  1064. bF: function(pageElems) {
  1065. pageElems.forEach(function (one) {
  1066. one.querySelectorAll('.g-load-img-wrap, .tw-absolute.tw-cursor-pointer, .avatar').forEach(function (now) {
  1067. getCSS('noscript+img', now).src = getCSS('noscript > img', now).src;
  1068. });
  1069. });
  1070. return pageElems
  1071. }
  1072. }
  1073. }, // 懂车帝论坛
  1074. kdslife: {
  1075. host: 'club.kdslife.com',
  1076. functionS: function() {
  1077. if (indexOF('/f_')) {
  1078. curSite = DBSite.kdslife;
  1079. } else if (indexOF('/t_')) {
  1080. curSite = DBSite.kdslife_t;
  1081. }},
  1082. pager: {
  1083. type: 1,
  1084. nextL: '//div[@class="fr i3_r"]/a[text()="后一页"]',
  1085. pageE: 'css;ul.main_List > li.i2:not(.h_bg)',
  1086. replaceE: 'css;ul.main_List > li.i3',
  1087. scrollD: 1000
  1088. }
  1089. }, // 宽带山论坛
  1090. kdslife_t: {
  1091. pager: {
  1092. type: 1,
  1093. nextL: '//div[@class="pages"]/a[text()=">>"]',
  1094. pageE: 'css;#reply_list_panel > *, script[src*="ui/js/kds.js"]',
  1095. insertP: ['css;#reply_list_panel', 3],
  1096. replaceE: 'css;.pages',
  1097. scriptT: 2,
  1098. scrollD: 1000
  1099. }
  1100. }, // 宽带山论坛 - 帖子内
  1101. libaclub: {
  1102. host: 'www.libaclub.com',
  1103. functionS: function() {
  1104. if (lp == '/' || indexOF('/date_')) {
  1105. curSite = DBSite.libaclub;
  1106. } else if (indexOF('/f_')) {
  1107. curSite = DBSite.libaclub_f;
  1108. } else if (indexOF('/t_') || indexOF('/reply_')) {
  1109. curSite = DBSite.libaclub_t;
  1110. } else if (indexOF('/prt_')) {
  1111. curSite = DBSite.libaclub_prt;
  1112. } else if (lp == '/facade.php') {
  1113. curSite = DBSite.libaclub_search;
  1114. }},
  1115. insStyle: 'li.ui-list-merchant-ad, .ui-nav-appImage {display: none !important;}',
  1116. pager: {
  1117. type: 1,
  1118. nextL: '//div[@class="ui-crumbs-more"]/a[@class="fn-link"][1]',
  1119. pageE: 'css;ul.ui-list > li:not(.ui-list-item-head):not(.ui-list-merchant-ad)',
  1120. replaceE: 'css;div.ui-crumbs-more',
  1121. scrollD: 1200
  1122. }
  1123. }, // 篱笆网论坛
  1124. libaclub_f: {
  1125. insStyle: 'li.ui-list-merchant-ad, .ui-nav-appImage {display: none !important;}',
  1126. pager: {
  1127. type: 1,
  1128. nextL: 'css;a.ui-paging-next',
  1129. pageE: 'css;ul.ui-list > li:not(.ui-list-item-head):not(.ui-list-merchant-ad)',
  1130. replaceE: 'css;div.ui-paging',
  1131. scrollD: 1200
  1132. }
  1133. }, // 篱笆网论坛 - 各版块帖子列表
  1134. libaclub_t: {
  1135. insStyle: 'li.ui-list-merchant-ad, .ui-nav-appImage {display: none !important;}',
  1136. pager: {
  1137. type: 1,
  1138. nextL: 'css;a.ui-paging-next',
  1139. pageE: 'css;.ui-box-content > div.ui-topic, .ui-box-content > a[name]',
  1140. insertP: ['css;.ui-box-content', 3],
  1141. replaceE: 'css;div.ui-paging',
  1142. scrollD: 1500
  1143. }
  1144. }, // 篱笆网论坛 - 帖子内
  1145. libaclub_prt: {
  1146. insStyle: 'li.ui-list-merchant-ad, .ui-nav-appImage {display: none !important;}',
  1147. pager: {
  1148. type: 1,
  1149. nextL: 'css;a.ui-paging-next',
  1150. pageE: 'css;ul.ui-list > li',
  1151. replaceE: 'css;div.ui-paging',
  1152. scrollD: 2000
  1153. }
  1154. }, // 篱笆网论坛 - 帖子内 - 打印版
  1155. libaclub_search: {
  1156. insStyle: 'li.ui-list-merchant-ad, .ui-nav-appImage {display: none !important;}',
  1157. pager: {
  1158. type: 1,
  1159. nextL: '//div[@class="ui-page"]/a[contains(text(), "下一页")]',
  1160. pageE: 'css;.ui-box-main > ul.ui-list > li',
  1161. replaceE: 'css;div.ui-page',
  1162. scrollD: 1200
  1163. }
  1164. }, // 篱笆网论坛 - 搜索页
  1165. taoguba: {
  1166. host: 'www.taoguba.com.cn',
  1167. functionS: function() {insStyle('#joinTGB {display: none !important;}')
  1168. if (indexOF('/Article/')) {
  1169. curSite = DBSite.taoguba_t;
  1170. } else if (indexOF('/shenghuoba/')) {
  1171. curSite = DBSite.taoguba_;
  1172. } else if (indexOF(/\/bbs|zongban|dianzan|jinghua\//)) {
  1173. curSite = DBSite.taoguba;
  1174. }},
  1175. pager: {
  1176. type: 1,
  1177. nextL: function() {
  1178. let next = getXpath('//div[contains(@class, "t_page01")]/a[contains(text(), "下一页")]'), next_ = '/';
  1179. if (next) {
  1180. next = next.getAttribute('onclick').replace('gotoPage(','').replace(')','').split(',');
  1181. if (indexOF(/\/dianzan|jinghua\//)) next_ = '-';
  1182. if (parseInt(next[0]) <= parseInt(next[2])) {return (`${location.origin}/${location.pathname.split('/')[1]}/${next[0]}${next_}${next[1]}`)}
  1183. }
  1184. return '';
  1185. },
  1186. pageE: 'css;.p_list > .p_list01[class*="user_"]',
  1187. replaceE: 'css;.t_page',
  1188. scrollD: 1000
  1189. }
  1190. }, // 淘股吧论坛
  1191. taoguba_: {
  1192. pager: {
  1193. type: 1,
  1194. nextL: function() {
  1195. let next = getCSS('#N_go_pageBtn'), next_ = location.pathname.split('/')[2].split('-')[0];
  1196. if (next && (parseInt(next.dataset.now) + 1 <= parseInt(next.dataset.total))) {
  1197. if (!next_) next_ = 'H';
  1198. return (`${location.origin}/shenghuoba/${next_}-${parseInt(next.dataset.now) + 1}`)
  1199. }
  1200. return '';
  1201. },
  1202. pageE: 'css;.lifeContent-topicList-item',
  1203. replaceE: 'css;.N_sortPage ',
  1204. scrollD: 1000
  1205. }
  1206. }, // 淘股吧论坛 - 生活圈
  1207. taoguba_t: {
  1208. pager: {
  1209. type: 1,
  1210. nextL: function() {
  1211. let next = getXpath('//div[contains(@class, "t_page01")]/a[contains(text(), "下一页")]');
  1212. if (next) {
  1213. next = next.getAttribute('onclick').replace('gotoPageTopic(','').replace(')','').split(',');
  1214. if (parseInt(next[0]) <= parseInt(next[1])) {return (`${location.origin}/Article/${getCSS("#looktopicID").value}/${next[0]}`)}
  1215. }
  1216. return '';
  1217. },
  1218. pageE: 'css;div[id^="reply_"]',
  1219. replaceE: 'css;.t_page',
  1220. scrollD: 1000
  1221. },
  1222. function: {
  1223. bF: src_bF,
  1224. pF: [0, 'img[data-original]', 'data-original']
  1225. }
  1226. }, // 淘股吧论坛 - 帖子内
  1227. lowendtalk: {
  1228. host: 'lowendtalk.com',
  1229. pager: {
  1230. type: 1,
  1231. nextL: 'css;a.Next',
  1232. pageE: 'css;ul.DataList > li',
  1233. replaceE: 'css;.Pager',
  1234. scrollD: 1500
  1235. }
  1236. }, // LowEndTalk
  1237. lieyou: {
  1238. host: 'bbs.lieyou888.com',
  1239. functionS: function() {if (indexOF('/forum')) {curSite = DBSite.lieyou;}},
  1240. pager: {
  1241. type: 1,
  1242. nextL: '//div[contains(@class, "_pageNav")]/a[text()="下一页"]',
  1243. pageE: 'css;ul.gb-bbs-list > li',
  1244. replaceE: 'css;._pageNav',
  1245. scrollD: 1000
  1246. },
  1247. function: {
  1248. bF: src_bF,
  1249. pF: [0, 'img[original]', 'original']
  1250. }
  1251. }, // 芥子空间论坛
  1252. xcar_forumdisplay: {
  1253. host: 'www.xcar.com.cn',
  1254. functionS: function() {if (lp == '/bbs/forumdisplay.php') {curSite = DBSite.xcar_forumdisplay}},
  1255. pager: {
  1256. type: 1,
  1257. nextL: 'css;a.page_down',
  1258. pageE: 'css;.table-section > dl:not(.table_head)',
  1259. replaceE: 'css;.forumList_page',
  1260. scrollD: 2000
  1261. }
  1262. }, // 爱卡汽车网论坛 - 各版块帖子列表
  1263. flyert_forumdisplay: {
  1264. host: 'www.flyert.com',
  1265. functionS: function() {if (indexOF('/forum-') || indexOF('mod=forumdisplay', 's')) {
  1266. curSite = DBSite.flyert_forumdisplay;
  1267. } else if (indexOF('/forum') || indexOF('mod=viewthread', 's')) {
  1268. if (GM_getValue('menu_discuz_thread_page')) {curSite = DBSite.flyert_viewthread;}
  1269. }},
  1270. pager: {
  1271. type: 1,
  1272. nextL: 'css;a.nxt:not([href*="javascript"])',
  1273. pageE: 'css;#threadlist table > tbody[id^="normalthread_"]',
  1274. replaceE: 'css;.pg',
  1275. scrollD: 2500
  1276. }
  1277. }, // 飞客网论坛 - 各版块帖子列表
  1278. flyert_viewthread: {
  1279. pager: {
  1280. type: 1,
  1281. nextL: 'css;a.nxt:not([href*="javascript"])',
  1282. pageE: 'css;#postlist > .comiis_viewbox',
  1283. replaceE: 'css;.comiis_pgs > .pg',
  1284. scrollD: 3000
  1285. }
  1286. }, // 飞客网论坛 - 帖子内
  1287. cnprint: {
  1288. host: 'www.cnprint.org',
  1289. functionS: function() {if (indexOF('/forum/')) {curSite = DBSite.cnprint;} else if (indexOF('/thread/') && GM_getValue('menu_discuz_thread_page')) {curSite = DBSite.cnprint_thread;}},
  1290. pager: {
  1291. type: 1,
  1292. nextL: 'css;a[rel="next"]',
  1293. pageE: 'css;tbody[id*="threadbits_forum"] > tr',
  1294. replaceE: 'css;.pagenav',
  1295. scrollD: 2500
  1296. }
  1297. }, // CPC 中文印刷社区
  1298. cnprint_thread: {
  1299. pager: {
  1300. type: 1,
  1301. nextL: 'css;a[rel="next"]',
  1302. pageE: 'css;#posts > div:not([id])',
  1303. replaceE: 'css;.pagenav',
  1304. scrollD: 2000
  1305. }
  1306. }, // CPC 中文印刷社区 - 帖子内
  1307. adnmb3: {
  1308. host: ['adnmb3.com', 'www.tnmb.org'],
  1309. functionS: function() {
  1310. if (indexOF('/m/f/')) {
  1311. curSite = DBSite.adnmb3_mf;
  1312. } else if (indexOF('/m/t/')) {
  1313. curSite = DBSite.adnmb3_mt;
  1314. } else if (indexOF(/\/(f|Forum)\//)) {
  1315. curSite = DBSite.adnmb3;
  1316. } else if (indexOF('/t/')) {
  1317. curSite = DBSite.adnmb3_t;
  1318. }},
  1319. pager: {
  1320. type: 1,
  1321. nextL: '//ul[contains(@class, "pagination")]//a[text()="下一页"]',
  1322. pageE: 'css;.h-threads-list > *, script[src$="/h.desktop.js"]',
  1323. insertP: ['css;.h-threads-list', 3],
  1324. replaceE: '//ul[contains(@class, "pagination")]',
  1325. scriptT: 2,
  1326. scrollD: 2500
  1327. }
  1328. }, // A 岛
  1329. adnmb3_t: {
  1330. pager: {
  1331. type: 1,
  1332. nextL: '//ul[contains(@class, "pagination")]//a[text()="下一页"]',
  1333. pageE: 'css;.h-threads-list > .h-threads-item > .h-threads-item-replys, script[src$="/h.desktop.js"]',
  1334. insertP: ['css;.h-threads-list > .h-threads-item', 3],
  1335. replaceE: '//ul[contains(@class, "pagination")]',
  1336. scriptT: 2,
  1337. scrollD: 2500
  1338. }
  1339. }, // A 岛 - 帖子内
  1340. adnmb3_mf: {
  1341. pager: {
  1342. type: 1,
  1343. nextL: '//li[contains(@class, "pagination-next")]//a[text()="下一页"]',
  1344. 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"]',
  1345. insertP: ['css;#h-threads-pagination', 1],
  1346. replaceE: 'css;#h-threads-pagination',
  1347. scriptT: 2,
  1348. scrollD: 2500
  1349. }
  1350. }, // A 岛 - 帖子列表(手机版)
  1351. adnmb3_mt: {
  1352. pager: {
  1353. type: 1,
  1354. nextL: '//li[contains(@class, "pagination-next")]//a[text()="下一页"]',
  1355. pageE: 'css;.h-threads-replylist > div, script[src$="/h.mobile.js"]',
  1356. insertP: ['css;.h-threads-replylist', 3],
  1357. replaceE: 'css;#h-threads-pagination',
  1358. scriptT: 2,
  1359. scrollD: 2500
  1360. }
  1361. }, // A 岛 - 帖子内(手机版)
  1362. pixiv: {
  1363. host: 'www.pixiv.net',
  1364. functionS: function() {locationC = true;
  1365. if (lp == '/') {
  1366. forceTarget();
  1367. } else if (indexOF('/tags/')/* && self == top*/) {
  1368. curSite = DBSite.pixiv;
  1369. } else if (indexOF('/users/') && indexOF(/\/(artworks|illustrations|manga)/)) {
  1370. curSite = DBSite.pixiv_user;
  1371. } else if (indexOF('/artworks/')) {
  1372. setTimeout(function(){getXpath('//button[contains(string(), "查看全部") or contains(string(), "See all") or contains(string(), "すべて見る") or contains(string(), "모두 보기")]').click();}, 1000)
  1373. }
  1374. },
  1375. forceTarget: true,
  1376. insStyle: 'ul[class*="-1 "] > li {display: inline !important;} #root{margin-bottom: -175px;} ul > li > button[class^="sc-"][style="background-color: rgb(0, 0, 0);"], a[href^="/premium/lead/lp"] {display: none !important;}',
  1377. history: true,
  1378. iframe: true,
  1379. pager: {
  1380. type: 5,
  1381. nextL: 'css;a[aria-disabled="false"][class*="filterProps-Styled-Component"][href]:last-child',
  1382. /*pageE: '//ul[contains(@class, "-1 ")]/li',
  1383. insertP: ['//ul[contains(@class, "-1 ")]', 3],
  1384. replaceE: '//nav[./a[@aria-disabled="false"][contains(@class, "filterProps-Styled-Component")]]',*/
  1385. scrollD: 2000
  1386. }
  1387. }, // Pixiv - 分类页
  1388. pixiv_user: {
  1389. forceTarget: true,
  1390. insStyle: '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;}',
  1391. history: true,
  1392. pager: {
  1393. type: 5,
  1394. nextL: 'css;a[aria-disabled="false"][class*="filterProps-Styled-Component"][href]:last-child',
  1395. /*pageE: '//ul[contains(@class, "-1 ")]/li',
  1396. insertP: ['//ul[contains(@class, "-1 ")]', 3],
  1397. replaceE: '//nav[./a[@aria-disabled="false"][contains(@class, "filterProps-Styled-Component")]]',*/
  1398. scrollD: 2000
  1399. }
  1400. }, // Pixiv - 用户作品页
  1401. vilipix: {
  1402. host: 'www.vilipix.com',
  1403. functionS: function() {locationC = true; if (lp == '/') {forceTarget();} else if (indexOF(/\/(tags|user|new|ranking)/)) {curSite = DBSite.vilipix;}},
  1404. forceTarget: true,
  1405. history: true,
  1406. pager: {
  1407. type: 6,
  1408. nextL: function() {let next = getCSS('li.number.active+li.number'); if (next) return (location.origin + location.pathname + '?p=' + next.textContent)},
  1409. pageE: 'css;ul.illust-content > li',
  1410. replaceE: 'css;ul.el-pager',
  1411. loadTime: 800,
  1412. scrollD: 2000
  1413. }
  1414. }, // Vilipix
  1415. pixivision: {
  1416. host: 'www.pixivision.net',
  1417. functionS: function() {if (!indexOF('/a/')) curSite = DBSite.pixivision;},
  1418. pager: {
  1419. type: 1,
  1420. nextL: 'css;a.next',
  1421. pageE: 'css;li.article-card-container',
  1422. replaceE: 'css;._pager',
  1423. scrollD: 2000
  1424. }
  1425. }, // Pixivision
  1426. _58pic: {
  1427. host: 'www.58pic.com',
  1428. functionS: function() {insStyle('.qt-model-t.login-model {display: none !important;}');
  1429. if (indexOF(/\/(tupian|piccate)\//)) {
  1430. curSite = DBSite._58pic;
  1431. 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;}')
  1432. } else if (indexOF('/c/')) {
  1433. curSite = DBSite._58pic_c;
  1434. }},
  1435. insStyle: '.qtw-card.place-box, .card-lazy, .is-line .is-back {display: none !important;}',
  1436. pager: {
  1437. type: 1,
  1438. nextL: '//div[contains(@class,"page-box")]//a[text()="下一页"]',
  1439. pageE: 'css;.card-grid-box:not(.favorites-box) > div',
  1440. replaceE: 'css;.page-box',
  1441. scrollD: 2500
  1442. },
  1443. function: {
  1444. bF: src_bF,
  1445. pF: [0, 'img[data-original]', 'data-original']
  1446. }
  1447. }, // 千图网 - 分类/搜索页
  1448. _58pic_c: {
  1449. pager: {
  1450. type: 1,
  1451. nextL: '//div[contains(@class,"page-box")]//a[text()="下一页"]',
  1452. pageE: 'css;.list-box > .qtw-card',
  1453. replaceE: 'css;.page-box',
  1454. scrollD: 4000
  1455. },
  1456. function: {
  1457. bF: src_bF,
  1458. pF: [0, 'img[data-original]', 'data-original']
  1459. }
  1460. }, // 千图网 - 专题/收藏夹
  1461. _588ku: {
  1462. host: '588ku.com',
  1463. insStyle: '.listlogin-box.listloginBox, .CLdialogV1, .editIndexEntry, .globalRSideB {display: none !important;}',
  1464. pager: {
  1465. type: 1,
  1466. nextL: '//ul[contains(@class, "page-list")]//a[text()="下一页"]',
  1467. pageE: 'css;.data-box .dataList, .data-box .data-list',
  1468. insertP: ['css;.data-box .dataList, .data-box .data-list', 3],
  1469. replaceE: 'css;ul.page-list',
  1470. scrollD: 2000
  1471. },
  1472. function: {
  1473. bF: src_bF,
  1474. pF: [0, 'img[data-original]', 'data-original']
  1475. }
  1476. }, // 千库网
  1477. nipic: {
  1478. host: ['www.nipic.com', 'soso.nipic.com'],
  1479. insStyle: 'li.search-works-item {display: none !important;}',
  1480. pager: {
  1481. type: 1,
  1482. nextL: '//a[@title="下一页" or text()="下一页"][not(contains(@class, "search-works-nextpage"))]',
  1483. pageE: 'css;ul#img-list-outer > li',
  1484. replaceE: 'css;.common-page-box, .common-seo-page-box',
  1485. scrollD: 2000
  1486. },
  1487. function: {
  1488. bF: src_bF,
  1489. pF: [0, 'img[data-original]', 'data-original']
  1490. }
  1491. }, // 昵图网
  1492. ztupic: {
  1493. host: 'www.ztupic.com',
  1494. functionS: function() {if (lp != '/' && !indexOF('/sucai/')) {curSite = DBSite.ztupic;}},
  1495. pager: {
  1496. type: 1,
  1497. nextL: 'css;a.page-link[rel="next"]',
  1498. pageE: 'css;.floor_item',
  1499. replaceE: 'css;ul.pagination',
  1500. scrollD: 2000
  1501. },
  1502. function: {
  1503. bF: src_bF,
  1504. pF: [0, 'img[data-src]', 'data-src']
  1505. }
  1506. }, // 众图网
  1507. pixabay: {
  1508. host: 'pixabay.com',
  1509. pager: {
  1510. type: 1,
  1511. nextL: '//a[text()="›"]',
  1512. pageE: 'css;[class^="results"] > [class^="container"] > div',
  1513. replaceE: '//a[text()="›"]',
  1514. scrollD: 2000
  1515. },
  1516. function: {
  1517. bF: src_bF,
  1518. pF: [0, 'img[data-lazy-src]', 'data-lazy-src']
  1519. }
  1520. }, // Pixabay
  1521. logosc: {
  1522. host: 'www.logosc.cn',
  1523. functionS: function() {if (indexOF('/so/')) {curSite = DBSite.logosc;}},
  1524. pager: {
  1525. type: 2,
  1526. nextL: 'css;button.so-pablo-button',
  1527. interval: 1500,
  1528. scrollD: 1500
  1529. }
  1530. }, // 搜图神器 (免费无版权)
  1531. sccnn: {
  1532. host: 'www.sccnn.com',
  1533. pager: {
  1534. type: 1,
  1535. nextL: '//ul[@class="listpage"]//a[text()=">"]',
  1536. pageE: 'css;td[valign="TOP"]:not([width]) tr[valign="Middle"]',
  1537. replaceE: 'css;ul.listpage',
  1538. scrollD: 1000
  1539. }
  1540. }, // 素材中国
  1541. sccnn_so: {
  1542. host: 'so.sccnn.com',
  1543. pager: {
  1544. type: 1,
  1545. nextL: 'css;font[color="Red"]+a.F16',
  1546. pageE: '//tr[@valign="Top"][1]/preceding-sibling::tr',
  1547. replaceE: '//tr[@valign="Top"][last()]',
  1548. scrollD: 1000
  1549. }
  1550. }, // 素材中国 - 搜索页
  1551. iconfont: {
  1552. host: 'www.iconfont.cn',
  1553. functionS: function() {locationC = true; if (indexOF('/search/')) curSite = DBSite.iconfont;},
  1554. forceTarget: true,
  1555. insStyle: '.footer, header .bind-tips, .block-pagination-wrap {display: none !important;}',
  1556. history: true,
  1557. iframe: true,
  1558. pager: {
  1559. type: 5,
  1560. nextL: () => getNextP('css;li.active+li:not(.disabled) > a', 'page=', /page=\d+/),
  1561. scrollD: 1000
  1562. }
  1563. }, // iconfont
  1564. iconarchive: {
  1565. host: 'iconarchive.com',
  1566. functionS: function() {if (indexOF(/\/(tag|search|category)/)) curSite = DBSite.iconarchive;},
  1567. history: true,
  1568. pager: {
  1569. type: 1,
  1570. nextL: 'css;a.next',
  1571. pageE: 'css;.icondetail',
  1572. replaceE: 'css;.pagination',
  1573. scrollD: 2000
  1574. }
  1575. }, // IconArchive
  1576. puxiang: {
  1577. host: 'www.puxiang.com',
  1578. functionS: function() {if (lp == '/search/favorite') {
  1579. curSite = DBSite.puxiang_collect;
  1580. } else if (lp == '/search/puxiang' || lp == '/list' || lp == '/galleries' || lp == '/articles') {
  1581. curSite = DBSite.puxiang;
  1582. } else if (lp == '/') {
  1583. curSite = DBSite.puxiang; curSite.pager.scrollD = 4000;
  1584. }},
  1585. pager: {
  1586. type: 1,
  1587. nextL: 'css;li.next > a',
  1588. pageE: 'css;.work-list > div',
  1589. replaceE: 'css;.pagerbar',
  1590. scrollD: 1500
  1591. }
  1592. }, // 普象网 - 作品集/搜索页
  1593. puxiang_collect: {
  1594. pager: {
  1595. type: 1,
  1596. nextL: 'css;li.next > a',
  1597. pageE: 'css;.collect-list > div',
  1598. replaceE: 'css;.pagerbar',
  1599. scrollD: 1500
  1600. }
  1601. }, // 普象网 - 收藏夹
  1602. xuexiniu: {
  1603. host: ['www.xuexiniu.com', 'bbs.xuexiniu.com'],
  1604. functionS: function() {
  1605. if (getCSS('body#nv_forum.pg_forumdisplay')) {
  1606. if (getCSS('ul.waterfall')) {
  1607. curSite = DBSite.xuexiniu_forum;
  1608. } else {
  1609. curSite = DBSite.discuz_guide
  1610. }
  1611. } else if (getCSS('body#nv_forum.pg_viewthread') && GM_getValue('menu_discuz_thread_page')) {
  1612. curSite = DBSite.xuexiniu_thread;
  1613. } else if (indexOF('/search.php')) {
  1614. curSite = DBSite.xuexiniu_search;
  1615. } else {
  1616. curSite = DBSite.xuexiniu;
  1617. }
  1618. },
  1619. pager: {
  1620. type: 1,
  1621. nextL: '//a[@class="page-link" and contains(text(), "下一页")]',
  1622. pageE: 'css;.row > .col-sm-6',
  1623. replaceE: 'css;ul.pagination',
  1624. scrollD: 1000
  1625. }
  1626. }, // 学犀牛 - 分类页
  1627. xuexiniu_forum: {
  1628. pager: {
  1629. type: 1,
  1630. nextL: 'css;a.nxt:not([href*="javascript"])',
  1631. pageE: 'css;.waterfall > li',
  1632. replaceE: 'css;.pg',
  1633. scrollD: 1500
  1634. }
  1635. }, // 学犀牛 - 各板块帖子列表
  1636. xuexiniu_thread: {
  1637. pager: {
  1638. type: 1,
  1639. nextL: 'css;a.nxt:not([href*="javascript"])',
  1640. pageE: 'css;#zhanzhuai_primary > .box',
  1641. replaceE: 'css;.pg',
  1642. scrollD: 1500
  1643. }
  1644. }, // 学犀牛 - 帖子内
  1645. xuexiniu_search: {
  1646. pager: {
  1647. type: 1,
  1648. nextL: 'css;a.nxt:not([href*="javascript"])',
  1649. pageE: 'css;.yangshi.yangshi2',
  1650. insertP: ['css;.page', 1],
  1651. replaceE: 'css;.page',
  1652. scrollD: 1500
  1653. }
  1654. }, // 学犀牛 - 搜索页
  1655. om: {
  1656. host: 'www.om.cn',
  1657. functionS: function() {if (location.pathname != '/') {curSite = DBSite.om;}},
  1658. pager: {
  1659. type: 1,
  1660. nextL: 'css;li.next > a',
  1661. pageE: 'css;.main_content > ul > li',
  1662. replaceE: 'css;ul.pagination',
  1663. scrollD: 1500
  1664. }
  1665. }, // 欧模网
  1666. xiadele: {
  1667. host: ['www.xiadele.com', 'search.xiadele.com'],
  1668. functionS: function() {if (location.pathname != '/') {curSite = DBSite.xiadele;}},
  1669. insStyle: '.last-li-carousel-img {display: none !important;}',
  1670. pager: {
  1671. type: 1,
  1672. nextL: 'css;li.next_page a[rel="next"]',
  1673. pageE: 'css;ul.list-page-ul > li',
  1674. replaceE: 'css;ul.pagination',
  1675. scrollD: 2000
  1676. }
  1677. }, // 下得乐
  1678. Mixkit: {
  1679. host: 'mixkit.co',
  1680. functionS: function() {if (location.pathname != '/') {curSite = DBSite.Mixkit;}},
  1681. pager: {
  1682. type: 1,
  1683. nextL: 'css;a.pagination__link--next',
  1684. pageE: 'css;.item-grid-item',
  1685. replaceE: 'css;.pagination__wrapper',
  1686. scrollD: 2000
  1687. }
  1688. }, // Mixkit
  1689. _3dmgame: {
  1690. host: 'www.3dmgame.com',
  1691. functionS: function() {
  1692. if (getCSS('.Llist_b > div.lis')) {
  1693. curSite = DBSite._3dmgame_list;
  1694. } else if (getCSS('.newsleft > ul')) {
  1695. curSite = DBSite._3dmgame_list2;
  1696. } else if (indexOF('/resource')) {
  1697. curSite = DBSite._3dmgame_list3;
  1698. } else {
  1699. curSite = DBSite._3dmgame;
  1700. }},
  1701. history: true,
  1702. pager: {
  1703. type: 3,
  1704. nextL: 'css;li.next > a',
  1705. pageE: 'css;script[src*="common.js"], .news_warp_center > *',
  1706. insertP: ['css;.news_warp_center', 3],
  1707. replaceE: 'css;.pagewrap',
  1708. scrollE: 'css;.pagewrap',
  1709. scriptT: 2,
  1710. scrollD: 1000
  1711. }
  1712. }, // 3DM
  1713. _3dmgame_list: {
  1714. pager: {
  1715. type: 1,
  1716. nextL: 'css;li.next > a',
  1717. pageE: 'css;.Llist_b > div.lis',
  1718. replaceE: 'css;.pagewrap',
  1719. scrollD: 1000
  1720. },
  1721. function: {
  1722. bF: src_bF,
  1723. pF: [0, 'img[data-original]', 'data-original']
  1724. }
  1725. }, // 3DM - 分类页
  1726. _3dmgame_list2: {
  1727. pager: {
  1728. type: 1,
  1729. nextL: 'css;li.next > a',
  1730. pageE: 'css;.newsleft > ul > li',
  1731. replaceE: 'css;.pagewrap',
  1732. scrollD: 1000
  1733. },
  1734. function: {
  1735. bF: src_bF,
  1736. pF: [0, 'img[data-original]', 'data-original']
  1737. }
  1738. }, // 3DM - 游戏专区 - 分类页
  1739. _3dmgame_list3: {
  1740. pager: {
  1741. type: 1,
  1742. nextL: 'css;li.next > a',
  1743. pageE: 'css;.item > ul',
  1744. insertP: ['css;.item > ul:last-child', 1],
  1745. replaceE: 'css;.pagewrap',
  1746. scrollD: 800
  1747. }
  1748. }, // 3DM - 游戏专区 - 资源页
  1749. _3dmgame_mod: {
  1750. host: 'mod.3dmgame.com',
  1751. history: true,
  1752. pager: {
  1753. type: 1,
  1754. nextL: () => getNextP('//li[@class="page-list active"]/following-sibling::li[contains(@class, "page-list")]/a', 'Page=', /Page=\d+/),
  1755. 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")]',
  1756. insertP: ['//div[contains(@class, "game-mod-wrap") or contains(@class, "search-mod ")]', 3],
  1757. scriptT: 2,
  1758. scrollD: 1200
  1759. }
  1760. }, // 3DM MOD站
  1761. ali213_www: {
  1762. host: 'www.ali213.net',
  1763. pager: {
  1764. type: 3,
  1765. nextL: 'css;#after_this_page',
  1766. pageE: 'css;#Content >*:not(.news_ding):not(.page_fenye)',
  1767. insertP: ['css;.page_fenye', 1],
  1768. replaceE: 'css;.page_fenye',
  1769. scrollE: 'css;.page_fenye',
  1770. scrollD: 1000
  1771. }
  1772. }, // 游侠网
  1773. ali213_list: {
  1774. host: 'down.ali213.net',
  1775. functionS: function() {if (getCSS('.famous-ul > .famous-li')) {curSite = DBSite.ali213_list;}},
  1776. pager: {
  1777. type: 1,
  1778. nextL: 'css;a.page-next',
  1779. pageE: 'css;.famous-ul > .famous-li',
  1780. replaceE: 'css;.page-container',
  1781. scrollD: 1000
  1782. },
  1783. function: {
  1784. bF: src_bF,
  1785. pF: [0, 'img[data-original]', 'data-original']
  1786. }
  1787. }, // 游侠网 - 分类页
  1788. ali213_gl: {
  1789. host: 'gl.ali213.net',
  1790. insStyle: '.n_show_b {display: none !important;}',
  1791. history: true,
  1792. pager: {
  1793. type: 3,
  1794. nextL: 'css;a.next',
  1795. pageE: 'css;.c-detail >*',
  1796. insertP: ['css;.c-detail', 3],
  1797. replaceE: 'css;.page_fenye',
  1798. scrollE: 'css;.page_fenye',
  1799. scrollD: 1000
  1800. }
  1801. }, // 游侠网 - 攻略
  1802. ali213_pic: {
  1803. host: 'pic.ali213.net',
  1804. insStyle: 'a.prev, a.next {display: none !important;}',
  1805. pager: {
  1806. type: 1,
  1807. nextL: 'css;a.next',
  1808. pageE: 'css;#image-show > img',
  1809. replaceE: 'css;#image-show > a',
  1810. scrollD: 1200
  1811. }
  1812. }, // 游侠网 - 图库
  1813. gamersky_ent: {
  1814. host: 'www.gamersky.com',
  1815. functionS: function() {if (indexOF('/ent/')) {curSite = DBSite.gamersky_ent;} else {curSite = DBSite.gamersky_gl;}},
  1816. pager: {
  1817. type: 3,
  1818. nextL: '//div[@class="page_css"]/a[text()="下一页"]',
  1819. pageE: 'css;.Mid2L_con > *:not(.gs_nc_editor):not(.pagecss):not(.page_css):not(.gs_ccs_solve):not(.post_ding)',
  1820. insertP: ['css;.page_css', 1],
  1821. replaceE: 'css;.page_css',
  1822. scrollE: 'css;.page_css',
  1823. scrollD: 1000
  1824. }
  1825. }, // 游民星空
  1826. gamersky_gl: {
  1827. history: true,
  1828. pager: {
  1829. type: 3,
  1830. nextL: '//div[@class="page_css"]/a[text()="下一页"]',
  1831. pageE: 'css;.Mid2L_con > *:not(.gs_nc_editor):not(.pagecss):not(.gs_ccs_solve):not(.post_ding)',
  1832. insertP: ['css;.gs_nc_editor', 1],
  1833. replaceE: 'css;.page_css',
  1834. scrollE: 'css;.page_css',
  1835. forceHTTPS: true,
  1836. scrollD: 1000
  1837. },
  1838. function: {
  1839. bF: gamersky_gl_bF
  1840. }
  1841. }, // 游民星空 - 攻略
  1842. nexusmods: {
  1843. host: 'www.nexusmods.com',
  1844. pager: {
  1845. type: 1,
  1846. nextL: nexusmods_nextL,
  1847. pageE: 'css;ul.tiles > li',
  1848. replaceE: 'css;.pagination',
  1849. scrollD: 4000
  1850. },
  1851. function: {
  1852. bF: nexusmods_bF
  1853. }
  1854. }, // NexusMods
  1855. curseforge: {
  1856. host: 'www.curseforge.com',
  1857. pager: {
  1858. type: 1,
  1859. nextL: 'css;.pagination-next > a',
  1860. pageE: 'css;div.my-2',
  1861. replaceE: 'css;.pagination',
  1862. scrollD: 2500
  1863. }
  1864. }, // CurseForge
  1865. steamcommunity: {
  1866. host: 'steamcommunity.com',
  1867. functionS: function() {if (indexOF('/workshop/browse')) {curSite = DBSite.steamcommunity;}},
  1868. pager: {
  1869. type: 1,
  1870. nextL: '//a[@class="pagebtn"][last()]',
  1871. pageE: 'css;.workshopBrowseItems > *',
  1872. replaceE: 'css;.workshopBrowsePaging',
  1873. scriptT: 2,
  1874. scrollD: 1500
  1875. }
  1876. }, // Steam 创意工坊 - 项目列表
  1877. yikm: {
  1878. host: 'www.yikm.net',
  1879. pager: {
  1880. type: 1,
  1881. nextL: '//ul[@class="pager"]//a[text()="下一页"]',
  1882. pageE: '//h2[contains(text(), "所有游戏") or contains(text(), "搜索结果")]/following-sibling::div[1]/div',
  1883. replaceE: 'css;ul.pager',
  1884. scrollD: 1500
  1885. }
  1886. }, // 小霸王其乐无穷
  1887. cs_rin_ru: {
  1888. host: 'cs.rin.ru',
  1889. functionS: function() {if (lp == '/forum/viewforum.php') { // 版块帖子列表
  1890. curSite = DBSite.cs_rin_ru;
  1891. } else if (lp == '/forum/viewtopic.php') { // 帖子内
  1892. if (GM_getValue('menu_discuz_thread_page')) curSite = DBSite.cs_rin_ru_list;
  1893. } else if (lp == '/forum/search.php') { // 搜索结果
  1894. curSite = DBSite.cs_rin_ru_search;
  1895. }},
  1896. pager: {
  1897. type: 1,
  1898. nextL: '//td[@class="gensmall"][@align="right"]//a[text()="Next"]',
  1899. pageE: 'css;#pagecontent > table.tablebg > tbody > tr:not([align])',
  1900. replaceE: 'css;#pagecontent > table:first-child',
  1901. scrollD: 1500
  1902. },
  1903. function: {
  1904. bF: cs_rin_ru_bF
  1905. }
  1906. }, // cs.rin.ru - 各版块帖子列表
  1907. cs_rin_ru_list: {
  1908. pager: {
  1909. type: 1,
  1910. nextL: 'id("pageheader")/p[@class="gensmall"]//a[text()="Next"]',
  1911. pageE: 'css;#pagecontent > table.tablebg:not(:nth-last-child(2)):not(:nth-child(2))',
  1912. replaceE: 'css;#pagecontent >table:not(.tablebg), #pageheader p.gensmall',
  1913. scrollD: 2000
  1914. }
  1915. }, // cs.rin.ru - 帖子内
  1916. cs_rin_ru_search: {
  1917. pager: {
  1918. type: 1,
  1919. nextL: 'id("wrapcentre")/div[@class="nav"]//a[text()="Next"]',
  1920. pageE: 'css;#wrapcentre > form > table.tablebg > tbody > tr[valign]',
  1921. replaceE: 'css;#wrapcentre > div',
  1922. scrollD: 1500
  1923. }
  1924. }, // cs.rin.ru - 搜索页
  1925. crackhub: {
  1926. host: 'crackhub.site',
  1927. insStyle: 'html.wp-dark-mode-active .inside-article {background-color: var(--wp-dark-mode-bg);}',
  1928. pager: {
  1929. type: 1,
  1930. nextL: 'css;a.next.page-numbers',
  1931. pageE: 'css;article[id^="post-"]',
  1932. replaceE: 'css;nav.paging-navigation',
  1933. scrollD: 2000
  1934. }
  1935. }, // Crackhub213
  1936. fitgirl: {
  1937. host: 'fitgirl-repacks.site',
  1938. pager: {
  1939. type: 1,
  1940. nextL: 'css;a.next.page-numbers',
  1941. pageE: 'css;article[id^="post-"]',
  1942. replaceE: 'css;nav.paging-navigation',
  1943. scrollD: 2500
  1944. }
  1945. }, // FitGirl Repacks
  1946. bilibili_search: {
  1947. host: 'search.bilibili.com',
  1948. functionS: function() {locationC = true; curSite = DBSite.bilibili_search;},
  1949. history: true,
  1950. retry: 100,
  1951. pager: {
  1952. type: 1,
  1953. nextL: bilibili_search_nextL,
  1954. pageE: '//ul[contains(@class, "video-list")]/li | //script[contains(text(), "window.__INITIAL_STATE__")]',
  1955. insertP: ['css;ul.video-list', 3],
  1956. replaceE: 'css;ul.pages',
  1957. scriptT: 2,
  1958. scrollD: 1000
  1959. },
  1960. function: {
  1961. aF: bilibili_search_aF
  1962. }
  1963. }, // B 站(Bilibili) - 搜索页
  1964. pianku: {
  1965. host: /pianku/,
  1966. functionS: function() {if (location.pathname != '/') {curSite = DBSite.pianku;}},
  1967. pager: {
  1968. type: 1,
  1969. nextL: 'css;a.a1',
  1970. pageE: 'css;.content-list > li',
  1971. replaceE: 'css;.pages',
  1972. scrollD: 1500
  1973. },
  1974. function: {
  1975. bF: src_bF,
  1976. pF: [0, 'img[data-src]', 'data-src']
  1977. }
  1978. }, // 片库
  1979. cupfox: {
  1980. host: 'www.cupfox.com',
  1981. pager: {
  1982. type: 2,
  1983. nextL: 'css;.load-more',
  1984. nextText: '点击加载更多',
  1985. scrollD: 700
  1986. }
  1987. }, // 茶杯狐
  1988. novipnoad: {
  1989. host: 'www.novipnoad.com',
  1990. functionS: function() {if (location.pathname != '/' && !indexOF('.html')) {curSite = DBSite.novipnoad;}},
  1991. pager: {
  1992. type: 1,
  1993. nextL: 'css;a.nextpostslink',
  1994. pageE: 'css;.video-listing-content .row > div',
  1995. replaceE: 'css;.wp-pagenavi',
  1996. scrollD: 1500
  1997. },
  1998. function: {
  1999. bF: src_bF,
  2000. pF: [0, 'img[data-original]', 'data-original']
  2001. }
  2002. }, // NO视频
  2003. ddrk: {
  2004. host: ['ddrk.me', 'ddys.tv'],
  2005. functionS: function() {if (lp == '/' || indexOF(/\/(category|tag)\//)) {curSite = DBSite.ddrk;}},
  2006. pager: {
  2007. type: 1,
  2008. nextL: 'css;a.next',
  2009. pageE: 'css;.post-box-list > article',
  2010. replaceE: 'css;.pagination_wrap',
  2011. scrollD: 1500
  2012. }
  2013. }, // 低端影视
  2014. nfmovies: {
  2015. host: 'www.nfmovies.com',
  2016. functionS: function() {if (lp == '/search.php' || indexOF('/list/')) {curSite = DBSite.nfmovies;}},
  2017. pager: {
  2018. type: 1,
  2019. nextL: '//ul[contains(@class, "myui-page")]/li/a[text()="下一页"]',
  2020. pageE: 'css;ul.myui-vodlist > li',
  2021. replaceE: 'css;ul.myui-page',
  2022. scrollD: 1500
  2023. },
  2024. function: {
  2025. bF: src_bF,
  2026. pF: [1, 'a[data-original]', 'data-original']
  2027. }
  2028. }, // 奈菲影视
  2029. zxzj: {
  2030. host: ['www.zxzj.me', 'www.zxzj.fun'],
  2031. functionS: function() {if (location.pathname != '/' && !indexOF('/detail/') && !indexOF('/video/')) {curSite = DBSite.zxzj;}},
  2032. insStyle: 'div.stui-page__all {display: none !important;}',
  2033. pager: {
  2034. type: 1,
  2035. nextL: '//ul[contains(@class, "stui-page__item")]//a[text()="下一页"]',
  2036. pageE: 'css;ul.stui-vodlist > li',
  2037. replaceE: 'css;ul.stui-page__item',
  2038. scrollD: 1000
  2039. },
  2040. function: {
  2041. bF: src_bF,
  2042. pF: [1, 'a[data-original]', 'data-original']
  2043. }
  2044. }, // 在线之家
  2045. enlienli: {
  2046. host: 'enlienli.com',
  2047. functionS: function() {if (indexOF('/show/') || indexOF('/search')) {curSite = DBSite.enlienli;}},
  2048. pager: {
  2049. type: 1,
  2050. nextL: 'css;a.page-number.page-next',
  2051. pageE: 'css;.module-items > *',
  2052. replaceE: 'css;#page',
  2053. scrollD: 1000
  2054. },
  2055. function: {
  2056. bF: src_bF,
  2057. pF: [0, 'img[data-src]', 'data-src']
  2058. }
  2059. }, // 嗯哩嗯哩
  2060. _91mjw: {
  2061. host: '91mjw.com',
  2062. functionS: function() {if (!indexOF('/video/') || !indexOF('/vplay/')) {curSite = DBSite._91mjw;}},
  2063. pager: {
  2064. type: 1,
  2065. nextL: 'css;.next-page > a',
  2066. pageE: 'css;.m-movies > article',
  2067. replaceE: 'css;.pagination',
  2068. scrollD: 1500
  2069. },
  2070. function: {
  2071. bF: src_bF,
  2072. pF: [0, 'img[data-original]', 'data-original']
  2073. }
  2074. }, // 91 美剧网
  2075. zhenbuka: {
  2076. host: ['www.zhenbuka3.com', 'www.zhenbuka5.com'],
  2077. functionS: function() {if (indexOF('/vodtype/')) {curSite = DBSite.zhenbuka;}},
  2078. pager: {
  2079. type: 1,
  2080. nextL: '//ul[contains(@class, "stui-page")]/li/a[text()="下一页"]',
  2081. pageE: 'css;ul.stui-vodlist > li',
  2082. replaceE: 'css;ul.stui-page',
  2083. scrollD: 1500
  2084. },
  2085. function: {
  2086. bF: src_bF,
  2087. pF: [1, 'a[data-original]', 'data-original']
  2088. }
  2089. }, // 真不卡影院
  2090. zzzfun: {
  2091. host: 'www.zzzfun.com',
  2092. functionS: function() {
  2093. if (indexOF('/vod_type') || indexOF('/vod_show')) {
  2094. curSite = DBSite.zzzfun;
  2095. } else if (indexOF('/vod_search')) {
  2096. curSite = DBSite.zzzfun_search;
  2097. }},
  2098. pager: {
  2099. type: 1,
  2100. nextL: 'css;#page a[title="下一页"]',
  2101. pageE: 'css;ul.search-result > a',
  2102. replaceE: 'css;#page',
  2103. scrollD: 1000
  2104. },
  2105. function: {
  2106. bF: src_bF,
  2107. pF: [0, 'img[data-original]', 'data-original']
  2108. }
  2109. }, // ZzzFun 动漫
  2110. zzzfun_search: {
  2111. pager: {
  2112. type: 1,
  2113. nextL: 'css;#page a[title="下一页"]',
  2114. pageE: 'css;ul.show-list > li',
  2115. replaceE: 'css;#page',
  2116. scrollD: 1000
  2117. },
  2118. function: {
  2119. bF: src_bF,
  2120. pF: [0, 'img[data-original]', 'data-original']
  2121. }
  2122. }, // ZzzFun 动漫 - 搜索页
  2123. tucao: {
  2124. host: 'www.tucao.one',
  2125. functionS: function() {if (indexOF('/list/')) {
  2126. curSite = DBSite.tucao;
  2127. } else if (indexOF('search', 's')) {
  2128. curSite = DBSite.tucao_search;
  2129. }},
  2130. pager: {
  2131. type: 1,
  2132. nextL: 'css;.pagego a',
  2133. pageE: 'css;.list > ul > li',
  2134. replaceE: 'css;.newpages, .pagego, #float_show',
  2135. scrollD: 1000
  2136. }
  2137. }, // 吐槽弹幕网
  2138. tucao_search: {
  2139. pager: {
  2140. type: 1,
  2141. nextL: '//a[@class="a1"][contains(text(), "下一页")]',
  2142. pageE: 'css;.search_list > *',
  2143. replaceE: 'css;.pages',
  2144. scrollD: 1000
  2145. }
  2146. }, // 吐槽弹幕网 - 搜索页
  2147. mandao: {
  2148. host: 'www.mandao.tv',
  2149. functionS: function() {if (location.pathname != '/' && !indexOF('/man')) {
  2150. curSite = DBSite.mandao;
  2151. }},
  2152. pager: {
  2153. type: 1,
  2154. nextL: '//div[contains(@class, "page")]/a[text()=">"]',
  2155. pageE: 'css;.index-tj > ul > li',
  2156. replaceE: 'css;.page',
  2157. scrollD: 1000
  2158. },
  2159. function: {
  2160. bF: src_bF,
  2161. pF: [0, 'img[data-original]', 'data-original']
  2162. }
  2163. }, // 漫岛动漫
  2164. yxdm: {
  2165. host: 'www.yxdm.li',
  2166. functionS: function() {if (indexOF('/search') || indexOF('/category') || indexOF('/resource')) {curSite = DBSite.yxdm;}},
  2167. pager: {
  2168. type: 1,
  2169. nextL: '//a[@class="nextPage" or text()="下一页"]',
  2170. pageE: 'css;.dhnew > ul > li',
  2171. replaceE: 'css;.pagelist',
  2172. scrollD: 2000
  2173. }
  2174. }, // 怡萱动漫
  2175. nicotv: {
  2176. host: 'www.nicotv.me',
  2177. functionS: function() {if (indexOF('/search') || indexOF('/type')) {curSite = DBSite.nicotv;}},
  2178. pager: {
  2179. type: 1,
  2180. nextL: '//ul[contains(@class, "pagination ")]//a[text()="»"]',
  2181. pageE: 'css;ul.list-unstyled > li',
  2182. replaceE: 'css;ul.pagination ',
  2183. scrollD: 1000
  2184. },
  2185. function: {
  2186. bF: src_bF,
  2187. pF: [0, 'img[data-original]', 'data-original']
  2188. }
  2189. }, // 妮可动漫
  2190. yhdm: {
  2191. host: ['www.imomoe.la', 'www.imomoe.live'],
  2192. functionS: function() {if (indexOF('/list/')) {
  2193. curSite = DBSite.yhdm;
  2194. } else if (lp == '/so.asp' || lp == '/search.asp') {
  2195. curSite = DBSite.yhdm_;
  2196. }},
  2197. pager: {
  2198. type: 1,
  2199. nextL: '//div[@class="pages"]/a[text()="下一页"]',
  2200. pageE: 'css;#contrainer > .img> ul > li',
  2201. replaceE: 'css;.pages',
  2202. scrollD: 1000
  2203. }
  2204. }, // 樱花动漫
  2205. yhdm_: {
  2206. pager: {
  2207. type: 1,
  2208. nextL: '//div[@class="pages"]/a[text()="下一页"]',
  2209. pageE: 'css;#contrainer .fire .pics > ul > li',
  2210. replaceE: 'css;.pages',
  2211. scrollD: 1000
  2212. }
  2213. }, // 樱花动漫 - 搜索页等
  2214. agefans: {
  2215. host: 'www.agefans.cc',
  2216. functionS: function() {if (indexOF('/catalog/') || lp == '/search') {
  2217. curSite = DBSite.agefans;
  2218. } else if (lp == '/recommend' || lp == '/update') {
  2219. curSite = DBSite.agefans_;
  2220. } else if (lp == '/rank') {
  2221. curSite = DBSite.agefans_rank;
  2222. }},
  2223. pager: {
  2224. type: 1,
  2225. nextL: 'id("container")//div[@class="blockcontent"]/div[@style][not(@class)]/li/a[contains(text(), "下一页")]',
  2226. pageE: 'css;#container .blockcontent1 > div',
  2227. replaceE: 'css;#container .blockcontent > div[style]:not([class])',
  2228. scrollD: 1000
  2229. }
  2230. }, // AGE 动漫 - 全部/搜索
  2231. agefans_: {
  2232. pager: {
  2233. type: 1,
  2234. nextL: 'id("container")//div[@class="blockcontent"]/div[@style][not(@class)]/li/a[contains(text(), "下一页")]',
  2235. pageE: 'css;#container .blockcontent > ul > li',
  2236. replaceE: 'css;#container .blockcontent > div[style]:not([class])',
  2237. scrollD: 1000
  2238. }
  2239. }, // AGE 动漫 - 其他页
  2240. agefans_rank: {
  2241. pager: {
  2242. type: 1,
  2243. nextL: 'id("container")/ul[@style][not(@class)]/li/a[contains(text(), "下一页")]',
  2244. pageE: 'css;#container > .div_right .blockcontent.div_right_r_3 > ul',
  2245. replaceE: 'css;#container > ul[style]:not([class])',
  2246. scrollD: 1000
  2247. }
  2248. }, // AGE 动漫 - 排行榜
  2249. dm233: {
  2250. host: 'www.dm233.cc',
  2251. functionS: function() {if (indexOF('/catalog/') || lp == '/recommend/' || lp == '/search') {
  2252. curSite = DBSite.dm233;
  2253. } else if (lp == '/article/') {
  2254. curSite = DBSite.dm233_article;
  2255. } else if (lp == '/rank/') {
  2256. curSite = DBSite.dm233_rank;
  2257. }},
  2258. pager: {
  2259. type: 1,
  2260. nextL: '//div[@class="pagelist"]//a[contains(text(), "下一页") or contains(text(), "下一頁")]',
  2261. pageE: 'css;.dhnew ul > li',
  2262. replaceE: 'css;.pagelist',
  2263. scrollD: 1000
  2264. }
  2265. }, // 233 动漫
  2266. dm233_article: {
  2267. pager: {
  2268. type: 1,
  2269. nextL: '//div[@class="pagelist"]//a[contains(text(), "下一页") or contains(text(), "下一頁")]',
  2270. pageE: 'css;.xgyd ul > li',
  2271. replaceE: 'css;.pagelist',
  2272. scrollD: 1000
  2273. }
  2274. }, // 233 动漫 - 动漫情报/资讯
  2275. dm233_rank: {
  2276. pager: {
  2277. type: 1,
  2278. nextL: '//div[@class="pagelist"]//a[contains(text(), "下一页") or contains(text(), "下一頁")]',
  2279. pageE: 'css;.side-update.normal-wai > .normal-nei',
  2280. replaceE: 'css;.pagelist',
  2281. scrollD: 1000
  2282. }
  2283. }, // 233 动漫 - 排行榜
  2284. anime1: {
  2285. host: 'anime1.me',
  2286. functionS: function() {if (indexOF('s=', 's')) {
  2287. curSite = DBSite.anime1_search;
  2288. } else if (lp == '/') {
  2289. curSite = DBSite.anime1;
  2290. }},
  2291. pager: {
  2292. type: 4,
  2293. nextL: anime1_nextL,
  2294. interval: 500,
  2295. scrollD: 800
  2296. }
  2297. }, // Anime1
  2298. anime1_search: {
  2299. pager: {
  2300. type: 1,
  2301. nextL: 'css;.nav-previous > a',
  2302. pageE: 'css;#main > article',
  2303. replaceE: 'css;nav.navigation',
  2304. scrollD: 1200
  2305. }
  2306. }, // Anime1 - 搜索页
  2307. yinfans: {
  2308. host: 'www.yinfans.net',
  2309. insStyle: '#post_container {height: auto !important;} #post_container > li {position: static !important; float: left !important; height: 620px !important;}',
  2310. pager: {
  2311. type: 1,
  2312. nextL: 'css;a.next',
  2313. pageE: 'css;#post_container > li',
  2314. replaceE: 'css;.pagination',
  2315. scrollD: 1500
  2316. }
  2317. }, // 音范丝
  2318. btbtt: {
  2319. host: /btbtt/,
  2320. pager: {
  2321. type: 1,
  2322. nextL: '//div[@class="page"]/a[contains(text(), "▶") or contains(text(), "下一页")]',
  2323. pageE: 'css;#threadlist > *',
  2324. replaceE: 'css;.page',
  2325. scrollD: 2000
  2326. }
  2327. }, // BT 之家
  2328. bdys: {
  2329. host: 'www.bd2020.com',
  2330. functionS: function() {if (location.pathname != '/' && !indexOF(/\/\d+\.htm/)) {curSite = DBSite.bdys;}},
  2331. pager: {
  2332. type: 2,
  2333. nextL: 'css;div.layui-flow-more > a',
  2334. nextText: '加载更多',
  2335. scrollD: 1000
  2336. }
  2337. }, // BD 影视
  2338. gaoqing_fm: {
  2339. host: 'gaoqing.fm',
  2340. pager: {
  2341. type: 2,
  2342. nextL: 'css;.col-md-12 > a, #loadmore > a',
  2343. interval: 1500,
  2344. scrollD: 1000
  2345. }
  2346. }, // 高清电台
  2347. yyds: {
  2348. host: 'yyds.fans',
  2349. functionS: function() {if (location.search != '' && !indexOF('p=', 's')) {curSite = DBSite.yyds;}},
  2350. pager: {
  2351. type: 1,
  2352. nextL: 'css;a.next.page-numbers',
  2353. pageE: 'css;.list-grouped > div',
  2354. replaceE: 'css;nav.pagination',
  2355. scrollD: 1100
  2356. }
  2357. }, // YYDS 电影
  2358. kisssub: {
  2359. host: ['www.kisssub.org','www.comicat.org'],
  2360. pager: {
  2361. type: 1,
  2362. nextL: 'css;a.nextprev',
  2363. pageE: 'css;#data_list > tr',
  2364. replaceE: 'css;.pages',
  2365. scrollD: 2500
  2366. }
  2367. }, // 爱恋动漫
  2368. dmhy: {
  2369. host: ['share.dmhy.org', 'dmhy.anoneko.com'],
  2370. pager: {
  2371. type: 1,
  2372. nextL: '//div[@class="nav_title"]/a[contains(text(), "下一")]',
  2373. pageE: 'css;#topic_list > tbody > tr',
  2374. replaceE: 'css;.nav_title',
  2375. scrollD: 1500
  2376. },
  2377. function: {
  2378. 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');`;}
  2379. }
  2380. }, // 动漫花园
  2381. hacg: {
  2382. host: 'www.hacg.cat',
  2383. functionS: function() {if (indexOF('/wp/') && !indexOF(/\d+\.html/)) curSite = DBSite.hacg},
  2384. pager: {
  2385. type: 1,
  2386. nextL: 'css;a.nextpostslink',
  2387. pageE: 'css;article[id^="post-"]',
  2388. replaceE: 'css;.wp-pagenavi',
  2389. scrollD: 1500
  2390. }
  2391. }, // 琉璃神社
  2392. futaacg: {
  2393. host: 'futaacg.com',
  2394. pager: {
  2395. type: 1,
  2396. nextL: 'css;ul.pagination a[rel="next"]',
  2397. pageE: 'css;.topic-list > div',
  2398. replaceE: 'css;ul.pagination',
  2399. scrollD: 1500
  2400. }
  2401. }, // 扶她动漫
  2402. bangumi: {
  2403. host: 'bangumi.moe',
  2404. pager: {
  2405. type: 2,
  2406. nextL: 'css;[torrent-list="lattorrents"] button[ng-click="loadMore()"] ,[torrent-list="torrents"] button[ng-click="loadMore()"]',
  2407. interval: 1000,
  2408. scrollD: 1500
  2409. }
  2410. }, // 萌番组
  2411. miobt: {
  2412. host: ['miobt.com', 'www.36dm.club'],
  2413. functionS: function() {curSite = DBSite.miobt; if (location.hostname === 'www.36dm.club') {curSite.pager.scrollD = 1000;}},
  2414. pager: {
  2415. type: 1,
  2416. nextL: '//a[@class="nextprev"][contains(text(), "〉") or contains(text(), "下一页") or contains(text(), "»")]',
  2417. pageE: 'css;#data_list > tr',
  2418. replaceE: 'css;.pages',
  2419. scrollD: 2000
  2420. }
  2421. }, // MioBT + 简单动漫
  2422. nyaa: {
  2423. host: /nyaa\.si/,
  2424. pager: {
  2425. type: 1,
  2426. nextL: 'css;a[rel="next"], li.next > a',
  2427. pageE: 'css;table.torrent-list > tbody > tr',
  2428. replaceE: 'css;ul.pagination',
  2429. scrollD: 2000
  2430. }
  2431. }, // Nyaa
  2432. skrbt: {
  2433. host: /skrbt/,
  2434. functionS: function() {if (lp == '/search') curSite = DBSite.skrbt;},
  2435. pager: {
  2436. type: 1,
  2437. nextL: skrbt_nextL,
  2438. pageE: 'css;div[class="row"] > .col-md-6 > ul',
  2439. insertP: ['css;nav[aria-label*="Page"]', 1],
  2440. replaceE: 'css;ul.pagination',
  2441. scrollD: 900
  2442. }
  2443. }, // SkrBT
  2444. rarbg: {
  2445. host: /rarbg/,
  2446. functionS: function() {if (lp == '/torrents.php') {curSite = DBSite.rarbg; rarbg_bF(getAllCSS('table.lista2t tr.lista2'));}},
  2447. insStyle: 'html::-webkit-scrollbar {height: 0 !important;}',
  2448. pager: {
  2449. type: 1,
  2450. nextL: 'css;#pager_links > a[title="next page"]',
  2451. pageE: 'css;table.lista2t tr.lista2',
  2452. replaceE: 'css;#pager_links',
  2453. scrollD: 1000
  2454. },
  2455. function: {
  2456. bF: rarbg_bF
  2457. }
  2458. }, // RARBG
  2459. subdh: {
  2460. host: 'subdh.com',
  2461. functionS: function() {if (lp == '/' || indexOF('/list/new')) {curSite = DBSite.subdh;} else if (indexOF('/search')) {curSite = DBSite.subdh_search;}},
  2462. pager: {
  2463. type: 1,
  2464. nextL: '//a[@class="page-link"][contains(text(), "下一页")]',
  2465. pageE: 'css;.col-lg-9 .bg-white.shadow-sm.rounded-3 > .row.gx-0',
  2466. replaceE: 'css;ul.pagination',
  2467. scrollD: 1000
  2468. }
  2469. }, // SubDH
  2470. subdh_search: {
  2471. pager: {
  2472. type: 1,
  2473. nextL: '//a[@class="page-link"][contains(text(), "下一页")]',
  2474. pageE: 'css;.col-lg-9 .bg-white.shadow-sm.rounded-3',
  2475. insertP: ['css;nav[aria-label="pagination"]', 1],
  2476. replaceE: 'css;ul.pagination',
  2477. scrollD: 1000
  2478. }
  2479. }, // SubDH - 搜索页
  2480. mini4k: {
  2481. host: 'www.mini4k.com',
  2482. functionS: function() {if (location.pathname != '/' && !indexOF(/\/\d{3,}/)) {curSite = DBSite.mini4k;};},
  2483. pager: {
  2484. type: 1,
  2485. nextL: 'css;a.pager__item--next',
  2486. pageE: 'css;div[class*="-item-list"] > ul > li',
  2487. replaceE: 'css;.pagination',
  2488. scrollD: 2000
  2489. }
  2490. }, // MINI4K
  2491. bthaha: {
  2492. host: /bthaha/,
  2493. functionS: function() {if (indexOF('/search/')) {
  2494. curSite = DBSite.bthaha;
  2495. getAllCSS('[id^="list_top"], [id^="list_bottom"]').forEach(function (one) {one.parentElement.parentElement.hidden = true;});
  2496. }},
  2497. insStyle: '[id^="list_top"], [id^="list_bottom"] {display: none !important;}',
  2498. pager: {
  2499. type: 1,
  2500. nextL: '//ul[@class="pagination"]/li/a[contains(text(), "下一页")]',
  2501. pageE: 'css;table.table > tbody > tr',
  2502. replaceE: 'css;ul.pagination',
  2503. scrollD: 1000
  2504. },
  2505. function: {
  2506. bF: bthaha_bF
  2507. }
  2508. }, // BTHaha
  2509. a4k: {
  2510. host: 'www.a4k.net',
  2511. functionS: function() {if (!indexOF('/subtitle/')) {curSite = DBSite.a4k;};},
  2512. pager: {
  2513. type: 1,
  2514. nextL: 'css;a.pager__item--next',
  2515. pageE: 'css;ul.list > li',
  2516. replaceE: 'css;.pagination',
  2517. scrollD: 1000
  2518. }
  2519. }, // A4k 字幕网(字幕)
  2520. assrt: {
  2521. host: 'assrt.net',
  2522. functionS: function() {if (location.pathname != '/') {curSite = DBSite.assrt;};},
  2523. history: true,
  2524. pager: {
  2525. type: 1,
  2526. nextL: () => getNextP('css;#pl-current+a', 'page=', /page=\d+/),
  2527. pageE: 'css;.resultcard > div:not(#top-banner):not(#bottom-banner):not(.pagelinkcard)',
  2528. insertP: ['css;.pagelinkcard', 1],
  2529. replaceE: 'css;.pagelinkcard',
  2530. scrollD: 1000
  2531. }
  2532. }, // 射手网(字幕)
  2533. subhd: {
  2534. host: 'subhd.tv',
  2535. functionS: function() {if (lp == '/forum/forum') {
  2536. curSite = DBSite.subhd_forum;
  2537. } else if (location.pathname != '/' && location.pathname != '/zu' && !indexOF('/a/') && !indexOF('/d/') && !indexOF('/forum/')) {
  2538. curSite = DBSite.subhd;
  2539. }},
  2540. pager: {
  2541. type: 1,
  2542. nextL: '//a[@class="page-link"][contains(text(), "下一页")]',
  2543. pageE: 'css;.bg-white.shadow-sm.rounded-3',
  2544. insertP: ['css;nav.clearfix', 1],
  2545. replaceE: 'css;nav.clearfix',
  2546. scrollD: 1000
  2547. }
  2548. }, // SubHD(字幕)
  2549. subhd_forum: {
  2550. pager: {
  2551. type: 1,
  2552. nextL: '//a[@class="page-link"][contains(text(), "下一页")]',
  2553. pageE: 'css;.bg-white.shadow-sm.rounded-3 > div',
  2554. replaceE: 'css;nav.clearfix',
  2555. scrollD: 800
  2556. }
  2557. }, // SubHD - forum(字幕)
  2558. manben: {
  2559. host: 'www.manben.com',
  2560. functionS: function() {if (indexOF(/\/m\d+/)) {
  2561. if (getCookie('showtype') != '2') {
  2562. document.cookie='showtype=2; expires=Thu, 18 Dec 2031 12:00:00 GMT; path=/'; // 写入 Cookie 开启 [垂直阅读] 模式
  2563. location.reload(); // 刷新网页
  2564. }
  2565. curSite = DBSite.mhxqiu;
  2566. }}
  2567. }, // 漫本
  2568. haoman: {
  2569. host: 'www.haoman6.com',
  2570. functionS: function() {
  2571. if (indexOF('/chapter/')) {
  2572. curSite = DBSite.haoman;
  2573. } else if (indexOF('/comic/')) {
  2574. if (getCSS('.chapter__more')) getCSS('.chapter__more').click();
  2575. } else if (indexOF('/category/') || indexOF('/search')) {
  2576. curSite = DBSite.haoman_list;
  2577. }},
  2578. insStyle: '.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;}',
  2579. history: true,
  2580. pager: {
  2581. type: 1,
  2582. nextL: function() {if (getCSS('a.rd-aside__item.j-rd-next')) return location.origin + getCSS('a.rd-aside__item.j-rd-next').getAttribute('_href')},
  2583. pageE: 'css;.rd-article-wr > div',
  2584. replaceE: 'css;a.last-crumb, .rd-aside',
  2585. interval: 2000,
  2586. scrollD: 2000
  2587. },
  2588. function: {
  2589. bF: src_bF,
  2590. pF: [0, 'img[dta-echo]', 'dta-echo']
  2591. }
  2592. }, // 好漫 6
  2593. haoman_list: {
  2594. pager: {
  2595. type: 1,
  2596. nextL: 'css;a.next',
  2597. pageE: 'css;.cate-comic-list > div',
  2598. replaceE: 'css;#Pagination',
  2599. scrollD: 1000
  2600. },
  2601. function: {
  2602. bF: src_bF,
  2603. pF: [0, 'img[data-original]', 'data-original']
  2604. }
  2605. }, // 好漫 6 - 分类/搜索页
  2606. cartoonmad: {
  2607. host: ['www.cartoonmad.com','www.cartoonmad.cc'],
  2608. functionS: function() {if (indexOF('/comic/')) {
  2609. getCSS('body > table > tbody > tr:nth-child(4) > td > table > tbody > tr:first-child > td:first-child > a').href = 'javascript:void(0);'; // 清理图片上的链接
  2610. curSite = DBSite.cartoonmad;
  2611. } else if (location.pathname != '/') {
  2612. curSite = DBSite.cartoonmad_list;
  2613. }},
  2614. insStyle: '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;}',
  2615. history: true,
  2616. pager: {
  2617. type: 1,
  2618. nextL: cartoonmad_nextL,
  2619. pageE: 'css;body > table > tbody > tr:nth-child(4) > td > table > tbody > tr:first-child > td:first-child img',
  2620. replaceE: 'css;body > table > tbody > tr:nth-child(2), body > table > tbody > tr:nth-child(5)',
  2621. scrollD: 2000
  2622. }
  2623. }, // 动漫狂
  2624. cartoonmad_list: {
  2625. pager: {
  2626. type: 1,
  2627. nextL: '//a[@class="pages"][contains(text(), "下一頁")]',
  2628. pageE: 'css;td[background="/image/content_box4.gif"]+td > table > tbody > tr',
  2629. replaceE: '//a[@class="pages"]/parent::td/parent::tr | //font[contains(text(), "目前在第")]',
  2630. scrollD: 1000
  2631. }
  2632. }, // 动漫狂 - 分类/搜索页
  2633. manhuacat: {
  2634. host: ['www.manhuacat.com', 'www.maofly.com'],
  2635. functionS: function() {if (indexOF(/\/manga\/\d+\/.+\.html/)) {
  2636. if (getCookie('is_pull') == 'true') { // 强制关闭 [下拉] 模式
  2637. document.cookie='is_pull=false; expires=Thu, 18 Dec 2031 12:00:00 GMT; path=/'; // 写入 Cookie 关闭 [下拉] 模式
  2638. location.reload(); // 刷新网页
  2639. }
  2640. setTimeout(manhuacat_init, 100);
  2641. curSite = DBSite.manhuacat;
  2642. } else if (indexOF('/list')) {
  2643. curSite = DBSite.manhuacat_list;
  2644. } else if (indexOF('/search') || indexOF('/update')) {
  2645. curSite = DBSite.manhuacat_search;
  2646. }},
  2647. insStyle: '#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;}', // 隐藏不需要的元素,调整图片
  2648. history: true,
  2649. pager: {
  2650. type: 4,
  2651. nextL: manhuacat_nextL,
  2652. insertP: ['css;.img-content', 3],
  2653. insertE: manhuacat_insertE,
  2654. replaceE: 'css;.comic-detail > .breadcrumb-bar, .comic-detail >h2.h4, .vg-r-data, body > script:not([src])',
  2655. interval: 2000,
  2656. scrollD: 3000
  2657. }
  2658. }, // 漫画猫
  2659. manhuacat_list: {
  2660. pager: {
  2661. type: 1,
  2662. nextL: '//div[contains(@class, "pagination")]//a[contains(text(), "下一页") or contains(text(), "下页")]',
  2663. pageE: 'css;.comic-main-section > *',
  2664. replaceE: 'css;.pagination',
  2665. scrollD: 1000
  2666. },
  2667. function: {
  2668. bF: src_bF,
  2669. pF: [0, 'img[data-original]', 'data-original']
  2670. }
  2671. }, // 漫画猫 - 分类页
  2672. manhuacat_search: {
  2673. pager: {
  2674. type: 1,
  2675. nextL: '//div[contains(@class, "pagination")]//a[contains(text(), "下一页") or contains(text(), "下页")]',
  2676. pageE: 'css;.comic-main-section .row > div',
  2677. replaceE: 'css;.pagination',
  2678. scrollD: 1000
  2679. }
  2680. }, // 漫画猫 - 搜索页
  2681. manhuatai: {
  2682. host: 'www.manhuatai.net',
  2683. functionS: function() {if (indexOF('/manhua/')) {
  2684. curSite = DBSite.manhuatai;
  2685. } else if (indexOF('/fenlei_') || indexOF('/top_')) {
  2686. curSite = DBSite.manhuatai_list;
  2687. } else if (indexOF('/search')) {
  2688. curSite = DBSite.manhuatai_search;
  2689. }},
  2690. history: true,
  2691. pager: {
  2692. type: 1,
  2693. nextL: '//div[contains(@class, "page")]//a[@href][contains(text(), "下一页") or contains(text(), "下一章")]',
  2694. pageE: 'css;#htmlContent p.img > img',
  2695. replaceE: 'css;.page, .title',
  2696. scrollD: 2000
  2697. }
  2698. }, // 漫画台
  2699. manhuatai_list: {
  2700. pager: {
  2701. type: 1,
  2702. nextL: 'css;#pagelink a.next',
  2703. pageE: 'css;.article-list',
  2704. replaceE: 'css;#pagelink',
  2705. scrollD: 1500
  2706. }
  2707. }, // 漫画台 - 分类页
  2708. manhuatai_search: {
  2709. pager: {
  2710. type: 1,
  2711. nextL: 'css;#pagelink a.next',
  2712. pageE: 'css;#content > table > tbody > tr:not([align])',
  2713. replaceE: 'css;#pagelink',
  2714. scrollD: 1500
  2715. }
  2716. }, // 漫画台 - 搜索页
  2717. manhuapi: {
  2718. host: 'www.manhuapi.com',
  2719. functionS: function() {if (indexOF('/chapter/')) {
  2720. curSite = DBSite.manhuapi;
  2721. } else if (!indexOF(/\/manhua\/\d+\.html/)) {
  2722. curSite = DBSite.manhuapi_list;
  2723. }},
  2724. history: true,
  2725. pager: {
  2726. type: 1,
  2727. nextL: '//div[@class="page"]/a[text()="下一页" or text()="下一章"]',
  2728. pageE: 'css;.mh_list img[src]',
  2729. replaceE: 'css;.page',
  2730. scrollD: 2000
  2731. }
  2732. }, // 漫画皮
  2733. manhuapi_list: {
  2734. pager: {
  2735. type: 1,
  2736. nextL: '//div[@class="pages"]/a[text()="下一页"]',
  2737. pageE: 'css;.cy_list_mh > ul',
  2738. replaceE: 'css;.pages',
  2739. scrollD: 1500
  2740. }
  2741. }, // 漫画皮 - 分类页
  2742. manhuagui: {
  2743. host: 'www.mhgui.com',
  2744. functionS: function() {if (indexOF(/\/comic\/\d+\/\d+\.html/)) {
  2745. if (!getXpath('//li[@class="pfunc"]/a[@class="current" and text()="双击"]')) getXpath('//li[@class="pfunc"]/a[text()="双击"]').click();
  2746. pausePage = false;
  2747. setTimeout(manhuagui_init, 100);
  2748. curSite = DBSite.manhuagui;
  2749. } else if (indexOF('list/') || indexOF('/s/')) {
  2750. curSite = DBSite.manhuagui_list;
  2751. }},
  2752. insStyle: '.sub-btn, .tc {display: none !important;} #mangaBox > img {width: auto !important;height: auto !important;display: block !important;margin: 0 auto !important;}',
  2753. pager: {
  2754. type: 4,
  2755. nextL: manhuagui_nextL,
  2756. pageE: 'css;body > script:not([src])',
  2757. insertP: ['css;#mangaBox', 3],
  2758. insertE: manhuagui_insertE,
  2759. replaceE: 'css;title',
  2760. interval: 4000,
  2761. scrollD: 2500
  2762. }
  2763. }, // 漫画柜
  2764. manhuagui_list: {
  2765. pager: {
  2766. type: 1,
  2767. nextL: '//div[@class="pager"]/a[text()="下一页"]',
  2768. pageE: 'css;.book-result > ul > li, .book-list > ul > li',
  2769. insertP: ['css;.book-result > ul, .book-list > ul', 3],
  2770. replaceE: 'css;.pager',
  2771. scrollD: 1500
  2772. },
  2773. function: {
  2774. bF: src_bF,
  2775. pF: [0, 'img[data-src]', 'data-src']
  2776. }
  2777. }, // 漫画台 - 分类/搜索页
  2778. manhuadb: {
  2779. host: 'www.manhuadb.com',
  2780. functionS: function() {if (indexOF(/\/manhua\/\d+\/.+\.html/)) {
  2781. if (getCSS('img.img-fluid.show-pic')) getCSS('img.img-fluid.show-pic').style.display = 'none'; // 隐藏第一个图片(避免重复)
  2782. setTimeout(manhuadb_init, 100);
  2783. curSite = DBSite.manhuadb;
  2784. } else if (indexOF('/list')) {
  2785. curSite = DBSite.manhuacat_list;
  2786. } else if (indexOF('/search') || indexOF('/update')) {
  2787. curSite = DBSite.manhuacat_search;
  2788. }},
  2789. insStyle: '.row.m-0.pt-3.ad_2_wrap, .row.m-0.ad_1_wrap, .pagination.justify-content-center, #left, #right {display: none !important;}',
  2790. pager: {
  2791. type: 4,
  2792. nextL: manhuadb_nextL,
  2793. pageE: 'css;body > script:not([type]):not([src]), .vg-r-data, ol.links-of-books.num_div',
  2794. insertP: ['css;.pjax-container', 3],
  2795. insertE: manhuadb_insertE,
  2796. interval: 5000,
  2797. scrollD: 3000
  2798. }
  2799. }, // 漫画 DB
  2800. hicomic: {
  2801. host: 'www.hicomic.net',
  2802. functionS: function() {if (indexOF('/chapters/')) {
  2803. setTimeout(hicomic_init, 100);
  2804. curSite = DBSite.hicomic;
  2805. }},
  2806. insStyle: '.content {height: auto !important;} .footer, .left_cursor, .right_cursor, .finish {display: none !important;} .content > img {display: block !important;margin: 0 auto !important;}',
  2807. pager: {
  2808. type: 4,
  2809. nextL: hicomic_nextL,
  2810. insertP: ['css;.content', 3],
  2811. insertE: hicomic_insertE,
  2812. interval: 5000,
  2813. scrollD: 3000
  2814. }
  2815. }, // HiComic (嗨漫画)
  2816. dmzj: {
  2817. host: 'www.dmzj.com',
  2818. functionS: function() {if (indexOF('/view/')) {
  2819. if (getCookie('display_mode') != '1') { // 强制开启 [上下滚动阅读] 模式
  2820. document.cookie='display_mode=1; expires=Thu, 18 Dec 2031 12:00:00 GMT; path=/'; // 写入 Cookie 开启 [上下滚动阅读] 模式
  2821. location.reload(); // 刷新网页
  2822. }
  2823. setTimeout(function() {dmzj_init('.comic_wraCon > a > img')}, 100);
  2824. curSite = DBSite.dmzj;
  2825. } else if (indexOF('/category') || indexOF('/update')) {
  2826. curSite = DBSite.dmzj_list;
  2827. } else if (indexOF('/rank')) {
  2828. curSite = DBSite.dmzj_rank;
  2829. }},
  2830. insStyle: '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;}', // 隐藏中间的页数信息
  2831. history: true,
  2832. pager: {
  2833. type: 4,
  2834. nextL: 'css;span.next > a',
  2835. insertP: ['css;.comic_wraCon', 3],
  2836. insertE: dmzj_insertE,
  2837. replaceE: 'css;.wrap_last_mid, .wrap_last_head',
  2838. interval: 2000,
  2839. scrollD: 3000
  2840. }
  2841. }, // 动漫之家 - 原创
  2842. dmzj_list: {
  2843. insStyle: '.wrap_mhlist_l.con_left, .wrap_list {height: auto!important;}',
  2844. pager: {
  2845. type: 1,
  2846. nextL: 'css;a.pg_next',
  2847. pageE: 'css;ul.list_con_li > li',
  2848. replaceE: 'css;.page',
  2849. scrollD: 1000
  2850. }
  2851. }, // 动漫之家 - 原创 - 分类页
  2852. dmzj_rank: {
  2853. insStyle: '.wrap_mhlist_l.con_left {height: auto!important;}',
  2854. pager: {
  2855. type: 1,
  2856. nextL: 'css;a.pg_next',
  2857. pageE: 'css;.ph_r_con_li > div:not(.ad_column)',
  2858. replaceE: 'css;.page',
  2859. scrollD: 1000
  2860. }
  2861. }, // 动漫之家 - 原创 - 排行榜
  2862. dmzj_manhua: {
  2863. host: 'manhua.dmzj.com',
  2864. functionS: function() {if (indexOF(/\/\d+\.shtml/)) {
  2865. let chapterScroll = getCSS('#qiehuan_txt') // 强制为 [上下滚动阅读] 模式
  2866. if (chapterScroll && chapterScroll.textContent === '切换到上下滚动阅读') {chapterScroll.click();}
  2867. setTimeout(function() {dmzj_init('#center_box > .inner_img img[src]')}, 100);
  2868. curSite = DBSite.dmzj_manhua;
  2869. } else if (indexOF('/update')) {
  2870. curSite = DBSite.dmzj_manhua_update;
  2871. }},
  2872. insStyle: '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;}', // 隐藏中间的页数信息
  2873. history: true,
  2874. pager: {
  2875. type: 4,
  2876. nextL: 'css;#next_chapter',
  2877. insertP: ['css;#center_box', 3],
  2878. insertE: dmzj_manhua_insertE,
  2879. replaceE: 'css;.display_graybg',
  2880. interval: 2000,
  2881. scrollD: 3000
  2882. }
  2883. }, // 动漫之家 - 日漫
  2884. dmzj_manhua_update: {
  2885. pager: {
  2886. type: 1,
  2887. nextL: '//div[@class="pages"]/a[contains(text(), "下一页")]',
  2888. pageE: 'css;.newpic_content > *:not(.pages)',
  2889. replaceE: 'css;.pages',
  2890. scrollD: 1000
  2891. }
  2892. }, //动漫之家 - 日漫 - 最新更新
  2893. acgn: {
  2894. host: 'comic.acgn.cc',
  2895. functionS: function() {
  2896. if (indexOF('/view-')) {
  2897. curSite = DBSite.acgn;
  2898. acgn_aF();
  2899. } else if (indexOF('/cate-') || indexOF('/pinyin-')) {
  2900. curSite = DBSite.acgn_list;
  2901. }
  2902. },
  2903. insStyle: '.img1 {cursor: initial !important;}',
  2904. history: true,
  2905. pager: {
  2906. type: 1,
  2907. nextL: 'css;#next_chapter',
  2908. pageE: 'css;.pic[_src]',
  2909. replaceE: 'css;[class^="display_"]',
  2910. interval: 2000,
  2911. scrollD: 2000
  2912. },
  2913. function: {
  2914. aF: acgn_aF
  2915. }
  2916. }, // 动漫戏说
  2917. acgn_list: {
  2918. pager: {
  2919. type: 1,
  2920. nextL: 'css;a[rel="next"]',
  2921. pageE: 'css;ul#display > li',
  2922. replaceE: 'css;#pagination',
  2923. scrollD: 1000
  2924. }
  2925. }, // 动漫戏说 - 分类页
  2926. copymanga: {
  2927. host: /copymanga\./,
  2928. functionS: function() {if (indexOF('/chapter/')) {
  2929. curSite = DBSite.copymanga;
  2930. } else if (indexOF('/comics')) {
  2931. curSite = DBSite.copymanga_list;
  2932. }},
  2933. insStyle: '.upMember, .comicContainerAds, .footer {display: none !important;} body, html {height: auto !important;}',
  2934. history: true,
  2935. iframe: true,
  2936. pager: {
  2937. type: 5,
  2938. nextL: 'css;.comicContent-next > a',
  2939. insStyle: 'h4.header, h4.header +div[style*="fixed"] {display: none !important;}',
  2940. scrollD: 3000
  2941. }
  2942. }, // 拷贝漫画
  2943. copymanga_list: {
  2944. pager: {
  2945. type: 1,
  2946. nextL: 'css;li.next > a',
  2947. pageE: 'css;.exemptComic-box > div',
  2948. replaceE: 'css;ul.page-all',
  2949. scrollD: 1500
  2950. },
  2951. function: {
  2952. bF: src_bF,
  2953. pF: [0, 'img[data-src]', 'data-src']
  2954. }
  2955. }, // 拷贝漫画 - 分类页
  2956. mhxqiu: {
  2957. host: /\.mhxqiu/,
  2958. functionS: function() {if (indexOF(/\/\d+\.html/)) { // 阅读页
  2959. curSite = DBSite.mhxqiu;
  2960. } else if (indexOF(/\/\d+\/$/)) { // 目录页
  2961. setTimeout(function(){if (getCSS('#zhankai')) getCSS('#zhankai').click();}, 500)
  2962. } else if (indexOF(/\/(sort|rank)\//)) { // 分类页
  2963. curSite = DBSite.mhxqiu_list;
  2964. }},
  2965. insStyle: '.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;}',
  2966. history: true,
  2967. pager: {
  2968. type: 4,
  2969. nextL: 'css;#mainControlNext',
  2970. insertP: ['css;#comicContain', 3],
  2971. insertE: mhxqiu_insertE,
  2972. replaceE: 'css;.main_control, h1.chaptername_title, span.title-comicHeading',
  2973. interval: 4000,
  2974. scrollD: 3000
  2975. }
  2976. }, // 漫画星球
  2977. mhxqiu_list: {
  2978. pager: {
  2979. type: 1,
  2980. nextL: '//div[@class="NewPages"]//a[contains(text(), "下一页")]',
  2981. pageE: 'css;.cy_list_mh > ul',
  2982. replaceE: 'css;.NewPages',
  2983. scrollD: 1000
  2984. }
  2985. }, // 漫画星球 - 分类页
  2986. fffdm: {
  2987. host: 'manhua.fffdm.com',
  2988. functionS: function() {if (location.pathname.split('/').length === 4) {curSite = DBSite.fffdm;}},
  2989. insStyle: '#footer, #header {display: none !important;} #mhimg0 img {display: block !important;margin: 0 auto !important;}',
  2990. history: true,
  2991. pager: {
  2992. type: 4,
  2993. nextL: '//a[contains(text(), "下一页") or contains(text(), "下一頁") or contains(text(), "下一话") or contains(text(), "下一話")]',
  2994. insertP: ['css;#mhimg0', 3],
  2995. insertE: fffdm_insertE,
  2996. replaceE: 'css;.navigation, #weizhi, h1',
  2997. scrollD: 2000
  2998. }
  2999. }, // 风之动漫
  3000. baozimh: {
  3001. host: ['www.webmota.com', 'cn.webmota.com', 'cn.baozimh.com'],
  3002. functionS: function() {
  3003. if (indexOF('/chapter/')) {
  3004. curSite = DBSite.baozimh;
  3005. } else if (indexOF('/comic/')) {
  3006. if (getCSS('#button_show_all_chatper')) getCSS('#button_show_all_chatper').click();
  3007. }},
  3008. insStyle: '#footer, #header {display: none !important;} .header, .bottom-bar {opacity: 0.3;}',
  3009. history: true,
  3010. pager: {
  3011. type: 1,
  3012. nextL: 'css;.next_chapter > a',
  3013. pageE: 'css;.comic-contain > amp-img',
  3014. replaceE: 'css;.next_chapter, .bottom-bar, .header .title',
  3015. scrollD: 2000
  3016. }
  3017. }, // 包子漫画
  3018. leyuman: {
  3019. host: 'www.leyuman.com',
  3020. functionS: function() {if (indexOF(/\/comic\/\d+\/\d+\.html/)) {
  3021. curSite = DBSite.leyuman;
  3022. setTimeout(leyuman_init, 100);
  3023. } else if (indexOF(/\/comic\/\d+\.html/)) {
  3024. setTimeout(function(){if (getCSS('#read-more')) getCSS('#read-more').click();}, 500)
  3025. } else {
  3026. curSite = DBSite.leyuman_list;
  3027. }},
  3028. insStyle: '.mh_select, .mh_comicpic > p, mh_headpager {display: none !important;} .mh_comicpic > img{width: 100% !important; height: auto !important;}',
  3029. history: true,
  3030. pager: {
  3031. type: 4,
  3032. nextL: 'css;#xurl',
  3033. insertP: ['css;.mh_comicpic', 3],
  3034. insertE: leyuman_insertE,
  3035. replaceE: 'css;.mh_headpager, .mh_readtitle',
  3036. interval: 3000,
  3037. scrollD: 3000
  3038. }
  3039. }, // 乐语漫画
  3040. leyuman_list: {
  3041. pager: {
  3042. type: 1,
  3043. nextL: '//a[@class="page-link"][contains(text(), "下一页")]',
  3044. pageE: 'css;.works_recommend.classification_works > ul',
  3045. replaceE: 'css;.paging',
  3046. scrollD: 1000
  3047. },
  3048. function: {
  3049. bF: src_bF,
  3050. pF: [0, 'img[data-src]', 'data-src']
  3051. }
  3052. }, // 乐语漫画 - 分类页
  3053. _77mh: {
  3054. host: 'www.77mh.cc',
  3055. functionS: function() {if (indexOF(/\/\d+\.html/)) {
  3056. curSite = DBSite._77mh;
  3057. setTimeout(_77mh_init, 100);
  3058. } else if (indexOF('/colist_')) {
  3059. setTimeout(function(){if (getCSS('#listmore1, .listmore')) getCSS('#listmore1, .listmore').click();}, 500)
  3060. } else {
  3061. curSite = DBSite._77mh_list;
  3062. }},
  3063. insStyle: '.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;}',
  3064. history: true,
  3065. pager: {
  3066. type: 4,
  3067. nextL: _77mh_nextL,
  3068. insertP: ['css;#comicImg', 3],
  3069. insertE: _77mh_insertE,
  3070. interval: 3000,
  3071. scrollD: 2000
  3072. }
  3073. }, // 新新漫画
  3074. _77mh_list: {
  3075. pager: {
  3076. type: 1,
  3077. nextL: '//div[@class="pages_s"]/a[text()="下一页"]',
  3078. pageE: 'css;.ar_list_co > ul > li',
  3079. replaceE: 'css;.pages_s',
  3080. scrollD: 1000
  3081. }
  3082. }, // 新新漫画 - 分类页
  3083. _77mh_search: {
  3084. host: 'so.77mh.cc',
  3085. pager: {
  3086. type: 1,
  3087. nextL: 'css;a.next',
  3088. pageE: 'css;.ar_list_co > ul > dl',
  3089. replaceE: 'css;.pages_s',
  3090. scrollD: 1000
  3091. }
  3092. }, // 新新漫画 - 搜索页
  3093. gufengmh: {
  3094. host: /gufengmh/,
  3095. functionS: function() {if (indexOF(/\/\d+.+\.html/)) {
  3096. let chapterScroll = getCSS('#chapter-scroll') // 强制为 [下拉阅读] 模式
  3097. if (chapterScroll && chapterScroll.className === '') {chapterScroll.click();}
  3098. curSite = DBSite.gufengmh;
  3099. } else if (indexOF(/\/(update|list|search)/)) {
  3100. curSite = DBSite.gufengmh_list;
  3101. }},
  3102. insStyle: 'p.img_info {display: none !important;}', // 隐藏中间的页数信息
  3103. pager: {
  3104. type: 4,
  3105. nextL: gufengmh_nextL,
  3106. pageE: 'css;body > script:first-child',
  3107. insertP: ['css;#images', 3],
  3108. insertE: gufengmh_insertE,
  3109. interval: 5000,
  3110. scrollD: 4000
  3111. }
  3112. }, // 古风漫画网
  3113. gufengmh_list: {
  3114. pager: {
  3115. type: 1,
  3116. nextL: 'css;li.next > a',
  3117. pageE: 'css;ul.book-list > li',
  3118. replaceE: 'css;ul.pagination',
  3119. scrollD: 1000
  3120. }
  3121. }, // 古风漫画网 - 分类页
  3122. szcdmj: {
  3123. host: 'www.szcdmj.com',
  3124. functionS: function() {
  3125. if (indexOF('/szcchapter/')) {
  3126. curSite = DBSite.szcdmj;
  3127. } else if (indexOF('/szcbook/')) {
  3128. if (getCSS('#detail-list-more')) getCSS('#detail-list-more').click();
  3129. } else if (lp == '/szcbolist' || lp == '/update') {
  3130. curSite = DBSite.szcdmj_list;
  3131. }},
  3132. insStyle: '.header {opacity: 0.3 !important;}',
  3133. history: true,
  3134. pager: {
  3135. type: 1,
  3136. nextL: '//div[@class="fanye"][1]/a[@href][text()="下一页" or text()="下一话"]',
  3137. pageE: 'css;.comicpage > div',
  3138. insertP: ['css;.comicpage', 3],
  3139. replaceE: 'css;.fanye,h1.title',
  3140. scrollD: 2000
  3141. },
  3142. function: {
  3143. bF: src_bF,
  3144. pF: [0, 'img[data-original]', 'data-original']
  3145. }
  3146. }, // 砂之船动漫家
  3147. szcdmj_list: {
  3148. pager: {
  3149. type: 1,
  3150. nextL: 'css;#nextPage',
  3151. pageE: 'css;ul.mh-list > li',
  3152. replaceE: 'css;.pagination',
  3153. scrollD: 1000
  3154. }
  3155. }, // 砂之船动漫家 - 分类/搜索页
  3156. mangabz: {
  3157. host: ['mangabz.com', 'www.mangabz.com'],
  3158. functionS: function() {if (indexOF(/\/m\d+/)) {
  3159. setTimeout(mangabz_init, 1500);
  3160. curSite = DBSite.mangabz;
  3161. } else if (indexOF(/\/\d+bz\//)) {
  3162. if (getCSS('.detail-list-form-more')) getCSS('.detail-list-form-more').click();
  3163. } else if (indexOF('/manga-list') || lp == '/search') {
  3164. curSite = DBSite.mangabz_list;
  3165. }},
  3166. insStyle: '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;}',
  3167. hiddenPN: true,
  3168. history: true,
  3169. pager: {
  3170. type: 4,
  3171. nextL: mangabz_nextL,
  3172. insertP: ['css;#cp_img', 3],
  3173. insertE: mangabz_insertE,
  3174. replaceE: 'css;p.top-title, body > .container > div:not([id])',
  3175. interval: 500,
  3176. scrollD: 2000
  3177. }
  3178. }, // Mangabz 漫画
  3179. mangabz_list: {
  3180. pager: {
  3181. type: 1,
  3182. nextL: '//div[@class="page-pagination"]//a[contains(text(), ">")]',
  3183. pageE: 'css;ul.mh-list > li',
  3184. replaceE: 'css;.page-pagination',
  3185. scrollD: 800
  3186. }
  3187. }, // Mangabz 漫画 - 分类/搜索页
  3188. xmanhua: {
  3189. host: ['xmanhua.com', 'www.xmanhua.com'],
  3190. functionS: function() {if (indexOF(/\/m\d+/)) {
  3191. setTimeout(mangabz_init, 1500);
  3192. curSite = DBSite.xmanhua;
  3193. } else if (indexOF(/\/\d+xm\//)) {
  3194. if (getCSS('.detail-list-form-more')) getCSS('.detail-list-form-more').click();
  3195. } else if (indexOF('/manga-list') || lp == '/search') {
  3196. curSite = DBSite.xmanhua_list;
  3197. }},
  3198. insStyle: '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;}',
  3199. hiddenPN: true,
  3200. history: true,
  3201. pager: {
  3202. type: 4,
  3203. nextL: xmanhua_nextL,
  3204. insertP: ['css;#cp_img', 3],
  3205. insertE: xmanhua_insertE,
  3206. replaceE: 'css;.reader-title, body > .container > div:not([id])',
  3207. interval: 500,
  3208. scrollD: 2500
  3209. }
  3210. }, // Xmanhua 漫画
  3211. xmanhua_list: {
  3212. pager: {
  3213. type: 1,
  3214. nextL: '//div[@class="page-pagination"]//a[contains(text(), ">")]',
  3215. pageE: 'css;ul.mh-list > li',
  3216. replaceE: 'css;.page-pagination',
  3217. scrollD: 1000
  3218. }
  3219. }, // Xmanhua 漫画 - 分类/搜索页
  3220. cocomanga: {
  3221. host: 'www.cocomanga.com',
  3222. functionS: function() {if (indexOF('.html')) {
  3223. if (!(getCookie('mh_readmode') === '' || getCookie('mh_readmode') === '3')) {
  3224. document.cookie='mh_readmode=; expires=Thu, 01 Jan 1970 00:00:00 GMT; path=/'; // 强制开启自带的无缝翻页功能
  3225. location.reload(); // 刷新网页
  3226. }
  3227. setTimeout(cocomanga_init, 500);
  3228. curSite = DBSite.cocomanga;
  3229. } else if (indexOF(/\/\d+\/$/)) {
  3230. setTimeout(function(){if (getCSS('a.website-display-all')) getCSS('a.website-display-all').click();}, 300)
  3231. } else if (lp == '/show') {
  3232. curSite = DBSite.cocomanga_list;
  3233. } else if (lp == '/search') {
  3234. curSite = DBSite.cocomanga_search;
  3235. }},
  3236. insStyle: '.mh_readend, .mh_footpager, .mh_readmode {display: none !important;} .mh_comicpic img {cursor: unset !important;} .mh_comicpic img {min-height: 150px;}',
  3237. history: true,
  3238. pager: {
  3239. type: 4,
  3240. nextL: '//a[contains(@class, "read_page_link") and contains(string(), "下一章")][not(contains(@href, "javascript"))]',
  3241. insertP: ['css;#mangalist', 3],
  3242. insertE: cocomanga_insertE,
  3243. replaceE: 'css;.mh_readtitle, .mh_headpager > a.mh_prevbook, .mh_readend',
  3244. interval: 1000,
  3245. scrollD: 2500
  3246. }
  3247. }, // COCOMANGA 漫画
  3248. cocomanga_list: {
  3249. pager: {
  3250. type: 1,
  3251. nextL: () => getNextP('css;.fed-page-info a.fed-btns-green+a[onclick]', 'page=', /page=\d+/),
  3252. pageE: 'css;ul.fed-list-info > li',
  3253. replaceE: 'css;.fed-page-info',
  3254. scrollD: 1000
  3255. },
  3256. function: {
  3257. bF: src_bF,
  3258. pF: [1, 'a[data-original]', 'data-original']
  3259. }
  3260. }, // COCOMANGA 漫画 - 分类页
  3261. cocomanga_search: {
  3262. pager: {
  3263. type: 1,
  3264. nextL: () => getNextP('css;.fed-page-info a.fed-btns-green+a[onclick]', 'page=', /page=\d+/),
  3265. pageE: 'css;dl.fed-deta-info',
  3266. replaceE: 'css;.fed-page-info',
  3267. scrollD: 1000
  3268. },
  3269. function: {
  3270. bF: src_bF,
  3271. pF: [1, 'a[data-original]', 'data-original']
  3272. }
  3273. }, // COCOMANGA 漫画 - 搜索页
  3274. qidian: {
  3275. host: 'www.qidian.com',
  3276. functionS: function() {if (indexOF('/all/')) {curSite = DBSite.qidian;}},
  3277. pager: {
  3278. type: 1,
  3279. nextL: 'css;a[class*="pagination-next"]',
  3280. pageE: 'css;ul.all-img-list > li',
  3281. replaceE: 'css;#page-container',
  3282. scrollD: 900
  3283. }
  3284. }, // 起点小说
  3285. qidian_read: {
  3286. host: 'read.qidian.com',
  3287. insStyle: '.admire-wrap {display: none !important;}',
  3288. history: true,
  3289. pager: {
  3290. type: 1,
  3291. nextL: 'css;a[id$="chapterNext"]',
  3292. pageE: 'css;.main-text-wrap > div:not(.admire-wrap)',
  3293. replaceE: 'css;.chapter-control',
  3294. scrollD: 900
  3295. }
  3296. }, // 起点小说 - 阅读页
  3297. baoshuu: {
  3298. host: 'www.baoshuu.com',
  3299. functionS: function() {if (indexOF('/TXT/list')) curSite = DBSite.baoshuu;},
  3300. pager: {
  3301. type: 1,
  3302. nextL: '//div[@class="listl2"]//a[text()="下一页"]',
  3303. pageE: 'css;.listl2 > ul > li',
  3304. replaceE: 'css;.listl2 > dl',
  3305. scrollD: 900
  3306. }
  3307. }, // 宝书网
  3308. baoshuu_m: {
  3309. host: 'm.baoshuu.com',
  3310. functionS: function() {if (indexOF('/TXT/list')) curSite = DBSite.baoshuu_m;},
  3311. pager: {
  3312. type: 1,
  3313. nextL: '//div[@class="man_first"]//a[text()="下一页"]',
  3314. pageE: 'css;.man_first > ul > li',
  3315. replaceE: 'css;.man_first > dl',
  3316. scrollD: 900
  3317. }
  3318. }, // 宝书网- 手机版
  3319. yushubo: {
  3320. host: 'www.yushubo.com',
  3321. functionS: function() {if (indexOF('/read_')) {
  3322. curSite = DBSite.yushubo;
  3323. } else if (indexOF('/lists/')) {
  3324. curSite = DBSite.yushubo_list;
  3325. } else if (indexOF('/all')) {
  3326. curSite = DBSite.yushubo_all;
  3327. }},
  3328. insStyle: '.readbg.mt10 {display: none !important;}',
  3329. history: true,
  3330. pager: {
  3331. type: 1,
  3332. nextL: '//div[contains(@class, "articlebtn")]/a[contains(text(), "下一页") or contains(text(), "下一章")]',
  3333. pageE: 'css;#BookText',
  3334. insertP: ['css;#BookText', 6],
  3335. replaceE: 'css;.articlebtn',
  3336. scrollD: 1000
  3337. }
  3338. }, // 御书网
  3339. yushubo_list: {
  3340. pager: {
  3341. type: 1,
  3342. nextL: 'id("pager")//a[contains(text(), "下一页")]',
  3343. pageE: 'css;.books-list > ul > li',
  3344. replaceE: 'css;#pager',
  3345. scrollD: 1000
  3346. }
  3347. }, // 御书网 - 分类页
  3348. yushubo_all: {
  3349. pager: {
  3350. type: 1,
  3351. nextL: 'id("pager")//a[contains(text(), "下一页")]',
  3352. pageE: 'css;ul.search-list > li',
  3353. replaceE: 'css;#pager',
  3354. scrollD: 1000
  3355. }
  3356. }, // 御书网 - 书库页
  3357. xineyby: {
  3358. host: 'www.xineyby.com',
  3359. functionS: function() {if (indexOF('/read/')) {
  3360. curSite = DBSite.xineyby;
  3361. } else if (indexOF(/\/(list|quanben|search)/)) {
  3362. curSite = DBSite.xineyby_list;
  3363. }},
  3364. history: true,
  3365. pager: {
  3366. type: 1,
  3367. nextL: 'id("footlink")/a[contains(text(), "下一页")]',
  3368. pageE: 'css;#contents',
  3369. insertP: ['css;#contents', 6],
  3370. replaceE: 'css;#footlink, #amain dd h1',
  3371. scrollD: 900
  3372. }
  3373. }, // 无错小说网
  3374. xineyby_list: {
  3375. pager: {
  3376. type: 1,
  3377. nextL: 'css;#pagelink a.next',
  3378. pageE: 'css;#content > dd tbody > tr:not(:first-child)',
  3379. insertP: ['css;#content > dd tbody', 3],
  3380. replaceE: 'css;#pagelink',
  3381. scrollD: 900
  3382. }
  3383. }, // 无错小说网 - 分类/搜索页
  3384. linovel: {
  3385. host: 'www.linovel.net',
  3386. functionS: function() {if (indexOF(/\/book\/\d+\/.+\.html/)) {
  3387. insStyle('.reward-section {display: none !important;}');
  3388. } else if (indexOF('/cat/')) {
  3389. curSite = DBSite.linovel;
  3390. }},
  3391. pager: {
  3392. type: 1,
  3393. nextL: '//ul[@class="pagination"]/li/a[contains(text(), "下一页")]',
  3394. pageE: 'css;.rank-book-list > div',
  3395. replaceE: 'css;ul.pagination',
  3396. scrollD: 1000
  3397. }
  3398. }, // 轻之文库
  3399. _23qb: {
  3400. host: 'www.23qb.net',
  3401. functionS: function() {if (indexOF(/\/book\/\d+\/.+\.html/)) {
  3402. curSite = DBSite._23qb;
  3403. } else if (location.pathname != '/' && !indexOF(/\/book\/\d+\//)) {
  3404. curSite = DBSite._23qb_list;
  3405. }},
  3406. pager: {
  3407. type: 1,
  3408. nextL: () => (location.origin + ReadParams.url_next),
  3409. pageE: 'id("mlfy_main_text")/* | //script[contains(text(), "ReadParams")]',
  3410. insertP: ['css;#mlfy_main_text', 3],
  3411. replaceE: 'css;title',
  3412. scriptT: 2,
  3413. scrollD: 1500
  3414. }
  3415. }, // 铅笔小说
  3416. _23qb_list: {
  3417. pager: {
  3418. type: 1,
  3419. nextL: 'css;.pages a.next, .pages > strong+a',
  3420. pageE: 'css;#sitebox > dl',
  3421. replaceE: 'css;.pages',
  3422. scrollD: 1000
  3423. },
  3424. function: {
  3425. bF: src_bF,
  3426. pF: [0, 'img[_src]', '_src']
  3427. }
  3428. }, // 铅笔小说 - 分类页
  3429. linovelib: {
  3430. host: 'www.linovelib.com',
  3431. functionS: function() {if (indexOF(/\/novel\/\d+\/.+\.html/)) {
  3432. curSite = DBSite.linovelib;
  3433. } else if (indexOF('/wenku/')) {
  3434. curSite = DBSite.linovelib_wenku;
  3435. } else if (indexOF('/top/') || indexOF('/topfull/') || indexOF('toplist.php')) {
  3436. curSite = DBSite.linovelib_top;
  3437. }},
  3438. history: true,
  3439. pager: {
  3440. type: 1,
  3441. nextL: '//p[@class="mlfy_page"]/a[contains(text(), "下一页") or contains(text(), "下一章")]',
  3442. pageE: 'css;#mlfy_main_text > *',
  3443. replaceE: 'css;p.mlfy_page',
  3444. scrollD: 1000
  3445. }
  3446. }, // 哔哩轻小说
  3447. linovelib_wenku: {
  3448. pager: {
  3449. type: 1,
  3450. nextL: 'css;#pagelink > a.next',
  3451. pageE: 'css;.store_collist > div.bookbox',
  3452. replaceE: 'css;#pagelink',
  3453. scrollD: 1000
  3454. },
  3455. function: {
  3456. bF: src_bF,
  3457. pF: [0, 'img[data-original]', 'data-original']
  3458. }
  3459. }, // 哔哩轻小说 - 文库
  3460. linovelib_top: {
  3461. pager: {
  3462. type: 1,
  3463. nextL: 'css;#pagelink > a.next',
  3464. pageE: 'css;.rankpage_box > div.rank_d_list',
  3465. replaceE: 'css;#pagelink',
  3466. scrollD: 1000
  3467. },
  3468. function: {
  3469. bF: src_bF,
  3470. pF: [0, 'img[data-original]', 'data-original']
  3471. }
  3472. }, // 哔哩轻小说 - 全本
  3473. linovelib_w: {
  3474. host: 'w.linovelib.com',
  3475. functionS: function() {if (indexOF(/\/novel\/\d+\/.+\.html/)) {
  3476. curSite = DBSite.linovelib_w;
  3477. } else if (indexOF('/wenku/') || indexOF('/sa/')) {
  3478. curSite = DBSite.linovelib_w_wenku;
  3479. }},
  3480. insStyle: 'body {min-height: 1000px;}',
  3481. history: true,
  3482. pager: {
  3483. type: 1,
  3484. nextL: function() {if (ReadParams) {return (location.origin + ReadParams.url_next)}; return ''},
  3485. pageE: '//body/script[contains(text(), "var ReadParams")] | id("apage")/div',
  3486. insertP: ['css;#apage', 3],
  3487. scriptT: 2,
  3488. scrollD: 1000
  3489. }
  3490. }, // 哔哩轻小说 (手机版)
  3491. linovelib_w_wenku: {
  3492. pager: {
  3493. type: 1,
  3494. nextL: 'css;#pagelink > strong+a ,#pagelink a.next',
  3495. pageE: 'css;ol.book-ol > li',
  3496. replaceE: 'css;#pagelink',
  3497. scrollD: 1000
  3498. },
  3499. function: {
  3500. bF: src_bF,
  3501. pF: [0, 'img[data-original]', 'data-original']
  3502. }
  3503. }, // 哔哩轻小说 (手机版) - 文库
  3504. _423down: {
  3505. host: 'www.423down.com',
  3506. functionS: function() {if (!indexOF('.html')) curSite = DBSite._423down;},
  3507. pager: {
  3508. type: 1,
  3509. nextL: '//div[@class="paging"]//a[contains(text(),"下一页")]',
  3510. pageE: 'css;div.content-wrap ul.excerpt > li',
  3511. replaceE: 'css;div.paging',
  3512. scrollD: 2000
  3513. }
  3514. }, // 423Down
  3515. iao_su: {
  3516. host: 'iao.su',
  3517. pager: {
  3518. type: 1,
  3519. nextL: 'css;li.next > a',
  3520. pageE: 'css;#index > article, #archive > article',
  3521. insertP: ['css;ol.page-navigator', 1],
  3522. replaceE: 'css;ol.page-navigator',
  3523. scriptT: 3,
  3524. scrollD: 1000
  3525. }
  3526. }, // 不死鸟
  3527. sharerw: {
  3528. host: 'www.sharerw.com',
  3529. functionS: function() {if (!indexOF('.html')) {if (lp == '/search.php') {curSite = DBSite.sharerw_search;} else {curSite = DBSite.sharerw;};};},
  3530. pager: {
  3531. type: 1,
  3532. nextL: 'css;span.next > a',
  3533. pageE: 'css;.new-post > article',
  3534. replaceE: 'css;.pagebar',
  3535. scrollD: 1500
  3536. }
  3537. }, // 分享者
  3538. sharerw_search: {
  3539. pager: {
  3540. type: 1,
  3541. nextL: 'css;span.next > a',
  3542. pageE: 'css;#mainbox > article',
  3543. replaceE: 'css;.pagebar',
  3544. scrollD: 1500
  3545. }
  3546. }, // 分享者 - 搜索页
  3547. extfans: {
  3548. host: 'www.extfans.com',
  3549. functionS: function() {if (location.pathname != '/') {curSite = DBSite.extfans;}},
  3550. pager: {
  3551. type: 1,
  3552. nextL: 'css;.page a[data-page="next"]',
  3553. pageE: 'css;.side-left > ul[class*="-list"] > li',
  3554. replaceE: 'css;.page',
  3555. scrollD: 2000
  3556. }
  3557. }, // 扩展迷
  3558. chrome_zzzmh: {
  3559. host: 'chrome.zzzmh.cn',
  3560. pager: {
  3561. type: 2,
  3562. nextL: 'css;button.more-btn',
  3563. interval: 1000,
  3564. scrollD: 1500
  3565. }
  3566. }, // 极简插件
  3567. appinn: {
  3568. host: 'www.appinn.com',
  3569. pager: {
  3570. type: 1,
  3571. nextL: 'css;a.next.page-numbers',
  3572. pageE: 'css;section#latest-posts > article',
  3573. replaceE: 'css;div.nav-links',
  3574. scrollD: 1500
  3575. }
  3576. }, // 小众软件
  3577. isharepc: {
  3578. host: 'www.isharepc.com',
  3579. pager: {
  3580. type: 1,
  3581. nextL: 'css;a.next',
  3582. pageE: 'css;.content > div',
  3583. replaceE: 'css;nav.pagination',
  3584. scrollD: 1000
  3585. }
  3586. }, // 乐软博客
  3587. ghxi: {
  3588. host: 'www.ghxi.com',
  3589. functionS: function() {if (lp == '/' && !location.search) {curSite = DBSite.ghxi;} else {curSite = DBSite.ghxi_list;}},
  3590. pager: {
  3591. type: 2,
  3592. nextL: 'css;.load-more',
  3593. interval: 1000,
  3594. scrollD: 5000
  3595. }
  3596. }, // 果核剥壳 - 首页
  3597. ghxi_list: {
  3598. pager: {
  3599. type: 1,
  3600. nextL: 'css;a.next',
  3601. pageE: 'css;ul.post-loop > li',
  3602. replaceE: 'css;ul.pagination',
  3603. scrollD: 1500
  3604. },
  3605. function: {
  3606. bF: src_bF,
  3607. pF: [0, 'img[data-original]', 'data-original']
  3608. }
  3609. }, // 果核剥壳 - 分类/搜索页
  3610. sixyin: {
  3611. host: 'www.sixyin.com',
  3612. functionS: function() {if (lp == '/' && location.search === '') { // 首页
  3613. curSite = DBSite.sixyin;
  3614. } else if (!indexOF('.html')) { // 分类页
  3615. curSite = DBSite.sixyin_list;
  3616. }},
  3617. pager: {
  3618. type: 2,
  3619. nextL: 'css;.load-more',
  3620. nextHTML: '点击查看更多',
  3621. scrollD: 1500
  3622. }
  3623. }, // 六音软件 - 首页
  3624. sixyin_list: {
  3625. pager: {
  3626. type: 1,
  3627. nextL: 'css;a.next',
  3628. pageE: 'css;ul.post-loop > li',
  3629. replaceE: 'css;ul.pagination',
  3630. scrollD: 1500
  3631. }
  3632. }, // 六音软件 - 分类页
  3633. apprcn: {
  3634. host: ['www.apprcn.com', 'free.apprcn.com'],
  3635. functionS: function() {if (lp == '/' || indexOF('/category/')) {curSite = DBSite.apprcn;}},
  3636. pager: {
  3637. type: 1,
  3638. nextL: '//div[@class="pagination"]//a[contains(text(), "Next")]',
  3639. pageE: 'css;article.article',
  3640. replaceE: 'css;.pagination',
  3641. scrollD: 1000
  3642. }
  3643. }, // 反斗软件
  3644. weidown: {
  3645. host: 'www.weidown.com',
  3646. functionS: function() {if (indexOF('/search/')) { //搜索页
  3647. curSite = DBSite.weidown_search;
  3648. } else if (indexOF('/special')) { // 专题页
  3649. curSite = DBSite.weidown_special;
  3650. } else {
  3651. curSite = DBSite.weidown;
  3652. }},
  3653. pager: {
  3654. type: 1,
  3655. nextL: 'css;a.nextpage',
  3656. pageE: 'css;.articleWrapper > .itemArticle, .articleWrapper > .richTextItem.search',
  3657. insertP: ['css;.articleWrapper', 3],
  3658. replaceE: 'css;#pageGroup',
  3659. scrollD: 1500
  3660. }
  3661. }, // 微当下载
  3662. weidown_search: {
  3663. pager: {
  3664. type: 1,
  3665. nextL: 'css;a.nextpage',
  3666. pageE: 'css;.articleListWrapper > .richTextItem.search',
  3667. replaceE: 'css;#pageGroup',
  3668. scrollD: 700
  3669. }
  3670. }, // 微当下载 - 搜索页
  3671. weidown_special: {
  3672. pager: {
  3673. type: 1,
  3674. nextL: 'css;a.nextpage',
  3675. pageE: 'css;.special > .item, .articleWrapper > div',
  3676. insertP: ['css;.special, .articleWrapper', 3],
  3677. replaceE: 'css;#pageGroup',
  3678. scrollD: 700
  3679. }
  3680. }, // 微当下载 - 专题页
  3681. fsylr: {
  3682. host: 'fsylr.com',
  3683. functionS: function() {if (!indexOF('.html')) {curSite = DBSite.fsylr;}},
  3684. pager: {
  3685. type: 1,
  3686. nextL: 'css;a.next.page-numbers',
  3687. pageE: 'css;.posts-con > div:not([class*="posts-"])',
  3688. replaceE: 'css;nav.pagination',
  3689. scrollD: 2000
  3690. }
  3691. }, // 发烧友绿软
  3692. iplaysoft: {
  3693. host: 'www.iplaysoft.com',
  3694. functionS: function() {if (indexOF('.html') || indexOF('/p/')) {curSite = DBSite.iplaysoft_comment;} else {curSite = DBSite.iplaysoft;}},
  3695. pager: {
  3696. type: 1,
  3697. nextL: 'css;.pagenavi a[title="下一页"]',
  3698. pageE: 'css;#postlist > div.entry',
  3699. replaceE: 'css;.pagenavi-button, .pagenavi',
  3700. scrollD: 1200
  3701. },
  3702. function: {
  3703. bF: src_bF,
  3704. pF: [0, 'img[data-src]', 'data-src']
  3705. }
  3706. }, // 异次元软件
  3707. iplaysoft_comment: {
  3708. pager: {
  3709. type: 2,
  3710. nextL: 'css;#loadHistoryComments',
  3711. nextTextOf: '展开后面',
  3712. scrollD: 1200
  3713. }
  3714. }, // 异次元软件 - 评论
  3715. mubolin: {
  3716. host: 'www.mubolin.cn',
  3717. pager: {
  3718. type: 1,
  3719. nextL: 'css;a.next.page-numbers',
  3720. pageE: 'css;#recent-content > div',
  3721. replaceE: 'css;nav.pagination',
  3722. scrollD: 1500
  3723. }
  3724. }, // 悪魔の小站
  3725. mpyit: {
  3726. host: 'www.mpyit.com',
  3727. functionS: function() {if (lp == '/' && !location.search) {
  3728. curSite = DBSite.mpyit;
  3729. } else if (indexOF('/category/') || indexOF('?s=', 's')) { // 搜索页 / 分类页
  3730. curSite = DBSite.mpyit_category;
  3731. }},
  3732. pager: {
  3733. type: 1,
  3734. nextL: 'css;a.page-numbers[title="下一页"]',
  3735. pageE: 'css;#post > div[id^="post-"]',
  3736. replaceE: 'css;#post > #pagenavi',
  3737. scrollD: 1700
  3738. }
  3739. }, // 老殁 | 殁漂遥
  3740. mpyit_category: {
  3741. pager: {
  3742. type: 1,
  3743. nextL: 'css;a.page-numbers[title="下一页"]',
  3744. pageE: 'css;#content > div[class^="entry_box"]',
  3745. replaceE: 'css;#content > #pagenavi',
  3746. scrollD: 1700
  3747. }
  3748. }, // 老殁 | 殁漂遥 - 搜索页/分类页
  3749. tenlonstudio: {
  3750. host: 'www.tenlonstudio.com',
  3751. functionS: function() {if (lp == '/' && !location.search) {
  3752. curSite = DBSite.tenlonstudio;
  3753. } else {
  3754. curSite = DBSite.tenlonstudio_list;
  3755. }},
  3756. pager: {
  3757. type: 2,
  3758. nextL: 'css;.load-more',
  3759. nextText: '加载更多',
  3760. interval: 500,
  3761. scrollD: 1000
  3762. }
  3763. }, // 腾龙工作室
  3764. tenlonstudio_list: {
  3765. pager: {
  3766. type: 1,
  3767. nextL: '//div[@class="btn-pager"]/a[contains(text(), "❯")]',
  3768. pageE: 'css;li.post-list-item',
  3769. replaceE: 'css;.ajax-pager',
  3770. scrollD: 1000
  3771. }
  3772. }, // 腾龙工作室 - 分类/搜索页
  3773. yxssp: {
  3774. host: 'www.yxssp.com',
  3775. pager: {
  3776. type: 1,
  3777. nextL: '//div[contains(@class, "page-nav")]/a[last()]',
  3778. pageE: 'css;.td-modules-container.td-module-number4 > div',
  3779. replaceE: 'css;.page-nav.td-pb-padding-side',
  3780. scrollD: 1000
  3781. }
  3782. }, // 异星软件空间
  3783. yrxitong: {
  3784. host: 'www.yrxitong.com',
  3785. functionS: function() {
  3786. if (lp == '/sr.jsp') {
  3787. curSite = DBSite.yrxitong_search;
  3788. } else if (!indexOF('/h-nd-')) {
  3789. curSite = DBSite.yrxitong;
  3790. }
  3791. },
  3792. pager: {
  3793. type: 1,
  3794. nextL: 'css;span.pageNext > a',
  3795. pageE: 'css;#containerFormsCenter .m_news_list > div',
  3796. replaceE: 'css;.pagenation',
  3797. scrollD: 1200
  3798. },
  3799. function: {
  3800. bF: src_bF,
  3801. pF: [1, 'a[data-original]', 'data-original']
  3802. }
  3803. }, // 小鱼儿 yr 系统
  3804. yrxitong_search: {
  3805. pager: {
  3806. type: 1,
  3807. nextL: 'css;span.pageNext > a',
  3808. pageE: 'css;#containerFormsCenter .newsList > div',
  3809. replaceE: 'css;.pagenation',
  3810. scrollD: 2000
  3811. }
  3812. }, // 小鱼儿 yr 系统 - 搜索页
  3813. downg: {
  3814. host: 'www.downg.com',
  3815. functionS: function() {if (indexOF('/new/')) {curSite = DBSite.downg;}},
  3816. pager: {
  3817. type: 1,
  3818. nextL: 'css;a.nextpage',
  3819. pageE: 'css;.ApdList > ul.ApdLi',
  3820. replaceE: 'css;.pagination',
  3821. scrollD: 1500
  3822. }
  3823. }, // 绿软家园
  3824. sordum: {
  3825. host: 'www.sordum.org',
  3826. pager: {
  3827. type: 1,
  3828. nextL: 'css;a.next.page-numbers',
  3829. pageE: 'css;.article > article',
  3830. replaceE: 'css;nav.navigation.posts-navigation',
  3831. scrollD: 1500
  3832. }
  3833. }, // (下面这几个都是国外博客网站)
  3834. winaero: {
  3835. host: 'winaero.com',
  3836. functionS: function() {if (lp == '/blog/' || indexOF('/category/')) curSite = DBSite.winaero;},
  3837. pager: {
  3838. type: 1,
  3839. nextL: 'css;.nav-previous > a',
  3840. pageE: 'css;#content > article',
  3841. replaceE: 'css;#nav-below',
  3842. scrollD: 1500
  3843. }
  3844. },
  3845. lrepacks: {
  3846. host: 'lrepacks.net',
  3847. functionS: function() {if (!indexOF('.html')) curSite = DBSite.lrepacks;},
  3848. pager: {
  3849. type: 1,
  3850. nextL: 'css;.page_next > a',
  3851. pageE: 'css;#main .post-list article',
  3852. replaceE: 'css;.page_nav',
  3853. scrollD: 1500
  3854. },
  3855. function: {
  3856. bF: lrepacks_bF
  3857. }
  3858. },
  3859. winhelponline: {
  3860. host: 'www.winhelponline.com',
  3861. functionS: function() {if (lp == '/blog/') {curSite = DBSite.winhelponline;}},
  3862. pager: {
  3863. type: 1,
  3864. nextL: 'css;span.prev > a',
  3865. pageE: 'css;#main > article',
  3866. replaceE: 'css;nav.paging-navigation',
  3867. scrollD: 2000
  3868. }
  3869. },
  3870. windowslatest: {
  3871. host: 'www.windowslatest.com',
  3872. pager: {
  3873. type: 1,
  3874. nextL: '//div[contains(@class, "page-nav")]/a[last()]',
  3875. pageE: 'css;.td-ss-main-content > div:not(.td-block-title-wrap):not(.page-nav)',
  3876. replaceE: 'css;.page-nav',
  3877. scrollD: 2000
  3878. }
  3879. },
  3880. thewindowsclub: {
  3881. host: 'www.thewindowsclub.com',
  3882. functionS: function() {curSite = DBSite.thewindowsclub; if (lp == '/') {curSite.pager.scrollD = 2000;}},
  3883. pager: {
  3884. type: 1,
  3885. nextL: 'css;li.pagination-next > a',
  3886. pageE: 'css;#genesis-content > article',
  3887. replaceE: 'css;.pagination',
  3888. scrollD: 1500
  3889. }
  3890. },
  3891. acs: {
  3892. host: ['pubs.acs.org','onlinelibrary.wiley.com'],
  3893. functionS: function() {if (indexOF('/doSearch')) {curSite = DBSite.acs;}},
  3894. history: true,
  3895. pager: {
  3896. type: 1,
  3897. nextL: 'css;a.pagination__btn--next',
  3898. pageE: 'css;ul.items-results > *',
  3899. replaceE: 'css;.pagination',
  3900. scrollD: 3000
  3901. }
  3902. }, // Wiley Online Library + ACS (Publications)
  3903. libgen: {
  3904. host: /libgen/,
  3905. functionS: function() {if (lp == '/search.php') {curSite = DBSite.libgen;}},
  3906. history: true,
  3907. pager: {
  3908. type: 1,
  3909. nextL: '//font/a[contains(text(), "►")]',
  3910. pageE: 'css;table[rules="rows"] > tbody > tr:nth-of-type(n+2), .paginator+script:not([src])',
  3911. insertP: ['css;table[rules="rows"] > tbody', 3],
  3912. replaceE: '//td[./font/a[contains(text(), "►")]]',
  3913. scriptT: 2,
  3914. scrollD: 2000
  3915. }
  3916. }, // Library Genesis
  3917. sciencedirect: {
  3918. host: 'www.sciencedirect.com',
  3919. functionS: function() {locationC = true; if (lp == '/search') {curSite = DBSite.sciencedirect; setTimeout(function(){insStyle('html, body {height: ' + (document.documentElement.scrollHeight || document.body.scrollHeight) + 'px;}')}, 2000)}},
  3920. insStyle: 'footer {display: none !important;}',
  3921. history: true,
  3922. iframe: true,
  3923. pager: {
  3924. type: 5,
  3925. nextL: 'css;a[data-aa-name="srp-next-page"]',
  3926. scrollD: 2000
  3927. }
  3928. }, // ScienceDirect
  3929. pubmed: {
  3930. host: 'pubmed.ncbi.nlm.nih.gov',
  3931. pager: {
  3932. type: 2,
  3933. nextL: 'css;button.load-button.next-page',
  3934. nextText: 'Show more results',
  3935. scrollD: 1500
  3936. }
  3937. }, // PubMed
  3938. x_mol: {
  3939. host: 'www.x-mol.com',
  3940. functionS: function() {if (indexOF('/search/q') || indexOF('/paper/')) {curSite = DBSite.x_mol;}},
  3941. history: true,
  3942. pager: {
  3943. type: 1,
  3944. nextL: () => getNextP('css;.pagination li.active+li > a', 'pageIndex=', /pageIndex=\d+/),
  3945. pageE: 'css;.magazine-senior-search-results-list > ul > li, .magazine-model-content-new > ul > li',
  3946. insertP: ['css;.magazine-senior-search-results-list > ul, .magazine-model-content-new > ul', 3],
  3947. replaceE: 'css;.pagination',
  3948. scrollD: 2000
  3949. }
  3950. }, // X-MOL
  3951. cqvip: {
  3952. host: 'www.cqvip.com',
  3953. functionS: function() {if (indexOF('/search')) {curSite = DBSite.cqvip;}},
  3954. history: true,
  3955. pager: {
  3956. type: 6,
  3957. nextL: '//ul[@class="pagenum"]//a[text()="下一页"]',
  3958. pageE: 'css;ul.prolist:last-child > li',
  3959. replaceE: 'css;ul.pagenum',
  3960. loadTime: 1000,
  3961. scrollD: 2000
  3962. }
  3963. }, // 维普网
  3964. ablesci: {
  3965. host: 'www.ablesci.com',
  3966. functionS: function() {if (indexOF('/detail') && GM_getValue('menu_discuz_thread_page')) {curSite = DBSite.ablesci_p;} else if (getCSS('ul.fly-list')) {curSite = DBSite.ablesci;}},
  3967. pager: {
  3968. type: 1,
  3969. nextL: 'css;li.next > a',
  3970. pageE: 'css;ul.fly-list > li',
  3971. replaceE: 'css;.pages',
  3972. scrollD: 2000
  3973. }
  3974. }, // 科研通
  3975. ablesci_p: {
  3976. pager: {
  3977. type: 1,
  3978. nextL: 'css;li.next > a',
  3979. pageE: 'css;ul#jieda > li',
  3980. replaceE: 'css;.pages',
  3981. scrollD: 2000
  3982. }
  3983. }, // 科研通 - 帖子内
  3984. google_scholar: {
  3985. pager: {
  3986. type: 1,
  3987. nextL: '//a[./span[contains(@class, "next")]]',
  3988. pageE: 'css;#gs_res_ccl_mid > *',
  3989. replaceE: 'id("gs_n")',
  3990. scriptT: 1,
  3991. scrollD: 2000
  3992. }
  3993. }, // 谷歌学术
  3994. bing_academic: {
  3995. insStyle: 'li.aca_algo_count {display: none !important;}',
  3996. pager: {
  3997. type: 1,
  3998. nextL: 'css;a.sb_pagN',
  3999. pageE: 'css;#b_results > li.aca_algo',
  4000. replaceE: 'css;#b_results .b_pag',
  4001. scrollD: 1000
  4002. }
  4003. }, // 必应学术
  4004. baidu_xueshu: {
  4005. host: 'xueshu.baidu.com',
  4006. functionS: function() {if (lp == '/s') {
  4007. curSite = DBSite.baidu_xueshu;
  4008. } else if (indexOF('journal/navigation')) {
  4009. curSite = DBSite.baidu_xueshu_journal;
  4010. } else if (indexOF('paper/show')) {
  4011. curSite = DBSite.baidu_xueshu_paper;
  4012. }},
  4013. history: true,
  4014. pager: {
  4015. type: 1,
  4016. nextL: 'id("page")/a[./i[@class="c-icon-pager-next"]]',
  4017. pageE: 'css;#bdxs_result_lists > div.result',
  4018. replaceE: 'css;#page',
  4019. scrollD: 1000
  4020. }
  4021. }, // 百度学术
  4022. baidu_xueshu_journal: {
  4023. history: true,
  4024. pager: {
  4025. type: 1,
  4026. nextL: 'css;a.res-page-next',
  4027. pageE: 'css;#journaldetail > div',
  4028. replaceE: 'css;.res-page',
  4029. scrollD: 1000
  4030. }
  4031. }, // 百度学术
  4032. baidu_xueshu_paper: {
  4033. pager: {
  4034. type: 2,
  4035. nextL: 'css;div:not([style*="display: none"]) > .more_btn',
  4036. nextText: '加载更多',
  4037. scrollD: 1000
  4038. }
  4039. }, // 百度学术
  4040. so_xueshu: {
  4041. host: 'xueshu.so.com',
  4042. functionS: function() {if (lp == '/s') {curSite = DBSite.so_xueshu;}},
  4043. pager: {
  4044. type: 1,
  4045. nextL: 'css;a#snext',
  4046. pageE: 'css;ul.list > li',
  4047. replaceE: 'css;#page',
  4048. scrollD: 1000
  4049. }
  4050. }, // 360 学术
  4051. wanfangdata: {
  4052. host: 's.wanfangdata.com.cn',
  4053. functionS: function() {locationC = true; curSite = DBSite.wanfangdata;},
  4054. insStyle: '#zkFooter {display: none !important;}',
  4055. history: true,
  4056. iframe: true,
  4057. pager: {
  4058. type: 5,
  4059. nextL: () => getNextP('css;.pager.active+span.pager', 'p=', /p=\d+/),
  4060. scrollD: 2000
  4061. }
  4062. }, // 万方数据知识服务平台
  4063. nsfc: {
  4064. host: ['output.nsfc.gov.cn', 'kd.nsfc.gov.cn'],
  4065. functionS: function() {if (indexOF('/conclusionProject/')) curSite = DBSite.nsfc;},
  4066. insStyle: '#pageNoUl {display: none !important;}',
  4067. pager: {
  4068. type: 4,
  4069. nextL: nsfc_nextL,
  4070. insertP: ['css;#pageNoUl', 1],
  4071. insertE: nsfc_insertE,
  4072. scrollD: 1500
  4073. }
  4074. }, // 国家自然科学基金
  4075. coolkeyan: {
  4076. host: 'www.coolkeyan.com',
  4077. functionS: function() {if (location.hash.indexOf('/project/') > -1) curSite = DBSite.coolkeyan;},
  4078. insStyle: '.q-img {height: auto !important;} .q-img__image {max-height: 1000px !important;} .row.q-my-sm.q-gutter-sm {display: none !important;}',
  4079. pager: {
  4080. type: 4,
  4081. nextL: coolkeyan_nextL,
  4082. insertP: ['//div[contains(@class, "q-img__image")][last()]', 4],
  4083. insertE: coolkeyan_insertE,
  4084. scrollD: 1500
  4085. }
  4086. }, // 酷科研
  4087. stackoverflow: {
  4088. host: 'stackoverflow.com',
  4089. functionS: function() {if (indexOF('/questions') && !indexOF(/\/questions\/\d+\//)) {
  4090. curSite = DBSite.stackoverflow;
  4091. } else if (lp == '/search') {
  4092. curSite = DBSite.stackoverflow_search;
  4093. } else if (lp == '/tags') {
  4094. curSite = DBSite.stackoverflow_tags;
  4095. } else if (lp == '/users') {
  4096. curSite = DBSite.stackoverflow_users;
  4097. }},
  4098. pager: {
  4099. type: 1,
  4100. nextL: 'css;a[rel="next"]',
  4101. pageE: 'css;#questions > div',
  4102. replaceE: 'css;.pager',
  4103. scrollD: 2000
  4104. }
  4105. }, // StackOverflow - Questions
  4106. stackoverflow_tags: {
  4107. pager: {
  4108. type: 1,
  4109. nextL: 'css;a[rel="next"]',
  4110. pageE: 'css;#tags-browser > div',
  4111. replaceE: 'css;.pager',
  4112. scrollD: 2000
  4113. }
  4114. }, // StackOverflow - Tags
  4115. stackoverflow_users: {
  4116. pager: {
  4117. type: 1,
  4118. nextL: 'css;a[rel="next"]',
  4119. pageE: 'css;#user-browser > div:first-child > div',
  4120. replaceE: 'css;.pager',
  4121. scrollD: 2000
  4122. }
  4123. }, // StackOverflow - Users
  4124. stackoverflow_search: {
  4125. pager: {
  4126. type: 1,
  4127. nextL: 'css;a[rel="next"]',
  4128. pageE: 'css;.js-search-results > div:first-child > div',
  4129. replaceE: 'css;.pager',
  4130. scrollD: 2000
  4131. }
  4132. }, // StackOverflow - Search
  4133. segmentfault: {
  4134. host: 'segmentfault.com',
  4135. functionS: function() {locationC = true;
  4136. if (indexOF('/questions')) {
  4137. curSite = DBSite.segmentfault;
  4138. } else if (lp == '/search') {
  4139. curSite = DBSite.segmentfault_search;
  4140. }},
  4141. pager: {
  4142. type: 1,
  4143. nextL: '//a[@class="page-link"][contains(text(), "下一页")]',
  4144. pageE: 'css;ul.list-group > li',
  4145. replaceE: 'css;ul.pagination',
  4146. scrollD: 1000
  4147. }
  4148. }, // SegmentFault - Questions
  4149. segmentfault_search: {
  4150. pager: {
  4151. type: 1,
  4152. nextL: 'css;a[rel="next"]',
  4153. pageE: 'css;.search-result > section',
  4154. replaceE: 'css;ul.pagination',
  4155. scrollD: 1000
  4156. }
  4157. }, // SegmentFault - Search
  4158. w3school_cn: {
  4159. host: 'www.w3school.com.cn',
  4160. functionS: function() {if (location.pathname.split('/').length > 2) {curSite = DBSite.w3school_cn;}},
  4161. insStyle: '#maincontent h1:not(:nth-of-type(1)) {margin-top: 30px;}',
  4162. history: true,
  4163. pager: {
  4164. type: 3,
  4165. nextL: function() { // 过滤部分非本页的参考手册
  4166. let next = getCSS('li.next > a[href]')
  4167. if (next && next.href.indexOf('/index.') === -1) return next.href;
  4168. curSite = {SiteTypeID: 0}; return ''
  4169. },
  4170. pageE: 'css;#maincontent > *:not([class*="prenextnav"]):not(#bpn):not(#tpn)',
  4171. insertP: ['id("bpn") | //div[contains(@class, "prenextnav")][last()]', 1],
  4172. replaceE: 'css;ul.prenext, #navsecond',
  4173. scrollE: 'id("bpn") | //div[contains(@class, "prenextnav")][last()]',
  4174. forceHTTPS: true,
  4175. scrollD: 600
  4176. }
  4177. }, // W3school
  4178. runoob: {
  4179. host: 'www.runoob.com',
  4180. functionS: function() {if (location.pathname.split('/').length > 2 && getCSS('#leftcolumn')) {curSite = DBSite.runoob;}},
  4181. insStyle: '#comments, #postcomments, #respond, #footer {display: none !important;} .article-intro h1:not(:nth-of-type(1)) {margin: 30px 0 10px 0;}',
  4182. history: true,
  4183. pager: {
  4184. type: 1,
  4185. nextL: function() { // 过滤部分非本页的参考手册
  4186. let next = getCSS('#leftcolumn > a[style]~a[href]')
  4187. if (next && next.href.split('/').length === location.href.split('/').length && next.href.split('/')[3] === location.href.split('/')[3]) return next.href;
  4188. next.href = location.href; curSite = {SiteTypeID: 0}; return ''
  4189. },
  4190. pageE: 'css;#content > *',
  4191. insertP: ['css;#content', 3],
  4192. replaceE: 'css;.previous-next-links, #leftcolumn',
  4193. forceHTTPS: true,
  4194. scrollD: 1000
  4195. },
  4196. function: {
  4197. aF: function() { // 左侧栏高亮当前页面标题
  4198. let title = document.title.split(' | '); if (title.length > 1) {title = title[0]; getAllCSS('#leftcolumn > a').forEach(function(e){if (e.innerText === title) {e.style = 'background-color: rgb(150, 185, 125); font-weight: bold; color: rgb(255, 255, 255);';}})}
  4199. }
  4200. }
  4201. }, // 菜鸟教程
  4202. cnblogs: {
  4203. host: ['www.cnblogs.com', 'zzk.cnblogs.com'],
  4204. functionS: function() {
  4205. if (location.hostname === 'zzk.cnblogs.com') {
  4206. curSite = DBSite.cnblogs_search;
  4207. } else if (getCSS('#post_list')) {
  4208. curSite = DBSite.cnblogs_list;
  4209. } else if (location.pathname.split('/').length === 3 && getCSS('.topicListFooter')) {
  4210. curSite = DBSite.cnblogs;
  4211. if (!getCSS('#homepage_top_pager')) {
  4212. getCSS('.forFlow').insertAdjacentHTML(getAddTo(2), '<div id="homepage_top_pager" class="topicListFooter"></div>');
  4213. getCSS('.forFlow').insertAdjacentHTML(getAddTo(3), '<div id="homepage_bottom_pager" class="topicListFooter"></div>');
  4214. }
  4215. }
  4216. },
  4217. pager: {
  4218. type: 1,
  4219. nextL: '//div[@class="topicListFooter"]//a[contains(text(), "下一页")]',
  4220. pageE: 'css;div.day',
  4221. replaceE: 'css;.topicListFooter',
  4222. scrollD: 1000
  4223. }
  4224. }, // 博客园 - 文章列表(个人)
  4225. cnblogs_list: {
  4226. pager: {
  4227. type: 1,
  4228. nextL: '//div[@class="pager"]//a[contains(text(), ">")]',
  4229. pageE: 'css;#post_list > article',
  4230. replaceE: 'css;.pager',
  4231. scrollD: 1000
  4232. }
  4233. }, // 博客园 - 文章列表
  4234. cnblogs_search: {
  4235. pager: {
  4236. type: 1,
  4237. nextL: '//div[@class="pager"]//a[contains(text(), ">")]',
  4238. pageE: 'css;div.searchItem',
  4239. replaceE: 'css;.pager',
  4240. scrollD: 1000
  4241. }
  4242. }, // 博客园 - 搜索页
  4243. gitee: {
  4244. host: 'gitee.com',
  4245. functionS: function() {
  4246. if (indexOF('/explore/')) {
  4247. curSite = DBSite.gitee;
  4248. } else if (indexOF(/\/issues$/)) {
  4249. curSite = DBSite.gitee_issues;
  4250. } else if (indexOF(/\/releases/)) {
  4251. curSite = DBSite.gitee_releases;
  4252. } else if (indexOF(/\/tags/)) {
  4253. curSite = DBSite.gitee_tags;
  4254. }
  4255. if (curSite.SiteTypeID > 0 && !curSite.pager.nextL) {
  4256. curSite.pager.type = 1;
  4257. curSite.pager.nextL = 'css;a[rel="next"]';
  4258. curSite.pager.replaceE = 'css;.pagination';
  4259. curSite.pager.scrollD = 2500;
  4260. }
  4261. },
  4262. pager: {
  4263. pageE: 'css;.items > .item',
  4264. }
  4265. }, // Gitee - Explore 列表
  4266. gitee_issues: {
  4267. pager: {
  4268. pageE: 'css;.issue-wrapper',
  4269. }
  4270. }, // Gitee - Issues 列表
  4271. gitee_releases: {
  4272. pager: {
  4273. pageE: 'css;.release-tag-item',
  4274. }
  4275. }, // Gitee - Releases 列表
  4276. gitee_tags: {
  4277. pager: {
  4278. pageE: 'css;.tag-item',
  4279. }
  4280. }, // Gitee - Tags 列表
  4281. gitee_search: {
  4282. host: 'search.gitee.com',
  4283. functionS: function() {if (location.search) curSite = DBSite.gitee_search;},
  4284. pager: {
  4285. type: 1,
  4286. nextL: 'css;li.next:not(.disabled) > a',
  4287. pageE: 'css;#hits-list > div',
  4288. replaceE: 'css;ul.pagination',
  4289. scrollD: 1000
  4290. }
  4291. }, // Gitee - Search 列表
  4292. github: {
  4293. host: ['github.com', 'hub.fastgit.org'],
  4294. functionS: function() {locationC = true;
  4295. if (lp == '/') {
  4296. curSite = DBSite.github;
  4297. } else if (indexOF('tab=stars', 's')) {
  4298. curSite = DBSite.github_star;
  4299. } else if (indexOF('tab=repositories', 's')) {
  4300. curSite = DBSite.github_repositories;
  4301. } else if (indexOF(/\/issues$/) || indexOF(/\/pulls$/)) {
  4302. curSite = DBSite.github_issues;
  4303. } else if (indexOF(/\/discussions$/) || indexOF('/discussions/categories')) {
  4304. curSite = DBSite.github_discussions;
  4305. } else if (indexOF(/\/releases$/)) {
  4306. curSite = DBSite.github_releases;
  4307. } else if (indexOF(/\/tags$/)) {
  4308. curSite = DBSite.github_tags;
  4309. } else if (indexOF('/commits')) {
  4310. curSite = DBSite.github_commits;
  4311. } else if (indexOF('/notifications')) {
  4312. curSite = DBSite.github_notifications;
  4313. } else if (indexOF('/search')) {
  4314. if (!location.search) return
  4315. if (!indexOF('type=', 's')) {
  4316. if (lp == '/search') {
  4317. curSite = DBSite.github_search_repositories;
  4318. } else {
  4319. curSite = DBSite.github_search_code;
  4320. }
  4321. } else {
  4322. curSite = DBSite['github_search_' + /type=[a-z]+/.exec(location.search.toLowerCase())[0].replace('type=','')];
  4323. }
  4324. if (curSite.SiteTypeID > 0 && !curSite.pager.nextL) {
  4325. curSite.pager.type = 1;
  4326. curSite.pager.nextL = 'css;a.next_page';
  4327. curSite.pager.replaceE = 'css;.pagination';
  4328. curSite.pager.scrollD = 3000;
  4329. }
  4330. }},
  4331. pager: {
  4332. type: 2,
  4333. nextL: 'css;.ajax-pagination-btn',
  4334. nextText: 'More',
  4335. scrollD: 2500
  4336. }
  4337. }, // Github - 首页
  4338. github_star: {
  4339. pager: {
  4340. type: 1,
  4341. nextL: '//div[@class="paginate-container"]//a[contains(text(), "Next")]',
  4342. pageE: 'css;#js-pjax-container .position-relative div[class^="col-lg-"] > div:not(.position-relative):not(.paginate-container)',
  4343. insertP: ['css;.paginate-container', 1],
  4344. replaceE: 'css;.paginate-container',
  4345. scrollD: 3000
  4346. }
  4347. }, // Github - 用户 Star 列表
  4348. github_repositories: {
  4349. pager: {
  4350. type: 1,
  4351. nextL: '//div[@class="paginate-container"]//a[contains(text(), "Next")]',
  4352. pageE: 'css;#user-repositories-list > ul > li',
  4353. replaceE: 'css;.paginate-container',
  4354. scrollD: 3000
  4355. }
  4356. }, // Github - 用户 项目 列表
  4357. github_issues: {
  4358. pager: {
  4359. type: 1,
  4360. nextL: 'css;a.next_page',
  4361. pageE: 'css;.js-navigation-container.js-active-navigation-container > div[id^="issue_"]',
  4362. replaceE: 'css;.pagination',
  4363. scrollD: 3000
  4364. }
  4365. }, // Github - Issues 列表 / PR 列表
  4366. github_discussions: {
  4367. pager: {
  4368. type: 1,
  4369. nextL: 'css;a.next_page',
  4370. pageE: 'css;#repo-content-pjax-container div[data-discussion-hovercards-enabled] > div',
  4371. replaceE: 'css;.pagination',
  4372. scrollD: 3000
  4373. }
  4374. }, // Github - Discussions 列表
  4375. github_releases: {
  4376. pager: {
  4377. type: 1,
  4378. nextL: 'css;a.next_page',
  4379. pageE: 'css;#repo-content-pjax-container > div[data-pjax] > div:not(.paginate-container)',
  4380. replaceE: 'css;.pagination',
  4381. scrollD: 3000
  4382. }
  4383. }, // Github - Releases 列表
  4384. github_tags: {
  4385. pager: {
  4386. type: 1,
  4387. nextL: '//div[@class="pagination"]/a[contains(text(), "Next")]',
  4388. pageE: 'css;.Box-body > div.Box-row',
  4389. replaceE: 'css;.pagination',
  4390. scrollD: 3000
  4391. }
  4392. }, // Github - Tags 列表
  4393. github_commits: {
  4394. pager: {
  4395. type: 1,
  4396. nextL: '//div[@class="paginate-container"]//a[contains(text(), "Older")]',
  4397. pageE: 'css;div.js-navigation-container > div',
  4398. replaceE: 'css;.paginate-container',
  4399. scrollD: 3000
  4400. }
  4401. }, // Github - Commits 列表
  4402. github_notifications: {
  4403. pager: {
  4404. type: 1,
  4405. nextL: 'css;nav.paginate-container > a[aria-label="Next"]',
  4406. pageE: 'css;li.notifications-list-item',
  4407. replaceE: 'css;nav.paginate-container, .js-notifications-list-paginator-counts',
  4408. scrollD: 3000
  4409. }
  4410. }, // Github - Notifications 列表
  4411. github_search_repositories: {
  4412. pager: {
  4413. pageE: 'css;ul.repo-list > li',
  4414. }
  4415. }, //Github - Search 列表
  4416. github_search_code: {
  4417. pager: {
  4418. pageE: 'css;.code-list-item',
  4419. }
  4420. }, // Github - Search 列表 - Code
  4421. github_search_commits: {
  4422. pager: {
  4423. pageE: 'css;#commit_search_results > div',
  4424. }
  4425. }, // Github - Search 列表 - Commit
  4426. github_search_issues: {
  4427. pager: {
  4428. pageE: 'css;.issue-list-item',
  4429. }
  4430. }, // Github - Search 列表 - Issues
  4431. github_search_discussions: {
  4432. pager: {
  4433. pageE: 'css;.discussion-list-item',
  4434. }
  4435. }, // Github - Search 列表 - Discussions
  4436. github_search_registrypackages: {
  4437. pager: {
  4438. pageE: 'css;#package_search_results > div',
  4439. }
  4440. }, // Github - Search 列表 - Package
  4441. github_search_marketplace: {
  4442. pager: {
  4443. pageE: 'css;#marketplace_search_results > div:first-child > div',
  4444. }
  4445. }, // Github - Search 列表 - Marketplace
  4446. github_search_topics: {
  4447. pager: {
  4448. pageE: 'css;.topic-list-item',
  4449. }
  4450. }, // Github - Search 列表 - Topics
  4451. github_search_wikis: {
  4452. pager: {
  4453. pageE: 'css;#wiki_search_results > div:first-child > div',
  4454. }
  4455. }, // Github - Search 列表 - wiki
  4456. github_search_users: {
  4457. pager: {
  4458. pageE: 'css;#user_search_results > div:first-child > div',
  4459. }
  4460. }, // Github - Search 列表 - user
  4461. oi_wiki: {
  4462. host: 'oi-wiki.org',
  4463. insStyle: 'blockquote.page-copyright, h2#__comments, form#gitalk-form {display: none !important;} article.md-content__inner{min-height: 700px;}',
  4464. history: true,
  4465. pager: {
  4466. type: 1,
  4467. nextL: 'css;li.md-nav__item.md-nav__item--active.md-nav__item--nested li.md-nav__item--active+li a',
  4468. pageE: 'css;article.md-content__inner',
  4469. insertP: ['css;article.md-content__inner', 6],
  4470. replaceE: 'css;.md-sidebar.md-sidebar--primary',
  4471. scrollD: 1300
  4472. }
  4473. }, // OI Wiki
  4474. guokr: {
  4475. host: 'www.guokr.com',
  4476. pager: {
  4477. type: 2,
  4478. nextL: 'css;div[class*="LoadMoreWrap"]',
  4479. interval: 1500,
  4480. scrollD: 1500
  4481. }
  4482. }, // 果壳网
  4483. expreview: {
  4484. host: 'www.expreview.com',
  4485. pager: {
  4486. type: 2,
  4487. nextL: 'css;#show_article_red_1SHOW',
  4488. interval: 1500,
  4489. scrollD: 1500
  4490. }
  4491. }, // 超能网
  4492. landian: {
  4493. host: 'www.landian.vip',
  4494. pager: {
  4495. type: 2,
  4496. nextL: 'css;.load-more > button',
  4497. nextText: '加载更多',
  4498. scrollD: 1300
  4499. }
  4500. }, // 蓝点网
  4501. ithome: {
  4502. host: 'www.ithome.com',
  4503. pager: {
  4504. type: 2,
  4505. nextL: 'css;a.more',
  4506. interval: 1500,
  4507. scrollD: 1500
  4508. }
  4509. }, // IT之家
  4510. _36kr: {
  4511. host: ['36kr.com', 'www.36kr.com'],
  4512. functionS: function() {if (lp != '/' && !indexOF('/p/') && !indexOF('/newsflashes/')) {curSite = DBSite._36kr;}},
  4513. pager: {
  4514. type: 2,
  4515. nextL: 'css;.kr-loading-more-button.show',
  4516. nextText: '查看更多',
  4517. scrollD: 1500
  4518. }
  4519. }, // 36氪
  4520. _36kr_m: {
  4521. host: 'm.36kr.com',
  4522. pager: {
  4523. type: 2,
  4524. nextL: 'css;.kr-loading-more-button-default',
  4525. nextText: '查看更多',
  4526. scrollD: 1500
  4527. }
  4528. }, // 36氪 - 手机版
  4529. zhutix: {
  4530. host: 'zhutix.com',
  4531. functionS: function() {if (getCSS('#post-list')) {
  4532. curSite = DBSite.zhutix;
  4533. } else {
  4534. curSite = DBSite.zhutix_list;
  4535. }},
  4536. pager: {
  4537. type: 1,
  4538. nextL: '//li[@class="next-page"]/a | //div[@class="btn-pager"]/a[contains(text(), "❯")]',
  4539. pageE: 'css;#post-list > ul > li',
  4540. replaceE: 'css;.pagination, .b2-pagenav.post-nav',
  4541. scrollD: 1500
  4542. }
  4543. }, // 致美化
  4544. zhutix_list: {
  4545. pager: {
  4546. type: 1,
  4547. nextL: 'css;li.next-page a',
  4548. pageE: 'css;#primary-home > div:not(.pagination)',
  4549. replaceE: 'css;.pagination',
  4550. scrollD: 1500
  4551. }
  4552. }, // 致美化 - 文章列表
  4553. lanzou: {
  4554. host: /\.lanzou[a-z]\./,
  4555. hiddenPN: true,
  4556. pager: {
  4557. type: 2,
  4558. nextL: 'css;#filemore',
  4559. nextTextOf: '更多',
  4560. isHidden: true,
  4561. scrollD: 800
  4562. }
  4563. }, // 蓝奏云 - 分享链接列表
  4564. lanzou_: {
  4565. host: 'pc.woozooo.com',
  4566. iframe: true,
  4567. hiddenPN: true,
  4568. pager: {
  4569. type: 2,
  4570. nextL: 'css;#filemore > span[onclick]',
  4571. nextText: '显示更多文件',
  4572. isHidden: true,
  4573. scrollD: 800
  4574. }
  4575. }, // 蓝奏云 - 后台
  4576. wikihow: {
  4577. host: ['www.wikihow.com', 'zh.wikihow.com'],
  4578. functionS: function() {if (indexOF('/Category:')) {
  4579. curSite = DBSite.wikihow;
  4580. } else if (indexOF('/wikiHowTo') && indexOF('?search=', 's')) {
  4581. curSite = DBSite.wikihow_search;
  4582. }},
  4583. pager: {
  4584. type: 1,
  4585. nextL: 'css;a.pag_next',
  4586. pageE: 'css;#cat_all > .cat_grid > div',
  4587. replaceE: 'css;#large_pagination',
  4588. scriptT: 3,
  4589. scrollD: 2000
  4590. }
  4591. }, // 指南
  4592. wikihow_search: {
  4593. pager: {
  4594. type: 1,
  4595. nextL: 'css;#searchresults_footer > a.buttonright',
  4596. pageE: 'css;#searchresults_list > a',
  4597. replaceE: 'css;#searchresults_footer',
  4598. scrollD: 3000
  4599. }
  4600. }, // 指南 - 搜索页
  4601. afreecatv: {
  4602. host: 'www.afreecatv.com',
  4603. pager: {
  4604. type: 2,
  4605. nextL: 'css;.btn-more > button',
  4606. interval: 2000,
  4607. scrollD: 1000
  4608. }
  4609. }, // 直播
  4610. greasyfork: {
  4611. host: 'greasyfork.org',
  4612. functionS: function() {if (indexOF(/\/scripts$/) || indexOF('/scripts/by-site/')) {
  4613. curSite = DBSite.greasyfork;
  4614. } else if (indexOF(/\/feedback$/)) {
  4615. curSite = DBSite.greasyfork_feedback;
  4616. } else if (indexOF('/discussions') && !indexOF(/\/\d+/)) {
  4617. curSite = DBSite.greasyfork_discussions;
  4618. }},
  4619. pager: {
  4620. type: 1,
  4621. nextL: 'css;a.next_page',
  4622. pageE: 'css;ol#browse-script-list > li',
  4623. replaceE: 'css;.pagination',
  4624. scrollD: 1300
  4625. }
  4626. }, // 脚本
  4627. greasyfork_feedback: {
  4628. pager: {
  4629. type: 1,
  4630. nextL: 'css;a.next_page',
  4631. pageE: 'css;.script-discussion-list > div',
  4632. replaceE: 'css;.pagination',
  4633. scrollD: 1800
  4634. }
  4635. }, // 脚本 - 反馈页
  4636. greasyfork_discussions: {
  4637. pager: {
  4638. type: 1,
  4639. nextL: 'css;a.next_page',
  4640. pageE: 'css;.discussion-list > div',
  4641. replaceE: 'css;.pagination',
  4642. scrollD: 1300
  4643. }
  4644. }, // 脚本 - 讨论页
  4645. smzdm: {
  4646. host: ['www.smzdm.com', 'search.smzdm.com'],
  4647. functionS: function() {if (location.hostname === 'search.smzdm.com' || indexOF('/fenlei/')) {
  4648. curSite = DBSite.smzdm;
  4649. }},
  4650. pager: {
  4651. type: 1,
  4652. nextL: '//ul[@class="pagenation-list"]//a[contains(text() ,"下一页")] | //ul[@class="pagenation-list"]/li[contains(@class, "next-page")]/a',
  4653. pageE: 'css;#feed-main-list > li',
  4654. replaceE: 'css;ul.pagenation-list',
  4655. scrollD: 1500
  4656. }
  4657. }, // 什么值得买 - 分类/搜索页
  4658. meidebi: {
  4659. host: 'www.meidebi.com',
  4660. functionS: function() {if (indexOF('/fenlei/') || lp == '/Search') {
  4661. curSite = DBSite.meidebi;
  4662. }},
  4663. pager: {
  4664. type: 1,
  4665. nextL: 'css;a.next',
  4666. pageE: 'css;.share-list > ul > li',
  4667. replaceE: 'css;.h-pages',
  4668. scrollD: 1500
  4669. }
  4670. }, // 没得比 - 分类/搜索页
  4671. ruyile_xuexiao: {
  4672. host: 'www.ruyile.com',
  4673. functionS: function() {
  4674. if (lp == '/xuexiao/') {
  4675. curSite = DBSite.ruyile_xuexiao;
  4676. } else if (lp == '/data/') {
  4677. curSite = DBSite.ruyile_data;
  4678. } else if (lp == '/shijuan/') {
  4679. curSite = DBSite.ruyile_shijuan;
  4680. }},
  4681. pager: {
  4682. type: 1,
  4683. nextL: '//div[@class="fy"]/a[contains(text(), "下一页")]',
  4684. pageE: 'css;.xxlb > .sk',
  4685. insertP: ['css;.xxlb', 3],
  4686. replaceE: 'css;.fy',
  4687. scrollD: 1000
  4688. }
  4689. }, // 如意了教育 - 学校
  4690. ruyile_data: {
  4691. pager: {
  4692. type: 1,
  4693. nextL: '//div[@class="fy"]/a[contains(text(), "下一页")]',
  4694. pageE: 'css;.m1_z > .lbk',
  4695. insertP: ['css;.page', 1],
  4696. replaceE: 'css;.fy',
  4697. scrollD: 1000
  4698. }
  4699. }, // 如意了教育 - 数据
  4700. ruyile_shijuan: {
  4701. pager: {
  4702. type: 1,
  4703. nextL: '//div[@class="fy"]/a[contains(text(), "下一页")]',
  4704. pageE: 'css;.m1_z > .m2_lb',
  4705. insertP: ['css;.page', 1],
  4706. replaceE: 'css;.fy',
  4707. scrollD: 1000
  4708. }
  4709. }, // 如意了教育 - 试卷
  4710. che168: {
  4711. host: 'www.che168.com',
  4712. functionS: function() {
  4713. if (location.pathname != '/' && !indexOF('/dealer/')) {
  4714. curSite = DBSite.che168;
  4715. }},
  4716. pager: {
  4717. type: 1,
  4718. nextL: 'css;a.page-item-next',
  4719. pageE: 'css;ul.viewlist_ul > li',
  4720. replaceE: 'css;.page',
  4721. scrollD: 2000
  4722. }
  4723. }, // 二手车之家
  4724. jiligamefun: {
  4725. host: 'www.jiligamefun.com',
  4726. functionS: function() {if (indexOF('/category/')) {curSite = DBSite.jiligamefun;}},
  4727. pager: {
  4728. type: 1,
  4729. nextL: 'css;a.poi-pager__item.poi-pager__item_next',
  4730. pageE: 'css;.inn-archive__container > article',
  4731. replaceE: 'css;.poi-pager',
  4732. scrollD: 1800
  4733. }
  4734. }, // 叽哩叽哩日报
  4735. wendangku: {
  4736. host: 'www.wendangku.net',
  4737. functionS: function() {if (indexOF('/doc/')) {curSite = DBSite.wendangku;}},
  4738. pager: {
  4739. type: 1,
  4740. nextL: 'css;a.next',
  4741. pageE: 'css;#contents > *:not(.pages)',
  4742. replaceE: 'css;.pages',
  4743. scrollD: 1800
  4744. }
  4745. }, // 文档库
  4746. getquicker: {
  4747. host: 'getquicker.net',
  4748. functionS: function() {if (indexOF('/Share/')) {curSite = DBSite.getquicker;}},
  4749. pager: {
  4750. type: 1,
  4751. nextL: '//a[@class="page-link" and text()="下一页"]',
  4752. pageE: 'css;table.table > tbody > tr:not(:first-child), script[src^="/js/site.js"]',
  4753. insertP: ['css;table.table > tbody', 3],
  4754. replaceE: 'css;ul.pagination',
  4755. scriptT: 2,
  4756. scrollD: 1000
  4757. }
  4758. }, // Quicker
  4759. netbian: {
  4760. host: 'pic.netbian.com',
  4761. insStyle: 'li.nextpage {display: none !important;}',
  4762. pager: {
  4763. type: 1,
  4764. nextL: '//div[@class="page"]/a[contains(text(),"下一页")]',
  4765. pageE: 'css;.slist ul > li:not(.nextpage)',
  4766. replaceE: 'css;.page',
  4767. scrollD: 1000
  4768. }
  4769. }, // 彼岸图网
  4770. ioliu: {
  4771. host: 'bing.ioliu.cn',
  4772. functionS: function() {if (!indexOF('/photo/') && !indexOF('.html')) {curSite = DBSite.ioliu; document.head.appendChild(document.createElement('base')).target = '_blank';}},
  4773. insStyle: '.progressive--not-loaded {filter: none !important;}',
  4774. pager: {
  4775. type: 1,
  4776. nextL: '//div[@class="page"]/a[contains(text(), "下一页")]',
  4777. pageE: 'css;body > .container > div.item',
  4778. replaceE: 'css;.page',
  4779. scrollD: 1000
  4780. }
  4781. }, // 必应壁纸
  4782. konachan: {
  4783. host: 'konachan.net',
  4784. functionS: function() {if (indexOF('/post')) {curSite = DBSite.konachan; document.head.appendChild(document.createElement('base')).target = '_blank';}},
  4785. insStyle: '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;}',
  4786. history: true,
  4787. pager: {
  4788. type: 1,
  4789. nextL: 'css;a.next_page',
  4790. pageE: 'css;ul#post-list-posts > li',
  4791. replaceE: 'css;#paginator',
  4792. scrollD: 1000
  4793. }
  4794. }, // 动漫壁纸
  4795. nastol: {
  4796. host: 'www.nastol.com.ua',
  4797. pager: {
  4798. type: 1,
  4799. nextL: '//a[./span[@class="nav-next"]]',
  4800. pageE: 'css;#dle-content > div',
  4801. replaceE: 'css;.navigation',
  4802. scrollD: 1000
  4803. }
  4804. }, // 壁纸
  4805. hdqwalls: {
  4806. host: 'hdqwalls.com',
  4807. pager: {
  4808. type: 1,
  4809. nextL: 'css;a#next',
  4810. pageE: 'css;.wallpapers_container > div.wall-resp',
  4811. replaceE: 'css;ul.pagination',
  4812. scrollD: 1000
  4813. }
  4814. }, // 壁纸
  4815. xinpianchang: {
  4816. host: 'www.xinpianchang.com',
  4817. insStyle: '.lazy-img {opacity: 1 !important;}',
  4818. pager: {
  4819. type: 1,
  4820. nextL: 'css;.page > a[title="下一页"]',
  4821. pageE: 'css;div[class*="-container"] div[class*="-con"] > ul > li, div[class*="-container"] div[class*="-con"] > div[class*="-wrap"] > ul > li',
  4822. insertP: ['css;div[class*="-container"] div[class*="-con"] > ul, div[class*="-container"] div[class*="-con"] > div[class*="-wrap"] > ul', 3],
  4823. replaceE: 'css;.page',
  4824. scrollD: 2000
  4825. },
  4826. function: {
  4827. bF: src_bF,
  4828. pF: [0, 'img[_src]', '_src']
  4829. }
  4830. }, // 新片场
  4831. tujigu: {
  4832. host: 'www.tujigu.net',
  4833. functionS: function() {
  4834. if (indexOF('/a/')) {
  4835. curSite = DBSite.tujigu;
  4836. } else if (location.pathname != '/' && !indexOF('/search/')) {
  4837. curSite = DBSite.tujigu_list;
  4838. }},
  4839. insStyle: '.content img {display: block !important;}',
  4840. pager: {
  4841. type: 1,
  4842. nextL: 'id("pages")/a[contains(text(), "下一页")]',
  4843. pageE: 'css;.content > img',
  4844. replaceE: 'css;#pages',
  4845. scrollD: 2000
  4846. },
  4847. function: {
  4848. bF: src_bF,
  4849. pF: [0, 'img[original]', 'original']
  4850. }
  4851. }, // 图集谷 - 图片页
  4852. tujigu_list: {
  4853. pager: {
  4854. type: 1,
  4855. nextL: 'id("pages")/a[contains(text(), "下一页")]',
  4856. pageE: 'css;.hezi > ul > li',
  4857. insertP: ['//div[@class="hezi"][last()]/ul', 3],
  4858. replaceE: 'css;#pages',
  4859. scrollD: 1000
  4860. }
  4861. }, // 图集谷 - 分类页
  4862. mvtui: {
  4863. host: 'mvtui.com',
  4864. functionS: function() {if (indexOF('.html')) {curSite = DBSite.mvtui;} else {curSite = DBSite.mvtui_list;}},
  4865. pager: {
  4866. type: 1,
  4867. nextL: 'css;.article-paging span.current+a',
  4868. pageE: 'css;.article-content > p',
  4869. replaceE: 'css;.article-paging',
  4870. scrollD: 3000
  4871. }
  4872. }, // 美女推 - 图片页
  4873. mvtui_list: {
  4874. pager: {
  4875. type: 1,
  4876. nextL: 'css;li.next-page a',
  4877. pageE: 'css;#posts > div',
  4878. replaceE: 'css;.pagination',
  4879. scrollD: 1500
  4880. },
  4881. function: {
  4882. bF: src_bF,
  4883. pF: [0, 'img[data-src]', 'data-src']
  4884. }
  4885. }, // 美女推 - 分类页
  4886. mzitu: {
  4887. host: 'www.mzitu.com',
  4888. functionS: function() {if (indexOF(/\/\d+/)) {curSite = DBSite.mzitu;getCSS('.main-image a[href]').href = 'javascript:void(0);'} else {curSite = DBSite.mzitu_list;}},
  4889. pager: {
  4890. type: 1,
  4891. nextL: '//div[@class="pagenavi"]/a[contains(string(), "下一页")]',
  4892. pageE: 'css;.main-image img',
  4893. replaceE: 'css;.pagenavi',
  4894. scrollD: 1500
  4895. }
  4896. }, // 妹子图 - 图片页
  4897. mzitu_list: {
  4898. pager: {
  4899. type: 1,
  4900. nextL: 'css;.next.page-numbers',
  4901. pageE: 'css;.postlist > ul > li',
  4902. replaceE: 'css;.pagination',
  4903. scrollD: 1000
  4904. },
  4905. function: {
  4906. bF: src_bF,
  4907. pF: [0, 'img[data-original]', 'data-original']
  4908. }
  4909. }, // 妹子图 - 分类/搜索页
  4910. xiurenji: {
  4911. host: /\.xiurenji\./,
  4912. functionS: function() {insStyle('img[src$=".gif"]:not([src*="logo"]) {display: none !important;}');
  4913. if (indexOF('.html') && !indexOF('/index')) {
  4914. curSite = DBSite.xiurenji;
  4915. } else if (indexOF('search')) {
  4916. curSite = DBSite.xiurenji_search;
  4917. } else {
  4918. curSite = DBSite.xiurenji_list;
  4919. }},
  4920. pager: {
  4921. type: 1,
  4922. nextL: '//div[@class="page"]/a[contains(text(), "后")]',
  4923. pageE: 'css;div.img > p > *',
  4924. replaceE: 'css;.page',
  4925. scrollD: 2000
  4926. }
  4927. }, // 秀人集 - 图片页
  4928. xiurenji_list: {
  4929. pager: {
  4930. type: 1,
  4931. nextL: '//div[@class="page"]/a[contains(text(), "下页")]',
  4932. pageE: 'css;td >.tp2 > *',
  4933. replaceE: 'css;.page',
  4934. scrollD: 1000
  4935. }
  4936. }, // 秀人集 - 分类页
  4937. xiurenji_search: {
  4938. pager: {
  4939. type: 1,
  4940. nextL: 'css;.page > a.current+a',
  4941. pageE: 'css;.node > *',
  4942. replaceE: 'css;.page',
  4943. scrollD: 1000
  4944. }
  4945. }, // 秀人集 - 搜索页
  4946. mm131: {
  4947. host: ['www.mm131.net', 'www.mmm131.com'],
  4948. functionS: function() {if (indexOF('.html')) {curSite = DBSite.mm131;} else {curSite = DBSite.mm131_list;}},
  4949. history: true,
  4950. retry: 300,
  4951. pager: {
  4952. type: 1,
  4953. nextL: '//div[@class="content-page"]/a[contains(text(), "下一页")]',
  4954. pageE: 'css;.content-pic img',
  4955. replaceE: 'css;.content-page',
  4956. scrollD: 2000
  4957. }
  4958. }, // MM131 - 图片页
  4959. mm131_list: {
  4960. pager: {
  4961. type: 1,
  4962. nextL: '//dd[@class="page"]/a[contains(text(), "下一页")]',
  4963. pageE: 'css;dl.list-left > dd:not([class="page"])',
  4964. replaceE: 'css;.page',
  4965. scrollD: 1000
  4966. }
  4967. }, // MM131 - 分类页
  4968. mm131_m: {
  4969. host: 'm.mmm131.com',
  4970. 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;}},
  4971. history: true,
  4972. retry: true,
  4973. pager: {
  4974. type: 1,
  4975. nextL: '//div[@class="paging"]/a[text()="下一张" or text()="下一页"]',
  4976. pageE: 'css;.post-content img',
  4977. replaceE: 'css;.paging',
  4978. scrollD: 2000
  4979. }
  4980. }, // MM131 - 手机版 - 图片页
  4981. mm131_m_list: {
  4982. pager: {
  4983. type: 1,
  4984. nextL: 'css;#xbtn',
  4985. pageE: 'css;#content > article',
  4986. replaceE: 'css;#webpage',
  4987. scrollD: 2000
  4988. },
  4989. function: {
  4990. bF: src_bF,
  4991. pF: [0, 'img[data-img]', 'data-img']
  4992. }
  4993. }, // MM131 - 手机版 - 分类页
  4994. mm131_m_: {
  4995. pager: {
  4996. type: 2,
  4997. nextL: 'css;#webpage>span[onclick]',
  4998. isHidden: true,
  4999. interval: 500,
  5000. scrollD: 2000
  5001. }
  5002. }, // MM131 - 手机版 - 首页
  5003. mrcong: {
  5004. host: 'mrcong.com',
  5005. functionS: function() {if (lp == '/' || indexOF('/tag/')) {curSite = DBSite.mrcong_list;} else {curSite = DBSite.mrcong;}},
  5006. pager: {
  5007. type: 1,
  5008. nextL: 'css;.post-page-numbers.current+a.post-page-numbers',
  5009. pageE: 'css;#fukie2 > p > img',
  5010. replaceE: 'css;.page-link',
  5011. scrollD: 3000
  5012. }
  5013. }, // MrCong - 图片页
  5014. mrcong_list: {
  5015. pager: {
  5016. type: 3,
  5017. nextL: 'css;.current+a.page',
  5018. pageE: 'css;article.item-list',
  5019. scrollE: 'css;.pagination',
  5020. replaceE: 'css;.pagination',
  5021. scrollD: 2000
  5022. }
  5023. }, // MrCong - 分类页
  5024. buondua: {
  5025. host: 'buondua.com',
  5026. functionS: function() {if (indexOF(/-photos-\d+/)) {curSite = DBSite.buondua;} else {curSite = DBSite.buondua_list;}},
  5027. pager: {
  5028. type: 3,
  5029. nextL: '//nav[@class="pagination"]//span[./a[contains(@class, "is-current")]]/following-sibling::span[1]/a',
  5030. pageE: 'css;.article-fulltext > p',
  5031. scrollE: 'css;nav.pagination',
  5032. replaceE: 'css;nav.pagination',
  5033. scrollD: 1500
  5034. },
  5035. function: {
  5036. bF: src_bF,
  5037. pF: [0, 'img[data-src]', 'data-src']
  5038. }
  5039. }, // Buon Dua - 图片页
  5040. buondua_list: {
  5041. pager: {
  5042. type: 3,
  5043. nextL: 'css;.pagination-next',
  5044. pageE: 'css;.items-row.column, .collection-item.column',
  5045. scrollE: 'css;nav.pagination',
  5046. replaceE: 'css;nav.pagination',
  5047. scrollD: 1200
  5048. },
  5049. function: {
  5050. bF: src_bF,
  5051. pF: [0, 'img[data-src]', 'data-src']
  5052. }
  5053. }, // Buon Dua - 分类页
  5054. fnvshen: {
  5055. host: 'www.fnvshen.com',
  5056. functionS: function() {
  5057. if (indexOF('/gallery/') || indexOF('/tag/')) {
  5058. curSite = DBSite.fnvshen_list;
  5059. } else if (indexOF('/g/')) {
  5060. curSite = DBSite.fnvshen;
  5061. } else if (indexOF(/\/article\/\d+\//)) {
  5062. curSite = DBSite.fnvshen_article;
  5063. } else if (indexOF('/article/')) {
  5064. curSite = DBSite.fnvshen_article_list;
  5065. }},
  5066. pager: {
  5067. type: 1,
  5068. nextL: 'id("pages")/a[contains(text(), "下一页")]',
  5069. pageE: 'css;#hgallery > img',
  5070. replaceE: 'css;#pages',
  5071. scrollD: 1000
  5072. }
  5073. }, // 宅男女神 - 图片页
  5074. fnvshen_list: {
  5075. insStyle: '.yalayi_box {display: none !important; margin: -4px 0 !important;}',
  5076. pager: {
  5077. type: 1,
  5078. nextL: '//div[@class="pagesYY"]//a[contains(text(), "下一页")]',
  5079. pageE: 'css;#listdiv > ul > li',
  5080. replaceE: 'css;.pagesYY',
  5081. scrollD: 1000
  5082. },
  5083. function: {
  5084. bF: src_bF,
  5085. pF: [0, 'img[data-original]', 'data-original']
  5086. }
  5087. }, // 宅男女神 - 分类页
  5088. fnvshen_article_list: {
  5089. pager: {
  5090. type: 1,
  5091. nextL: '//div[@class="pagesYY"]//a[contains(text(), "下一页")]',
  5092. pageE: 'css;li.other_girlli',
  5093. replaceE: 'css;.pagesYY',
  5094. scrollD: 1000
  5095. }
  5096. }, //宅男女神 - 文章列表
  5097. fnvshen_article: {
  5098. pager: {
  5099. type: 1,
  5100. nextL: 'css;.pagesYY a.cur+a',
  5101. pageE: 'css;#articleDiv',
  5102. insertP: ['css;#articleDiv', 6],
  5103. replaceE: 'css;.pagesYY',
  5104. scrollD: 1000
  5105. }
  5106. }, // 宅男女神 - 文章内
  5107. xrmn5: {
  5108. host: 'www.xrmn5.cc',
  5109. functionS: function() {if (indexOF(/\d+\.html/)) {
  5110. curSite = DBSite.xrmn5;
  5111. } else if (indexOF('/search')) {
  5112. curSite = DBSite.xrmn5_search;
  5113. } else {
  5114. curSite = DBSite.xrmn5_list;
  5115. }},
  5116. pager: {
  5117. type: 1,
  5118. nextL: '//div[contains(@class, "page")]//a[contains(text(), "下页")]',
  5119. pageE: 'css;.content_left > p > img',
  5120. replaceE: 'css;.page',
  5121. scrollD: 3000
  5122. }
  5123. }, // 秀人美女 - 图片页
  5124. xrmn5_list: {
  5125. pager: {
  5126. type: 1,
  5127. nextL: '//div[contains(@class, "page")]//a[contains(text(), "下页")]',
  5128. pageE: 'css;ul.update_area_lists > li',
  5129. replaceE: 'css;.page',
  5130. scrollD: 2000
  5131. }
  5132. }, // 秀人美女 - 分类页
  5133. xrmn5_search: {
  5134. pager: {
  5135. type: 1,
  5136. nextL: 'css;.page a.current+a',
  5137. pageE: 'css;div.sousuo',
  5138. replaceE: 'css;.page',
  5139. scrollD: 2000
  5140. }
  5141. }, // 秀人美女 - 搜索页
  5142. jpmn8: {
  5143. host: 'www.jpmn8.com',
  5144. functionS: function() {if (indexOF(/\/\d+\.html/)) {curSite = DBSite.jpmn8;} else if (location.pathname != '/') {curSite = DBSite.jpmn8_list;}},
  5145. insStyle: 'img[onload] {min-height: 500px;}',
  5146. pager: {
  5147. type: 1,
  5148. nextL: '//div[@class="pagination1"]//a[text()="下一页"]',
  5149. pageE: 'css;img[onload]',
  5150. replaceE: 'css;.pagination1',
  5151. scrollD: 3000
  5152. }
  5153. }, // 精品美女 - 图片页
  5154. jpmn8_list: {
  5155. pager: {
  5156. type: 1,
  5157. nextL: '//div[@class="pagination1"]//a[text()="下一页"]',
  5158. pageE: 'css;article.excerpt',
  5159. replaceE: 'css;.pagination1',
  5160. scrollD: 1500
  5161. }
  5162. }, // 精品美女 - 分类页
  5163. ku137: {
  5164. host: 'www.ku137.net',
  5165. functionS: function() {if (indexOF(/\/\d+\.html/)) {curSite = DBSite.ku137;} else if (location.pathname != '/') {curSite = DBSite.ku137_list;}},
  5166. insStyle: '.Title9, .dibu1, .dibu2 {display: none !important;} .content img {min-height: 500px;}',
  5167. pager: {
  5168. type: 1,
  5169. nextL: '//div[@class="page"]/a[text()="下一页"]',
  5170. pageE: 'css;.content > img',
  5171. replaceE: 'css;.page',
  5172. scrollD: 3000
  5173. }
  5174. }, // 美女写真 - 图片页
  5175. ku137_list: {
  5176. pager: {
  5177. type: 1,
  5178. nextL: '//div[@class="page"]/a[text()="下一页"]',
  5179. pageE: 'css;.m-list > ul > li',
  5180. replaceE: 'css;.page',
  5181. scrollD: 1500
  5182. }
  5183. }, // 美女写真 - 分类页
  5184. ku137_m: {
  5185. host: 'm.ku137.net',
  5186. functionS: function() {if (indexOF(/\/\d+\.html/)) {curSite = DBSite.ku137_m;} else if (location.pathname != '/') {curSite = DBSite.ku137_m_list;}},
  5187. insStyle: '.ArticleImageBox img {min-height: 300px;}',
  5188. pager: {
  5189. type: 1,
  5190. nextL: '//div[@class="article_page"]//a[text()="下一页"]',
  5191. pageE: 'css;.ArticleImageBox > *',
  5192. replaceE: 'css;.article_page',
  5193. scrollD: 3000
  5194. }
  5195. }, // 美女写真 - 手机版 - 图片页
  5196. ku137_m_list: {
  5197. pager: {
  5198. type: 1,
  5199. nextL: '//div[@class="article_page"]//a[text()="下一页"]',
  5200. pageE: 'css;.PictureList > ul > li',
  5201. replaceE: 'css;.article_page',
  5202. scrollD: 1500
  5203. }
  5204. }, // 美女写真 - 手机版 - 分类页
  5205. mnttz: {
  5206. host: 'www.mnttz.com',
  5207. functionS: function() {if (indexOF(/\/\d+\.html/)) {curSite = DBSite.mnttz;} else {curSite = DBSite.mnttz_list;}},
  5208. insStyle: 'img.content_img {min-height: 500px;}',
  5209. pager: {
  5210. type: 1,
  5211. nextL: 'css;.article-paging > span+a',
  5212. pageE: 'css;img.content_img',
  5213. replaceE: 'css;.article-paging',
  5214. scrollD: 3000
  5215. }
  5216. }, // 美女套图 - 图片页
  5217. mnttz_list: {
  5218. pager: {
  5219. type: 1,
  5220. nextL: 'css;li.next-page > a',
  5221. pageE: 'css;article.excerpt',
  5222. replaceE: 'css;.pagination',
  5223. scrollD: 1500
  5224. },
  5225. function: {
  5226. bF: src_bF,
  5227. pF: [0, 'img[data-src]', 'data-src']
  5228. }
  5229. }, // 美女套图 - 分类页
  5230. kingdom: {
  5231. host: ['kingdom-en.com', 'www.kingdom-en.com', 'm.kingdom-en.com'],
  5232. functionS: function() {if (indexOF(/\/\d+\.html/)) {curSite = DBSite.kingdom;} else {curSite = DBSite.kingdom_list;}},
  5233. insStyle: '.pic_center img {min-height: 300px;} .arcmain > .title, .footer, .index-list-title, .listmain_st {display: none !important;}',
  5234. pager: {
  5235. type: 1,
  5236. nextL: '//a[@class="page_next"] | //div[@class="article_page"]//a[text()="下一页"]',
  5237. pageE: 'css;.pic_center img',
  5238. replaceE: '//div[@class="pages2" or @class="article_page"]',
  5239. scrollD: 4000
  5240. }
  5241. }, // King爱模 - 图片页
  5242. kingdom_list: {
  5243. pager: {
  5244. type: 1,
  5245. nextL: () => getCSS('a.page_next').href.replace(/(www.)?ermo.net/, location.hostname).replace(/http(s)?:/, location.protocol),
  5246. pageE: 'css;.channel_list3 > ul > li, ul#container > li',
  5247. replaceE: 'css;.pages, .list_page',
  5248. scrollD: 1000
  5249. }
  5250. }, // King爱模 - 分类页
  5251. cadtutor: {
  5252. host: 'www.cadtutor.net',
  5253. functionS: function() {
  5254. if (indexOF('/forum/forum/')) {
  5255. curSite = DBSite.cadtutor;
  5256. } else if (indexOF('/forum/topic/') && GM_getValue('menu_discuz_thread_page')) {
  5257. curSite = DBSite.cadtutor_post;
  5258. } else if (indexOF('/forum/search/')) {
  5259. curSite = DBSite.cadtutor_search;
  5260. }},
  5261. pager: {
  5262. type: 1,
  5263. nextL: 'css;a[rel="next"]',
  5264. pageE: 'css;ol.ipsDataList > li:not([data-rowid])~li',
  5265. replaceE: 'css;ul.ipsPagination',
  5266. scrollD: 2000
  5267. }
  5268. }, // CADTutor - 列表页
  5269. cadtutor_post: {
  5270. pager: {
  5271. type: 1,
  5272. nextL: 'css;a[rel="next"]',
  5273. pageE: 'css;#elPostFeed > form > *:not(input):not(.after-first-post)',
  5274. replaceE: 'css;ul.ipsPagination',
  5275. scrollD: 2000
  5276. }
  5277. }, // CADTutor - 帖子内
  5278. cadtutor_search: {
  5279. pager: {
  5280. type: 1,
  5281. nextL: 'css;a[rel="next"]',
  5282. pageE: 'css;ol.ipsStream > li',
  5283. replaceE: 'css;ul.ipsPagination',
  5284. scrollD: 2000
  5285. }
  5286. }, // CADTutor - 搜索页
  5287. theswamp: {
  5288. host: 'www.theswamp.org',
  5289. functionS: function() {
  5290. if (!location.search) return
  5291. if (indexOF('board=', 's')) {
  5292. curSite = DBSite.theswamp;
  5293. } else if (indexOF('topic=', 's') && GM_getValue('menu_discuz_thread_page')) {
  5294. curSite = DBSite.theswamp_post;
  5295. }},
  5296. pager: {
  5297. type: 1,
  5298. nextL: 'css;.pagelinks > strong+a',
  5299. pageE: 'css;#messageindex tbody > tr:not([class])',
  5300. replaceE: 'css;.pagelinks',
  5301. scrollD: 2000
  5302. }
  5303. }, // TheSwamp - 列表页
  5304. theswamp_post: {
  5305. pager: {
  5306. type: 1,
  5307. nextL: 'css;.pagelinks > strong+a',
  5308. pageE: 'css;#forumposts form > *',
  5309. replaceE: 'css;.pagelinks',
  5310. scrollD: 2000
  5311. }
  5312. } // TheSwamp - 帖子内
  5313. };
  5314. // 生成 SiteTypeID
  5315. setSiteTypeID();
  5316. // 用于脚本判断(针对部分特殊的网站)
  5317. SiteType = {
  5318. BAIDU_TIEBA: DBSite.baidu_tieba.SiteTypeID
  5319. };
  5320. }
  5321.  
  5322.  
  5323. if (webType != 1) {
  5324. switch (webType) {
  5325. case 2: // < 所有 Discuz!论坛 >
  5326. discuz_(); break;
  5327. case 3: // < 所有 Flarum 论坛 >
  5328. DBSite.flarum.functionS(); break;
  5329. case 4: // < 所有 phpBB 论坛 >
  5330. DBSite.phpbb.functionS(); break;
  5331. case 5: // < 所有 Xiuno 论坛 >
  5332. DBSite.xiuno.functionS(); break;
  5333. case 6: // < 所有 XenForo 论坛 >
  5334. DBSite.xenforo.functionS(); break;
  5335. case 100: // < 所有使用 WordPress DUX 主题的网站 >
  5336. DBSite.dux.functionS(); if (location.hostname === 'apphot.cc') {curSite.pager.scrollD = 2500;}; break;
  5337. case 101: // < 所有使用 WordPress XIU 主题的网站 >
  5338. DBSite.dux.functionS(); curSite.function = {bF: src_bF, pF: [0, 'img.thumb[data-original]', 'data-original']}; break;
  5339. case 102: // < 所有使用 WordPress D8 主题的网站 >
  5340. DBSite.dux.functionS(); delete curSite.function; break;
  5341. case 103: // < 所有使用 WordPress Begin 主题的网站 >
  5342. DBSite.begin.functionS(); break;
  5343. case 200: // < 所有使用 笔趣阁 模板的小说网站 >
  5344. DBSite.biquge.functionS(); break;
  5345. }
  5346. }
  5347.  
  5348. // 显示页码
  5349. if (GM_getValue('menu_page_number')) {pageNumber('add');} else {pageNumber('set');}
  5350. // 左键双击网页空白处暂停翻页
  5351. pausePageEvent();
  5352. // 强制新标签页打开链接(翻页模式 5/6)
  5353. if (curSite.forceTarget) forceTarget();
  5354.  
  5355. // 对于使用 pjax 技术的网站,需要监听 URL 变化来重新判断翻页规则
  5356. if (locationC) {
  5357. nowLocation = location.href
  5358. addLocationchange(); // 自定义 locationChange 事件
  5359. if (webType === 1) {
  5360. window.addEventListener('locationChange', function(){
  5361. lp = location.pathname;
  5362. //console.log(nowLocation, location.href)
  5363. if (curSite.history && window.top.document.xiu_nowUrl === location.href) {nowLocation = location.href; return}
  5364. if (nowLocation == location.href) return
  5365. if (curSite.pager && curSite.pager.type == 5) {
  5366. if (self != top) {window.top.location.href = location.href;} else {if (getCSS('iframe#xiu_iframe')) {getCSS('iframe#xiu_iframe').remove();}}
  5367. pausePage = true;
  5368. } // 对于翻页模式 5,如果是 iframe 框架内 URL 变动,则升级为顶级页面,如果是顶级页面的 URL 变动,则清理 iframe 框架
  5369. nowLocation = location.href; curSite = {SiteTypeID: 0}; pageNum.now = 1; // 重置规则+页码
  5370. registerMenuCommand(); // 重新判断规则
  5371. //console.log(curSite);
  5372. if (curSite.insStyle) {insStyle(curSite.insStyle)} // 插入 Style CSS 样式
  5373. curSite.pageUrl = ''; // 下一页URL
  5374. pageLoading(); // 自动无缝翻页
  5375.  
  5376. if (GM_getValue('menu_page_number')) {pageNumber('add');} else {pageNumber('set');} // 显示页码
  5377. pausePageEvent(); // 左键双击网页空白处暂停翻页
  5378. })
  5379. } else if (webType === 3) {
  5380. window.addEventListener('locationChange', function(){
  5381. lp = location.pathname;
  5382. if (nowLocation == location.href) return
  5383. nowLocation = location.href; curSite = {SiteTypeID: 0}; pageNum.now = 1; // 重置规则+页码
  5384. DBSite.flarum.functionS(); // 重新判断规则
  5385. if (curSite.insStyle) {insStyle(curSite.insStyle)} // 插入 Style CSS 样式
  5386. pageLoading(); // 自动无缝翻页
  5387.  
  5388. if (GM_getValue('menu_page_number')) {pageNumber('add');} else {pageNumber('set');} // 显示页码
  5389. pausePageEvent(); // 左键双击网页空白处暂停翻页
  5390. })
  5391. }
  5392. }
  5393. // 插入 Style CSS 样式
  5394. if (curSite.insStyle) insStyle(curSite.insStyle)
  5395.  
  5396. // 对翻页模式 5 的子 iframe 添加一个跟随滚动的事件
  5397. if (curSite.pager && curSite.pager.type === 5 && self != top) {
  5398. var beforeScrollTop = document.documentElement.scrollTop || document.body.scrollTop
  5399. window.addEventListener('scroll', function (e) {
  5400. let scrollTop = window.parent.document.documentElement.scrollTop || window.parent.document.body.scrollTop,
  5401. clientHeight = window.parent.document.documentElement.clientHeight || window.parent.document.body.clientHeight,
  5402. scrollHeight = window.parent.document.documentElement.scrollHeight || window.parent.document.body.scrollHeight,
  5403. afterScrollTop = document.documentElement.scrollTop || document.body.scrollTop,
  5404. delta = afterScrollTop - beforeScrollTop;
  5405. if (delta == 0) return false;
  5406. beforeScrollTop = afterScrollTop;
  5407. //console.log(delta, scrollHeight - (scrollTop + clientHeight), '2222')
  5408. if (delta > 0 && scrollTop + clientHeight < scrollHeight) {
  5409. window.parent.scrollBy(0, delta*2);
  5410. }
  5411. }, false);
  5412. }
  5413.  
  5414. curSite.pageUrl = ''; // 下一页URL
  5415. //console.log(curSite);
  5416. pageLoading(); // 自动无缝翻页
  5417.  
  5418.  
  5419. // --------------------------------------------------------
  5420.  
  5421.  
  5422. // [Discuz! 论坛] 判断各版块帖子列表类型
  5423. function discuzForum() {
  5424. if (getCSS('#autopbn')) { // 判断是否有 [下一页] 按钮
  5425. curSite = DBSite.discuz_forum;
  5426. } else if (getCSS('#waterfall')) { // 判断是否为图片模式
  5427. if (!getCSS('#pgbtn, .pgbtn')) { // 如果各版块帖子列表已存在这个元素,说明自带了无缝翻页
  5428. curSite = DBSite.discuz_waterfall; waterfallStyle(); // 图片模式列表样式预处理
  5429. }
  5430. } else {
  5431. curSite = DBSite.discuz_guide;
  5432. }
  5433. }
  5434. function discuz_() {
  5435. if (getCSS('body[id="nv_forum"][class^="pg_"][onkeydown*="27"]')) {
  5436. switch (getCSS('body[id="nv_forum"][class^="pg_"][onkeydown*="27"]').className) {
  5437. case 'pg_forumdisplay': // < 各版块帖子列表 >
  5438. discuzForum(); break;
  5439. case 'pg_viewthread': // < 帖子内 >
  5440. if (GM_getValue('menu_discuz_thread_page')) curSite = DBSite.discuz_thread; break;
  5441. case 'pg_guide': // < 导读帖子列表等 >
  5442. curSite = DBSite.discuz_guide; break;
  5443. case 'pg_collection': // < 淘贴列表 >
  5444. curSite = DBSite.discuz_collection; break;
  5445. }
  5446. }
  5447. // 如果上面没有匹配的则继续 < 搜索结果 >
  5448. if (curSite.SiteTypeID === 0) {
  5449. if (indexOF('search') || getCSS('body[id="nv_search"][onkeydown*="27"]')) {
  5450. curSite = DBSite.discuz_search;
  5451. }
  5452. }
  5453. // 如果上面没有匹配的则继续
  5454. if (curSite.SiteTypeID === 0) {
  5455. if (indexOF('.html')) { // 判断是不是静态网页(.html 结尾)
  5456. if (indexOF('/forum-')) { // < 各版块帖子列表 >
  5457. discuzForum();
  5458. } else if (indexOF('/thread-')) { // < 帖子内 >
  5459. if (GM_getValue('menu_discuz_thread_page')) curSite = DBSite.discuz_thread;
  5460. }
  5461. }
  5462. }
  5463. // 如果上面没有匹配的则继续
  5464. if (curSite.SiteTypeID === 0) {
  5465. if (indexOF('mod=forumdisplay', 's') || indexOF('forumdisplay.php')) { // < 各版块帖子列表 >
  5466. discuzForum();
  5467. } else if (indexOF('mod=viewthread', 's') || indexOF('viewthread.php')) { // < 帖子内 >
  5468. if (GM_getValue('menu_discuz_thread_page')) curSite = DBSite.discuz_thread;
  5469. } else if (indexOF('mod=guide', 's')) { // < 导读帖子列表 >
  5470. curSite = DBSite.discuz_guide;
  5471. } else if(indexOF('mod=space', 's') && indexOF('do=thread', 's')) { // 别人的主题/回复
  5472. curSite = DBSite.discuz_youspace;
  5473. } else if (indexOF('mod=collection', 's')) { // < 淘贴列表 >
  5474. curSite = DBSite.discuz_collection;
  5475. } else if (getCSS('#threadlist')) { // < 部分论坛的各板块 URL 是自定义的 >
  5476. discuzForum();
  5477. } else if (getCSS('#postlist')) { // < 部分论坛的帖子内 URL 是自定义的 >
  5478. if (GM_getValue('menu_discuz_thread_page')) curSite = DBSite.discuz_thread;
  5479. }
  5480. }
  5481. }
  5482. // [Discuz! 论坛] 图片模式列表样式预处理
  5483. function waterfallStyle() {
  5484. let width = getCSS('#waterfall > li:first-child').style.width;
  5485. 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;}`);
  5486. }
  5487.  
  5488.  
  5489. // [谷歌搜索] 的插入前函数(加载视频图片)
  5490. function google_bF(pageElems) {
  5491. if (!indexOF('tbm=nws', 's')){
  5492. pageElems.forEach(function (one) {
  5493. getAllCSS('a[aria-label][href*="https://www.youtube.com/watch?v="]').forEach(function (one1) {
  5494. let img = getCSS('img', one1)
  5495. if (img) img.src = `https://i.ytimg.com/vi/${one1.href.split('?v=')[1]}/mqdefault.jpg`
  5496. })
  5497. });
  5498. }
  5499. return pageElems
  5500. }
  5501.  
  5502.  
  5503. // [必应搜索] 的插入前函数(加载网站图标)
  5504. function bing_bF(pageElems) {
  5505. pageElems.forEach(function (one) {
  5506. getAllCSS('div.rms_iac[data-src]').forEach(function (one1) {
  5507. one1.outerHTML = `<img src="${one1.dataset.src}" height="16" width="16" alt="全球 Web 图标" role="presentation" class="rms_img">`;
  5508. })
  5509. });
  5510. return pageElems
  5511. }
  5512.  
  5513.  
  5514. // [头条搜索] 的插入前函数(过滤相关搜索)
  5515. function toutiao_bF(pageElems) {
  5516. if (getXpath('//div[contains(@class,"-header") and string()="相关搜索"]', pageElems[pageElems.length - 1])) pageElems[pageElems.length - 1].style.display = 'none';
  5517. return pageElems
  5518. }
  5519.  
  5520.  
  5521. // [Startpage] 获取下一页地址
  5522. function startpage_nextL() {
  5523. let form = getXpath('//div[contains(@class, "pagination ")]/form[./button[@class="pagination__next-prev-button next"]]'), value;
  5524. if (form) {
  5525. form.querySelectorAll('input[name]').forEach(function(input) {value += input.name + '=' + input.value + '&';}) // 生成表单参数
  5526. value = encodeURI(value.replace(/&$/,'')); // 清理最后一个 & 符号
  5527. if (form.action && value) return (form.action + '?' + value)
  5528. }
  5529. return '';
  5530. }
  5531.  
  5532.  
  5533. // [F 搜] 的插入前函数(移除旧页码)
  5534. function fsou_bF(pageElems) {
  5535. let old = getCSS('.bottom-pagination')
  5536. if (old) old.remove();
  5537. return pageElems
  5538. }
  5539.  
  5540.  
  5541. // [SkrBT] 获取下一页地址
  5542. function skrbt_nextL() {
  5543. let page = getCSS('a[onclick][aria-label="Next"]');
  5544. if (page) {page = /(?<=\()\d+(?=\))/.exec(page.onclick)[0];} else {return '';} // 获取下一页页码
  5545. if (page) {
  5546. let action = getCSS('#search-form').action, value = ''; // 获取提交表单 URL
  5547. getAllCSS('#search-form input[name]').forEach(function(input) {value += input.name + '=' + input.value + '&';}) // 生成表单参数
  5548. value = encodeURI(value.replace(/&$/,'').replace(/p=\d+/,'p=' + page)); // 清理最后一个 & 符号,并替换页码
  5549. if (action && value) return (action + '?' + value)
  5550. }
  5551. return '';
  5552. }
  5553.  
  5554.  
  5555. // [百度贴吧](发帖按钮点击事件)
  5556. function baidu_tieba_1() {
  5557. let button = getCSS('.tbui_aside_fbar_button.tbui_fbar_post > a');
  5558. if (button) {
  5559. button.remove();
  5560. 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>')
  5561. button = getCSS('.tbui_aside_fbar_button.tbui_fbar_post > a');
  5562. if (button) {
  5563. button.onclick = function(){
  5564. let button2 = getCSS('div.edui-btn.edui-btn-fullscreen.edui-btn-name-portrait');
  5565. if (button2) {button2.click();} else {alert('提示:登录后才能发帖!');}
  5566. return false;
  5567. }
  5568. }
  5569. }
  5570. }
  5571. // [百度贴吧] 插入数据
  5572. function baidu_tieba_insertE(pageElems, type) {
  5573. if (!pageElems) return
  5574. // 获取 <script> 内容
  5575. const scriptElems = getXpath(`//script[contains(text(), 'Bigpipe.register("frs-list/pagelet/thread_list", ')]`, pageElems, pageElems);
  5576. if (scriptElems) {
  5577. // 从 <script> 中提取帖子列表字符串
  5578. let scriptText = scriptElems.textContent.replace('Bigpipe.register("frs-list/pagelet/thread_list", ','');
  5579. scriptText = scriptText.slice(0, scriptText.indexOf(').'));
  5580. // 字符串转 Element 元素
  5581. let temp_baidu_tieba = document.createElement('div'); temp_baidu_tieba.innerHTML = JSON.parse(scriptText).content;
  5582. processElems(temp_baidu_tieba);
  5583. }
  5584. }
  5585.  
  5586.  
  5587. // [V2EX] 的插入后函数(新标签页打开链接)
  5588. function v2ex_aF(css) {
  5589. let links = getAllCSS(css);if (!links) return
  5590. links.forEach(function (_this) {_this.target = '_blank';});
  5591. }
  5592.  
  5593.  
  5594. // [龙的天空] 获取下一页地址
  5595. function lkong_nextL() {
  5596. let next = getCSS('li.ant-pagination-next'), page;
  5597. if (next && next.getAttribute('aria-disabled') === 'false') {
  5598. page = getCSS('li.ant-pagination-item-active[title]');
  5599. if (page && page.title) {
  5600. return (location.origin + location.pathname + '?page=' + ++page.title);
  5601. }
  5602. }
  5603. return '';
  5604. }
  5605.  
  5606.  
  5607. // [游民星空-攻略] 的插入前函数(移除下一页底部的 "更多相关内容请关注:xxx" 文字)
  5608. function gamersky_gl_bF(pageElems) {
  5609. pageElems.forEach(function (one) {if (one.tagName === 'P' && one.textContent.indexOf('更多相关内容请关注') > -1) {one.style.display = 'none';}});
  5610. return pageElems
  5611. }
  5612.  
  5613.  
  5614. // [NexusMods] 获取下一页地址
  5615. function nexusmods_nextL() {
  5616. if (getCSS('.nexus-ui-blocker')) return
  5617. let modList;
  5618. if (indexOF('/news')) {modList = RH_NewsTabContent;} else {modList = RH_ModList;}
  5619. let out_items = JSON.stringify(modList.out_items).replace(/{|}|"/g,''),
  5620. nextNum = getXpath('//div[contains(@class, "pagenav")][1]//a[contains(@class, "page-selected")]/parent::li/following-sibling::li/a'),
  5621. categories = modList.out_items.categories, categoriesUrl = '';
  5622. var url = '';
  5623. if (nextNum && nextNum.innerText) {
  5624. nextNum = nextNum.innerText;
  5625. if (out_items.indexOf('page:') > -1) {
  5626. out_items = out_items.replace(/page:\d+/, `page:${nextNum}`)
  5627. } else {
  5628. out_items += `,page:${nextNum}`;
  5629. }
  5630. if (categories && categories != []) {
  5631. for (let i = 0; i < categories.length; i++) {
  5632. categoriesUrl += `,categories[]:${categories[i]}`
  5633. }
  5634. categoriesUrl = categoriesUrl.replace(/,/,'');
  5635. if (out_items.indexOf('categories:') > -1) {
  5636. out_items = out_items.replace(/categories:\[.*\]/, categoriesUrl)
  5637. }
  5638. }
  5639. return `https://www.nexusmods.com${modList.uri}?RH_${modList.id}=${out_items}`
  5640. }
  5641. return ''
  5642. }
  5643. // [NexusMods] 的插入前函数(隐藏底部元素)
  5644. function nexusmods_bF(pageElems) {
  5645. pageElems.forEach(function (one) {
  5646. let now = one.querySelector('.mod-tile-left');
  5647. if (now) {
  5648. let downloadCount = now.querySelector('.downloadcount > span.flex-label');
  5649. if (downloadCount) {
  5650. if (GlobalModStats[now.dataset.gameId] && GlobalModStats[now.dataset.gameId][now.dataset.modId]) {
  5651. downloadCount.textContent = shortFormat(parseInt(GlobalModStats[now.dataset.gameId][now.dataset.modId].total));
  5652. }
  5653. }
  5654. }
  5655. });
  5656. return pageElems
  5657. }
  5658.  
  5659.  
  5660. // [cs_rin_ru] 各版块帖子列表的插入前函数(过滤置顶帖子)
  5661. function cs_rin_ru_bF(pageElems) {
  5662. for (let i = 0; i < pageElems.length; i++) {
  5663. if (pageElems[i].textContent.replace(/\n| /g,'') === 'Topics') {
  5664. pageElems.splice(0,i+1);
  5665. break;
  5666. }
  5667. }
  5668. return pageElems
  5669. }
  5670.  
  5671.  
  5672. // [bilibili_search] 获取下一页地址
  5673. function bilibili_search_nextL() {
  5674. if (!location.search) return
  5675. let pageActive = 1, pageLast = parseInt(getXpath('//ul[@class="pages"]/li[contains(@class, "page-item")][not(contains(@class, "next") or contains(@class, "prev"))][last()]').innerText);
  5676. if (!pageLast) return
  5677. if (indexOF(/page=\d+/, 's')) {
  5678. pageActive = parseInt(/page=\d+/.exec(location.search)[0].replace('page=',''))
  5679. }
  5680. if (pageActive < pageLast) {
  5681. if (indexOF(/page=\d+/, 's')) {
  5682. return (location.origin + location.pathname + location.search.replace(/page=\d+/,`page=${pageActive+1}`))
  5683. } else {
  5684. return (location.origin + location.pathname + location.search + `&page=${pageActive+1}`)
  5685. }
  5686. }
  5687. }
  5688. // [bilibili_search] 插入后函数(加载图片)
  5689. function bilibili_search_aF() {
  5690. let result = __INITIAL_STATE__.flow[__INITIAL_STATE__.flow.fields[0]].result;
  5691. if (result.length > 0) {
  5692. let imgArr = getAllCSS('.img > .lazy-img > img[src=""]');
  5693. if (imgArr.length > 0) {
  5694. for (let i = 0; i < imgArr.length; i++) {
  5695. imgArr[i].src = result[i].pic;
  5696. }
  5697. }
  5698. }
  5699. }
  5700.  
  5701.  
  5702. // [Anime1] 获取下一页内容(叠加)
  5703. function anime1_nextL() {
  5704. let next = getCSS('#tablepress-1_next');
  5705. if (next && next.className.indexOf('disabled') === -1) {
  5706. let oldList = getCSS('tbody.row-hover').innerHTML;
  5707. if (oldList) {
  5708. next.click();
  5709. pageNum.now = pageNum._now + 1;
  5710. getCSS('tbody.row-hover').insertAdjacentHTML('afterbegin', oldList); // 插入到列表头部
  5711. }
  5712. }
  5713. }
  5714.  
  5715.  
  5716. // [BTHaha] 的插入前函数(隐藏底部元素)
  5717. function bthaha_bF(pageElems) {
  5718. pageElems.forEach(function (one) {
  5719. let now = one.querySelector('[id^="list_top"], [id^="list_bottom"]')
  5720. if (now) {one.hidden = true;}
  5721. });
  5722. return pageElems
  5723. }
  5724.  
  5725.  
  5726. // [RARBG] 的插入前函数(鼠标指向显示封面)
  5727. function rarbg_bF(pageElems) {
  5728. pageElems.forEach(function (one) {
  5729. one.querySelectorAll('td > a[onmouseover][onmouseout]').forEach(function (now) {
  5730. now.parentElement.parentElement.setAttribute('onmouseover', now.getAttribute('onmouseover')); now.removeAttribute('onmouseover');
  5731. now.parentElement.parentElement.setAttribute('onmouseout', now.getAttribute('onmouseout')); now.removeAttribute('onmouseout');
  5732. });
  5733. });
  5734. return pageElems
  5735. }
  5736.  
  5737.  
  5738. // [LRepacks] 的插入前函数(调整 class)
  5739. function lrepacks_bF(pageElems) {
  5740. pageElems.forEach(function (one) {
  5741. let now = one.querySelector('.slideUp, .elementFade')
  5742. if (now) {
  5743. now.className = now.className.replace('slideUp','slideUpRun').replace('elementFade','elementFadeRun');
  5744. }
  5745. });
  5746. return pageElems
  5747. }
  5748.  
  5749.  
  5750. // [漫画狂] 获取下一页地址
  5751. function cartoonmad_nextL() {
  5752. let url = getXpath('//a[@class="pages"][contains(text(),"下一頁")]');
  5753. if (url) {
  5754. if (url.getAttribute('href') === 'thend.asp') {
  5755. url = getXpath('//a[@class="pages"][contains(string(),"下一話")]')
  5756. if (url) return url.href;
  5757. pausePage = false;
  5758. GM_notification({text: `注意:该网站早期漫画(如海贼王、柯南)因为网站自身问题而无法翻至下一话(仅限于显示为 [第 X 卷]/[下一卷] 的)。\n因此需要手动去 [目录页] 进入下一卷!`, timeout: 10000});
  5759. } else {
  5760. return url.href;
  5761. }
  5762. }
  5763. return '';
  5764. }
  5765.  
  5766.  
  5767. // [漫画猫] 初始化(显示本话所以图片)
  5768. function manhuacat_init() {
  5769. let _img = '';
  5770. for (let now of img_data_arr) {_img += `<img src="${asset_domain}${img_pre}${now}">`;}
  5771. getOne(curSite.pager.insertP[0]).innerHTML = _img;
  5772.  
  5773. }
  5774. // [漫画猫] 获取下一页地址
  5775. function manhuacat_nextL(pageElems, type) {
  5776. if (type === 'url') {
  5777. if(pageElems.code == '0000') {
  5778. if (pageElems.url === curSite.pageUrl) return
  5779. curSite.pageUrl = pageElems.url;
  5780. getPageElems_(curSite.pageUrl); // 真正的下一页链接
  5781. }
  5782. } else {
  5783. let vg_r_data = getCSS('.vg-r-data');
  5784. if (vg_r_data) {
  5785. getPageElems_(`${location.origin}/chapter_num?chapter_id=${vg_r_data.dataset.chapter_num}&ctype=1&type=${vg_r_data.dataset.chapterType};`, 'json', 'GET', '', 'url');
  5786. }
  5787. }
  5788. }
  5789. // [漫画猫] 插入数据
  5790. function manhuacat_insertE(pageElems, type) {
  5791. if (!pageElems) return
  5792. if (type === 'url') { // 获取下一页链接
  5793. manhuacat_nextL(pageElems, type); return
  5794. }
  5795. addHistory(pageElems);
  5796. replaceElems(pageElems);
  5797.  
  5798. // 插入图片
  5799. 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');;
  5800. for (let now of _img_arr) {_img += `<img src="${vg_r_data.dataset.chapterDomain}${img_pre}${now}">`;}
  5801. if (_img) {
  5802. getOne(curSite.pager.insertP[0]).insertAdjacentHTML(getAddTo(curSite.pager.insertP[1]), _img); // 将 img 标签插入到网页中
  5803. pageNum.now = pageNum._now + 1
  5804. }
  5805. }
  5806.  
  5807.  
  5808. // [漫画柜] 初始化(将本话其余图片插入网页中)
  5809. function manhuagui_init() {
  5810. // hook imgDate 代码
  5811. SMH.imgData = function(n) {window['imgDate'] = n;return{preInit:function(){}}}
  5812. // 重新执行本页的 imgDate 代码
  5813. insScript(curSite.pager.pageE);
  5814. let _img = '', imgPath = `${location.protocol}//i.hamreus.com${window['imgDate'].path}`;
  5815. //console.log(imgPath, window['imgDate'])
  5816. if (!(window['imgDate']) || !(imgPath)) return
  5817. // 遍历图片文件名数组,组合为 img 标签
  5818. 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}">`;}
  5819. // 插入并覆盖原来的一个图片
  5820. getOne(curSite.pager.insertP[0]).innerHTML = _img;
  5821. pausePage = true;
  5822. }
  5823. // [漫画柜] 获取下一页地址
  5824. function manhuagui_nextL() {
  5825. if (window['imgDate'].nextId == 0) return
  5826. var url = location.origin + location.pathname.replace(window['imgDate'].cid.toString(), window['imgDate'].nextId.toString())
  5827. if (url === curSite.pageUrl) return
  5828. curSite.pageUrl = url
  5829. getPageElems_(curSite.pageUrl);
  5830. }
  5831. // [漫画柜] 插入数据
  5832. function manhuagui_insertE(pageElems, type) {
  5833. if (!pageElems) return
  5834. // 重新执行本页的 imgDate 代码
  5835. insScript(curSite.pager.pageE, document.body, pageElems);
  5836. let _img = '', imgPath = `${location.protocol}//i.hamreus.com${window['imgDate'].path}`;
  5837. //console.log(imgPath, window['imgDate'])
  5838. if (!(window['imgDate']) || !(imgPath)) return
  5839. // 遍历图片文件名数组,组合为 img 标签
  5840. 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}">`;}
  5841. getOne(curSite.pager.insertP[0]).insertAdjacentHTML(getAddTo(curSite.pager.insertP[1]), _img);
  5842. addHistory(pageElems);
  5843. pageNum.now = pageNum._now + 1
  5844. }
  5845.  
  5846.  
  5847. // [漫画 DB] 初始化(将本话其余图片插入网页中)
  5848. function manhuadb_init() {
  5849. let _img = '', data = getCSS('.vg-r-data'), imgDate;
  5850. if (!data) return
  5851. getAllCSS(curSite.pager.pageE.replace('css;', '')).forEach(function (one) {
  5852. if (one.tagName === 'SCRIPT' && one.textContent.indexOf('var img_data =') > -1) {
  5853. let json = JSON.parse(window.atob(one.textContent.split("'")[1]));
  5854. if (json) {
  5855. let _img = '';
  5856. 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}">`;}
  5857. getOne(curSite.pager.insertP[0]).insertAdjacentHTML(getAddTo(curSite.pager.insertP[1]), _img); // 将 img 标签插入到网页中
  5858. }
  5859. }
  5860. })
  5861. }
  5862. // [漫画 DB] 获取下一页地址
  5863. function manhuadb_nextL() {
  5864. let nextArr = getAllCSS('a.fixed-a-es'), next;
  5865. var url = '';
  5866. if (nextArr.length == 0) return
  5867. for (let i = 0; i < nextArr.length; i++) {
  5868. if (nextArr[i].className.indexOf('active') > -1) {
  5869. if (nextArr[i+1]) url = nextArr[i+1].href;
  5870. break;
  5871. }
  5872. }
  5873. if (url === curSite.pageUrl) return
  5874. curSite.pageUrl = url
  5875. getPageElems_(curSite.pageUrl);
  5876. }
  5877. // [漫画 DB] 插入数据
  5878. function manhuadb_insertE(pageElems, type) {
  5879. if (!pageElems) return
  5880. if (replaceElems(pageElems, curSite.pager.pageE, curSite.pager.pageE)) {
  5881. addHistory(pageElems);
  5882. pageNum.now = pageNum._now + 1
  5883. manhuadb_init(); // 将刚刚替换的图片插入网页中
  5884. }
  5885. }
  5886.  
  5887.  
  5888. // [HiComic(嗨漫画)] 初始化(将本话其余图片插入网页中)
  5889. function hicomic_init() {
  5890. let _img = '';
  5891. getAllCSS('.chapter > section:not(:first-child) > section[val]').forEach(function (one) {
  5892. let src = one.getAttribute('val');
  5893. if (src.indexOf('!p_c_c_') === -1) src += '!p_c_c_h'
  5894. _img += `<img src="${src}">`
  5895. })
  5896. getOne(curSite.pager.insertP[0]).insertAdjacentHTML(getAddTo(curSite.pager.insertP[1]), _img); // 将 img 标签插入到网页中
  5897. window.document.title = window.document.title.replace(/(\(第.+\))? - HiComic/, `(${getCSS('.chapter_name').textContent}) - HiComic`); // 修改网页标题(加上 第 X 话)
  5898. }
  5899. // [HiComic(嗨漫画)] 获取下一页地址
  5900. function hicomic_nextL() {
  5901. let nextId;
  5902. nextId = getCSS('.next_chapter:not(.end)')
  5903. if (nextId && nextId.id && nextId.id != 'None') {
  5904. curSite.pageUrl = location.href;
  5905. getPageElems_(`https://www.hicomic.net/api/web/chapter/${nextId.id}/contents`, 'json');
  5906. }
  5907. }
  5908. // [HiComic(嗨漫画)] 插入数据
  5909. function hicomic_insertE(pageElems, type) {
  5910. if (!pageElems || pageElems.code != 200) return
  5911. if (pageElems.results.chapter.next) { // 写入下一页的 UUID
  5912. getCSS('.next_chapter').id = pageElems.results.chapter.next;
  5913. } else {
  5914. getCSS('.next_chapter').id = 'None';
  5915. getCSS('.next_chapter').classList.add('end');
  5916. }
  5917. curSite.pageUrl =`https://www.hicomic.net/chapters/${pageElems.results.chapter.uuid}/contents`
  5918. getCSS('.chapter_name').textContent = pageElems.results.chapter.name; // 修改漫画标题
  5919. addHistory(pageElems, window.document.title.replace(/(\(第.+\))? - HiComic/, `(${pageElems.results.chapter.name}) - HiComic`));
  5920. let _img = '';
  5921. for (let i = 0; i < pageElems.results.chapter.contents.length; i++) { // 遍历图片文件名数组,组合为 img 标签
  5922. let src = pageElems.results.chapter.contents[i].url;
  5923. if (src.indexOf('!p_c_c_') === -1) src += '!p_c_c_h';
  5924. _img += `<img src="${src}">`
  5925. }
  5926. getOne(curSite.pager.insertP[0]).insertAdjacentHTML(getAddTo(curSite.pager.insertP[1]), _img); // 将 img 标签插入到网页中
  5927. pageNum.now = pageNum._now + 1
  5928. }
  5929.  
  5930.  
  5931. // [动漫之家] 初始化(调整本话其余图片)
  5932. function dmzj_init(css) {
  5933. let _img = '';
  5934. getAllCSS(css).forEach(function (one) {_img += `<img src="${one.dataset.original}">`;})
  5935. getOne(curSite.pager.insertP[0]).innerHTML = _img;
  5936. }
  5937. // [动漫之家] 插入数据
  5938. function dmzj_insertE(pageElems, type) {
  5939. if (!pageElems) return
  5940. // 插入并运行 <script>
  5941. insScript('css;head > script[type]:not([src])', document.body, pageElems);
  5942.  
  5943. // 插入图片
  5944. let _img = '', _img_arr;
  5945. if (pages.indexOf('|') === -1) {
  5946. _img_arr = JSON.parse(pages.replace(/\r\n/g,'|')).page_url.split('|');
  5947. } else {
  5948. _img_arr = JSON.parse(pages).page_url.split('|');
  5949. }
  5950. for (let now of _img_arr) {
  5951. _img += `<img src="${img_prefix}${now}">`;
  5952. }
  5953. if (_img) {
  5954. getOne(curSite.pager.insertP[0]).insertAdjacentHTML(getAddTo(curSite.pager.insertP[1]), _img); // 将 img 标签插入到网页中
  5955. addHistory(pageElems);
  5956. if (replaceElems(pageElems)) pageNum.now = pageNum._now + 1
  5957. }
  5958. }
  5959. // [动漫之家-漫画] 插入数据
  5960. function dmzj_manhua_insertE(pageElems, type) {
  5961. if (!pageElems) return
  5962. // 插入并运行 <script>
  5963. insScript('css;head > script[type]:not([src])', document.body, pageElems);
  5964.  
  5965. // 插入图片
  5966. let _img = '';
  5967. for (let now of arr_pages) {
  5968. _img += `<img src="${img_prefix}${now}">`;
  5969. }
  5970. if (_img) {
  5971. getOne(curSite.pager.insertP[0]).insertAdjacentHTML(getAddTo(curSite.pager.insertP[1]), _img); // 将 img 标签插入到网页中
  5972. addHistory(pageElems);
  5973. if (replaceElems(pageElems)) pageNum.now = pageNum._now + 1
  5974. }
  5975. }
  5976.  
  5977.  
  5978. // [动漫戏说] 插入后函数(加载图片)
  5979. function acgn_aF() {
  5980. let old = getAllCSS('.pic[_src][id]'), _img = '';
  5981. if (old.length > 0) {
  5982. for (let now of old) {now.outerHTML = `<div class="pic" _src="${now.getAttribute('_src')}"><img src="${now.getAttribute('_src')}" class="img1"></div>`;}
  5983. }
  5984. }
  5985.  
  5986.  
  5987. // [漫画星球] 插入数据
  5988. function mhxqiu_insertE(pageElems, type) {
  5989. if (!pageElems) return
  5990. // 插入并运行 <script>
  5991. insScript('//script[contains(text(), "eval") and contains(text(), "newImgs")]', document.body, pageElems);
  5992.  
  5993. // 插入图片
  5994. let _img = '';
  5995. 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>`;}
  5996. if (_img) {
  5997. // 将 img 标签插入到网页中
  5998. getOne(curSite.pager.insertP[0]).insertAdjacentHTML(getAddTo(curSite.pager.insertP[1]), _img);
  5999. addHistory(pageElems);
  6000. pageNum.now = pageNum._now + 1
  6001. replaceElems(pageElems)
  6002. }
  6003. }
  6004.  
  6005.  
  6006. // [风之动漫] 插入数据
  6007. function fffdm_insertE(pageElems, type) {
  6008. if (!pageElems) return
  6009. // 插入并运行 <script>
  6010. let scriptElems = getXpath('id("main")/script[contains(text(), "mhpicurl")][1]', pageElems, pageElems);
  6011. if (scriptElems) {
  6012. document.body.appendChild(document.createElement('script')).textContent = scriptElems.textContent.replace(/document\.write.+/, '');
  6013.  
  6014. // 插入图片
  6015. setTimeout(function() {
  6016. getOne(curSite.pager.insertP[0]).appendChild(document.createElement('img')).src = mhpicurl;
  6017. addHistory(pageElems);
  6018. pageNum.now = pageNum._now + 1
  6019. replaceElems(pageElems)
  6020. }, 100)
  6021. }
  6022. }
  6023.  
  6024.  
  6025. // [乐语漫画] 初始化(调整本话其余图片)
  6026. function leyuman_init() {
  6027. let _img = '';
  6028. for (let one of JSON.parse(z_img)) {
  6029. if (one.slice(0,4) === 'http') {
  6030. _img += `<img src="${one}">`;
  6031. } else {
  6032. _img += `<img src="https://img.shishi-life.com/${one}">`;
  6033. }
  6034. }
  6035. getOne(curSite.pager.insertP[0]).innerHTML = _img;
  6036.  
  6037. }
  6038. // [乐语漫画] 插入数据
  6039. function leyuman_insertE(pageElems, type) {
  6040. if (!pageElems) return
  6041. // 插入并运行 <script>
  6042. insScript('//body//script[not(@src)][contains(text(), "z_img=")]', document.body, pageElems);
  6043.  
  6044. // 插入图片
  6045. let _img = '';
  6046. for (let one of JSON.parse(z_img)) {
  6047. if (one.slice(0,4) === 'http') {
  6048. _img += `<img src="${one}">`;
  6049. } else {
  6050. _img += `<img src="https://img.shishi-life.com/${one}">`;
  6051. }
  6052. }
  6053. if (_img) {
  6054. // 将 img 标签插入到网页中
  6055. getOne(curSite.pager.insertP[0]).insertAdjacentHTML(getAddTo(curSite.pager.insertP[1]), _img);
  6056. addHistory(pageElems);
  6057. pageNum.now = pageNum._now + 1
  6058. replaceElems(pageElems)
  6059. }
  6060. }
  6061.  
  6062.  
  6063. // [新新漫画] 初始化(调整本话其余图片)
  6064. function _77mh_init() {
  6065. let _img = '';
  6066. for (let one of arr) {_img += `<img src="${img_qianz}${one}">`;}
  6067. getOne(curSite.pager.insertP[0]).innerHTML = _img;
  6068. }
  6069. // [新新漫画] 获取下一页地址
  6070. function _77mh_nextL() {
  6071. let next = nextLink_b
  6072. if (next && next != curSite.pageUrl) {
  6073. curSite.pageUrl = next;
  6074. getPageElems_(curSite.pageUrl);
  6075. }
  6076. }
  6077. // [新新漫画] 插入数据
  6078. function _77mh_insertE(pageElems, type) {
  6079. if (!pageElems) return
  6080. // 插入并运行 <script>
  6081. insScript('//script[not(@src)][contains(text(), "eval(")]', document.body, pageElems);
  6082.  
  6083. // 插入图片
  6084. let _img = '';
  6085. for (let one of msg.split('|')) {_img += `<img src="${img_qianz}${one}.webp">`;}
  6086. if (_img) {
  6087. // 将 img 标签插入到网页中
  6088. getOne(curSite.pager.insertP[0]).insertAdjacentHTML(getAddTo(curSite.pager.insertP[1]), _img);
  6089. addHistory(pageElems);
  6090. pageNum.now = pageNum._now + 1
  6091. }
  6092. }
  6093.  
  6094.  
  6095. // [古风漫画网] 获取下一页地址
  6096. function gufengmh_nextL() {
  6097. let pageElems = getOne(curSite.pager.pageE); // 寻找数据所在元素
  6098. if (pageElems) {
  6099. let comicUrl, nextId;
  6100. var url = '';
  6101. pageElems.textContent.split(';').forEach(function (one){ // 分号 ; 分割为数组并遍历
  6102. //console.log(one)
  6103. if (one.indexOf('comicUrl') > -1) { // 下一页 URL 前半部分
  6104. comicUrl = one.split('"')[1];
  6105. } else if (one.indexOf('nextChapterData') > -1) { // 下一页 URL 的后半部分 ID
  6106. nextId = one.split('"id":')[1].split(',')[0];
  6107. }
  6108. })
  6109. if (comicUrl && nextId && nextId != 'null') { // 组合到一起就是下一页 URL
  6110. url = comicUrl + nextId + '.html'
  6111. if (url === curSite.pageUrl) return
  6112. curSite.pageUrl = url
  6113. getPageElems_(curSite.pageUrl); // 访问下一页 URL 获取
  6114. }
  6115. }
  6116. }
  6117. // [古风漫画网] 插入数据
  6118. function gufengmh_insertE(pageElems, type) {
  6119. if (pageElems) {
  6120. let url = curSite.pageUrl;
  6121. pageElems = getOne(curSite.pager.pageE, pageElems, pageElems);
  6122. let chapterImages, chapterPath;
  6123. getOne(curSite.pager.pageE).innerText = pageElems.textContent; // 将当前网页内的数据所在元素内容改为刚刚获取的下一页数据内容,以便循环获取下一页 URL
  6124. pageElems.textContent.split(';').forEach(function (one){ // 分号 ; 分割为数组并遍历
  6125. //console.log(one)
  6126. if (one.indexOf('chapterImages') > -1) { // 图片文件名数组
  6127. chapterImages = one.replace(/^.+\[/, '').replace(']', '').replaceAll('"', '').split(',')
  6128. } else if (one.indexOf('chapterPath') > -1) { // 图片文件路径
  6129. chapterPath = one.split('"')[1];
  6130. } else if (one.indexOf('pageTitle') > -1) { // 网页标题
  6131. addHistory(pageElems, one.split('"')[1]);
  6132. }
  6133. })
  6134. if (chapterImages && chapterPath) {
  6135. let _img = '';
  6136. chapterImages.forEach(function (one2){_img += '<img src="https://res.xiaoqinre.com/' + chapterPath + one2 + '" data-index="0" style="display: inline-block;">';})
  6137. getOne(curSite.pager.insertP[0]).insertAdjacentHTML(getAddTo(curSite.pager.insertP[1]), _img); // 将 img 标签插入到网页中
  6138. pageNum.now = pageNum._now + 1
  6139. }
  6140. }
  6141. }
  6142.  
  6143.  
  6144. // [Mangabz 漫画] 初始化(调整本话图片)
  6145. function mangabz_init() {
  6146. let showimage = getCSS('#showimage'),
  6147. cp_img = getCSS('#cp_img'),
  6148. cp_image = getCSS('#cp_image');
  6149. if (showimage) {showimage.removeAttribute('oncontextmenu');}
  6150. if (cp_img) {cp_img.removeAttribute('oncontextmenu');}
  6151. if (cp_image) {
  6152. cp_image.removeAttribute('oncontextmenu');
  6153. cp_image.removeAttribute('id');
  6154. cp_image.removeAttribute('style');
  6155. }
  6156. }
  6157. // [Mangabz 漫画] 获取下一页地址
  6158. function mangabz_nextL() {
  6159. var url = '';
  6160. if (MANGABZ_PAGE === MANGABZ_IMAGE_COUNT) { // 下一话
  6161. if (getNextE('//a[./img[contains(@src, "icon_xiayizhang")]]')) getPageElems_(curSite.pageUrl); // 访问下一话 URL 获取
  6162. } else { // 下一页
  6163. if (!mkey) var mkey = '';
  6164. 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}`
  6165. if (url === curSite.pageUrl) return
  6166. curSite.pageUrl = url
  6167. //console.log(curSite.pageUrl)
  6168. getPageElems_(curSite.pageUrl, 'text', 'GET', '', 'Next'); // 访问下一页 URL 获取
  6169. }
  6170. }
  6171. // [Mangabz 漫画] 插入数据
  6172. function mangabz_insertE(pageElems, type) {
  6173. if (pageElems) {
  6174. if (type === 'Next') { // 下一页
  6175. let imgArr = eval(pageElems),
  6176. _img = '';
  6177. for (let now of imgArr) {_img += `<img src="${now}">`;}
  6178. if (_img) {
  6179. getOne(curSite.pager.insertP[0]).insertAdjacentHTML(getAddTo(curSite.pager.insertP[1]), _img); // 将 img 标签插入到网页中
  6180. MANGABZ_PAGE += imgArr.length;
  6181. addHistory(pageElems, document.title, location.origin + MANGABZ_CURL.substring(0, MANGABZ_CURL.length - 1) + '-p' + MANGABZ_PAGE + '/');
  6182. }
  6183. } else { // 下一话
  6184. // 插入 <script> 标签
  6185. insScript('css;html:not([dir]) > head > script:not([src])', document.body, pageElems);
  6186. addHistory(pageElems);
  6187. pageNum.now = pageNum._now + 1
  6188. replaceElems(pageElems)
  6189. MANGABZ_PAGE = 0;
  6190. mangabz_nextL();
  6191. }
  6192. }
  6193. }
  6194.  
  6195.  
  6196. // [Xmanhua 漫画] 获取下一页地址
  6197. function xmanhua_nextL() {
  6198. var url = '';
  6199. if (XMANHUA_PAGE === XMANHUA_IMAGE_COUNT) { // 下一话
  6200. if (getNextE('//a[./img[contains(@src, "reader-bottom-right-2.png")]]')) getPageElems_(curSite.pageUrl); // 访问下一话 URL 获取
  6201. } else { // 下一页
  6202. if (!mkey) var mkey = '';
  6203. 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}`
  6204. if (url === curSite.pageUrl) return
  6205. curSite.pageUrl = url
  6206. //console.log(curSite.pageUrl)
  6207. getPageElems_(curSite.pageUrl, 'text', 'GET', '', 'Next'); // 访问下一页 URL 获取
  6208. }
  6209. }
  6210. // [Xmanhua 漫画] 插入数据
  6211. function xmanhua_insertE(pageElems, type) {
  6212. if (pageElems) {
  6213. if (type === 'Next') { // 下一页
  6214. let imgArr = eval(pageElems),
  6215. _img = '';
  6216. for (let now of imgArr) {_img += `<img src="${now}">`;}
  6217. if (_img) {
  6218. getOne(curSite.pager.insertP[0]).insertAdjacentHTML(getAddTo(curSite.pager.insertP[1]), _img); // 将 img 标签插入到网页中
  6219. XMANHUA_PAGE += imgArr.length;
  6220. addHistory(pageElems, document.title, location.origin + XMANHUA_CURL.substring(0, XMANHUA_CURL.length - 1) + '-p' + XMANHUA_PAGE + '/');
  6221. }
  6222. } else { // 下一话
  6223. // 插入 <script> 标签
  6224. insScript('css;html:not([dir]) > head > script:not([src])', document.body, pageElems);
  6225. addHistory(pageElems);
  6226. pageNum.now = pageNum._now + 1
  6227. replaceElems(pageElems)
  6228. XMANHUA_PAGE = 0;
  6229. xmanhua_nextL();
  6230. }
  6231. }
  6232. }
  6233.  
  6234.  
  6235. // [COCOMANGA 漫画] 初始化(调整本话图片)
  6236. function cocomanga_init() {
  6237. let last = getCSS('.mh_comicpic:last-of-type');
  6238. if (last && last.getAttribute('p')) {
  6239. getOne(curSite.pager.insertP[0]).innerHTML = ''; // 删除旧图片元素
  6240. cocomanga_img(parseInt(last.getAttribute('p'))) // 插入新图片元素
  6241. }
  6242. }
  6243. // [COCOMANGA 漫画] 生成图片元素并插入网页
  6244. function cocomanga_img(totalImageCount) {
  6245. if (totalImageCount < 1) return
  6246. let _img = '';
  6247. for (let i=1; i<=totalImageCount; i++) {_img += `<div class="mh_comicpic" p="${i}"><img src="${__cr.getPicUrl(i)}"></div>`;}
  6248. getOne(curSite.pager.insertP[0]).insertAdjacentHTML(getAddTo(curSite.pager.insertP[1]), _img); // 将 img 标签插入到网页中
  6249. }
  6250. // [COCOMANGA 漫画] 插入数据
  6251. function cocomanga_insertE(pageElems, type) {
  6252. if (pageElems) {
  6253. // 插入 <script> 标签
  6254. insScript('css;head > script:not([src]), script[src*="custom.js"], script[src*="dynamicjs.js"]', document.body, pageElems);
  6255.  
  6256. // 插入新图片元素
  6257. setTimeout(function() {
  6258. let totalImageCount = __cdecrypt('fw122587mkertyui', CryptoJS.enc.Base64.parse(mh_info.enc_code1).toString(CryptoJS.enc.Utf8));
  6259. if (!totalImageCount) totalImageCount = __cdecrypt('fw12558899ertyui', CryptoJS.enc.Base64.parse(mh_info.enc_code1).toString(CryptoJS.enc.Utf8));
  6260. cocomanga_img(parseInt(totalImageCount));
  6261. }, 100)
  6262. addHistory(pageElems);
  6263. pageNum.now = pageNum._now + 1
  6264. replaceElems(pageElems)
  6265. }
  6266. }
  6267.  
  6268.  
  6269. // [国家自然科学基金] 获取下一页地址
  6270. function nsfc_nextL() {
  6271. let id = decodeURIComponent(document.location.href.split('/')[document.location.href.split('/').length - 1]), data
  6272. if (!document.nowPageNum) document.nowPageNum = 2
  6273. data = `id=${id}&index=${document.nowPageNum}`
  6274. if (data === curSite.pageUrl) return
  6275. curSite.pageUrl = data
  6276. getPageElems_(location.origin + '/baseQuery/data/completeProjectReport', 'json', 'POST', data); // 访问下一页 URL 获取
  6277. }
  6278. // [国家自然科学基金] 插入数据
  6279. function nsfc_insertE(pageElems, type) {
  6280. if (!pageElems || pageElems.code != 200) {curSite.SiteTypeID = 0; return}
  6281. if (!pageElems.data.hasnext) {curSite.SiteTypeID = 0} else {document.nowPageNum++}
  6282. pageNum.now = pageNum._now + 1
  6283. 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}">`);
  6284. }
  6285.  
  6286.  
  6287.  
  6288. // [酷科研] 获取下一页地址
  6289. function coolkeyan_nextL() {
  6290. if (!getCSS('.q-img__image')) return
  6291. let id = getCSS('.q-breadcrumbs--last > span.q-breadcrumbs__el'), data
  6292. if (id && id.textContent) {id=parseInt(id.textContent)} else {return}
  6293. if (!document.nowPageNum) document.nowPageNum = 2
  6294. data = `ratify_no=${id}&index=${document.nowPageNum}`
  6295. if (data === curSite.pageUrl) return
  6296. curSite.pageUrl = data
  6297. getPageElems_(location.origin + '/api/funds/nsfc/creport?' + data, 'json', 'GET'); // 访问下一页 URL 获取
  6298. }
  6299. // [酷科研] 插入数据
  6300. function coolkeyan_insertE(pageElems, type) {
  6301. if (!pageElems || pageElems == {}) {curSite.SiteTypeID = 0; return}
  6302. if (!pageElems.url) {curSite.SiteTypeID = 0; return} else {document.nowPageNum++}
  6303. pageNum.now = pageNum._now + 1
  6304. getCSS('.q-img>div[style*="padding-bottom"]').style.paddingBottom = `${(document.nowPageNum * 1000) - 1000}px`
  6305. 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>`);
  6306. }
  6307.  
  6308.  
  6309. // --------------------------------------------------------
  6310.  
  6311.  
  6312. // 自动无缝翻页
  6313. function pageLoading() {
  6314. if (curSite.SiteTypeID == 0) return
  6315. windowScroll(function (direction, e) {
  6316. // 下滑 且 未暂停翻页 且 SiteTypeID > 0 时,才准备翻页
  6317. if (direction != 'down' || !pausePage || curSite.SiteTypeID == 0) return
  6318. // 翻页模式 5 且为框架内时,要判断顶层是否通过页码暂停翻页了
  6319. if (curSite.pager.type == 5 && self != top && window.top.document.xiu_pausePage == false) return
  6320.  
  6321. let scrollTop = document.documentElement.scrollTop || window.pageYOffset || document.body.scrollTop,
  6322. scrollHeight = window.innerHeight || document.documentElement.clientHeight,
  6323. scrollD = curSite.pager.scrollD;
  6324.  
  6325. // <<<<< 翻页类型 3(依靠 [基准元素] 与 [浏览器可视区域底部] 之间的距离缩小来触发翻页)>>>>>
  6326. if (curSite.pager.type === 3) {
  6327. let scrollE = getOne(curSite.pager.scrollE);
  6328. //console.log(scrollE.offsetTop, scrollE.offsetTop - (scrollTop + scrollHeight), scrollD, scrollTop + scrollHeight, curSite.SiteTypeID)
  6329. if (scrollE.offsetTop - (scrollTop + scrollHeight) <= scrollD) {intervalPause(); checkURL(getPageElems);}
  6330.  
  6331. } else {
  6332. if (document.documentElement.scrollHeight <= scrollHeight + scrollTop + scrollD) {
  6333. // <<<<< 翻页类型 1(由脚本实现自动无缝翻页)>>>>>
  6334. if (curSite.pager.type === 1) {
  6335. intervalPause(); checkURL(getPageElems);
  6336.  
  6337. // <<<<< 翻页类型 2(网站自带了自动无缝翻页功能,只需要点击下一页按钮即可)>>>>>
  6338. } else if (curSite.pager.type === 2) {
  6339. let autopbn = getOne(curSite.pager.nextL);
  6340. if (!autopbn) return
  6341. if (curSite.pager.isHidden && isHidden(autopbn)) return // 如果 isHidden = true,那么需要判断元素是否隐藏
  6342. if (curSite.pager.nextText) {
  6343. // 按钮文本,当按钮文本 = 该文本时,才会点击按钮加载下一页
  6344. if (autopbn.innerText === curSite.pager.nextText) {autopbn.click(); pageNum.now = pageNum._now + 1;}
  6345. } else if (curSite.pager.nextTextOf) {
  6346. // 按钮文本的一部分,当按钮文本包含该文本时,才会点击按钮加载下一页
  6347. if (autopbn.innerText.indexOf(curSite.pager.nextTextOf) > -1) {autopbn.click(); pageNum.now = pageNum._now + 1;}
  6348. } else if (curSite.pager.nextHTML) {
  6349. // 按钮内元素,当按钮内元素 = 该元素内容时,才会点击按钮加载下一页
  6350. if (autopbn.innerHTML === curSite.pager.nextHTML) {autopbn.click(); pageNum.now = pageNum._now + 1;}
  6351. } else {
  6352. // 对于没有按钮文字变化的按钮,可以指定间隔时间(默认 300ms)
  6353. if (!curSite.pager.interval) curSite.pager.interval = 300;
  6354. intervalPause();
  6355. // 如果没有指定按钮文字就直接点击
  6356. autopbn.click(); pageNum.now = pageNum._now + 1;
  6357. }
  6358.  
  6359. // <<<<< 翻页类型 4(部分简单的动态加载类网站)>>>>>
  6360. } else if (curSite.pager.type === 4) {
  6361. // 为百度贴吧的发帖考虑,预留底部一小部分...
  6362. if (!(curSite.SiteTypeID === SiteType.BAIDU_TIEBA && document.documentElement.scrollHeight <= scrollHeight + scrollTop + 200)) {
  6363. intervalPause(); if (typeof curSite.pager.nextL == 'function') {curSite.pager.nextL();} else if (getNextE(curSite.pager.nextL)) {getPageElems_(curSite.pageUrl);}
  6364. }
  6365.  
  6366. // <<<<< 翻页类型 5(插入 iframe 方式来加载下一页)>>>>>
  6367. } else if (curSite.pager.type === 5) {checkURL(insIframe);
  6368.  
  6369. // <<<<< 翻页类型 6(通过 iframe 获取下一页动态加载内容)>>>>>
  6370. } else if (curSite.pager.type === 6) {checkURL(insIframe_);}
  6371. }
  6372. }
  6373. });
  6374.  
  6375. function intervalPause() {
  6376. if (curSite.pager.interval) {
  6377. pausePage = false
  6378. setTimeout(function(){pausePage = true;}, curSite.pager.interval)
  6379. }
  6380. }
  6381. }
  6382. // 判断是支持
  6383. function doesItSupport() {
  6384. setDBSite(); // 配置 DBSite 变量对象
  6385.  
  6386. // 遍历判断是否是某个已支持的网站,顺便直接赋值
  6387. let support = false;
  6388. for (let now in DBSite) { // 遍历对象
  6389. if (!DBSite[now].host) continue; // 如果不存在则继续下一个循环
  6390. if (Array.isArray(DBSite[now].host)) { // 如果是数组
  6391. for (let i of DBSite[now].host) { // 遍历数组
  6392. if (i === location.hostname) {
  6393. if (DBSite[now].functionS) {
  6394. DBSite[now].functionS();
  6395. } else {
  6396. curSite = DBSite[now];
  6397. }
  6398. support = true; break; // 如果找到了就退出循环
  6399. }
  6400. }
  6401. } else if (DBSite[now].host instanceof RegExp) {
  6402. if (DBSite[now].host.test(location.hostname)) {
  6403. if (self != top) {if (!DBSite[now].iframe) break;} // 如果当前位于 iframe 框架下,就需要判断是否需要执行
  6404. if (DBSite[now].functionS) {
  6405. DBSite[now].functionS();
  6406. } else {
  6407. curSite = DBSite[now];
  6408. }
  6409. support = true; break; // 如果找到了就退出循环
  6410. }
  6411. } else if (DBSite[now].host === location.hostname) {
  6412. if (self != top) {if (!DBSite[now].iframe) break;} // 如果当前位于 iframe 框架下,就需要判断是否需要执行
  6413. if (DBSite[now].functionS) {
  6414. DBSite[now].functionS();
  6415. } else {
  6416. curSite = DBSite[now];
  6417. }
  6418. support = true; break; // 如果找到了就退出循环
  6419. }
  6420. }
  6421.  
  6422. if (support) {
  6423. console.info('[自动无缝翻页] - 独立规则 网站'); return 1;
  6424. } 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)) {
  6425. console.info('[自动无缝翻页] - <Discuz!> 论坛'); return 2;
  6426. } else if (getCSS('#flarum-loading')) {
  6427. console.info('[自动无缝翻页] - <Flarum> 论坛'); return 3;
  6428. } else if (getCSS('body#phpbb')) {
  6429. console.info('[自动无缝翻页] - <phpBB> 论坛'); return 4;
  6430. } else if (getXpath('//footer//a[contains(string(), "Xiuno")] | //link[contains(@href, "xiuno")] | //script[contains(@src, "xiuno")]')) {
  6431. console.info('[自动无缝翻页] - <Xiuno> 论坛'); return 5;
  6432. } else if (typeof XF != 'undefined') {
  6433. console.info('[自动无缝翻页] - <XenForo> 论坛'); return 6;
  6434. } else if (getCSS('link[href*="themes/dux" i], script[src*="themes/dux" i]')) {
  6435. console.info('[自动无缝翻页] - 使用 WordPress <DUX> 主题的网站'); return 100;
  6436. } else if (getCSS('link[href*="themes/xiu" i], script[src*="themes/xiu" i]')) {
  6437. console.info('[自动无缝翻页] - 使用 WordPress <XIU> 主题的网站'); return 101;
  6438. } else if (getCSS('link[href*="themes/d8" i], script[src*="themes/d8" i]')) {
  6439. console.info('[自动无缝翻页] - 使用 WordPress <D8> 主题的网站'); return 102;
  6440. } else if (getCSS('link[href*="themes/begin" i], script[src*="themes/begin" i], img[src*="themes/begin" i]')) {
  6441. console.info('[自动无缝翻页] - 使用 WordPress <Begin> 主题的网站'); return 103;
  6442. } else if (getCSS('meta[name="description"][content*="小说"], meta[name="description"][content*="章节"], meta[name="description"][content*="阅读"]') && getCSS('#content, #chaptercontent, .chaptercontent, #BookText') && getXpath('//a[contains(text(), "下一章") or contains(text(), "下一页")]')) {
  6443. console.info('[自动无缝翻页] - <笔趣阁> 模板的小说网站'); return 200;
  6444. } else if (self != top) {
  6445. return -1;
  6446. }
  6447. return 0;
  6448. }
  6449.  
  6450.  
  6451. // 翻页类型 1/3
  6452. function getPageElems(url) {
  6453. GM_xmlhttpRequest({
  6454. url: url,
  6455. method: 'GET',
  6456. overrideMimeType: 'text/html; charset=' + document.charset,
  6457. headers: {
  6458. 'Referer': location.href
  6459. },
  6460. timeout: 10000,
  6461. onload: function (response) {
  6462. try {
  6463. //console.log('最终 URL:' + response.finalUrl, '返回内容:' + response.responseText)
  6464. processElems(createDocumentByString(response.responseText));
  6465. } catch (e) {
  6466. console.log(e);
  6467. }
  6468. }
  6469. });
  6470. }
  6471. // 翻页类型 4
  6472. function getPageElems_(url, type = '', method = 'GET', data = '', type2) {
  6473. let mimeType;
  6474. switch (type) {
  6475. case 'json':
  6476. mimeType = 'application/json; charset=' + document.charset; break;
  6477. case 'text':
  6478. mimeType = 'text/plain; charset=' + document.charset; break;
  6479. default:
  6480. mimeType = 'text/html; charset=' + document.charset;
  6481. }
  6482.  
  6483. GM_xmlhttpRequest({
  6484. url: url,
  6485. method: method,
  6486. data: data,
  6487. responseType: type,
  6488. overrideMimeType: mimeType,
  6489. headers: {
  6490. 'Referer': location.href,
  6491. 'Content-Type': (method === 'POST') ? 'application/x-www-form-urlencoded':''
  6492. },
  6493. timeout: 10000,
  6494. onload: function (response) {
  6495. try {
  6496. //console.log('最终 URL:' + response.finalUrl, '返回内容:' + response.responseText)
  6497. switch (type) {
  6498. case 'json':
  6499. curSite.pager.insertE(response.response, type2);
  6500. break;
  6501. case 'text':
  6502. curSite.pager.insertE(response.responseText, type2)
  6503. break;
  6504. default:
  6505. curSite.pager.insertE(createDocumentByString(response.responseText), type2)
  6506. }
  6507. } catch (e) {
  6508. console.log(e);
  6509. }
  6510. }
  6511. });
  6512. }
  6513. // 翻页类型 5(插入 iframe 方式加载下一页)
  6514. function insIframe(src) {
  6515. // 停用当前页面翻页
  6516. if (curSite.SiteTypeID == 0) return
  6517. curSite.SiteTypeID = 0;
  6518.  
  6519. var beforeScrollTop = document.documentElement.scrollTop || document.body.scrollTop
  6520. // 当滚动条到底部时(即完全显示 iframe 框架),隐藏当前页面的滚动条
  6521. window.addEventListener('scroll', function () {
  6522. let scrollTop = document.documentElement.scrollTop || document.body.scrollTop,
  6523. clientHeight = document.documentElement.clientHeight || document.body.clientHeight,
  6524. scrollHeight = document.documentElement.scrollHeight || document.body.scrollHeight,
  6525. afterScrollTop = document.documentElement.scrollTop || document.body.scrollTop,
  6526. delta = afterScrollTop - beforeScrollTop;
  6527. if (delta == 0) return false;
  6528. beforeScrollTop = afterScrollTop;
  6529.  
  6530. //console.log(delta, scrollHeight - (scrollTop + clientHeight + 10), '1111')
  6531. if (delta > 0 && scrollTop + clientHeight + 10 >= scrollHeight && !getCSS('#xiu-scroll')) {
  6532. let newStyle = document.createElement('style'); newStyle.id = 'xiu-scroll';
  6533. newStyle.textContent = 'html::-webkit-scrollbar, body::-webkit-scrollbar {width: 0 !important;height: 0 !important;} html, body {scrollbar-width: none !important;}';
  6534. if (curSite.pager.insStyle) newStyle.textContent += curSite.pager.insStyle;
  6535. document.documentElement.appendChild(newStyle);
  6536. } else if (delta < 0 && getCSS('#xiu-scroll')) {
  6537. getCSS('#xiu-scroll').remove();
  6538. }
  6539. }, false);
  6540.  
  6541. // 创建 iframe
  6542. let iframe = document.createElement('iframe');
  6543. iframe.style = 'position: absolute; width: 100%; height: 100%; border: none;';
  6544. iframe.id = 'xiu_iframe';
  6545. iframe.src = src;
  6546.  
  6547. // 加载完成后才继续
  6548. iframe.onload = function() {
  6549. // 添加历史记录
  6550. if (curSite.history) addHistory(iframe.contentWindow.document, iframe.contentWindow.document.title);
  6551. // 当前页码 + 1
  6552. if (!curSite.hiddenPN) {
  6553. let autopageNumber = getCSS('#Autopage_number', window.top.document)
  6554. if (autopageNumber) {autopageNumber.textContent = parseInt(autopageNumber.textContent) + 1;}
  6555. }
  6556. }
  6557.  
  6558. // 插入 iframe
  6559. document.documentElement.appendChild(iframe);
  6560. }
  6561. // 翻页类型 6(通过 iframe 获取下一页动态加载内容)
  6562. function insIframe_(src) {
  6563. // 暂停翻页
  6564. if (!pausePage) return
  6565. pausePage = false
  6566. console.log(src)
  6567. // 如果不存在,则创建一个 iframe
  6568. let iframe = document.getElementById('xiu_iframe');
  6569. if (!iframe) {
  6570. iframe = document.createElement('iframe');
  6571. iframe.style = 'position: absolute; top: 0px; left: 0px; width: 100%; height: 100%; border: none; z-index: -999; /*visibility: hidden;*/';
  6572. iframe.id = 'xiu_iframe';
  6573. iframe.src = src;
  6574. }
  6575.  
  6576. // 加载完成后才继续
  6577. iframe.onload = function() {
  6578. //iframe.contentWindow.scrollTo(0, 999999); // 滚动到底部,以触发网页的滚动条相关加载事件
  6579. //iframe.contentWindow.scrollTo({top: 9999999, behavior: 'smooth'});
  6580. if (!curSite.pager.loadTime) curSite.pager.loadTime = 100; // 默认 100ms
  6581. //console.log(curSite.pager.loadTime, curSite.pager.loadTime/30)
  6582. //console.time('sort');
  6583. let time1 = 0 ,time2 = setInterval(function(){
  6584. let scrollHeight = (iframe.contentWindow.document.documentElement.scrollHeight || iframe.contentWindow.document.body.scrollHeight)/10
  6585. iframe.contentWindow.scrollTo(0, 999999);
  6586. iframe.contentWindow.scrollTo(0, scrollHeight*time1);
  6587. //console.log(time1, iframe.contentWindow.document.documentElement.scrollHeight || iframe.contentWindow.document.body.scrollHeight)
  6588. if (++time1 == 10) {
  6589. //console.timeEnd('sort');
  6590. clearInterval(time2);
  6591. processElems(iframe.contentWindow.document); // 插入/替换元素等
  6592. //console.log(iframe.contentWindow.document.documentElement.scrollHeight || iframe.contentWindow.document.body.scrollHeight)
  6593. pausePage = true; // 恢复翻页
  6594. }
  6595. }, curSite.pager.loadTime/10)
  6596. }
  6597.  
  6598. // 插入 iframe(如果已存在则直接改 src)
  6599. if (document.getElementById('xiu_iframe')) {
  6600. iframe.src = src;
  6601. } else {
  6602. document.documentElement.appendChild(iframe);
  6603. }
  6604. }
  6605.  
  6606.  
  6607. // XHR 后处理结果,插入、替换元素等(适用于翻页类型 1/3/6)
  6608. function processElems(response) {
  6609. if (!curSite.pager.insertP) {curSite.pager.insertP = [curSite.pager.pageE, 5]}
  6610. let pageElems = getAll(curSite.pager.pageE, response, response), toElement;
  6611. if (curSite.pager.insertP[1] === 5) { // 插入 pageE 列表最后一个元素的后面
  6612. toElement = getAll(curSite.pager.insertP[0]).pop();
  6613. } else {
  6614. toElement = getOne(curSite.pager.insertP[0]);
  6615. }
  6616. //console.log(curSite.pager.pageE, pageElems, curSite.pager.insertP, toElement)
  6617.  
  6618. if (pageElems.length > 0 && toElement) {
  6619. // 如果有插入前函数就执行函数
  6620. if (curSite.function && curSite.function.bF) {
  6621. if (curSite.function.pF) { // 如果指定了参数
  6622. pageElems = curSite.function.bF(pageElems, curSite.function.pF);
  6623. } else {
  6624. pageElems = curSite.function.bF(pageElems);
  6625. }
  6626. }
  6627.  
  6628. // 插入位置
  6629. let addTo = getAddTo(curSite.pager.insertP[1]);
  6630.  
  6631. // 插入新页面元素
  6632. if (curSite.pager.insertP[1] === 6) { // 插入到目标内部末尾(针对文本,比如小说网页)
  6633. let afterend = '';
  6634. pageElems.forEach(function (one) {afterend += one.innerHTML;});
  6635. toElement.insertAdjacentHTML(addTo, afterend);
  6636. } else {
  6637. if (curSite.pager.insertP[1] === 2 || curSite.pager.insertP[1] === 4 || curSite.pager.insertP[1] === 5) pageElems.reverse(); // 插入到 [元素内头部]、[目标本身后面] 时,需要反转顺序
  6638. pageElems.forEach(function (one) {toElement.insertAdjacentElement(addTo, one);});
  6639. }
  6640.  
  6641. // 当前页码 + 1
  6642. pageNum.now = pageNum._now + 1
  6643.  
  6644. // 插入 <script> 标签
  6645. if (curSite.pager.scriptT || curSite.pager.scriptT == 0) {
  6646. switch (curSite.pager.scriptT) {
  6647. case 0: // 下一页的所有 <script> 标签
  6648. insScript('css;script', toElement, response); break;
  6649. case 1: // 下一页的所有 <script> 标签(不包括 src 链接)
  6650. insScript('css;script:not([src])', toElement, response); break;
  6651. case 2: // 下一页主体元素 (pageE) 的同级 <script> 标签
  6652. insScript(null, toElement, pageElems); break;
  6653. case 3: // 下一页主体元素 (pageE) 的子元素 <script> 标签
  6654. insScript('css;script:not([src])', toElement, pageElems); break;
  6655. }
  6656. }
  6657.  
  6658. // 添加历史记录
  6659. if (curSite.history) addHistory(response);
  6660.  
  6661. // 替换待替换元素
  6662. if (curSite.pager.replaceE) replaceElems(response);
  6663.  
  6664. // 如果有插入后函数就执行函数
  6665. if (curSite.function && curSite.function.aF) {
  6666. if (curSite.function.pF) { // 如果指定了参数
  6667. curSite.function.aF(curSite.function.pF);
  6668. } else {
  6669. curSite.function.aF();
  6670. }
  6671. }
  6672. } else { // 获取主体元素失败后,尝试重新获取
  6673. if (curSite.retry) {
  6674. setTimeout(function(){curSite.pageUrl = '';}, curSite.retry)
  6675. } else { // 尝试替换元素看能不能继续翻页下去
  6676. if (curSite.pager.replaceE) {
  6677. if (replaceElems(response)) { // 如果替换成功
  6678. pageNum.now = pageNum._now + 1; // 当前页码 + 1
  6679. if (curSite.history) addHistory(response); // 添加历史记录
  6680. }
  6681. }
  6682. }
  6683. }
  6684. }
  6685. // 通用型插入前函数(加载图片)
  6686. function src_bF(pageElems, css) {
  6687. pageElems.forEach(function (one) {
  6688. if (css[0] == 0) { // src 图片
  6689. one.querySelectorAll(css[1]).forEach(function (now) {
  6690. now.src = now.getAttribute(css[2]);
  6691. });
  6692. } else if (css[0] == 1) { // 背景图片
  6693. one.querySelectorAll(css[1]).forEach(function (now) {
  6694. now.style.backgroundImage = 'url("' + now.getAttribute(css[2]) + '")';
  6695. });
  6696. }
  6697. });
  6698. return pageElems
  6699. }
  6700. // 通用型获取下一页地址(URL 替换 page= 参数)
  6701. function getNextP(css, pf, reg) {
  6702. let nextNum = getOne(css);
  6703. var url = '';
  6704. if (nextNum && nextNum.textContent) {
  6705. nextNum = nextNum.textContent.replaceAll(' ','');
  6706. if (location.search) {
  6707. if (indexOF(pf, 's')) {
  6708. url = location.search.replace(reg, pf + nextNum);
  6709. } else {
  6710. url = location.search + '&' + pf + nextNum;
  6711. }
  6712. } else {
  6713. url = '?' + pf + nextNum;
  6714. }
  6715. url = location.origin + location.pathname + url;
  6716. }
  6717. return url
  6718. }
  6719. // 通用型获取下一页地址(直接从元素获取)
  6720. function getNextE(css) {
  6721. if (!css) css = curSite.pager.nextL;
  6722. let next = getOne(css)
  6723. if (next && next.nodeType === 1 && next.href && next.href.slice(0,4) === 'http' && next.href != curSite.pageUrl) {
  6724. if (curSite.pager.forceHTTPS && location.protocol === 'https:') {
  6725. curSite.pageUrl = next.href.replace(/^http:/,'https:');
  6726. } else {
  6727. curSite.pageUrl = next.href;
  6728. }
  6729. //console.log(curSite.pageUrl)
  6730. return true
  6731. }
  6732. return false
  6733. }
  6734. // 检查 URL
  6735. function checkURL(func) {
  6736. if (typeof curSite.pager.nextL == 'function') {
  6737. let tempUrl = curSite.pager.nextL();
  6738. if (!tempUrl || (tempUrl && tempUrl.slice(0,4) != 'http') || tempUrl === curSite.pageUrl ) return;
  6739. curSite.pageUrl = tempUrl;
  6740. func(curSite.pageUrl);
  6741. } else if (getNextE()) {
  6742. func(curSite.pageUrl);
  6743. }
  6744. //console.log(curSite.pageUrl);
  6745. }
  6746. // 替换元素
  6747. function replaceElems(pageElems, o = curSite.pager.replaceE, r = curSite.pager.replaceE) {
  6748. let oriE = getAll(o),
  6749. repE = getAll(r, pageElems, pageElems);
  6750. //console.log(oriE, repE)
  6751. if (oriE.length != 0 && repE.length != 0 && oriE.length === repE.length) {
  6752. for (let i = 0; i < oriE.length; i++) {
  6753. oriE[i].outerHTML = repE[i].outerHTML;
  6754. }
  6755. return true
  6756. }
  6757. return false
  6758. }
  6759. // 添加历史记录
  6760. function addHistory(pageElems, title, url) {
  6761. if (!curSite.pageUrl) return
  6762. title = title || pageElems.querySelector('title').textContent || window.top.document.title;
  6763. url = url || curSite.pageUrl;
  6764. window.top.document.title = title;
  6765. window.top.document.xiu_nowUrl = curSite.pageUrl;
  6766. window.top.history.pushState('xiu_history', title, url);
  6767. }
  6768. // 插入 <Script>
  6769. function insScript(selector, toElement = document.body, contextNode = document) {
  6770. let scriptElems = contextNode;
  6771. if (selector) {
  6772. if (contextNode instanceof Array) {
  6773. scriptElems = []; contextNode.forEach(function (one) {scriptElems = scriptElems.concat(getAll(selector, one, one));})
  6774. } else {
  6775. scriptElems = getAll(selector, contextNode, contextNode);
  6776. }
  6777. }
  6778. scriptElems.forEach(function (one) {
  6779. if (one.tagName === 'SCRIPT') {
  6780. if (one.src) {
  6781. toElement.appendChild(document.createElement('script')).src = one.src;
  6782. } else {
  6783. toElement.appendChild(document.createElement('script')).textContent = one.textContent;
  6784. }
  6785. }
  6786. });
  6787. }
  6788. // 插入 <Style>
  6789. function insStyle(style) {
  6790. document.documentElement.appendChild(document.createElement('style')).textContent = style;
  6791. }
  6792.  
  6793.  
  6794. // 获取元素(CSS/Xpath)来自:https://github.com/machsix/Super-preloader
  6795. function getCSS(css, contextNode = document) {
  6796. return contextNode.querySelector(css);
  6797. }
  6798. function getAllCSS(css, contextNode = document) {
  6799. return [].slice.call(contextNode.querySelectorAll(css));
  6800. }
  6801. function getXpath(xpath, contextNode, doc = document) {
  6802. contextNode = contextNode || doc;
  6803. try {
  6804. const result = doc.evaluate(xpath, contextNode, null, XPathResult.FIRST_ORDERED_NODE_TYPE, null);
  6805. // 应该总是返回一个元素节点
  6806. return result.singleNodeValue && result.singleNodeValue.nodeType === 1 && result.singleNodeValue;
  6807. } catch (err) {
  6808. throw new Error(`无效 Xpath: ${xpath}`);
  6809. }
  6810. }
  6811. function getAllXpath(xpath, contextNode, doc = document) {
  6812. contextNode = contextNode || doc;
  6813. const result = [];
  6814. try {
  6815. const query = doc.evaluate(xpath, contextNode, null, XPathResult.ORDERED_NODE_SNAPSHOT_TYPE, null);
  6816. for (let i = 0; i < query.snapshotLength; i++) {
  6817. const node = query.snapshotItem(i);
  6818. // 如果是 Element 节点
  6819. if (node.nodeType === 1) result.push(node);
  6820. }
  6821. } catch (err) {
  6822. throw new Error(`无效 Xpath: ${xpath}`);
  6823. }
  6824. return result;
  6825. }
  6826. function getOne(selector, contextNode = undefined, doc = document) {
  6827. if (!selector) return;
  6828. contextNode = contextNode || doc;
  6829. if (selector.search(/^css;/i) === 0) {
  6830. return getCSS(selector.slice(4), contextNode);
  6831. } else {
  6832. return getXpath(selector, contextNode, doc);
  6833. }
  6834. }
  6835. function getAll(selector, contextNode = undefined, doc = document) {
  6836. if (!selector) return [];
  6837. contextNode = contextNode || doc;
  6838. if (selector.search(/^css;/i) === 0) {
  6839. return getAllCSS(selector.slice(4), contextNode);
  6840. } else {
  6841. return getAllXpath(selector, contextNode, doc);
  6842. }
  6843. }
  6844. function createDocumentByString(e) {
  6845. if (e) {
  6846. if ('HTML' !== document.documentElement.nodeName) return (new DOMParser).parseFromString(e, 'application/xhtml+xml');
  6847. var t;
  6848. try { t = (new DOMParser).parseFromString(e, 'text/html');} catch (e) {}
  6849. if (t) return t;
  6850. if (document.implementation.createHTMLDocument) {
  6851. t = document.implementation.createHTMLDocument('ADocument');
  6852. } else {
  6853. 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) {}
  6854. }
  6855. if (t) {
  6856. var r = document.createRange(),
  6857. n = r.createContextualFragment(e);
  6858. r.selectNodeContents(document.body);
  6859. t.body.appendChild(n);
  6860. 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);
  6861. return t;
  6862. }
  6863. } else console.error('没有找到要转成 DOM 的字符串');
  6864. }
  6865.  
  6866.  
  6867. // 强制新标签页打开链接(翻页模式 5/6)
  6868. function forceTarget() {
  6869. document.body.addEventListener('click', function(e) {
  6870. if (e.target.tagName === 'A') {
  6871. forceTarget_(e.target, e);
  6872. } else {
  6873. let path = e.path || e.composedPath();
  6874. for (let i = 1; i < path.length - 3; i++) {
  6875. //console.log(path[i])
  6876. if (path[i].tagName === 'A') {
  6877. forceTarget_(path[i], e);
  6878. break;
  6879. }
  6880. }
  6881. }
  6882. });
  6883.  
  6884. function forceTarget_(target, e){
  6885. if (target.href && target.target != '_blank' && !(target.getAttribute('onclick')) && target.href.slice(0,4) == 'http' && target.getAttribute('href').slice(0,1) != '#') {
  6886. e.preventDefault(); // 阻止默认打开链接事件
  6887. //console.log(target.href);
  6888. //window.top.location.href = target.href;
  6889. window.GM_openInTab(target.href, {active: true,insert: true,setParent: true});
  6890. }
  6891. }
  6892. //document.head.appendChild(document.createElement('base')).target = '_top';
  6893. }
  6894. // 判断元素是否隐藏(隐藏返回 true)
  6895. function isHidden(el){
  6896. return (el.offsetParent === null);
  6897. }
  6898. // 判断 URL 是否存在指定文本
  6899. function indexOF(e, l = 'p', low = false){
  6900. switch (l) {
  6901. case 'h':
  6902. l = location.href; break;
  6903. case 'p':
  6904. l = location.pathname; break;
  6905. case 's':
  6906. l = location.search; break;
  6907. }
  6908. //console.log(l,e,l.indexOf(e))
  6909. if (low) {e = e.toLowerCase(); l = l.toLowerCase();} // 全部转为小写
  6910. if (e instanceof RegExp) {
  6911. if (e.test(l)) return true
  6912. } else {
  6913. if (l.indexOf(e) > -1) return true
  6914. }
  6915. return false
  6916. }
  6917. // 启用/禁用 (当前网站)
  6918. function menu_disable(type) {
  6919. switch(type) {
  6920. case 'check':
  6921. return check(); break;
  6922. case 'add':
  6923. add(); break;
  6924. case 'del':
  6925. del(); break;
  6926. }
  6927.  
  6928. function check() { // 存在返回真,不存在返回假
  6929. if (GM_getValue('menu_disable').indexOf(location.hostname) == -1) return false // 不存在返回假
  6930. return true
  6931. }
  6932.  
  6933. function add() {
  6934. if (check()) return
  6935. let list = GM_getValue('menu_disable'); // 读取网站列表
  6936. list.push(location.hostname); // 追加网站域名
  6937. GM_setValue('menu_disable', list); // 写入配置
  6938. location.reload(); // 刷新网页
  6939. }
  6940.  
  6941. function del() {
  6942. if (!check()) return
  6943. let list = GM_getValue('menu_disable'), // 读取网站列表
  6944. index = list.indexOf(location.hostname);
  6945. list.splice(index, 1); // 删除网站域名
  6946. GM_setValue('menu_disable', list); // 写入配置
  6947. location.reload(); // 刷新网页
  6948. }
  6949. }
  6950. // 左键双击网页空白处暂停翻页
  6951. function pausePageEvent() {
  6952. if (!GM_getValue('menu_pause_page')) return
  6953. if (curSite.SiteTypeID === 0) return
  6954. if (curSite.pager && curSite.pager.type == 5) window.top.document.xiu_pausePage = pausePage
  6955. document.body.addEventListener('dblclick', function () {
  6956. if (pausePage) {GM_notification({text: `❌ 已暂停本页 [自动无缝翻页]\n (再次双击可恢复)`, timeout: 2000});} else {GM_notification({text: `✅ 已恢复本页 [自动无缝翻页]\n (再次双击可暂停)`, timeout: 2000});}
  6957. pausePage = !pausePage;
  6958. if (curSite.pager && curSite.pager.type == 5) window.top.document.xiu_pausePage = pausePage
  6959. });
  6960. }
  6961. // 显示页码
  6962. function pageNumber(type) {
  6963. 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}
  6964. let status = getCSS('#Autopage_number');
  6965. switch (type) {
  6966. case 'add':
  6967. add(); break;
  6968. case 'del':
  6969. del(); break;
  6970. case 'set':
  6971. set(); break;
  6972. }
  6973.  
  6974. function add(){
  6975. if (status) {
  6976. if (status.style.display === 'none') {status.style.display = 'flex';}
  6977. return
  6978. }
  6979. // 插入网页
  6980. let _html = `<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>
  6981. <div id="Autopage_number" title="1. 此处数字为 [当前页码] (可在脚本菜单中关闭)&#10;&#10;2. 鼠标左键点击此处 [临时暂停本页自动无缝翻页](再次点击可恢复)">${pageNum._now}</div>`
  6982. document.documentElement.insertAdjacentHTML('beforeend', _html);
  6983. if (curSite.pager && curSite.pager.type == 5) window.top.document.xiu_pausePage = pausePage
  6984. // 点击事件(临时暂停翻页)
  6985. getCSS('#Autopage_number').onclick = function () {
  6986. if (pausePage) {this.style = 'color: #FF5722 !important; font-style: italic !important;';} else {this.style = '';}
  6987. pausePage = !pausePage;
  6988. if (curSite.pager && curSite.pager.type == 5) window.top.document.xiu_pausePage = pausePage
  6989. };
  6990. status = getCSS('#Autopage_number');
  6991. set();
  6992. }
  6993. // 监听储存当前页码的对象值的变化
  6994. function set(){
  6995. Object.defineProperty(pageNum, 'now', {
  6996. set: function(value) {
  6997. this._now = value;
  6998. if (status) status.textContent = value;
  6999. }
  7000. });
  7001. }
  7002. function del(){
  7003. if (!status) return
  7004. status.style.display = 'none';
  7005. }
  7006. }
  7007. // 菜单开关
  7008. function menu_switch(menu_status, Name, Tips) {
  7009. if (menu_status === true){
  7010. GM_setValue(Name, false);
  7011. } else {
  7012. GM_setValue(Name, true);
  7013. }
  7014. if (Name === 'menu_page_number') {
  7015. if (menu_status === true){pageNumber('del');} else {pageNumber('add');}
  7016. registerMenuCommand(); // 重新注册脚本菜单
  7017. } else {
  7018. location.reload();}
  7019. };
  7020. // 生成 SiteTypeID
  7021. function setSiteTypeID() {
  7022. let num = 0
  7023. for (let val in DBSite) {
  7024. DBSite[val].SiteTypeID = num = num + 1;
  7025. }
  7026. }
  7027. // 获取 Cookie
  7028. function getCookie(name) {
  7029. if (!name) return ''
  7030. let arr = document.cookie.split(';');
  7031. name += '='
  7032. for (let i=0; i<arr.length; i++) {
  7033. let now = arr[i].trim();
  7034. if (now.indexOf(name) == 0) return now.substring(name.length, now.length);
  7035. }
  7036. return '';
  7037. }
  7038. // 插入位置
  7039. function getAddTo(num) {
  7040. switch (num) {
  7041. case 1:
  7042. return 'beforebegin'; break;
  7043. case 2:
  7044. return 'afterbegin'; break;
  7045. case 3:
  7046. case 6:
  7047. return 'beforeend'; break;
  7048. case 4:
  7049. case 5:
  7050. return 'afterend'; break;
  7051. }
  7052. }
  7053. // 滚动条事件
  7054. function windowScroll(fn1) {
  7055. var beforeScrollTop = document.documentElement.scrollTop || document.body.scrollTop,
  7056. fn = fn1 || function () {};
  7057. setTimeout(function () { // 延时 1 秒执行,避免刚载入到页面就触发翻页事件
  7058. window.addEventListener('scroll', function (e) {
  7059. var afterScrollTop = document.documentElement.scrollTop || document.body.scrollTop,
  7060. delta = afterScrollTop - beforeScrollTop;
  7061. if (delta == 0) return false;
  7062. fn(delta > 0 ? 'down' : 'up', e);
  7063. beforeScrollTop = afterScrollTop;
  7064. }, false);
  7065. }, 1000)
  7066. }
  7067. // 自定义 locationChange 事件(用来监听 URL 变化)
  7068. function addLocationchange() {
  7069. history.pushState = ( f => function pushState(){
  7070. var ret = f.apply(this, arguments);
  7071. window.dispatchEvent(new Event('pushstate'));
  7072. window.dispatchEvent(new Event('locationChange'));
  7073. return ret;
  7074. })(history.pushState);
  7075.  
  7076. history.replaceState = ( f => function replaceState(){
  7077. var ret = f.apply(this, arguments);
  7078. window.dispatchEvent(new Event('replacestate'));
  7079. window.dispatchEvent(new Event('locationChange'));
  7080. return ret;
  7081. })(history.replaceState);
  7082.  
  7083. window.addEventListener('popstate',()=>{
  7084. window.dispatchEvent(new Event('locationChange'))
  7085. });
  7086. }
  7087. })();