1337x NSFW Hider

Hides 18+ content

Aby zainstalować ten skrypt, wymagana jest instalacje jednego z następujących rozszerzeń: Tampermonkey, Greasemonkey lub Violentmonkey.

Aby zainstalować ten skrypt, wymagana jest instalacje jednego z następujących rozszerzeń: Tampermonkey, Violentmonkey.

Aby zainstalować ten skrypt, wymagana jest instalacje jednego z następujących rozszerzeń: Tampermonkey, Violentmonkey.

Aby zainstalować ten skrypt, wymagana będzie instalacja rozszerzenia Tampermonkey lub Userscripts.

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

Aby zainstalować ten skrypt, musisz zainstalować rozszerzenie menedżera skryptów użytkownika.

(Mam już menedżera skryptów użytkownika, pozwól mi to zainstalować!)

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

Będziesz musiał zainstalować rozszerzenie menedżera stylów użytkownika, aby zainstalować ten styl.

Będziesz musiał zainstalować rozszerzenie menedżera stylów użytkownika, aby zainstalować ten styl.

Musisz zainstalować rozszerzenie menedżera stylów użytkownika, aby zainstalować ten styl.

(Mam już menedżera stylów użytkownika, pozwól mi to zainstalować!)

// ==UserScript==
// @name         1337x NSFW Hider
// @namespace    http://tampermonkey.net/
// @version      2024-12-04
// @description  Hides 18+ content
// @author       DamienKnight
// @match        *.1337x.to/*
// @grant        none
// ==/UserScript==

(function() {
    'use strict';

    // Dictionary of terms to search for (case-insensitive)
    const terms = ["Affair", "Anal", "Ass", "Audition", "BBC", "BFF", "Bitch", "Black", "Bloomer", "Blow", "Boss", "Brat", "Brazzers", "Brother", "Busty", "Caught", "Cheat", "Cheek", "Come", "Commando", "Creampie", "Cum", "Deep", "Delivery", "Desire", "Dick", "Exploit", "Family", "Fuck", "Gangbang", "Girl", "Horny", "Hot", "Husband", "Love", "Lust", "Mature", "MILF", "Mom", "Mother", "Neighbor", "NewSensations", "Office", "Oiled", "Onlyfans", "Passionate", "Perfect", "Perv", "Pussy", "Racy", "Raw", "Rough", "Secret", "Seduce", "Sex", "Sister", "Slick", "Slut", "Squirt", "Step", "Stroke", "Suck", "Swap", "Taboo", "Therapy", "Tight", "Tits", "Wife", "Young", "XXX"];

    // Function to check if href contains any term from the dictionary (case-insensitive)
    const containsTerm = href => terms.some(term => href.toLowerCase().includes(term.toLowerCase()));

    // Hide <li> with links containing any term in the dictionary
    document.querySelectorAll('li a[href]').forEach(link => {
        if (containsTerm(link.href)) {
            link.closest('li').style.display = 'none';
        }
    });

    // Hide <tr> with links containing any term in the dictionary
    document.querySelectorAll('tr a[href]').forEach(link => {
        if (containsTerm(link.href)) {
            link.closest('tr').style.display = 'none';
        }
    });

    // Hide <div> with the class "list-box hidden-sm" (Affiliate Links on the Sidebar)
    document.querySelectorAll('div.list-box.hidden-sm').forEach(div => {
        div.style.display = 'none';
    });

})();