- From: Tab Atkins Jr. via GitHub <sysbot+gh@w3.org>
- Date: Wed, 21 Aug 2024 16:48:38 +0000
- To: public-css-archive@w3.org
From the discussion, there were two significant pushbacks: 1. It might be useful to get the author/OS's original preference, even if the page is currently overriding that preference. 2. We need to be able to respond to color-scheme changes on elements within the page, too, so we should design a style query for this instead. For (1), I accept that this information might be useful, but not useful *within static CSS*. If you need this info, it'll be in JS, as part of a larger preference-handling mechanism. I'm open to being corrected, but currently I see no possibly reason you would want to style the page based on a color scheme *not being used on the page*. Getting this information (the original preference) from a JS API sounds reasonable, tho. For (2), I agree that would be useful (and agree that it needs a special mechanism, since it's about the *used* color scheme, not the computed value, which SQs currently match on). What I disagree is that this is something we should do *instead* of my proposal. I think they're both useful! Notably, circling around to my response to (1), even if we designed such an SQ, in what world is it useful to continue to provide authors with the ability to style the page based on a color scheme that's not being used? What's the use-case for a page with `<meta name=color-scheme content=dark>` matching `@media (prefers-color-scheme: light){...}`? So I'm just confused by this response being an *objection*. If we think the SQ approach would be *more useful*, are we going to just recommend that authors *only* use this mechanism, and mark the MQ as deprecated and recommend against its use? If we *don't* do that, what does our author guidance for the MQ look like? @fantasai, could you elaborate more on why the existence of a proper SQ for color-scheme means we should leave the MQ as it is? I'd love to see a hypothetical use-case. -- GitHub Notification of comment by tabatkins Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/10249#issuecomment-2302539694 using your GitHub account -- Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config
Received on Wednesday, 21 August 2024 16:48:39 UTC