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

Unified Diff: LayoutTests/css3/flexbox/percent-height-children-of-alignSelf-stretch-flex-item.html

Issue 331203002: Blink doesn't honor percent heights on children of "align-self:stretch" flex items in a fixed-height (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Addresses changes asked in comments in patch 4 Created 6 years, 6 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: LayoutTests/css3/flexbox/percent-height-children-of-alignSelf-stretch-flex-item.html
diff --git a/LayoutTests/css3/flexbox/percent-height-children-of-alignSelf-stretch-flex-item.html b/LayoutTests/css3/flexbox/percent-height-children-of-alignSelf-stretch-flex-item.html
new file mode 100644
index 0000000000000000000000000000000000000000..d4e663ec7f1d3e681140f280943010282118cd88
--- /dev/null
+++ b/LayoutTests/css3/flexbox/percent-height-children-of-alignSelf-stretch-flex-item.html
@@ -0,0 +1,69 @@
+<!DOCTYPE html>
+<style>
+.flexbox-horizontal {
cbiesinger 2014/06/24 03:01:28 I'd really prefer you to use the stylesheet in css
harpreet.sk 2014/06/24 07:56:59 Now using flexbox.css
+ display: flex;
+ height: 100px;
+ background-color: purple;
+ position: relative;
+}
+
+.flexbox-vertical {
+ display: flex;
+ width: 100px;
+ background-color: purple;
+ position: relative;
+ -webkit-writing-mode: vertical-rl;
+}
+
+.flex-item {
+ flex: 1;
+ background-color: red;
+}
+</style>
+<script src="../../resources/check-layout.js"></script>
+<script>
+function changeHeight()
+{
+ document.getElementById('dynamicHorizontalChild').style.height = "90%";
+ document.getElementById('dynamicVerticalChild').style.width = "30%";
+ checkLayout('.flexbox-horizontal');
+ checkLayout('.flexbox-vertical');
+}
+</script>
+<body onload="changeHeight()">
+<div class="flexbox-horizontal">
+ <div data-expected-height="100" class="flex-item">
+ <div data-expected-height="70" style="height:70%; background-color:lime">Horizontal Writing Mode</div>
+ </div>
+</div>
+
+<div class="flexbox-vertical">
+ <div data-expected-width="100" class="flex-item">
+ <div data-expected-width="50" style="width: 50%; background-color:lime">Vertical Writing Mode</div>
+ </div>
+</div>
+
+<div class="flexbox-horizontal">
+ <div data-expected-height="100" class="flex-item">
+ <div id="dynamicHorizontalChild" data-expected-height="90" style="height:70%; background-color:lime">Horizontal Writing Mode</div>
+ </div>
+</div>
+
+<div class="flexbox-vertical">
+ <div data-expected-width="100" class="flex-item">
+ <div id="dynamicVerticalChild" data-expected-width="30" style="width: 50%; background-color:lime">Vertical Writing Mode</div>
+ </div>
+</div>
+
+<div class="flexbox-horizontal">
+ <div data-expected-height="100" class="flex-item" style="padding:10px; border:2px solid black">
+ <div data-expected-height="53" style="height:70%; background-color:lime">Horizontal Writing Mode</div>
+ </div>
+</div>
+
+<div class="flexbox-vertical">
+ <div data-expected-width="100" class="flex-item" style="padding:10px; border:2px solid black">
+ <div data-expected-width="38" style="width: 50%; background-color:lime">Vertical Writing Mode</div>
+ </div>
+</div>
+</body>

Powered by Google App Engine
This is Rietveld 408576698