[Webkit-unassigned] [Bug 210077] New: [css-flexbox] Indefinite flex-basis percentage should cause height to be ignored

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Mon Apr 6 15:02:31 PDT 2020


https://bugs.webkit.org/show_bug.cgi?id=210077

            Bug ID: 210077
           Summary: [css-flexbox] Indefinite flex-basis percentage should
                    cause height to be ignored
           Product: WebKit
           Version: WebKit Nightly Build
          Hardware: Unspecified
                OS: Unspecified
            Status: NEW
          Severity: Normal
          Priority: P2
         Component: CSS
          Assignee: webkit-unassigned at lists.webkit.org
          Reporter: clopez at igalia.com

What steps will reproduce the problem?
  Load http://jsfiddle.net/q52pk5m4/1/

What is the expected output?
 The black-bordered box (the flex item) should shrinkwrap the text.
 No red should be visible.

What do you see instead?
 The black-bordered box is 400px tall. It is much taller than its text.


The flex item does have "height: 400px", but that should have no effect on its actual height, since it's a flex item and its flex-basis property is set. (The default 'flex-basis' property defers to the 'height', but here we've set flex-basis to 0%.)

Since we don't have anything to resolve our 0% against, the 0% is treated like auto-sizing, and so we should shrinkwrap the text.
But WebKit is incorrectly treating flex-basis:0% like flex-basis:auto and interpreting that 'auto' as meaning it should fall back to the 'height' property, which it should not

This very same issue has been reported and fixed for Chrome on https://crbug.com/531656

And there are two WPT tests for this:

  https://wpt.live/css/css-flexbox/flex-basis-010.html
  https://wpt.live/css/css-flexbox/flex-aspect-ratio-img-column-010.html

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20200406/6d842462/attachment.htm>


More information about the webkit-unassigned mailing list