Status: FAIL | Duration: 14ms | Subtests: 0/1 | Open test on wpt.live | Open ref on wpt.live | wpt.fyi
/css/css-grid/grid-lanes/tentative/item-placement/row-fill-reverse-definite-size-002.html
<!DOCTYPE html> <html> <head> <meta charset="utf-8"> <title>CSS Grid Lanes: Row fill-reverse where items overflow the definite size</title> <link rel="help" href="https://drafts.csswg.org/css-grid-3"> <link rel="match" href="row-fill-reverse-definite-size-002-ref.html"> <link rel="author" title="Celeste Pan" href="mailto:celestepan@microsoft.com"> <style> .grid-lanes { display: grid-lanes; flow-tolerance: 0; grid-template-rows: repeat(3, 50px); gap: 10px; width: 120px; border: solid blue; grid-lanes-direction: row fill-reverse; } </style> </head> <body> <p>Test that grid-lanes items with fill-reverse placement are correctly positioned when overflowing a definite-size row container.</p> <div class="grid-lanes"> <div style="background: lavender; width: 20px;">1</div> <div style="background: lightskyblue; width: 30px;">2</div> <div style="background: lightgreen; width: 20px;">3</div> <div style="background: lightpink; grid-row: span 2; width: 25px;">4</div> <div style="background: lavender; width: 20px; margin-left: 10px;">5</div> <div style="background: lightskyblue; width: 35px;">6</div> <div style="background: lightgreen; width: 20px;">7</div> <div style="background: lightpink; width: 40px;">8</div> <!-- Negative margin-left, less than item size --> <div style="background: coral; width: 30px; margin-left: -10px;">9</div> <!-- Negative margin-right, less than item size --> <div style="background: gold; width: 30px; margin-right: -10px;">10</div> <!-- Negative margin-left, greater than item size --> <div style="background: tomato; width: 15px; margin-left: -25px;">11</div> <!-- The furthest right the item can go is 40px to the left of where item 9 starts --> <div style="background: orchid; width: 15px; margin-right: -100px;">12</div> </div> </body> </html>
/css/css-grid/grid-lanes/tentative/item-placement/row-fill-reverse-definite-size-002-ref.html
<!DOCTYPE html> <html> <head> <meta charset="utf-8"> <style> .container { display: grid; grid-template-rows: repeat(3, 50px); row-gap: 10px; width: 120px; border: solid blue; } .row { display: flex; flex-direction: row-reverse; column-gap: 10px; margin-left: -40px; } </style> </head> <body> <p>Test that grid-lanes items with fill-reverse placement are correctly positioned when overflowing a definite-size row container.</p> <div class="container"> <div class="row"> <div style="background: lavender; width: 20px;">1</div> <div style="background: lightpink; width: 25px; height: 110px; margin-right: 10px;">4</div> <div style="background: lightgreen; width: 20px;">7</div> <div style="background: coral; width: 30px; margin-left: -10px;">9</div> </div> <div class="row"> <div style="background: lightskyblue; width: 30px;">2</div> <div style="background: lightpink; width: 40px; margin-right: 35px;">8</div> <div style="background: tomato; width: 15px;">11</div> <div style="background: orchid; width: 15px; margin-right: -125px; z-index: 1;">12</div> </div> <div class="row"> <div style="background: lightgreen; width: 20px;">3</div> <div style="background: lavender; width: 20px; margin-left: 10px;">5</div> <div style="background: lightskyblue; width: 35px;">6</div> <div style="background: gold; width: 30px; margin-right: -10px;">10</div> </div> </div> </body> </html>