您需要先安装一个扩展,例如 篡改猴、Greasemonkey 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 Userscripts ,之后才能安装此脚本。
您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。
您需要先安装用户脚本管理器扩展后才能安装此脚本。
Makes the menu bar in GitHub stay at the top of the page when scrolling
当前为
// ==UserScript== // @name Floating Menu Bar (GitHub) // @namespace chriskim06 // @description Makes the menu bar in GitHub stay at the top of the page when scrolling // @include https://github.com/* // @version 1.0.3 // @grant none // @locale en // ==/UserScript== (function() { var menu = document.getElementsByClassName('header header-logged-in true'); if (menu.length) { menu[0].style.position = 'fixed'; menu[0].style.zIndex = '10000'; menu[0].style.width = '100%'; var flash = document.getElementById('js-flash-container'); if (flash !== null) { flash.style.position = 'relative'; flash.style.top = '50px'; } var content = document.getElementsByClassName('main-content'); if (content.length) { content[0].style.position = 'relative'; content[0].style.top = '50px'; } content = document.getElementsByClassName('container'); var footer = content.item(content.length - 1); if (footer !== null) { footer.style.position = 'relative'; footer.style.top = '50px'; } } })();