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

> So overrides can only opt-in rather than opt-out of accessibility features.

I'm not sure I understand why this is helpful.

When switched on by the user/user-agent, the various `prefers-*` MQ do not turn on accessibility features supplied by the user-agent. They inform the site that the user has a preference, and it's up to the site to do something about it. By default, nothing happens. If the site wants to ignore the user's preference, they already can, simply by doing nothing.

If the site has some reason to think that the user's preference (or lack thereof) is different from what it's getting from the ua, It can chose to do something else, or to do nothing. We cannot change that. It doesn't matter whether that comes from something reasonable like a settings dialog, or unreasonable like the author thinking that everyone surely agrees with their personal tastes: it's up to the author to supply the feature, so if they think they should not, there's nothing we can do about it.

So, I don't think we're protecting the user from anything by preventing the site from opting out.

Note: There are cases where the browser may combine a `prefers-*` MQ with some behavior forcibly done by the browser, but that's a separate thing, and these overrides would have no influence on those. For example, User agents may consider setting `prefers-reduced-data` based on the same user or system preference as they use to set the `Save-Data` HTTP request header. But the `Save-Data` HTTP request header is not *caused by* the `prefers-reduced-data` MQ, and even if a site overrode that MQ, it would have no effect on the HTTP header. 

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


-- 
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config

Received on Monday, 23 October 2023 02:15:48 UTC