@workday/canvas-kit-popup-stack
Advanced tools
Changelog
4.0.3 (2020-08-04)
Changelog
4.1.1 (2020-07-27)
Changelog
4.1.0 (2020-07-17)
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)