EasyCSDN

这是一款提高CSDN简洁度的插件。它可以让你的CSDN学习之路变得简洁、专注、高效、畅快。主要功能是净化页面,净化99%多余元素,只展示文章正文和关联文章。

As of 2023-11-25. See the latest version.

  1. // ==UserScript==
  2. // @name EasyCSDN
  3. // @description 这是一款提高CSDN简洁度的插件。它可以让你的CSDN学习之路变得简洁、专注、高效、畅快。主要功能是净化页面,净化99%多余元素,只展示文章正文和关联文章。
  4. // @version 9.0
  5. // @author xcanwin
  6. // @namespace https://github.com/xcanwin/EasyCSDN/
  7. // @supportURL https://github.com/xcanwin/EasyCSDN/
  8. // @license GPL-2.0-only
  9. // @match *://blog.csdn.net/*/article/details/*
  10. // @match *://*.blog.csdn.net/article/details/*
  11. // @grant GM_addStyle
  12. // @run-at document-start
  13. // ==/UserScript==
  14.  
  15. (function() {
  16. 'use strict';
  17.  
  18. /*电脑端*/
  19. GM_addStyle(`
  20. .passport-login-container /*隐藏登录提示*/,
  21. .passport-login-tip-container /*隐藏登录权益提示*/,
  22. #toolbarBox /*隐藏顶部*/,
  23. .blog_container_aside /*隐藏左边栏*/,
  24. #rightAside /*隐藏右边栏*/,
  25. .csdn-side-toolbar /*隐藏右边栏-磁吸*/,
  26. .blog-footer-bottom /*隐藏底部*/,
  27. .recommend-nps-box /*隐藏打分*/,
  28. .left-toolbox /*隐藏关注*/,
  29. .blog-tags-box /*隐藏开头的专栏收录*/,
  30. #blogColumnPayAdvert /*隐藏结尾的专栏收录*/,
  31. #treeSkill /*隐藏技能树*/,
  32. code .hljs-button /*隐藏复制提示*/,
  33. .article-search-tip /*隐藏正文搜索提示*/
  34. {
  35. display: none !important;
  36. }
  37.  
  38. /*隐藏背景*/
  39. body {
  40. background: none !important;
  41. background-image: unset !important;
  42. background-color: #ffebeb !important;
  43. }
  44.  
  45. /*正文居中*/
  46. #mainBox {
  47. display: flex;
  48. justify-content: center;
  49. }
  50.  
  51. /*展示全屏*/
  52. #mainBox, #mainBox main {
  53. width: 100%;
  54. margin-bottom: unset !important;
  55. }
  56. .main_father {
  57. padding: unset !important;
  58. }
  59. .main_father.d-flex {
  60. display: unset !important;
  61. }
  62.  
  63. /*展示分界线*/
  64. #toolBarBox {
  65. margin-bottom: 64px !important;
  66. }
  67. `);
  68.  
  69. /*移动端*/
  70. GM_addStyle(`
  71. #csdn-toolbar /*隐藏顶部*/,
  72. #operate /*隐藏底部评论和搜索提示*/,
  73. .aside-header-fixed /*隐藏关注*/
  74. {
  75. display: none !important;
  76. }
  77.  
  78. /*展示全屏*/
  79. body #main {
  80. padding-top: unset !important;
  81. margin-top: unset !important;
  82. }
  83. body {
  84. padding-bottom: unset !important;
  85. }
  86.  
  87. /*展示分界线*/
  88. .spec_space {
  89. background-color: #ffebeb !important;
  90. height: 32px !important;
  91. }
  92.  
  93. `);
  94.  
  95. })();