Skip to content

Commit

Permalink
Add possibility to cancel from onShow event
Browse files Browse the repository at this point in the history
  • Loading branch information
emilpalsson committed Jun 23, 2020
1 parent b2e430e commit 60aa29d
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/Tooltip/js/tippy.js
Original file line number Diff line number Diff line change
Expand Up @@ -169,7 +169,9 @@ class Tippy {
return
}

this.callbacks.show.call(popper)
if (this.callbacks.show.call(popper, data.el) === false) {
return
}

// Custom react
if (data.settings && data.settings.open === false) {
Expand Down

0 comments on commit 60aa29d

Please sign in to comment.