vendor/assets/javascripts/collapse.js in flashgrid-1.0.13 vs vendor/assets/javascripts/collapse.js in flashgrid-1.0.14
- old
+ new
@@ -1,6 +1,7 @@
-+function ($) { "use strict";
++function ($) {
+ 'use strict';
// COLLAPSE PUBLIC CLASS DEFINITION
// ================================
var Collapse = function (element, options) {
@@ -47,11 +48,11 @@
this.transitioning = 1
var complete = function () {
this.$element
.removeClass('collapsing')
- .addClass('in')
+ .addClass('collapse in')
[dimension]('auto')
this.transitioning = 0
this.$element.trigger('shown.bs.collapse')
}
@@ -115,9 +116,10 @@
return this.each(function () {
var $this = $(this)
var data = $this.data('bs.collapse')
var options = $.extend({}, Collapse.DEFAULTS, $this.data(), typeof option == 'object' && option)
+ if (!data && options.toggle && option == 'show') option = !option
if (!data) $this.data('bs.collapse', (data = new Collapse(this, options)))
if (typeof option == 'string') data[option]()
})
}
\ No newline at end of file