Skip to content

Commit fc0a9d1

Browse files
committed
添加 自定义翻页规则界面关于 fun.isPager() 的示例说明
1 parent b003c93 commit fc0a9d1

1 file changed

Lines changed: 11 additions & 1 deletion

File tree

Autopage.user.js

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2696,7 +2696,7 @@ function: {
26962696
<pre style="white-space: pre-wrap;user-select: auto;">
26972697
// 下面示例是把所有规则都塞进去了,但实际上大部分都用不上,大多数网站只需要像第一个 "aaa" 这样的规则(replaceE 规则可以省略,脚本会自动判断)
26982698
// "aaa" 是规则名,唯一!如果和 外置规则名 重复,则会将完全覆盖同名的外置规则,支持中文等各种字符
2699-
// "url" 是用来控制哪些网站中页面适用该规则,省略后代表该规则应用于全站
2699+
// "url" 是用来控制哪些网站中页面适用该规则,省略后代表该规则应用于全站(如果不知道写什么,那么就写 fun.isPager() 这样脚本会自动匹配当前网站下存在 nextL 及 pageE 元素的网页,大部分网站是没问题的)
27002700
// "replaceE" 省略后将会自动判断是替换 nextL 元素还是 nextL 的父元素(当 nextL 元素后面或前面有 <a> 的相邻兄弟元素时替换其父元素,反之替换其自身,仅限模式1/3/6,且 js 代码除外),值为空 "" 时则完全不替换
27012701
// "scrollD" 是用来控制翻页敏感度的(越大就越早触发翻页,访问速度慢的网站需要调大,可省略(注意逗号),默认 2000)
27022702
@@ -2742,6 +2742,16 @@ function: {
27422742
"aF": "document.body.appendChild(document.createElement('script')).textContent = 'xxx'"
27432743
}
27442744
},
2745+
"如果 url 不会写,那就直接写 fun.isPager() 这样脚本会自动匹配当前网站下存在 nextL 及 pageE 元素的网页": {
2746+
"host": "cccc",
2747+
"url": "fun.isPager()",
2748+
"pager": {
2749+
"nextL": "xxxx",
2750+
"pageE": "xxxx",
2751+
"replaceE": "xxxx",
2752+
"scrollD": 2000
2753+
}
2754+
},
27452755
"这里也可以用中文": {
27462756
"host": "/\\.ccc\\.com/",
27472757
"url": "fun.isUrlC(); return (fun.lp() == '/' || fun.indexOF('/s') || fun.isMobile())",

0 commit comments

Comments
 (0)