您需要先安装一个扩展,例如 篡改猴、Greasemonkey 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 Userscripts ,之后才能安装此脚本。
您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。
您需要先安装用户脚本管理器扩展后才能安装此脚本。
Keep your hand free from scroll button.
当前为
- // ==UserScript==
- // @name LazyScroller (beta)
- // @version 0.0
- // @description Keep your hand free from scroll button.
- // @namespace idmresettrial
- // @author idmresettrial
- // @run-at document-end
- // @grant none
- // @require http://ajax.googleapis.com/ajax/libs/jquery/1.11.1/jquery.min.js
- // Website list
- // @match *://*.vozforums.com/*
- // End list
- // ==/UserScript==
- site = window.location.hostname;
- distance = 300;
- duration = 200;
- pause = 300;
- direct = "out";
- repeat = "";
- lazyScroller = '<div id="lazyScroller"><div class="lazyButton" id="lazyUp">↑</div><div class="lazyButton" id="lazyDown">↓</div></div>';
- $("body").append(lazyScroller);
- $("#lazyScroller").attr("style","position:fixed; top:100px; left:500px; z-index:999;");
- $(".lazyButton").attr("style","margin:10px; width:20px; height:20px; font-size:10px; color:#fff;line-height:20px;text-align:center;background:#7abf16");
- $("#lazyScroller .lazyButton").mouseover(function() {
- direct = $(this).attr("id");
- setTimeout(function() {go();},pause);
- });
- $("#lazyScroller .lazyButton").mouseout(function() {
- direct = "out";
- clearTimeout(repeat)
- });
- function go()
- {
- if (direct === "lazyUp") {
- $("body").animate({scrollTop: ($("body").scrollTop()-distance)}, duration);
- repeat = setTimeout(function() {go();},duration+pause);
- } else if (direct === "lazyDown") {
- $("body").animate({scrollTop: ($("body").scrollTop()+distance)}, duration);
- repeat = setTimeout(function() {go();},duration+pause);
- } else clearTimeout(repeat);
- }
QingJ © 2025
镜像随时可能失效,请加Q群300939539或关注我们的公众号极客氢云获取最新地址