Commit ed699265 by Crisu83

merge with default

parents d7e91463 cf04c538
/* ==========================================================
* bootstrap-alert.js v2.0.0
* bootstrap-alert.js v2.0.2
* http://twitter.github.com/bootstrap/javascript.html#alerts
* ==========================================================
* Copyright 2012 Twitter, Inc.
......@@ -51,11 +51,14 @@
$parent.length || ($parent = $this.hasClass('alert') ? $this : $this.parent())
$parent.removeClass('in')
$parent
.trigger('close')
.removeClass('in')
function removeElement() {
$parent.remove()
$parent.trigger('closed')
$parent
.trigger('closed')
.remove()
}
$.support.transition && $parent.hasClass('fade') ?
......
/* ============================================================
* bootstrap-button.js v2.0.0
* bootstrap-button.js v2.0.2
* http://twitter.github.com/bootstrap/javascript.html#buttons
* ============================================================
* Copyright 2012 Twitter, Inc.
......@@ -91,7 +91,9 @@
$(function () {
$('body').on('click.button.data-api', '[data-toggle^=button]', function ( e ) {
$(e.currentTarget).button('toggle')
var $btn = $(e.target)
if (!$btn.hasClass('btn')) $btn = $btn.closest('.btn')
$btn.button('toggle')
})
})
......
/* ==========================================================
* bootstrap-carousel.js v2.0.0
* bootstrap-carousel.js v2.0.2
* http://twitter.github.com/bootstrap/javascript.html#carousel
* ==========================================================
* Copyright 2012 Twitter, Inc.
......@@ -29,6 +29,9 @@
this.$element = $(element)
this.options = $.extend({}, $.fn.carousel.defaults, options)
this.options.slide && this.slide(this.options.slide)
this.options.pause == 'hover' && this.$element
.on('mouseenter', $.proxy(this.pause, this))
.on('mouseleave', $.proxy(this.cycle, this))
}
Carousel.prototype = {
......@@ -61,6 +64,7 @@
, pause: function () {
clearInterval(this.interval)
this.interval = null
return this
}
......@@ -88,6 +92,8 @@
$next = $next.length ? $next : this.$element.find('.item')[fallback]()
if ($next.hasClass('active')) return
if (!$.support.transition && this.$element.hasClass('slide')) {
this.$element.trigger('slide')
$active.removeClass('active')
......@@ -133,6 +139,7 @@
$.fn.carousel.defaults = {
interval: 5000
, pause: 'hover'
}
$.fn.carousel.Constructor = Carousel
......
/* =============================================================
* bootstrap-collapse.js v2.0.0
* bootstrap-collapse.js v2.0.2
* http://twitter.github.com/bootstrap/javascript.html#collapse
* =============================================================
* Copyright 2012 Twitter, Inc.
......@@ -74,7 +74,9 @@
[dimension](size || 'auto')
[0].offsetWidth
this.$element.addClass('collapse')
this.$element[size ? 'addClass' : 'removeClass']('collapse')
return this
}
, transition: function ( method, startEvent, completeEvent ) {
......
/* ============================================================
* bootstrap-dropdown.js v2.0.0
* bootstrap-dropdown.js v2.0.2
* http://twitter.github.com/bootstrap/javascript.html#dropdowns
* ============================================================
* Copyright 2012 Twitter, Inc.
......
/* =========================================================
* bootstrap-modal.js v2.0.0
* bootstrap-modal.js v2.0.2
* http://twitter.github.com/bootstrap/javascript.html#modals
* =========================================================
* Copyright 2012 Twitter, Inc.
......
/* ===========================================================
* bootstrap-popover.js v2.0.0
* bootstrap-popover.js v2.0.2
* http://twitter.github.com/bootstrap/javascript.html#popovers
* ===========================================================
* Copyright 2012 Twitter, Inc.
......
/* =============================================================
* bootstrap-scrollspy.js v2.0.0
* bootstrap-scrollspy.js v2.0.2
* http://twitter.github.com/bootstrap/javascript.html#scrollspy
* =============================================================
* Copyright 2012 Twitter, Inc.
......
/* ========================================================
* bootstrap-tab.js v2.0.0
* bootstrap-tab.js v2.0.2
* http://twitter.github.com/bootstrap/javascript.html#tabs
* ========================================================
* Copyright 2012 Twitter, Inc.
......
/* ===========================================================
* bootstrap-tooltip.js v2.0.0
* bootstrap-tooltip.js v2.0.2
* http://twitter.github.com/bootstrap/javascript.html#tooltips
* Inspired by the original jQuery.tipsy by Jason Frame
* ===========================================================
......@@ -206,7 +206,7 @@
title = $e.attr('data-original-title')
|| (typeof o.title == 'function' ? o.title.call($e[0]) : o.title)
title = title.toString().replace(/(^\s*|\s*$)/, "")
title = (title || '').toString().replace(/(^\s*|\s*$)/, "")
return title
}
......
/* ===================================================
* bootstrap-transition.js v2.0.0
* bootstrap-transition.js v2.0.2
* http://twitter.github.com/bootstrap/javascript.html#transitions
* ===================================================
* Copyright 2012 Twitter, Inc.
......
/* =============================================================
* bootstrap-typeahead.js v2.0.0
* bootstrap-typeahead.js v2.0.2
* http://twitter.github.com/bootstrap/javascript.html#typeahead
* =============================================================
* Copyright 2012 Twitter, Inc.
......@@ -40,6 +40,7 @@
, select: function () {
var val = this.$menu.find('.active').attr('data-value')
this.$element.val(val)
this.$element.change();
return this.hide()
}
......@@ -165,9 +166,6 @@
}
, keyup: function (e) {
e.stopPropagation()
e.preventDefault()
switch(e.keyCode) {
case 40: // down arrow
case 38: // up arrow
......@@ -180,6 +178,7 @@
break
case 27: // escape
if (!this.shown) return
this.hide()
break
......@@ -187,10 +186,11 @@
this.lookup()
}
e.stopPropagation()
e.preventDefault()
}
, keypress: function (e) {
e.stopPropagation()
if (!this.shown) return
switch(e.keyCode) {
......@@ -210,12 +210,12 @@
this.next()
break
}
e.stopPropagation()
}
, blur: function (e) {
var that = this
e.stopPropagation()
e.preventDefault()
setTimeout(function () { that.hide() }, 150)
}
......
Markdown is supported
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