Commit d08f7dd8 authored by Chris Rebert's avatar Chris Rebert
Browse files

Merge pull request #13330 from Kronuz/patch-1

Wait for the expected target during a collapse
parents 1254c322 82b066f0
4 merge requests!28721Hot test,!16605Test pull please ignore,!22103test,!25326Adjust examples
Showing with 10 additions and 2 deletions
+10 -2
......@@ -56,7 +56,11 @@
this.transitioning = 1
var complete = function (e) {
if (e && e.target != this.$element[0]) return
if (e && e.target != this.$element[0]) {
this.$element
.one($.support.transition.end, $.proxy(complete, this))
return
}
this.$element
.removeClass('collapsing')
.addClass('collapse in')[dimension]('auto')
......@@ -92,7 +96,11 @@
this.transitioning = 1
var complete = function (e) {
if (e && e.target != this.$element[0]) return
if (e && e.target != this.$element[0]) {
this.$element
.one($.support.transition.end, $.proxy(complete, this))
return
}
this.transitioning = 0
this.$element
.trigger('hidden.bs.collapse')
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment