-
Notifications
You must be signed in to change notification settings - Fork 4.1k
Allow negated prefers-reduced-motion media queries in AMP validator #40454
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Allow negated prefers-reduced-motion media queries in AMP validator #40454
Conversation
|
Hi @erwinmombay 👋 This PR updates the AMP validator to allow negated All CI checks are passing. Thanks! |
milindmore22
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
|
thanks @Durvesh-dev , reviewing. |
banaag
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could you add a validator test for this? Something like: https://github.com/ampproject/amphtml/pull/39558/files#diff-cf571d8f18ca528dbc7956b0a627f9f486ef84b415beaf3ba4a4d6355b4cb4bf
Summary
Fixes AMP validator incorrectly flagging valid CSS media queries using
not (prefers-reduced-motion: reduce)as malformed.Details
notas a valid media query modifier in the validator specMotivation
This syntax is valid per CSS Media Queries Level 5 and is already used in
AMP documentation (e.g. amp-animation).
Fixes #40384