Badges: fix print centering — override overflow:hidden on body/html in print

This commit is contained in:
Scott Idem
2026-03-12 17:46:50 -04:00
parent 1e70271002
commit 5ef66af98d

View File

@@ -161,11 +161,19 @@
and a dynamic @page rule can be injected here via print_margin_cfg. -->
<style>
@media print {
/* Full-page reset */
/* Full-page reset.
app.css sets `overflow: hidden` on html + body globally. In print,
with display:contents dissolving the intermediate wrappers, body's
only remaining content is the badge (~3.5in wide). overflow:hidden
makes body a BFC that shrinks-to-content — producing a body box that
is badge-width instead of page-width. Overriding with overflow:visible
restores normal block sizing: body fills 100% of the page width. */
html, body {
height: 100%;
width: 100% !important;
height: 100% !important;
margin: 0 !important;
padding: 0 !important;
overflow: visible !important;
}
/* Body is the sole centering flex container.