Content-Length: 303726 | pFad | https://github.com/w3c/csswg-drafts/issues/4790

4B [css-grid] Growth limits not increased with min-content contributions of spanning items · Issue #4790 · w3c/csswg-drafts · GitHub
Skip to content

[css-grid] Growth limits not increased with min-content contributions of spanning items #4790

@Loirooriol

Description

@Loirooriol

If you have a non-spanning item, https://drafts.csswg.org/css-grid/#algo-single-span-items

  • For min-content maximums:
    If the track has a min-content max track sizing function, set its growth limit to the maximum of the items’ min-content contributions.

But for spanning items, https://drafts.csswg.org/css-grid/#algo-spanning-items

  • For intrinsic maximums: Next increase the growth limit of tracks with an intrinsic max track sizing function by distributing extra space as needed to account for these items' minimum contributions. [...]

Why do we distribute the min-content contribution in the former case, but only the minimum contribution in the latter?

.grid { display: grid }
.grid.one { grid-template-columns: minmax(0, min-content) }
.grid.two { grid-template-columns: repeat(2, minmax(0, min-content)) }
.grid > .item { min-width: 0; background: cyan }
.grid.two > .item { grid-column: span 2 }
<div class="grid one">
  <div class="item">Foo</div>
</div>
<div class="grid two">
  <div class="item">Foo</div>
</div>

looks like

Thus violating

Note: This step is a simplification of the steps below for handling spanning items, and should yield the same behavior as running those instructions on items with a span of 1.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions









      ApplySandwichStrip

      pFad - (p)hone/(F)rame/(a)nonymizer/(d)eclutterfier!      Saves Data!


      --- a PPN by Garber Painting Akron. With Image Size Reduction included!

      Fetched URL: https://github.com/w3c/csswg-drafts/issues/4790

      Alternative Proxies:

      Alternative Proxy

      pFad Proxy

      pFad v3 Proxy

      pFad v4 Proxy