Restream template button

Adds a template button to restream.io that changes the title of videos

スクリプトをインストールするには、Tampermonkey, GreasemonkeyViolentmonkey のような拡張機能のインストールが必要です。

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

スクリプトをインストールするには、TampermonkeyViolentmonkey のような拡張機能のインストールが必要です。

スクリプトをインストールするには、TampermonkeyUserscripts のような拡張機能のインストールが必要です。

このスクリプトをインストールするには、Tampermonkeyなどの拡張機能をインストールする必要があります。

このスクリプトをインストールするには、ユーザースクリプト管理ツールの拡張機能をインストールする必要があります。

(ユーザースクリプト管理ツールは設定済みなのでインストール!)

このスタイルをインストールするには、Stylusなどの拡張機能をインストールする必要があります。

このスタイルをインストールするには、Stylus などの拡張機能をインストールする必要があります。

このスタイルをインストールするには、Stylus tなどの拡張機能をインストールする必要があります。

このスタイルをインストールするには、ユーザースタイル管理用の拡張機能をインストールする必要があります。

このスタイルをインストールするには、ユーザースタイル管理用の拡張機能をインストールする必要があります。

このスタイルをインストールするには、ユーザースタイル管理用の拡張機能をインストールする必要があります。

(ユーザースタイル管理ツールは設定済みなのでインストール!)

このスクリプトの質問や評価の投稿はこちら通報はこちらへお寄せください
// ==UserScript==
// @name         Restream template button
// @namespace    http://tamermonkey.net
// @version      0.1
// @description  Adds a template button to restream.io that changes the title of videos
// @author       Jacqueb
// @match        https://restream.io/titles
// @grant        none
// ==/UserScript==

var d = new Date();

if(d.getHours() <= 12) {window.realtime = "Morning"} else {window.realtime = "Evening"};
var wd = ["Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday"];

setInterval(function() {if(document.getElementsByClassName("form-group")[0] != null) {if(document.getElementById("extrabutton") == null) {document.getElementsByClassName("sub-menu-block")[0].innerHTML += "<div style='margin-left: 120px; margin-top: 140px; position: absolute' id='extrabutton' id='mybutton' class='app-title-main__button'><input onclick='window.lol1 = true' type='button' class='button button_type_action' value='Template'></div>"}}},0)
setInterval(function() {document.getElementById("extrabutton").style.top = "180";
document.getElementById("extrabutton").style.left = "120"; if(window.lol1 == true) {makeDate();}},0);

setInterval(function() {if(document.getElementById("extrabutton") != null) {setStyles()}},0);
function setStyles() {
}

function makeDate() {
    document.getElementById("jsAllTitlesInput").value = 'PHPCG ' + (d.getMonth() + 1) + '/' + d.getDate() + '/' + d.getFullYear() + ' ' + wd[d.getDay()] + ' ' + realtime + ' Service';
    window.lol1 = false;
}