W3C home > Mailing lists > Public > public-css-archive@w3.org > August 2021

Re: [csswg-drafts] [mediaqueries-5] Script control of (prefers-*) queries (#6517)

From: Tab Atkins Jr. via GitHub <sysbot+gh@w3.org>
Date: Fri, 13 Aug 2021 21:56:46 +0000
To: public-css-archive@w3.org
Message-ID: <issue_comment.created-898739613-1628891805-sysbot+gh@w3.org>
> Namely, a very natural extension is one that lets you toggle preferences per site and if there's only one thing to set then there's a race between the site and the extension: if they both attempt to override the preference the last one to do so wins.

Sure, but why would you use both a site-based and an extension-based toggle on the same page? One or the other would work fine, so I don't think we need to worry about colliding.

(And it's not like the extension can guarantee things anyway, since the page might use *only* a manually-set light/dark pref, initialized from the standard MQ.)

> Also unless overriding media queries rolls out with custom media queries how would you feature test this without overrding a preference which could itself mess with such an extension.

In this suggestion, overriding is *part* of custom MQs, so they'd go out together.

-- 
GitHub Notification of comment by tabatkins
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/6517#issuecomment-898739613 using your GitHub account


-- 
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config
Received on Friday, 13 August 2021 21:56:48 UTC

This archive was generated by hypermail 2.4.0 : Tuesday, 19 October 2021 01:31:48 UTC