- From: Lea Verou via GitHub <sysbot+gh@w3.org>
- Date: Sun, 14 Apr 2024 19:54:54 +0000
- To: public-css-archive@w3.org
> `none` is not a placeholder for the corresponding channel (i.e. `&` in nesting). `none` is a way to make or represent a missing channel. Missing/powerless channels are filled in with the corresponding value from the other color. > > This would be a very large change and one that opens up more questions than it answers. I honestly have no idea what is confusing you here. Yes, `none` represents a missing channel, and gets a concrete value when interpolated with another color that has `none` in the same place. Until then, it stays `none` except when that is _really_ not possible. The spec does have some issues around this and needs to be clarified ASAP, but that's far from "a very large change". > How does it work when channel keywords are used in different positions? > > ``` > color-mix( > in lab, > lab(50% none none), > lab(50% 10% 20%) > ) > > lab(50% 10% 20%) > ``` Yup. > ``` > color-mix( > in lab, > lab(from lab(50% none none) l b a), > lab(50% 10% 20%) > ) > > lab(50% 10% 20%) > ``` `lab(from lab(50% none none) l b a)` becomes `lab(50% none none)` and `color-mix(in lab, lab(50% none none), lab(50% 10% 20%))` is `lab(50% 10% 20%)` so yeah, that's the correct result. > ``` > color-mix( > in lab, > lab(from lab(50% none none) l a b), > lab(50% 10% 20%) > ) > > lab(50% 10% 20%) > ``` Yup. > ``` > color-mix( > in lab, > lab(from lab(50% none none) l calc(b) calc(a)), > lab(50% 10% 20%) > ) > > lab(50% 10% 20%) > /* or? */ > lab(50% 20% 10%) > ``` `lab(50% 10% 20%)` and the spec needs to clarify this. We cannot have discontinuities because something was wrapped in `calc()`. -- GitHub Notification of comment by LeaVerou Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/10151#issuecomment-2054167970 using your GitHub account -- Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config
Received on Sunday, 14 April 2024 19:54:55 UTC