Re: [csswg-drafts] [css-color] Add OKLab, OKLCH (#6642)

> > we've accidentally set a precedent of all the specialized color functions have three-letter names
>
> I don't think any precedent has been set.

rgb(), hsl(), hwb(), lab(), lch(). I specifically said it was *accidental*, but it's still there, and people pattern-match. color() is the exception, and it *is* an exceptional function compared to the others. This doesn't mean we're forced into this, but it does, I think, imply that people will reach for the 3-latter `lab()` over `oklab()`.

Regardless, tho, that wasn't my point. My point is just that when having two names that are variants of each other, one of which is longer than the other, people will naturally reach for the shorter one *by default*; this is a relatively standard principle of language-design UX.  If we think that OKLab is better than Lab for authors, then we'll be doing them a disservice by having `lab()` and `oklab()` as the naming. Having `lab()` be OKLab, and letting people still access Lab with `color(cielab, ...)` would enable people to have access to both when needed, but give authors the more preferable functionality with the easier syntax.

-- 
GitHub Notification of comment by tabatkins
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/6642#issuecomment-930279948 using your GitHub account


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

Received on Wednesday, 29 September 2021 15:21:53 UTC