Merge pull request #13102 from emilio/print-small-page

print: RFC: Center when printing a PDF with smaller size than the output page.
This commit is contained in:
Brendan Dahl 2021-03-15 18:51:42 -07:00 committed by GitHub
commit dd3797a325
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1763,6 +1763,15 @@ html[dir="rtl"] #documentPropertiesOverlay .row > * {
max-height: 100%;
page-break-after: always;
page-break-inside: avoid;
/* If we're smaller than the page, center the canvas horizontally and
* vertically */
min-height: 100%;
min-width: 100%;
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
}
#printContainer canvas,
#printContainer img {