Anti Filter Bubble

Google anti-filter engine:hide big tech globally, forums & pre-2015 filters search

ही स्क्रिप्ट इंस्टॉल करण्यासाठी तुम्हाला Tampermonkey, Greasemonkey किंवा Violentmonkey यासारखे एक्स्टेंशन इंस्टॉल करावे लागेल.

You will need to install an extension such as Tampermonkey to install this script.

ही स्क्रिप्ट इंस्टॉल करण्यासाठी तुम्हाला Tampermonkey किंवा Violentmonkey यासारखे एक्स्टेंशन इंस्टॉल करावे लागेल..

You will need to install an extension such as Tampermonkey or Userscripts to install this script.

ही स्क्रिप्ट इंस्टॉल करण्यासाठी तुम्हाला Tampermonkey यासारखे एक्स्टेंशन इंस्टॉल करावे लागेल..

ही स्क्रिप्ट इंस्टॉल करण्यासाठी तुम्हाला एक युझर स्क्रिप्ट व्यवस्थापक एक्स्टेंशन इंस्टॉल करावे लागेल.

(माझ्याकडे आधीच युझर स्क्रिप्ट व्यवस्थापक आहे, मला इंस्टॉल करू द्या!)

ही स्टाईल इंस्टॉल करण्यासाठी तुम्हाला Stylus सारखे एक्स्टेंशन इंस्टॉल करावे लागेल.

ही स्टाईल इंस्टॉल करण्यासाठी तुम्हाला Stylus सारखे एक्स्टेंशन इंस्टॉल करावे लागेल.

ही स्टाईल इंस्टॉल करण्यासाठी तुम्हाला Stylus सारखे एक्स्टेंशन इंस्टॉल करावे लागेल.

ही स्टाईल इंस्टॉल करण्यासाठी तुम्हाला एक युझर स्टाईल व्यवस्थापक इंस्टॉल करावे लागेल.

ही स्टाईल इंस्टॉल करण्यासाठी तुम्हाला एक युझर स्टाईल व्यवस्थापक इंस्टॉल करावे लागेल.

ही स्टाईल इंस्टॉल करण्यासाठी तुम्हाला एक युझर स्टाईल व्यवस्थापक इंस्टॉल करावे लागेल.

(माझ्याकडे आधीच युझर स्टाईल व्यवस्थापक आहे, मला इंस्टॉल करू द्या!)

// ==UserScript==
// @name         Anti Filter Bubble 
// @namespace    https://openweb-tools.example
// @version      1.0
// @description  Google anti-filter engine:hide big tech globally, forums & pre-2015 filters search 
// @match        https://www.google.*/*
// @grant        none
// @license      GPL-3.0-or-later
// @run-at       document-idle
// ==/UserScript==

/*
GPL v3
https://www.gnu.org/licenses/gpl-3.0.html
*/

(function () {
'use strict';

if (!location.href.includes("/search")) return;
if (document.getElementById("afb-v5")) return;

/* ---------- STORAGE ---------- */

const STORAGE = {
    hide: "afb_hide_bigtech",
    forums: "afb_forums",
    old: "afb_old"
};

/* ---------- STATE ---------- */

let hide = localStorage.getItem(STORAGE.hide) === "1";
let forums = localStorage.getItem(STORAGE.forums) === "1";
let old = localStorage.getItem(STORAGE.old) === "1";

/* ---------- CONFIG ---------- */

const BLOCK = [
"reddit.com","quora.com","youtube.com",
"facebook.com","instagram.com","tiktok.com",
"twitter.com","x.com","pinterest.com","medium.com"
];

/* ---------- HELPERS ---------- */

function preservePage(u){
    const current = new URL(location.href);
    const start = current.searchParams.get("start");
    if (start) u.searchParams.set("start", start);
}

/* ---------- UI (OFFSET LEFT) ---------- */

const panel = document.createElement("div");
panel.id = "afb-v5";

panel.style = `
position:fixed;
bottom:20px;
right:200px; /* <-- KEY FIX: shifted left from Deep Search Jumper */
z-index:999999;
background:rgba(0,0,0,0.9);
color:#0f0;
padding:10px;
border-radius:10px;
font-family:monospace;
font-size:12px;
box-shadow:0 0 10px rgba(0,0,0,.6);
`;

panel.innerHTML = `
<b>AntiFilter</b><br>

<button id="afb-hide">Hide BigTech</button>
<button id="afb-forum">Forums</button>
<button id="afb-old">Pre2015</button>
`;

document.body.appendChild(panel);

/* ---------- FILTER ---------- */

function applyFilter(){
    if (!hide) return;

    document.querySelectorAll("div.g, div.MjjYud").forEach(el=>{
        const a = el.querySelector("a");
        if (!a) return;

        if (BLOCK.some(d => a.href.includes(d))){
            el.style.display = "none";
        }
    });
}

/* ---------- BUTTONS ---------- */

document.getElementById("afb-hide").onclick = () => {
    hide = !hide;
    localStorage.setItem(STORAGE.hide, hide ? "1" : "0");
    applyFilter();
};

document.getElementById("afb-forum").onclick = () => {
    forums = !forums;
    localStorage.setItem(STORAGE.forums, forums ? "1" : "0");

    const u = new URL(location.href);
    let q = u.searchParams.get("q") || "";

    if (forums && !q.match(/\bforum\b/i)) q += " forum";
    if (!forums) q = q.replace(/\bforum\b/gi,"").trim();

    u.searchParams.set("q", q);
    preservePage(u);

    location.href = u.toString();
};

document.getElementById("afb-old").onclick = () => {
    old = !old;
    localStorage.setItem(STORAGE.old, old ? "1" : "0");

    const u = new URL(location.href);

    if (old){
        u.searchParams.set("tbs","cdr:1,cd_min:1/1/1990,cd_max:12/31/2014");
    } else {
        u.searchParams.delete("tbs");
    }

    preservePage(u);
    location.href = u.toString();
};

/* ---------- AUTO APPLY ---------- */

setInterval(applyFilter, 1200);

})();