<html>
    <head>
      <base href="https://bugs.webkit.org/">
    </head>
    <body><table border="1" cellspacing="0" cellpadding="8">
        <tr>
          <th>Bug ID</th>
          <td><a class="bz_bug_link 
          bz_status_NEW "
   title="NEW - [css-grid] Automatic minimum size is not clamped if min track sizing function is auto"
   href="https://bugs.webkit.org/show_bug.cgi?id=180283">180283</a>
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>[css-grid] Automatic minimum size is not clamped if min track sizing function is auto
          </td>
        </tr>

        <tr>
          <th>Product</th>
          <td>WebKit
          </td>
        </tr>

        <tr>
          <th>Version</th>
          <td>WebKit Nightly Build
          </td>
        </tr>

        <tr>
          <th>Hardware</th>
          <td>Unspecified
          </td>
        </tr>

        <tr>
          <th>OS</th>
          <td>Unspecified
          </td>
        </tr>

        <tr>
          <th>Status</th>
          <td>NEW
          </td>
        </tr>

        <tr>
          <th>Severity</th>
          <td>Normal
          </td>
        </tr>

        <tr>
          <th>Priority</th>
          <td>P2
          </td>
        </tr>

        <tr>
          <th>Component</th>
          <td>Layout and Rendering
          </td>
        </tr>

        <tr>
          <th>Assignee</th>
          <td>webkit-unassigned@lists.webkit.org
          </td>
        </tr>

        <tr>
          <th>Reporter</th>
          <td>jfernandez@igalia.com
          </td>
        </tr>

        <tr>
          <th>CC</th>
          <td>bfulgham@webkit.org, simon.fraser@apple.com, zalan@apple.com
          </td>
        </tr></table>
      <p>
        <div>
        <pre>Created <span class=""><a href="attachment.cgi?id=328159" name="attach_328159" title="Test case to reproduce the bug">attachment 328159</a> <a href="attachment.cgi?id=328159&action=edit" title="Test case to reproduce the bug">[details]</a></span>
Test case to reproduce the bug

The spec is quite clear regarding this (<a href="https://drafts.csswg.org/css-grid/#min-size-auto">https://drafts.csswg.org/css-grid/#min-size-auto</a>):

"However, if the grid item spans only grid tracks that have a fixed max track sizing function, its specified size and content size in that dimension (and the input to the transferred size in the other dimension) are further clamped to less than or equal to the stretch fit the grid area’s size (so as to prevent the automatic minimum size from forcing overflow of its fixed-size grid area)."

It says that if the max track sizing function is fixed, it should clamp the automatic minimum size.

In the attached example we have a grid container with:
  grid-template-columns: minmax(auto, 0px);

So the automatic minimum size of the item needs to be clamped to 0px.
And the final size of the track should be 0px.

This is basically what this test wrongly checks:
<a href="http://w3c-test.org/css/css-grid/grid-items/grid-minimum-size-grid-items-017.html">http://w3c-test.org/css/css-grid/grid-items/grid-minimum-size-grid-items-017.html</a>

Firefox does this right.</pre>
        </div>
      </p>


      <hr>
      <span>You are receiving this mail because:</span>

      <ul>
          <li>You are the assignee for the bug.</li>
      </ul>
    </body>
</html>