Last active
December 1, 2016 16:57
-
-
Save fabiorochafg/5554099 to your computer and use it in GitHub Desktop.
A print stylesheet example.
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 { | |
*, | |
*:before, | |
*:after, | |
*:first-letter, | |
p:first-line, | |
div:first-line, | |
blockquote:first-line, | |
li:first-line { | |
background: transparent !important; | |
box-shadow: none !important; | |
color: #000 !important; | |
margin: 0 !important; | |
padding: 0 !important; | |
text-shadow: none !important; | |
} | |
a, | |
a:visited { | |
text-decoration: underline; | |
} | |
a:after { | |
content: " ("attr(href)")"; | |
} | |
a[href^="javascript:"]:after, | |
a[href^="#"]:after { | |
content: ""; | |
} | |
abbr[title]:after { | |
content: " ("attr(title)")"; | |
} | |
body { | |
color: #000; | |
font: 9pt serif; | |
line-height: 1.4em; | |
} | |
h1 { | |
width: 100%; | |
} | |
h1 a:after { | |
content: ""; | |
} | |
img { | |
max-width: 100%; | |
} | |
p { | |
orphans: 3; | |
widows: 3; | |
} | |
p a { | |
word-wrap: break-word; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment