Greasy Fork

Dark JVC Fix

Fix Dark JVC dans la liste des sujets

目前为 2020-10-01 提交的版本。查看 最新版本

// ==UserScript==
// @name         Dark JVC Fix
// @namespace    http://tampermonkey.net/
// @version      0.5
// @description  Fix Dark JVC dans la liste des sujets
// @author       Dwnlt
// @include      https://www.jeuxvideo.com/forums/0-*
// @include      https://www.jeuxvideo.com/recherche/forums/0-*
// @grant        none
// @run-at       document-body
// ==/UserScript==

(function() {
    'use strict';
    let fixCss =
    `
.topic-list .dfp__atf ~ li:nth-of-type(even) {
    background: #2E2E2E !important;
}
.topic-list .dfp__atf ~ li:nth-of-type(odd) {
    background: #2A2A2A !important;
}

.topic-list li.topic-delete-gta{
    background: #2E2E2E !important;
}

.topic-list .dfp__atf ~ li:nth-of-type(even):hover, .topic-list .dfp__atf ~ li:nth-of-type(odd):hover {
    background: #202020 !important;
}
    `
    function injectCss(){
        let head = document.getElementsByTagName('head')[0];
        if (!head) { return; }
        let style = document.createElement('style');
        style.type = 'text/css';
        style.innerHTML = fixCss;
        head.appendChild(style);
    }
    injectCss();
})();