gecko-dev/testing/web-platform/tests/css/css-overflow/webkit-line-clamp-026.html
Morten Stenshorne 34ddd43293 Bug 1553330 [wpt PR 16943] - Make webkit-line-clamp-026.html fail consistently., a=testonly
Automatic update from web-platform-tests
Make webkit-line-clamp-026.html fail consistently.

Make sure that layout has happened before modifying style.
This is what the test wants to test.

Bug: 965137
Change-Id: I2efcae8113b693fe7d591e6eff3df3937ed4df43
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1623089
Reviewed-by: Christian Biesinger <cbiesinger@chromium.org>
Commit-Queue: Morten Stenshorne <mstensho@chromium.org>
Cr-Commit-Position: refs/heads/master@{#661966}

--

wp5At-commits: e9b2f877b4333b51cd309a9d5ba6cbbab6b5b173
wpt-pr: 16943
2019-06-19 11:05:46 -07:00

28 lines
1 KiB
HTML

<!DOCTYPE html>
<meta charset="utf-8">
<title>CSS Overflow: Dynamically changing -webkit-box-orient when -webkit-line-clamp applies</title>
<link rel="author" title="Cameron McCormack" href="mailto:cam@mcc.id.au">
<link rel="help" href="https://drafts.csswg.org/css-overflow-3/#webkit-line-clamp">
<link rel="match" href="reference/webkit-line-clamp-026-ref.html">
<meta name="assert" content="Dynamically changing a -webkit-line-clamp affected element to be -webkit-box-orient:horizontal should cause the line clamp to be removed.">
<style>
.clamp {
display: -webkit-box;
-webkit-box-orient: vertical;
-webkit-line-clamp: 3;
font: 16px / 32px monospace;
white-space: pre;
background-color: yellow;
overflow: hidden; /* can be removed once implementations update their old -webkit-line-clamp implementations */
}
</style>
<div class="clamp">Line 1
Line 2
Line 3
Line 4
Line 5</div>
<p>Following content.</p>
<script>
document.body.offsetTop;
document.querySelector(".clamp").style.webkitBoxOrient = "horizontal";
</script>