Commit 2fe58cbd by niskac

updated assets to Bootstrap 2.0.2

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