palantir/blueprint
View on GitHubTooltip with Popover with HOC issues : z-index and hide/unhide
Open
#3,900 opened on Dec 19, 2019
P3Package: coreType: bughelp wanted
Description
Environment
- Package version(s): 3.22
- Browser and OS versions: Firefox/Chrome 78.0 and Windows 10
Steps to reproduce / Actual behavior
I created a sandbox to demonstrate the issue: https://codesandbox.io/s/blueprint-sandbox-l1ih1
When I create a HOC based on BlueprintJS tooltip component I get two weird behaviors when using popovers:
- Tooltips z-index is not consistent. Sometimes it appears behind popovers and sometimes it appears in front (on top of).
Video taken from the sandbox above:

- The behaviour without HOC is that the the tooltip is hidden as soon as the popover is shown With HOC the tooltip appears always.
Expected behavior
- With HOC, the tooltip should not be shown if the popover is open
- Tooltips should be consistent. They should always be on top of everything.
Possible solution
Is this an issue with popperjs? I see the version in latest Blueprint is 1.15.0. Does latest version fix this?
Consider switching to other popup js lib. See this comment: https://github.com/popperjs/popper.js/issues/808#issuecomment-557480207