您需要先安装一个扩展,例如 篡改猴、Greasemonkey 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 Userscripts ,之后才能安装此脚本。
您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。
您需要先安装用户脚本管理器扩展后才能安装此脚本。
仅保留新闻列表
当前为
// ==UserScript== // @name 极简 It之家新闻列表 // @namespace http://tampermonkey.net/ // @version 1.5 // @description 仅保留新闻列表 // @author You // @match *://*.ithome.com/* // @grant none // ==/UserScript== (function () { 'use strict'; var currentURL = window.location.href; var newsList = /list/; setTimeout(() => { // 如果是新闻列表 if (newsList.test(currentURL)) { // 新闻列表页 $("html body").html($("#list .fl").html()); $("html body").css({ "width": "850px", "margin": "0 auto" }); $("ul.datel li a.t").css("width", "575px"); } else { // 内容页面 $("html body").html($("#dt.fl").html()); $("#dt>div:eq(1)").remove(); $("#dt .fl").css("width", "auto"); $("#dt .fl>script").remove(); $("#dt .fl .shareto").remove(); $("#dt .fl .related_post").remove(); $("#dt .fl iframe:first").remove(); $("img").each(function () { $(this).prop("src", $(this).data("original")) }); } }, 500); })();