Intent to prototype and ship: Additional CSS Color (level 4) functions

157 views
Skip to first unread message

Tiaan Louw

unread,
Mar 13, 2023, 12:00:59 PM3/13/23
to dev-pl...@mozilla.org

Around the last week of March 2023, I intend to turn the new [color-4] additions on by default on all platforms. It has been developed behind the “layout.css.more_color_4.enabled” preference.


Summary: New color functionality was added to the CSS color specification (level 4) that will be very useful to developers.  They include new color types, lab(), lch(), oklab() and oklch().  Also some new color spaces were introduced through the color() function, namely srgb (equivalent to the existing rgb/rgba() functions), srgb-linear, display-p3, a98-rgb, prophoto-rgb, rec2020.  Color can also be specified in the XYZ color format through the color() function.  Some additional features like support for the “none” keyword is now also supported.


Bug: https://bugzilla.mozilla.org/show_bug.cgi?id=css-color-4


Bug to turn on by default: https://bugzilla.mozilla.org/show_bug.cgi?id=1813497


Specification: https://drafts.csswg.org/css-color-4/


Platform coverage: All platforms where Gecko is supported.


Preference: layout.css.more_color_4.enabled


DevTools bug: https://bugzilla.mozilla.org/show_bug.cgi?id=1632548


Other browsers:

  • Blink: Shipped in version 111 (Released 2023-03-07)

  • WebKit: Shipped in version 15 (Released 2021-09-20)


Web platform tests: https://wpt.fyi/results/css/css-color


--
Tiaan Louw
Senior Software Engineer | Berlin

Slack: tlouw
Reply all
Reply to author
Forward
0 new messages