I just landed a patch to implement the #rgba and #rrggbbaa syntax
for colors in CSS, and realized I probably should have sent an
intent to dev-platform slightly sooner.

This is an additional syntax for an existing feature already usable
as the rgba() and hsla() color functions, commonly requested by
developers, and recently implemented in both Chromium and WebKit.  I
figured we may as well add it now both because it's popular and
because we're likely to have to for compatibility soon enough.

It allows, for example, the color previously specifiable as
rgba(221, 34, 170, 0.6) or to be specified as #d2a9 or #dd22aa99.
(rgb(221, 34, 170) has always been specifiable as #d2a or #dd22aa;
this just extends the compact hexadecimal syntax to allow alpha.)

It affects only colors specified in CSS, and not those specified in
HTML attributes.

Bug: https://bugzilla.mozilla.org/show_bug.cgi?id=567283
Spec: https://drafts.csswg.org/css-color-4/#hex-notation
Target release: Firefox 49

-David

-- 
𝄞   L. David Baron                         http://dbaron.org/   𝄂
𝄢   Mozilla                          https://www.mozilla.org/   𝄂
             Before I built a wall I'd ask to know
             What I was walling in or walling out,
             And to whom I was like to give offense.
               - Robert Frost, Mending Wall (1914)

Attachment: signature.asc
Description: PGP signature

_______________________________________________
dev-platform mailing list
dev-platform@lists.mozilla.org
https://lists.mozilla.org/listinfo/dev-platform

Reply via email to