Re: [csswg-drafts] [css-values]: Express conditional values in a more terse way (#5009)

I agree with @LeaVerou that var-like behavior is not a problem for authors, even if it was an unfortunate compromise, and that _many_ use-cases (flexbox & grid-templates stand out) rely on any-value output. Parse-time fallback is great, but we also have `@supports`. I do not believe that authors will spend the time to distinguish between two seemingly-identical functions just to get parse-time fallback in a subset of use-cases. Instead we'd be introducing non-obvious failures, any time an author without full IACVT knowledge (most authors) adds a `var()` inside an existing `cond()`, and suddenly breaks the fallback. Using a math function is not a stable promise that you get parse-time fallback. As a teacher, I would always encourage people to use `@supports` anyway, for either function, just in case.

I like where Lea is going with the `if()` proposal, designed to handle a wide range of condition-types and outputs.

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


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

Received on Thursday, 25 February 2021 17:38:19 UTC