<?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>184027</bug_id>
          
          <creation_ts>2018-03-26 16:24:27 -0700</creation_ts>
          <short_desc>Allow mathematical expressions in image sizes</short_desc>
          <delta_ts>2026-04-13 01:04:30 -0700</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>WebKit</product>
          <component>DOM</component>
          <version>WebKit Nightly Build</version>
          <rep_platform>Unspecified</rep_platform>
          <op_sys>Unspecified</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>DUPLICATE</resolution>
          <dup_id>304915</dup_id>
          <see_also>https://bugs.webkit.org/show_bug.cgi?id=259812</see_also>
          <bug_file_loc>https://github.com/whatwg/html/pull/3084</bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P2</priority>
          <bug_severity>Normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="John Musgrave">musgravejw</reporter>
          <assigned_to name="Nobody">webkit-unassigned</assigned_to>
          <cc>annevk</cc>
    
    <cc>cdumez</cc>
    
    <cc>cyb.ai.815</cc>
    
    <cc>domfarolino</cc>
    
    <cc>fotis.papadogeorgopoulos</cc>
    
    <cc>koivisto</cc>
    
    <cc>mike</cc>
    
    <cc>philip</cc>
    
    <cc>simon.fraser</cc>
    
    <cc>zcorpan</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>1409440</commentid>
    <comment_count>0</comment_count>
    <who name="John Musgrave">musgravejw</who>
    <bug_when>2018-03-26 16:24:27 -0700</bug_when>
    <thetext>Currently `calc()` is supported as a CSS mathematical function. The CSS Values and Units Level 4 Specification describes a list of math functions [1] consisting of `calc()` in addition to `min()` and `max()`.  Suggest implementing recent specification changes.

The motivation for opening this bug is the reference to the aforementioned mathematical functions in the HTML Standard [2], which supports the appearance of mathematical functions in the `sizes` attribute on &lt;img&gt; elements.

[1]: https://drafts.csswg.org/css-values/#math-function
[2]: https://github.com/whatwg/html/pull/3084 &amp; https://github.com/w3c/web-platform-tests/pull/10167</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1409569</commentid>
    <comment_count>1</comment_count>
    <who name="Dominic Farolino">domfarolino</who>
    <bug_when>2018-03-27 09:50:56 -0700</bug_when>
    <thetext>Note this issue might be a duplicate of one, though I&apos;m not sure. Tab told me that the reason `min()` and `max()` made it into the spec as mathematical functions was because Apple said they were going to implement them, so there might already be an issue tracking their implementation. Either way... :)</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1949397</commentid>
    <comment_count>2</comment_count>
    <who name="Philip Jägenstedt">philip</who>
    <bug_when>2023-04-18 01:08:34 -0700</bug_when>
    <thetext>https://wpt.fyi/results/html/semantics/embedded-content/the-img-element/sizes/parse-a-sizes-attribute-width-1000px.html?label=experimental&amp;label=master&amp;aligned shows 4 Safari-only test failures due to min() and max() not being supported.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2199605</commentid>
    <comment_count>3</comment_count>
    <who name="Anne van Kesteren">annevk</who>
    <bug_when>2026-04-13 01:04:30 -0700</bug_when>
    <thetext>

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

    </bug>

</bugzilla>