- From: Guillaume via GitHub <sysbot+gh@w3.org>
- Date: Fri, 13 Sep 2024 14:21:41 +0000
- To: public-css-archive@w3.org
cdoublev has just created a new issue for https://github.com/w3c/csswg-drafts: == [mediaqueries-5] Should `aspect-ratio` evaluate to `false` when one side is `0`? == For example, when the user resized a **vertical** browser panel that covers the entire viewport, the aspect ratio resolves to `Infinity` but users might expect it to evaluate to false. ```css @media not (aspect-ratio) { .animated { animation-play-state: paused; } } ``` Chrome always evaluates `aspect-ratio` to true when one side is `0`, Firefox evaluates it to false when the viewport width is `0`. > When written like [`(color)`], the media feature is evaluated in a boolean context. If the feature would be true for any value *other* than the number `0`, a `<dimension>` with the value `0`, the keyword `none`, or a value explicitly defined by that media feature to evaluate as false in a boolean context, the media feature evaluates to true. Otherwise, it evaluates to false. https://drafts.csswg.org/mediaqueries-5/#mq-boolean-context ***aside:*** I would also add `no-preference` and *a function resolving to one of these values* (eg. `calc(0)`, `var(--feature)`) to the list of the "falsy" values. Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/10887 using your GitHub account -- Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config
Received on Friday, 13 September 2024 14:21:41 UTC