Bug 198765 - html.css and MediaFeatureNames.h refer to prefers-dark-interface" which was renamed to "prefers-color-scheme"
Summary: html.css and MediaFeatureNames.h refer to prefers-dark-interface" which was r...
Status: NEW
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebKit Misc. (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Timothy Hatcher
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2019-06-11 13:11 PDT by Simon Fraser (smfr)
Modified: 2024-03-11 17:19 PDT (History)
5 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Simon Fraser (smfr) 2019-06-11 13:11:56 PDT
prefers-dark-interface is the old name.
Comment 1 Ahmad Saleem 2024-03-11 17:19:29 PDT
We still have this:

https://searchfox.org/wubkat/rev/711120e7edec012527620d07bf63d85713a180fd/Source/WebCore/css/html.css#483

@media (prefers-dark-interface) {
    input {
        background-color: transparent;
    }

...

and

https://searchfox.org/wubkat/rev/711120e7edec012527620d07bf63d85713a180fd/Source/WebCore/css/query/MediaQueryFeatures.cpp#530


const FeatureSchema& prefersDarkInterface()
{
    static MainThreadNeverDestroyed<IdentifierSchema> schema {
        "prefers-dark-interface"_s,
        FixedVector { CSSValueNoPreference, CSSValuePrefers },
        [](auto& context) {
            Ref page = *context.document->frame()->page();
            bool prefersDarkInterface = page->useSystemAppearance() && page->useDarkAppearance();

            return MatchingIdentifiers { prefersDarkInterface ? CSSValuePrefers : CSSValueNoPreference };
        }
    };
    return schema;
}

..

___

We have following test as well - use-system-appearance-user-stylesheet-parsing.html