Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(974)

Unified Diff: third_party/WebKit/LayoutTests/fast/css/getComputedStyle/getComputedStyle-z-index-inherit.html

Issue 2047283002: Avoid touching z-index in StyleAdjuster by using an isStackingContext flag instead (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Update comments Created 4 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/LayoutTests/fast/css/getComputedStyle/getComputedStyle-z-index-inherit.html
diff --git a/third_party/WebKit/LayoutTests/fast/css/getComputedStyle/getComputedStyle-z-index-inherit.html b/third_party/WebKit/LayoutTests/fast/css/getComputedStyle/getComputedStyle-z-index-inherit.html
new file mode 100644
index 0000000000000000000000000000000000000000..0e577dc923278b18ef5c8d84bd0715b8dd7c9bb2
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/fast/css/getComputedStyle/getComputedStyle-z-index-inherit.html
@@ -0,0 +1,34 @@
+<!DOCTYPE html>
+<script src="../../../resources/testharness.js"></script>
+<script src="../../../resources/testharnessreport.js"></script>
+
+<style>
+#auto {
+ z-index: auto;
+ opacity: 0.9;
+}
+
+#one {
+ z-index: 1;
+}
+
+#inheritAuto, #inheritOne {
+ position: relative;
+ z-index: inherit;
+}
+</style>
+
+<div id="auto">
+ <div id="inheritAuto"></div>
+</div>
+
+<div id="one">
+ <div id="inheritOne"></div>
+</div>
+
+<script>
+test(() => {
+ assert_equals(getComputedStyle(inheritAuto).zIndex, 'auto');
+ assert_equals(getComputedStyle(inheritOne).zIndex, '1');
+}, 'z-index should inherit the computed value');
+</script>

Powered by Google App Engine
This is Rietveld 408576698