Greasy Fork

改变pku树洞网页版显示

change view of pku hole!

目前为 2019-04-23 提交的版本。查看 最新版本

// ==UserScript==
// @name         改变pku树洞网页版显示
// @namespace    [email protected]
// @version      0.1
// @description  change view of pku hole!
// @author       nicolas
// @match        http://pkuhelper.pku.edu.cn/hole/
// @grant        none
// ==/UserScript==

setInterval(function() {
    'use strict';
    var aEle = document.getElementsByTagName('*');
    for(var i=0;i<aEle.length;i++){
         if(aEle[i].className == "flow-item-row"){
            aEle[i].style.display="flex";
        }
        if(aEle[i].className == "flow-item"){
            aEle[i].style.margin="0 auto";
        }
        if(aEle[i].className == "flow-reply-row"){
            aEle[i].parentNode.removeChild(aEle[i]);
        }
    }
}, 100);