mediawiki-skins-MinervaNeue/resources/skins.minerva.base.styles/print/styles.less
jdlrobson d996008e9a Make sure lazy loaded images display in printed PDFs
The CSS animation will never complete in print media so will not display
in PDF rendering. A note is added to explain this rule.

Bug: T220668
Change-Id: I82260fa4e18a13970243d3cb2fc585aefb3c1d09
2019-07-09 10:50:46 -07:00

55 lines
926 B
Plaintext

@import '../../../minerva.less/minerva.variables';
@import '../../../minerva.less/minerva.mixins';
@media print {
.noprint,
.banner-container,
.header,
.pre-content,
.post-content {
display: none;
}
h1,
h2,
h3,
h4,
h5,
h6 {
page-break-after: avoid;
}
table,
figure,
img,
.lazy-image-placeholder {
page-break-inside: avoid;
}
img {
max-width: 100%;
// Disable lazy loading transition animation for print media (T220668) so they display.
&.image-lazy-loaded {
.animation( none ) !important;
}
}
}
@media print and ( max-device-width: @width-breakpoint-tablet ) {
// Chrome: override the default margins and reveal the footer
// Experimental technology (see https://developer.mozilla.org/en-US/docs/Web/CSS/@page/size)
@page {
margin: 50px 0;
}
html {
padding: 0 50px;
}
@import 'header.less';
@import 'article.less';
@import 'references.less';
@import 'footer.less';
}