您需要先安装一个扩展,例如 篡改猴、Greasemonkey 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 Userscripts ,之后才能安装此脚本。
您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。
您需要先安装用户脚本管理器扩展后才能安装此脚本。
Greasy Fork is available in English.
将视频进度条移至末尾,绕过基于进度的限制。
// ==UserScript== // @name 视频进度条拉到尾端 // @namespace none // @version 1.2 // @description 将视频进度条移至末尾,绕过基于进度的限制。 // @author AMin // @match *://*/* // @grant none // @license Proprietary // @run-at document-end // ==/UserScript== (function () { 'use strict'; const manipulateProgressBar = () => { const video = document.querySelector('video'); if (!video) return; const originalTime = video.currentTime; video.currentTime = video.duration - 2; setTimeout(() => video.currentTime = originalTime, 900); }; const createButton = () => { const button = document.createElement('button'); Object.assign(button.style, { position: 'absolute', top: '10px', left: '10px', backgroundColor: '#444', color: '#fff', border: 'none', padding: '8px 16px', cursor: 'pointer', opacity: '0.85', zIndex: '10000' }); button.textContent = '视频置为最后'; button.onclick = manipulateProgressBar; document.body.appendChild(button); }; const observer = new MutationObserver((mutations, obs) => { if (document.querySelector('video')) { createButton(); obs.disconnect(); } }); document.querySelector('video') ? createButton() : observer.observe(document.body, { childList: true, subtree: true }); })();