Closed Bug 1687862 Opened 4 years ago Closed 4 years ago

[wpt-sync] Sync PR 27269 - [css-flex] Ignore items' heights for intrinsic block size calculation

Categories

(Core :: Layout: Flexbox, task, P4)

task

Tracking

()

RESOLVED FIXED
87 Branch
Tracking Status
firefox87 --- fixed

People

(Reporter: wpt-sync, Unassigned)

References

()

Details

(Whiteboard: [wptsync downstream])

Sync web-platform-tests PR 27269 into mozilla-central (this bug is closed when the sync is complete).

PR: https://github.com/web-platform-tests/wpt/pull/27269
Details from upstream follow.

b'David Grogan <dgrogan@chromium.org>' wrote:

[css-flex] Ignore items' heights for intrinsic block size calculation

Blink currently makes this flex item 200px tall. Firefox gives it the
correct height of 100px.

\<div style="display: flex; flex-direction: column">
\<div style="flex-basis: 100px; height: 200px">
\<div style="height: 100%">

Blink was letting the inner div's height resolve against the flex item's
200px, giving the flex item an automatic minimum size of 200px, even
though the min-content size is supposed to be calculated with the item
having an 'auto' size. Meaning we should ignore the item's 200px height.

To keep the 200px from having an effect, this patch broadens the
definition of ConstraintSpace().IsFixedBlockSizeDefinite. It no longer
has to accompany a FixedBlockSize. It now means that the element is to
be laid out as if it has an auto height.

Flexbox now sets this constraint on items when the flexbox needs the
item's intrinsic block size.

Bug: 1033476
Change-Id: I0376e8ec71ef5a6a71989a8bdda63b39718852e8
Reviewed-on: https://chromium-review.googlesource.com/2640774
WPT-Export-Revision: 490fcbced000a8aa3d3cdff263776bcd48aa09c5

Component: web-platform-tests → Layout: Flexbox
Product: Testing → Core

CI Results

Ran 15 Firefox configurations based on mozilla-central, and Firefox, Chrome, and Safari on GitHub CI

Total 10 tests and 1 subtests

Status Summary

Firefox

OK : 2
PASS: 13

Chrome

OK : 2
PASS: 8
FAIL: 5

Safari

OK : 2
PASS: 7
FAIL: 6

Links

Gecko CI (Treeherder)
GitHub PR Head
GitHub PR Base

Pushed by wptsync@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/857348316c00 [wpt PR 27269] - [css-flex] Ignore items' heights for intrinsic block size calculation, a=testonly
Status: NEW → RESOLVED
Closed: 4 years ago
Resolution: --- → FIXED
Target Milestone: --- → 87 Branch
You need to log in before you can comment on or make changes to this bug.