Caniuse: Add CSS Color Level 4 new rgb and rgba syntax

Created on 23 Jan 2019  路  4Comments  路  Source: Fyrd/caniuse

Chrome, Firefox, & now Safari Technology Preview support it.

The differences are:

There is a new comma-free syntax, where the optional alpha is separated by a slash:
rgb(128 34 56)
rgb(128 34 56 / 50%)

Floating point values are allowed, and rounded:
rgb(128.5 34.2 56.5) becomes rgb(129 34 57)

rgba() is a pure alias for rgb(), so these are equivalent:
rgb(128 34 56 / 50%)
rgba(128 34 56 / 50%)

webkit bug: https://bugs.webkit.org/show_bug.cgi?id=192321

Duplicate Support data suggestion

Most helpful comment

As well as lab()/lch()/... from this Editor鈥檚 Draft maybe?

All 4 comments

As well as lab()/lch()/... from this Editor鈥檚 Draft maybe?

+1

Syntax with 4th parameter also spec'd for HSL: hsl(0 0% 0% / 20%); 馃帀

Duplicate of #2679

Was this page helpful?
0 / 5 - 0 ratings

Related issues

madebyfabian picture madebyfabian  路  3Comments

SanderMuller picture SanderMuller  路  3Comments

valioDOTch picture valioDOTch  路  3Comments

myfonj picture myfonj  路  3Comments

mhartoft picture mhartoft  路  3Comments