- From: Tab Atkins Jr. via GitHub <sysbot+gh@w3.org>
- Date: Wed, 06 Oct 2021 16:34:13 +0000
- To: public-css-archive@w3.org
> Secondly, if that were true, #RGB would be the most popular color syntax, which is not the case. I made my point pithily in the middle of a longer argument, but to be more specific: given two *seemingly identical or very similar* pieces of functionality, people will tend to reach for the one with shorter name/syntax, both because it's easier, and because (partially *due to* this effect) API designers usually give the preferred solution a shorter name. Hex notation, especially 3-char hex, is substantially different in both abilities and syntax to any other color function, so it doesn't necessarily fit into this. On the other hand, lab() and oklab() functions, which take essentially identical arguments and output approximately identical colors, are *exactly* the pattern I'm talking about. (Also who would choose "oklab" over "lab"? If it was *better*lab(), sure, but just ok? Pass. ^_^) (Also, for the generic case of "I need a quick color and I know very roughly what it should be but don't care about the details right now", I personally *do* reach for 3-char hex first precisely because it *is* the shortest color syntax that satisfies that use-case.) > One issue with Oklab is that it uses different coordinates than Lab, namely 0-1 ranges instead of 0-100. If we do add such a syntax in CSS, I wonder if there is value in trying to harmonize the two a little. Our lab() doesn't use a 0-100 syntax anyway, it uses 0%-100%. I don't see why we wouldn't use exactly the same thing here. -- GitHub Notification of comment by tabatkins Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/6642#issuecomment-936639186 using your GitHub account -- Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config
Received on Wednesday, 6 October 2021 16:34:14 UTC