FA gear

FA enhancement

目前为 2025-02-02 提交的版本。查看 最新版本

// ==UserScript==
// @name         FA gear
// @namespace    
// @version      0.1
// @description  FA enhancement
// @author       Boni
// @match        https://www.furaffinity.net/msg/submissions/*
// @grant        none
// @license GNU GPLv3
// ==/UserScript==


(function() {
    'use strict';

    window.addEventListener("load", function() {
        document.querySelectorAll(".notifications-by-date").forEach(section => {
            let images = section.querySelectorAll("figure");
            let blockedImages = section.querySelectorAll("img.blocked-content");

            if (images.length === blockedImages.length) {
                // Remove the entire section if all images are blocked
                section.remove();
            } else if (blockedImages.length === 1) {
                // Remove the single blocked image if only one is blocked
                blockedImages[0].closest("figure").remove();
            }
        });
    });
})();