W3C home > Mailing lists > Public > public-css-archive@w3.org > December 2019

[csswg-drafts] [css-pseudo][MQ][css-env] Seasonal Theming (#4627)

From: Christoph Päper via GitHub <sysbot+gh@w3.org>
Date: Sun, 22 Dec 2019 13:30:32 +0000
To: public-css-archive@w3.org
Message-ID: <issues.opened-541451193-1577021431-sysbot+gh@w3.org>
Crissov has just created a new issue for https://github.com/w3c/csswg-drafts:

== [css-pseudo][MQ][css-env] Seasonal Theming ==
Although we already have mediaqueries – drafted for level 5 – for user preferences regarding [dark themes](https://drafts.csswg.org/mediaqueries-5/#prefers-color-scheme "prefers-color-scheme: no-preference | light | dark") and [measured environmental lightning](https://drafts.csswg.org/mediaqueries-5/#light-level "light-level: dim | normal | washed"), styling based on the userʼs seasonal and temporal surroundings can be more complex than that. 

Many sites use special (content and) style during specific times of the year (and less often of the month, week or day), or in anticipation thereof. A problem with server-side approaches is that they may not be appropriate within the visitorʼs timezone, location or culture – the result can be irritating or even offensive. 

* Meteorological seasons and lunar crescents are inverted in the opposite hemisphere. 
* The time of day depends on the userʼs longitudinal location and national laws. 
* Availability of sunlight outside buildings depends on the date, (absolute) time and latitudinal location of the user. 
* Holidays depend on national laws, the calendar(s) in use, the predominant local religion or culture and that observed by the user.

I am not sure how to address this the best way in CSS, but I believe it is in scope. Environment variables, pseudo classes and media queries _could_ provide solutions.

~~~~ css
@media sunlit {
  {foo: bar;}
:waning-crescent {foo: bar;} 
foo {bar: env(seasonal-color);} 

Fingerprinting and privacy concerns should be about as serious as for preferred languages and available fonts. 

Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/4627 using your GitHub account
Received on Sunday, 22 December 2019 13:30:34 UTC

This archive was generated by hypermail 2.4.0 : Tuesday, 5 July 2022 06:41:57 UTC