1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-26 23:37:36 +00:00

LibWeb: Add support for grid items with negative column-start in GFC

This changes grid items position storage type from unsigned to signed
integer so it can represent negative offsets and also updates placement
for grid items with specified column to correctly handle negative
offsets.
This commit is contained in:
Aliaksandr Kalenik 2023-06-07 12:00:01 +03:00 committed by Andreas Kling
parent 2c16e8371f
commit 0f1f95da46
4 changed files with 241 additions and 64 deletions

View file

@ -0,0 +1,38 @@
<style>
.grid {
display: grid;
grid-template-columns: auto;
}
.a {
grid-column: -3;
background-color: lightblue;
}
.b {
grid-column-start: -1;
background-color: lightcoral;
}
.c {
grid-column: 1;
background-color: lightsalmon;
}
.d {
grid-column: 3;
background-color: lightgreen;
}
</style>
<div class="grid">
<div class="a">a</div>
<div class="c">c</div>
<div class="b">b</div>
<div class="b">b</div>
<div class="d">d</div>
<div class="c">c</div>
<div class="d">d</div>
<div class="e">e</div>
<div class="f">f</div>
</div>