mirror of
https://github.com/SerenityOS/serenity
synced 2024-10-15 04:13:11 +00:00
Base: Add paint effects with opacity/transforms HTML test cases
This commit is contained in:
parent
e3537e4374
commit
c0eda77928
90
Base/res/html/misc/effects_with_opacity_and_transforms.html
Normal file
90
Base/res/html/misc/effects_with_opacity_and_transforms.html
Normal file
|
@ -0,0 +1,90 @@
|
|||
<style>
|
||||
body {
|
||||
background-image: linear-gradient(to bottom left, rgb(211, 157, 157), rgb(30, 101, 182), blue);
|
||||
}
|
||||
|
||||
.image-box {
|
||||
background-image: url(old-computer.png);
|
||||
height: 120px;
|
||||
width: 175px;
|
||||
background-size: cover;
|
||||
border: 2px solid black;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
margin: 5px;
|
||||
}
|
||||
|
||||
|
||||
.backdrop-box {
|
||||
background-color: rgba(255, 255, 255, 0.1);
|
||||
border-radius: 5px;
|
||||
width: 50%;
|
||||
height: 50%;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
backdrop-filter: grayscale() invert() blur(5px);
|
||||
}
|
||||
|
||||
|
||||
.box {
|
||||
width: 100px;
|
||||
height: 100px;
|
||||
border-radius: 50%;
|
||||
background-image: url(old-computer.png);;
|
||||
background-size: contain;
|
||||
}
|
||||
|
||||
.egg {
|
||||
border: 1px solid black;
|
||||
height: 100px;
|
||||
width: 100px;
|
||||
margin: 50px;
|
||||
border-radius: 80% 15% 55% 50% / 55% 15% 80% 50%;
|
||||
box-shadow: 20px 10px 5px magenta, cyan -20px -10px 5px, yellow 10px -5px 5px 20px;
|
||||
}
|
||||
|
||||
.op-30 {
|
||||
opacity: 30%;
|
||||
}
|
||||
|
||||
.scale-up {
|
||||
transform: scale(1.3, 1.4);
|
||||
}
|
||||
|
||||
.scale-down {
|
||||
transform: scale(0.5, 0.4);
|
||||
}
|
||||
</style>
|
||||
|
||||
<table>
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Normal</th>
|
||||
<th>Opacity: 30%</th>
|
||||
<th>Scaled Up</th>
|
||||
<th>Scaled Down</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td><div class="egg"></div></td>
|
||||
<td><div class="op-30 egg"></div></td>
|
||||
<td><div class="scale-up egg"></div></td>
|
||||
<td><div class="scale-down egg"></div></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><div class="box"></div></td>
|
||||
<td><div class="op-30 box"></div></td>
|
||||
<td><div class="scale-up box"></div></td>
|
||||
<td><div class="scale-down box"></div></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><div class="image-box"><div class="backdrop-box"></div></div></td>
|
||||
<td><div class="image-box"><div class="op-30 backdrop-box"></div></div></td>
|
||||
<td><div class="image-box"><div class="scale-up backdrop-box"></div></div></td>
|
||||
<td><div class="image-box"><div class="scale-down backdrop-box"></div></div></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
|
@ -153,6 +153,7 @@
|
|||
<li><a href="cascade-keywords.html">Cascade keywords (initial, inherit, unset)</a></li>
|
||||
<li><a href="inline-node.html">Styling "inline" elements</a></li>
|
||||
<li><a href="pseudo-elements.html">Pseudo-elements (::before, ::after, etc)</a></li>
|
||||
<li><a href="effects_with_opacity_and_transforms.html">Effects with opacity and transforms</a></li>
|
||||
</ul>
|
||||
|
||||
<h2>JavaScript/Wasm</h2>
|
||||
|
|
Loading…
Reference in a new issue