-
Notifications
You must be signed in to change notification settings - Fork 713
[css-color-adjust-1] Emojis in forced colors mode #8064
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
Comments
This is a neat idea. Just two (sad) remarks about status quo from random passers-by:
So the only browser that passes this test is Mozilla Firefox on Windows 10. Google Chrome on Windows 10 let's us set the monochrome (or colourful) font only when forced with explicit
(This particular character โ ๐พ/๐พ๏ธ/๐พ๏ธ โ is not present in that tested "Emoji Presentation Sequences, v15.1" list. Using as illustration for semi-related reasons (*).) |
There are quite promising statements in recent Microsoft announcement about Segoe UI in Windows 11 regarding monochrome Emoji variant: https://microsoft.design/articles/bringing-new-emoji-to-windows-11 (tweet)
and
|
Thanks @myfonj for the update here, adding it to the agenda to see if it is something we should incorporate into the forced colors mode spec |
To some extent this also depends on whether the emoji font is vector or raster, which depends on the platform. Changing the colors of pixels in a raster image (apart from simple grey-scaling, which is unlikely to look good in all cases) is harder than changing the colors in a palette or selecting an alternate palette. |
The CSS Working Group just discussed
The full IRC log of that discussion<TabAtkins> alisonmaher:<emeyer> alisonmaher: Today we aren't doing anything special <emeyer> โฆProposal is to call back to monochrome versions of emojis in forced-color mode <emeyer> โฆOr else, no change to what happens now <emilio> I think making font selection depend on forced-colors feels a bit too subtle <emeyer> astearns: Any opinions? <emilio> But also I don't think it matters much one way or the other <emeyer> (silence) <emeyer> ChrisL: Could you explain the interaction with variation selectors? <emeyer> alisonmaher: I'm not familiar with that <TabAtkins> q+ <astearns> ack emilio <astearns> ack TabAtkins <emeyer> TabAtkins: I think overall this looks reasonable <emeyer> โฆThe effect looks right <emeyer> โฆChris's point about grayscaling emoji is well taken but I don't think there's a good solution here <emeyer> s/emoji/raster emoji/ <emilio> q+ <astearns> ack fantasai <Zakim> fantasai, you wanted to ask if this should depend on font-variant-emoji <emeyer> โฆWe should maybe add a note about that case if we know what we want to say <emeyer> fantasai: We have a font-variant-emoji proeprty, and I'm wondering if this should depend on that <fantasai> normal | text | emoji | unicode <emilio> q- <emeyer> fantasai: Where normal means the user gets to choose and platform conventions are followed <emeyer> โฆtext means 15, emoji is 16, unicode is follow unicode's table <emeyer> astearns: Are you suggesting we change to normal? <emeyer> fantasai: Maybe to normal and unicode? <emeyer> alisonmaher: That sounds reasonable to me <dbaron> s/15/variation selector 15/ <emeyer> astearns: Does that answer your question, Chris? <emeyer> ChrisL: Not sure, but it seems to say this would work with variation selectors unless you did a certain thing, and then it owuldn <astearns> ack emilio <emeyer> s/owuldn/wouldn't/ <emeyer> fantasai: The unicode value is the one that honors the variation selectors <emeyer> โฆtext ignores whatever's happening according to unicode rules and use text, and emoji also ignore the rules and use the color emoji <emeyer> astearns: If I'm following, then are we coming to using monochrome emoji in forced-colors mode if the font-variant-emoji property is set to normal or unicode <emeyer> fantasai: Alternative proposal is to use it for normal and unicode unless variation selector 16 is present, in which case allow that character to override and present in color <emeyer> alisonmaher: Don't have a strong opinion here <emeyer> fantasai: The advantage of the latter proposal is an author could pick out a specific character they want but I doubt people are doing that, so I lean tothe first option <emeyer> s/tothe/to the/ <emeyer> ChrisL: Currently FF is the onlny browser to pass the relevent tests <emeyer> astearns: But not Safari, which doesn't have forced-color modes, yes? <ChrisL> I meant in general, the font-variant-emoji property <emeyer> RESOLVED: use monochrome emoji in forced-colors mode if the font-variant-emoji property is set to normal or unicode <ChrisL> https://wpt.fyi/results/css/css-fonts/parsing/font-variant-emoji-valid.html?label=experimental&label=master&aligned <ChrisL> https://wpt.fyi/results/css/css-fonts/parsing/font-variant-emoji-computed.html?label=experimental&label=master&aligned |
To summarize, CSS authors can add styles like this. :root, input, button, textarea, select {
font-variant-emoji: emoji;
}
@media (forced-colors: active) {
:root, input, button, textarea, select {
font-variant-emoji: normal;
}
} |
Authors could do this, but the resolution was to have browsers fall back to monochrome emojis by default in this mode - this behavior, though, has not yet been implemented |
Currently in forced colors mode, emojis are not adjusted (similarly to images).
For example, when using the following emojis: ๐ค๐ก๐๐โ๐คทโโ๏ธ๐๐๐ค๐ฎ๐๐ป
Blink and Gecko will produce the following in a dark forced color scheme:

However, in EdgeHTML and most Windows apps, emojis will fall back to use a monochrome variant of the emoji colored in the Windows High Contrast text color (i.e.

CanvasText
):The monochrome variant would provide higher levels of contrast and parity with how Windows generally handles emojis in High Contrast. Is this something we should consider recommending or aligning with in the spec?
The text was updated successfully, but these errors were encountered: