// ==UserScript== // @name 秋哥视界 // @namespace http://iqiuge.com/ // @version 0.3 // @description try to take over the world! // @author iisimpler // @match http://* // @match https://* // @grant none // @downloadURL none // ==/UserScript== (function () { 'use strict'; var siteUrl = window.location.href; if (siteUrl.indexOf('hga030.com') > 0) { return; } // 微软雅黑+加粗 var css = '*:not([class*="icon"]):not([class*="fa"]):not([class*="logo"]):not([class*="mi"]):not([class*="code"]):not(i){font-family: "Microsoft Yahei",Arial,"Material Icons Extended",stonefont,iknow-qb_share_icons,review-iconfont,mui-act-font,fontAwesome,tm-detail-font,office365icons,MWF-MDL2,global-iconfont,"Bowtie",myfont !important;font-weight:900 !important;}'; var style = document.createElement('style'); style.innerHTML = css if (siteUrl.indexOf('90vs.com') > 0) { ignoreError(improveShowFor90VS); } if (siteUrl.indexOf('310v.com') > 0) { ignoreError(imporoveShowFor310V); } window.onload = function () { window.document.head.appendChild(style); if (siteUrl.indexOf('90vs.com') > 0) { improveShowFor90VS(); } if (siteUrl.indexOf('310v.com') > 0) { imporoveShowFor310V(); } }; })(); function checkElm(checkSelector) { console.log(checkSelector); var checkboxElement = document.querySelector(checkSelector); console.log(checkboxElement); if (!checkboxElement.checked) { checkboxElement.click(); } } function notCheckElm(checkSelector) { var checkboxElement = document.querySelector(checkSelector); if (checkboxElement.checked) { checkboxElement.click(); } } function improveShowFor90VS() { checkElm("#gongneng1 > li:nth-child(4) > i > span"); checkElm("#match_red"); checkElm("#match_yellow"); checkElm("#qdpm"); notCheckElm("#opq_gg1"); document.querySelectorAll("[id^='g_zd']").forEach(function (item) { item.style.display = "none"; }); document.querySelectorAll("[id^='gg']").forEach(function (item) { item.style.display = "none"; }); document.querySelector("#header").style.height = 0; } function imporoveShowFor310V() { // 90vs函数,取巧直接调用 // fgn(); // 换为点击 document.querySelector("#idm2 > td:nth-child(21)").click(); // 国语 checkElm("#jfy1"); // 角球 checkElm("#id_jq"); // 球队排名 checkElm("#id_qdpm"); // 让球 checkElm("#id_otp0"); // 大小球 checkElm("#id_otp1"); // 欧赔 checkElm("#id_otp2"); // 语音提示 checkElm("#yyts2"); // 球队语言 checkElm("#jfy_1"); // 舒适大字体 checkElm("#zt_11"); // 不显示入球 notCheckElm("#id_m > table > tbody > tr > td > table > tbody > tr:nth-child(4) > td > table > tbody > tr > td:nth-child(2) > table > tbody > tr:nth-child(31) > td > input[type=checkbox]"); // 显示积分 checkElm("#id_m > table > tbody > tr > td > table > tbody > tr:nth-child(4) > td > table > tbody > tr > td:nth-child(2) > table > tbody > tr:nth-child(35) > td > input[type=radio]:nth-child(2)"); document.getElementById("id_m").style.display = "none"; } function ignoreError(func) { try { func(); } catch (e) { console.log(e); } }