[wp-trac] [WordPress Trac] #53815: safecss_filter_attr removes styles with min() max() and minmax()

WordPress Trac noreply at wordpress.org
Wed Jul 28 12:44:09 UTC 2021


#53815: safecss_filter_attr removes styles with min() max() and minmax()
--------------------------+-----------------------------
 Reporter:  sagarnasit    |      Owner:  (none)
     Type:  defect (bug)  |     Status:  new
 Priority:  normal        |  Milestone:  Awaiting Review
Component:  Formatting    |    Version:
 Severity:  normal        |   Keywords:
  Focuses:                |
--------------------------+-----------------------------
 safecss_filter_attr function eliminates the CSS with min(), max() and
 minmax().

 I was trying to use min() with the recently released theme.json layout
 settings to adjust max-width dynamically based on device width.



 {{{
 "contentSize": "min( calc(100vw - 30px), 620px)",
 "wideSize": "min( calc(100vw - 30px), 1200px)",
 }}}



 WordPress 5.8 release adds support for calc() and var() in #46197 and
 dropping support for IE11, now adding min(), max(), and minmax() would be
 helpfull for theme developers.

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/53815>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list