Re: [csswg-drafts] [css-color-4] Consider removing lab(...) and lch(...) syntax and using color(lab ...) and color(lch ...) only (#5887)

The CSS Working Group just discussed `[css-color-4] Consider removing lab(...) and lch(...) syntax and using color(lab ...) and color(lch ...) only`, and agreed to the following:

* `RESOLVED: Drop lab from color()`

<details><summary>The full IRC log of that discussion</summary>
&lt;dael> Topic: [css-color-4] Consider removing lab(...) and lch(...) syntax and using color(lab ...) and color(lch ...) only<br>
&lt;chris> q+<br>
&lt;dael> github: https://github.com/w3c/csswg-drafts/issues/5887<br>
&lt;dael> leaverou_: I did not open this so not sure I should present. I could.<br>
&lt;dael> chris: I'm happy to present<br>
&lt;astearns> ack chris<br>
&lt;dael> chris: Basically issue is we have 2 ways to express lab<br>
&lt;dael> chris: Have to be kept separate in the impl. Keep track of which used. Do we need 2?<br>
&lt;leaverou_> q+<br>
&lt;dael> chris: Can delete either. People like lab b/c brief. Only added lab to color b/c sure why not when smfr asked. Since Apple is now asking to remove easiest to remove<br>
&lt;leaverou_> +1 to smfr's reasoning for color()<br>
&lt;TabAtkins> q+<br>
&lt;argyle> +1<br>
&lt;dael> smfr: Talked to Sam. Didn't come to agreement. Don't htink we're arbiters of CSS. Rational to add it is wanted color function to be superset or union of all ways to desc colors. Where there is a color function with a color space where that space could be used in first arg<br>
&lt;dael> smfr: Someone uses tooling doing all their colors with color funt and want roundtrip with 10bit<br>
&lt;dael> smfr: Okay if we remove, but for completeness it makes sense to have<br>
&lt;astearns> ack leaverou_<br>
&lt;dael> chris: Understand argument. Would be nice. As someone pointed out we missed with devicecmyk and lch. That was different a while ago but if we wanted to do this need to add lch into the color function so you would need to say this param is a hue. Doable but complex<br>
&lt;florian> q+<br>
&lt;dael> leaverou_: Opposed to dropping. nice readable syntax. could instead drop distinction and allow browsers to store color lab and lab function as the same thing.<br>
&lt;dael> leaverou_: Usefult o keep distinction for srgb colors. But spec by color isn't legacy and for lab it's the same colors. If it's complex for impl no reason to stor ehte syntax<br>
&lt;dael> leaverou_: Agree with smfr there's value in color desc all colors. Allows lib to serialize whatever color w/o special case. Nice to have, not a huge need. Nice if possible. Good to add lch and every other color we support<br>
&lt;dael> leaverou_: Might even be value in normalizing coord in a 0-1 range and then color can generic spec any color supported<br>
&lt;astearns> ack TabAtkins<br>
&lt;chris> angles in [0..1] eww no<br>
&lt;dael> TabAtkins: on the idea of unifying everything into color with lch and hsl, color only ccepts numbers and not angles. I'm not familar with math, but I don't htink color space ever has angle would would be special casing angle to the pre-defined ones. Feels odd to dup the work to color. Poss, but awk<br>
&lt;dael> TabAtkins: on leaverou_ side I would rather a single way to represent rather then 2 ways to rep with 1 serialization. I could be okay, but don't like alaising to a different value then spec and since we don't have legacy need we shouldn't invent one<br>
&lt;astearns> ack argyle<br>
&lt;dael> TabAtkins: Support keeping lab and lch functions and if nec drop lab from color<br>
&lt;argyle> i am?<br>
&lt;argyle> np =)<br>
&lt;astearns> ack florian<br>
&lt;dael> florian: Wondering, if we drop the keywords for simplification we're left with one double? Or is color with srgb keyword is that different behavior?<br>
&lt;dael> chris: It is. Higher precision requirement<br>
&lt;dael> leaverou_: Interpolates differently as well<br>
&lt;dael> florian: Thank you<br>
&lt;dael> astearns: Seems like things have gone somewhat afield. The question of if we have lab and lch in color function or just lab?<br>
&lt;dael> chris: Just lab<br>
&lt;dael> smfr: To defend Sam's point he would prefer not to have color(labl) and lab() so prefer to drop one. My preference is weak so willing to drop color(lab)<br>
&lt;dael> chris: Can you explain why tracking which method used? Seralization?<br>
&lt;dael> smfr: Yep<br>
&lt;dael> leaverou_: If they were parse time aliases would have same problem?<br>
&lt;dael> emilio: No, but then need to decide one<br>
&lt;dael> astearns: And then arbitrarily changing how things spec in style sheet for impl-only reason<br>
&lt;dael> astearns: My uninformed opinion, I kind of agree with smfr that it would be nice to have color spec any colora t all, but sounds like problems with colors that use angle. Unclear if we could get to a superset colorf unction.<br>
&lt;dael> astearns: Sounds like a slight reason to drop lab from color. no strong opinion<br>
&lt;argyle> agree with what alan just said<br>
&lt;dael> chris: My preference too. Can see both arguments<br>
&lt;dael> smfr: Can live with dropping lab from color<br>
&lt;chris> +1<br>
&lt;dael> astearns: Prop: Drop lab from color()<br>
&lt;dael> astearns: Anyone arguing against?<br>
&lt;dael> astearns: Objections?<br>
&lt;dael> RESOLVED: Drop lab from color()<br>
&lt;chris> Thanks for the explanation @smfr helpful<br>
&lt;dael> leaverou_: Question, I always assumed if we want to add new color spaces we first add in color function and if we see huge usage we might add as separate color functions<br>
&lt;fantasai> +1 leaverou_<br>
&lt;dael> leaverou_: Means in future might have color color formats spec by both color() and own function. Wouldn't that cause same problem?<br>
&lt;dael> astearns: it would<br>
&lt;chris> It would, but no clash as the custom one use dashed-ident<br>
&lt;dael> astearns: but I think argument there is this is for authors. Huge usage is worth extra effort on impl side. Maybe we wouldn't get to that decision unless usage is off the charts<br>
&lt;chris> I see<br>
&lt;dael> leaverou_: chris, not talking custom color spaces, talking about new predefined<br>
&lt;dael> astearns: I can see if at some point we figure out how to put angle spec colors into color funct we can revist color function being a strict superset and re-add lab<br>
&lt;dael> astearns: I don't know we have a strong precident for colors in future<br>
&lt;dael> leaverou_: Can have angle in color. Current grammar doesn't allow, but not reason not to<br>
&lt;chris> The current grammar allows hue angles to omit a unit<br>
&lt;dael> TabAtkins: Id on't think we can do custom colors spaces with angle so would have to special case predefined which is weird<br>
&lt;dael> leaverou_: It does<br>
&lt;faceless> +1 to "ew"<br>
&lt;dael> fantasai: Could predfine at 360deg<br>
&lt;fantasai> s/predefine at/define as 100% of<br>
&lt;dael> chris: Ew. Can drop unit ID right now so can say 40 for 40deg<br>
&lt;argyle> 1 is pretty convenient to use with display-p3 tho, i know i'm hitting max without knowing what the max number is<br>
&lt;dael> astearns: Is there an issue?<br>
&lt;dael> chris: No<br>
&lt;dael> astearns: Should be?<br>
&lt;dael> TabAtkins: No reason to yet. No color which can be spec uses an angle yet<br>
&lt;dael> chris: I bleive that's correct<br>
&lt;dael> astearns: leaverou_ should we revisit the resolution or move on?<br>
&lt;dael> leaverou_: okay<br>
</details>


-- 
GitHub Notification of comment by css-meeting-bot
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/5887#issuecomment-839930964 using your GitHub account


-- 
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config

Received on Wednesday, 12 May 2021 16:42:38 UTC