Skip to content

v3.0.0

Compare
Choose a tag to compare
@aribouius aribouius released this 26 May 16:27
· 12 commits to master since this release

Breaking Changes

  • <ThemeProvider />
    • The compose prop now only accepts a boolean, and defaults to true. The ability to customize the previous context theme was moved to the theme prop.
  • themed
    • No longer injects the entire context theme when a theme selector is not provided. Themes must now be explicitly assigned.
    • Function theme selectors now receive a previously bound theme as the first argument, and the context theme as the second argument.
    • Calling themed with a previously themed component no longer creates a new wrapping component, but instead creates a modified copy of the original.
    • Themes now get composed with previously assigned themes by default.
    • No longer expects the compose option to be a boolean. It now must be a function that composes themes.
  • <Themed />
    • Theme objects provided via theme prop are now composed by default.
    • Support for the themeConfig prop has been removed.
  • composeTheme
    • This function has been replaced by compose.

Updates

  • themed
    • Is now also the default export (c07f99f).
    • Now supports local theme objects (9accf08).
    • Now supports array context theme selectors (0a083c5).
    • Has a new pure option (81d12c2).
    • Exposes the wrapped component as a static property (623b301).
    • Hoists static properties from the wrapped component (d5eea34).
    • Now supports chaining of themed components (0a083c5).
  • <Themed />
    • Now allows theme prop to be a function that receives the previous theme and context theme and returns a customized final theme.
    • Has a new childRef prop (3e22961).

Please refer to the API Reference for a complete overview of the new plugin API.