summaryrefslogtreecommitdiff
path: root/Base/res/html/misc
diff options
context:
space:
mode:
authorMacDue <macdue@dueutil.tech>2022-09-25 15:46:16 +0100
committerAndreas Kling <kling@serenityos.org>2022-09-25 18:37:31 +0200
commitc0eda779287d4b1305046164cd0a8ee5a5799e0b (patch)
tree24c6b76560dfa31186abbe569aead3d4f15f378b /Base/res/html/misc
parente3537e437486844142c70305aeaef7738bf1f39f (diff)
downloadserenity-c0eda779287d4b1305046164cd0a8ee5a5799e0b.zip
Base: Add paint effects with opacity/transforms HTML test cases
Diffstat (limited to 'Base/res/html/misc')
-rw-r--r--Base/res/html/misc/effects_with_opacity_and_transforms.html90
-rw-r--r--Base/res/html/misc/welcome.html1
2 files changed, 91 insertions, 0 deletions
diff --git a/Base/res/html/misc/effects_with_opacity_and_transforms.html b/Base/res/html/misc/effects_with_opacity_and_transforms.html
new file mode 100644
index 0000000000..b249cfe1db
--- /dev/null
+++ b/Base/res/html/misc/effects_with_opacity_and_transforms.html
@@ -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>
diff --git a/Base/res/html/misc/welcome.html b/Base/res/html/misc/welcome.html
index 625131f188..6fbd7153bb 100644
--- a/Base/res/html/misc/welcome.html
+++ b/Base/res/html/misc/welcome.html
@@ -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>