<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 - [:has() pseudo-class] Styles matching non-matching elements on load"
   href="https://bugs.webkit.org/show_bug.cgi?id=234732">234732</a>
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>[:has() pseudo-class] Styles matching non-matching elements on load
          </td>
        </tr>

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

        <tr>
          <th>Version</th>
          <td>Safari Technology Preview
          </td>
        </tr>

        <tr>
          <th>Hardware</th>
          <td>Mac (Intel)
          </td>
        </tr>

        <tr>
          <th>OS</th>
          <td>macOS 11
          </td>
        </tr>

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

        <tr>
          <th>Severity</th>
          <td>Critical
          </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>brandon@dreamthinkbuild.com
          </td>
        </tr></table>
      <p>
        <div>
        <pre>Created <span class=""><a href="attachment.cgi?id=448057" name="attach_448057" title="screenshot of has pseudo-class bug">attachment 448057</a> <a href="attachment.cgi?id=448057&action=edit" title="screenshot of has pseudo-class bug">[details]</a></span>
screenshot of has pseudo-class bug

Congrats on launching the :has() pseudo-class! Excited by all the possibilities this will open for styling.

One unexpected side effect I'm seeing when testing— it appears that `:has()` sometimes matches for non-matching elements. The inspector doesn't show the styles but they appear on-page. If I comment out the styles in the inspector and then un-comment them, they disappear.

 * Example URL: <a href="https://codepen.io/brandonmcconnell/pen/45b67ffa16dc41614efdd140bef1f439">https://codepen.io/brandonmcconnell/pen/45b67ffa16dc41614efdd140bef1f439</a>
 * Example screenshot attached
 * Example screen recording: <a href="https://www.loom.com/share/0cf9c18a99a8421f9957ff04c34f64de">https://www.loom.com/share/0cf9c18a99a8421f9957ff04c34f64de</a>

This bug is critical to the use of `:has()` so this should be resolved before the `:has()` pseudo-class is released into the production browser.</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>