2010-10-22 22:31:36 +00:00
< head >
< style >
#overflow::-webkit-scrollbar {
visibility: hidden;
}
< / style >
< / head >
< body style = "height: 200%" >
< p >
Test for < i > < a href = "https://bugs.webkit.org/show_bug.cgi?id=48154" > https://bugs.webkit.org/show_bug.cgi?id=48154< / a >
< a href = "rdar://problem/8251616" > < rdar://problem/8251616>< / a > Layout not updating in a subtree when a scrollbar is hidden in a flexbox descendant< / i > .
< / p >
< p >
There should be no red on this page.
< / p >
< p id = "result" > Test did not run.< / p >
< div style = "display: -webkit-box; -webkit-box-orient: vertical;" >
< div > <!-- this is going to end up marked for layout after initial layout -->
< div id = "target" style = "width: 100px; height: 100px; background-color: red;" > < / div >
< div id = "overflow" style = "overflow: auto; height: 100px; width: 100px;" >
< div style = "height: 150px;" > < / div >
< / div >
< / div >
< / div >
< script >
2012-06-15 07:38:37 +00:00
if (window.testRunner)
testRunner.dumpAsText();
2010-10-22 22:31:36 +00:00
function test()
{
var target = document.getElementById("target");
target.style.height = "0";
document.getElementById("result").innerText = target.offsetHeight == 0 ? "PASS" : "FAIL";
}
document.body.offsetTop;
test();
< / script >
< / body >