aboutsummaryrefslogtreecommitdiff
path: root/js/src
diff options
context:
space:
mode:
authorRyan Berliner <[email protected]>2021-03-07 08:28:41 -0500
committerXhmikosR <[email protected]>2021-03-16 07:48:50 +0200
commit72d23135799059d4282ea5764455f92f39ced5a5 (patch)
treecbabeb7072f5c487e1300bf585c1a74fa35553e7 /js/src
parent6ef70b342c27445685715f51cfcafb719356870f (diff)
downloadbootstrap-72d23135799059d4282ea5764455f92f39ced5a5.tar.xz
bootstrap-72d23135799059d4282ea5764455f92f39ced5a5.zip
reuse existing popper on show during tooltip fadeout
Diffstat (limited to 'js/src')
-rw-r--r--js/src/tooltip.js6
1 files changed, 3 insertions, 3 deletions
diff --git a/js/src/tooltip.js b/js/src/tooltip.js
index 857f72c8a..de7dcca69 100644
--- a/js/src/tooltip.js
+++ b/js/src/tooltip.js
@@ -284,11 +284,11 @@ class Tooltip extends BaseComponent {
EventHandler.trigger(this._element, this.constructor.Event.INSERTED)
if (this._popper) {
- this._popper.destroy()
+ this._popper.update()
+ } else {
+ this._popper = Popper.createPopper(this._element, tip, this._getPopperConfig(attachment))
}
- this._popper = Popper.createPopper(this._element, tip, this._getPopperConfig(attachment))
-
tip.classList.add(CLASS_NAME_SHOW)
const customClass = typeof this.config.customClass === 'function' ? this.config.customClass() : this.config.customClass