用video的bug来跳过进度条

Use the video bug to skip the progress bar

当前为 2024-08-04 提交的版本,查看 最新版本

// ==UserScript==
// @name         用video的bug来跳过进度条
// @namespace    http://tampermonkey.net/
// @version      1.21
// @description  Use the video bug to skip the progress bar
// @author       lvandy
// @match        *://*/*
// @license MIT
// @grant        none
// ==/UserScript==

(function() {
    'use strict';

    // 监听点击事件
    document.addEventListener('click', function(e) {
        // 检查点击的元素是否是视频元素
        if (e.target.tagName.toLowerCase() === 'video') {
            // 获取视频元素
            var video = e.target;

            // 将视频跳转到最后一秒钟
            video.currentTime = video.duration - 1;
        }
    });
})();

QingJ © 2025

镜像随时可能失效,请加Q群300939539或关注我们的公众号极客氢云获取最新地址