/*! * bootstrap v3.3.0 (http://getbootstrap.com) * copyright 2011-2014 twitter, inc. * licensed under mit (https://github.com/twbs/bootstrap/blob/master/license) */ /*! * generated using the bootstrap customizer (http://v3.bootcss.com/customize/?id=45efb871570c7c1a9ae33cc761abd068) * config saved to config.json and https://gist.github.com/45efb871570c7c1a9ae33cc761abd068 */ if (typeof jquery === 'undefined') { throw new error('bootstrap\'s javascript requires jquery') } +function ($) { var version = $.fn.jquery.split(' ')[0].split('.') if ((version[0] < 2 && version[1] < 9) || (version[0] == 1 && version[1] == 9 && version[2] < 1)) { throw new error('bootstrap\'s javascript requires jquery version 1.9.1 or higher') } }(jquery); /* ======================================================================== * bootstrap: alert.js v3.3.0 * http://getbootstrap.com/javascript/#alerts * ======================================================================== * copyright 2011-2014 twitter, inc. * licensed under mit (https://github.com/twbs/bootstrap/blob/master/license) * ======================================================================== */ +function ($) { 'use strict'; // alert class definition // ====================== var dismiss = '[data-dismiss="alert"]' var alert = function (el) { $(el).on('click', dismiss, this.close) } alert.version = '3.3.0' alert.transition_duration = 150 alert.prototype.close = function (e) { var $this = $(this) var selector = $this.attr('data-target') if (!selector) { selector = $this.attr('href') selector = selector && selector.replace(/.*(?=#[^\s]*$)/, '') // strip for ie7 } var $parent = $(selector) if (e) e.preventdefault() if (!$parent.length) { $parent = $this.closest('.alert') } $parent.trigger(e = $.event('close.bs.alert')) if (e.isdefaultprevented()) return $parent.removeclass('in') function removeelement() { // detach from parent, fire event then clean up data $parent.detach().trigger('closed.bs.alert').remove() } $.support.transition && $parent.hasclass('fade') ? $parent .one('bstransitionend', removeelement) .emulatetransitionend(alert.transition_duration) : removeelement() } // alert plugin definition // ======================= function plugin(option) { return this.each(function () { var $this = $(this) var data = $this.data('bs.alert') if (!data) $this.data('bs.alert', (data = new alert(this))) if (typeof option == 'string') data[option].call($this) }) } var old = $.fn.alert $.fn.alert = plugin $.fn.alert.constructor = alert // alert no conflict // ================= $.fn.alert.noconflict = function () { $.fn.alert = old return this } // alert data-api // ============== $(document).on('click.bs.alert.data-api', dismiss, alert.prototype.close) }(jquery); /* ======================================================================== * bootstrap: button.js v3.3.0 * http://getbootstrap.com/javascript/#buttons * ======================================================================== * copyright 2011-2014 twitter, inc. * licensed under mit (https://github.com/twbs/bootstrap/blob/master/license) * ======================================================================== */ +function ($) { 'use strict'; // button public class definition // ============================== var button = function (element, options) { this.$element = $(element) this.options = $.extend({}, button.defaults, options) this.isloading = false } button.version = '3.3.0' button.defaults = { loadingtext: 'loading...' } button.prototype.setstate = function (state) { var d = 'disabled' var $el = this.$element var val = $el.is('input') ? 'val' : 'html' var data = $el.data() state = state + 'text' if (data.resettext == null) $el.data('resettext', $el[val]()) // push to event loop to allow forms to submit settimeout($.proxy(function () { $el[val](data[state] == null ? this.options[state] : data[state]) if (state == 'loadingtext') { this.isloading = true $el.addclass(d).attr(d, d) } else if (this.isloading) { this.isloading = false $el.removeclass(d).removeattr(d) } }, this), 0) } button.prototype.toggle = function () { var changed = true var $parent = this.$element.closest('[data-toggle="buttons"]') if ($parent.length) { var $input = this.$element.find('input') if ($input.prop('type') == 'radio') { if ($input.prop('checked') && this.$element.hasclass('active')) changed = false else $parent.find('.active').removeclass('active') } if (changed) $input.prop('checked', !this.$element.hasclass('active')).trigger('change') } else { this.$element.attr('aria-pressed', !this.$element.hasclass('active')) } if (changed) this.$element.toggleclass('active') } // button plugin definition // ======================== function plugin(option) { return this.each(function () { var $this = $(this) var data = $this.data('bs.button') var options = typeof option == 'object' && option if (!data) $this.data('bs.button', (data = new button(this, options))) if (option == 'toggle') data.toggle() else if (option) data.setstate(option) }) } var old = $.fn.button $.fn.button = plugin $.fn.button.constructor = button // button no conflict // ================== $.fn.button.noconflict = function () { $.fn.button = old return this } // button data-api // =============== $(document) .on('click.bs.button.data-api', '[data-toggle^="button"]', function (e) { var $btn = $(e.target) if (!$btn.hasclass('btn')) $btn = $btn.closest('.btn') plugin.call($btn, 'toggle') e.preventdefault() }) .on('focus.bs.button.data-api blur.bs.button.data-api', '[data-toggle^="button"]', function (e) { $(e.target).closest('.btn').toggleclass('focus', e.type == 'focus') }) }(jquery); /* ======================================================================== * bootstrap: carousel.js v3.3.0 * http://getbootstrap.com/javascript/#carousel * ======================================================================== * copyright 2011-2014 twitter, inc. * licensed under mit (https://github.com/twbs/bootstrap/blob/master/license) * ======================================================================== */ +function ($) { 'use strict'; // carousel class definition // ========================= var carousel = function (element, options) { this.$element = $(element) this.$indicators = this.$element.find('.carousel-indicators') this.options = options this.paused = this.sliding = this.interval = this.$active = this.$items = null this.options.keyboard && this.$element.on('keydown.bs.carousel', $.proxy(this.keydown, this)) this.options.pause == 'hover' && !('ontouchstart' in document.documentelement) && this.$element .on('mouseenter.bs.carousel', $.proxy(this.pause, this)) .on('mouseleave.bs.carousel', $.proxy(this.cycle, this)) } carousel.version = '3.3.0' carousel.transition_duration = 600 carousel.defaults = { interval: 5000, pause: 'hover', wrap: true, keyboard: true } carousel.prototype.keydown = function (e) { switch (e.which) { case 37: this.prev(); break case 39: this.next(); break default: return } e.preventdefault() } carousel.prototype.cycle = function (e) { e || (this.paused = false) this.interval && clearinterval(this.interval) this.options.interval && !this.paused && (this.interval = setinterval($.proxy(this.next, this), this.options.interval)) return this } carousel.prototype.getitemindex = function (item) { this.$items = item.parent().children('.item') return this.$items.index(item || this.$active) } carousel.prototype.getitemfordirection = function (direction, active) { var delta = direction == 'prev' ? -1 : 1 var activeindex = this.getitemindex(active) var itemindex = (activeindex + delta) % this.$items.length return this.$items.eq(itemindex) } carousel.prototype.to = function (pos) { var that = this var activeindex = this.getitemindex(this.$active = this.$element.find('.item.active')) if (pos > (this.$items.length - 1) || pos < 0) return if (this.sliding) return this.$element.one('slid.bs.carousel', function () { that.to(pos) }) // yes, "slid" if (activeindex == pos) return this.pause().cycle() return this.slide(pos > activeindex ? 'next' : 'prev', this.$items.eq(pos)) } carousel.prototype.pause = function (e) { e || (this.paused = true) if (this.$element.find('.next, .prev').length && $.support.transition) { this.$element.trigger($.support.transition.end) this.cycle(true) } this.interval = clearinterval(this.interval) return this } carousel.prototype.next = function () { if (this.sliding) return return this.slide('next') } carousel.prototype.prev = function () { if (this.sliding) return return this.slide('prev') } carousel.prototype.slide = function (type, next) { var $active = this.$element.find('.item.active') var $next = next || this.getitemfordirection(type, $active) var iscycling = this.interval var direction = type == 'next' ? 'left' : 'right' var fallback = type == 'next' ? 'first' : 'last' var that = this if (!$next.length) { if (!this.options.wrap) return $next = this.$element.find('.item')[fallback]() } if ($next.hasclass('active')) return (this.sliding = false) var relatedtarget = $next[0] var slideevent = $.event('slide.bs.carousel', { relatedtarget: relatedtarget, direction: direction }) this.$element.trigger(slideevent) if (slideevent.isdefaultprevented()) return this.sliding = true iscycling && this.pause() if (this.$indicators.length) { this.$indicators.find('.active').removeclass('active') var $nextindicator = $(this.$indicators.children()[this.getitemindex($next)]) $nextindicator && $nextindicator.addclass('active') } var slidevent = $.event('slid.bs.carousel', { relatedtarget: relatedtarget, direction: direction }) // yes, "slid" if ($.support.transition && this.$element.hasclass('slide')) { $next.addclass(type) $next[0].offsetwidth // force reflow $active.addclass(direction) $next.addclass(direction) $active .one('bstransitionend', function () { $next.removeclass([type, direction].join(' ')).addclass('active') $active.removeclass(['active', direction].join(' ')) that.sliding = false settimeout(function () { that.$element.trigger(slidevent) }, 0) }) .emulatetransitionend(carousel.transition_duration) } else { $active.removeclass('active') $next.addclass('active') this.sliding = false this.$element.trigger(slidevent) } iscycling && this.cycle() return this } // carousel plugin definition // ========================== function plugin(option) { return this.each(function () { var $this = $(this) var data = $this.data('bs.carousel') var options = $.extend({}, carousel.defaults, $this.data(), typeof option == 'object' && option) var action = typeof option == 'string' ? option : options.slide if (!data) $this.data('bs.carousel', (data = new carousel(this, options))) if (typeof option == 'number') data.to(option) else if (action) data[action]() else if (options.interval) data.pause().cycle() }) } var old = $.fn.carousel $.fn.carousel = plugin $.fn.carousel.constructor = carousel // carousel no conflict // ==================== $.fn.carousel.noconflict = function () { $.fn.carousel = old return this } // carousel data-api // ================= var clickhandler = function (e) { var href var $this = $(this) var $target = $($this.attr('data-target') || (href = $this.attr('href')) && href.replace(/.*(?=#[^\s]+$)/, '')) // strip for ie7 if (!$target.hasclass('carousel')) return var options = $.extend({}, $target.data(), $this.data()) var slideindex = $this.attr('data-slide-to') if (slideindex) options.interval = false plugin.call($target, options) if (slideindex) { $target.data('bs.carousel').to(slideindex) } e.preventdefault() } $(document) .on('click.bs.carousel.data-api', '[data-slide]', clickhandler) .on('click.bs.carousel.data-api', '[data-slide-to]', clickhandler) $(window).on('load', function () { $('[data-ride="carousel"]').each(function () { var $carousel = $(this) plugin.call($carousel, $carousel.data()) }) }) }(jquery); /* ======================================================================== * bootstrap: dropdown.js v3.3.0 * http://getbootstrap.com/javascript/#dropdowns * ======================================================================== * copyright 2011-2014 twitter, inc. * licensed under mit (https://github.com/twbs/bootstrap/blob/master/license) * ======================================================================== */ +function ($) { 'use strict'; // dropdown class definition // ========================= var backdrop = '.dropdown-backdrop' var toggle = '[data-toggle="dropdown"]' var dropdown = function (element) { $(element).on('click.bs.dropdown', this.toggle) } dropdown.version = '3.3.0' dropdown.prototype.toggle = function (e) { var $this = $(this) if ($this.is('.disabled, :disabled')) return var $parent = getparent($this) var isactive = $parent.hasclass('open') clearmenus() if (!isactive) { if ('ontouchstart' in document.documentelement && !$parent.closest('.navbar-nav').length) { // if mobile we use a backdrop because click events don't delegate $('