Re: [csswg-drafts] [css-images-4] Allow stripes to be used as gradients (#7244)

Agree that keyword is bad; divergent syntaxes based on keywords aren't great for authors, and make Typed OM cry.

I also think that, if we believe it's worthwhile to specify gradients with stripe syntax (which, I believe, hasn't been sufficiently established yet) that it's better to give them their own function rather than nest functions. (aka option 2 over all the others)

> But the big downside here is that the syntax regarding the color stops is not the same because the meaning of thickness is different from the positioning syntax for color stops in gradients.

This is fine? It's literally the entire point of them, after all, and I'm not seeing why this is a problem in `linear-stripes()` but okay in `linear-gradient(..., stripes())`.

> And another downside is that existing functions and data types are not reused. So, any additions to them also require some updates to those functions.

No, we'd just create a non-terminal for the first arg of each of the gradient functions, and then use it in both gradients and stripes. Then any updates apply to all at the same time.

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


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

Received on Monday, 2 May 2022 21:32:44 UTC