Skip to content

Commit 36269a5

Browse files
committed
feat: Add match *://www.zhihu.com/pub/reader/*`, and fix a little style
1 parent a31fb59 commit 36269a5

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

toc-bar.user.js

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010
// @match *://www.jianshu.com/p/*
1111
// @match *://cdn2.jianshu.io/p/*
1212
// @match *://zhuanlan.zhihu.com/p/*
13+
// @match *://www.zhihu.com/pub/reader/*
1314
// @match *://mp.weixin.qq.com/s*
1415
// @match *://cnodejs.org/topic/*
1516
// @match *://*zcfy.cc/article/*
@@ -52,6 +53,10 @@
5253
return location.pathname.startsWith('/p/')
5354
},
5455
},
56+
'www.zhihu.com': {
57+
contentSelector: '.reader-chapter-content',
58+
scrollSmoothOffset: -52,
59+
},
5560
zcfy: {
5661
contentSelector: '.markdown-body',
5762
},
@@ -282,7 +287,7 @@
282287
/* tocbot related */
283288
.toc-bar__toc {
284289
max-height: 80vh;
285-
overflow-y: scroll;
290+
overflow-y: auto;
286291
}
287292
288293
.toc-list-item > a:hover {

0 commit comments

Comments
 (0)