You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Theming responsibility should be delegated to the consuming project for 3 reasons:
Currently we get around Emotion lib integration issues by creating our own context in uikit and exporting useTheme with our own ThemeProvider
This works because context is shared.
css={(theme) => {...}} this should work but Emotion uses it's own jsx runtime which in turn uses its own theme context, so our theme will always be empty object
suggestion is to move theming out of UIKit and have the consuming project decide the process
we can still export a default theme that is compatible with an Emotion theme provider
Types are too tightly coupled to the defaultTheme. Extending the theme in a project will cause type errors.
no reason for reactivity of theme provider. can just use normal object
if a project wants reactivity eg. for a dark mode it can be added to its project
The text was updated successfully, but these errors were encountered:
Theming responsibility should be delegated to the consuming project for 3 reasons:
Currently we get around Emotion lib integration issues by creating our own context in uikit and exporting
useTheme
with our ownThemeProvider
This works because context is shared.
css={(theme) => {...}}
this should work but Emotion uses it's own jsx runtime which in turn uses its own theme context, so our theme will always be empty objectsuggestion is to move theming out of UIKit and have the consuming project decide the process
we can still export a default theme that is compatible with an Emotion theme provider
Types are too tightly coupled to the defaultTheme. Extending the theme in a project will cause type errors.
no reason for reactivity of theme provider. can just use normal object
if a project wants reactivity eg. for a
dark mode
it can be added to its projectThe text was updated successfully, but these errors were encountered: