Skip to content

JS user-script. - Adding a control panel to the video (if Discord's native controls don't turn off the sound).

Notifications You must be signed in to change notification settings

TheGreyCardinal/Discord_Video_Controls

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 

Repository files navigation

Discord Video Controls.

JS user-script. - Adding a control panel to the video (if Discord's native controls don't turn off the sound).

  1. Add a user-script extension to your browser.
    For example: User JavaScript and CSS

  2. Add a rule for:
    https://discord.com/*

  3. Rule code:

 window.addEventListener("load", function() 
  {
   setInterval(add_video_controls, 1000);
  });

 function add_video_controls()
  {
   var list = document.querySelectorAll("video");
   
   for (var i = 0; i < list.length; i++)
    {
     if (list[i].controls == false)
      {
       list[i].setAttribute("controls", true);
       list[i].setAttribute("style", "z-index: 10000;");
      }
    }
  }
  1. Example:
    Example

About

JS user-script. - Adding a control panel to the video (if Discord's native controls don't turn off the sound).

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published