W3C home > Mailing lists > Public > public-css-archive@w3.org > May 2017

Re: [csswg-drafts] [css-grid] Ability to have grid items cause cells to be marked as occupied for flow purposes

From: Manuel Rego Casasnovas via GitHub <sysbot+gh@w3.org>
Date: Tue, 30 May 2017 12:13:04 +0000
To: public-css-archive@w3.org
Message-ID: <issue_comment.created-304859233-1496146383-sysbot+gh@w3.org>
>> for example, if an image 100px tall by 250px tall is placed into a cell, it will overlap the next cell and a half to the right of its own cell.
>
> Are you sure you're not just seeing a bug in Chrome? In the case you describe, the max-sizing function is fixed and if the image has a default min-width:auto then the clamping rule in ยง6.6 applies and the image should be 100px wide and its height scaled according to its intrinsic ratio. This works correctly in Firefox Nightly, but not Chrome Canary.

Indeed it seems we've a bug in Chrome as we only apply the clamping to regular items but not images.

@MatsPalmgren one question, what should be the expected height for the first row in [the following example](http://jsbin.com/diqaxay/1/edit?html,css,output)?
```html
<div style="display: inline-grid; border: solid thick;
            grid-template-columns: 100px;">
  <img src="https://placehold.it/200x100" />
  <div style="background: lime; font-size: 2em;">itemmmmmmm</div>
</div>
```

I see that in Firefox it's 100px, despite the image final height is 50px. Is that the expected behavior? Thanks.

-- 
GitHub Notification of comment by mrego
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/1394#issuecomment-304859233 using your GitHub account
Received on Tuesday, 30 May 2017 12:13:11 UTC

This archive was generated by hypermail 2.3.1 : Monday, 23 October 2017 10:12:54 UTC