<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 - We don't invalidate descendants when the matching status of a ::slotted selector changes."
   href="https://bugs.webkit.org/show_bug.cgi?id=172822">172822</a>
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>We don't invalidate descendants when the matching status of a ::slotted selector changes.
          </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>CSS
          </td>
        </tr>

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

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

        <tr>
          <th>CC</th>
          <td>koivisto@iki.fi, rniwa@webkit.org
          </td>
        </tr>

        <tr>
          <th>Blocks</th>
          <td>172753
          </td>
        </tr></table>
      <p>
        <div>
        <pre>Consider the following test-case, straight from fast/shadow-dom/css-scoping-slot-with-id.html:

<my-host id="t4"><div>text</div></my-host>
<script>
var host = document.querySelector('#t4');
var shadow = host.attachShadow({ mode: 'open' });
shadow.innerHTML = `
  <style>
    #myslot::slotted(*) {
      background-color: green; width: 100%; height: 100%;
    }
  </style>
  <slot id="notmyslot" style="color:green"></slot>
`;
var slot = shadow.querySelector("#notmyslot");
slot.offsetWidth;
slot.setAttribute("id", "myslot");
</script>

This test-case is failing with my patch in <a class="bz_bug_link 
          bz_status_NEW "
   title="NEW - Don't always do a style recalc for display: contents elements."
   href="show_bug.cgi?id=172753">bug 172753</a> because of the following:

We see that the <slot> element may change style and schedule it for a recalc, _but_ we don't invalidate the subtree, which may change because of the ::slotted pseudo-element, so when we see that the style hasn't changed for it we just don't recalc the inner <div>'s style.

This is wallpapered because right now we always force an Inherit change for display: contents elements, which ends up working in this test case.</pre>
        </div>
      </p>

        <div id="referenced">
          <hr style="border: 1px dashed #969696">
          <b>Referenced Bugs:</b>
          <ul>
              <li>
                [<a class="bz_bug_link 
          bz_status_NEW "
   title="NEW - Don't always do a style recalc for display: contents elements."
   href="https://bugs.webkit.org/show_bug.cgi?id=172753">Bug 172753</a>] Don't always do a style recalc for display: contents elements.
              </li>
          </ul>
        </div>
        <br>

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

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