您需要先安装一个扩展,例如 篡改猴、Greasemonkey 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 Userscripts ,之后才能安装此脚本。
您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。
您需要先安装用户脚本管理器扩展后才能安装此脚本。
追っかけ配信ではない、かつ再生中、かつニコ生ゲーム中の場合に、シークバー移動をブロックすることで、意図せず追っかけ配信へ切り替わってしまう問題に対処します。
当前为
// ==UserScript== // @name ニコ生ゲーム中のシークバー移動を防止 // @description 追っかけ配信ではない、かつ再生中、かつニコ生ゲーム中の場合に、シークバー移動をブロックすることで、意図せず追っかけ配信へ切り替わってしまう問題に対処します。 // @namespace https://gf.qytechs.cn/users/137 // @version 1.0.3 // @match https://live.nicovideo.jp/watch/lv* // @license MPL-2.0 // @contributionURL https://www.amazon.co.jp/registry/wishlist/E7PJ5C3K7AM2 // @compatible Edge // @compatible Firefox 推奨 // @compatible Opera // @compatible Chrome // @grant dummy // @noframes // @icon https://nicolive.cdn.nimg.jp/relive/party1-static/images/common/favicon.3cf1c.ico // @author 100の人 // @homepageURL https://gf.qytechs.cn/users/137 // ==/UserScript== 'use strict'; document.head.insertAdjacentHTML('beforeend', `<style> [class*="seek-controller"][aria-disabled="true"]::after { content: ""; position: absolute; top: 0; right: 0; bottom: 0; left: 0; cursor: not-allowed; } </style>`); const seekController = document.querySelector('[class*="seek-controller"]'); const playButton = document.querySelector('[class*="play-button"]'); let liveStatus = document.querySelector('[data-live-status]'); const lockItemArea = document.querySelector('[class*="lock-item-area"]'); function switchEnabled() { seekController.setAttribute('aria-disabled', /* 追っかけ再生中ではない */ liveStatus.dataset.liveStatus === 'live' && /* 再生中 */ playButton.dataset.toggleState === 'true' && /* ゲーム中 */ lockItemArea.querySelector('[data-content-type="game"], [data-content-type="atsumaru"]') ? 'true' : 'false'); } new Promise(function (resolve) { if (liveStatus) { resolve(); return; } new MutationObserver(function (mutations, observer) { liveStatus = document.querySelector('[data-live-status]') if (liveStatus) { observer.disconnect(); resolve(); } }).observe(document.querySelector('[class*="time-status-area"]'), { childList: true }); }).then(function () { switchEnabled(); new MutationObserver(switchEnabled).observe(liveStatus, { attributeFilter: [ 'data-live-status' ] }); new MutationObserver(switchEnabled).observe(playButton, { attributeFilter: [ 'data-toggle-state' ] }); new MutationObserver(switchEnabled).observe(lockItemArea, { childList: true }); });
QingJ © 2025
镜像随时可能失效,请加Q群300939539或关注我们的公众号极客氢云获取最新地址