Fix WebEx

Improve WebEx Browser Events!

2020-11-06 या दिनांकाला. सर्वात नवीन आवृत्ती पाहा.

ही स्क्रिप्ट इंस्टॉल करण्यासाठी तुम्हाला Tampermonkey, Greasemonkey किंवा Violentmonkey यासारखे एक्स्टेंशन इंस्टॉल करावे लागेल.

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

ही स्क्रिप्ट इंस्टॉल करण्यासाठी तुम्हाला Tampermonkey किंवा Violentmonkey यासारखे एक्स्टेंशन इंस्टॉल करावे लागेल..

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

ही स्क्रिप्ट इंस्टॉल करण्यासाठी तुम्हाला Tampermonkey यासारखे एक्स्टेंशन इंस्टॉल करावे लागेल..

ही स्क्रिप्ट इंस्टॉल करण्यासाठी तुम्हाला एक युझर स्क्रिप्ट व्यवस्थापक एक्स्टेंशन इंस्टॉल करावे लागेल.

(माझ्याकडे आधीच युझर स्क्रिप्ट व्यवस्थापक आहे, मला इंस्टॉल करू द्या!)

ही स्टाईल इंस्टॉल करण्यासाठी तुम्हाला Stylus सारखे एक्स्टेंशन इंस्टॉल करावे लागेल.

ही स्टाईल इंस्टॉल करण्यासाठी तुम्हाला Stylus सारखे एक्स्टेंशन इंस्टॉल करावे लागेल.

ही स्टाईल इंस्टॉल करण्यासाठी तुम्हाला Stylus सारखे एक्स्टेंशन इंस्टॉल करावे लागेल.

ही स्टाईल इंस्टॉल करण्यासाठी तुम्हाला एक युझर स्टाईल व्यवस्थापक इंस्टॉल करावे लागेल.

ही स्टाईल इंस्टॉल करण्यासाठी तुम्हाला एक युझर स्टाईल व्यवस्थापक इंस्टॉल करावे लागेल.

ही स्टाईल इंस्टॉल करण्यासाठी तुम्हाला एक युझर स्टाईल व्यवस्थापक इंस्टॉल करावे लागेल.

(माझ्याकडे आधीच युझर स्टाईल व्यवस्थापक आहे, मला इंस्टॉल करू द्या!)

// ==UserScript==
// @name         Fix WebEx
// @namespace    http://tampermonkey.net/
// @version      0.9
// @description  Improve WebEx Browser Events!
// @author       You
// @match        https://*.webex.com/ec3300/*
// @grant        GM_addStyle
// @require      https://cdn.jsdelivr.net/gh/jonlabelle/cookie-js@0164446481bebb3bb283024f3b1aea1fe80a9d9b/Cookie.min.js
// @require      https://cdnjs.cloudflare.com/ajax/libs/arrive/2.4.1/arrive.min.js
// ==/UserScript==
GM_addStyle ( `
#dockdomid {
	opacity: 0;
}
#dockdomid:hover {
	opacity: 1;
	transition: opacity .1s ease-in-out .0s;
}
.share-header-message-CkhKQ {
	display: none;
}
` );

(function() {
    'use strict';

    let firstName = "firstName";
    let lastName = "lastName";
    let email = "email";

    window.onload = () => {
        document.getElementById("ec-btn-joinnow-thin-client").type = "submit";
        document.getElementById("_submit").remove();
        document.getElementsByName(firstName)[0].value = Cookie.get(firstName);
        document.getElementsByName(lastName)[0].value = Cookie.get(lastName);
        document.getElementsByName(email)[0].value = Cookie.get(email);

        document.getElementsByName("JoinActionForm")[0].addEventListener("submit", (e) => {
            Cookie.set(firstName, document.getElementsByName(firstName)[0].value, { expires: 365, sameSite: 'Strict', secure: true });
            Cookie.set(lastName, document.getElementsByName(lastName)[0].value, { expires: 365, sameSite: 'Strict', secure: true });
            Cookie.set(email, document.getElementsByName(email)[0].value, { expires: 365, sameSite: 'Strict', secure: true });
        });


    }

    //Connect to Audio
    let audioSelector = 'button[aria-label="Audio"]';
    let connectSelector = 'button[aria-label="Connect"]';
    let fullscreenSelector = 'button[aria-label="Full screen"]';
    document.arrive(fullscreenSelector, function() {
        document.querySelector(fullscreenSelector).click();
        document.querySelector(audioSelector).click();
    });
    document.arrive(connectSelector, function() {
        setTimeout(function () { //wait for connection
           document.querySelector(connectSelector).click();
        }, 2000);
        Arrive.unbindAllArrive(); //free up memory
    });


})();