amphtml
amphtml copied to clipboard
Support `prefers-color-scheme` media query in AMP emails (Dark Mode)
Description
Gmail's automatic dark mode for emails can be hit or miss, and I think AMP has the potential to improve on it by supporting dark mode media queries like this:
@media (prefers-color-scheme: dark) {
/* dark-mode-only CSS */
}
For example, I use images to display the trash icon and plus button in the email below:
| Light Mode | Dark Mode |
|---|---|
But these images automatically get inverted on dark mode, making them appear invisible.
I wish I had more control over how dark mode renders my emails.
Alternatives Considered
An alternative (for my use case, anyway) would be allowing <svg> elements in AMP emails, because those can at least match the text color by doing fill=currentColor
Additional Context
No response