summaryrefslogtreecommitdiffstats
path: root/third_party/WebKit/LayoutTests/fast/css-grid-layout/grid-item-order-paint-order.html
blob: 26c4c04e9beb43bcf13c2d44a8646a074b07867d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
<!DOCTYPE html>
<html>
<head>
<link href="../css-intrinsic-dimensions/resources/width-keyword-classes.css" rel="stylesheet">
<link href="resources/grid.css" rel="stylesheet">
<style>
.grid {
    grid-template-rows: 100px;
    grid-template-columns: 100px;
}
.sizedToGridArea {
    background-color: green;
}

.red {
    background-color: red;
}

.negativeOrder {
    order: -1;
}

.positiveOrder {
    order: 10;
}
</style>
</head>
<body>
    <p>This test checks that 'order' changes the paint ordering.</p>
    <p>There should be 2 green squares below.</p>
    <div class="grid fit-content">
        <div class="sizedToGridArea firstRowFirstColumn"></div>
        <div class="sizedToGridArea firstRowFirstColumn negativeOrder red"></div>
    </div>

    <div class="grid fit-content">
        <div class="sizedToGridArea firstRowFirstColumn positiveOrder"></div>
        <div class="sizedToGridArea firstRowFirstColumn red"></div>
    </div>
</body>
</html>