forked from mirrors/gecko-dev
Automatic update from web-platform-tests [css-flex] Fix a test that had bad expectations Some hand calculations in the reference didn't age well. I replaced the -ref.html with checkLayout. The test failed in Firefox in an identical fashion. New test passes in both browsers. Just a test, no behavior change. Fixed: 1111708 Change-Id: I7fc82e5d990c57db6c0d205e30aacaed88990418 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2490251 Commit-Queue: David Grogan <dgrogan@chromium.org> Reviewed-by: Christian Biesinger <cbiesinger@chromium.org> Cr-Commit-Position: refs/heads/master@{#820506} -- wpt-commits: 1c0b752760fb1ecad549c887a0829c43196b5a8b wpt-pr: 26208
40 lines
1.1 KiB
HTML
40 lines
1.1 KiB
HTML
<!DOCTYPE html>
|
|
<title>flexbox | justify-content: center / overflow</title>
|
|
<link rel="author" href="http://opera.com" title="Opera Software">
|
|
<link rel="author" href="mailto:dgrogan@chromium.org" title="David Grogan">
|
|
<link rel="help"
|
|
href="http://www.w3.org/TR/css-flexbox-1/#justify-content-property">
|
|
<meta name="assert" content="Items that overflow a singleline justify-content:center flexbox container are positioned correctly.">
|
|
|
|
<script src="/resources/testharness.js"></script>
|
|
<script src="/resources/testharnessreport.js"></script>
|
|
<script src="/resources/check-layout-th.js"></script>
|
|
|
|
Blue is the flexbox. Orange are items that overflow it.
|
|
|
|
<style>
|
|
.flexbox {
|
|
background: blue;
|
|
margin-left: 50px;
|
|
height: 150px;
|
|
width: 50px;
|
|
display: flex;
|
|
justify-content: center;
|
|
position: relative;
|
|
}
|
|
span {
|
|
background: orange;
|
|
margin: 10px;
|
|
flex: 1 0 40px;
|
|
}
|
|
</style>
|
|
|
|
<div class=flexbox>
|
|
<span data-expected-width=40 data-offset-x=-55></span>
|
|
<span data-expected-width=40 data-offset-x=5></span>
|
|
<span data-expected-width=40 data-offset-x=65></span>
|
|
</div>
|
|
|
|
<script>
|
|
checkLayout('span');
|
|
</script>
|