EBC Live

移除遮罩,快速進入 東森 EBC YT 直播頻道

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

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

// ==UserScript==
// @name          EBC Live
// @namespace     abner6718
// @description   移除遮罩,快速進入 東森 EBC YT 直播頻道
// @copyright     2022, abner6718 (https://greasyfork.org/en/users/929971-abner6718)
// @license       MIT
// @version       0.0.1
// @match         https://news.ebc.net.tw/live*
// @icon          https://www.google.com/s2/favicons?sz=64&domain=net.tw
// @grant         GM_addStyle
// @grant         GM_registerMenuCommand
// ==/UserScript==

GM_addStyle(`
#livePlayer-iframe-overlay {
    display: none;
}

.ytp-cued-thumbnail-overlay {
    display: none;
}
`)

function get_youtube_link(){
    let youtube_code = document.querySelector('.live-else-little-box').getAttribute('data-code');

    return `https://www.youtube.com/watch?v=${youtube_code}`;
}

GM_registerMenuCommand("前往 Youtube", () => {
    window.location.href = get_youtube_link();
});