<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugs.webkit.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.4.1"
          urlbase="https://bugs.webkit.org/"
          
          maintainer="admin@webkit.org"
>

    <bug>
          <bug_id>264397</bug_id>
          
          <creation_ts>2023-11-08 03:23:44 -0800</creation_ts>
          <short_desc>When no clearance applies to an element with &apos;clear&apos; set, place the element below the float just as we would if it was clear:none</short_desc>
          <delta_ts>2023-11-10 04:49:15 -0800</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>WebKit</product>
          <component>Layout and Rendering</component>
          <version>WebKit Nightly Build</version>
          <rep_platform>Unspecified</rep_platform>
          <op_sys>Unspecified</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords>BrowserCompat, InRadar</keywords>
          <priority>P2</priority>
          <bug_severity>Normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Ahmad Saleem">ahmad.saleem792</reporter>
          <assigned_to name="Nobody">webkit-unassigned</assigned_to>
          <cc>bfulgham</cc>
    
    <cc>simon.fraser</cc>
    
    <cc>webkit-bug-importer</cc>
    
    <cc>zalan</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>1990785</commentid>
    <comment_count>0</comment_count>
    <who name="Ahmad Saleem">ahmad.saleem792</who>
    <bug_when>2023-11-08 03:23:44 -0800</bug_when>
    <thetext>Hi Team,

I came across another failing test on STP182:

Test Case: https://jsfiddle.net/d83gt4d8/16/

^ This fails in Safari but passes in Chrome Canary 121 and Firefox Nightly 121.

Test Case (from commit): https://jsfiddle.net/vo39besy/show

^ Third last and above fails in Safari.

Blink Commit: https://chromium.googlesource.com/chromium/blink/+/502ffded2efe7d27b5e0ec085a47d4764b65c12c

WebKit Source: https://searchfox.org/wubkat/source/Source/WebCore/rendering/RenderBlockFlow.cpp#1593

____

This compiles:

if (!grandchildBox)
        return;
    // Make sure to update the block margins now for the grandchild box so that we&apos;re looking at

...

 // If we have a &apos;clear&apos; value but also have a margin we may not actually require clearance to move past any floats.
    // If that&apos;s the case we want to be sure we estimate the correct position including margins after any floats rather
    // than use &apos;clearance&apos; later which could give us the wrong position.
    if (RenderStyle::usedClear(*grandchildBox) != UsedClear::None &amp;&amp; !childBlock.marginBeforeForChild(*grandchildBox))
        return;

______

It progress above test case and it might also progress &apos;no-clearance-due-to-large-margin.html&apos; on WPT in css2 directory.

_______

Just wanted to raise, so we can fix it. Adding &apos;BrowserCompat&apos; since only Safari / WebKit fails it.

Thanks!</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1990998</commentid>
    <comment_count>1</comment_count>
    <who name="Ahmad Saleem">ahmad.saleem792</who>
    <bug_when>2023-11-08 16:16:29 -0800</bug_when>
    <thetext>PR Attempt - https://github.com/WebKit/WebKit/pull/20199</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1991499</commentid>
    <comment_count>2</comment_count>
    <who name="EWS">ews-feeder</who>
    <bug_when>2023-11-10 04:48:11 -0800</bug_when>
    <thetext>Committed 270525@main (f5f625b22572): &lt;https://commits.webkit.org/270525@main&gt;

Reviewed commits have been landed. Closing PR #20199 and removing active labels.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1991500</commentid>
    <comment_count>3</comment_count>
    <who name="Radar WebKit Bug Importer">webkit-bug-importer</who>
    <bug_when>2023-11-10 04:49:15 -0800</bug_when>
    <thetext>&lt;rdar://problem/118230738&gt;</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>