<?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>286472</bug_id>
          
          <creation_ts>2025-01-24 06:54:47 -0800</creation_ts>
          <short_desc>padding-left / inline-end is not applied in RTL flex containers</short_desc>
          <delta_ts>2026-02-13 12:40:04 -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>Safari 18</version>
          <rep_platform>Mac (Apple Silicon)</rep_platform>
          <op_sys>Unspecified</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          <see_also>https://bugs.webkit.org/show_bug.cgi?id=255346</see_also>
          <bug_file_loc>https://codepen.io/jacobrask/pen/azoQBMv</bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords>BrowserCompat, InRadar</keywords>
          <priority>P2</priority>
          <bug_severity>Normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          <blocked>292022</blocked>
    
    <blocked>307840</blocked>
          <everconfirmed>1</everconfirmed>
          <reporter name="Jacob Rask">jacob</reporter>
          <assigned_to name="fantasai">fantasai.bugs</assigned_to>
          <cc>ahmad.saleem792</cc>
    
    <cc>bfulgham</cc>
    
    <cc>fantasai.bugs</cc>
    
    <cc>karlcow</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>2089506</commentid>
    <comment_count>0</comment_count>
    <who name="Jacob Rask">jacob</who>
    <bug_when>2025-01-24 06:54:47 -0800</bug_when>
    <thetext>An element with
- fixed width
- `dir=rtl`
- either `padding-inline-end` or padding-left`

will not get the padding applied. The padding is not rendered and is not included in the element&apos;s `scrollWidth`. 

See https://codepen.io/jacobrask/pen/azoQBMv</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2089824</commentid>
    <comment_count>1</comment_count>
    <who name="Radar WebKit Bug Importer">webkit-bug-importer</who>
    <bug_when>2025-01-26 08:07:17 -0800</bug_when>
    <thetext>&lt;rdar://problem/143656026&gt;</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2089825</commentid>
    <comment_count>2</comment_count>
    <who name="alan">zalan</who>
    <bug_when>2025-01-26 08:10:23 -0800</bug_when>
    <thetext>Thank you for filing this bug!
Sadly this is not specific to RTL, WebKit fails to account for inline-end padding in both directions.

&lt;style&gt;
.scroller {
  background: yellow;
  width: 100px;
  height: 100px;
  padding-inline-end: 500px;
  overflow-x: auto;
  overflow-y: hidden;
}
.content {
  width: 300px;
  height: 50px;
  background-color: green;
}
&lt;/style&gt;
&lt;div class=scroller&gt;
  &lt;div class=content&gt;&lt;/div&gt;
&lt;/div&gt;</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2154103</commentid>
    <comment_count>3</comment_count>
    <who name="fantasai">fantasai.bugs</who>
    <bug_when>2025-10-24 12:09:29 -0700</bug_when>
    <thetext>Fixed in https://github.com/WebKit/WebKit/pull/52498</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2170374</commentid>
    <comment_count>4</comment_count>
    <who name="fantasai">fantasai.bugs</who>
    <bug_when>2026-01-08 11:51:22 -0800</bug_when>
    <thetext>Relanded in https://github.com/WebKit/WebKit/pull/56240</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>