Close Zoom Tabs!

make you not have to click the button to close like 100 zoom tabs that get opened every day!

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

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

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ć!)

Advertisement:

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ć!)

Advertisement:

// ==UserScript==
// @name         Close Zoom Tabs!
// @namespace    http://tampermonkey.net/
// @version      0.1
// @description  make you not have to click the button to close like 100 zoom tabs that get opened every day!
//               especially now that chrome has re-added the checkbox to auto-open zoom, this makes it a 0-effort
//               process - to click a zoom link, then just click the "join with video" button.  
//               Note:  If your company has a custom zoom domain, you may need to add a second @match line for it
//               e.g., https://mycompany.zoom.us/j/*
// @author       Darin Kelkhoff
// @match        https://zoom.us/j/*
// @grant        window.close
// ==/UserScript==

(function() {
    'use strict';

    function makeTransparent(selector)
    {
        try // try, in case element isn't found in dom
        {
            document.querySelector(selector).style.background = "transparent";
        }
        catch(e) {}
    }

    function fadeToBlack()
    {
        console.log("starting fade to black");
        makeTransparent('#header_container');
        makeTransparent('[role="main"]');
        makeTransparent('#zoom-ui-frame');

        document.querySelector('body').style.transition = "all 4s linear";
        document.querySelector('body').style.backgroundColor = "black";
    }

    function close()
    {
        console.log("time to close the zoom window now");
        window.close();
    }

    setTimeout(fadeToBlack, 1000); // wait a second for elements to be in dom
    setTimeout(close, 5*1000); // wait a few seconds, to make sure zoom opened.

})();