-
-
Save amcgregor/7c86bbb7909fd4427ef3115bb0629db4 to your computer and use it in GitHub Desktop.
Some "user styles" overrides I use to make Github Gists more printable. Well, PDF-izable.
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
@media print { | |
div.js-header-wrapper, | |
.pagehead-actions, | |
.pagehead .note a, | |
.pagehead div.d-flex.flex-md-row, | |
.file-actions, | |
.js-discussion | |
{ display: none !important; } | |
.file { border-width: 0; } | |
.p-5 { border: 0; padding-left: 0 !important; padding-right: 0 !important; padding-top: 16px !important; } | |
.file-header { background: transparent; } | |
.markdown-body table { width: 100% !important; display: table; } | |
.markdown-body thead, | |
.markdown-body tbody, | |
.markdown-body tr, | |
.markdown-body th, | |
.markdown-body td | |
{ width: auto; page-break-inside: avoid; } | |
.markdown-body pre { | |
padding: 0 !important; | |
} | |
.markdown-body blockquote { color: #444; } | |
.markdown-body h3 { margin-top: 0; } | |
h1, h2, h3, h4, h5, h6 { page-break-after: avoid; break-after: avoid; } | |
h1 + *, h2 + *, h3 + *, h4 + *, h5 + *, h6 + * { page-break-before: avoid; break-before: avoid; } | |
.markdown-body a { color: black; font-weight: bold; } | |
.markdown-body a:not([href^="#"])::after { | |
display: inline; | |
content: ' (' attr(href) ')'; | |
font-weight: normal; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment