Easyv水印隐藏

Hide the watermark on the page

您需要先安裝使用者腳本管理器擴展,如 TampermonkeyGreasemonkeyViolentmonkey 之後才能安裝該腳本。

您需要先安裝使用者腳本管理器擴充功能,如 TampermonkeyViolentmonkey 後才能安裝該腳本。

您需要先安裝使用者腳本管理器擴充功能,如 TampermonkeyViolentmonkey 後才能安裝該腳本。

您需要先安裝使用者腳本管理器擴充功能,如 TampermonkeyUserscripts 後才能安裝該腳本。

你需要先安裝一款使用者腳本管理器擴展,比如 Tampermonkey,才能安裝此腳本

您需要先安裝使用者腳本管理器擴充功能後才能安裝該腳本。

(我已經安裝了使用者腳本管理器,讓我安裝!)

你需要先安裝一款使用者樣式管理器擴展,比如 Stylus,才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展,比如 Stylus,才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展,比如 Stylus,才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展後才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展後才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展後才能安裝此樣式

(我已經安裝了使用者樣式管理器,讓我安裝!)

// ==UserScript==
// @name         Easyv水印隐藏
// @namespace    http://tampermonkey.net/
// @version      0.3
// @description  Hide the watermark on the page
// @author       Your Name
// @match        https://workspace.easyv.cloud/*
// @grant        none
// ==/UserScript==

(function() {
    'use strict';

    // 创建一个观察者来监测 DOM 变化
    const observer = new MutationObserver((mutations) => {
        mutations.forEach((mutation) => {
            // 隐藏水印
            const watermark = document.querySelector('.index__canvas--Za5X5');
            if (watermark) {
                watermark.style.display = 'none'; // 隐藏水印
            }
            // 隐藏额外的元素
            const trialElement = document.querySelector('.index__trial--MHQvd');
            if (trialElement) {
                trialElement.style.display = 'none'; // 隐藏指定元素
            }
        });
    });

    // 开始观察页面的变化
    observer.observe(document.body, { childList: true, subtree: true });

    // 页面加载时隐藏水印和其他元素
    window.addEventListener('load', function() {
        const watermark = document.querySelector('.index__canvas--Za5X5');
        if (watermark) {
            watermark.style.display = 'none'; // 隐藏水印
        }
        const trialElement = document.querySelector('.index__trial--MHQvd');
        if (trialElement) {
            trialElement.style.display = 'none'; // 隐藏指定元素
        }
    });
})();