Last active
December 14, 2023 01:21
-
-
Save cynecx/3487dd866b5ec8be63162dec35aae74c to your computer and use it in GitHub Desktop.
Use with userscript extension on iOS. I hate sticky headers.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // ==UserScript== | |
| // @name Fix Github Mobile | |
| // @encoding utf-8 | |
| // @match *://*.github.com/* | |
| // @compatible chrome | |
| // @compatible firefox | |
| // @compatible opera | |
| // @compatible safari | |
| // @compatible edge | |
| // @run-at document-idle | |
| // ==/UserScript== | |
| (function () { | |
| "use strict"; | |
| const styles = ` | |
| .pr-toolbar { | |
| height: auto !important; | |
| margin-top: -16px !important; | |
| } | |
| #repo-content-pjax-container > .clearfix { | |
| padding-left: 8px !important; | |
| padding-right: 8px !important; | |
| } | |
| .toolbar-shadow { | |
| display: none !important; | |
| } | |
| .js-sticky { | |
| position: unset !important; | |
| width: unset !important; | |
| } | |
| .js-position-sticky { | |
| position: unset !important; | |
| } | |
| .js-position-sticky.is-placeholder { | |
| display: none !important; | |
| } | |
| .js-sticky.js-sticky-offset-scroll { | |
| display: none !important; | |
| } | |
| .gh-header-shadow { | |
| display: none !important; | |
| } | |
| .data { | |
| overflow-x: auto; | |
| } | |
| .blob-code-inner { | |
| white-space: pre !important; | |
| } | |
| div[data-selector='repos-split-pane-content'] > :last-child { | |
| margin-left: 0px; | |
| margin-right: 0px; | |
| } | |
| main > react-app > div > * { | |
| padding-left: 4px !important; | |
| padding-right: 4px !important; | |
| } | |
| div:has(>button[data-testid~="date-picker-commits"]) { | |
| flex-direction: row; | |
| } | |
| li div[class~="listviewitem-leadingcontent"] { | |
| padding-left: 0px !important; | |
| } | |
| li div[data-testid~="listview-item-metadata"] { | |
| padding-right: 0px !important; | |
| } | |
| li[class~="listviewitem"] > div > h4 { | |
| font-size: 0.9rem; | |
| } | |
| li[class~="listviewitem"] > div[data-testid~="listview-item-title-container"] > span > button { | |
| height: 16px !important; | |
| } | |
| `; | |
| const elem = document.createElement("style"); | |
| elem.innerText = styles; | |
| document.head.appendChild(elem); | |
| })(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment