Skip to content

v4.1.0

Compare
Choose a tag to compare
@NicholasBoll NicholasBoll released this 17 Jul 22:53
· 2262 commits to master since this release
7acb125

2020-07-17

Components

Infrastructure

Theming

  • refactor(common): Update pickForegroundColor to use fallback color logic (#752) @donovangini

Breaking Changes:

  • feat(popup-stack): Add adapter API to integrate with other popup systems (#782) @NicholasBoll

This is a potentially breaking change if you use usePopupStack and ReactDOM.createPortal(contents, document.body):
We added createContainer to PopupStack. React no longer controls the element that is given to the the PopupStack. The PopupStack will now create a containing element that your content should render into. If you recognize this pattern, you'll need to render into stackRef.current instead of document.body.

Before:

const ref = React.createRef<HTMLDivElement>(null);

usePopupStack(ref)

React.createPortal(contents, document.body)

Now

const stackRef = usePopupStack()

React.createPortal(contents, stackRef.current)