Skip to content

Improve typography for print media #738

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Feb 28, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 25 additions & 0 deletions themes/vue/source/css/_common.styl
Original file line number Diff line number Diff line change
Expand Up @@ -208,3 +208,28 @@ sup.beta.beta
margin-left: .7em
text-transform: uppercase
opacity: .6

@media print
body
color: rgb(0,0,0)
.highlight
padding: 0
page-break-inside: avoid
.code
pre
color: rgb(0,0,0)
background-color: rgb(255,255,255)
border-style: solid
border-width: 2px 2px 2px 2px
border-color: #e8e8e8
page-break-inside: avoid
h1,h2,h3,h4,h5
color: rgb(0,0,0)
page-break-after: avoid
page-break-before:
img
page-break-inside: avoid
h2+p
page-break-before: avoid
a:link:after, a:visited:after { content:" [" attr(href) "] "; }

7 changes: 7 additions & 0 deletions themes/vue/source/css/_demo.styl
Original file line number Diff line number Diff line change
Expand Up @@ -60,3 +60,10 @@ ul#demo, ul.demo

th, td
padding: 3px 7px

@media print
#demo, .demo, .content .demo
page-break-inside: avoid
padding: 1em
margin-bottom: 1em
border-width: 2px
10 changes: 9 additions & 1 deletion themes/vue/source/css/page.styl
Original file line number Diff line number Diff line change
Expand Up @@ -250,4 +250,12 @@

@media print
.footer
display: none
display: none
.content
padding-left: 0px
.content p
line-height: 1.35em
&.tip
background-color: rgb(255,255,255)
border: 2px solid #e8e8e8
border-left: 4px solid $red