您需要先安装一个扩展,例如 篡改猴、Greasemonkey 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 Userscripts ,之后才能安装此脚本。
您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。
您需要先安装用户脚本管理器扩展后才能安装此脚本。
Pin the latest message written by Live owner or moderator to the top
当前为
// ==UserScript== // @name YouTube Sticky LiveChat // @namespace https://i544c.github.io // @version 0.1 // @description Pin the latest message written by Live owner or moderator to the top // @author i544c // @match https://www.youtube.com/watch?v=* // @grant none // ==/UserScript== (() => { let chatframe = null; const main = () => { console.log('Found LiveChat frame'); const style = document.createElement('style'); style.textContent = ` #item-offset { overflow: visible !important; } #items { transform: none !important; } yt-live-chat-text-message-renderer[author-type="owner"], yt-live-chat-text-message-renderer[author-type="moderator"] { background: black; position: sticky; top: 0px; z-index: 1; } `; chatframe.contentDocument.body.appendChild(style); }; const findInterval = window.setInterval(() => { console.log('Search LiveChat frame'); chatframe = document.querySelector('#chatframe'); if (chatframe) { chatframe.onload = main; window.clearInterval(findInterval); } }, 1000); })();
QingJ © 2025
镜像随时可能失效,请加Q群300939539或关注我们的公众号极客氢云获取最新地址