aboutsummaryrefslogtreecommitdiff
path: root/js/src
diff options
context:
space:
mode:
authorMark Otto <[email protected]>2016-11-28 13:39:56 -0800
committerMark Otto <[email protected]>2016-11-28 13:39:56 -0800
commit82875586c1ee8d1bc19227bb1e6646a3e87e233d (patch)
treed4d173e362e51f43e363ec4571ae2a3b5977f542 /js/src
parentd6c1fa37bd6dd9bb99fc3c18750c76a3d8c0a3b3 (diff)
parent4f520c7ff301ce42f01e32bd77606ce94384cd13 (diff)
downloadbootstrap-82875586c1ee8d1bc19227bb1e6646a3e87e233d.tar.xz
bootstrap-82875586c1ee8d1bc19227bb1e6646a3e87e233d.zip
Merge branch 'v4-js-carousel' of https://github.com/J2TeaM/bootstrap into J2TeaM-v4-js-carousel
Diffstat (limited to 'js/src')
-rw-r--r--js/src/carousel.js11
-rw-r--r--js/src/popover.js4
-rw-r--r--js/src/tooltip.js4
3 files changed, 5 insertions, 14 deletions
diff --git a/js/src/carousel.js b/js/src/carousel.js
index d85082ce5..e56d4f0f2 100644
--- a/js/src/carousel.js
+++ b/js/src/carousel.js
@@ -353,15 +353,10 @@ const Carousel = (($) => {
$(activeElement)
.one(Util.TRANSITION_END, () => {
$(nextElement)
- .removeClass(directionalClassName)
- .removeClass(direction)
+ .removeClass(`${directionalClassName} ${direction}`)
+ .addClass(ClassName.ACTIVE)
- $(nextElement).addClass(ClassName.ACTIVE)
-
- $(activeElement)
- .removeClass(ClassName.ACTIVE)
- .removeClass(direction)
- .removeClass(directionalClassName)
+ $(activeElement).removeClass(`${ClassName.ACTIVE} ${direction} ${directionalClassName}`)
this._isSliding = false
diff --git a/js/src/popover.js b/js/src/popover.js
index 01804eda6..a08ed4de9 100644
--- a/js/src/popover.js
+++ b/js/src/popover.js
@@ -117,9 +117,7 @@ const Popover = (($) => {
this.setElementContent($tip.find(Selector.TITLE), this.getTitle())
this.setElementContent($tip.find(Selector.CONTENT), this._getContent())
- $tip
- .removeClass(ClassName.FADE)
- .removeClass(ClassName.ACTIVE)
+ $tip.removeClass(`${ClassName.FADE} ${ClassName.ACTIVE}`)
this.cleanupTether()
}
diff --git a/js/src/tooltip.js b/js/src/tooltip.js
index 94f77a2a4..dbc9cf18c 100644
--- a/js/src/tooltip.js
+++ b/js/src/tooltip.js
@@ -377,9 +377,7 @@ const Tooltip = (($) => {
this.setElementContent($tip.find(Selector.TOOLTIP_INNER), this.getTitle())
- $tip
- .removeClass(ClassName.FADE)
- .removeClass(ClassName.ACTIVE)
+ $tip.removeClass(`${ClassName.FADE} ${ClassName.ACTIVE}`)
this.cleanupTether()
}