forked from mirrors/gecko-dev
Automatic update from web-platform-tests[Squad] Get rid of MutableStyleRef() in list items. Clone and reset ComputedStyle When modifying the style of anonymous layout objects inside list items. Bug: 813068 Change-Id: Icd0d9d93d0e64fd130cfb5ba151bce7c34bfb234 Reviewed-on: https://chromium-review.googlesource.com/1053727 Reviewed-by: cathie chen <cathiechen@tencent.com> Commit-Queue: Rune Lillesveen <futhark@chromium.org> Cr-Commit-Position: refs/heads/master@{#558257} -- wpt-commits: b22e127b0477ecbae77b8a75173b1f93338d0af7 wpt-pr: 10979
20 lines
861 B
HTML
20 lines
861 B
HTML
<!DOCTYPE html>
|
|
<meta charset="utf-8">
|
|
<title>CSS Display: reflowing a display:list-item on dom changes - non-zero height</title>
|
|
<link rel="author" title="Rune Lillesveen" href="mailto:futhark@chromium.org">
|
|
<link rel="help" href="https://drafts.csswg.org/css-display-3/#list-items">
|
|
<script src="/resources/testharness.js"></script>
|
|
<script src="/resources/testharnessreport.js"></script>
|
|
<ul>
|
|
<li id="item" style="background:green">
|
|
<div id="content" style="overflow:hidden">Text<div>
|
|
</li>
|
|
</ul>
|
|
<script>
|
|
test(function() {
|
|
document.body.offsetTop; // force layout
|
|
item.insertBefore(document.createTextNode("This text should have a green background"), item.firstChild);
|
|
content.innerHTML = "";
|
|
assert_not_equals(item.clientHeight, 0, "The height of the LI should not be 0px.");
|
|
}, "List item height after DOM change.");
|
|
</script>
|