Status: FAIL | Duration: 24ms | Subtests: 0/1 | Open test on wpt.live | Open ref on wpt.live | wpt.fyi
/css/css-grid/grid-lanes/grid-placement/row-explicit-placement-007.html
<!DOCTYPE html> <html> <link rel="help" href="https://drafts.csswg.org/css-grid-3"> <link rel="match" href="row-explicit-placement-007-ref.html"> <link rel="author" title="Alison Maher" href="mailto:almaher@microsoft.com"> <style> .grid-lanes { display: grid-lanes; grid-auto-flow: column; grid-lanes-direction: row; background: gray; flow-tolerance: 0; height: 200px; width: 200px; gap: 20px; padding: 20px; } .first-track { background: lightskyblue; grid-row-start: 1; } .second-track { background: lightcoral; grid-row-start: 2; height: 200%; } .third-track { background: lightgreen; grid-row-start: 3; } </style> <body> <p>Test that grid-lanes items with explicit placement are correctly positioned within the grid axis, with an orthogonal item.</p> <div class="grid-lanes"> <div class="first-track" style="writing-mode: vertical-rl;">This is some text</div> <div class="second-track">Some larger words in this sentence</div> <div class="third-track">The cat cannot be separated from milk</div> <div class="first-track">Some larger words in this sentence</div> <div class="second-track">The cat cannot be separated from milk</div> </div> </body> </html>
/css/css-grid/grid-lanes/grid-placement/row-explicit-placement-007-ref.html
<!DOCTYPE html> <html> <link rel="help" href="https://drafts.csswg.org/css-grid-3"> <link rel="author" title="Alison Maher" href="mailto:almaher@microsoft.com"> <style> #grid { display: grid; grid-template-columns: 200px 200px; background: gray; height: 200px; width: 200px; gap: 20px; padding: 20px; } .first-track { background: lightskyblue; grid-row-start: 1; } .second-track { background: lightcoral; grid-row-start: 2; height: 200%; } .third-track { background: lightgreen; grid-row-start: 3; } </style> <body> <p>Test that grid-lanes items with explicit placement are correctly positioned within the grid axis, with an orthogonal item.</p> <div id="grid"> <div id="first-item" class="first-track" style="writing-mode: vertical-rl; width: fit-content;"> This is some text </div> <div class="second-track">Some larger words in this sentence</div> <div class="third-track">The cat cannot be separated from milk</div> <div id="fourth-item" class="first-track" style="position: relative;">Some larger words in this sentence</div> <div class="second-track">The cat cannot be separated from milk</div> </div> <script> const grid = document.getElementById('grid'); const gridrect = grid.getBoundingClientRect(); // Width of the grid, minus padding. const gridwidth = gridrect.width - 40; const element1 = document.getElementById('first-item'); const rect = element1.getBoundingClientRect(); const width = rect.width; const element4 = document.getElementById('fourth-item'); const translation = gridwidth - width; element4.style.left = '-' + translation + 'px'; </script> </body> </html>