2
0
mirror of https://github.com/tenrok/bootstrap.git synced 2026-06-14 18:42:30 +03:00

change namespace back to dot notation and someother js shizzle

This commit is contained in:
fat
2013-05-16 20:19:51 -07:00
parent 5ab72f7687
commit 140ef2320b
22 changed files with 105 additions and 103 deletions
+5 -5
View File
@@ -45,14 +45,14 @@
$parent = $this.hasClass('alert') ? $this : $this.parent()
}
$parent.trigger(e = $.Event('bs:alert:close'))
$parent.trigger(e = $.Event('close.bs.alert'))
if (e.isDefaultPrevented()) return
$parent.removeClass('in')
function removeElement() {
$parent.trigger('bs-closed').remove()
$parent.trigger('closed.bs.alert').remove()
}
$.support.transition && $parent.hasClass('fade') ?
@@ -69,9 +69,9 @@
$.fn.alert = function (option) {
return this.each(function () {
var $this = $(this)
var data = $this.data('bs-alert')
var data = $this.data('bs.alert')
if (!data) $this.data('bs-alert', (data = new Alert(this)))
if (!data) $this.data('bs.alert', (data = new Alert(this)))
if (typeof option == 'string') data[option].call($this)
})
}
@@ -91,6 +91,6 @@
// ALERT DATA-API
// ==============
$(document).on('click.bs-alert.bs-data-api', dismiss, Alert.prototype.close)
$(document).on('click.bs.alert.data-api', dismiss, Alert.prototype.close)
}(window.jQuery);