Less Addicting YouTube

Removes some distractions from YouTube with just CSS

// ==UserScript==
// @name         Less Addicting YouTube
// @namespace    http://tampermonkey.net/
// @version      0.5
// @description  Removes some distractions from YouTube with just CSS
// @author       Andrew Rosiclair <git@arosiclair>
// @match        https://www.youtube.com/*
// @icon         https://www.google.com/s2/favicons?sz=64&domain=youtube.com
// @grant        GM_addStyle
// @license      MIT
// ==/UserScript==

(function () {
  "use strict";

  console.log("[Less Addicting Youtube] cleaning");

  const styles = [
    // Hide categories at the top of the homepage
    "ytd-feed-filter-chip-bar-renderer[component-style=\"FEED_FILTER_CHIP_BAR_STYLE_TYPE_DEFAULT\"] { display: none; }",

    // Hide special recommendations like Shorts on the homepage
    "ytd-rich-section-renderer { display: none; }",

    // Hide commenter avatars
    "#author-thumbnail { display: none; }",

    // Hide recommendations at the end of videos
    ".html5-endscreen { display: none; }",

    // Hide recommendations on the side of the video page
    "#secondary { visibility: hidden; }",

    // Adjust the indent on comment replies
    "ytd-comment-replies-renderer { margin-left: 0px; } .expander-header { margin-bottom: 8px; } #expander-contents { margin-left: 24px; } ytd-comment-view-model { margin-bottom: 12px; }",
  ];

  GM_addStyle(styles.join(" "));

  console.log("[Less Addicting Youtube] cleaned");
})();

QingJ © 2025

镜像随时可能失效,请加Q群300939539或关注我们的公众号极客氢云获取最新地址