Files
styled-components/packages
Evan Jacobs ace5dd2933 feat: CSS variable injection, cssvar helper, media query theme pattern for cssvar
When using <ThemeProvider>, css variables synthesized from the given theme
will be automatically injected into the page. The developer can then decide to
consume the variables via the new "cssvar" helper.

In tandem with this change, I have introduced a special key to the theme object
definition ("MQ_THEME_KEY") that allows for media-query based adaptation of theme. Note: this only
applies to cssvar usage, useTheme and such will not adapt the retrieved value based
on MQ.

The primary use case for this functionality is easier SSR support for things like dark mode.
2021-09-21 14:17:35 -04:00
..
2021-09-21 11:48:42 -04:00