1
0
mirror of https://github.com/twbs/bootstrap.git synced 2025-08-17 19:06:40 +02:00
This commit is contained in:
Mark Otto
2016-10-31 21:14:23 -07:00
parent f734814f6b
commit 76d53404b5
36 changed files with 5740 additions and 227 deletions

6
js/dist/tab.js vendored
View File

@@ -139,10 +139,14 @@ var Tab = function ($) {
// private
Tab.prototype._activate = function _activate(element, container, callback) {
var _this2 = this;
var active = $(container).find(Selector.ACTIVE_CHILD)[0];
var isTransitioning = callback && Util.supportsTransitionEnd() && (active && $(active).hasClass(ClassName.FADE) || Boolean($(container).find(Selector.FADE_CHILD)[0]));
var complete = $.proxy(this._transitionComplete, this, element, active, isTransitioning, callback);
var complete = function complete() {
return _this2._transitionComplete(element, active, isTransitioning, callback);
};
if (active && isTransitioning) {
$(active).one(Util.TRANSITION_END, complete).emulateTransitionEnd(TRANSITION_DURATION);