Skip to content

Commit

Permalink
Merge pull request #220 from timotheegoguely/print
Browse files Browse the repository at this point in the history
Add print style
  • Loading branch information
lkhrs authored Dec 11, 2024
2 parents 3abdc12 + 904128b commit fd8f603
Showing 1 changed file with 46 additions and 0 deletions.
46 changes: 46 additions & 0 deletions simple.css
Original file line number Diff line number Diff line change
Expand Up @@ -707,3 +707,49 @@ sub {
padding: 1.5rem;
margin: 2rem 0;
}

/* Print */
@media print {
@page {
margin: 1cm;
}
body {
display: block;
}
body > header {
background-color: unset;
}
body > header nav,
body > footer {
display: none;
}
article {
border: none;
padding: 0;
}
a[href^="http"]::after {
content: " <" attr(href) ">";
}
abbr[title]:after {
content: " (" attr(title) ")";
}
a {
text-decoration: none;
}
p {
widows: 3;
orphans: 3;
}
hr {
border-top: 1px solid var(--border);
}
mark {
border: 1px solid var(--border);
}
pre, table, figure, img, svg {
break-inside: avoid;
}
pre code {
white-space: pre-wrap;
}
}

0 comments on commit fd8f603

Please sign in to comment.