Closed resource11 closed 5 years ago
Hi @resource11. That’s a fair question, and thanks for reviewing that other thread.
I believe the CSSWG was only answering the first half of your question, which was whether color-mod()
was officially deprecated. color-mod()
is officially deprecated.
Unfortunately, their response left some ambiguity in regards to the second half of your question, which was whether color-mod()
was specifically deprecated in favor of color()
. color-mod()
is not deprecated specifically in favor of color()
color()
and color-mod()
are unrelated functions that accomplish very different things. color()
is for specifying color profiles, whereas color-mod()
was for modifying colors.
For what it’s worth, color()
(for specifying color profiles) has shipped in Safari since 2017.
If you’re curious as to why this plugin still exists and hasn’t been updated, it is because:
color-mod()
was once named color()
and this plugin as written before that name was changed. No one at that time knew how unstable the name was.This is one of the reasons why I created cssdb; to report early spec stability and to track spec changes. I then push breaking changes following semver.
Thanks for the clarification, @jonathantneal, it's helpful.
Re: points 1-3, yes, I read through entire thread (and all the sub-threads that followed), and bookmarked that glorious cssdb a while back. Did I mention that cssdb is glorious?
However!
This is great info for anyone else who wants the background of why this library's still here without digging through the threads of two libraries or the most recent version of the draft spec.
It's also still good to know the additional history behind point 3 (the css-color-function dependency). For anyone curious, here's that thread behind the keeping color().
Personally, I'm still using this older library while the spec on color-mod()
is further developed by the CSSWG. It still works pretty great in our config.
Closing as color()
will not be re-added for modifying colors. I also hope this closed issue helps other. Thanks for following up, @resource11.
Hey @jonathantneal,
Thanks for all the work you do on this plugin! I've been following the thread about
color-mod()
vscolor()
in this repo and in your postcss-color-mod-function repo.The CSS Working group has confirmed that
color-mod()
is deprecated andcolor()
is the spec that is in the latest working draft as of January 2019.Is it possible this plugin will be revived?