Context provider for theming.
Loads theme definitions either from a directory of {id}.json files (via the path prop) or from pre-built inline objects (via themes).
{id}.json
path
themes
Descendant components can use the useTheme hook to access color() and style() functions, and setTheme() to switch themes.
color()
style()
setTheme()
Context provider for theming.
Loads theme definitions either from a directory of
{id}.jsonfiles (via thepathprop) or from pre-built inline objects (viathemes).Descendant components can use the useTheme hook to access
color()andstyle()functions, andsetTheme()to switch themes.