Status: FAIL | Duration: 20ms | Subtests: 0/1 | Open test on wpt.live | Open ref on wpt.live | wpt.fyi
/css/css-page/margin-boxes/dimensions-010-print.html
<!DOCTYPE html> <link rel="author" title="Morten Stenshorne" href="mailto:mstensho@chromium.org"> <link rel="help" href="https://drafts.csswg.org/css-page-3/#margin-dimension"> <meta name="assert" content="Zero min/max content min/max size."> <link rel="match" href="dimensions-010-print-ref.html"> <style> :root { print-color-adjust: exact; } @page { margin: 100px; size: 650px 500px; @top-left { background: hotpink; content: ""; } @top-center { background: cyan; content: ""; } @top-right { background: yellow; content: ""; } @left-top { background: yellow; content: ""; } @left-middle { background: cyan; content: ""; } @left-bottom { background: hotpink; content: ""; } @right-top { background: red; content: ""; } @right-middle { background: cyan; content: "\a0"; } @right-bottom { background: red; content: ""; } @bottom-left { background: hotpink; content: "\a0"; } @bottom-center { background: red; content: ""; } /* Since there's a center box here, although it doesn't require any space, it will be there right in the center, meaning that the hotpink box, which *does* require space, can only receive everything to the left of the center box. */ @bottom-right { background: yellow; content: ""; } } </style>
/css/css-page/margin-boxes/dimensions-010-print-ref.html
<!DOCTYPE html> <link rel="author" title="Morten Stenshorne" href="mailto:mstensho@chromium.org"> <style> @page { size: 650px 500px; margin: 0; } :root { print-color-adjust: exact; } body { margin: 0; } .grid { display: grid; grid-template-columns: 100px auto 100px; grid-template-rows: 100px auto 100px; height: 100vh; } .vertical-edge { display: flex; } .horizontal-edge { display: flex; flex-flow: column; } </style> <div class="grid"> <div class="corner"></div> <div class="vertical-edge"> <div style="width:150px; background:hotpink;"></div> <div style="width:150px; background:cyan;"></div> <div style="width:150px; background:yellow;"></div> </div> <div class="corner"></div> <div class="horizontal-edge"> <div style="height:100px; background:yellow;"></div> <div style="height:100px; background:cyan;"></div> <div style="height:100px; background:hotpink;"></div> </div> <div></div> <div class="horizontal-edge"> <div style="height:300px; background:cyan;"></div> </div> <div class="corner"></div> <div class="vertical-edge"> <div style="width:225px; background:hotpink;"></div> <div style="width:225px; background:yellow;"></div> </div> <div class="corner"></div> </div>