// ==UserScript== // @name 天天基金 - 基金PC详情页精简 // @namespace Violentmonkey Scripts // @grant none // @description 移除页面乱七八糟的内容, 专注走势和净值 // @version 1.0.4 // @author SkayZhang // @license MIT // @icon https://j5.dfcfw.com/image/201502/20150227144530.png // @supportURL https://greasyfork.org/zh-CN/scripts/436307/feedback // @match *://fund.eastmoney.com/* // @description 2021/11/30 上午10:54:52 // @require https://cdn.bootcdn.net/ajax/libs/jquery/3.6.0/jquery.min.js // @downloadURL https://update.greasyfork.icu/scripts/436307/%E5%A4%A9%E5%A4%A9%E5%9F%BA%E9%87%91%20-%20%E5%9F%BA%E9%87%91PC%E8%AF%A6%E6%83%85%E9%A1%B5%E7%B2%BE%E7%AE%80.user.js // @updateURL https://update.greasyfork.icu/scripts/436307/%E5%A4%A9%E5%A4%A9%E5%9F%BA%E9%87%91%20-%20%E5%9F%BA%E9%87%91PC%E8%AF%A6%E6%83%85%E9%A1%B5%E7%B2%BE%E7%AE%80.meta.js // ==/UserScript== (function () { 'use strict' let id = "" let chatDom $("body>*").css("opacity","0") let state = localStorage.getItem("cleanState") setTimeout(()=>{ if(state){ main.init() main.clean() main.build() }else main.addBtn() },500); let main = { init(){ id = window.location.pathname.replace("/","") id = id.substring(0,id.indexOf(".")) $("body").append(``) chatDom = $(".estimatedchart").html() }, clean(){ // 移除顶部广告 $("body>div[id!=body]").first().remove() // 待移除元素列表 let removeList = ["#rightadvert","#BottomSwith","#_AdSame_divsub_pd",".buyWayWrap",".fund_item.quotationItem_DataMap.popTab",".choseBuyWay-shadow",".dropdown.head-item.droplist",".logo.fl","h1.fl",".item_title.hd",".quotationItem",".estimatedsideInfo",".fundDetail-footer",".fundDetail-tools",".fl.links","#referAd1",".referAdDiv"] // 遍历列表并移除元素 for(let i in removeList){ $(removeList[i]).remove() } // 待移除元素下级列表 let removeSubList = [".adcommon",".fundtypeNav",".SitePath",".lazy",".recentBrowse",".declare",".cpright",".cls_btn","#float_phone"] // 遍历下级列表并移除元素 for(let i in removeSubList){ $(removeSubList[i]).parent().remove() } }, build(){ // 移动走势图未知 $(".choseBuyWay").append(`