<?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>252403</bug_id>
          
          <creation_ts>2023-02-16 08:33:36 -0800</creation_ts>
          <short_desc>HTMLStyleElement mangles -webkit-mask-repeat into unsupported mask-repeat</short_desc>
          <delta_ts>2023-12-17 04:09:41 -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>CSS</component>
          <version>Safari 16</version>
          <rep_platform>Unspecified</rep_platform>
          <op_sys>Unspecified</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>DUPLICATE</resolution>
          <dup_id>243915</dup_id>
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords>InRadar</keywords>
          <priority>P2</priority>
          <bug_severity>Normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Carlos Lopez">clshortfuse</reporter>
          <assigned_to name="Nobody">webkit-unassigned</assigned_to>
          <cc>annevk</cc>
    
    <cc>ntim</cc>
    
    <cc>webkit-bug-importer</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>1934189</commentid>
    <comment_count>0</comment_count>
    <who name="Carlos Lopez">clshortfuse</who>
    <bug_when>2023-02-16 08:33:36 -0800</bug_when>
    <thetext>When creating an HTMLStyleElement with `-webkit-mask-repeat` included, the property is mangled to `mask-repeat`. Webkit supports `-webkit-mask-repeat`, but not `mask-repeat`. Therefore, when attempting to reflect back into another HTMLStyleElement, the style is invalid. This is used to ponyfill/polyfill CSS Modules (native ones).

Test: https://codepen.io/shortfuse/pen/PodwrJE

Chrome PASS
Firefox PASS
WebKit/Safari FAIL

Unprefixing is fine if it&apos;s supported. Firefox unprefixes and that&apos;s fine. Chrome doesn&apos;t unprefix, so that&apos;s also fine. But Webkit will unprefix and break the ability to replicate styles. 

Related:

* https://bugs.webkit.org/show_bug.cgi?id=167255
* https://bugs.webkit.org/show_bug.cgi?id=227967
* https://bugs.webkit.org/show_bug.cgi?id=229082</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1936200</commentid>
    <comment_count>1</comment_count>
    <who name="Radar WebKit Bug Importer">webkit-bug-importer</who>
    <bug_when>2023-02-23 08:34:17 -0800</bug_when>
    <thetext>&lt;rdar://problem/105835488&gt;</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1936264</commentid>
    <comment_count>2</comment_count>
    <who name="Tim Nguyen (:ntim)">ntim</who>
    <bug_when>2023-02-23 11:09:31 -0800</bug_when>
    <thetext>The unprefixed mask-repeat is supported by Safari, and -webkit-mask-repeat is an alias of it.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1936376</commentid>
    <comment_count>3</comment_count>
    <who name="Carlos Lopez">clshortfuse</who>
    <bug_when>2023-02-23 16:12:29 -0800</bug_when>
    <thetext>CSS.supports(&quot;mask-repeat-x&quot;, &quot;initial&quot;) and CSS.supports(&quot;mask-repeat-y&quot;, &quot;initial&quot;) reports false on iPad 16.1

The codepen shows this pretty clearly. &quot;-webkit-mask-repeat&quot; gets mangled to &quot;mask-repeat-x&quot; and &quot;mask-repeat-y&quot; and neither are supported.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1944421</commentid>
    <comment_count>4</comment_count>
    <who name="Tim Nguyen (:ntim)">ntim</who>
    <bug_when>2023-03-27 16:39:38 -0700</bug_when>
    <thetext>mask-repeat-x/mask-repeat-y shouldn&apos;t exist, only -webkit-mask-repeat-x/-webkit-mask-repeat-y should.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1944422</commentid>
    <comment_count>5</comment_count>
    <who name="Tim Nguyen (:ntim)">ntim</who>
    <bug_when>2023-03-27 16:41:06 -0700</bug_when>
    <thetext>Actually, -webkit-mask-repeat-x/-webkit-mask-repeat-y should have been removed as well</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2000264</commentid>
    <comment_count>6</comment_count>
    <who name="Anne van Kesteren">annevk</who>
    <bug_when>2023-12-17 04:09:41 -0800</bug_when>
    <thetext>The -x/-y variants were removed in bug 243915.

*** This bug has been marked as a duplicate of bug 243915 ***</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>