[csswg-drafts] [css-values] Should trigonometric functions work outside of `calc`? (#7265)

Antonio-Laguna has just created a new issue for https://github.com/w3c/csswg-drafts:

== [css-values] Should trigonometric functions work outside of `calc`? ==
Hey there!

I've been reading [the spec for trigonometric functions](https://www.w3.org/TR/css-values-4/#trig-funcs) to implement them on PostCSS Preset Env.

From reading the spec it's not clear that functions shouldn't work only on `calc()`. `pi` and `e` for example have a special note:

> Note: These keywords are only usable within a calculation, such as calc(pow(e, pi) - pi), or min(pi, 5, e). If used outside of a calculation, they’re treated like any other keyword: animation-name: pi; refers to an animation named "pi"; line-height: e; is invalid (not similar to line-height: 2.7, but line-height: calc(e); is).

Webkit's implementation only allows to use inverse trigonometric outside of `calc` since they resolve to `deg` however, even if odd, should it be possible to do `line-height: sin(45deg)` given that it resolves to `.707`?

Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/7265 using your GitHub account


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

Received on Tuesday, 10 May 2022 16:15:53 UTC