Re: [csswg-drafts] [mediaqueries] Non-positive value should be invalid for 'resolution' feature

As a general rule, banning zero from a `<number>` or `<dimension>` is disallowed; it's an open range <https://wiki.csswg.org/spec/limited-ranges>.  

perspective()'s special zero behavior is a worst-case thing; the behavior impls settled on is nonsensical from a numerical perspective, not to mention totally discontinuous, and we're sticking with it only because content depends on it.  If its behavior had been properly described originally, and someone had noticed it, it would have been changed in the design phase (almost certainly by specifying that there's a UA-specific minimum value).  It is never an example to look to, and cannot be used to justify more bad behavior.

The correct behavior for this case is fairly similar, in that as the value approaches 0 the size of the pixel approaches infinity.  The correct solution is thus to define that negative values are invalid, and that there's a UA-specific minimum value.

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

Received on Wednesday, 24 May 2017 07:54:15 UTC