mirror of
https://github.com/twbs/bootstrap.git
synced 2025-08-17 19:06:40 +02:00
dist
This commit is contained in:
18
js/dist/tab.js
vendored
18
js/dist/tab.js
vendored
@@ -142,7 +142,7 @@ var Tab = function ($) {
|
||||
var isTransitioning = callback && Util.supportsTransitionEnd() && active && $(active).hasClass(ClassName.FADE);
|
||||
|
||||
var complete = function complete() {
|
||||
return _this2._transitionComplete(element, active, isTransitioning, callback);
|
||||
return _this2._transitionComplete(element, active, callback);
|
||||
};
|
||||
|
||||
if (active && isTransitioning) {
|
||||
@@ -150,15 +150,11 @@ var Tab = function ($) {
|
||||
} else {
|
||||
complete();
|
||||
}
|
||||
|
||||
if (active) {
|
||||
$(active).removeClass(ClassName.SHOW);
|
||||
}
|
||||
};
|
||||
|
||||
_proto._transitionComplete = function _transitionComplete(element, active, isTransitioning, callback) {
|
||||
_proto._transitionComplete = function _transitionComplete(element, active, callback) {
|
||||
if (active) {
|
||||
$(active).removeClass(ClassName.ACTIVE);
|
||||
$(active).removeClass(ClassName.SHOW + " " + ClassName.ACTIVE);
|
||||
var dropdownChild = $(active.parentNode).find(Selector.DROPDOWN_ACTIVE_CHILD)[0];
|
||||
|
||||
if (dropdownChild) {
|
||||
@@ -176,12 +172,8 @@ var Tab = function ($) {
|
||||
element.setAttribute('aria-selected', true);
|
||||
}
|
||||
|
||||
if (isTransitioning) {
|
||||
Util.reflow(element);
|
||||
$(element).addClass(ClassName.SHOW);
|
||||
} else {
|
||||
$(element).removeClass(ClassName.FADE);
|
||||
}
|
||||
Util.reflow(element);
|
||||
$(element).addClass(ClassName.SHOW);
|
||||
|
||||
if (element.parentNode && $(element.parentNode).hasClass(ClassName.DROPDOWN_MENU)) {
|
||||
var dropdownElement = $(element).closest(Selector.DROPDOWN)[0];
|
||||
|
Reference in New Issue
Block a user