Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Select an option

  • Save jim60105/ec3f6c6b2a26b351830dddd8a0e4f6d7 to your computer and use it in GitHub Desktop.

Select an option

Save jim60105/ec3f6c6b2a26b351830dddd8a0e4f6d7 to your computer and use it in GitHub Desktop.
ShowRoomの見た目なんとかする
// ==UserScript==
// @name ShowRoomスッキリ
// @namespace http://tampermonkey.net/
// @version 0.2
// @description ごちゃごちゃすぎる
// @author Momoyama Mirai (Edited by jim60105)
// @match https://www.showroom-live.com/*
// @grant none
// ==/UserScript==
const sleep = (time) => new Promise((resolve) => setTimeout(() => resolve(), time * 1000));
(async function () {
'use strict';
console.log('[UserScript]ShowRoomスッキリ')
await sleep(1);
// どうでもいい要素を削除
const removeTagList = [
'#js-avatar', '#js-side-bar', '#flashContent', '#js-onlive-list', '#js-audition-profile', '#js-audition-judgement-submit',
// 公告banner
'.l-publicity-banner',
// footer icon
'#icon-room-twitter-wrapper', '#js-room-onlive-wrapper',
// 影片下的畫質設定條
'#videoSettings',
// twitterダイアログ、 ヘルプ 、 演者通報 、 視聴者通報 、 視聴者のミュート確認ダイアログ 、 オーナーのブロック確認ダイアログ 、 ギフトの消費確認ダイアログ 、 ゴールド足りないダイアログ 、 アイテムたりないダイアログ 、 投票中 、 投票結果 、 イベントとか支援ゲージとか 、 ボーナスゲット 、 event_deital 、 ユーザープロフィール 、 品質選択 、 アニメーションギフト用モーダル
// '#dialog-section',
'#telop'
];
for (const tag of removeTagList) {
try {
document.querySelector(tag).remove();
} catch (e) {
console.error(e);
}
}
// 背景画像消す
document.querySelector('#js-room-section').style = "background-image: initial;"
// 動画部分を全画面に
document.querySelector('.l-room-video').style = "width: 100vw; left: initial; margin-left: initial; height: initial; top: 50px;";
document.querySelector('#js-room-video').style = "width: 100%; overflow: initial;";
document.body.style = "height: 100vh;overflow: hidden;";
})();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment