Skip to content

Commit

Permalink
fix: Prevent Tooltip setState call if not open (#5363)
Browse files Browse the repository at this point in the history
  • Loading branch information
grommett authored Feb 17, 2020
1 parent b40adbe commit aa276b2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/react/src/components/Tooltip/Tooltip.js
Original file line number Diff line number Diff line change
Expand Up @@ -331,7 +331,7 @@ class Tooltip extends Component {
evt.target &&
this._tooltipEl &&
this._tooltipEl.contains(evt.target);
if (!shouldPreventClose) {
if (!shouldPreventClose && this.state.open) {
this._handleUserInputOpenClose(evt, { open: false });
}
};
Expand Down

0 comments on commit aa276b2

Please sign in to comment.