Hide Google Meet Visitor Icon

Remove screen space wasting "Visitors are in this meeting" warning icon

当前为 2023-12-07 提交的版本,查看 最新版本

// ==UserScript==
// @name         Hide Google Meet Visitor Icon
// @namespace    https://greasyfork.org/en/users/922168-mark-zinzow
// @version      0.2
// @description  Remove screen space wasting "Visitors are in this meeting" warning icon
// @author       Mark Zinzow
// @match        https://meet.google.com/*
// @match        https://meet.google.com/r*
// @icon         https://www.google.com/s2/favicons?sz=64&domain=google.com
// @supportURL   https://greasyfork.org/en/scripts/481476-hide-google-meet-visitor-icon/feedback
// @license MIT
// @grant none
// @run-at document-end
// ==/UserScript==

(function() {
    'use strict';
    function killIconDiv() {
    const firstDiv = document.querySelector('div[jscontroller="hVZhab"]');
        if (firstDiv) {
          console.log("Div found.");
          firstDiv.remove();
        }
    }
// 0.1 Didn't work unless a visitor was already in the meeting
    for (let i = 0; i < 600 ; i++) { //600 keeps trying to remove this icon every 2 seconds for 20 minutes
    setTimeout(killIconDiv, i*2000);
}
})();