mirror of
https://github.com/twbs/bootstrap.git
synced 2025-09-25 21:09:06 +02:00
all unit tests passing in ie7
This commit is contained in:
6
js/bootstrap-collapse.js
vendored
6
js/bootstrap-collapse.js
vendored
@@ -124,8 +124,10 @@
|
||||
|
||||
$(function () {
|
||||
$('body').on('click.collapse.data-api', '[data-toggle=collapse]', function ( e ) {
|
||||
var $this = $(this)
|
||||
, target = $this.attr('data-target') || e.preventDefault() || $this.attr('href')
|
||||
var $this = $(this), href
|
||||
, target = $this.attr('data-target')
|
||||
|| e.preventDefault()
|
||||
|| (href = $this.attr('href')) && href.replace(/.*(?=#[^\s]+$)/, '') //strip for ie7
|
||||
, option = $(target).data('collapse') ? 'toggle' : $this.data()
|
||||
$(target).collapse(option)
|
||||
})
|
||||
|
Reference in New Issue
Block a user