Bug 148069 - [CSS Grid Layout] Do not stretch always grid items with auto width
Summary: [CSS Grid Layout] Do not stretch always grid items with auto width
Alias: None
Product: WebKit
Classification: Unclassified
Component: Layout and Rendering (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Javier Fernandez
Keywords: BlinkMergeCandidate
Depends on:
Blocks: 60731
  Show dependency treegraph
Reported: 2015-08-16 15:18 PDT by Javier Fernandez
Modified: 2015-08-22 11:42 PDT (History)
10 users (show)

See Also:

Patch (37.88 KB, patch)
2015-08-16 15:42 PDT, Javier Fernandez
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Javier Fernandez 2015-08-16 15:18:23 PDT
We assumed that any grid item with 'auto' width will be stretched to fill all the available space in its grid area. We assumed this because grid area acts as item's container.

However, Grid Layout specification states on its Alignment section that items will be stretched by default, unless either justify-self or align-self compute to a value other than stretch or margins are auto. In those cases, grid items will auto-size to fit their contents.
Comment 1 Javier Fernandez 2015-08-16 15:42:08 PDT
Created attachment 259130 [details]
Comment 2 WebKit Commit Bot 2015-08-18 10:03:12 PDT
Comment on attachment 259130 [details]

Clearing flags on attachment: 259130

Committed r188582: <http://trac.webkit.org/changeset/188582>
Comment 3 WebKit Commit Bot 2015-08-18 10:03:17 PDT
All reviewed patches have been landed.  Closing bug.
Comment 4 Michael Catanzaro 2015-08-22 11:42:03 PDT
I added ENABLE(CSS_GRID_LAYOUT) guards around the use of parent()->isRenderGrid() in r188823.