Last active
October 1, 2022 15:04
-
-
Save sthalik/9842c2e273f7a060b5673296966c26e2 to your computer and use it in GitHub Desktop.
This file contains 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
/* ==UserStyle== | |
@name doc.magnum.graphics - 10/1/2022, 2:07:33 PM | |
@namespace github.com/openstyles/stylus | |
@version 1.0.0 | |
@description A new userstyle | |
@author Me | |
==/UserStyle== */ | |
@-moz-document domain("doc.magnum.graphics") { | |
/* even wider on 4K screens */ | |
@media screen and (min-width: 1700px) { | |
.m-container { | |
width: 1300px; | |
} | |
} | |
/* sticky table of contents */ | |
@media screen and (min-width: 1400px) { | |
main article nav:first-of-type { | |
position: fixed; | |
top: 0; | |
left: 0; | |
width: 300px; | |
height: 100%; | |
background-color: #293039; | |
z-index: 2002; | |
padding: .5rem 1rem; | |
} | |
main article nav:first-of-type ul { | |
padding-left: 1.5rem; | |
} | |
main article nav:first-of-type > ul { | |
padding-left: .5rem; | |
list-style: none; | |
} | |
header > nav > .m-container { | |
margin-left: 300px; | |
} | |
} | |
/* sticky top nav menu */ | |
@media screen and (min-height: 651px) { | |
body > header > nav { | |
position: fixed; | |
top: 0; | |
width: 100%; | |
z-index: 2001; | |
} | |
main article:first-child { | |
padding-top: 3rem; | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment