NOTICE: By continued use of this site you understand and agree to the binding Terms of Service and Privacy Policy.
// ==UserScript== // @name Youtube hide verified // @namespace hide-verified // @author ballerburg9005 // @description hides verified account's videos and all shorts at click of button from search results // @version 1 // @grant none // @include http*://*youtube.*/* // @run-at document-start // @license MIT // ==/UserScript== (function() { 'use strict'; })(); new MutationObserver(function(_,self) { if(document.querySelector("ytd-icon") != null) document.querySelector("ytd-icon").style.padding = "0px"; var renderer = document.querySelector("ytd-topbar-logo-renderer"); if(renderer != null && !renderer.classList.contains('peek-aboo-hide-verified-was-here')) { renderer.classList.add('peek-aboo-hide-verified-was-here'); const script = document.createElement('script'); script.type = "text/javascript"; script.innerHTML = ` function bust_a_nut_verified() { for(el of document.querySelectorAll("ytd-reel-shelf-renderer")) el.style.display = "none"; for(el of document.querySelectorAll("[aria-label='Verified'], [overlay-style='SHORTS'] ")) { var parent = el; for(var i = 0; i < 24; i++) { if(parent != null) { parent = parent.parentElement; if(parent != null && parent.tagName.toLowerCase() == "ytd-video-renderer") break; } } if(parent != null && parent.tagName.toLowerCase() == "ytd-video-renderer") parent.style.display = "none"; } } function measure_verified() { var videos = document.querySelectorAll("ytd-video-renderer").length; var verified_videos = document.querySelectorAll("[aria-label='Verified']").length * 0.5; if(videos > 10 && verified_videos >= videos*0.75) { if(document.querySelector("#peek-aboo-hide-verified-info-box") != null) document.querySelector("#peek-aboo-hide-verified-info-box").innerHTML = "Warning! A high ratio of <i>verified</i> accounts (especially state-funded news outlets) often indicates doctored / censored results."; } else if(document.querySelector("#peek-aboo-hide-verified-info-box") != null) document.querySelector("#peek-aboo-hide-verified-info-box").innerHTML = ""; } setInterval(measure_verified, 200); `; renderer.appendChild(script); renderer.innerHTML += ` <span style='padding: 10px 0px; padding-right: 10px; margin: 4px; display: inline-block;'> <button onclick='setInterval(bust_a_nut_verified, 500);' style="margin: 4px;">hide verified</button> </span> <span style='padding: 10px 0px; margin: 0px; display: inline-block; color: red; min-width: 200px' id="peek-aboo-hide-verified-info-box"> `; } }).observe(document, {childList:true, subtree:true});