Re: [csswg-drafts] [css-values] Allow sqrt(<length-percentage>) (#3764)

The same reasoning for avoiding dimensions in `pow` apply to `sqrt`.

If `1em` is `16px`, then `sqrt(1em)` would give `1em`, while `sqrt(16px)` would give `4px`, or `0.25em`, which are very different values for what should otherwise be identical input arguments! This sort of input dependency is troublesome for CSS, which generally allows values to be canonicalized freely; it also makes more complex expressions like `sqrt(2em + 10px)` difficult to interpret.

I don't really see how your other proposals are related to this issue, but `root(<number>, <integer>)` could be interesting because I guess `pow(-8, 1/3)` will be NaN like in JS, but `root(-8, 3)` could be `-2`.

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

Received on Tuesday, 26 March 2019 13:52:20 UTC