Reputation: 85
I am looking to figure how to retain text colors for html emails in Gmail app on Android, set to dark mode. The linear gradient and background-clip method works perfectly for Gmail on iOS but not on Android - referencing this ticket.
Any help would be appreciated.
Upvotes: 0
Views: 53
Reputation: 1
Unfortunately, you can't control color inversion (not at all) in dark mode when using Gmail.
Here's a link going deeper into this issue:
https://www.litmus.com/blog/the-ultimate-guide-to-dark-mode-for-email-marketers
Upvotes: 0
Reputation: 5204
There is no known solution for overriding dark mode on Gmails perfectly.
You mention an hack that works for Gmail iOS--on some versions but not others (e.g. Gmail IMAP business accounts vs normal gmail.com accounts), where background-clip does not work, and defaults instead to "border-box" instead of "text", leaving a big box where you text is. Not a great fallback.
The latest version of Android (13) doesn't let you change the background colour using linear-gradient, but does let you use the text hack. Previous versions are the opposite, so, you shouldn't use it.
With therefore some versions being completely and utterly unreadable, these hacks are not safe to use.
There is a little bit of a safer hack for Gmail iOS text (to keep it white only), but no help for Android (https://www.hteumeuleu.com/2021/fixing-gmail-dark-mode-css-blend-modes/).
Upvotes: 0