GameSense Forum Customization

Changes the forum background image and sets the theme to light blue.

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴Greasemonkey 油猴子Violentmonkey 暴力猴,才能安装此脚本。

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴,才能安装此脚本。

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴Violentmonkey 暴力猴,才能安装此脚本。

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴Userscripts ,才能安装此脚本。

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴,才能安装此脚本。

您需要先安装一款用户脚本管理器扩展后才能安装此脚本。

(我已经安装了用户脚本管理器,让我安装!)

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

(我已经安装了用户样式管理器,让我安装!)

// ==UserScript==
// @name         GameSense Forum Customization
// @namespace    http://tampermonkey.net/
// @version      1.1
// @description  Changes the forum background image and sets the theme to light blue.
// @author       bekonn
// @match        https://gamesense.pub/*
// @grant        none
// @run-at       document-start
// @license MIT
// ==/UserScript==

(function() {
    'use strict';

const customCSS = `

        body {
            background-image: url('https://i.imgur.com/7KI4AQL.png') !important;

            background-size: cover !important;
            background-attachment: fixed !important;
            background-position: center center !important;
            background-color: #000000 !important;
            background-repeat: no-repeat;
        }

        .pun,
        .punwrap,
        #brdheader,
        #brdfooter,

        .block,
        .box,
        .inbox,

        .blocktable,
        .block table,
        .block table tbody,
        .block table tr,

        .rowodd, .roweven,
        .tcl, .tcr, .tcm,
        div.top-box,
        .end-box,
        #brdtitle,
        #brddesc {
            background-color: transparent !important;
            border: none !important;
            box-shadow: none !important;
        }


        .blockform h2 span,
        #shout,
        #brdwelcome {
            background-color: rgba(0, 0, 0, 0.7) !important;
            padding: 10px;
            border-radius: 5px;
        }

        .box {
            background-color: rgba(0, 0, 0, 0.5) !important;
        }

        .blockform h2, .forumlist h3 {
            background-color: rgba(0, 0, 0, 0.8) !important;
        }

        body,
        .pun,
        .punwrap,
        .inbox a, .box a,
        h1, h2, h3, h4,
        li, p, span,
        .usergroup-5, .usergroup-3,
        #brdmenu ul li a,
        .rowOdd a, .rowEven a,
        div, table, tr, td {
            color: #FFFFFF !important;
        }
    `;

    function addGlobalStyle(css) {
        var head, style;
        head = document.getElementsByTagName('head')[0];
        if (!head) { return; }
        style = document.createElement('style');
        style.type = 'text/css';
        style.innerHTML = css;
        head.appendChild(style);
    }

    addGlobalStyle(customCSS);
})();