Closed Bug 1233218 Opened 9 years ago Closed 8 years ago

[css-grid] Grid row track sizing does not keep up with descendant size changes

Categories

(Core :: Layout, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED

People

(Reporter: eric, Assigned: MatsPalmgren_bugz)

References

Details

(Keywords: testcase, Whiteboard: [fixed by bug 1174569])

User Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:46.0) Gecko/20100101 Firefox/46.0
Build ID: 20151216030229

Steps to reproduce:

I created a testcase where images’ sizing was either a percentage of the grid item they inhabit, or a fixed width: http://meyerweb.com/eric/css/tests/grid-resizing.html

(Note the credit in that testcase for where it came from, and follow it to see another example of grid sizing problems, this time with `width`.  I did not file a separate bug because I don’t know if the problems are the same problem, or related problems.)


Actual results:

In the first two tests, the grid row tracks are erroneously sized as if the images had not been scaled to fit their parent elements (which are grid items; the images themselves are not).  Interestingly, this scales with percentage values, so a `width: 50%` will create grid row tracks half as tall as those where the images are given `width: 100%`.

In the third test, where the images are given explicit pixel widths, the error does not happen.


Expected results:

The grid row tracks should be sized to fit the content as it is displayed, and resized if the content resized.  This does happen if you check the checkbox before the second test (the `width: 50%` test): the grid row tracks are made large enough to fit the suddenly huge pictures.  Unchecked the box, though, and the grid row tracks go back to their previous, erroneous size.

Note: this bug may or may not be related to https://bugzilla.mozilla.org/show_bug.cgi?id=1222724.
Summary: [css-grid] Grid row sizing does not keep up with descendant size changes → [css-grid] Grid row track sizing does not keep up with descendant size changes
Component: Untriaged → Layout
Product: Firefox → Core
Version: 46 Branch → Trunk
Mats, mind taking a look?
Flags: needinfo?(mats)
Yeah, I'll get to this in the next few weeks hopefully.
Flags: needinfo?(mats)
Assignee: nobody → mats
Status: UNCONFIRMED → NEW
Depends on: 1174569
Ever confirmed: true
Keywords: testcase
This should be fixed by bug 1174569 in the latest Nightly.
Status: NEW → RESOLVED
Closed: 8 years ago
Resolution: --- → FIXED
Whiteboard: [fixed by bug 1174569]
Actually, the fix is only on m-c, it will be in the *next* Nightly we build from there...
(so it will take a day or so)
You need to log in before you can comment on or make changes to this bug.