removed twitch click mute
This commit is contained in:
25
dist/twitch-click-mute.user.js
vendored
25
dist/twitch-click-mute.user.js
vendored
@@ -1,25 +0,0 @@
|
||||
// ==UserScript==
|
||||
// @name Twitch.tv Click to Mute
|
||||
// @namespace zomo.dev
|
||||
// @match https://www.twitch.tv/*
|
||||
// @version 1.0
|
||||
// @description click to mute/unmute a stream. does not work if the stream has an overlay
|
||||
// @downloadURL https://git.zomo.dev/zomo/browser-scripts/raw/branch/main/dist/twitch-click-mute.user.js
|
||||
// @supportURL https://git.zomo.dev/zomo/browser-scripts/issues
|
||||
// @homepageURL https://git.zomo.dev/zomo/browser-scripts
|
||||
// ==/UserScript==
|
||||
addEventListener('load', () => {
|
||||
document.body.addEventListener('click', e => {
|
||||
let target = e.target
|
||||
if (
|
||||
target &&
|
||||
target.getAttribute('data-a-target') ===
|
||||
'player-overlay-click-handler'
|
||||
) {
|
||||
let video = document.querySelector('video')
|
||||
if (video) {
|
||||
video.muted = !video.muted
|
||||
}
|
||||
}
|
||||
})
|
||||
})
|
||||
Reference in New Issue
Block a user