From bdb1fc59cb12461b87e04adf56a364393fc4f928 Mon Sep 17 00:00:00 2001 From: xiu2 <54703944+XIU2@users.noreply.github.com> Date: Mon, 28 Mar 2022 17:05:36 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96=20=E9=A6=96=E9=A1=B5=20-=20?= =?UTF-8?q?=E5=85=B3=E6=B3=A8=E4=B8=8B=E5=8A=9F=E8=83=BD=E4=BB=A3=E7=A0=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Zhihu-Enhanced.user.js | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/Zhihu-Enhanced.user.js b/Zhihu-Enhanced.user.js index 4f37ffa..dd6394e 100644 --- a/Zhihu-Enhanced.user.js +++ b/Zhihu-Enhanced.user.js @@ -3,7 +3,7 @@ // @name:zh-CN 知乎增强 // @name:zh-TW 知乎增強 // @name:en Zhihu enhancement -// @version 2.0.2 +// @version 2.0.3 // @author X.I.U // @description 移除登录弹窗、屏蔽首页视频、默认收起回答、快捷收起回答/评论(左键两侧)、快捷回到顶部(右键两侧)、屏蔽用户、屏蔽关键词、移除高亮链接、屏蔽盐选内容、净化搜索热门、净化标题消息、展开问题描述、显示问题作者、置顶显示时间、完整问题时间、区分问题文章、直达问题按钮、默认高清原图、默认站外直链 // @description:zh-TW 移除登錄彈窗、屏蔽首頁視頻、默認收起回答、快捷收起回答/評論、快捷回到頂部、屏蔽用戶、屏蔽關鍵詞、移除高亮鏈接、屏蔽鹽選內容、淨化搜索熱門、淨化標題消息、置頂顯示時間、完整問題時間、區分問題文章、默認高清原圖、默認站外直鏈... @@ -1468,16 +1468,19 @@ function questionInvitation(){ } else { // 首页 // + // 解决屏蔽类别后,因为首页信息流太少而没有滚动条导致无法加载更多内容的问题 + document.lastElementChild.appendChild(document.createElement('style')).textContent = '.Topstory-container {min-height: 1500px;}'; + collapsedNowAnswer('main div'); // 收起当前回答 + 快捷返回顶部 collapsedNowAnswer('.Topstory-container'); // 收起当前回答 + 快捷返回顶部 setInterval(function(){topTime_('.TopstoryItem', 'ContentItem-meta')}, 300); // 置顶显示时间 addTypeTips(); // 区分问题文章 addToQuestion(); // 直达问题按钮 - blockUsers('index'); // 屏蔽指定用户 - blockKeywords('index'); // 屏蔽指定关键词 - blockType(); // 屏蔽指定类别(视频/文章等) - // 解决屏蔽视频后,因为首页信息流太少而没有滚动条导致无法加载更多内容的问题 - if (menu_value('menu_blockTypeVideo')) document.lastElementChild.appendChild(document.createElement('style')).textContent = '.Topstory-container{min-height: 1500px;}'; + if (location.pathname == '/') { + blockUsers('index'); // 屏蔽指定用户 + blockKeywords('index'); // 屏蔽指定关键词 + blockType(); // 屏蔽指定类别(视频/文章等) + } } } })(); \ No newline at end of file