Zoom Records Hotkeys

Add hotkeys for prerecorded zoom videos

You will need to install an extension such as Tampermonkey, Greasemonkey or Violentmonkey to install this script.

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

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

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

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

You will need to install a user script manager extension to install this script.

(I already have a user script manager, let me install it!)

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.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

(I already have a user style manager, let me install it!)

// ==UserScript==
// @name         Zoom Records Hotkeys
// @namespace    https://kyleschwartz.ca
// @version      0.1.1
// @description  Add hotkeys for prerecorded zoom videos
// @author       Kyle Schwartz
// @match        https://*.zoom.us/rec/play/*
// @grant        none
// ==/UserScript==

(function() {
    'use strict';

    document.addEventListener('keydown', e => {
        if (e.code === "Space"){
            document.getElementsByClassName("vjs-play-control")[0].click();
        } else if (e.code === "KeyF") {
            document.getElementsByClassName("vjs-fullscreen-toggle-control-button")[0].click();
        } else if (e.code === "ArrowLeft"){
            document.getElementById("vjs_video_3_html5_api").currentTime -= 10;
        } else if (e.code === "ArrowRight"){
            document.getElementById("vjs_video_3_html5_api").currentTime += 10;
        }
    });
})();